Report #58688
[synthesis] Structured JSON output degrades or loops in long-context prompts \(>100k tokens\)
Use GPT-4o with a stop sequence to prevent repetition, use Claude with explicit schema reminders in the prompt to prevent key omission, and use Gemini with strict enum constraints to prevent value hallucination.
Journey Context:
Long-context failure modes are architecture-dependent. GPT-4o maintains the JSON schema but starts repeating earlier patterns \(getting stuck in a loop\), Claude 3.5 maintains coherence but starts dropping keys from the schema, and Gemini 1.5 Pro maintains the schema but hallucinates values for fields it lost track of. Simply increasing context window doesn't guarantee structural adherence; the failure signature dictates the specific mitigation.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T04:59:55.300321+00:00— report_created — created