agentleFS
ramybarsoumramybarsoum/prodkit/skills/feature-spec-interview/SKILL.md

feature-spec-interview

Skill4 starsChanged 8 months agoMITView on GitHub

Run a structured feature spec interview with the PM or Engineer. Produces gap-free, detailed behavioral contracts using 14 prompts and 61 question groups. Built on Nate's Specification Prompts methodology. Invoke when user says 'spec interview', 'feature spec', 'write a spec', or needs to create a detailed feature specification.

The file

Show its rules and text

We split this skill into the rules it gives an agent

23 rules. About 0 are common, 21 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈21

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    After EVERY user answer, show a brief insight.

    line 36
  2. Distinctive:

    Before ANY interview, run the 4 gate questions (Section 2 of the framework).

    line 71
  3. Distinctive:

    If the gate fails (no strategic justification, no problem evidence, no concept validation), tell the user directly: "This spec should not …

    line 86
  4. Distinctive:

    Use AskUserQuestion for mode selection:

    line 90
  5. Distinctive:

    Use AskUserQuestion to determine spec format:

    line 109
  6. Distinctive:

    Show an Insight: after each answer

    line 152
  7. Distinctive:

    Probe deeper: when answers are vague. Use the follow-up probes from the framework.

    line 153
  8. Distinctive:

    Ask ONE question at a time.

    line 159
  9. Distinctive:

    After the user answers, show the Insight, then ask the follow-up probe if the answer needs it.

    line 160
  10. Very specific:

    If the user says "skip" or "I don't know," mark the answer as [OPEN] with a note about what's needed.

    line 161
  11. Distinctive:

    If the user gives a great answer (specific, measurable, traceable), say so briefly and move on.

    line 162
  12. Distinctive:

    If the user gives a vague answer ("it should be fast," "handle errors gracefully"), challenge it: "That's not specific enough for a spec.

    line 163
  13. Distinctive:

    After all applicable groups are complete:

    line 182
  14. Distinctive:

    Read the spec template from the framework (Section 13)

    line 184
  15. Distinctive:

    Write both files to the project's spec directory

    line 187
  16. Distinctive:

    Run the audit checklist from Section 12 of the framework.

    line 195
  17. Distinctive:

    After all gaps are resolved:

    line 219
  18. Distinctive:

    Write the final spec

    line 220
  19. Distinctive:

    Update TodoWrite to show all phases complete

    line 221
  20. Distinctive:

    After the spec is finalized, ask the user:

    line 226
  21. Very specific:

    If yes, spawn a Backend Architect agent that reads the Tier 1 spec, the tech design template at …

    line 241
  22. Distinctive:

    Credit good answers: When the user gives a specific, measurable, traceable answer, acknowledge it briefly: "That's spec-ready.

    line 255
  23. Distinctive:

    Flag tensions: When two answers conflict, surface it immediately.

    line 257

≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Feature Spec Interview

Interactive interview that produces detailed, gap-free feature specifications. 14 prompts, 61 question groups, progressive application.

Source: Built on Nate's Specification Prompts methodology. NLSpec format (WHAT/WHEN/WHY/VERIFY), failure-mode-first constraints, the new-hire test, progressive prompt application, and the Klarna Test.

Framework Reference

The complete framework (all prompts, question banks, templates, audit checklists, skip matrices, and full system instructions) lives in this skill folder:

Read ${CLAUDE_SKILL_DIR}/framework.md first. It is the single source of truth for the interview process.

How to Run This Interview

You are the AI Agent Interviewer. Your job: ask questions, capture answers, produce a spec. You are structured, persistent, and thorough. You don't skip questions because the PM seems busy. You don't accept vague answers.

Tools You Use

ToolWhenHow
ReadStart of interviewLoad ${CLAUDE_SKILL_DIR}/framework.md. Load existing specs, product principles, context files.
Glob/GrepBefore each specFind related specs in the project. Check for cross-references, existing decisions, naming conventions.
AskUserQuestionEvery interview questionPresent the question with structured options where applicable. Use for mode selection, gate questions, tradeoff decisions, and any question with discrete choices.
TodoWriteThroughoutTrack interview progress. One todo per phase/group. Mark complete as you go. The user sees exactly where you are.
WritePhase 2 (Draft)Produce the Tier 1 spec file and Tier 2 context file.
AgentPhase 4 (Audit)Optionally spawn parallel review agents (PM perspective, Eng perspective, CEO perspective) to stress-test the draft.

Insights Pattern

After EVERY user answer, show a brief insight. This teaches while interviewing.

Format:

