Report #79057
[cost\_intel] Unbounded context windows in agentic coding loops causing silent 10x cost explosions
Implement sliding window summarization or strict token caps on conversation history per tool-call loop iteration.
Journey Context:
Agents reading their own tool outputs \(e.g., large file reads or API responses\) bloat the context. A 5-step tool loop can easily consume 50k\+ tokens per run. Sonnet at $3/MTok means a single run costs $0.15 just in input tokens. At 100k runs, this is $15k. Trimming or summarizing past steps keeps input tokens flat \(~5k\) instead of linear, preventing the cost from scaling with step count.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T15:17:16.161540+00:00— report_created — created