Skill · Workflow
spec-to-tickets
Grills a feature idea with recommended answers, pauses for you to confirm or correct them, writes a spec with numbered acceptance criteria, splits it into vertical-slice tickets in parallel, checks that every criterion is covered and every ticket is small and testable, and exports for your tracker. Use when asked to run the "Feature idea to spec and tickets" workflow.
The skill itself. Agents read the name and description first and load the rest only when a task matches.
spec-to-tickets/SKILL.md
---
name: spec-to-tickets
description: Grills a feature idea with recommended answers, pauses for you to confirm or correct them, writes a spec with numbered acceptance criteria, splits it into vertical-slice tickets in parallel, checks that every criterion is covered and every ticket is small and testable, and exports for your tracker. Use when asked to run the "Feature idea to spec and tickets" workflow.
---
# Feature idea to spec and tickets
Grills a feature idea with recommended answers, pauses for you to confirm or correct them, writes a spec with numbered acceptance criteria, splits it into vertical-slice tickets in parallel, checks that every criterion is covered and every ticket is small and testable, and exports for your tracker.
## Inputs
Ask for any of these that the user hasn't given:
- `idea` (e.g. "Let teams share a prompt collection with a public link that anyone can view and copy from")
- `users` (e.g. "Workspace owners who curate prompts; visitors without an account")
- `constraints` (e.g. "Ship in 2 weeks with 1 engineer. No new paid services. Must not expose private prompts.")
- `stack` (e.g. "Next.js App Router, Postgres with Drizzle, Better Auth, Vercel")
- `codebase_notes` (e.g. "Collections live in src/lib/collections. Prompts have visibility PRIVATE | WORKSPACE | PUBLIC. Paste README or schema excerpts here.")
- `answers` (e.g. "Leave blank on the first run. On a re-run: 1. Links never expire. 3. Owners can revoke a link.")
- `ticket_format` (e.g. "CSV")
## Steps
Run the steps in order. Refer to saved results by name. Don't skip a step that says STOP.
1. **Manual start** — Start: Start with {{idea}}. Add {{users}}, {{stack}}, {{constraints}} and any {{codebase_notes}}. Leave {{answers}} blank on the first run; set {{ticket_format}} to CSV or markdown.
2. **Grill the plan** — Interview the plan for {{idea}} for {{users}}, built on {{stack}}, within {{constraints}}. Code notes (may be blank): {{codebase_notes}}. Don't ask anything the notes already answer.
This step can't wait for replies, so write the whole interview at once. Cover every open design branch: scope of the first version, users and permissions, data model and ownership, states and edge cases (empty, duplicate, concurrent edits, deletes), errors and limits, migration of existing data, non-goals, rollout, and how success is measured. For each: one question, why it matters (what changes in the build depending on the answer), and your recommended answer with a one-line reason. Order the questions so earlier answers settle later ones. 12 questions max, numbered.
Answers from an earlier run (may be blank): {{answers}}
Treat answered branches as resolved and quote the answer; only ask what's still open. End with 'Decisions so far': each decision marked 'user' or 'default (unconfirmed)'. Save the result as `questions`.
3. **Answer or accept the defaults** — STOP and ask the user to approve before continuing: Read the questions and recommended answers. If any recommendation is wrong, reject, paste your numbered answers into the answers variable and run again. Approve to write the spec from your answers plus the recommended defaults.
4. **Write the spec** — Write the spec for {{idea}} from the decisions in {{questions}}. Sections:
1. Problem: 3 sentences max, whose problem and what it costs them
2. Goals (measurable) and non-goals
3. Decisions: each marked 'user' or 'default (unconfirmed)'
4. Glossary: each domain term in one line
5. User stories, numbered US-1, US-2…: 'As a … I want … so that …'
6. Acceptance criteria, numbered AC-1, AC-2…, in Given/When/Then, each linked to a story, covering the edge cases from the interview
7. Data and API changes, in terms of {{stack}} and the code notes
8. Open risks and unknowns, each with how to settle it
Every acceptance criterion must be checkable by a test or by a person clicking through. Don't add features the decisions didn't cover. Keep the spec under 1,200 words and at most 15 acceptance criteria; merge overlapping ones. Save the result as `spec`.
5. **Split into tickets** — Launch these as parallel subagents in one message, then wait for all of them. Split {{spec}} into tickets for your part only. Each ticket is a vertical slice: it changes whichever layers it needs (data, API, UI) so something works end to end and can be demoed or tested. For each ticket give: an ID with your lane's prefix, title, the outcome a user or tester can see, ACs covered (by number), in scope and out of scope, blocked by (ticket IDs), size S (under a day) or M (1-3 days), and the first test to write. At most 5 tickets, each under 100 words. Anything bigger than M must be split. Don't write tickets for another lane's part. Save the result as `tickets`.
- **Core path (prefix C)**: The thinnest end-to-end version first (a walking skeleton), then the main user stories.
- **Edge cases (prefix E)**: Empty, invalid, duplicate, concurrent and permission cases, plus error handling and limits from the acceptance criteria. Assume the core tickets exist and list them as blockers by description if you don't know their IDs.
- **Rollout (prefix R)**: Migrations or backfills, the feature flag, analytics for the goals, docs, and removing the flag afterwards. Each ticket must ship on its own.
6. **Merge and order** — Merge the lanes in {{tickets}} into one backlog of at most 12 tickets (merge or drop the least important if there are more). Keep each ticket under 100 words. Remove duplicates, renumber as T-01, T-02… so every ticket comes after the tickets that block it, and update 'blocked by' to the new IDs. Keep each ticket's lane (core, edge-case, rollout). Then add:
- A coverage table: every AC from {{spec}} with the tickets that cover it; mark uncovered ACs 'MISSING'.
- A dependency list in the form T-03 -> T-05.
- A final section titled 'Acceptance criteria' that lists every AC from the spec by number with a one-line summary, for the review step. Save the result as `tickets`.
7. **Critic review** — Review loop (max 2 passes): Pass only if all of these hold:
1. Every AC in the 'Acceptance criteria' section at the end is covered by at least one ticket in the coverage table, and none is marked MISSING.
2. No ticket is bigger than M (3 days).
3. Every ticket's outcome is observable: a user, tester or automated test can see it work. 'Set up X' or 'backend for Y' alone fails unless another ticket depends on it as infrastructure.
4. 'Blocked by' lists only existing ticket IDs with lower numbers, there are no cycles, and T-01 has no blockers.
5. Every ticket names the first test to write.
6. No ticket adds scope that no AC asks for.
In feedback, list only the ticket IDs and the rule each breaks (one line each), and tell the reviser to change only those tickets, keep everything else word for word, keep the 'Acceptance criteria' section unchanged and update the coverage table to match. Save the result as `tickets`.
8. **Export for your tracker** — Export {{tickets}} as {{ticket_format}}; if it's blank, use markdown.
CSV: header Title,Description,Acceptance Criteria,Estimate,Blocked By,Labels; one row per ticket in order; Description holds the outcome, scope and first test; Estimate is 1 for S and 3 for M (days); Labels include the lane (core, edge-case, rollout); every field double-quoted with inner quotes doubled. 'Blocked By' imports as text in most trackers, so link dependencies after import.
Markdown: one checklist item per ticket in order, with its ACs, size and blockers underneath.
Return only the export. Save the result as `export`.
9. **Sign off** — STOP and ask the user to approve before continuing: Check the decisions marked 'default (unconfirmed)' in the spec and the ticket order. Approve to export the spec and tickets; reject to stop.
10. **Save spec and tickets** — Finish: Return {{spec}}, {{tickets}} and {{export}}.
## Done when
Every step has run, each approval was given, and you've reported what was produced and where it was saved.