An effort to allow organizations to focus on product scenarios rather than writing undifferentiated code with the help of Spec-Driven Development.
- 🤔 What is Spec-Driven Development?
- ⚡ Get started
- 🔧 Specify CLI Reference
- 📚 Core philosophy
- 🌟 Development phases
- 🎯 Experimental goals
- 🔧 Prerequisites
- 📖 Documentation
- 🔍 Troubleshooting
- 👥 Maintainers
- 💬 Support
- 🙏 Acknowledgements
- 📄 License
Spec-Driven Development flips the script on traditional software development. For decades, code has been king — specifications were just scaffolding we built and discarded once the "real work" of coding began. Spec-Driven Development changes this: specifications become executable, directly generating working implementations rather than just guiding them.
Initialize your project depending on the coding agent you're using:
uvx --from git+https://github.com/hcnimi/spec-kit.git specify init <PROJECT_NAME>uvx --from git+https://github.com/hcnimi/spec-kit.git- Where to get the package (temporary execution, doesn't install permanently)specify- The CLI tool to executeinit <PROJECT_NAME>- Command and arguments passed to the CLI
If you prefer to install the specify CLI globally for repeated use:
Using uv (recommended):
uv tool install git+https://github.com/hcnimi/spec-kit.gitUsing pip:
pip install git+https://github.com/hcnimi/spec-kit.gitAfter global installation, use specify directly:
specify init <PROJECT_NAME> --ai claudeTo uninstall:
uv tool uninstall specify-cli
# or
pip uninstall specify-cliIf you have existing spec-kit projects initialized with init.sh, they will not automatically use the latest templates after global install. Slash commands like /specify and /plan use templates from your project's .specify/ directory, not the globally installed CLI.
To update existing projects:
- Single project:
cd my-project && specify init --here --ai claude - Multiple projects:
./init.sh --all-repos --ai claude
See Migration Guide for detailed instructions.
| Scenario | Tool | Command |
|---|---|---|
| New project | specify CLI | specify init my-project --ai claude |
| Update single existing project | specify CLI | specify init --here --ai claude |
| Update multiple projects | init.sh | ./init.sh --all-repos --ai claude |
| Local development/testing | init.sh | ./init.sh . --ai claude |
| Multi-repo workspace | specify CLI | specify init --workspace |
Both tools are complementary, not replacements. The specify CLI is recommended for new projects and cross-platform support, while init.sh excels at bulk operations and local development.
If you have this repository cloned locally, you can use the init.sh script directly:
# Single repository mode:
# Basic usage - creates project in new directory
./init.sh my-project
# Initialize in current directory
./init.sh . --ai claude --script sh
# Destroy existing files and start fresh
./init.sh my-project --destroy --ai claude
# Use different AI assistants
./init.sh my-project --ai gemini
./init.sh my-project --ai copilot
./init.sh my-project --ai cursor
# Use PowerShell scripts instead of bash
./init.sh my-project --ai claude --script ps
# Multi-repository mode:
# Preview updates for all repos in current directory
./init.sh --all-repos --ai claude
# Search specific path with custom depth
./init.sh --all-repos --search-path ~/git/myorg --max-depth 2
# Execute without preview (still asks for confirmation)
./init.sh --all-repos --execute --ai claude
# Bulk refresh with --destroy (extra safety prompt)
./init.sh --all-repos --destroy --ai claude --search-path ~/git
# Combine with different script types
./init.sh --all-repos --ai gemini --script ps| Option | Description | Values |
|---|---|---|
--ai |
AI assistant to use | claude, gemini, copilot, cursor (default: claude) |
--script |
Script type to install | sh (bash), ps (PowerShell) (default: sh) |
--destroy |
Delete existing .specify/ directory and start fresh |
Flag |
--all-repos |
Process all repos containing .specify folders (multi-repo mode) |
Flag |
--search-path |
Directory to search for repos with .specify (multi-repo mode only) |
Path (default: current directory) |
--max-depth |
Search depth for .specify folders (multi-repo mode only) |
Number (default: 3) |
--execute |
Skip preview and execute immediately (multi-repo mode only) | Flag |
--help |
Show help message | Flag |
The --destroy flag removes the entire .specify/ directory to start with a clean slate. When you use this flag:
- Confirmation prompt: You'll be asked to confirm deletion of the
.specify/directory - Constitution preservation: If
constitution.mdexists, you'll be prompted whether to preserve it - Complete removal: The entire
.specify/directory is deleted and recreated fresh - Preservation handling: If you chose to preserve
constitution.md, it's restored after the fresh copy
What gets destroyed:
.specify/memory/(exceptconstitution.mdif preserved).specify/scripts/.specify/templates/.specify/docs/- AI-specific command directories (
.claude/commands/,.gemini/commands/, etc.)
What's preserved:
specs/directory (never touched)- Your project files outside
.specify/ constitution.md(if you choose to preserve it).gitignoreentries (updated, not destroyed)
Multi-repo mode with --destroy:
When using --all-repos with --destroy, you'll receive an extra safety confirmation prompt requiring you to type "yes, I'm sure" before proceeding. This prevents accidental bulk deletion across multiple repositories. The constitution preservation prompt will be asked for each repository individually.
The script will:
- Create a
.specify/directory with all necessary templates and scripts - Generate AI-specific command files (
.claude/commands/,.gemini/commands/, etc.) - Preserve your existing
constitution.mdif you choose to - Set up proper
.gitignoreentries - Copy scripts based on your chosen platform (bash or PowerShell)
📝 Note: This section describes the
--all-reposflag for bulk updates across independent projects. For multi-repo workspaces (centralized specs spanning multiple repos), see Multi-Repo Workspaces Guide. Important: Workspaces require the workspace directory to be a git repository.
The --all-repos flag enables bulk initialization across multiple repositories containing .specify folders. This is useful for:
- Updating spec-kit templates across your organization's microservices
- Rolling out spec-kit updates to multiple projects simultaneously
- Standardizing configurations across team repositories
How it works:
- Discovery: Searches for all directories containing
.specifyfolders within the specified search path and depth - Preview: Always shows a preview of all repositories that will be updated (unless
--executeis used) - Confirmation: Asks for user confirmation before making any changes
- Execution: Processes each repository sequentially with detailed progress reporting
Safety features:
- Preview-first workflow: Always previews changes before execution (can skip with
--execute) - Extra confirmation for --destroy: Requires typing
"yes, I'm sure"when combining--all-reposwith--destroy - Individual prompts: Constitution preservation is asked per repository
- Failure isolation: If one repository fails, others continue processing
- Summary report: Shows success/failure counts and lists any failed repositories
Usage examples:
# Preview updates for all repos in current directory (depth 3)
./init.sh --all-repos --ai claude
# Search in specific directory with custom depth
./init.sh --all-repos --search-path ~/git/myorg --max-depth 2 --ai claude
# Preview updates for all repos and specify script type
./init.sh --all-repos --ai gemini --script ps
# Skip preview and execute immediately
./init.sh --all-repos --execute --ai claude
# Bulk refresh with --destroy (requires extra confirmation)
./init.sh --all-repos --destroy --ai claudeConfiguration options:
--search-path: Directory to search (default: current directory)--max-depth: How deep to search for.specifyfolders (default: 3)--execute: Skip preview and proceed directly to confirmation
Example output:
Found 5 repositories with .specify:
1. /Users/you/git/project-a
2. /Users/you/git/project-b
3. /Users/you/git/project-c
4. /Users/you/git/project-d
5. /Users/you/git/project-e
Settings:
AI: claude
Script: sh
Destroy: no
=== PREVIEW MODE ===
[1/5] Would update: project-a
Would create .specify directory structure
Would copy memory folder
[...]
Do you want to proceed with these changes? (y/N):
To install from your own fork or a specific branch:
# Automatic detection (recommended) - CLI auto-detects fork/branch from uvx command
uvx --from git+https://github.com/YOUR_USERNAME/spec-kit.git@BRANCH_NAME specify init <PROJECT_NAME> --ai claude
# Manual specification (if you need to override auto-detection)
uvx --from git+https://github.com/YOUR_USERNAME/spec-kit.git@BRANCH_NAME specify init <PROJECT_NAME> \
--ai claude --repo-owner YOUR_USERNAME --repo-branch BRANCH_NAME
# Or set environment variables
export SPECIFY_REPO_OWNER=YOUR_USERNAME
export SPECIFY_REPO_BRANCH=BRANCH_NAME
uvx --from git+https://github.com/YOUR_USERNAME/spec-kit.git@BRANCH_NAME specify init <PROJECT_NAME> --ai claudeAuto-Detection Feature: When using uvx --from with a GitHub URL, the CLI automatically detects the repository owner and branch, eliminating the need to manually specify --repo-owner and --repo-branch flags. This ensures you download templates from the same fork/branch you're running the CLI from.
For complex products or 0-to-1 development, start with strategic planning:
/product-vision Build a team collaboration platform for distributed teamsThis creates docs/product-vision.md with personas, success metrics, and product-wide requirements. Skip this for simple features or single-feature tools.
Use the /specify command to describe what you want to build. Focus on requirements and constraints.
/specify Build an application that can help me organize my photos in separate photo albums. Albums are grouped by date and can be re-organized by dragging and dropping on the main page. Albums are never in other nested albums. Within each album, photos are previewed in a tile-like interface.If product vision exists, /specify inherits personas and product-wide requirements. Otherwise, it works standalone.
Use the /plan command to provide your tech stack and architecture choices.
/plan The application uses Vite with minimal number of libraries. Use vanilla HTML, CSS, and JavaScript as much as possible. Images are not uploaded anywhere and metadata is stored in a local SQLite database.For features >1000 LOC total, use /decompose to break into atomic capabilities (400-1000 LOC total each).
/decompose
# Generates capability breakdown and creates cap-001/, cap-002/, etc.Use /tasks to create an actionable task list, then ask your agent to implement the feature.
For detailed step-by-step instructions, see our Getting Started Tutorial.
/specify → /plan → /tasks → /implement# On parent branch: username/jira-123.user-system
/specify → /decompose → creates cap-001/, cap-002/, cap-003/ on parent branch
# For each capability (creates NEW branch per capability):
/plan --capability cap-001 → creates branch username/jira-123.user-system-cap-001
/tasks → /implement → PR: cap-001 branch → main (400-1000 LOC total) ✓ MERGED
# Back to parent, sync with main, repeat:
git checkout username/jira-123.user-system
git pull origin main
/plan --capability cap-002 → creates branch username/jira-123.user-system-cap-002
/tasks → /implement → PR: cap-002 branch → main (400-1000 LOC total) ✓ MERGED
# Continue for cap-003, cap-004, etc.Result: Multiple atomic PRs (400-1000 LOC total each) instead of one massive PR.
Key Benefits:
- Each capability gets its own branch and atomic PR to main
- Fast reviews (1-2 days per PR vs 7+ days for large PRs)
- Parallel development (team members work on different capabilities)
- Early integration feedback (merge to main frequently)
The specify command supports the following options:
| Command | Description |
|---|---|
init |
Initialize a new Specify project from the latest template |
check |
Check for installed tools (git, claude, gemini, code/code-insiders, cursor-agent) |
| Command | Purpose | When to Use |
|---|---|---|
/specify |
Create feature specification | Always - first step for any feature |
/decompose |
Break feature into capabilities | For complex features (>1000 LOC total, >5 requirements) |
/plan |
Create implementation plan | After /specify (simple) or /decompose (complex) |
/tasks |
Generate task list | After /plan is complete |
/implement |
Execute implementation | After /tasks is complete |
| Argument/Option | Type | Description |
|---|---|---|
<project-name> |
Argument | Name for your new project directory (optional if using --here) |
--ai |
Option | AI assistant to use: claude, gemini, copilot, or cursor |
--script |
Option | Script variant to use: sh (bash/zsh) or ps (PowerShell) |
--ignore-agent-tools |
Flag | Skip checks for AI agent tools like Claude Code |
--no-git |
Flag | Skip git repository initialization |
--here |
Flag | Initialize project in the current directory instead of creating a new one |
--skip-tls |
Flag | Skip SSL/TLS verification (not recommended) |
--debug |
Flag | Enable detailed debug output for troubleshooting |
--repo-owner |
Option | GitHub repository owner (default: github, auto-detected from uvx --from) |
--repo-name |
Option | GitHub repository name (default: spec-kit, auto-detected from uvx --from) |
--repo-branch |
Option | GitHub repository branch to download from (uses releases by default, auto-detected from uvx --from) |
# Basic project initialization
specify init my-project
# Initialize with specific AI assistant
specify init my-project --ai claude
# Initialize with Cursor support
specify init my-project --ai cursor
# Initialize with PowerShell scripts (Windows/cross-platform)
specify init my-project --ai copilot --script ps
# Initialize in current directory
specify init --here --ai copilot
# Skip git initialization
specify init my-project --ai gemini --no-git
# Enable debug output for troubleshooting
specify init my-project --ai claude --debug
# Check system requirements
specify checkSpec-Driven Development is a structured process that emphasizes:
- Intent-driven development where specifications define the "what" before the "how"
- Rich specification creation using guardrails and organizational principles
- Multi-step refinement rather than one-shot code generation from prompts
- Heavy reliance on advanced AI model capabilities for specification interpretation
| Phase | Focus | Key Activities |
|---|---|---|
| 0-to-1 Development ("Greenfield") | Generate from scratch |
|
| Creative Exploration | Parallel implementations |
|
| Iterative Enhancement ("Brownfield") | Brownfield modernization |
|
Greenfield with Product Vision (Complex product, 0-to-1):
/product-vision → docs/product-vision.md (personas, success metrics, product NFRs)
/specify → specs/proj-1.mvp/spec.md (inherits from product vision)
/plan → specs/proj-1.mvp/plan.md (establishes docs/system-architecture.md v1.0.0)
/tasks → specs/proj-1.mvp/tasks.md
implement → MVP launched
Greenfield without Product Vision (Simple tool, single feature):
/specify → specs/proj-1.tool/spec.md (standalone specification)
/plan → specs/proj-1.tool/plan.md (establishes docs/system-architecture.md v1.0.0)
/tasks → specs/proj-1.tool/tasks.md
implement → Tool launched
Brownfield Feature Addition (Extending existing product):
/specify → specs/proj-2.feature/spec.md (inherits from docs/product-vision.md + docs/system-architecture.md)
/plan → specs/proj-2.feature/plan.md (extends architecture v1.0.0 → v1.1.0)
/tasks → specs/proj-2.feature/tasks.md
implement → Feature added, architecture extended
For detailed workflows including architecture refactoring, see our Core Concepts documentation.
Our research and experimentation focus on:
- Create applications using diverse technology stacks
- Validate the hypothesis that Spec-Driven Development is a process not tied to specific technologies, programming languages, or frameworks
- Demonstrate mission-critical application development
- Incorporate organizational constraints (cloud providers, tech stacks, engineering practices)
- Support enterprise design systems and compliance requirements
- Build applications for different user cohorts and preferences
- Support various development approaches (from vibe-coding to AI-native development)
- Validate the concept of parallel implementation exploration
- Provide robust iterative feature development workflows
- Extend processes to handle upgrades and modernization tasks
- Linux/macOS (or WSL2 on Windows)
- AI coding agent: Claude Code, GitHub Copilot, Gemini CLI, or Cursor
- uv for package management
- Python 3.11+
- Git
Comprehensive documentation is organized into focused sections:
- 📚 Getting Started - Installation, quick start, first project tutorial
- 📖 How-To Guides - Task-focused guides for different scenarios
- 💡 Core Concepts - Deep dives into philosophy and principles
- 📋 Reference - Technical specifications and API docs
- ✅ Validation - Quality gates and review processes
- 🔧 Contributing - Developer and contributor guides
- Installation Guide
- Your First Spec Tutorial
- Multi-Repo Workspaces
⚠️ Workspace must be a git repository - Atomic PRs for Large Features
- Spec-Driven Philosophy
If you're having issues with Git authentication on Linux, you can install Git Credential Manager:
#!/usr/bin/env bash
set -e
echo "Downloading Git Credential Manager v2.6.1..."
wget https://github.com/git-ecosystem/git-credential-manager/releases/download/v2.6.1/gcm-linux_amd64.2.6.1.deb
echo "Installing Git Credential Manager..."
sudo dpkg -i gcm-linux_amd64.2.6.1.deb
echo "Configuring Git to use GCM..."
git config --global credential.helper manager
echo "Cleaning up..."
rm gcm-linux_amd64.2.6.1.debThis fork is maintained by:
- Hubert Nimitanakit (@hcnimi)
Original Creators (GitHub's spec-kit):
For support, please open a GitHub issue. We welcome bug reports, feature requests, and questions about using Spec-Driven Development.
This project is a fork and evolution of GitHub's spec-kit, originally created by Den Delimarsky and John Lam.
Additional Inspirations:
- PRPs (Prompt-Response Pairs) by Wirasm - Influenced our approach to agentic engineering workflows
- OpenSpec by Fission-AI - Inspired the adaptive workflow modes (quick/lightweight/full) introduced in v0.4.0
We're grateful to these projects for advancing spec-driven and AI-native development methodologies.
This project is licensed under the terms of the MIT open source license. Please refer to the LICENSE file for the full terms.
