Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
c66385e
docs(tasks): add spec/tasks for slash commands helper
ryderstorm Oct 22, 2025
46b1649
feat(slash-commands): bootstrap config and detection
ryderstorm Oct 22, 2025
a69ced9
feat: implement Markdown and TOML command generators with override su…
ryderstorm Oct 22, 2025
fdcb0c6
feat: add output normalization and snapshot regression tests
ryderstorm Oct 22, 2025
58b9891
chore: mark task 2.0 complete - all generator subtasks finished
ryderstorm Oct 22, 2025
5153e6b
feat: implement slash command writer with multi-agent support
ryderstorm Oct 22, 2025
a892441
chore: remove generated test files
ryderstorm Oct 22, 2025
a253a23
feat: implement Typer CLI with auto-detection and selection flows
ryderstorm Oct 22, 2025
446a274
feat: implement overwrite handling with backup support
ryderstorm Oct 22, 2025
1bf4461
docs: add slash command generator documentation
ryderstorm Oct 22, 2025
1a90435
docs: mark task 5.0 and all subtasks complete
ryderstorm Oct 22, 2025
3505cd1
fix: add missing tomli-w dependency and update documentation
ryderstorm Oct 22, 2025
f3f5701
feat: Fix critical audit issues and add detection path option
ryderstorm Oct 22, 2025
005a247
docs: Add reference links to supported agents table
ryderstorm Oct 22, 2025
be1708c
feat: implement consistent exit codes and improved error handling
ryderstorm Oct 22, 2025
d088b34
feat: change default paths to home directory and unify option names
ryderstorm Oct 22, 2025
d8b792d
feat: improve --list-agents output with Rich table
ryderstorm Oct 22, 2025
3966f64
feat: improve list-agents table formatting
ryderstorm Oct 22, 2025
dd513e4
fix: correct detection logic to check command directory
ryderstorm Oct 22, 2025
da1baff
fix: correct agent command directories based on official documentation
ryderstorm Oct 22, 2025
bf2eb1d
refactor: remove unsupported agents and update remaining paths
ryderstorm Oct 23, 2025
114d253
fix(config): correct Cursor agent command directory and file extension
ryderstorm Oct 23, 2025
248002b
feat(slash-commands): add version and updated_at metadata to generate…
ryderstorm Oct 23, 2025
8b49c52
refactor(generators): align TOML format with official Gemini CLI spec
ryderstorm Oct 23, 2025
b5441cc
feat(slash-commands): add cleanup command for generated files
ryderstorm Oct 23, 2025
c74bd0f
docs(tasks): add spec and task list for code review fixes
ryderstorm Oct 23, 2025
4c8cafd
feat: add slash_commands to package discovery configuration
ryderstorm Oct 23, 2025
3648ff2
docs: document TOML reading approach and Python version requirements
ryderstorm Oct 23, 2025
2261547
test: add generated content validation tests
ryderstorm Oct 23, 2025
420bfc5
refactor: centralize version management
ryderstorm Oct 23, 2025
ddbf4bf
docs: enhance troubleshooting documentation and Python version requir…
ryderstorm Oct 23, 2025
d1d333e
docs(slash-command-generator): align documentation with actual implem…
ryderstorm Oct 23, 2025
db564dd
test(coverage): add pytest-cov configuration and documentation
ryderstorm Oct 23, 2025
2f021fd
refactor(version): support both local and installed package modes
ryderstorm Oct 23, 2025
21cd658
feat(server): add command-line argument parsing for transport and port
ryderstorm Oct 23, 2025
620f797
docs: reorganize README with clearer usage options
ryderstorm Oct 23, 2025
95749bf
fix: address CodeRabbitAI review comments
ryderstorm Oct 23, 2025
d24a467
fix: update typer version constraint to match available PyPI version
ryderstorm Oct 23, 2025
ce5e36e
chore: update all packages to latest compatible versions
ryderstorm Oct 23, 2025
c0aa9c9
fix: address additional CodeRabbit review comments
ryderstorm Oct 23, 2025
41f7d23
ci: add pre-push test hook and fix dry_run file count bug
ryderstorm Oct 23, 2025
2055453
fix: address remaining CodeRabbit AI review comments
ryderstorm Oct 23, 2025
06169b0
fix: address PR review feedback for slash command generator
ryderstorm Oct 23, 2025
9306fc1
fix: normalize path return types to strings in find_generated_files
ryderstorm Oct 23, 2025
21836fa
fix(install): add fallback to find prompts in installed package
ryderstorm Oct 23, 2025
9315ebb
docs: add TLDR section to README showing quick start workflow
ryderstorm Oct 23, 2025
79045d8
docs: replace Profit with SHIP IT meme in TLDR
ryderstorm Oct 23, 2025
076761d
docs(specs): add spec for fixing bundled prompts directory resolution
ryderstorm Oct 23, 2025
8c174b1
docs(specs): add task list for fixing bundled prompts directory resol…
ryderstorm Oct 23, 2025
b629fcc
feat: add importlib.resources support for bundled prompts resolution
ryderstorm Oct 23, 2025
ac9d0c6
fix: only fall back to bundled prompts for default directory
ryderstorm Oct 23, 2025
bd2744d
docs(tasks): update task list for bundled prompts resolution
ryderstorm Oct 23, 2025
17531c1
docs(tasks): mark all tasks complete for bundled prompts resolution
ryderstorm Oct 23, 2025
7aa966b
docs: improve README with numbered steps and supported AI tools table
ryderstorm Oct 23, 2025
d09623a
fix(review): address PR review feedback
ryderstorm Oct 23, 2025
d98688a
fix(writer): improve importlib.resources package anchor path
ryderstorm Oct 23, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
run: uv sync --all-groups --frozen

