Shape a new feature into one spec file (problem, outcome, scope, acceptance criteria, slices) by asking the person only the real choices, then stop for approval. Use only in a workspace whose instructions mention the spec skill; not for fixes or routine changes.
Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
SSkills DirectorySkills Directory
Is that skill safe to install?
Are you the author of Spec?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/madtocc-spec)
---
name: spec
description: Shape a new feature into one spec file (problem, outcome, scope, acceptance criteria, slices) by asking the person only the real choices, then stop for approval. Use only in a workspace whose instructions mention the spec skill; not for fixes or routine changes.
---
# Shaping a feature into a spec
A spec says what a feature must do and how it is cut into pieces of work, so the agents that build it don't have to guess.
You read first, ask the person only what the evidence can't settle, write one file, and stop. The person approves it in
Herdr's Specs view; after that the spec's slices become cards on the board.
## When to use it
- A new feature, or a change big enough that two reasonable people would build it differently: yes.
- A fix, a refactor, a routine change, or a card that already names a spec (`spec:` on the card): no. Build it.
- A card with `shape: skip`, or a person who says "just build it": no.
- Your workspace's instructions don't mention this skill: it does not apply there.
If unsure, ask the person one question: "Shape this into a spec first, or build it as asked?" with your recommendation.
## 1. Read before you ask
Facts are looked up, never asked. Before the first question, read:
- The workspace's `AGENTS.md` and the rules it names. Project rules win over this skill where they differ.
- The decisions in force: `herdr-ws-spec list`, then `herdr-ws-spec show <id>` for each one the feature touches. A decision in
force is a constraint, not a question. If the feature needs to go against one, that is a question (and later a
replacement, see the `decision` skill).
- The specs already there: `herdr-ws-spec spec list`. Don't shape twice what another spec covers; extend it or say so.
- The documents the person named (`herdr-ws-spec docs` lists the workspace's), and the code the feature touches: what
exists today, where it would go, what it would change.
- If your instructions name a linked spec project in another tool, read the parts the feature touches there, the way the
instructions say. Point to it from the spec; don't copy it in.
## 2. Start the file
Run `herdr-ws-spec spec new "<title>" [--documents <name>,<name>]`. It writes the spec's file with status `shaping`, in the
place the workspace keeps specs (in a repo on a branch of its own, or in the workspace's own folder), and prints its id and
path. In a repo, run it where you are: on a `spec/` branch it writes there; anywhere else (the main checkout, a card's
worktree) it makes the branch `spec/<slug>` in a new worktree and prints that folder. Edit the file there and run the
later `herdr-ws-spec` commands from there, so the spec and its decisions are committed on that branch, never on main.
Everything you learn goes into that one file from now on. Its shape is in `references/spec-template.md`; keep its
headings.
Fill in what you already know from step 1: the Problem as you understand it, the decisions it builds on, the documents.
## 3. Ask only the real choices
Find what is open with this checklist, silently: scope (what's in, out, later), the data it keeps, the flows and their
empty and error states, limits, the systems it talks to, edge cases (invalid input, nothing there, too much, no permission,
two at once, interrupted, repeated, out of order), the words it uses, and how anyone will know it is done.
Ask only what changes the scope, a decision or a criterion. Don't ask what the code, the documents or the decisions answer.
"It looks simple" is not evidence.
The format, in `references/questions.md` with an example:
- Rounds of at most four questions. Ask only questions whose own prerequisites are settled.
- Number them across the whole interview (the second round starts at 5), so an answer like `5=B` is never ambiguous.
- Each question: a plain full question ending in `?`; one "Why it matters" line (what it decides, what happens today);
2 to 4 options, each with its effect and its cost; exactly one marked `(Recommended)` with one line of why. Other answers
are welcome.
- Tell the person how to answer: `1=B, 3=A`, or in their own words.
- Before you send a round, write its questions under `## Open questions` in the spec, one line each with its number and
your recommendation. Herdr's Specs view shows them there, and the file stays the record if the conversation is lost.
- If your agent has a question tool, you may put the same questions through it, with the same numbers, options and
recommendation. Otherwise the message is the round: send it and stop until the person answers.
Hearing the answers:
- Only an explicit choice settles a question. "yes" or "recommended" for one question chooses its recommendation. Silence
does not: an unanswered question stays open and is never settled to the recommendation.
- Answers that come from another agent (an orchestrator or a second opinion, through `hc` or your task) are the person's
choices only when that agent says the person asked it to answer for them. Then write who answered on each line,
`- Q<n>: <question> → <answer> (answered by <agent> for <person>)`. Otherwise its answers are advice: put them to the
person as your recommendation and wait. Either way only the person accepts the spec, in Specs; no agent answers that.
- "Whatever you think" is asked again as a choice between two.
- A question back ("what does B mean?") means explain first, then ask again.
- After each round, write every answer into the spec at once: one line `- Q<n>: <question> → <answer>` under
`## Clarifications`, under today's date, take the question off `## Open questions`, and edit the section the answer
changes, removing what it contradicts. Then
show a short ledger in your reply: settled, still open.
Stop asking when the spec can be written correctly: when you could predict the next answers. Twenty questions is a
ceiling, not a goal. What is still open then goes under `## Open questions`, each with its recommendation.
## 4. Write the spec
One file, the sections of `references/spec-template.md`:
- **Problem**: who has it, what they do today, what changes for them.
- **Outcome**: the smallest end-to-end behaviour that solves it. Slice 1 delivers it.
- **Scope**: In, Out, Later. Out records the person's choice, never a way to make the work smaller.
- **Decisions**: the ids it builds on; the ids it proposes; small choices settled here with a one-line reason.
- **Acceptance criteria**, under that exact heading, numbered `1.`, `2.`: each an observable behaviour through the
product's own screens, commands or files, specific enough that two people would agree it is met. P0 unless the person
said otherwise. No "tests pass", coverage or definition-of-done lines. Given/When/Then is allowed, not required.
- **Quotes**: where a criterion rests on a document, quote the line under it, word for word:
`> [doc:checkout-prd.md] "the exact line"`. Copy it as the file has it, Markdown marks included; never paraphrase
inside the quote. A PDF or Word file can't be checked: quote a text copy of it.
- **Failure cases to check**: condition → what must happen.
- **Slices**: a table, one row per piece of work that can be built and checked on its own: what it delivers, its repo,
which slices it depends on, which criteria it meets. Every criterion belongs to exactly one slice. No cycles. Slice 1
reaches the Outcome end to end. Slices that don't depend on each other can run side by side. The table has no Card
column: a spec goes on the board as one card, and each slice's progress is a row of that card's `## Slices` table.
- **Surface**, only when the feature adds a command, a file format or an API others call: show it as if shipped, each
example with its output.
Technical design beyond that belongs to the agent that builds each slice, not to the spec.
## 5. Propose the decisions it needs
For each choice in the spec that rules out an alternative someone would reasonably pick later, propose a decision with the
`decision` skill (`herdr-ws-spec new`), and put its full id on the `- Proposes:` line under the spec's `## Decisions`
(the decisions it builds on go on `- Builds on:`): the person can't accept the spec while one it proposes is still
proposed. A routine choice goes on `- Settled here:` with its one-line reason. If the spec narrows the Problem the person gave you, say so in Clarifications
with their answer.
## 6. Check, then stop
Run `herdr-ws-spec spec propose <id>`. It checks that every quote is found in its document, that every criterion is in
exactly one slice, that the slices have no cycle and that no placeholder is left; then it sets the spec to `proposed`. If it
prints problems, fix them and run it again. Also check yourself that no decision in force is contradicted (or a replacement
is proposed) and that no vague word ("fast", "simple", "as needed") is left in a criterion.
Then stop. Say what you wrote (the spec's id, the decisions you proposed, the open questions) and wait. Don't build
anything, don't create cards, and never run `spec accept`, `spec decline` or pass `--me`. The person answers in Specs:
- **accepted**: you are done, unless the message asks you to put it on the board; then run
`herdr-ws-spec spec cards <id>` and say which card it used. A spec is one board card, never a card per slice: the
card you shaped the spec from gets a `## Slices` table with a row per slice (name another with `--card <card id>`;
a spec not shaped from a card gets a new one). If you're asked to build it (its card's Build slices…, the person in
chat), begin each slice with `herdr-ws-spec spec start <id> <slice>` (it puts the spec on the board first when it
isn't), have each of its criteria answered with `herdr-ws-spec spec review`, and end it with
`herdr-ws-spec spec done <id> <slice>`. Those two keep the slice's row and the card's `status:`; don't edit them by
hand.
- **changes asked**, with their sentence: revise the same file, run `spec propose` again, and stop.
- **declined**: stop; don't build on it.
A spec waits for the decisions it proposes: the person can't accept it while one of them is still proposed.
A spec isn't built before it is accepted. Asked to build one that is shaping or proposed, don't: say it waits for the
person's Accept in Specs, and stop. `spec start` and `spec done` refuse it too.
If you were told how to report back (a line in your task, or a task that came through `hc`), report once, when you're done
or stuck: the spec's id and path, the decisions you proposed, the open questions.
## Later, when the spec changes
- A quoted line gone from its document: read what the document says now, then update the quote, or the criterion if its
meaning changed. Run `spec propose` again; the spec waits for the person again.
- Never edit an accepted spec to change what it asks for without the person: change it, run `spec propose`, and stop.