A skill-first spec-driven development workflow for collaborating with AI agents to deliver reliable outcomes.
This repository provides a primary agent skill plus structured prompt files that guide AI assistants through a complete software development workflow:
- Define intent: generate a reviewed spec with clear demo criteria
- Plan: break work into demoable tasks and subtasks, then run a planning audit gate
- Execute: implement with checkpoints and proof artifacts
- Validate: verify implementation against the spec with evidence
Think of the skill and the prompt files that power it as reusable playbooks that keep AI agents focused and consistent across long conversations.
- TLDR / Quickstart
- Details for the 4-step workflow
- Artifacts and directory layout
- Documentation
- Context verification markers
- Security best practices
- Contributing
- References
- License
Install skill/ when your AI assistant supports skill folders or skill-native workflows. This is the primary recommended path because the single sdd skill can reassess repository state, load the right phase reference, and continue from persisted artifacts without making users remember four separate phase commands.
Install the SDD skill using the skills.sh CLI:
# List available skills in this repository without installing
npx skills add liatrio-labs/spec-driven-workflow --list
# Install the SDD skill
npx skills add liatrio-labs/spec-driven-workflow --skill sdd
# Install the SDD skill non-interactively
npx skills add liatrio-labs/spec-driven-workflow --skill sdd --yes
# Install to specific agents
npx skills add liatrio-labs/spec-driven-workflow --skill sdd -a cursor -a codex
# Install globally instead of project scope
npx skills add liatrio-labs/spec-driven-workflow --skill sdd --globalThe SDD skill is explicit-invocation only: users should intentionally invoke it through their agent harness, such as /sdd or $sdd. It is not designed to be dynamically loaded or automatically triggered by the agent. Once explicitly invoked, the skill router reassesses the workspace, loads the correct SDD phase reference, and continues from persisted artifacts in docs/specs/.
Compatibility notes:
- Agent support for skills and allowed tools varies by agent harness.
- Use
DISABLE_TELEMETRY=1orDO_NOT_TRACK=1to opt out of telemetry when running theskills.shCLI.
Use prompts/ as slash commands when your assistant does not support skills or when your team specifically wants separate phase commands. Install these prompts as native /slash-commands in your AI assistant (Cursor, Windsurf, Claude Code, etc.) using the slash-command-manager utility:
Prerequisite: uvx comes from uv. Install uv first if you donβt already have it:
- (Mac):
brew install uv - (Windows):
winget install astral-sh.uv
uvx --from git+https://github.com/liatrio-labs/slash-command-manager \
slash-man generate \
--github-repo liatrio-labs/spec-driven-workflow \
--github-branch main \
--github-path prompts/uvx --from git+https://github.com/liatrio-labs/slash-command-manager `
slash-man generate `
--github-repo liatrio-labs/spec-driven-workflow `
--github-branch main `
--github-path prompts/What this command does:
uvxruns a Python tool without installing it globally (likenpxfor Python)- Fetches the
slash-command-managertool from GitHub - Auto-detects your installed AI assistants from the list of supported tools
- Downloads the prompt files for each supported tool from the
prompts/directory - Installs them as slash commands for each supported tool
Result: you can now type /SDD-1-generate-spec in your AI assistant to start the prompt-command workflow.
Where to use the slash commands: in AI chat UIs (e.g., Windsurf, Claude Code) type / in the chat input. Some AI assistants require being in "Agent" or "Code" mode for slash commands to appear.
Copy the contents of a prompt file directly from prompts/ and paste it into your AI chat. The AI will follow the structured instructions in the prompt.
For the recommended skill install, explicitly invoke the skill via your agent harness, usually /sdd. In Codex, use $sdd. You can supply a feature/idea/task along with the invocation, or invoke the skill without extra detail and let its internal router detect the appropriate SDD phase from persisted artifacts. Here are some example invocations:
/sdd review issue #123 and start creating a spec for it/sdd generate tasks for the latest spec/sdd run a validation for the latest spec
Or just invoke the skill with /sdd and let the skill guide you through the appropriate phase based on the repo context.
For slash-command installs, invoke each step individually:
- Run
/SDD-1-generate-specand describe the feature you want. If the AI determines material clarification is needed, answer the generated questions file before continuing. - Next, use
/SDD-2-generate-task-list-from-specpointing it at the generated spec; complete task generation, baseline planning commit, planning audit, and user-approved remediation if needed. - Then execute
/SDD-3-manage-tasksto implement tasks one at a time (creating proof artifacts before commits) after the SDD-2 audit required gates pass. - Finally, apply
/SDD-4-validate-spec-implementationto verify the implementation against the spec.
Each phase is available through the recommended sdd skill router and, for slash-command installs, through an equivalent prompt file. The workflow produces specific artifacts in docs/specs/.
-
Generate a spec (
prompts/SDD-1-generate-spec.md)- What it does: checks scope, researches current best practices for relevant technologies, determines whether clarification is needed, optionally creates a questions file for material ambiguities with recommended answers and justification notes, and writes a junior-friendly spec with demo criteria
- Output:
docs/specs/[NN]-spec-[feature-name]/[NN]-spec-[feature-name].mdand, when needed,docs/specs/[NN]-spec-[feature-name]/[NN]-questions-[N]-[feature-name].md - Why: aligns humans + AI on what to build before any code changes
-
Generate a task list (
prompts/SDD-2-generate-task-list-from-spec.md)- What it does: converts the spec into parent tasks (demoable units) + detailed subtasks, creates a baseline planning commit, runs a planning audit gate, and requires user-approved remediation before implementation handoff
- Output:
docs/specs/[NN]-spec-[feature-name]/[NN]-tasks-[feature-name].mdanddocs/specs/[NN]-spec-[feature-name]/[NN]-audit-[feature-name].md - Why: catches planning defects early and improves downstream validation readiness
-
Manage tasks (implementation loop) (
prompts/SDD-3-manage-tasks.md)- What it does: guides execution with checkpoints, verification checklists, and proof artifacts created before each commit
- Output:
docs/specs/[NN]-spec-[feature-name]/[NN]-proofs/[NN]-task-[TT]-proofs.md - Why: keeps work single-threaded, demoable, and evidence-driven
-
Validate implementation (
prompts/SDD-4-validate-spec-implementation.md)- What it does: validates implementation vs spec using proof artifacts, applies validation gates, produces a coverage matrix
- Output: validation report (markdown) showing verified/missing items
- Why: confirms completeness before shipping
-
SHIP IT π’π¨
- Skill-first workflow: Use the
sddskill to route from idea β spec β task list β implementation-ready backlog, with prompt files available for assistants that need slash/custom prompts. - Planning quality gate: SDD-2 includes a mandatory audit with human-approved remediation before implementation starts.
- Predictable delivery: Every step emphasizes demoable slices, proof artifacts, and collaboration with junior developers in mind.
- Flexible install paths: Install the skill for skill-native agents first; use prompt files when slash/custom prompt support is the better fit.
- Context verification: Built-in emoji markers (SDD1οΈβ£-SDD4οΈβ£) detect when AI responses follow critical instructions, helping identify context rot issues early.
Spec-Driven Development (SDD) keeps AI collaborators and human developers aligned around a shared source of truth. This repository provides a lightweight, skill-first workflow that turns an idea into a reviewed specification, an actionable plan, and a disciplined execution loop. By centering on markdown artifacts instead of heavy platform tooling, the workflow travels with youβacross projects, models, and collaboration environments.
- Clarify intent before delivery: The spec prompt requires a clarification sufficiency check so material ambiguities are resolved before planning, while minor uncertainty can remain explicit in the spec.
- Ground plans in current guidance: The spec prompt combines repository pattern discovery with current external best-practice research for material technologies, then asks follow-up questions when those signals still leave meaningful choices open.
- Ship demoable slices: Every stage pushes toward thin, end-to-end increments with clear demo criteria and proof artifacts.
- Make work transparent: Tasks live in versioned markdown files so stakeholders can review, comment, and adjust scope anytime.
- Progress one slice at a time: The management prompt enforces single-threaded execution to reduce churn and unfinished work-in-progress.
- Stay automation ready: While SDD works with plain Markdown, the skill and prompts are structured for MCP, IDE agents, or other AI integrations.
Each SDD run writes Markdown outputs into docs/specs/[NN]-spec-[feature-name]/ (where [NN] is a zero-padded 2-digit number: 01, 02, 03, etc.), giving you a lightweight backlog that is easy to review, share, and implement.
- Specs:
docs/specs/[NN]-spec-[feature-name]/[NN]-spec-[feature-name].md - Questions files (when needed):
docs/specs/[NN]-spec-[feature-name]/[NN]-questions-[N]-[feature-name].md - Task lists:
docs/specs/[NN]-spec-[feature-name]/[NN]-tasks-[feature-name].md - Audit reports:
docs/specs/[NN]-spec-[feature-name]/[NN]-audit-[feature-name].md - Proof artifacts:
docs/specs/[NN]-spec-[feature-name]/[NN]-proofs/[NN]-task-[TT]-proofs.md - Validation reports:
docs/specs/[NN]-spec-[feature-name]/[NN]-validation-[feature-name].md
Example directory structure:
[NN]-questions-[N]-[feature-name].md is optional and appears only when the spec prompt determines a clarification round is required.
docs/specs
βββ 01-spec-feature-name
βββ 01-proofs
β βββ 01-task-01-proofs.md
β βββ 01-task-02-proofs.md
β βββ 01-task-03-proofs.md
β βββ 01-task-04-proofs.md
βββ 01-questions-1-feature-name.md
βββ 01-audit-feature-name.md
βββ 01-spec-feature-name.md
βββ 01-tasks-feature-name.md
βββ 01-validation-feature-name.mdFor comprehensive documentation, examples, and detailed guides, visit the SDD Playbook:
- SDD Playbook β Complete overview and workflow guide
- Comparison β How SDD compares to other structured development tools
- Developer Experience β Real-world usage examples and patterns
- Common Questions β FAQ and troubleshooting
- Video Overview β Visual walkthrough of the workflow
- Reference Materials β Additional resources and examples
To preview the playbook locally with hot reload, run:
uvx livereload --port 8012 docs/Then open http://localhost:8012.
- Start here: Common Questions
- Ask/Report: open a GitHub Issue in this repo with details about your environment + prompt/tooling
Each prompt includes a context verification marker (SDD1οΈβ£ for spec generation, SDD2οΈβ£ for task breakdown, SDD3οΈβ£ for task management, SDD4οΈβ£ for validation) that appears at the start of AI responses. These markers help detect context rotβa phenomenon where AI performance degrades as input context length increases, even when tasks remain simple.
Why this matters: Context rot doesn't announce itself with errors. It creeps in silently, causing models to lose track of critical instructions. When you see the marker at the start of each response, it's an indicator that the AI is probably following the prompt's instructions. If the marker disappears, it's an immediate signal that context instructions may have been lost.
What to expect: You'll see responses like SDD1οΈβ£ I'll help you generate a specification... or SDD3οΈβ£ Let me start implementing task 1.0.... This is normal and indicates the verification system is working. For more details, see the research documentation.
Proof artifacts are committed to your repository and may be publicly visible. Never commit real credentials or sensitive data. Follow these guidelines:
- Replace credentials with placeholders: Use
[YOUR_API_KEY_HERE],[REDACTED], orexample-key-123instead of real API keys, tokens, or passwords - Use example values: When demonstrating configuration, use dummy or example data instead of production values
- Sanitize command output: Review CLI output and logs for accidentally captured credentials before committing
- Consider pre-commit hooks: Tools like gitleaks, truffleHog, or talisman can automatically scan for secrets before commits
The SDD skill and prompt files include built-in reminders about security, but ultimate responsibility lies with the developer to review artifacts before committing or pushing to remotes.
See CONTRIBUTING.md. Please review CODE_OF_CONDUCT.md.
| Reference | Description | Link |
|---|---|---|
| AI Dev Tasks | Foundational example of an SDD workflow expressed entirely in Markdown. | snarktank/ai-dev-tasks |
| Slash Command Manager | Utility for installing prompts as slash commands in AI assistants. | liatrio-labs/slash-command-manager |
| skills.sh | CLI for installing repository skills into skill-native AI assistant workflows. | skills.sh |
| MCP | Standard protocol for AI agent interoperability. | modelcontextprotocol.io |
This project is licensed under the Apache License, Version 2.0. See the LICENSE file for details.


