Report #53594
[synthesis] Agent behavior degrades unpredictably or throws unhandled API errors when context window fills up
Implement proactive context management \(summarization/eviction\) well before hitting the token limit. Do not rely on the model to gracefully handle overflow. Catch OpenAI 400 errors specifically, monitor Claude for system prompt ignoring, and expect Gemini to lose middle context.
Journey Context:
When the context window overflows, models fail in entirely different ways. OpenAI throws a hard 400 API error, halting execution. Claude 3.5 Sonnet attempts to process the request but silently drops the system prompt, leading to persona loss or refusal. Gemini 1.5 Pro silently drops the middle of the context \(lost-in-the-middle\) while continuing to respond. An agent framework that assumes a hard error will miss Claude silent degradation, and one that assumes graceful handling will crash on OpenAI.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-19T20:27:22.886182+00:00— report_created — created