feat: add merge-blocks command for merging adjacent compressed blocks#33
Closed
ranxianglei wants to merge 1 commit into
Closed
feat: add merge-blocks command for merging adjacent compressed blocks#33ranxianglei wants to merge 1 commit into
ranxianglei wants to merge 1 commit into
Conversation
f636c7e to
1cfdc10
Compare
… blocks - lib/compress/merge-blocks.ts: model-callable merge_blocks tool - lib/commands/merge-blocks.ts: /acp merge-blocks user command - nudge.ts: guide model to use merge_blocks tool (not slash command) - Enhanced block list shows topic per block - Tests updated for new nudge text
1cfdc10 to
797a027
Compare
Owner
Author
|
Not help ,close . |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
/acp merge-blockscommand: merge adjacent compressed blocks in one callb1: "Proxy cost analysis")/acp merge-blocks <range>Problem
Sessions accumulate 400+ small blocks. Model can't merge them because it doesn't know compress can cover existing blocks, and mark_block is deferred + one-at-a-time.
Solution
/acp merge-blocks 421-428— auto-finds message range, concatenates summaries, creates new block, deactivates old ones via consumedBlockIds.Changes (8 files)
lib/commands/merge-blocks.ts(350 lines) — new commandlib/commands/help.ts— help textlib/commands/index.ts— command registrationlib/hooks.ts— command handler wiringlib/prompts/extensions/nudge.ts— enhanced block list + merge guidancetests/nudge-text.test.ts— updated testsdevlog/2026-06-29_merge-blocks/{REQ,WORKLOG}.mdTest plan
/acp merge-blocks 1-3merges blocks correctly