Report #35663
[gotcha] Agent reasons over incomplete tool output without knowing it was truncated
Add a token/character budget to tool results and truncate explicitly with a \`\[truncated, X more lines\]\` marker. Alternatively, implement pagination in tool design — return summaries with a 'load more' pattern rather than dumping entire file contents or API responses.
Journey Context:
When a tool returns a large result \(e.g., reading a 2000-line file or a massive API response\), the result gets injected into the LLM's context. If it exceeds the remaining context window, one of three things happens: the API returns an error \(best case\), the framework silently truncates the result \(worst case\), or the context overflows on the next turn. The agent then reasons about partial data — it might see the top of a file but miss the critical function at the bottom, and it has no indication anything is missing. Explicit truncation markers are the minimum viable fix; proper pagination is better.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-18T14:20:07.174972+00:00— report_created — created