agentleFS
teltringhamteltringham/sdd-plugin/skills/sdd-plan/SKILL.md

sdd-plan

Skill0 starsChanged 8 months agoMITView on GitHub

Decomposes a specification into a vertically-sliced task DAG and generates both a human-readable plan and a machine-readable prd.json for the Ralph iterate loop. Use after /sdd-spec to create implementable tasks from a specification.

2 other projects use a version of this.

Adopted by

Most recently taken up by

  • Other versions2 projects use a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 2

    1. felipefontoura/pi-sdd-kit★ 34same name
    2. sivaprasadreddy/sdd-skills★ 32same 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.

The file

Show its rules and text

We split this skill into the rules it gives an agent

37 rules. About 0 are common, 12 are distinctive, and 25 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈12

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 25

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Use --auto when invoking from Mission Runner, CI, or any non-interactive context.

    line 30
  2. Very specific:

    If $ARGUMENTS is a file path, read it directly

    line 36
  3. Very specific:

    If $ARGUMENTS is a slug (e.g., "auth"), look for context/specs/spec-{slug}.md

    line 37
  4. Very specific:

    If $ARGUMENTS is empty, find the most recently modified file in context/specs/

    line 38
  5. Very specific:

    If no spec found, suggest running /sdd-spec first

    line 39
  6. Distinctive:

    Read the full spec file

    line 43
  7. Very specific:

    Verify it has traceability IDs (SPEC-{slug}-NNN)

    line 44
  8. Very specific:

    Verify it has acceptance criteria (Given/When/Then)

    line 45
  9. Distinctive:

    If the spec has unresolved open questions, warn the user and ask whether to proceed

    line 46
  10. Distinctive:

    Interactive mode (default): treat the PRD as a tagless legacy spec (Conflict 2 grandfathered) — defaults to hardening behavior, with an …

    line 48
  11. Distinctive:

    Read CLAUDE.md or AGENTS.md if they exist (for quality gate commands, coding standards, git conventions)

    line 53
  12. Very specific:

    Check if templates/quality-gates.yml exists (for deterministic gate definitions)

    line 54
  13. Very specific:

    Read any existing plans in context/plans/ to understand the current task landscape

    line 55
  14. Distinctive:

    Every spec requirement must be covered by at least one story

    line 76
  15. Distinctive:

    No story should cover more than 3 spec requirements (split if bigger)

    line 77
  16. Very specific:

    Apply characterization routing: When the spec is opaque-external, or a single story explicitly involves an opaque interface, tag the story …

    line 82
  17. Very specific:

    Use the template at ${CLAUDE_PLUGIN_ROOT}/templates/plan/plan.md.

    line 86
  18. Very specific:

    Writing style: write story descriptions, acceptance criteria, risks, and implementer notes in STE-100 controlled language per …

    line 92
  19. Very specific:

    Before writing the PRD, decide whether the implementer needs to cd into a sibling code repo.

    line 98
  20. Distinctive:

    Interactive (default): follow steps a–d below.

    line 101
  21. Very specific:

    Write the user-confirmed absolute path into the PRD's top-level repoRoot field.

    line 109
  22. Very specific:

    Do NOT set repoRoot — a single PRD cannot target two repos cleanly.

    line 117
  23. Very specific:

    Create a JSON file validated against ${CLAUDE_PLUGIN_ROOT}/templates/task/prd.json.schema.json:

    line 122
  24. Distinctive:

    After generating both files, verify:

    line 162
  25. Very specific:

    Every SPEC-{slug}-NNN requirement in the spec is referenced by at least one story's specRequirements

    line 163
  26. Distinctive:

    No story references a requirement ID that doesn't exist in the spec

    line 164
  27. Distinctive:

    After the story DAG is drafted but BEFORE the plan is finalized, author the outcome-assertion corpus and run the coverage gate.

    line 169
  28. Distinctive:

    If there are dependency chains, note which stories can run in parallel

    line 206
  29. Very specific:

    When the spec is classified opaque-external (or any single story explicitly targets an opaque interface in a documented-external spec), the …

    line 222
  30. Very specific:

    Populate the expected_outputs skeleton: Default skeleton — leave the skeleton in place during automated planning and ask the operator to …

    line 228
  31. Very specific:

    When /sdd-plan is invoked on a PRD whose parent spec lacks interface_maturity AND the operator declares a new story whose interface is …

    line 255
  32. Very specific:

    If the parent PRD has interface_maturity set, this operator prompt does NOT fire — the spec-time classification is authoritative.

    line 265
  33. Very specific:

    When invoked with --auto, write a JSON sidecar to:

    line 269
  34. Very specific:

    Create parent directories as needed.

    line 275
  35. Very specific:

    If coverage_status is incomplete or halts is non-empty, the Mission Runner surfaces the gap to the operator instead of advancing to …

    line 316
  36. Very specific:

    All stories have passes: false, attempts: 0

    line 323
  37. Distinctive:

    Every spec requirement is covered by at least one story

    line 324

≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill 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.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

SDD Plan

Decompose a specification into vertical task slices with a machine-readable prd.json.

Arguments

$ARGUMENTS — path to spec file, spec slug, or omit to auto-detect the most recent spec in context/specs/.

--auto — optional flag. Replaces every interactive prompt in this skill (repoRoot resolution, characterization tagging per story, coverage-gate halt) with fail-fast behavior and a structured JSON sidecar that the Mission Runner can consume. Default: omitted (human-driven). See "Modes" below.

--repo-root <abs-path> — required when --auto is used. The absolute path the §6 interactive prompt would otherwise ask for. Ignored in interactive mode.

Modes

This skill runs in two modes that share §1–§9 (locate spec, decompose, generate plan + prd.json, coverage gate, traceability cross-check) and diverge at every operator-prompting branch:

  • Interactive (default) — §6 asks the operator to confirm repoRoot, §2.6/C asks per opaque-external story whether to tag characterization, §8.5/C halts and waits for the operator to fix coverage gaps. Human-driven; preserves the v1.x flow.
  • Autonomous (--auto) — every prompt is replaced with fail-fast behavior:
    • §6 repoRoot resolution: read from --repo-root <abs-path>. If absent, exit non-zero with Error: --auto requires --repo-root <abs-path>. The interactive operator-confirmation step is disabled in autonomous mode.
    • §2 interface_maturity read: take the value directly from spec frontmatter. If absent, exit non-zero with Error: --auto requires the parent spec to declare interface_maturity in frontmatter (controlled-internal | documented-external | opaque-external). The Conflict-2 grandfather prompt is disabled in autonomous mode.
    • §2.6/C characterization-tagging prompt: skipped entirely. Every story is tagged characterization: "untagged" with a structured summary in the sidecar listing the untagged story IDs. The operator (or downstream /sdd-iterate) backfills.
    • §8.5/C coverage gate: on status == "incomplete", do NOT halt for operator input. Exit non-zero with structured JSON in the sidecar listing uncovered_assertions, orphan_stories, and bidirectional_drift.
    • JSON sidecar emitted at <repoRoot>/.sdd/plan-runs/<spec-slug>/plan-<ts>.json (see §10 below for shape) where <ts> is a UTC ISO-8601 timestamp safe for filenames (YYYYMMDDTHHMMSSZ).

Use --auto when invoking from Mission Runner, CI, or any non-interactive context. Default behavior is unchanged for human-driven /sdd-plan.

Process

1. Locate the spec

  • If $ARGUMENTS is a file path, read it directly
  • If $ARGUMENTS is a slug (e.g., "auth"), look for context/specs/spec-{slug}.md
  • If $ARGUMENTS is empty, find the most recently modified file in context/specs/
  • If no spec found, suggest running /sdd-spec first

