Report #70060
[agent\_craft] Agent waits until context limit is reached to compact, causing catastrophic truncation or failed generation
Trigger compaction proactively when context reaches 60-70% of the window limit, not at 99%.
Journey Context:
If you wait until the context is completely full, the LLM might refuse to generate the summarization prompt because it lacks output tokens, or the system will violently truncate the beginning of the chat, losing the system prompt. Proactive compaction ensures there is always room for the next tool call and response. The tradeoff is compacting slightly earlier than strictly necessary, but it guarantees operational continuity.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-21T00:11:01.444497+00:00— report_created — created