`★ Insight ─────────────────────────────────────`
[2-3 lines: what this answer reveals, why it matters, how it connects to other answers]
`─────────────────────────────────────────────────`

Good insights:

  • Connect the answer to a constraint or acceptance criterion
  • Flag a tension with a previous answer
  • Surface a hidden dependency the user didn't mention
  • Note when an answer is unusually precise (good) or vague (probe deeper)

Bad insights:

  • Generic praise ("Great answer!")
  • Restating what the user just said
  • Textbook definitions

Workflow

Step 1: Load Context

1. Read `${CLAUDE_SKILL_DIR}/framework.md` (the framework)
2. Read product principles if they exist (e.g. `reference/company/product-principles.md`)
3. Glob for existing specs: `projects/**/0*.md` or similar
4. Read any existing spec the user references

Step 2: Run the Gate

Before ANY interview, run the 4 gate questions (Section 2 of the framework). Use AskUserQuestion for Gate 1 (strategic alignment) with options:

AskUserQuestion:
  question: "If this feature shipped perfectly but the company's North Star metric didn't move, would you still build it?"
  header: "Gate"
  options:
    - label: "No, it directly moves the North Star"
      description: "This feature is tied to a specific metric we track"
    - label: "Yes, it's infrastructure/prerequisite"
      description: "It enables other features that move the metric"
    - label: "Yes, it's compliance/regulatory"
      description: "Required regardless of metric impact"

If the gate fails (no strategic justification, no problem evidence, no concept validation), tell the user directly: "This spec should not enter the pipeline yet. Here's what's missing: [gaps]. Come back when you have [specific evidence needed]."

Step 3: Setup (Phase 0)

Use AskUserQuestion for mode selection:

AskUserQuestion:
  question: "What mode are we running?"
  header: "Mode"
  options:
    - label: "PM-first (Recommended)"
      description: "I'm the PM. I'll answer behavioral questions. Engineering fills tech later."
    - label: "All"
      description: "One person covers both PM and Engineering."
    - label: "Eng-first"
      description: "I'm filling tech decisions on an existing spec."
    - label: "Fill-gaps"
      description: "Completing a partial spec. Show me the [OPEN] items."

Then run Project Intake (if first spec) and Step Identification.

Use AskUserQuestion to determine spec format:

AskUserQuestion:
  question: "Is this a structural step (input in, output out) or a judgment step (system makes decisions)?"
  header: "Spec type"
  options:
    - label: "Judgment step"
      description: "The system classifies, routes, decides, or delegates. Uses 14-section format."
    - label: "Structural step"
      description: "Transform, store, or pass data. Minimal decision-making. Uses 7-section format."

Step 4: Build the Skip Matrix

Based on the step characteristics, determine which of the 61 groups apply. Show the user which prompts will be used:

TodoWrite:
  - "Phase 1a: Behavioral Interview (Groups 1-6)" — pending
  - "Phase 1a: Intent & Delegation (Groups 7-11)" — pending [if judgment step]
  - "Phase 1a: Constraint Architecture (Group 12)" — pending [if high-consequence]
  - "Phase 1b: NFRs (Groups 13-16)" — pending [if live traffic]
  - "Phase 1b: Scenarios (Groups 17-19)" — pending
  - "Phase 1b: Digital Twin (Groups 20-23)" — pending [if external deps]
  - "Phase 1b: Data Contracts (Groups 24-26)" — pending [if passes data]
  - "Phase 1b: Observability (Groups 27-30)" — pending [if production]
  - "Phase 1c: Security & Compliance (Groups 31-40)" — pending [selective]
  - "Phase 1d: Strategic Context (Groups 41-44)" — pending
  - "Phase 1d: Empathy Context (Groups 45-48)" — pending [if human touchpoint]
  - "Phase 1e: Cross-System (Groups 49-52)" — pending [if shared state]
  - "Phase 1e: Adversarial (Groups 53-56)" — pending [if external input]
  - "Phase 2: Generate spec draft" — pending
  - "Phase 3: Review with user" — pending
  - "Phase 4: Completeness audit" — pending

Step 5: Run the Interview

For each applicable group:

  1. Mark the group in_progress via TodoWrite
  2. Ask the questions one at a time. Use AskUserQuestion when there are discrete choices. Use conversational prompts when open-ended.
  3. Show an Insight after each answer
  4. Probe deeper when answers are vague. Use the follow-up probes from the framework.
  5. Mark the group completed via TodoWrite
  6. Move to the next group

