prd
Generate a Product Requirements Document from an Idea Brief or raw description. Always reads system-context.md to account for existing system state. Includes functional requirements, API contracts, data models, and test strategy. Triggers: "prd", "requirements", "write PRD", "product requirements"
From sdlc-toolkitnpx claudepluginhub youarenext/sdlc-toolkit --plugin sdlc-toolkitThis skill is limited to using the following tools:
templates/discovery-index.mdtemplates/prd.mdPRD Skill
Generate a complete PRD based on an Idea Brief, user description, or System Context. PRD must include: functional requirements, API contracts, data models, testing strategy.
Entry Points
PRD can be created from different sources:
- From Idea Brief — if the ideation phase is complete, read
docs/discovery/NN-<slug>/idea-brief.md - Directly — if ideation is skipped, PRD is created from user description or command arguments
Key Mechanism: Accounting for Existing System
The PRD skill always starts by reading system-context.md:
- First PRD (system-context empty): generates from scratch, writes "Greenfield" in "Current System State" section
- Subsequent PRDs: reads existing APIs, models, services and builds a delta — what we're adding/changing
Pre-check for Greenfield
Before generating PRD, check:
- Is
docs/system-context.mdempty or missing? (greenfield) - Does
.claude/rules/tech-stack.mdexist?
If greenfield AND no tech-stack.md:
→ Suggest to the user: "This looks like a new project without established tech stack. Consider running /sdlc-toolkit:foundation first to define project structure and technical conventions. This will help ensure consistent architecture decisions."
Let the user decide whether to run foundation first or proceed with PRD.
Instructions
- Read
@docs/system-context.md— this is the current system state - Read
@docs/discovery/INDEX.md— determine the next iteration number (NN) - Determine the requirements source:
- If iteration slug is provided (e.g., "01-article-reading") — read Idea Brief from
docs/discovery/01-article-reading/idea-brief.md - If text description is provided — use it as direct input, generate slug from it
- If arguments are empty — ask the user what we're building
- If iteration slug is provided (e.g., "01-article-reading") — read Idea Brief from
- Generate a slug if creating new iteration — short, hyphenated, lowercase, English only
- Example: "User Authentication System" →
user-auth
- Example: "User Authentication System" →
- Create the iteration folder first if it doesn't exist:
docs/discovery/NN-<slug>/- Example:
docs/discovery/01-article-reading/
- Example:
- If
docs/discovery/INDEX.mddoesn't exist — create it using the template - If system-context is not empty — determine what's already implemented and build PRD as delta
- Generate PRD using the template
- For each API endpoint — specify method, path, request/response schema in JSON
- For each data model — specify fields, types, constraints, indexes
- Testing Strategy section is required — include approach and key scenarios
- Save to
docs/discovery/NN-<slug>/prd.md(INSIDE the iteration folder!) - Update
docs/discovery/INDEX.md— add or update row, statusIn Review
Critical: Folder Structure
CORRECT structure:
docs/discovery/
├── INDEX.md
└── 01-article-reading/ ← folder for iteration
├── idea-brief.md ← (optional) from ideation phase
└── prd.md ← PRD inside folder
WRONG structure (don't do this):
docs/discovery/
├── INDEX.md
└── 01-prd.md ← WRONG! No folder created
Important
- Every API endpoint must have a concrete request/response schema — no abstractions
- Every functional requirement must have verifiable acceptance criteria
- "Current System State" section is auto-filled from system-context.md
- If greenfield — state it explicitly
- Data Models must include field types, constraints, and relationships between models
- Slug must be short, hyphenated, lowercase, English (e.g.:
article-processing,user-auth) - Always ensure the iteration folder exists, then save prd.md inside it
Supporting files
- templates/prd.md — PRD template
- templates/discovery-index.md — Discovery Index template