[v2] Make compaction summaries structured and economical#2406
[v2] Make compaction summaries structured and economical#2406SivanCola wants to merge 8 commits into
Conversation
- Replaces free-form summary prompt with structured 5-section template (Goal / Decisions / Files / Commands / Pending) - Adds foldEconomics() to skip compaction when input region is too small - Wraps summaries in <compaction-summary> tags for distinguishability
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: fc6f416022
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Resolved the merge conflict by merging the latest |
Summary
Change compaction summaries to a fixed five-section structure and skip summarization when the compactable region is too small to be worthwhile.
Root Cause
Free-form summaries are harder for the agent to resume from, and compacting very small regions can cost more latency and tokens than it saves.
Technical Approach
Update the summarizer prompt to emit Goal, Decisions, Files, Commands, and Pending sections; wrap summaries in a dedicated tag; add a simple fold-economics threshold.
Focused Optimization Points
Verification
Not run during this publishing pass. This is opened as a draft PR for upstream review of the split branch.