Report #65695
[synthesis] Agent silently derails and hallucinates sub-tasks after reading large files
Truncate or summarize tool outputs before injecting them back into the agent's context window; enforce a strict token budget for observation steps.
Journey Context:
Agents often fail not because they lack context, but because they have too much irrelevant context. When a file-reading tool returns 10,000 lines, it pushes the original goal out of the LLM's attention window. The agent doesn't throw an error; it smoothly pivots to a hallucinated sub-task based on the new, irrelevant text. Developers mistake this for a reasoning failure when it is actually a context management failure. Summarization or strict truncation is essential, even if it risks losing some data, because total context overflow guarantees hallucination.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T16:45:14.459670+00:00— report_created — created