.apm/skills/sdd-pipeline/SKILL.md
This skill should be used when the user asks about 'spec-driven development', 'SDD pipeline', 'specky', 'pipeline phases', 'EARS notation', 'requirements engineering', 'model routing', or needs guidance on the 10-phase SDD workflow (Init → Discover → Specify → Clarify → Design → Tasks → Analyze → Implement → Verify → Release). Also trigger on 'spec this', 'plan this feature', 'break into tasks', 'quality gate', 'constitution', or 'spec sync'.
npx skillsauth add paulasilvatech/specky SDD Pipeline GuideInstall 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.
The SDD pipeline consists of 10 sequential phases designed to transform feature requests into production-ready code with comprehensive specification artifacts:
Phase 0: Init — Project initialization, scope definition, stakeholder identification, and initial artifact setup (CONSTITUTION.md).
Phase 1: Discover — Brownfield/greenfield analysis, technology stack discovery, document import, and ecosystem investigation. Produces RESEARCH.md.
Phase 2: Specify — Detailed requirements capture using EARS notation, acceptance criteria definition, and constraint documentation. Produces SPECIFICATION.md.
Phase 3: Clarify — Refinement of ambiguous requirements, stakeholder interviews, discovery questions, and context enrichment. Updates SPECIFICATION.md.
Phase 4: Design — System architecture, data flow diagrams, API contracts, and technical approach documentation. Produces DESIGN.md.
Phase 5: Tasks — Work breakdown structure, task dependencies, story points estimation, and implementation sequencing. Produces TASKS.md.
Phase 6: Analyze — Cross-artifact analysis, quality checklist, compliance checks, and completeness audit. Produces ANALYSIS.md, COMPLIANCE.md.
Phase 7: Implement — Code generation, infrastructure setup, test scaffolding, and quality checklist generation based on specifications.
Phase 8: Verify — Test execution, coverage analysis, phantom completion detection, and spec-code drift verification. Produces VERIFICATION.md.
Phase 9: Release — Release gate execution, documentation generation, PR creation, work item export, and changelog preparation.
EARS (Easy Approach to Requirements Syntax) provides five core patterns plus a complex pattern for unambiguous requirement capture:
Shall — Mandatory requirements. Format: "The system shall [action]."
Should — Desired but not mandatory. Format: "The system should [action]."
May — Optional enhancements. Format: "The system may [action]."
If...Then... — Conditional requirements. Format: "If [condition] then [action]."
When...Then... — Trigger-based requirements. Format: "When [event] then [action]."
Complex — Combination patterns for intricate business logic.
Route specification and implementation tasks to models based on phase complexity:
| Phase | Model | Reasoning | |-------|-------|-----------| | 0 (Init) | Haiku | Basic scope definition, lightweight | | 1 (Discover) | Sonnet | Multi-source synthesis, ecosystem analysis | | 2 (Specify) | Opus | Complex requirement formalization, EARS patterns | | 3 (Clarify) | Opus | Interactive refinement, stakeholder context | | 4 (Design) | Opus | Architecture decisions, multi-component systems | | 5 (Tasks) | Sonnet | Work breakdown, dependency mapping | | 6 (Analyze) | Sonnet | Cross-artifact analysis, compliance checks | | 7 (Implement) | Sonnet | Code scaffolding, quality checklists | | 8 (Verify) | Opus | Coverage analysis, drift detection | | 9 (Release) | Haiku | Final gates, documentation assembly |
Reference: arXiv:2502.08235 — "Extended Thinking and Specification Quality in Large Language Models"
Key finding for Phase 7 (Implementation): Enabling extended thinking (chain-of-thought) reduces quality by 30% while increasing cost by 43% in code generation tasks. Recommendation: Use standard inference for Phase 7 scaffolding; reserve extended thinking for Phase 8 verification.
The pipeline includes 14 automation hooks for customization:
Blocking Hooks (workflow stops if hook fails — exit code 2):
artifact-validator — Pre-tool: blocks if required artifacts missingphase-gate — Post-tool: blocks if output artifact wasn't createdsecurity-scan — Pre-release: blocks if hardcoded secrets detectedrelease-gate — Pre-release: blocks if gate conditions not metAdvisory Hooks (workflow continues; failures logged):
branch-validator — Pre-tool: warns if wrong branch for phasespec-sync — Post-tool: checks spec-code driftauto-checkpoint — Post-tool: suggests checkpoint after artifact changesspec-quality — Post-spec: validates specification qualitytask-tracer — Post-tasks: traces task dependenciesears-validator — Post-spec: validates EARS notation patternslgtm-gate — Post-spec/design/tasks: pauses for human LGTMdrift-monitor — Post-verify/review: monitors specification driftcognitive-debt-alert — Post-analysis: flags cognitive debt metricsmetrics-dashboard — Post-analysis: updates metrics dashboardHooks are configured in sdd-hooks.json with PreToolUse and PostToolUse matchers.
Direct CLI:
/specky:init
/specky:discover
/specky:specify
/specky:clarify
/specky:design
/specky:tasks
/specky:analyze
/specky:implement
/specky:verify
/specky:release
Agent-based:
@specky-sdd-agent init feature-name
@specky-sdd-agent specify --input=RESEARCH.md
@specky-sdd-agent implement --model=sonnet
Use the /specky:check command to validate artifact completeness before advancing phases.
Every spec gets its own branch. Work progresses through environments before reaching production:
spec/001-user-auth ──→ develop ──→ stage ──→ main
spec/002-payments ──→ ↑
spec/003-notifs ──→ ↑
| Branch | Phases | Artifacts Created | When to Merge |
|--------|--------|-------------------|---------------|
| spec/NNN-feature-name | 0-7 | CONSTITUTION.md, .sdd-state.json, RESEARCH.md, SPECIFICATION.md, DESIGN.md, TASKS.md, CHECKLIST.md, VERIFICATION.md, CROSS_ANALYSIS.md | After Phase 7 passes |
| develop | 8 (Verify) | ANALYSIS.md, COMPLIANCE.md | After integration review |
| stage | 8-9 (QA + Gates) | Release docs, changelog | After blocking gates pass |
| main | Production | — | Protected; deploy-ready |
spec/NNN-feature-namedevelop, never from main.specs/ artifacts are created on the spec branch (Phases 0-7)develop only after Phase 8 (verify) passesstage only after integration review on developmain only after blocking gates pass on stageStarting a new spec:
git checkout develop
git pull origin develop
git checkout -b spec/001-user-authentication
# Run @sdd-init / /specky-greenfield
After Phase 7 passes:
git checkout develop
git merge --no-ff spec/001-user-authentication
git branch -d spec/001-user-authentication
git push origin develop
Promoting to stage:
git checkout stage
git merge --no-ff develop
git push origin stage
# Run @release-engineer for blocking gates
Releasing to production:
git checkout main
git merge --no-ff stage
git tag -a v1.0.0 -m "Release v1.0.0"
git push origin main --tags
| Phase | Tools |
|-------|-------|
| 0 Init | sdd_init, sdd_scan_codebase, sdd_create_branch |
| 1 Discover | sdd_discover, sdd_research, sdd_import_document, sdd_import_transcript, sdd_batch_import, sdd_check_ecosystem |
| 2 Specify | sdd_write_spec, sdd_turnkey_spec, sdd_validate_ears, sdd_figma_to_spec |
| 3 Clarify | sdd_clarify, sdd_validate_ears, sdd_turnkey_spec |
| 4 Design | sdd_write_design, sdd_generate_all_diagrams, sdd_generate_diagram |
| 5 Tasks | sdd_write_tasks, sdd_checklist |
| 6 Analyze | sdd_run_analysis, sdd_cross_analyze, sdd_compliance_check, sdd_check_sync |
| 7 Implement | sdd_implement, sdd_generate_tests, sdd_generate_pbt, sdd_generate_iac, sdd_generate_dockerfile, sdd_generate_devcontainer |
| 8 Verify | sdd_verify_tests, sdd_verify_tasks, sdd_check_sync, sdd_validate_ears |
| 9 Release | sdd_create_pr, sdd_generate_all_docs, sdd_export_work_items |
| Any | sdd_get_status, sdd_advance_phase, sdd_checkpoint, sdd_restore, sdd_metrics, sdd_model_routing |
| Phase | Agent | Model | |-------|-------|-------| | Pre | @specky-onboarding | Haiku | | All | @specky-orchestrator | Sonnet | | 0 | @sdd-init | Haiku | | 1 | @research-analyst | Sonnet | | 2 | @spec-engineer | Opus | | 3 | @sdd-clarify | Opus | | 4 | @design-architect | Opus | | 5 | @task-planner | Sonnet | | 6 | @quality-reviewer | Sonnet | | 7 | @implementer | Sonnet | | 8 | @test-verifier | Opus | | 9 | @release-engineer | Haiku |
testing
This skill should be used when the user asks to 'verify tests', 'check coverage', 'detect phantom completions', 'check spec drift', or needs guidance on Phase 8 verification. Also trigger on 'sdd test', 'test traceability', 'verification report', or 'gate criteria'.
devops
This skill should be used when the user asks to 'orchestrate pipeline', 'run full pipeline', 'coordinate phases', 'advance phase', or needs guidance on end-to-end pipeline execution. Also trigger on 'specky orchestrate', 'phase transition', 'LGTM gate', 'pipeline status', or 'which agent for this phase'.
tools
This skill should be used when the user asks 'help me with specky', 'what is specky', 'how to use specky', 'specky onboarding', 'get started', or needs guidance on project setup, work modes, or available agents/tools/prompts. Also trigger on '@specky', 'specky help', or 'show me specky commands'.
development
This skill should be used when generating or formatting SDD artifacts (CONSTITUTION.md, SPECIFICATION.md, DESIGN.md, TASKS.md, VERIFICATION.md, ANALYSIS.md). Also trigger on 'sdd markdown', 'artifact format', or 'spec formatting'.