- name: Run tests with coverage
run: uv run pytest -vv --cov=mcp_server --cov-report=term-missing:skip-covered --cov-report=xml
run: uv run pytest -vv --cov=mcp_server --cov=slash_commands --cov-report=term-missing:skip-covered --cov-report=xml


- name: Upload coverage.xml artifact
Expand Down
7 changes: 5 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@
__pycache__
.venv

# Misc
temp/
# Coverage
htmlcov
.coverage
coverage.xml

# Misc
temp/
10 changes: 10 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,13 @@ repos:
stages: [commit-msg]
args:
- "--extends=@commitlint/config-conventional"

- repo: local
hooks:
- id: run-tests
name: Run pytest before push
entry: pytest
language: system
stages: [pre-push]
pass_filenames: false
always_run: true
11 changes: 8 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ pre-commit install
### Common Commands

```bash
# Run tests
# Run tests with coverage
uv run pytest

# Run full pre-commit checks across the repo
Expand All @@ -55,14 +55,19 @@ See `docs/operations.md` for more details on transports and configuration.

## Testing

- Tests use `pytest`.
- Tests use `pytest` with coverage reporting via `pytest-cov`.
- Before submitting a PR, run:

```bash
# Run tests with coverage report
uv run pytest
uv run pre-commit run --all-files

