Skip to content

UserIntentReasonSchema

const UserIntentReasonSchema: ZodObject<{ id: ZodOptional<ZodString>; intent: ZodString; referents: ZodOptional<ZodRecord<ZodString, ZodType<Mutable<JsonValue>, unknown, $ZodTypeInternals<Mutable<JsonValue>, unknown>>>>; type: ZodLiteral<"user_intent">; }, $strip>

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

Wire-format Zod parser for UserIntentReason. The type discriminator pins the variant; intent is an arbitrary natural-language string with no length constraint (callers may submit empty intents — the engine prompt builder is responsible for filtering them). An id, when present, must not be blank, and referents must be a JSON object.