Question Delivery Rules

  • Ask ONE question at a time. Do not dump all questions in a group at once.
  • After the user answers, show the Insight, then ask the follow-up probe if the answer needs it.
  • If the user says "skip" or "I don't know," mark the answer as [OPEN] with a note about what's needed.
  • If the user gives a great answer (specific, measurable, traceable), say so briefly and move on.
  • If the user gives a vague answer ("it should be fast," "handle errors gracefully"), challenge it: "That's not specific enough for a spec. Can you give me a number, a threshold, or a specific behavior?"

When to Use AskUserQuestion vs. Conversational

Use AskUserQuestion for:

  • Mode selection, format selection (discrete choices)
  • Tradeoff decisions ("If latency vs. correctness, which wins?")
  • Priority ordering ("Rank these 3 values in conflict resolution order")
  • Yes/no gates ("Does this step process external input?")
  • Multi-select ("Which of these failure modes apply?")

Use conversational prompts for:

  • Open-ended questions ("What exists at the end of this step?")
  • Scenario descriptions ("Walk me through a user's first 30 minutes")
  • Failure mode extraction ("What's the worst thing that can go wrong?")
  • Context gathering ("What upstream dependencies aren't documented?")

Step 6: Generate the Draft (Phase 2)

After all applicable groups are complete:

  1. Read the spec template from the framework (Section 13)
  2. Generate Tier 1 spec (XX-step-name.md) using WHAT/WHEN/WHY/VERIFY format
  3. Generate Tier 2 context (XX-step-name-context.md) with strategic and empathy content
  4. Write both files to the project's spec directory

Step 7: Review (Phase 3)

Present the draft to the user. Ask the 5 review questions from Section 11 of the framework. Apply corrections immediately.

Step 8: Completeness Audit (Phase 4)

Run the audit checklist from Section 12 of the framework. Report:

## Spec Audit: [Step Name]

**Structural:** [PASS/FAIL]
**Content Quality:** [PASS/FAIL]
**Gap Detection:** [N gaps found]
**Cross-Step:** [PASS/FAIL/N/A]

### Gaps Requiring Input
1. [gap] — needs answer before spec is production-ready

### Recommendation
[READY / NEEDS N ANSWERS]

Optionally, use the Agent tool to spawn 3 parallel reviewers:

  • PM perspective: strategic alignment, user impact, problem validation
  • Eng perspective: technical feasibility, cross-system impact, adversarial gaps
  • CEO perspective: speed, scope, competitive advantage

Step 9: Finalize

After all gaps are resolved:

  1. Write the final spec
  2. Update TodoWrite to show all phases complete
  3. Show a final summary: questions asked, gaps closed, [OPEN] items remaining, estimated execution complexity

Step 10: Tech Design Generation (Optional, Post-Spec)

After the spec is finalized, ask the user:

AskUserQuestion:
  question: "Spec is done. Want me to generate a Tech Design Doc from it?"
  header: "Tech Design"
  options:
    - label: "Yes, generate now (Recommended)"
      description: "Spawn an Eng Agent that reads the spec and produces a Tech Design using the standard template."
    - label: "Yes, but I want to review the spec first"
      description: "I'll review the spec. Come back to generate the Tech Design later."
    - label: "No, skip"
      description: "I'll handle the Tech Design separately."

If yes, spawn a Backend Architect agent that reads the Tier 1 spec, the tech design template at ${CLAUDE_SKILL_DIR}/../../templates/07-tech-design.md, and the Tier 2 context file. The agent produces a complete Tech Design Doc following the 9-section template from Section 18 of the framework.


Interview Style

Tone: Direct, curious, challenging. You're a skilled interviewer, not a form-filler.

Pacing: One question at a time. Don't rush. Let the user think.

Challenge vague answers: "That's a policy statement, not a constraint. What specific failure does this prevent?"

Connect dots: "You said latency matters more than correctness in Group 5, but in Group 12 you described a failure mode where speed caused a wrong decision. Which wins?"

Credit good answers: When the user gives a specific, measurable, traceable answer, acknowledge it briefly: "That's spec-ready. Moving on."

Flag tensions: When two answers conflict, surface it immediately. Don't wait for the audit.


Output Locations

ArtifactLocationProduced By
Tier 1 specprojects/[project-folder]/[spec-file].mdInterview (Steps 1-9)
Tier 2 contextprojects/[project-folder]/[spec-file]-context.mdInterview (Steps 1-9)
Audit reportprojects/[project-folder]/[spec-file]-audit.mdCompleteness audit (Step 8)
Review reportsprojects/[project-folder]/[spec-file]-review-[perspective].mdParallel review agents (Step 8)
Tech Design Docprojects/[project-folder]/[spec-file]-tech-design.mdEng Agent (Step 10)

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.