# View HTML coverage report (opens in default browser)
uv run python -m webbrowser htmlcov/index.html
```

The test suite generates both terminal and HTML coverage reports showing which code paths are tested.

## Branching and Commit Conventions

### Branch Naming
Expand Down
91 changes: 81 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,35 @@
</p>

<p align="center">
<a href="https://github.com/liatrio-labs/spec-driven-workflow-mcp/actions/workflows/ci.yml"><img src="https://github.com/liatrio-labs/spec-driven-workflow-mcp/actions/workflows/ci.yml/badge.svg" alt="CI Status"/></a>
<a href="https://github.com/liatrio-labs/spec-driven-workflow-mcp/blob/main/LICENSE"><img src="https://img.shields.io/badge/License-Apache_2.0-blue.svg" alt="License"/></a>
<a href="https://github.com/liatrio-labs/spec-driven-workflow-mcp/stargazers"><img src="https://img.shields.io/github/stars/liatrio-labs/spec-driven-workflow-mcp?style=social" alt="GitHub stars"/></a>
<a href="https://github.com/liatrio-labs/spec-driven-workflow/actions/workflows/ci.yml"><img src="https://github.com/liatrio-labs/spec-driven-workflow/actions/workflows/ci.yml/badge.svg" alt="CI Status"/></a>
<a href="https://github.com/liatrio-labs/spec-driven-workflow/blob/main/LICENSE"><img src="https://img.shields.io/badge/License-Apache_2.0-blue.svg" alt="License"/></a>
<a href="https://github.com/liatrio-labs/spec-driven-workflow/stargazers"><img src="https://img.shields.io/github/stars/liatrio-labs/spec-driven-workflow?style=social" alt="GitHub stars"/></a>
<a href="docs/operations.md"><img src="https://img.shields.io/badge/docs-Operations-blue" alt="Documentation"/></a>
</p>

## TLDR

1. Install the workflow prompts as slash commands in all your [local AI tools](#supported-ai-tools):

```bash
uvx --from git+https://github.com/liatrio-labs/spec-driven-workflow sdd-generate-commands generate --yes
```

2. In your AI tool of choice, use `/generate-spec` with your idea:

```text
/generate-spec I want to add user authentication to my app
```

→ AI asks clarifying questions → You provide answers → Spec created in `tasks/0001-spec-user-auth.md`

3. Continue the flow:

- Run `/generate-task-list-from-spec` → Task list created in `tasks/tasks-0001-spec-user-auth.md`
- Use `/manage-tasks` → Execute tasks one-by-one with proof artifacts

4. **SHIP IT** 🚢💨

## Highlights

- **Prompt-first workflow:** Use curated prompts to go from idea → spec → task list → implementation-ready backlog.
Expand Down Expand Up @@ -115,19 +138,57 @@ sequenceDiagram
- **Status Keys:** `[ ]` not started, `[~]` in progress, `[x]` complete, mirroring the manage-tasks guidance.
- **Proof Artifacts:** URLs, CLI commands, screenshots, or tests captured per task to demonstrate working software.

## Hands-On Usage (No MCP Required)
## Hands-On Usage

The SDD workflow can be used in three ways, from simplest to most automated:

### Option 1: Manual Copy-Paste (No Tooling Required)

1. **Kick off a spec:** Copy or reference `prompts/generate-spec.md` inside your preferred AI chat. Provide the feature idea, answer the clarifying questions, and review the generated spec before saving it under `/tasks`.
2. **Plan the work:** Point the assistant to the new spec and walk through `prompts/generate-task-list-from-spec.md`. Approve parent tasks first, then request the detailed subtasks and relevant files. Commit the result to `/tasks`.
3. **Execute with discipline:** Follow `prompts/manage-tasks.md` while implementing. Update statuses as you work, attach proof artifacts, and pause for reviews at each demoable slice.

### Slash Command Integration (TBD)
### Option 2: Native Slash Commands (Recommended)

#### Supported AI Tools

The slash command generator currently supports the following AI coding assistants:

| AI Tool | Command Install Location |
|--------------|--------------------------------------------------|
| Claude Code | `~/.claude/commands` |
| Codex CLI | `~/.codex/prompts` |
| Cursor | `~/.cursor/commands` |
| Gemini CLI | `~/.gemini/commands` |
| VS Code | `~/.config/Code/User/prompts` |
| Windsurf | `~/.codeium/windsurf/global_workflows` |

Guides are coming for wiring these prompts as first-class slash commands in popular IDEs and AI tools (Windsurf, VS Code, Cursor, Claude Code, Codex, and more).
For full setup and agent-specific details, see [docs/slash-command-generator.md](./docs/slash-command-generator.md).

## Optional: Automate with the MCP Server
#### Slash Command Installation

Prefer tighter tooling? This repository also ships an MCP server that exposes the same prompts programmatically. Treat it as an accelerator—everything above works without it.
Generate slash commands for your AI coding assistant and use the prompts as native commands:

```bash
# Clone and install locally
git clone https://github.com/liatrio-labs/spec-driven-workflow.git
cd spec-driven-workflow
uv sync
uv run sdd-generate-commands generate --yes

