sdd-init
Skill0 starsChanged 8 months agoMITView on GitHub
Bootstraps the SDD context directory structure for a project. Creates context/specs/, context/plans/, context/impl/, and spec/active/ directories with convention guides. Use when starting a new SDD project or adding SDD to an existing codebase.
3 other projects use a version of this.
Adopted by
Most recently taken up by
- felipefontoura/pi-sdd-kittheir own version, first seen May 15, 2026
- sivaprasadreddy/sdd-skillstheir own version, first seen Apr 27, 2026
- Maicololiveras/praxisgenai-agent-orchestratortheir own version, first seen Mar 16, 2026
Other versions3 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 3
- felipefontoura/pi-sdd-kit★ 34same name
- sivaprasadreddy/sdd-skills★ 32same name
- Maicololiveras/praxisgenai-agent-orchestrator★ 1same 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 repository13 other files it gives its agents.
- AGENTS.mdAGENTS.md
- sdd-adrSkill
- sdd-implementSkill
- sdd-iterateSkill
- sdd-monitorSkill
- sdd-planSkill
- sdd-reviewSkill
- sdd-runSkill
- sdd-specSkill
- sdd-standupSkill
- sdd-statusSkill
- sdd-triageSkill
- sdd-ux-validateSkill
The file
We split this skill into the rules it gives an agent
11 rules. 0 are common, 4 are distinctive, and 7 are very specific to this project.
0
Common
Most of the 3 edited versions we read keep these.
4
Distinctive
This author's own choices. Worth a look.
7
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 12
Check if context/ already exists.
- Distinctive: line 14
Create the following directories:
- Very specific: line 49
When .sdd/role contains workspace (case-insensitive, leading/trailing whitespace trimmed), the stop hook exits idle without scanning any …
- Very specific: line 68
After this, Claude Code sessions in home-lab/ will not fire the Ralph stop hook even if spec/active/ contains PRDs with passes: false …
- Very specific: line 84
Create context/impl/backprop-log.json with initial empty structure:
- Very specific: line 93
Create progress.txt if it does not exist, using the template from ${CLAUDE_PLUGIN_ROOT}/templates/progress.txt (includes typed symbol …
- Very specific: line 126
Choice 1 (default — local same-family): Write .sdd/config.json:
- Very specific: line 152
Choice 4 (skip): Do not write .sdd/config.json.
- Distinctive: line 168
Always print the following note as part of the step 7 summary output:
- Distinctive: line 176
All directories exist with CLAUDE.md guides
- Distinctive: line 180
No existing files are overwritten without user confirmation
“Common” is measured: kept by at least 6 in 10 of the 3 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
SDD Init
Bootstrap the Spec-Driven Development directory structure in the current project.
Process
- Check if
context/already exists. If it does, warn the user and ask before overwriting any CLAUDE.md files. - Create the following directories:
context/ ├── refs/ # Reference material (existing docs, research, examples) ├── specs/ # Specifications with acceptance criteria ├── plans/ # Task decomposition and dependency graphs ├── impl/ # Implementation tracking and backpropagation logs └── prompts/ # Phase-specific prompt templates (optional) - Also create
spec/active/if it does not exist (this is where prd.json task files live).
3b. Create the .sdd/ infrastructure directory:
.sdd/
├── session/ # JSONL session logs (gitignored)
├── worktrees/ # Ralph worktree isolation (gitignored)
├── tips/ # Symlink to plugin tips/ or project-local tips
└── role # Optional: role marker (see §3b-role below)§3b-role — .sdd/role marker convention (v1.1.0+)
Some directories contain SDD spec files (spec/active/*.prd.json) for planning or
reference purposes, but are NOT active implementation directories. Without a marker,
the Ralph stop hook would fire on these directories and dispatch stories from a
planning workspace — the opposite of the intended behavior (closes smoke #14).
To suppress Ralph-loop firing in a non-implementation directory, create the file
.sdd/role with the single line workspace:
workspaceWhen .sdd/role contains workspace (case-insensitive, leading/trailing whitespace
trimmed), the stop hook exits idle without scanning any PRDs, regardless of their
contents.
The default role — when the file is absent OR contains implementation — is
implementation: the hook fires normally.
When to set .sdd/role = workspace:
- A directory that holds planning PRDs, spec libraries, or documentation PRDs that are not being actively implemented in the current session.
- Multi-project home directories (e.g.
~/project-roots/home-lab/) where PRDs exist for planning and tracking but implementation happens in child repositories.
Example (home-lab planning workspace):
mkdir -p ~/project-roots/home-lab/.sdd
echo workspace > ~/project-roots/home-lab/.sdd/roleAfter this, Claude Code sessions in home-lab/ will not fire the Ralph stop hook
even if spec/active/ contains PRDs with passes: false stories.
Commit the marker: .sdd/role is safe to commit. It contains no credentials or
session state. Add .sdd/session/ and .sdd/worktrees/ to .gitignore (step 3d)
but NOT .sdd/role itself.
3c. Create context/decisions/ for Architecture Decision Records.
3d. Add .sdd/session/ and .sdd/worktrees/ to .gitignore if not already present.
- Copy CLAUDE.md convention guides into each context subdirectory from the plugin templates:
context/specs/CLAUDE.mdfrom${CLAUDE_PLUGIN_ROOT}/templates/context/specs-CLAUDE.mdcontext/plans/CLAUDE.mdfrom${CLAUDE_PLUGIN_ROOT}/templates/context/plans-CLAUDE.mdcontext/impl/CLAUDE.mdfrom${CLAUDE_PLUGIN_ROOT}/templates/context/impl-CLAUDE.md
Create
context/impl/backprop-log.jsonwith initial empty structure:{ "entries": [] }The root key is
entries(canonical as of v1.0.0). Older projects may have logs with the priorbackpropagation_logroot key — readers in this plugin accept both during the migration window, andscripts/migrate-backprop-log.shrewrites old-shape logs in place.- Create
progress.txtif it does not exist, using the template from${CLAUDE_PLUGIN_ROOT}/templates/progress.txt(includes typed symbol conventions).
6b. Copy constitution.md from ${CLAUDE_PLUGIN_ROOT}/constitution.md into the project root (or spec/constitution.md) if not present. This provides SDD governance rules.
6c. Provider config prompt. Ask the operator how to configure provider routing for this project. Display the following prompt verbatim and read a single character (default 1 on empty input):
Configure provider routing for this project? sdd-init will write
.sdd/config.json based on your choice.
[1] Default: local same-family
Worker: local. Architect-tier: local. same_family_warning=true.
Local-by-default; cross-family wiring audits will be flagged
per spec-plugin-v1.md §2.4.
[2] Cross-family: local worker + hosted Anthropic architect-tier
Worker: local. Architect-tier: anthropic-hosted.
same_family_warning=false. Recommended for projects with
opaque-external interface work.
[3] Custom: pick worker and architect-tier individually
(advanced — operator picks each from the supported list:
worker ∈ {local}, architect_tier ∈ {local, anthropic-hosted}).
[4] Skip (config not written)
Project will run without provider config; sdd_resolve_provider
returns 'no_config' until config is added.
Choice [default 1]:Branch on the operator's response. The target file is .sdd/config.json (relative to project root, alongside the rest of the .sdd/ infrastructure created in step 3b). The matching JSON Schema is written to .sdd/config.schema.json so editors and validators can reference it.
- Choice 1 (default — local same-family). Write
.sdd/config.json:{ "version": 1, "worker": { "provider": "local" }, "architect_tier": { "provider": "local" }, "same_family_warning": true } - Choice 2 (cross-family — local worker + hosted Anthropic architect). Write
.sdd/config.json:{ "version": 1, "worker": { "provider": "local" }, "architect_tier": { "provider": "anthropic-hosted" }, "same_family_warning": false } Choice 3 (custom). Prompt twice — once for
worker.providerand once forarchitect_tier.provider. Validate each response against the supported list before writing; on invalid input, re-prompt for that field. Supported values at v1.0.0:worker.provider ∈ {local}(worker is constrained tolocalat v1.0.0; the prompt is functionally informational, but ask for parity with the schema's structure so future provider expansion does not require re-implementing the prompt).architect_tier.provider ∈ {local, anthropic-hosted}. Provider names are free-form strings that should match keys in.sdd/providers.yamlwhen one exists —localconventionally names your self-hosted inference lane.
Compute
same_family_warningfrom equality of the twoproviderfields:trueifworker.provider == architect_tier.provider, elsefalse. Then write.sdd/config.jsonwith the resolvedversion: 1,worker,architect_tier, andsame_family_warningfields.- Choice 4 (skip). Do not write
.sdd/config.json. Print exactly:Skipped provider config. Run /sdd-init again or hand-edit .sdd/config.json (schema at .sdd/config.schema.json) before running missions.
Notes for the operator:
- The config is project-local and meant to be committed to the repo. It contains no credentials — credential resolution happens elsewhere (keychain / vault).
- The operator may re-run
sdd-initlater to overwrite.sdd/config.json, or hand-edit the file directly per the JSON Schema at.sdd/config.schema.json. - Cross-reference: this is the v1.0.0 acceptance criterion from
decisions-2026-05-08.mdConflict 3 — config must be simple and clean, single file, schema next to it.
- Print a summary of what was created and suggest next steps:
- "Run
/sdd-spec [feature]to create your first specification" - "Run
/sdd-statusto check project state"
- "Run
7b. First-run note (v1.1+): session restart required after plugin upgrade.
Always print the following note as part of the step 7 summary output:
Session restart note: If you just upgraded this plugin via
claude plugins install, the running Claude Code session keeps the old MCP layer until you restart. New behaviors, tools, and schema changes from the upgrade are not active yet. Exit Claude Code and reopen it to bind to the new version. See README's "Session restart required after upgrade" section for details.
This rule applies on every /sdd-init invocation — not only the first run — because the most common reason to re-run /sdd-init in an existing project is to pick up a plugin upgrade. Printing the note unconditionally keeps the rule visible without requiring the skill to detect whether an upgrade actually occurred.
Output contract
- All directories exist with CLAUDE.md guides
context/impl/backprop-log.jsonexists with empty logprogress.txtexists.sdd/config.jsonexists IF operator chose option 1, 2, or 3 (option 4 leaves it absent —sdd_resolve_providerreturnsno_configin that state, which is intentional).- No existing files are overwritten without user confirmation
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.

