co-mono/packages
Mario Zechner a38e619095 feat(coding-agent): implement new compaction system with overflow recovery
Phase 1: Updated compaction.ts
- findCutPoint now returns CutPointResult with isSplitTurn and turnStartIndex
- Can cut at user, assistant, or bashExecution messages (never tool results)
- Added turnPrefixSummary support for split turns (parallel summarization)
- estimateTokens helper for context size estimation

Phase 2: Updated session-manager.ts
- CompactionEntry now has optional turnPrefixSummary field
- loadSessionFromEntries injects both summaries when turn was split

Phase 3: Updated agent-session.ts
- Overflow detection via isContextOverflow after agent_end
- Proactive compaction check on turn_end before next LLM call
- _abortingForCompaction flag to skip saving aborted messages
- Auto-retry after overflow recovery or proactive compaction
- New event fields: reason (overflow/threshold), willRetry

Phase 4: Updated interactive-mode.ts
- Shows reason in compaction status (Context overflow detected...)
- Shows retry status after compaction

Tests updated for new CutPointResult return type.
2025-12-09 17:18:53 +01:00
..
agent Release v0.16.0 2025-12-09 15:43:29 +01:00
ai Update generated models 2025-12-09 15:44:45 +01:00
coding-agent feat(coding-agent): implement new compaction system with overflow recovery 2025-12-09 17:18:53 +01:00
mom Port truncation logic from coding-agent to mom 2025-12-09 16:05:08 +01:00
pods Release v0.16.0 2025-12-09 15:43:29 +01:00
proxy Release v0.16.0 2025-12-09 15:43:29 +01:00
tui Release v0.16.0 2025-12-09 15:43:29 +01:00
web-ui Release v0.16.0 2025-12-09 15:43:29 +01:00