# Or run directly from the git repo via uvx
uvx --from git+https://github.com/liatrio-labs/spec-driven-workflow sdd-generate-commands generate --yes
```

This will auto-detect your configured AI assistants (Claude Code, Cursor, Windsurf, etc.) and generate command files in your home directory.

**Note**: Once available on PyPI, you'll be able to run `uvx spec-driven-development-mcp sdd-generate-commands generate --yes` for a one-liner installation.

See [docs/slash-command-generator.md](./docs/slash-command-generator.md) for details.

### Option 3: MCP Server (Advanced)

Run the prompts as an MCP server for programmatic access. This option is most useful for custom integrations and tools that support MCP.

> Note: MCP prompt support is not uniformly supported across AI tools. See [docs/mcp-prompt-support.md](./docs/mcp-prompt-support.md) for details.

Expand All @@ -141,8 +202,8 @@ Prefer tighter tooling? This repository also ships an MCP server that exposes th

```bash
# Clone the repository
git clone https://github.com/liatrio-labs/spec-driven-workflow-mcp.git
cd spec-driven-workflow-mcp
git clone https://github.com/liatrio-labs/spec-driven-workflow.git
cd spec-driven-workflow

# Install dependencies
uv sync
Expand All @@ -153,7 +214,11 @@ uv sync
**STDIO (local development):**

```bash
# From local clone
uvx fastmcp run server.py

# Or run directly from the git repo via uvx
uvx --from git+https://github.com/liatrio-labs/spec-driven-workflow spec-driven-development-mcp
```

**With MCP Inspector:**
Expand All @@ -165,9 +230,15 @@ uvx fastmcp dev server.py
**HTTP Transport:**

```bash
# Use fastmcp CLI for HTTP transport
uvx fastmcp run server.py --transport http --port 8000

# Or run directly from the git repo via uvx
uvx --from git+https://github.com/liatrio-labs/spec-driven-workflow spec-driven-development-mcp --transport http --port 8000
```

**Note**: Once available on PyPI, you'll be able to run `uvx spec-driven-development-mcp` for a one-liner installation with optional `--transport` and `--port` arguments. The `fastmcp run` approach remains available for development and advanced options.

See [docs/operations.md](docs/operations.md) and [CONTRIBUTING.md](CONTRIBUTING.md) for advanced configuration, deployment, and contribution guidelines.

## References
Expand Down
26 changes: 26 additions & 0 deletions __version__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
"""Centralized version management for the project.

This module reads the version from pyproject.toml to ensure a single source of truth.
"""

from __future__ import annotations

import tomllib
from importlib.metadata import version as get_package_version
from pathlib import Path


def _get_version() -> str:
"""Get the version from pyproject.toml."""
pyproject_path = Path(__file__).parent / "pyproject.toml"
if pyproject_path.exists():
# Local development mode
with pyproject_path.open("rb") as f:
data = tomllib.load(f)
return data["project"]["version"]
else:
# Installed package mode
return get_package_version("spec-driven-development-mcp")


__version__ = _get_version()
4 changes: 2 additions & 2 deletions docs/operations.md
Original file line number Diff line number Diff line change
Expand Up @@ -147,10 +147,10 @@ uv run pytest
### Run with Coverage

```bash
uv run pytest --cov=mcp_server --cov-report=html
uv run pytest --cov=mcp_server --cov=slash_commands --cov-report=html
```

### Run Specific Test File
Open `htmlcov/index.html` in your browser to view the detailed coverage report.

```bash
uv run pytest tests/test_prompts.py -v
Expand Down
Loading