Claude-skill-registry compound-apply-spec
Write a CompoundSpec v2 JSON payload and apply it via compound_apply to create/update skills, instincts, and docs.
install
source · Clone the upstream repo
git clone https://github.com/majiayu000/claude-skill-registry
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/majiayu000/claude-skill-registry "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/data/compound-apply-spec" ~/.claude/skills/majiayu000-claude-skill-registry-compound-apply-spec && rm -rf "$T"
manifest:
skills/data/compound-apply-spec/SKILL.mdsource content
<!-- BEGIN:compound:skill-managed -->
Why this exists
The plugin is deterministic. The agent is not. So we separate:
- Agent: decides what to learn (writes the spec).
- Tool (
): validates and applies changes safely.compound_apply
CompoundSpec v2
Top-level keys (all optional except
schema_version):
: must beschema_version2
:auto{ reason, sessionID }
instincts
instincts
:create[]{ id, title, trigger, action, confidence }
:update[]{ id, confidence_delta, evidence_note }
skills
skills
:create[]{ name, description, body }
:update[]{ name, description?, body }
Notes:
must matchname
.^[a-z][a-z0-9]*(?:-[a-z0-9]+)*$
is markdown without frontmatter.body- If updating a skill:
must be the entire final managed body (no snippets/diffs).skills.update[].body
docs
docs
: boolean (refresh derived indexes/blocks)sync
:blocks.upsert[]{ file, id, content }
Only upsert AI-managed blocks; do not rewrite human-owned text.
When writing markdown content inside
docs.blocks.upsert[].content:
- Use repo-root-relative paths when referencing files/dirs (no absolute paths).
changelog
changelog
: a single sentence describing the memory delta.{ note }
Apply
- Draft the CompoundSpec v2 as a single JSON object.
- Output JSON only (no code fences, no commentary).
- Run
to validate and write the memory/doc updates.compound_apply()
Manual notes
This section is preserved when the skill is updated. Put human notes, caveats, and exceptions here.