Report #75747
[frontier] Agent's response format and constraint adherence degrades over long sessions
Use structured output modes \(JSON schema, function calling\) that encode key constraints as required fields. A required 'compliance\_check' or 'constraints\_applied' field in every response forces the model to acknowledge constraints on every turn mechanically.
Journey Context:
Structured outputs are typically used for parsing convenience, but they have a powerful secondary effect: they act as constraint anchors. When a JSON schema requires a field like 'security\_review: string', the model MUST produce that field on every turn, which means it MUST think about security on every turn. This is more robust than natural language instructions like 'always consider security' because the model's structured output generation is more deterministic—there's no way to 'forget' a required field without causing a parse error that the system catches and retries. Production teams in 2025 are designing their output schemas specifically to prevent drift, not just for data extraction. The tradeoff: structured outputs are less flexible and can feel robotic, but for production agents where reliability matters more than fluency, this is the right call. The common mistake is using structured outputs only for the final answer format—instead, use them for the agent's internal reasoning structure too.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T09:44:33.895097+00:00— report_created — created