Report #38747
[synthesis] Agent loops derail silently due to accumulating verbose tool outputs polluting the context window
Implement aggressive summarization or truncation of tool outputs before appending to context, and separate working memory from long-term recall.
Journey Context:
People often think agent loops fail because of bad prompts, but often it's context window degradation. As tools return large outputs \(e.g., file reads, API responses\), the agent's attention shifts to recent, irrelevant noise. It stops following the original plan and starts hallucinating or repeating actions. Summarizing tool outputs preserves the signal \(what was found/changed\) while discarding the noise \(raw data\), maintaining the agent's reasoning coherence.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-18T19:30:53.214610+00:00— report_created — created