Skip to content

Spec lifecycle

How a feature specification under specs/ moves from draft to closed, how closed specs are marked, and how the index at specs/README.md is kept true. This page is the reference the constitution's Principle II (spec-driven development) and CLAUDE.md point to. Adopted 2026-10-30.

Why metadata, not moves

Spec Kit identifies a feature by its directory: specs/NNN-feature-name/. The scripts in .specify/scripts/bash/ allocate the next number from the highest NNN- prefix present under specs/ and resolve a feature branch to its directory by that prefix. Moving a finished spec out of specs/ would make the next /speckit-specify reuse its number and would break every specs/NNN reference in ADRs, other specs and CLAUDE.md.

So directories are never moved, renamed or renumbered. A spec's lifecycle state lives in its header, and the index is generated from the headers.

The header

Every spec.md carries these lines near the top, in this order, each on one line:

**Status**: <Word> (<YYYY-MM-DD>). <One sentence: what the word means for this spec right now.>
**In flight**: <branch, PR or session holding it>      ← optional; present only while someone works on it
**Release**: <version it shipped in or targets>         ← optional

<Word> is one of the fixed vocabulary. The date is when the word last changed. The sentence is free text and may go on to say more, but the index shows only the first sentence.

Word Meaning Typical next
Draft Written; open questions remain. /speckit-clarify has not finished. Clarified, Withdrawn
Clarified Open questions answered; no plan yet. Planned
Planned plan.md (and usually tasks.md) exist; no code has landed. Active, Parked
Active Code is landing against it. The spec is the authority for that work. Done, Superseded, Parked
Done Every requirement that was going to ship has shipped; release gates named in the spec have run. —
Superseded by NNN Its mechanism was replaced by spec NNN before or after completion. NNN says what it closed. —
Parked Still wanted; deliberately not being worked. The sentence names the condition that reopens it. Active, Withdrawn
Withdrawn No longer wanted. The sentence says why. Nothing reopens it; a new spec would be written instead. —

Done, Superseded, Parked and Withdrawn are closed. The other four are open.

Closing a spec

Closing is one small docs PR per spec or per related group:

  1. Set the status word and date. Write the sentence as evidence, not opinion: the merged PR numbers, the release, or the superseding spec and the requirement there that names this one (for example 022 FR-019).
  2. Add a short Closed block directly under the header: date, reason, and where the mechanism now lives (a code path, a later spec, an ADR). Three to six lines.
  3. If tasks.md exists, add one line at its top: > Closed <date> as <Word>; boxes below are as they were at closure. Do not back-fill boxes to make the file look finished.
  4. For Superseded, point both ways: the closed spec names the superseder in its status; the superseding spec lists what it closed (a requirement or a "Supersedes" section).
  5. Remove the **In flight** line.
  6. Regenerate the index (below) and commit it in the same PR.

Open specs change the same way: the word, the date, the sentence, and the **In flight** line whenever work starts or stops. Nothing else in a spec is lifecycle metadata.

The index and its check

specs/README.md is generated by scripts/specs/index.py from the headers. It lists open specs first (status, date, release, task boxes done/open, who holds it, the sentence) and closed specs after. Never edit it by hand.

python3 -I scripts/specs/index.py           # rewrite specs/README.md
python3 -I scripts/specs/index.py --check   # exit 1 on an invalid header or a stale README

The GitHub Actions workflow specs-index.yml runs --check on every pull request that touches specs/ or the script. A spec without a status line, with a word outside the vocabulary, without a date, or naming a superseder that does not exist fails the check, as does a README that no longer matches the headers.

Ownership across sessions

Several agents (local and cloud sessions, and people) work on specs at once. The **In flight** line is the shared truth for who holds a spec: set it when starting, clear it when the PR merges, and read it before editing a spec you did not open. Hand-offs within one thread still use the continuation files under .local/docs/continuations/ (see CLAUDE.md); the index is for coordination between threads.

What this does not change

  • The Spec Kit flow (/speckit-specify → /speckit-plan → /speckit-tasks → /speckit-implement) and the templates under .specify/templates/. The status line already exists in the template; only its vocabulary is fixed.
  • The constitution. Principle II already requires specs; this page is the operational detail it defers to.
  • Consensus-change routing, testing tiers, or anything about code.