Guided problem → design → plan documentation workflow for a new feature
How this command is triggered — by the user, by Claude, or both
Slash command
/doc-driven-development:start-feature Optional feature slug (e.g. user-auth, billing-export)The summary Claude sees in its command listing — used to decide when to auto-load this command
Four-phase state machine: PROBLEM → DESIGN (optional) → PLAN → DONE. Each phase produces a fully-populated doc. No `<placeholder>` text is left for the user to fill in. --- ## Setup Before entering any phase: **1. Get the feature slug.** Check if an argument was passed (e.g., `/start-feature my-feature`). If yes, use it. If not, ask: "What's the feature slug? Use kebab-case — e.g. `user-auth`, `billing-export`." **2. Detect doc convention** by reading the project's `CLAUDE.md` with the Read tool: - Mentions `feature-work/` → doc root is `feature-work/` - Otherwise → doc root is `docs...
Four-phase state machine: PROBLEM → DESIGN (optional) → PLAN → DONE. Each phase produces a
fully-populated doc. No <placeholder> text is left for the user to fill in.
Before entering any phase:
1. Get the feature slug.
Check if an argument was passed (e.g., /start-feature my-feature). If yes, use it. If not,
ask: "What's the feature slug? Use kebab-case — e.g. user-auth, billing-export."
2. Detect doc convention by reading the project's CLAUDE.md with the Read tool:
feature-work/ → doc root is feature-work/docs/Announce: Writing docs to <doc-root>/<slug>/
Create the directory:
mkdir -p <doc-root>/<slug>
3. Get metadata:
date +%Y-%m-%d # today
git config user.name # owner
4. Read the three pipeline templates:
${CLAUDE_PLUGIN_ROOT}/skills/start-feature/templates/problem.md${CLAUDE_PLUGIN_ROOT}/skills/start-feature/templates/design.md${CLAUDE_PLUGIN_ROOT}/skills/start-feature/templates/plan.mdAnnounce: [PHASE: PROBLEM]
Ask these questions one at a time. Wait for the complete answer before asking the next.
After collecting answers, read any related existing files (feature docs, source modules) to ground the draft in real project context.
Draft problem.md from the template. Fill every section. Replace <username> with the git
owner, YYYY-MM-DD with today's date, and feature name throughout.
Present the draft. Ask: "Does this problem.md look right? Any changes?"
Revise until approved. Write to <doc-root>/<slug>/problem.md.
Transition question:
"Is this feature complex enough to warrant a design doc, or is the approach already obvious? (Trivial → we skip straight to the plan.)"
Announce: [PHASE: DESIGN]
Read relevant project files — existing modules, patterns, anything the feature will touch — to ground the design in real context before proposing approaches.
Propose 2–3 approaches. For each:
Ask: "Which approach would you like to go with?"
Then ask, one at a time:
Draft design.md from the template. The Alternatives considered section must include every
approach proposed above plus the chosen one with rationale. Set problem: ./problem.md in
frontmatter.
Present the draft. Ask: "Does this design.md look right? Any changes?"
Revise until approved. Write to <doc-root>/<slug>/design.md.
Announce: [PHASE: PLAN]
Draft plan.md from the template. The plan must contain:
Set frontmatter to design: ./design.md (or design: ./problem.md if design was skipped).
Present the draft. Ask: "Does this plan.md look right? Any changes?"
Revise until approved. Write to <doc-root>/<slug>/plan.md.
Announce: [PHASE: DONE]
git add <doc-root>/<slug>/
git commit -m "docs(<slug>): add problem/design/plan"
Print summary:
✓ <doc-root>/<slug>/problem.md
✓ <doc-root>/<slug>/design.md (or "— skipped (trivial feature)")
✓ <doc-root>/<slug>/plan.md
Committed: docs(<slug>): add problem/design/plan
deferred.md — write when a planned item is intentionally skipped during implementation. Document what was skipped and the specific reason. Review at project close.
Read from: ${CLAUDE_PLUGIN_ROOT}/skills/start-feature/templates/deferred.md
completed.md — write when the feature ships. The handoff manifest: new modules, dependencies, interface changes, follow-ups.
Read from: ${CLAUDE_PLUGIN_ROOT}/skills/start-feature/templates/completed.md
Archiving: once completed.md is written, move <doc-root>/<slug>/ to
<doc-root>/archived/<slug>/ so the doc root reflects only current in-progress work.
npx claudepluginhub brent-hoover/caderon-pack --plugin doc-driven-development