skills/user-story/SKILL.md
Generate hierarchical user stories (epics, features, tasks) with formal Given/When/Then acceptance criteria. Works from brainstorm output or standalone. Produces structured requirements that feed directly into create-plan. Triggers on "create user stories", "write stories", "define requirements", "user story", or when presenting features that need requirements decomposition.
npx skillsauth add mhylle/claude-skills-collection user-storyInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
This skill generates hierarchical user stories (epics → features → tasks) with formal Given/When/Then acceptance criteria. It works in two modes: consuming brainstorm output for rich context, or standalone with its own clarification phase. Task-level stories share format with create-plan phases for seamless handoff.
Workflow Position: brainstorm → (ADRs + user stories) → create-plan → implement-plan
Related ADRs:
When this skill is invoked, respond:
"I'm ready to help you define user stories. I can work from a brainstorm document or start fresh. Let me check for recent brainstorms, or you can describe the feature/system you want to define requirements for."
Determine the input mode and gather initial context.
Step 1: Check for explicit brainstorm path
If the user passed a file path argument ($0):
Read($0) # Read the brainstorm file
→ Proceed to Phase 2 with brainstorm content as context.
Step 2: Auto-scan for recent brainstorms
If no argument provided, scan for recent brainstorm files:
Glob("docs/brainstorms/*.md")
| Scenario | Action | |----------|--------| | Recent brainstorms found (last 7 days) | Present list and ask: "I found these recent brainstorms. Would you like to base user stories on one of them, or start fresh?" | | No recent brainstorms | Proceed to standalone mode (Phase 3) | | User selects a brainstorm | Read the file, proceed to Phase 2 | | User wants to start fresh | Proceed to Phase 3 |
Step 3: Check for existing user stories
Always check for existing stories to avoid duplication:
Read("docs/user-stories/INDEX.md") # If it exists
If existing stories overlap with the current scope, note them and ask whether to extend, revise, or create new epics.
Gather all relevant context before generating stories.
Always do:
Read brainstorm output (if available from Phase 1)
Read existing ADRs for architectural context:
Read("docs/decisions/INDEX.md")
# Then Quick Reference (first 10 lines) of relevant ADRs
Read existing user stories INDEX (if it exists):
Read("docs/user-stories/INDEX.md")
When project context is detected (user mentions codebase, files, modules):
Task(subagent_type="codebase-locator",
prompt="Find all files related to [feature area]")
Task(subagent_type="codebase-analyzer",
prompt="Analyze how [related functionality] is implemented")
After gathering context, present a summary:
## Context Summary
- **Source**: [Brainstorm file / Standalone input]
- **Existing Stories**: [None / EPIC-01, EPIC-02...]
- **Relevant ADRs**: [ADR-NNNN, ...]
- **Codebase Context**: [Key files and patterns found]
Then proceed to Phase 3 if standalone, or Phase 4 if brainstorm input provides sufficient context.
When working without brainstorm input, use targeted Socratic questioning to understand requirements.
Round 1: Users & Goals (ask 2-3 questions)
| Category | Example Questions | |----------|------------------| | Users/Personas | "Who are the primary users of this system/feature?" | | | "Are there different user roles with different needs?" | | Core Goals | "What is the primary problem being solved?" | | | "What does success look like for the user?" |
Round 2: Scope & Constraints (ask 2-3 questions)
| Category | Example Questions | |----------|------------------| | Scope | "What is explicitly in scope for this work?" | | | "What should be considered out of scope?" | | Constraints | "Are there technical constraints to be aware of?" | | | "Are there existing systems this must integrate with?" |
Round 3: Success Criteria (ask 2-3 questions)
| Category | Example Questions | |----------|------------------| | Acceptance | "How will you know this feature is working correctly?" | | | "What are the key scenarios that must work?" | | Edge Cases | "What error cases or edge cases concern you most?" | | | "What happens when things go wrong?" |
Continuation Protocol:
Generate hierarchical user stories from the gathered context.
Step 1: Identify Epics
Extract high-level goals/capabilities from the input. Each epic represents a major user-facing capability.
Epic format:
ID: EPIC-NN
Title: [Capability name]
Description: As a [user type], I want [goal] so that [benefit]
Status: Draft
Limits: If more than 5-7 epics emerge, discuss with the user which to prioritize for this session.
Step 2: Decompose into Features
For each epic, identify 2-5 features that compose it:
Feature format:
ID: EPIC-NN.F-NN
Title: [Feature name]
Description: As a [user type], I want [specific capability] so that [benefit]
Limit: Max 5 features per epic. If more emerge, suggest splitting the epic.
Step 3: Decompose into Tasks
For each feature, identify 2-5 implementable tasks:
Task format (shared with create-plan phases):
ID: EPIC-NN.F-NN.T-NN
Title: [Task name]
**Objective**: [What this task accomplishes]
**Acceptance Criteria**:
- **Given** [precondition]
**When** [action]
**Then** [expected result]
**Tasks** (tests first, then implementation):
- [ ] Write tests: [test file] covering [scenarios]
- [ ] Implement: [file] to make tests pass
- [ ] Verify: [specific check or command]
**Exit Conditions**:
Build Verification:
- [ ] [build/lint/typecheck commands]
Runtime Verification:
- [ ] [start command, no errors]
Functional Verification:
- [ ] [test commands, specific checks]
Limit: Max 5 tasks per feature. If more emerge, suggest splitting the feature.
Step 4: Review with User
Before writing output, present the hierarchy for review:
## Story Hierarchy Preview
### EPIC-01: [Title]
- EPIC-01.F-01: [Feature title] (N tasks)
- EPIC-01.F-02: [Feature title] (N tasks)
### EPIC-02: [Title]
- EPIC-02.F-01: [Feature title] (N tasks)
Total: N epics, N features, N tasks
Does this decomposition look right? Any adjustments before I write the detailed stories?
Wait for user confirmation before proceeding to output.
Write the user story files following the conventions from ADR-0003 and ADR-0004.
Step 1: Create directory (if needed)
mkdir -p docs/user-stories
Step 2: Write epic files
For each epic, write a file using the template from references/story-template.md:
File: docs/user-stories/EPIC-NN-slug.md
See references/story-template.md for the complete format.
Step 3: Create/update INDEX.md
Write/update docs/user-stories/INDEX.md using the template from references/index-template.md.
Step 4: Report summary
After writing all files, present:
## User Stories Created
| File | Epic | Features | Tasks |
|------|------|----------|-------|
| [EPIC-01-slug.md](docs/user-stories/EPIC-01-slug.md) | [Title] | N | N |
| [EPIC-02-slug.md](docs/user-stories/EPIC-02-slug.md) | [Title] | N | N |
**Index**: docs/user-stories/INDEX.md
## Recommended Next Steps
1. Review and refine acceptance criteria
2. Create ADRs for any architectural decisions identified (`/adr`)
3. Create implementation plan from these stories (`/create-plan`)
Task-level stories share structure with create-plan phases per ADR-0005.
See references/shared-format.md for the exact contract.
Shared base (both user stories and plan phases):
User stories add:
Before finalizing output, verify:
Structure:
Content:
Context:
| Level | Represents | Timeframe | Example | |-------|-----------|-----------|---------| | Epic | Major user capability | Weeks-months | "User Authentication" | | Feature | Deliverable functionality | Days-weeks | "Password Reset Flow" | | Task | Single implementable unit | Hours-days | "Email Validation on Reset Form" |
When create-plan is invoked after user stories:
story-template.md - Epic file format and story structure at each levelindex-template.md - INDEX.md template for user stories directoryshared-format.md - Shared format contract between user stories and create-plantesting
One-command issue-to-merge pipeline orchestrator. Drives a GitHub issue through nine stages (preflight, plan, implement, review, ci, cloud_review, deploy, e2e, logs) with two human gates, persisting all run state to files so a crashed or interrupted run resumes losslessly. Triggers on "/ship-issue" with an issue number or URL. User-invoked only.
tools
--- name: tt-workflow-build description: Tasktracker-native trigger for a PARALLEL build via the Claude Code Workflow tool. Thin by design — it does two things, then drives to done: (1) ensure a tasktracker project exists (use the existing one, or create one), then (2) start a dynamic `Workflow` that builds it, tracking the work in tasktracker and using the build + verify skills. It does NOT analyze parallelism up front, ask the user to choose a mode, hand back, or fall back to a sequential skil
tools
--- name: grumpy-reviewer description: A single grumpy, nitpicky structural code reviewer that runs as an isolated subagent and treats the code as third-party work submitted by a junior programmer for validation. It cares about exactly one thing — maintainability — judged through separation of concerns, service-oriented design, helper-method extraction, small files, and the rule of 7 (as any grouping nears 7 members, it pushes for sub-groupings). It is deliberately kept OUT of the implementation
development
--- name: tt-workflow-run description: Tasktracker-native autonomous build-loop orchestrator. Drives a first-class `workflow_run` end-to-end — create the run (Gate 1 lifecycle completeness + Gate 2 zero-defects-in), then loop while `getNextReadyTask(projectId)` returns a slice — `setActiveTask` → record a pre-slice `scanArchitectureDrift` baseline → delegate the slice to `/tt-implement-phase` (which does the code work, registers the architecture delta in-slice, and auto-logs defects/learnings/fr