skills/spec-driven-development/SKILL.md
Use when implementing features from a spec or requirements document, doing multi-phase work, or when you need structured Analyze-Plan-Ask-Execute-Review cycles to prevent ad-hoc coding and ensure spec-aligned, pattern-consistent implementations
npx skillsauth add tadejpolajnar/spec-driven-development spec-driven-developmentInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Think First, Prompt Second. Enforces a structured 5-phase cycle that prevents vibe coding: Analyze -> Plan -> Ask -> Execute -> Review. Every implementation starts from a spec, respects existing codebase patterns, and delivers small, reviewable, committed phases.
Do NOT use for: single-line fixes, typos, config changes, pure research, or tasks with very specific line-level instructions. If the user asks a direct question or gives a specific fix, respond directly — don't invoke this workflow.
You need a spec — not loose tickets or vague descriptions. Minimum viable spec:
If the user provides a loose request, ask them to clarify into a spec before proceeding.
digraph sdd {
rankdir=TB;
node [shape=box];
Analyze [label="1. Analyze"];
Plan [label="2. Plan"];
Ask [label="3. Ask"];
Execute [label="4. Execute"];
Review [label="5. Review"];
Stop [label="STOP\nwait for approval" shape=doublecircle];
Commit [label="Commit phase" shape=diamond];
MorePhases [label="More phases?" shape=diamond];
NeedsReanalysis [label="Scope changed?" shape=diamond];
NeedsReplan [label="Plan still valid?" shape=diamond];
Analyze -> Plan;
Plan -> Stop;
Stop -> Ask [label="approved"];
Ask -> NeedsReanalysis;
NeedsReanalysis -> Analyze [label="yes — new requirements"];
NeedsReanalysis -> Execute [label="no"];
Execute -> Commit;
Commit -> Review;
Review -> NeedsReplan;
NeedsReplan -> Plan [label="no — replan remaining"];
NeedsReplan -> MorePhases [label="yes"];
MorePhases -> Execute [label="next phase"];
MorePhases -> "Done" [label="all phases complete"];
}
Goal: Understand the spec AND the codebase before touching anything.
Output — Analysis Summary:
### Spec Understanding
[Restated spec + acceptance criteria list]
### Codebase Findings
- Architecture: [overview]
- Conventions: [naming, patterns, structure]
- Tech stack: [frameworks, tools]
### Similar Implementations Found
- [file:line] — [what it does, relevance]
### Integration Points
- [module/file] — [how the feature connects]
### Risks & Concerns
- [risk] — [severity, mitigation]
### Open Questions
- [questions needing clarification]
Rules:
Goal: Break work into small, ordered, committable phases.
Keep the plan concise. One-line scope per phase. No prose.
Output — Implementation Plan:
### Overview
[1-2 sentence summary. Total phases: N]
### Phase 1: [Short Title]
- Scope: [one sentence]
- Files: modify [path], create [path]
- Pattern: [path:line] — [follow this for...]
- Tests: [what to test]
- Commit: `feat(scope): description (phase 1/N)`
### Phase 2: [Short Title]
...
### Dependencies
- Phase 2 depends on Phase 1
- Phases 3-4 can run in parallel
Rules:
STOP and wait for user approval before executing.
No special process — this is a natural conversation pause.
Surface:
Rule: Never assume. If uncertain, ask. If nothing is ambiguous, state "No open questions" and proceed.
Loop-back rule: If the user's answers reveal new requirements or significantly change scope, go back to Phase 1 — Analyze to re-assess the codebase with the new context. If answers only affect the plan (not the analysis), go back to Phase 2 — Plan to adjust.
Goal: Implement one phase at a time, following existing patterns.
feat(<scope>): <description> (phase N/M)Rules:
Goal: Verify the phase against spec acceptance criteria.
Output — Phase Review:
### Status: PASS | ISSUES FOUND
### Spec Compliance
- [criterion]: PASS/FAIL — [details]
### Issues (if any)
1. [severity]: [description] — [file:line] — [fix]
### Scope: [OK | drift details]
### Recommendation: PROCEED | FIX [list]
Rules:
Loop-back rule: If review reveals architectural issues or plan assumptions that were wrong, go back to Phase 2 — Plan to re-plan the remaining phases. Don't force a broken plan — adjust it.
Multi-agent review (on request): If the user asks for thorough review, assess from three perspectives sequentially — architecture (patterns, separation of concerns, API design), code quality (bugs, edge cases, test coverage), and security (auth, input validation, injection, OWASP top 10). Synthesize into a single report.
| Anti-Pattern | Prevention | |---|---| | Vibe coding | Mandatory Analyze + Plan before any code | | Over-scoping | Phase boundaries enforce <200 lines, minimal changes | | Pattern violations | Analyzer searches for existing patterns first | | Reinventing the wheel | Analyzer finds similar implementations to reuse | | Big-bang commits | Phase-by-phase commits enforced | | Spec drift | Reviewer checks against spec acceptance criteria | | Assuming requirements | Ask phase surfaces ambiguities before coding |
| Symptom | Cause | Fix | |---|---|---| | Doesn't match spec | Rushed Phase 1 | Redo analysis, restate spec | | Inconsistent patterns | Skipped pattern search | Run analysis again | | Too many files changed | Phases too large | Re-split into smaller phases | | User surprised by approach | Skipped approval | Always stop for plan review | | Major issues in review | Phase scope too large | Smaller phases |
development
Maintainer-only workflow for handling GitHub Secret Scanning alerts on OpenClaw. Use when Codex needs to triage, redact, clean up, and resolve secret leakage found in issue comments, issue bodies, PR comments, or other GitHub content.
development
Maintainer workflow for OpenClaw releases, prereleases, changelog release notes, and publish validation. Use when Codex needs to prepare or verify stable or beta release steps, align version naming, assemble release notes, check release auth requirements, or validate publish-time commands and artifacts.
development
Run, watch, debug, and extend OpenClaw QA testing with qa-lab and qa-channel. Use when Codex needs to execute the repo-backed QA suite, inspect live QA artifacts, debug failing scenarios, add new QA scenarios, or explain the OpenClaw QA workflow. Prefer the live OpenAI lane with regular openai/gpt-5.4 in fast mode; do not use gpt-5.4-pro or gpt-5.4-mini unless the user explicitly overrides that policy.
development
End-to-end Parallels smoke, upgrade, and rerun workflow for OpenClaw across macOS, Windows, and Linux guests. Use when Codex needs to run, rerun, debug, or interpret VM-based install, onboarding, gateway smoke tests, latest-release-to-main upgrade checks, fresh snapshot retests, or optional Discord roundtrip verification under Parallels.