Repository navigation
fix(agents): send every repo search to code_search - #35
Merged
Merged
Conversation
…l searches bash must not run
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.
Why
An audit of transcripts from Sep 22–25, after the code-index fixes (#25–#34), found that code search no longer fails (0 of 383 calls, down from 47%). But agents on Opus 5.5, the default model since Sep 22, almost never use it:
lemoncrow:code)The instruction said "otherwise start with
code_search" and banned grep only "to read, search, or recheck indexed results". Opus 5.5 reads that narrowly. It runsgrep -rn,rgandgit grepover the tree for symbols, UI copy, flag names and constants, which are all things code search answers.Change
In the write-capable tool-discipline section, which build agents and main sessions get:
code_search, including symbols, strings and regex, with every term in one query.bashnames the banned commands:grep -r,rg,git grep,find,sed,catandheadover the repo. Shell search stays allowed for logs, scratch files and a command's own output.The persona budget has only 16 tokens to spare on
main, so the rule replaces existing wording instead of adding to it. Persona sources now total 4,949 of 4,950 tokens. It drops the clause "related_symbols/candidate_filescover every site" andtailfrom the list of banned readers.The read-only section is unchanged.
Checked
make sync-agent-contextregenerated 31 host files.Follow-up
Rerun the audit a few days after this is installed and compare Opus 5.5's share of repo searches against the 3% above.