spec-impl
Implements an approved spec. Validates that the state means "Approved" (in any language), creates a git branch named after the…
Designs and develops specs following the spec-driven method. Asks clarifying questions before proposing structure, and builds the spec section by section. Use it when starting a large feature, before writing code.
$ npx -y skills add klerith/fernando-skills --skill spec --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/specContext preview
The summary Claude sees to decide when to auto-load this skill.
Designs and develops specs following the spec-driven method. Asks clarifying questions before proposing structure, and builds the spec section by section. Use it when starting a large feature, before writing code.
name: spec description: Designs and develops specs following the spec-driven method. Asks clarifying questions before proposing structure, and builds the spec section by section. Use it when starting a large feature, before writing code. disable-model-invocation: true argument-hint: 'short feature description or requirement' allowed-tools: Read, Glob, Grep, Write, AskUserQuestion, Bash(ls:*), Bash(cat:*), Bash(date:*)
Today's date (use this for the spec header, never guess it): !`date +%F`
Specs that already exist: !`ls specs/ 2>/dev/null || echo "The specs/ folder does not exist yet"`
---
This skill helps you produce a useful spec following the spec-driven method. **You don't write code here.** Your job is to help the user clarify what they want to build, ask questions when something is not well-defined enough, and develop the spec section by section until it is ready to be saved into `specs/`.
A spec is not decorative documentation. It is the contract that drives later execution. If the spec is vague, the code will improvise. That is why this flow is **deliberately slow during the definition phase** and **fast during the writing phase**.
Read `template.md` (in the same directory as this skill) to see the full structure the spec will follow. Lean on it at every step.
Before asking questions about the feature, make sure you have project context:
1. Read the project-memory file, if one exists. Try in order and stop at the first hit: `CLAUDE.md`, `AGENTS.md`, `GEMINI.md`, `README.md`. This adapts the skill to whichever agent is running it (Claude Code, Codex, Gemini CLI, etc.). 2. Look at the `specs/` listing in the session context above to see which specs already exist and how they are numbered. 3. If previous specs exist, read at least the two most recent ones to pick up the project's conventions — including the **language** they are written in and the exact wording they use for states and section headings. A new spec must match the existing ones.
If the `$ARGUMENTS` argument comes in empty, ask the user for an initial **single-sentence** description of what they want to build. If the description does not fit in one sentence, that is the first signal that the feature is too big — suggest splitting it before continuing.
This is the most important phase of the command. Your job here is to **detect ambiguities and ask**, not to assume.
Ask questions in blocks of 3 to 5 at a time (not one single question followed by another single question — that is exhausting). After each block, wait for an answer before continuing.
**Question categories you should always consider:**
**How to phrase the questions:**
**When to stop asking:**
Stop when you can answer these three questions without assuming anything:
1. Which files will appear or change? 2. What is the first executable step and what is the last one? 3. How do I verify the feature is finished?
If you still cannot answer one of them, keep asking.
Once Phase 2 is closed, decide how to write it:
**If you already have all the information you need** — meaning you can answer the three Phase 2 questions (which files change, what the first and last executable steps are, how to verify it is finished) **without assuming anything** — then **do not go section by section**. Write the complete spec and jump straight to Phase 4 to save the file. Do not ask for section-by-section confirmation, and do not show a draft for approval first: the user already answered everything in Phase 2, and re-asking is friction. The user reviews the saved file and asks for changes if needed.
**Only if information is still missing** (the user cut Phase 2 short, an answer was vague, or some section cannot be written without inventing something), develop the sections **one by one**, showing each one and waiting for confirmation before moving to the next.
In both cases the content follows the same order:
1. **Header** (st
Spec-driven development skills for Claude Code, Cursor, Codex, and Antigravity. By Fernando Herrera.