2. Read and validate the spec

  • Read the full spec file
  • Verify it has traceability IDs (SPEC-{slug}-NNN)
  • Verify it has acceptance criteria (Given/When/Then)
  • If the spec has unresolved open questions, warn the user and ask whether to proceed
  • Read the interface_maturity classification. Look in the spec's metadata block at the top of the file (alongside **Spec ID:**, **Author:**, etc.) for a line of the form **interface_maturity:** controlled-internal | documented-external | opaque-external. This field is written by /sdd-spec (§2.5) and drives the characterization-routing rules in the §2.6 — Characterization routing section below. If the field is absent, behavior diverges by mode:
    • Interactive mode (default): treat the PRD as a tagless legacy spec (Conflict 2 grandfathered) — defaults to hardening behavior, with an operator prompt fired only when a new story declared by the operator targets an opaque-external interface.
    • Autonomous mode (--auto): exit non-zero with Error: --auto requires the parent spec to declare interface_maturity in frontmatter. The Conflict-2 grandfather prompt is disabled in autonomous mode. Record the failure in the sidecar's halts array.

3. Identify the project context

  • Read CLAUDE.md or AGENTS.md if they exist (for quality gate commands, coding standards, git conventions)
  • Check if templates/quality-gates.yml exists (for deterministic gate definitions)
  • Read any existing plans in context/plans/ to understand the current task landscape

4. Decompose into vertical slices

Each story must deliver testable end-to-end functionality. Slice vertically, not horizontally:

  • BAD: "Set up database schema" -> "Write API endpoints" -> "Add frontend"
  • GOOD: "User can register with email" -> "User can log in" -> "User can reset password"

