user-story skill
Create user stories with Mike Cohn format and Gherkin acceptance criteria. Use when turning user needs into development-ready work with clear outcomes and testable conditions.
Is the user-story skill safe?
Clean: nothing in its files matched our rules. We read 5 files in the folder on 2026-09-28.
No findings.
Install the user-story skill
A skill is a folder. Copy it into your agent's skills folder and the agent loads it when the task matches its description.
git clone --depth 1 https://github.com/deanpeters/Product-Manager-Skills.git /tmp/Product-Manager-Skills mkdir -p ~/.claude/skills cp -r /tmp/Product-Manager-Skills/skills/user-story ~/.claude/skills/user-story
In the Claude apps, zip the folder and upload it from the Skills settings. The folder on GitHub
The instructions your agent would load
SKILL.md as published, without the frontmatter. Read it on GitHub
Purpose
Create clear, concise user stories that combine Mike Cohn's user story format with Gherkin-style acceptance criteria. Use this to translate user needs into actionable development work that focuses on outcomes, ensures shared understanding between product and engineering, and provides testable success criteria.
This is not a feature spec—it's a conversation starter that captures who benefits, what they're trying to do, why it matters, and how you'll know it works.
Input
Works best with: The feature or user need the story captures. Also useful: The user role, the outcome they want, and edge cases the acceptance criteria must cover.
Anything supplied with the invocation itself — text after the skill name, a pasted context dump, or an appended ARGUMENTS: line — counts as answers already given. Use it and skip whatever it covers; don't re-ask.
Arriving empty-handed? That works too. The skill asks who the user is and what they're trying to accomplish before drafting story and Gherkin criteria.
Example invocation: Write user stories for password reset via SMS for our banking app — include the lockout edge case.
Key Concepts
The Mike Cohn + Gherkin Format
A user story combines:
Use Case (Mike Cohn format):
- As a [user persona/role]
- I want to [action to achieve outcome]
- so that [desired outcome]
Acceptance Criteria (Gherkin format):
- Scenario: [Brief description of the scenario]
- Given: [Initial context or preconditions]
- and Given: [Additional preconditions]
- When: [Event that triggers the action]
- Then: [Expected outcome]
Why This Structure Works
- User-centric: Forces focus on who benefits and why
- Outcome-focused: "So that" emphasizes the value delivered, not just the action
- Testable: Gherkin acceptance criteria are concrete and verifiable
- Conversational: Story is the opening for discussion, not the final spec
- Shared language: Product, engineering, and QA all understand the format
Anti-Patterns (What This Is NOT)
- Not a task: "As a developer, I want to refactor the database" (this is a tech task, not user value)
- Not a feature list: "I want dashboards, reports, and analytics" (this is too big—needs splitting)
- Not vague: "I want a better experience" (unmeasurable, no clear outcome)
- Not a contract: Stories are placeholders for conversation, not locked-in specs
When to Use This
- Translating user needs into development work
- Backlog grooming and sprint planning
- Communicating value to engineering and design
- Ensuring testable acceptance criteria exist before development
When NOT to Use This
- For pure technical debt or refactoring (use engineering tasks instead)
- When stories are too large (split first—see skills/user-story-splitting/SKILL.md)
- Before understanding the user problem (write a problem statement first)
Application
Step 1: Gather Context
Before writing a story, ensure you have:
- User persona: Who is this for? (reference skills/proto-persona/SKILL.md)
- Problem understanding: What need does this address? (reference skills/problem-statement/SKILL.md)
- Desired outcome: What does success look like?
- Constraints: Technical, time, or scope limitations
If missing context: Run discovery interviews or problem validation work first.
Optional Helper Script (Template Generator)
If you want a consistent Markdown stub, you can generate one from CLI inputs. This script is deterministic and does not fetch data or write files.
python3 scripts/user-story-template.py --persona \"trial user\" --action \"log in with Google\" --outcome \"access the app without creating a new password\"Step 2: Write the Use Case
Use template.md for the full fill-in structure.
Fill in the template:
### User Story [ID]:
- **Summary:** [Brief, memorable title focused on value to the user]
#### Use Case:
- **As a** [user name if available, otherwise persona, otherwise role]
- **I want to** [action user takes to get to outcome]
- **so that** [desired outcome]Quality checks:
- "As a" specificity: Is this a specific persona (e.g., "trial user") or generic ("user")?
- "I want to" clarity: Is this an action the user takes, or a feature you're building?
- "So that" outcome: Does this explain the user's motivation? Or is it just restating the action?
Common mistakes:
- ❌ "As a user, I want a login button, so that I can log in" (restating the action)
- ✅ "As a trial user, I want to log in with Google, so that I can access the app without creating a new password"
Step 3: Write the Acceptance Criteria
Fill in the template:
#### Acceptance Criteria:
- **Scenario:** [Brief, human-readable scenario describing value]
- **Given:** [Initial context or precondition]
- **and Given:** [Additional context or preconditions]
- **and Given:** [Additional context as needed]
- **and Given:** [UI-focused context ensuring 'When' can happen]
- **and Given:** [Outcomes-focused context ensuring 'Then' is delivered]
- **When:** [Event that triggers the action—aligns with 'I want to']
- **Then:** [Expected outcome—aligns with 'so that']Quality checks:
- Multiple Givens are okay: Preconditions stack up (e.g., "Given I'm logged in" + "Given I have items in my cart")
- Only one When: If you need multiple "When" statements, you likely have multiple stories—split them
- Only one Then: If you need multiple "Then" statements, you likely have multiple stories—split them
- Alignment: Does "When" match "I want to"? Does "Then" match "so that"?
Red flags:
- Multiple Whens/Thens: Sign of scope creep—split the story (reference skills/user-story-splitting/SKILL.md)
- Vague Thens: "Then I see improved performance" (unmeasurable—make it specific)
Step 4: Add a Summary
Write a short, memorable summary that captures the story's value:
- **Summary:** [Brief, human-readable title]Examples:
- ✅ "Enable Google login for trial users to reduce signup friction"
- ✅ "Bulk delete items to save time for power users"
- ❌ "Add delete button" (feature-centric, not value-centric)
Step 5: Validate and Refine
- Read aloud to the team: Does everyone understand who, what, why?
- Test acceptance criteria: Can QA write test cases from this?
- Check for splitting: If the story feels too big, use skills/user-story-splitting/SKILL.md
- Ensure testability: Can you prove "Then" happened?
Examples
See examples/sample.md for full examples (good, bad, and split-needed stories).
Mini example excerpt:
### User Story 042:
- **Summary:** Enable Google login for trial users to reduce signup friction
#### Use Case:
- **As a** trial user visiting the app for the first time
- **I want to** log in using my Google account
- **so that** I can access the app without creating and remembering a new password
#### Acceptance Criteria:
- **Scenario:** First-time trial user logs in via Google OAuth
- **Given:** I am on the login page
- **and Given:** I have a login account
- **When:** I click the "Sign in with Google" button and authorize the app
- **Then:** I am logged into the app and redirected to the onboarding flowCommon Pitfalls
Pitfall 1: Technical Tasks Disguised as User Stories
Symptom: "As a developer, I want to refactor the API, so that the code is cleaner"
More skills from deanpeters/Product-Manager-Skills
- Aacquisition-channel-advisorEvaluate acquisition channels using unit economics, customer quality, and scalability. Use when deciding whether to scale, test, or kill a growth channel.
- Aagent-orchestration-advisorDesign multi-agent AI workflows with clear boundaries, handoffs, and monitoring. Use when a complex PM task should run as parallel specialized agents instead of one linear process.
- Aai-shaped-readiness-advisorAssess whether your product work is AI-first or AI-shaped. Use when evaluating AI maturity and choosing the next team capability to build.
- Aaltitude-horizon-frameworkUnderstand the PM-to-Director transition through altitude and horizon thinking. Use when diagnosing scope, time-horizon, or leadership-level gaps.
- Aansoff-matrixMap evidence-backed growth options across the Ansoff Matrix with risk-rated sequencing. Use when the question is where the next tranche of growth comes from, and at what risk.
- Aautonomous-investigationThe protocol behind every investigation skill. Use when AI research must proceed without you: search-plan gate, Fact/Inference/Assumption labels, confidence stacking, diffable outputs.
- Abattle-card-builderResearch and draft a competitive battle card from public evidence — every claim labeled and sourced. Use when a rep needs a field-action card, not a research report.
- Abusiness-health-diagnosticDiagnose SaaS business health across growth, retention, efficiency, and capital. Use when preparing a business review or prioritizing urgent fixes.
- Acompany-intelResearch a company, industry, or competitor set using web search and seven analytical lenses. Use when you need structured intel that feeds downstream PM skills.
- Acompany-researchCreate a company research brief with executive quotes, product strategy, and org context. Use when preparing for interviews, competitive analysis, partnerships, or market-entry work.
- Acompetitive-analysis-processOrchestrate a complete competitive analysis across six steps, from landscape to strategic direction. Use when you need the full picture, not a single scan or card.
- Acompetitive-intel-watchScheduled delta monitoring against a prior competitive snapshot. Use when tracking competitors on a cadence: material shifts only, cited evidence, battle-card update flags, runs unattended.