spec-init
Skill0 starsChanged 45 days agoMITView on GitHub
Install the spec-as-truth substrate into a repo: specs/ with the registry tool, FORMAT.md, a registry skeleton, and co-change-derived boundary proposals. Use when the user wants to set up spec-driven development, initialize the spec layer, or invokes /spec-init in a repo without specs/.
7 other projects use a version of this.
Adopted by
Most recently taken up by
- thistleknot/skillstheir own version, first seen Nov 8, 2026
- yuri-xyz/skillstheir own version, first seen Nov 8, 2026
- HHU3637kr/skillstheir own version, first seen Sep 22, 2026
- maurigre/mgr-methodtheir own version, first seen Jul 15, 2026
- fernandoxavier02/Pipeline-Orchestratortheir own version, first seen Jun 29, 2026
- legeling/PromptHubtheir own version, first seen Jun 15, 2026
Other versions7 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 7
- legeling/PromptHub★ 1.8ksame name
- HHU3637kr/skills★ 146same name
- maurigre/mgr-method★ 2same name
- yuri-xyz/skills★ 2same name
- fernandoxavier02/Pipeline-Orchestrator★ 1same name
- telefrek/vallorcine★ 0same name
- thistleknot/skills★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository14 other files it gives its agents.
- architectureSkill
- debugSkill
- fan-outSkill
- finishSkill
- merge-conflictsSkill
- reviewSkill
- spec-adoptSkill
- spec-amendSkill
- spec-boundariesSkill
- spec-implementSkill
- spec-reviewSkill
- spec-runSkill
- spec-shapeSkill
- tddSkill
The file
We split this skill into the rules it gives an agent
5 rules. 0 are common, 0 are distinctive, and 5 are very specific to this project.
0
Common
Most of the 4 edited versions we read keep these.
0
Distinctive
This author's own choices. Worth a look.
5
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 15
Refuse double-init: If specs/registry.yaml exists, stop and say so — point at node specs/registry.mjs check instead.
- Very specific: line 31
If .git/hooks/pre-commit already exists (husky, lefthook, git-lfs…), do NOT overwrite it — instead add a line to the existing hook (or the …
- Very specific: line 47
If the repo already carries a section describing those layers (a domain-modeling setup writes one), point at it instead of restating it — …
- Very specific: line 63
Propose boundaries from the history: Run python3 ${CLAUDE_PLUGIN_ROOT}/substrate/cochange.py .
- Very specific: line 98
Never overwrite an existing specs/ — this skill initialises, it does not upgrade.
“Common” is measured: kept by at least 6 in 10 of the 4 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Install the spec layer's substrate into the current repo. This scaffolds; it adopts nothing — adoption is its own act, per FORMAT.md.
Procedure
- Refuse double-init. If
specs/registry.yamlexists, stop and say so — point atnode specs/registry.mjs checkinstead. - Copy the substrate from this plugin into
specs/:${CLAUDE_PLUGIN_ROOT}/substrate/registry.mjs→specs/registry.mjs${CLAUDE_PLUGIN_ROOT}/substrate/FORMAT.md→specs/FORMAT.md${CLAUDE_PLUGIN_ROOT}/substrate/registry.template.yaml→specs/registry.yaml${CLAUDE_PLUGIN_ROOT}/substrate/REGISTRY.template.md→specs/REGISTRY.md${CLAUDE_PLUGIN_ROOT}/substrate/hooks/pre-commit→specs/hooks/pre-commit(keep it executable) These are vendored copies on purpose: the repo must be able to runnode specs/registry.mjs checklocally with no plugin installed. js-yaml is used when the repo has it; a bundled fallback parser covers the rest.
- Wire the repo so the layer is ambient, not opt-in.
- Install the hook:
ln -sf ../../specs/hooks/pre-commit .git/hooks/pre-commit. If.git/hooks/pre-commitalready exists (husky, lefthook, git-lfs…), do NOT overwrite it — instead add a line to the existing hook (or the repo's hook manager config) that runsspecs/hooks/pre-commit. The hook blocks commits stagingspecs/whencheckfails, and warns (never blocks) when staged code is spec-owned with no spec delta. - Append the spec section to the repo's agent instruction file: adapt
${CLAUDE_PLUGIN_ROOT}/substrate/AGENTS.section.mdinto AGENTS.md (or CLAUDE.md — whichever the repo treats as canonical), filling in the adopted-capabilities list (right after init: "none yet"). That section is the knowledge-layout map (plans, ADRs, product briefs). Do not create those directories — the first file in each is when it appears. - Fill the section's verification commands — test, typecheck, lint —
from the repo's manifest (package.json scripts, Makefile, Cargo.toml,
pyproject.toml), and run each once to confirm it works. An unattended
run (spec-run) verifies with exactly these; drop any the repo lacks,
and ask the user when none is discoverable.
If the repo already carries a section describing those layers (a
domain-modelingsetup writes one), point at it instead of restating it — two maps of the same layers will drift.
- Install the hook:
- Greenfield fork. A repo with no (or only scaffold) history has nothing
for co-change to read and nothing for spec-adopt to describe — skip steps
5 and 6 and invert the flow: capabilities come from the user's intent —
spec-system:spec-shape interviews for it — and each first spec is written
as a target, not a description. Its
registry entry carries
pinned: nonewith aplan:— the missing pin is the record that the code does not exist yet,checknotes (rather than rejects) owned paths not yet on disk while it is open, and spec-implement builds test-first against the plan, runningregistry.mjs pinwhen the behaviour is real and evidenced. Keep the entry's statusunspecifieduntil that first pin move landsadopted. - Propose boundaries from the history. Run
python3 ${CLAUDE_PLUGIN_ROOT}/substrate/cochange.py . --threshold 0.35(raise the threshold by 0.05 if one cluster swallows everything; lower it if all singletons). Read the repo's own conventions (CLAUDE.md / AGENTS.md / architecture docs) before naming anything. - Fill
specs/registry.yamlwith the proposed capabilities, every onestatus: unspecified— they are hypotheses, and the registry says so. Apply the boundary rules from FORMAT.md: a capability is observable behaviour at a contract; spec names are not package names; hub files are seams or cross-cutting, not capabilities. Claim shared files symbol-by-symbol (path#symbol), never whole. - Verify and render.
node specs/registry.mjs checkmust pass; thennode specs/registry.mjs syncto generate the REGISTRY.md tables. - Stop for the human. Present the proposed boundaries with the co-change evidence and ask which to confirm — naming and drawing boundaries is the user's decision. Do not adopt any capability in the same pass; suggest starting with the smallest confirmed one.
- Record the reasoning the registry cannot hold. Where a confirmed
boundary was argued over, drawn against the evidence, or landed as
contested/unspecified by design, offer an ADR — but only when the decision is hard to reverse, surprising without context, and a real trade-off (FORMAT.md, "Recording a decision as an ADR"). It goes todocs/adr/NNNN-<slug>.md, one paragraph is enough, andregistry.yamlpoints at it withadr:. This is the momentdocs/adr/gets created if the repo has none; step 3 deliberately did not create it empty.
Rules
- Scaffold only: no spec files, no pins, no behaviour changes. (The
greenfield fork's target specs are the one exception — pinned
none, they assert nothing about code.) - Never overwrite an existing specs/ — this skill initialises, it does not upgrade. (Upgrading a vendored registry.mjs is a manual copy, compared by TOOL_VERSION.)
- The registry template's comments are the user's documentation — keep them.
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.