For each story, define:

  • ID: STORY-{N} (sequential, starting at 1)
  • Title: Short, action-oriented (starts with a verb or "User can...")
  • Priority: Execution order (1 = first). Dependencies must have lower priority numbers.
  • Category: deep (complex logic), quick (straightforward), test (test-only), research (needs investigation), review (evaluation), visual (UI/multimodal)
  • Spec requirements: Which SPEC-{slug}-NNN IDs this story implements (traceability)
  • Acceptance criteria: Machine-checkable conditions (subset of the spec's criteria)
  • Complexity budget: maxFiles (default 5), maxLOCDiff (default 200)
  • Dependencies: Which other STORY IDs must complete first
  • bindingGate: Which verification gate applies to this story's acceptance criteria. Auto-detect first (no operator prompt needed): inspect the spec's user stories and the story's uxAcceptanceCriteria. If the spec has any UI-bearing user stories (stories whose persona/goal explicitly involves a visible user interface, screen, form, or interactive element) OR the story has any uxAcceptanceCriteria, set bindingGate=mixed automatically. For specs without UI-bearing stories and no uxAcceptanceCriteria, set bindingGate=code automatically without operator input. Only prompt the operator when the inference is ambiguous (e.g., the story accesses a UI library but no user-visible surface is described). Semantics: code = TDD pipeline + sdd-evaluator only (pure-code stories, default for non-UI specs); ux = sdd-ux-validate only (UX assertions without a TDD path); mixed = both gates required to pass before the story closes (UI-bearing specs default to this). Stories without a bindingGate default to code for backward compatibility.

Rules:

  • Every spec requirement must be covered by at least one story
  • No story should cover more than 3 spec requirements (split if bigger)
  • First story should be the simplest possible end-to-end slice (proves the architecture works)
  • Last story should be integration/smoke tests that validate the whole feature
  • Aim for 3-8 stories. If you have more than 12, the spec is too broad.
  • maxAttempts defaults to 3. Set to 5 for deep category stories.
  • Apply characterization routing. When the spec is opaque-external, or a single story explicitly involves an opaque interface, tag the story per §2.6 — tags, expected_outputs, budget. Characterization stories run before the implementation stories that depend on their output.

5. Generate the human-readable plan

Use the template at ${CLAUDE_PLUGIN_ROOT}/templates/plan/plan.md. Include:

  • Task dependency graph (text-based or mermaid)
  • Full story details
  • Risk assessment
  • Notes for the implementer

Writing style: write story descriptions, acceptance criteria, risks, and implementer notes in STE-100 controlled language per ${CLAUDE_PLUGIN_ROOT}/rules/ste100-writing.md — one instruction per sentence, active voice, one term per concept. Acceptance criteria stay machine-checkable.

Save to context/plans/plan-{slug}.md.

6. Resolve repoRoot (sibling-repo target detection)

Before writing the PRD, decide whether the implementer needs to cd into a sibling code repo. See context/decisions/sdd-reporoot-convention-2026-04-22.md for the motivating incident.

Mode split:

  • Interactive (default): follow steps a–d below.
  • Autonomous (--auto): read the absolute path from --repo-root <abs-path> and write it directly to the PRD's repoRoot field. Skip the heuristic scan and the operator prompt entirely. If --repo-root is absent, exit non-zero with Error: --auto requires --repo-root <abs-path>. The interactive operator-confirmation step is disabled in autonomous mode. and record the failure in the sidecar's halts array. The Mission Runner is responsible for resolving the target repo before invoking /sdd-plan --auto.

a. Scan the plan's intended writes paths for a sibling-repo prefix — a leading path component that is NOT one of the SDD workspace directories (context/, spec/, scripts/, templates/, progress.txt, etc.). Examples that ARE sibling-repo prefixes: web-app/src/..., api-service/scripts/..., mobile-app/app/....

b. If a sibling-repo prefix dominates (i.e., most or all writes start with the same non-workspace prefix <repo>/):

  • Heuristically resolve a default absolute path: search ~/project-roots/<repo> first; fall back to siblings of the current SDD workspace.
  • Prompt the user once with the detected repo and the heuristic default — e.g., Detected target repo: 'constellation'. Absolute path? [/Users/tyler/project-roots/constellation].
  • Write the user-confirmed absolute path into the PRD's top-level repoRoot field.
  • All reads / writes arrays in the user stories are interpreted relative to that repoRoot.

c. If no sibling-repo prefix is detected (all writes target workspace-internal paths like context/impl/..., spec/active/...):

  • Omit repoRoot from the PRD.
  • Emit a note in the skill output: No sibling repo detected; PRD will use invocation CWD.

d. If multiple distinct sibling-repo prefixes appear (e.g., the plan writes to both web-app/src/... and api-service/scripts/...):

  • Do NOT set repoRoot — a single PRD cannot target two repos cleanly.
  • Warn the user and suggest splitting the plan into one PRD per target repo.

7. Generate the machine-readable prd.json

Create a JSON file validated against ${CLAUDE_PLUGIN_ROOT}/templates/task/prd.json.schema.json:

{
  "project": "{project-name}",
  "branchName": "feature/{slug}",
  "description": "{spec title}",
  "specPath": "context/specs/spec-{slug}.md",
  "repoRoot": "/absolute/path/to/target/repo",
  "issueRef": "",
  "userStories": [
    {
      "id": "STORY-1",
      "title": "...",
      "description": "...",
      "acceptanceCriteria": ["criterion 1", "criterion 2"],
      "specRequirements": ["SPEC-{slug}-001", "SPEC-{slug}-002"],
      "reads": ["src/foo/Bar.cs", "tests/foo/BarTests.cs"],
      "writes": ["src/foo/Bar.cs", "tests/foo/BarTests.cs"],
      "priority": 1,
      "category": "deep",
      "complexityBudget": { "maxFiles": 5, "maxLOCDiff": 200 },
      "passes": false,
      "attempts": 0,
      "maxAttempts": 3,
      "backpropagated": false,
      "issueRef": "",
      "branch": "",
      "notes": ""
    }
  ]
}

repoRoot is omitted entirely (not set to "") when the plan targets only the SDD workspace itself. reads / writes are optional but strongly recommended — they narrow the implementer's context and feed the complexity-budget guard.

Save to spec/active/{slug}.prd.json. Create spec/active/ if it does not exist.

8. Cross-check traceability

After generating both files, verify:

  • Every SPEC-{slug}-NNN requirement in the spec is referenced by at least one story's specRequirements
  • No story references a requirement ID that doesn't exist in the spec
  • Report any gaps to the user

8.5 — Outcome-assertion authoring + coverage gate (§2.9 / W10)

After the story DAG is drafted but BEFORE the plan is finalized, author the outcome-assertion corpus and run the coverage gate.

A. Author the corpus. Walk the spec's user stories first, then its requirements. For each user story, ask: "What user-visible outcome would prove this story's goal was achieved?" Then for each spec requirement, trace it up to the user story it serves (Serves: field) and ask: "What outcome-shaped invariant would prove this requirement holds at runtime?" Phrase as user-facing or system-level invariants ("login completes within 200ms", "deletion is recoverable for 24 hours", "validator never advances on a same-family wiring audit"), NOT implementation assertions ("LoginController returns HTTP 200"). The asymmetry is the entire point — outcome-shaped assertions cannot be designed to fit the code, so a passing assertion is evidence about the user-visible system, not about the implementation that happens to live behind it today.

Each assertion entry has the shape:

{
  "id": "ASSERT-NNN",
  "description": "outcome-shaped invariant in plain language",
  "source_spec_ref": "spec-{slug}.md §X.Y",
  "user_story_ref": "As [persona], I want [outcome] — the user story this assertion serves",
  "covered_by": ["STORY-N", ...]
}

user_story_ref records the plain-language user story the assertion serves, restoring the up-chain link (assertion → user story → persona). This makes a "green" test's connection to a human outcome visible. Populate it by tracing the requirement's Serves: field (set by the spec author per A3) up to the user story text. When the assertion is authored from the user story directly (not a requirement), use the full user story Connextra text.

Persist the corpus as a top-level assertions array on the PRD root (sibling to userStories). id is unique within the PRD. source_spec_ref is optional additional traceability.

B. Map stories to assertions. Walk every story; for each, populate assertion_ids with the IDs of every assertion it satisfies. Reciprocally, populate each assertion's covered_by with the story IDs that satisfy it. Both directions must be populated — the predicate tool validates them against each other.

C. Run the coverage gate. Invoke sdd_assertion_coverage_check with the current prd_path. Three branches:

  • status == "complete" — proceed to step 9.
  • status == "incomplete" — behavior diverges by mode:
    • Interactive (default): halt. Print uncovered_assertions, orphan_stories, and bidirectional_drift. Refuse to advance until the operator addresses each issue. Recommended phrasing: "Coverage gate failed: every story must satisfy ≥1 assertion AND every assertion must be covered by ≥1 story. See uncovered/orphan/drift lists below; author or remap before I can finalize the plan."
    • Autonomous (--auto): fail fast. Do NOT halt for operator input. Write the sidecar with coverage_status: "incomplete" and a coverage_gaps object containing the three lists from the predicate (uncovered_assertions, orphan_stories, bidirectional_drift). Exit non-zero. The Mission Runner reads the sidecar to route into a remediation step or surface the gaps to the operator.
  • status == "legacy" (no assertions field — Conflict 2 grandfather, OR new PRD with operator-explicit skip) — emit a warning citing spec-plugin-v1.md §2.9 and the grandfather rule, then continue. New PRDs SHOULD author assertions; legacy PRDs MAY skip until they next iterate.

D. Discipline note for failed assertions during iteration. A failed assertion at runtime is a SPEC issue, not a test/assertion issue. Backpropagation amends the spec and (if the spec amendment changes the outcome contract) the assertion — never the assertion alone to make a passing implementation look right. See sdd-iterate skill for the full backprop discipline.

9. Update progress and suggest next steps

  • Append to progress.txt: [{timestamp}] Created plan: context/plans/plan-{slug}.md — {N} stories
  • Suggest: "Run /sdd-implement to start the Ralph loop"
  • Suggest: "Run ./scripts/ralph.sh for model-agnostic execution"
  • If there are dependency chains, note which stories can run in parallel

§2.6 — Characterization routing (interface-maturity-driven)

This section codifies how /sdd-plan consumes the interface_maturity classification written by /sdd-spec (§2.5) and routes opaque-external work to a characterization story tag with wider budgets and explicit outputs. Per decisions-2026-05-08.md Conflict 2, the rule is operator-facing: existing tagless PRDs are grandfathered, new PRDs require the field, and tagless legacy PRDs trigger an operator prompt at story-add time when the new story is opaque-external.

A. Read interface_maturity at plan start

Step 2 above already reads the field. Three branches at plan time:

  • controlled-internal — fully owned, stable interface. Standard hardening behavior. No tags required. (Default for grandfathered tagless PRDs.)
  • documented-external — third-party with a stable, well-documented contract. Standard hardening behavior. Per-story characterization is permitted if a single story's interface is opaque, but is not the default.
  • opaque-external — third-party or runtime with an unstable or undocumented contract. Characterization-first routing per behavior B below.

B. Route opaque-external work to characterization

When the spec is classified opaque-external (or any single story explicitly targets an opaque interface in a documented-external spec), the story or stories targeting the opaque interface are routed as follows:

  1. Tag the story. Append "characterization" to the story's tags array. (Other tags such as "integration-discovery" may coexist.)

    Autonomous mode (--auto): the per-story characterization-tagging interactive prompts in §2.6/C are skipped. Instead, every story produced in this run is tagged with the literal string "untagged" in a top-level characterization field on the story (i.e., characterization: "untagged"), and the sidecar's characterization_summary.untagged_story_ids array lists every such story. The operator (or downstream /sdd-iterate) backfills the real tag. The §2.6/B behaviors above (expected_outputs skeleton, budget multipliers, DAG ordering) still apply to stories the planner can confidently classify from the spec's interface_maturity field alone — only the per-story prompt in §2.6/C is replaced.

  2. Populate the expected_outputs skeleton. Default skeleton — leave the skeleton in place during automated planning and ask the operator to fill in the specifics during plan review:

    {
      "probes": [],
      "transcript_corpus": null,
      "replay_harness": null,
      "parity_checks": [],
      "discovery_notes": null
    }

    Per-field semantics:

    • probes: descriptions of the probes the story produces (e.g. "AX-snapshot probe of Showdown subprocess protocol headers").
    • transcript_corpus: { path, description } for where captured interaction transcripts will land. Null in the skeleton; populated during plan review.
    • replay_harness: { path, description } for the replay harness this story produces. Null in the skeleton; populated during plan review. (Harness templates themselves are deferred to a follow-up session; §2.6 captures only the path.)
    • parity_checks: production-shape parity checks this story will exercise.
    • discovery_notes: path to discovery notes the story produces.
  3. Set budget multipliers. Set budget.tokens_multiplier: 2.5 and budget.time_multiplier: 2.0. Characterization is explorative, not implementation-bounded — these multipliers apply on top of any absolute caps in complexityBudget. Adjust per story if the operator has cause.
  4. DAG ordering. Characterization stories must precede the implementation stories that depend on their output. Set the implementation story's dependencies to include the characterization story's ID, and set the characterization story's priority lower (i.e., it executes first).

C. Operator prompt for tagless legacy PRDs (Conflict 2 grandfather rule)

Autonomous mode (--auto): this entire section is disabled. The fail-fast on missing interface_maturity in §2 has already exited the run before reaching this point.

When /sdd-plan is invoked on a PRD whose parent spec lacks interface_maturity AND the operator declares a new story whose interface is opaque-external, emit this prompt before generating the story:

This story targets an opaque-external interface. The parent PRD pre-dates the §2.5 interface_maturity field. Should I tag this story characterization and apply characterization defaults (wider budgets, expected_outputs skeleton)? [yes / no / skip-tagging]

  • yes — apply behavior B above to this story.
  • no — proceed under the parent PRD's grandfathered hardening default; do not tag.
  • skip-tagging — same as no, but explicitly records the operator's choice in the story's notes field for traceability (e.g., notes: "Operator declined characterization tag for known-opaque interface — see decisions-2026-05-08.md Conflict 2").

The prompt fires per opaque-external new story, not as a hidden background check. Skipping tagging is an allowed Conflict 2 outcome — the operator owns the call for legacy PRDs.

If the parent PRD has interface_maturity set, this operator prompt does NOT fire — the spec-time classification is authoritative.

§10 — Autonomous-mode JSON sidecar (--auto only)

When invoked with --auto, write a JSON sidecar to:

<repoRoot>/.sdd/plan-runs/<spec-slug>/plan-<ts>.json

Create parent directories as needed. <spec-slug> is taken from the spec filename (spec-<slug>.md → <slug>). <ts> is YYYYMMDDTHHMMSSZ UTC. The sidecar shape:

{
  "schema_version": 1,
  "spec_path": "context/specs/spec-foo.md",
  "prd_path": "spec/active/foo.prd.json",
  "repo_root": "/Users/tyler/project-roots/foo",
  "interface_maturity": "controlled-internal | documented-external | opaque-external",
  "coverage_status": "complete | incomplete | legacy",
  "coverage_gaps": {
    "uncovered_assertions": ["ASSERT-NNN"],
    "orphan_stories": ["STORY-N"],
    "bidirectional_drift": ["explanation string"]
  },
  "characterization_summary": {
    "untagged_story_ids": ["STORY-N"],
    "characterization_story_ids": ["STORY-N"]
  },
  "halts": [
    { "stage": "interface_maturity_read | repo_root_resolution | coverage_gate", "reason": "string" }
  ],
  "timestamp_utc": "2026-05-15T18:42:31Z"
}

coverage_gaps is an empty object when coverage_status == "complete". halts is an empty array on a clean run; populated entries indicate the fail-fast that caused exit. The Mission Runner reads this sidecar to decide next-step routing without parsing markdown.

Worked example for Mission Runner consumers:

# Mission Runner invokes /sdd-plan on a freshly-spec'd feature:
claude --print "/sdd-plan auth --auto --repo-root /Users/tyler/project-roots/auth-service"

# Reads the resulting sidecar, branches on status:
cat /Users/tyler/project-roots/auth-service/.sdd/plan-runs/auth/plan-20260515T184231Z.json \
  | jq -r '.coverage_status, (.characterization_summary.untagged_story_ids | length)'
# complete
# 5

If coverage_status is incomplete or halts is non-empty, the Mission Runner surfaces the gap to the operator instead of advancing to /sdd-implement.

Output contract

  • context/plans/plan-{slug}.md exists with all stories detailed
  • spec/active/{slug}.prd.json exists and validates against the schema
  • repoRoot is set to a confirmed absolute path when the plan targets a sibling repo, or omitted when the plan targets the SDD workspace itself
  • All stories have passes: false, attempts: 0
  • Every spec requirement is covered by at least one story
  • Traceability is bidirectional (spec -> story and story -> spec)
  • progress.txt is updated
  • Stories targeting opaque-external interfaces are tagged characterization per §2.6, with expected_outputs populated (skeleton acceptable) and budget multipliers set
  • Outcome-assertion corpus authored per §2.9 / W10 (top-level assertions array on the PRD), each story carries assertion_ids, and sdd_assertion_coverage_check returns complete (or legacy with grandfather warning emitted)
  • In --auto mode: structured JSON sidecar written to <repoRoot>/.sdd/plan-runs/<spec-slug>/plan-<ts>.json per §10; every interactive prompt (repoRoot, characterization tagging, coverage halt) replaced with fail-fast behavior; missing prerequisites (--repo-root, interface_maturity) exit non-zero with structured halts in the sidecar

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.