Repository navigation
Add edits_self_config trait: agent writes to its own settings/hooks (#317) - #505
Merged
blitzcrieg1 merged 4 commits intoNov 27, 2026
Merged
Conversation
blitzcrieg1
force-pushed
the
feat/self-config-trait-317
branch
from
November 27, 2026 17:45
2cb9390 to
6efb80c
Compare
blitzcrieg1
force-pushed
the
feat/self-config-trait-317
branch
from
November 27, 2026 17:49
6efb80c to
43fb44e
Compare
blitzcrieg1
added a commit
that referenced
this pull request
Nov 27, 2026
Generated by Mistral Vibe. Co-authored-by: Mistral Vibe <[email protected]>
This was referenced Nov 28, 2026
This was referenced Nov 30, 2026
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.
First slice of #317 under the bounty program (#454), claimed on the issue — one trait per PR, starting with
edits_self_config. The other four signals stay for follow-up PRs.What lands
edits_self_config(registered inKNOWN_TRAITS), earned by a write to the agent's own configuration:~/.claude/settings.json/settings.local.json,~/.claude.json, files under~/.claude/hooks/,~/.cursor/hooks.json,~/.codex/hooks.json,~/.codex/config.toml. Project-local.claude/settings.jsoncounts — Claude Code reads it from the project too, and a hook planted there runs with the same authority. The filename must end the path:settings.json.bakdoes not count.apply_patchbody naming the path —classify_tool_call's write branch, which previously returned nothing); shell writes aimed at the path (redirect,tee,dd of=, in-placesed, thecp/mv/installdestination slot — reads and copies away from the path stay quiet, and single-quoted prose cannot fire it because the check runs on the literal view); and the MITRE mapper, which upgrades such a write to T1562 Impair Defenses.On corpus coverage
Corpus expectations assert rule ids, and a trait emits no Detection, so there is no honest corpus case for this PR — coverage is at the classifier/mapper level instead: 14 new tests pinning the fires and the quiet lookalikes (other tools' settings files,
.claudeproject notes, reads, prose about the path). When a rule consumes the trait, its corpus pair belongs with that rule's PR.Numbers
Tests collected 3034 → 3048 (+14). Benchmark unchanged (112 cases, 61/61, 0 missed, 0 false positives). The detection, MITRE, ingest and benchmark test files are fully green, and ruff is clean. Note: #504 (off-hours corpus) also touches the README collected count — if it lands first, this branch's count becomes 3051; happy to rebase.