Skip to content

Variable: SegmentPolicySchema

Makaio Framework


Makaio Framework / contracts/session / SegmentPolicySchema

const SegmentPolicySchema: ZodObject<{ fromMessageId: ZodString; overrides: ZodOptional<ZodRecord<ZodString, ZodLiteral<"exclude">>>; policy: ZodEnum<{ exclude: "exclude"; summarize: "summarize"; verbatim: "verbatim"; }>; stripReasoning: ZodOptional<ZodBoolean>; stripToolOutputs: ZodOptional<ZodBoolean>; summaryText: ZodOptional<ZodString>; toMessageId: ZodString; }, $strip>

Defined in: ../../../packages/contracts/src/session/schemas/lifecycle-events.ts:24

Policy for a contiguous range of messages in a fork context window.

Segments define how a slice of conversation history is projected into the child session. When segments is present on ForkTransforms, removedMessageIds and appliedPipeline are ignored — segments take precedence as the authoritative context curation strategy.