@benjaminthomas/spec-driven-dev 0.0.0-stage → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +483 -2
- package/bin/cli.mjs +357 -0
- package/package.json +12 -4
- package/skills/generative-seo/SKILL.md +255 -0
- package/skills/generative-seo/assets/citation-log-template.md +17 -0
- package/skills/generative-seo/assets/competitor-analysis-template.md +20 -0
- package/skills/generative-seo/assets/content-plan-template.md +15 -0
- package/skills/generative-seo/assets/geo-config-template.md +33 -0
- package/skills/generative-seo/assets/geo-playbook-template.md +22 -0
- package/skills/generative-seo/assets/social-queue-template.md +8 -0
- package/skills/generative-seo/references/geo-methodology.md +143 -0
- package/skills/spec-checkpoint/SKILL.md +106 -0
- package/skills/spec-create/SKILL.md +149 -0
- package/skills/spec-create/references/action-required-template.md +53 -0
- package/skills/spec-create/references/readme-template.md +53 -0
- package/skills/spec-create/references/requirements-template.md +54 -0
- package/skills/spec-create/references/task-template.md +86 -0
- package/skills/spec-implement/SKILL.md +236 -0
- package/skills/spec-implement/references/coder-prompt-template.md +48 -0
- package/skills/spec-implement/references/fix-prompt-template.md +38 -0
- package/skills/spec-implement/references/review-prompt-template.md +50 -0
- package/skills/spec-investigate/SKILL.md +323 -0
- package/skills/spec-investigate/references/report-template.md +53 -0
- package/skills/spec-setup/SKILL.md +99 -0
- package/skills/spec-setup/references/config-template.yml +45 -0
- package/skills/spec-ship/SKILL.md +218 -0
- package/skills/spec-verify/SKILL.md +153 -0
- package/skills/spec-verify/references/report-template.md +57 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 benjaminbarnabas
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,3 +1,484 @@
|
|
|
1
|
-
#
|
|
1
|
+
# spec-driven-dev
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
**A step-by-step workflow that gets AI coding agents from "here's a ticket" to "here's a reviewed PR"
|
|
4
|
+
without guessing.** It first investigates the problem, then writes a plan you approve, then builds it
|
|
5
|
+
in parallel with tests and review, then checks the real running app, and finally commits and opens
|
|
6
|
+
the PR.
|
|
7
|
+
|
|
8
|
+
It's a set of eight [Agent Skills](https://agentskills.io), plain Markdown instruction files that
|
|
9
|
+
AI coding tools load on demand. It works with Claude Code, Codex CLI, Cursor, and Google Antigravity,
|
|
10
|
+
in any language or framework, and in a single repo, a monorepo, or several repos that change
|
|
11
|
+
together. One command installs it: `npx @benjaminthomas/spec-driven-dev`.
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
## Contents
|
|
16
|
+
|
|
17
|
+
- [Why use it](#why-use-it)
|
|
18
|
+
- [Quick start (5 minutes)](#quick-start-5-minutes)
|
|
19
|
+
- [Project setup: your team's rules](#project-setup-your-teams-rules)
|
|
20
|
+
- [How the workflow fits together](#how-the-workflow-fits-together)
|
|
21
|
+
- [The skills, one by one](#the-skills-one-by-one)
|
|
22
|
+
- [What ends up in your repo](#what-ends-up-in-your-repo)
|
|
23
|
+
- [Safety rails](#safety-rails)
|
|
24
|
+
- [FAQ](#faq)
|
|
25
|
+
- [Install](#install)
|
|
26
|
+
- [Compatibility](#compatibility)
|
|
27
|
+
- [By the numbers](#by-the-numbers)
|
|
28
|
+
- [Working on this repo](#working-on-this-repo)
|
|
29
|
+
|
|
30
|
+
---
|
|
31
|
+
|
|
32
|
+
## Why use it
|
|
33
|
+
|
|
34
|
+
Asking an AI agent to "just build it" tends to fail in predictable ways:
|
|
35
|
+
|
|
36
|
+
| Problem | What this workflow does instead |
|
|
37
|
+
|---|---|
|
|
38
|
+
| The agent guesses how your system works and builds on a wrong assumption | **`spec-investigate`** reads the real code first and labels every finding as verified, inferred, assumed, or unknown |
|
|
39
|
+
| A big plan won't fit in the agent's context, or is too vague to act on | **`spec-create`** splits the work into small, self-contained task files, so each agent reads only its own |
|
|
40
|
+
| One agent working alone is slow | **`spec-implement`** runs several coder agents in parallel, each in its own copy of the repo |
|
|
41
|
+
| "It compiles" gets treated as "it works" | **`spec-verify`** drives the real running app and checks every acceptance criterion, with evidence |
|
|
42
|
+
| Broken code gets committed, or a PR is pushed by accident | **`spec-checkpoint`** commits only once lint, types, tests, and build all pass. **`spec-ship`** asks before it pushes |
|
|
43
|
+
|
|
44
|
+
Each stage writes its result to a file, so you can stop at any point, hand over to a teammate, or
|
|
45
|
+
start a new session and continue where you left off.
|
|
46
|
+
|
|
47
|
+
---
|
|
48
|
+
|
|
49
|
+
## Quick start (5 minutes)
|
|
50
|
+
|
|
51
|
+
**1. Install.** In your project folder (or, for several repos, their shared parent folder), run:
|
|
52
|
+
|
|
53
|
+
```bash
|
|
54
|
+
npx @benjaminthomas/spec-driven-dev
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
The installer:
|
|
58
|
+
1. **Finds your AI tools** (Claude Code, Cursor, Codex CLI, Antigravity) and installs the skills
|
|
59
|
+
into each one you choose, for this project or for all projects.
|
|
60
|
+
2. **Sets up your project** by detecting its layout, issue tracker, branch conventions, and
|
|
61
|
+
commands, then asking you to confirm. The answers go into `.spec-driven.yml`
|
|
62
|
+
([details below](#project-setup-your-teams-rules)).
|
|
63
|
+
|
|
64
|
+
**2. In your project, run each stage in order.** You can type the slash command or just say the
|
|
65
|
+
words in quotes.
|
|
66
|
+
|
|
67
|
+
```
|
|
68
|
+
/spec-investigate STP-123 "look into STP-123 before we plan it"
|
|
69
|
+
→ read specs/stp-123-…/investigation.md
|
|
70
|
+
|
|
71
|
+
/spec-create "turn this into a spec"
|
|
72
|
+
→ review specs/stp-123-…/ ← YOU APPROVE HERE
|
|
73
|
+
|
|
74
|
+
/spec-implement "implement the spec"
|
|
75
|
+
/spec-verify "does it actually work?"
|
|
76
|
+
/spec-checkpoint "checkpoint"
|
|
77
|
+
/spec-ship "ship it"
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
That's the whole workflow. Every stage can be used on its own as well: use `/spec-create` straight
|
|
81
|
+
from a planning chat, or `/spec-checkpoint` on any work in progress.
|
|
82
|
+
|
|
83
|
+
---
|
|
84
|
+
|
|
85
|
+
## Project setup: your team's rules
|
|
86
|
+
|
|
87
|
+
Teams work differently. Some branch from `main`, some from `staging`. Some name branches `STP-123`,
|
|
88
|
+
others `fix/STP-123-short-name`. Some have one repo, others have six. None of this is built into the
|
|
89
|
+
skills. Each project describes its own rules in **`.spec-driven.yml`**, and every skill reads that
|
|
90
|
+
file before doing anything.
|
|
91
|
+
|
|
92
|
+
**How the file gets created:** `npx @benjaminthomas/spec-driven-dev` (or `npx @benjaminthomas/spec-driven-dev setup` to run only this
|
|
93
|
+
step) detects the answers from your repos and asks you to confirm them. In your AI tool you can also
|
|
94
|
+
say **"run spec-setup"**: that does a deeper version that also reads `CLAUDE.md`/`AGENTS.md`, CI
|
|
95
|
+
config, and recent PRs, and fills in what the installer can't (such as each repo's role, or commands
|
|
96
|
+
for stacks other than Node). If a skill finds no config, it runs this setup first.
|
|
97
|
+
|
|
98
|
+
**What it asks:**
|
|
99
|
+
|
|
100
|
+
| Question | Detected from | Example answer |
|
|
101
|
+
|---|---|---|
|
|
102
|
+
| Project layout | git repos and workspace files (`pnpm-workspace.yaml`, `turbo.json`, `nx.json`, `go.work`, …) | `single`, `monorepo`, or `multi-repo` |
|
|
103
|
+
| Which repos belong together (multi-repo) | sibling git repos grouped by GitHub owner | `api`, `web`, `worker` |
|
|
104
|
+
| Issue tracker | ticket keys in branch names and commits | Jira, key `STP` |
|
|
105
|
+
| Base branch / PR target | default branch, `staging`/`develop` branches | `staging` |
|
|
106
|
+
| Branch name pattern | your recent branch names | `{ticket}` → `STP-123` |
|
|
107
|
+
| Commit style | your recent commit messages | `conventional` (`feat: …`) or `ticket` (`STP-123: …`) |
|
|
108
|
+
| Lint / typecheck / test / build / dev commands | `package.json` scripts and lockfile (per repo or package) | `pnpm run lint` |
|
|
109
|
+
| Where specs go | (you choose) | `specs/` |
|
|
110
|
+
|
|
111
|
+
**Where the file lives, by layout:**
|
|
112
|
+
|
|
113
|
+
| Layout | What it means | `.spec-driven.yml` goes in | How the workflow adapts |
|
|
114
|
+
|---|---|---|---|
|
|
115
|
+
| **single** | one repo, one app | the repo root (commit it, so the team shares it) | as described below |
|
|
116
|
+
| **monorepo** | one repo, many apps/packages | the repo root (commit it) | tasks name their package, and checks run per package |
|
|
117
|
+
| **multi-repo** | several repos that change together | their shared parent folder (personal to your machine) | investigation searches every listed repo, tasks stay inside one repo each, and `spec-ship` opens one PR per repo, each linking the others |
|
|
118
|
+
|
|
119
|
+
To change the rules later, edit the file or run setup again, then run `npx @benjaminthomas/spec-driven-dev doctor`
|
|
120
|
+
to confirm the file still matches your repos. Setup never overwrites the file without
|
|
121
|
+
asking. See [`config-template.yml`](skills/spec-setup/references/config-template.yml) for every field.
|
|
122
|
+
|
|
123
|
+
## How the workflow fits together
|
|
124
|
+
|
|
125
|
+
```
|
|
126
|
+
┌──────────────────┐ ┌─────────────┐ ┌──────────┐ ┌────────────────┐ ┌─────────────┐ ┌─────────────────┐ ┌───────────┐
|
|
127
|
+
│ spec-investigate │ → │ spec-create │ → │ YOU │ → │ spec-implement │ → │ spec-verify │ → │ spec-checkpoint │ → │ spec-ship │
|
|
128
|
+
│ understand │ │ plan │ │ approve │ │ build + test │ │ prove │ │ commit │ │ open PR │
|
|
129
|
+
└──────────────────┘ └─────────────┘ └──────────┘ └────────────────┘ └─────────────┘ └─────────────────┘ └───────────┘
|
|
130
|
+
investigation.md specs/<feature>/ code + tests, verification- local commit pushed branch
|
|
131
|
+
+ work branch task files one commit/batch report.md + GitHub PR
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
- **The approval step is yours.** Nothing builds until you've read the spec and run `spec-implement`
|
|
135
|
+
yourself. `spec-investigate` never moves on to the next stage by itself.
|
|
136
|
+
- **Each stage reads the previous stage's files.** `spec-create` uses `investigation.md` as its
|
|
137
|
+
evidence, `spec-implement` works through the task files, and `spec-verify` checks against their
|
|
138
|
+
acceptance criteria.
|
|
139
|
+
- **Stages can be skipped.** For new projects with nothing to investigate, start at `spec-create`.
|
|
140
|
+
For a quick fix, use only `spec-checkpoint` and `spec-ship`.
|
|
141
|
+
|
|
142
|
+
---
|
|
143
|
+
|
|
144
|
+
## The skills, one by one
|
|
145
|
+
|
|
146
|
+
### 0. `spec-setup`: learn the project's rules
|
|
147
|
+
|
|
148
|
+
**Say:** "run spec-setup", "configure the pipeline", "change our branch rules"
|
|
149
|
+
|
|
150
|
+
**What it does:** see [Project setup](#project-setup-your-teams-rules). It writes `.spec-driven.yml` and
|
|
151
|
+
nothing else: no branches, commits, or code.
|
|
152
|
+
|
|
153
|
+
### 1. `spec-investigate`: understand before planning
|
|
154
|
+
|
|
155
|
+
**Say:** "investigate STP-123", "look into this before we plan it", or `/spec-investigate <input>`
|
|
156
|
+
|
|
157
|
+
**Give it any of these:**
|
|
158
|
+
|
|
159
|
+
| Input | Example |
|
|
160
|
+
|---|---|
|
|
161
|
+
| Jira ticket | `STP-123` or `https://acme.atlassian.net/browse/STP-123` |
|
|
162
|
+
| GitHub issue | `#482` or `https://github.com/acme/app/issues/482` |
|
|
163
|
+
| Linear issue | `https://linear.app/acme/issue/ENG-91` |
|
|
164
|
+
| Transcript / notes / PRD / log file | `./call-transcript.txt`, `./prd.md`, `./error.log` |
|
|
165
|
+
| Plain text | `"Checkout times out for EU users since Tuesday's deploy"` |
|
|
166
|
+
| Pasted material | a Slack thread or stack trace pasted into the same message |
|
|
167
|
+
|
|
168
|
+
You can add `--context ./notes.md` to supply extra background, such as meeting notes.
|
|
169
|
+
|
|
170
|
+
**What it does:**
|
|
171
|
+
1. Loads the input. For tickets, that includes comments and linked issues. Free text is read
|
|
172
|
+
carefully: "maybe we should add an endpoint" is recorded as a proposal, not a requirement.
|
|
173
|
+
2. Creates a work branch from the base branch in `.spec-driven.yml`, named by its pattern, and never
|
|
174
|
+
touches existing work. In a multi-repo setup, it creates the branch only in the repos that need
|
|
175
|
+
changes.
|
|
176
|
+
3. Traces how the system actually works, naming real files and functions. For bugs, it finds the
|
|
177
|
+
root cause.
|
|
178
|
+
4. Sorts the work into **required / supporting / optional / out of scope**, and lists risks, security
|
|
179
|
+
and performance concerns, and existing tests.
|
|
180
|
+
|
|
181
|
+
**You get:** `specs/<feature>/investigation.md`, with every finding labelled **VERIFIED**,
|
|
182
|
+
**INFERRED**, **ASSUMPTION**, or **UNKNOWN**.
|
|
183
|
+
|
|
184
|
+
**It won't:** write code, write tests, or start `spec-create` without being asked.
|
|
185
|
+
|
|
186
|
+
### 2. `spec-create`: turn the plan into tasks
|
|
187
|
+
|
|
188
|
+
**Say:** "create a spec", "plan this feature", "break this into tasks"
|
|
189
|
+
|
|
190
|
+
**What it does:** It reads `investigation.md` if one exists, plus your planning conversation. If
|
|
191
|
+
there's no conversation, it asks you a few questions first. It then splits the work into tasks,
|
|
192
|
+
each touching 1–5 files, and groups them into **batches**. Tasks in the same batch don't depend on
|
|
193
|
+
each other and don't touch the same files, so they can be built at the same time.
|
|
194
|
+
|
|
195
|
+
**You get:** a `specs/<feature>/` folder (see [What ends up in your repo](#what-ends-up-in-your-repo)).
|
|
196
|
+
Each task file is complete on its own: description, files to change, implementation steps, **tests
|
|
197
|
+
to write**, and acceptance criteria.
|
|
198
|
+
|
|
199
|
+
**Then:** read it, edit anything you disagree with, and only then run `spec-implement`.
|
|
200
|
+
|
|
201
|
+
### 3. `spec-implement`: build it, batch by batch
|
|
202
|
+
|
|
203
|
+
**Say:** "implement this feature", "run the spec", "continue implementing"
|
|
204
|
+
|
|
205
|
+
**What it does, for each batch:**
|
|
206
|
+
1. Starts one coder agent per task, running at the same time. Each one works in its **own git
|
|
207
|
+
worktree** (a separate copy of the repo) so they can't overwrite each other's work.
|
|
208
|
+
2. Each coder **writes the task's tests first**, then writes code until they pass, and then runs
|
|
209
|
+
lint and typecheck.
|
|
210
|
+
3. Merges the worktrees back. If two tasks conflict, it stops and asks you.
|
|
211
|
+
4. A **separate reviewer agent** runs lint, typecheck, and tests and checks every acceptance
|
|
212
|
+
criterion. If anything fails, fix agents are sent in, for up to 3 rounds before it stops and
|
|
213
|
+
asks you.
|
|
214
|
+
5. Commits the batch and ticks it off in the spec's README.
|
|
215
|
+
|
|
216
|
+
**It can resume:** if you stop halfway, run it again and it carries on from the first unfinished
|
|
217
|
+
batch. If your tool can't run agents in parallel, it does the tasks one at a time instead.
|
|
218
|
+
|
|
219
|
+
### 4. `spec-verify`: prove it works
|
|
220
|
+
|
|
221
|
+
**Say:** "verify this", "test it end to end", "does this actually work?"
|
|
222
|
+
|
|
223
|
+
**What it does:** It collects every acceptance criterion from the spec, starts your app, and checks
|
|
224
|
+
each one the way a user would: clicking through the UI, calling real API routes, and reading the
|
|
225
|
+
database only to confirm the result.
|
|
226
|
+
|
|
227
|
+
**You get:** `specs/<feature>/verification-report.md`, with pass or fail for each criterion and the
|
|
228
|
+
evidence (screenshots, responses, data). If there's no spec, it asks you what "working" means and
|
|
229
|
+
checks that instead.
|
|
230
|
+
|
|
231
|
+
### 5. `spec-checkpoint`: commit safely
|
|
232
|
+
|
|
233
|
+
**Say:** "checkpoint", "commit everything", "save my progress"
|
|
234
|
+
|
|
235
|
+
**What it does:** It runs the lint, typecheck, test, and build commands from `.spec-driven.yml` (or
|
|
236
|
+
finds them in `package.json`, `Makefile`, `pyproject.toml`, CI config, and so on) and fixes failures.
|
|
237
|
+
Then it stages everything and commits in your configured style (`feat: …` or `STP-123: …`). In a
|
|
238
|
+
multi-repo setup, it makes one commit in each repo that changed.
|
|
239
|
+
|
|
240
|
+
**It won't:** push. Committing is a local step.
|
|
241
|
+
|
|
242
|
+
### 6. `spec-ship`: open the PR
|
|
243
|
+
|
|
244
|
+
**Say:** "ship it", "push this", "open a PR"
|
|
245
|
+
|
|
246
|
+
**What it does:** It creates a branch using your naming pattern if you're on the default branch,
|
|
247
|
+
**shows you exactly what will be pushed and waits for your "yes"**, then pushes and opens a GitHub PR
|
|
248
|
+
against your configured PR target, with a written description. In a multi-repo setup, it opens one
|
|
249
|
+
PR per repo, each linking the others. If a PR already exists for the branch, it pushes the new commits to that PR
|
|
250
|
+
instead of opening another one.
|
|
251
|
+
|
|
252
|
+
**Needs:** the [GitHub CLI](https://cli.github.com) (`gh`), logged in.
|
|
253
|
+
|
|
254
|
+
### Bonus: `generative-seo`, a separate skill for SEO
|
|
255
|
+
|
|
256
|
+
This one isn't part of the workflow. It runs SEO and **GEO** (Generative Engine Optimization: getting
|
|
257
|
+
your content cited by ChatGPT, Perplexity, and Google AI Overviews) for any website codebase. It has
|
|
258
|
+
seven modes: `audit`, `content`, `optimize`, `competitors`, `citations`, `report`, and `social`. The
|
|
259
|
+
first time, it asks a few questions about your brand, domain, and framework, and remembers the
|
|
260
|
+
answers. See `skills/generative-seo/SKILL.md`.
|
|
261
|
+
|
|
262
|
+
---
|
|
263
|
+
|
|
264
|
+
## What ends up in your repo
|
|
265
|
+
|
|
266
|
+
```
|
|
267
|
+
specs/
|
|
268
|
+
└── stp-123-csv-export-missing-rows/
|
|
269
|
+
├── investigation.md ← spec-investigate: what's true today, with evidence
|
|
270
|
+
├── requirements.md ← spec-create: what we're building and why
|
|
271
|
+
├── action-required.md ← spec-create: things only a human can do (API keys, DNS, accounts)
|
|
272
|
+
├── README.md ← spec-create: batches, dependency graph, progress checkboxes
|
|
273
|
+
├── tasks/
|
|
274
|
+
│ ├── task-01-fix-pagination.md
|
|
275
|
+
│ ├── task-02-add-export-test-fixtures.md
|
|
276
|
+
│ └── …
|
|
277
|
+
└── verification-report.md ← spec-verify: pass/fail per acceptance criterion
|
|
278
|
+
```
|
|
279
|
+
|
|
280
|
+
These are plain Markdown files, so you can review them in a PR, edit them, or hand them to a
|
|
281
|
+
teammate. If your repo gitignores `specs/`, the skills respect that.
|
|
282
|
+
|
|
283
|
+
---
|
|
284
|
+
|
|
285
|
+
## Safety rails
|
|
286
|
+
|
|
287
|
+
Built into the skills, not left to the agent's judgment:
|
|
288
|
+
|
|
289
|
+
- **You approve before anything is built.** Nothing goes from investigation to implementation by
|
|
290
|
+
itself.
|
|
291
|
+
- **Your work is never destroyed.** No stash, reset, force-push, or branch deletion without your
|
|
292
|
+
say-so. If there are uncommitted changes it doesn't recognise, it stops and asks.
|
|
293
|
+
- **No guessing.** Gaps are marked UNKNOWN, and missing tickets are asked for rather than made up.
|
|
294
|
+
- **Tests can't be cheated.** Coders may not delete, skip, or weaken a test to make it pass, and the
|
|
295
|
+
reviewer checks for this.
|
|
296
|
+
- **Pushing needs an explicit "yes".**
|
|
297
|
+
- **Investigation stays in scope.** Ideas that come up along the way go under "optional" or "out of
|
|
298
|
+
scope" instead of being folded into the work.
|
|
299
|
+
|
|
300
|
+
---
|
|
301
|
+
|
|
302
|
+
## FAQ
|
|
303
|
+
|
|
304
|
+
**Do I need Jira?**
|
|
305
|
+
No. Use GitHub Issues, Linear, a transcript, a document, or a sentence of plain text. Jira is just
|
|
306
|
+
one of the options.
|
|
307
|
+
|
|
308
|
+
**How does it choose the base branch and branch name?**
|
|
309
|
+
From `.spec-driven.yml`, which setup fills in by looking at your recent branches and asking you to
|
|
310
|
+
confirm. To change it, edit `git.base_branch` / `git.branch_name` or run setup again.
|
|
311
|
+
|
|
312
|
+
**Should I commit `.spec-driven.yml`?**
|
|
313
|
+
For a single repo or monorepo, yes: the whole team then follows the same rules. A multi-repo
|
|
314
|
+
config sits outside any repo, so it stays on your machine.
|
|
315
|
+
|
|
316
|
+
**Does it work with my stack?**
|
|
317
|
+
Yes. No skill assumes a language or framework. Each one finds the repo's own commands.
|
|
318
|
+
|
|
319
|
+
**Can I skip stages?**
|
|
320
|
+
Yes. Every skill works on its own. `spec-verify` even works without a spec: it asks what to check.
|
|
321
|
+
|
|
322
|
+
**What if my tool can't run agents in parallel?**
|
|
323
|
+
`spec-implement` builds tasks one at a time instead. You get the same results, just more slowly.
|
|
324
|
+
|
|
325
|
+
**Can I stop halfway?**
|
|
326
|
+
Yes. Progress is saved in the spec's `README.md` checkboxes and the commit for each batch. Run
|
|
327
|
+
`spec-implement` again to continue.
|
|
328
|
+
|
|
329
|
+
**`spec-verify` says it skipped some UI checks.**
|
|
330
|
+
Your tool needs browser automation (an MCP browser server, a built-in browser tool, or an
|
|
331
|
+
extension) for checks that involve the UI. Checks that only touch the API or database work
|
|
332
|
+
everywhere.
|
|
333
|
+
|
|
334
|
+
---
|
|
335
|
+
|
|
336
|
+
## Install
|
|
337
|
+
|
|
338
|
+
### Any tool: npm (recommended)
|
|
339
|
+
|
|
340
|
+
```bash
|
|
341
|
+
npx @benjaminthomas/spec-driven-dev # detect tools, install, set up the project
|
|
342
|
+
npx @benjaminthomas/spec-driven-dev setup # only (re)run project setup
|
|
343
|
+
npx @benjaminthomas/spec-driven-dev --global # install for all projects, not just this one
|
|
344
|
+
npx @benjaminthomas/spec-driven-dev --tools=cursor,codex # pick tools without being asked
|
|
345
|
+
npx @benjaminthomas/spec-driven-dev --skills=spec-create,spec-ship # install only some skills
|
|
346
|
+
npx @benjaminthomas/spec-driven-dev --yes # accept every detected default (CI-friendly)
|
|
347
|
+
npx @benjaminthomas/spec-driven-dev doctor # check .spec-driven.yml against the real repos
|
|
348
|
+
npx @benjaminthomas/spec-driven-dev status # list specs with unfinished work
|
|
349
|
+
```
|
|
350
|
+
|
|
351
|
+
`doctor` checks that every branch, folder, and `npm run` script named in the config exists, and
|
|
352
|
+
that each value is one the skills understand. It exits 1 if anything is wrong, so you can run it in
|
|
353
|
+
CI. `status` prints nothing when all specs are finished.
|
|
354
|
+
|
|
355
|
+
Run it again at any time to update: it replaces the installed skill folders with the latest
|
|
356
|
+
version. `npx github:benjaminthomas/spec-driven-dev` installs straight from GitHub (for example, an unreleased
|
|
357
|
+
commit on `main`).
|
|
358
|
+
|
|
359
|
+
### Claude Code (plugin, with automatic updates)
|
|
360
|
+
|
|
361
|
+
```
|
|
362
|
+
/plugin marketplace add https://github.com/benjaminthomas/spec-driven-dev.git
|
|
363
|
+
/plugin install spec-driven-dev@spec-driven-dev
|
|
364
|
+
```
|
|
365
|
+
|
|
366
|
+
To update, run `/plugin marketplace update spec-driven-dev`, then update the plugin from `/plugin`.
|
|
367
|
+
|
|
368
|
+
The plugin also adds a **session-start reminder**. When you open Claude Code in a project with
|
|
369
|
+
unfinished specs, Claude is told which ones and what the next step is (for example,
|
|
370
|
+
`specs/stp-123: 3/5 tasks done → next: spec-implement`). It prints nothing when everything is
|
|
371
|
+
finished. If
|
|
372
|
+
you use the plugin, `npx @benjaminthomas/spec-driven-dev` skips Claude Code so you don't get every skill twice. Run
|
|
373
|
+
`npx @benjaminthomas/spec-driven-dev setup` for the project config.
|
|
374
|
+
|
|
375
|
+
### By hand
|
|
376
|
+
|
|
377
|
+
Copy the `skills/<name>/` folders you want. Each one is self-contained. Where each tool looks for
|
|
378
|
+
skills:
|
|
379
|
+
|
|
380
|
+
| Tool | This project | All projects |
|
|
381
|
+
|---|---|---|
|
|
382
|
+
| Claude Code | `.claude/skills/<name>/` | `~/.claude/skills/<name>/` |
|
|
383
|
+
| Codex CLI | `.agents/skills/<name>/` | `~/.agents/skills/<name>/` |
|
|
384
|
+
| Cursor | `.cursor/skills/<name>/` (also reads `.agents/skills/`) | `~/.cursor/skills/<name>/` |
|
|
385
|
+
| Antigravity | `.agents/skills/<name>/` | `~/.gemini/config/skills/<name>/` |
|
|
386
|
+
|
|
387
|
+
Codex CLI and Antigravity share the project path, so installing for one covers both.
|
|
388
|
+
|
|
389
|
+
### Fallback: MCP server (for tools without Agent Skills support)
|
|
390
|
+
|
|
391
|
+
If your tool supports MCP but not Agent Skills, `mcp-server/` serves the same eight skills as MCP
|
|
392
|
+
tools. It reads `skills/` directly, so there's nothing to keep in sync.
|
|
393
|
+
|
|
394
|
+
```bash
|
|
395
|
+
cd mcp-server && npm install
|
|
396
|
+
```
|
|
397
|
+
|
|
398
|
+
Point your tool's MCP config at `node /path/to/spec-driven-dev/mcp-server/server.js` (stdio).
|
|
399
|
+
Each skill becomes a tool that returns its instructions, and supporting files are available as
|
|
400
|
+
`skill://<name>/<path>` resources. Prefer native skills support where your tool has it.
|
|
401
|
+
|
|
402
|
+
---
|
|
403
|
+
|
|
404
|
+
## Compatibility
|
|
405
|
+
|
|
406
|
+
| Skill | Claude Code | Codex CLI | Cursor | Antigravity | Notes |
|
|
407
|
+
|---|---|---|---|---|---|
|
|
408
|
+
| `spec-setup` | ✅ | ✅ | ✅ | ✅ | Reads git and project files, and writes one config file |
|
|
409
|
+
| `spec-investigate` | ✅ | ✅ | ✅ | ✅ | Fetches tickets via whatever access the tool has (Atlassian/Linear MCP, `gh`); otherwise asks you to paste the ticket. Files and text need nothing extra |
|
|
410
|
+
| `spec-create` | ✅ | ✅ | ✅ | ✅ | Planning and writing files only |
|
|
411
|
+
| `spec-implement` | ✅ | ✅ | ✅ | ✅ | Parallel agents and worktrees where the tool supports them; otherwise one task at a time |
|
|
412
|
+
| `spec-verify` | ✅ | ⚠️ | ⚠️ | ⚠️ | UI checks need browser automation; API and database checks work everywhere |
|
|
413
|
+
| `spec-checkpoint` | ✅ | ✅ | ✅ | ✅ | Plain git plus your repo's own check commands |
|
|
414
|
+
| `spec-ship` | ✅ | ✅ | ✅ | ✅ | git plus the GitHub CLI (`gh`) |
|
|
415
|
+
| `generative-seo` | ✅ | ✅ | ✅ | ✅ | Web search and writing files |
|
|
416
|
+
|
|
417
|
+
⚠️ = works, but one step depends on a capability your tool might not have. The skill tells you and
|
|
418
|
+
skips that step rather than failing.
|
|
419
|
+
|
|
420
|
+
---
|
|
421
|
+
|
|
422
|
+
## By the numbers
|
|
423
|
+
|
|
424
|
+
| Skill | Stage | SKILL.md lines | Words | Supporting files |
|
|
425
|
+
|---|---|---:|---:|---:|
|
|
426
|
+
| `spec-setup` | 0 · configure | 99 | 857 | 1 |
|
|
427
|
+
| `spec-investigate` | 1 · understand | 323 | 2,708 | 1 |
|
|
428
|
+
| `spec-create` | 2 · plan | 149 | 1,328 | 4 |
|
|
429
|
+
| `spec-implement` | 3 · build | 236 | 1,790 | 3 |
|
|
430
|
+
| `spec-verify` | 4 · prove | 153 | 1,459 | 1 |
|
|
431
|
+
| `spec-checkpoint` | 5 · commit | 106 | 762 | 0 |
|
|
432
|
+
| `spec-ship` | 6 · PR | 218 | 1,235 | 0 |
|
|
433
|
+
| `generative-seo` | standalone | 255 | 2,209 | 7 |
|
|
434
|
+
| **Total** | | **1,539** | **12,348** | **17** |
|
|
435
|
+
|
|
436
|
+
- **8** skills: **1** setup + **6** workflow stages + **1** standalone
|
|
437
|
+
- **4** tools supported natively (Claude Code, Codex CLI, Cursor, Antigravity), plus an MCP fallback
|
|
438
|
+
- **3** layouts: single repo, monorepo, multi-repo
|
|
439
|
+
- **1** install command, `npx @benjaminthomas/spec-driven-dev`, plus the Claude Code plugin and an MCP fallback
|
|
440
|
+
- **0** stack assumptions: lint, typecheck, test, build, and dev commands come from your repo
|
|
441
|
+
|
|
442
|
+
_The table is generated by `python3 scripts/check.py --fix`; CI fails if it goes out of date._
|
|
443
|
+
|
|
444
|
+
---
|
|
445
|
+
|
|
446
|
+
## Working on this repo
|
|
447
|
+
|
|
448
|
+
```
|
|
449
|
+
skills/<name>/SKILL.md the skill itself (frontmatter: name, description, license)
|
|
450
|
+
skills/<name>/references/ templates and prompts the skill loads when needed
|
|
451
|
+
.claude-plugin/ Claude Code plugin + marketplace manifests
|
|
452
|
+
.agents/skills/ symlinks so Codex/Antigravity pick the skills up inside this repo
|
|
453
|
+
bin/cli.mjs the npx installer + project setup (no dependencies)
|
|
454
|
+
package.json npm package (ships bin/ and skills/)
|
|
455
|
+
mcp-server/ MCP fallback server
|
|
456
|
+
hooks/hooks.json Claude Code session-start hook (runs `cli.mjs status`)
|
|
457
|
+
CHANGELOG.md what changed in each version
|
|
458
|
+
scripts/check.py consistency checks + metrics generator
|
|
459
|
+
scripts/test-cli.mjs installer self-test (fake HOME, throwaway repos)
|
|
460
|
+
evals/ `claude plugin eval` cases
|
|
461
|
+
```
|
|
462
|
+
|
|
463
|
+
- **Adding a skill:** create `skills/<name>/SKILL.md`, then add the name to the two manifests, a `.agents/skills/<name>` symlink, the `STAGES` map in
|
|
464
|
+
`scripts/check.py`, and this README. `python3 scripts/check.py` lists anything you missed.
|
|
465
|
+
- **Before pushing:** run `python3 scripts/check.py --fix`. CI (`.github/workflows/check.yml`) runs
|
|
466
|
+
the same checks, the installer self-test, and a syntax check on the MCP server.
|
|
467
|
+
- **Evals:** `claude plugin eval . --runs 1` checks that skills trigger on their phrases and stay
|
|
468
|
+
within their own stage. These runs use your Claude credentials, so they aren't part of CI.
|
|
469
|
+
- **Skill rules** (from [Anthropic's skill authoring guide](https://platform.claude.com/docs/en/agents-and-tools/agent-skills/best-practices),
|
|
470
|
+
enforced by `scripts/check.py`):
|
|
471
|
+
- Names are lowercase with hyphens.
|
|
472
|
+
- Descriptions are 1,024 characters or fewer, in the third person, and say both what the skill
|
|
473
|
+
does and when to use it.
|
|
474
|
+
- `SKILL.md` stays under 500 lines, with detail in `references/` one link deep.
|
|
475
|
+
- Facts are read from the repo, not assumed.
|
|
476
|
+
- **Releasing:**
|
|
477
|
+
1. Increase `version` in both `package.json` and `.claude-plugin/plugin.json` (the check fails if
|
|
478
|
+
they differ).
|
|
479
|
+
2. Add a `CHANGELOG.md` entry.
|
|
480
|
+
3. Push, then `npm publish`.
|
|
481
|
+
|
|
482
|
+
## License
|
|
483
|
+
|
|
484
|
+
MIT. See `LICENSE`.
|