claude-skill-compounder
CLAUDE.md1 starsChanged 38 days agoMITView on GitHub
Guidance for Claude Code when working in this repository. compound: a Claude Code mod plus a CLI. The repository root is the plugin. Read docs/design.md before changing anything; it is the contract both halves are built to. - One implementation of each thing. The mod never reads or writes a lesson file or the event log; it calls bin/compound. Event field names are defined once, in the docstring at the top of bin/compound. - No mocks. A test writes real…
- Reads credentials
In this repository4 other files it gives its agents.
- finish-taskSkill
- learnSkill
- reuseSkill
- verify-assumptions-firstSkill
The file
We split this CLAUDE.md into the rules it gives an agent
3 rules. About 0 are common, 1 is distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 38
No mocks. A test writes real files and runs the real CLI.
- Very specific: line 40
Never run bin/compound install, uninstall or update against the real ~/.claude while developing.
- Very specific: line 60
Before a tool call the mod makes one CLI call, check, and no listing.
≈ “Common” is an estimate: at least 1 in 5 of the 26,980 CLAUDE.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
CLAUDE.md
Guidance for Claude Code when working in this repository.
What this is
compound: a Claude Code mod plus a CLI. The repository root is the plugin. Read
docs/design.md before changing anything; it is the contract both halves are built to.
| Path | What |
.claude-plugin/plugin.json, hooks/hooks.json | the plugin manifest and the hooks module's name |
hooks/register.ts | every hook; the only file that touches the engine interface $ |
hooks/judge.ts, render.ts, store.ts, knobs.ts, safe.ts, view.ts | pure logic, each with a *.test.ts; view.ts is what the band and the /compound pane show |
hooks/ui.test.ts | the band and the pane mounted through the hooks on the terminal and desktop surfaces |
types/index.d.ts | the contract for the values the mod keeps in $.state; plugin.json names it |
bin/compound | the CLI: one Python file, standard library only, runs on Python 3.9 |
skills/learn, skills/reuse | the two procedures the mod sends Claude to |
lessons/, skills/ | the general pool shipped to every user |
tests/test_*.py | CLI tests |
tests/journeys/ | real-session drivers, run by hand |
dev/ui-check.sh, dev/ui-check.tape | a recorded interactive session (vhs) with a screenshot of each phase, for looking at the band and the pane |
Commands
./run_tests.sh
claude plugin validate --strict .
claude plugin test .
python3 tests/journeys/journey_<name>.pyRules
- One implementation of each thing. The mod never reads or writes a lesson file or the
event log; it calls
bin/compound. Event field names are defined once, in the docstring at the top ofbin/compound. - No mocks. A test writes real files and runs the real CLI. A journey runs a real session.
- Never run
bin/compound install,uninstallorupdateagainst the real~/.claudewhile developing. Pass--claude-dirand--bin-dir, or setCOMPOUND_HOMEandCOMPOUND_CLAUDE_DIR. - A hook must never break a turn: every failure is caught, logged as an
errorevent and reported, and the turn goes on. - The function-hook API allows a plugin one unmatched
tool.callhook, requires literal names in$.env.get, and keeps a module's variables for the life of the process, so per-session state is keyed on the session id. - A render hook draws from
$.stateand answersnext(e)on any failure. The band's one timer runs only while a spinner turns or a result fades. The pane's CLI reads are never made on a path a tool call waits on. - A Bash call is exempt from the guards, recall and capture only when
soleCliShapeinhooks/render.tsproves it is one simplecompound ...invocation. It is an allowlist and fails closed: add to it only what can be proved, with a case inhooks/decisions.test.tsin each direction. - Whether a recall counts toward ineffective is decided in the CLI (
recall_verdict), whencompound logwrites the event. The mod reads the reply and predicts nothing. compound logtakes only the types the mod writes. A test that needs an event a command writes usesseed_eventintests/test_support.py, which refuses a store that is not in a temporary directory.- Before a tool call the mod makes one CLI call,
check, and no listing. Every CLI call the mod makes takes its budget fromBUDGETinhooks/render.ts: 2 s at most while a tool call or a stop waits, 5 s at most at a typed prompt. - What the user is told about a
compoundcommand the session ran follows the event the command wrote, never the command's text. - Documentation describes what the package does now, for a reader who has never seen it.
A new
COMPOUND_*name, subcommand, option or claim kind goes intodocs/design.mdin the same change;tests/test_docs.pyfails otherwise. notes/holds dated session notes. It is a log, not a description of behaviour.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

