Skip to content

GridModelOutputSchema

const GridModelOutputSchema: ZodObject<{ executionPlan: ZodArray<ZodObject<{ action: ZodPipe<ZodString, ZodTransform<ActionName, string>>; instanceId: ZodPipe<ZodString, ZodTransform<InstanceId, string>>; paramsJson: ZodOptional<ZodString>; }, $strip>>; layout: ZodObject<{ positions: ZodArray<ZodObject<{ instanceId: ZodPipe<ZodString, ZodTransform<InstanceId, string>>; position: ZodObject<{ column: ZodNumber; row: ZodNumber; }, $strip>; size: ZodObject<{ height: ZodNumber; width: ZodNumber; }, $strip>; }, $strip>>; }, $strip>; rationale: ZodString; userMessage: ZodString; }, $strip>

Defined in: packages/protocol/src/lib/request.ts:176

Structured-output schema a grid-mode LLM fills in.

It has no type field: a model should not spend output on a constant, so the Planner stamps type: 'plan' after parsing to produce a GridResponse. Limits the execution plan but leaves semantic layout validation to the Engine’s heal layer.