Repository navigation
feat(kb): kb_edit patches big pages; a HOLD ends the task's /goal (v0.495.0) - #962
Merged
Merged
Conversation
….495.0) kb_write replaced a whole page and took inline text only, so adding two changelog lines to a ~149k-char page meant retyping it — which produced placeholder / literal $(cat …) bodies and pasted-back kb_read headers saved over the page, until a human edited it by hand. - kb_edit: anchored edits + append (optionally under a heading), baseRev conflict - kb_write: `file` source (agent folder only), shrink brake (>40% needs confirmRewrite), strips kb_read headers pasted onto a body - kb_read: heading / offset+limit / outline; big pages return an outline - /goal: a blocked/held/cancelled task ends the goal (prompt clause) and parking it types `/goal clear` into the live session Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
From a field report: an agent couldn't add two changelog lines to a ~149k-char KB page, and a task's
/goalkept re-prompting the agent after the task was put on HOLD.KB
kb_edit: anchorededits(eacholdStringmust occur exactly once) and/orappend, optionally at the end of anunderHeadingsection. OptionalbaseRevturns a stale read into a conflict.kb_write: acceptsfile(a .md/.txt in the agent's own folder, no dot-folders, ≤2 MB). Refuses a rewrite that deletes >40% of an existing page of ≥2k chars unlessconfirmRewriteis set, and says that args aren't shell-expanded when the body looks like$(cat …). Stripskb_readheader lines pasted onto the top of a body.kb_read:heading/offset+limit/outline. An unranged read of a page over 60k chars returns the outline plus the first 150 lines. Header lines now sit above a────fence.kb.write.refused,kb.write.conflict;kb.writtennow recordsmodeandfile./goal vs HOLD
/goalcondition) now says a blocked/held/cancelled task ends the goal.maybeHoldDelegatetypes/goal clearinto the live session when a task with criteria is parked, whoever parked it (the agent itself included). Auditedsession.goal.cleared.Tests:
scripts/kb-edit-test.cjs(50 assertions, including the incident end to end over the MCP process). Fulltest:governancepasses: 153/153.🤖 Generated with Claude Code