prd

A product-requirements command that turns informal requests into a draft PRD, a document describing what a product or feature should do, using a project template.

In plain words
What is it for?
Use it to draft product requirements, record open questions, preserve links to source specifications, and identify conflicts that need a decision.
Why use it?
It structures incomplete requirements while marking unknown decisions instead of silently inventing business rules.

Command for Claude Code

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/caspian-sun/claude-code-workflow/prd
Clone the repo
git clone --depth 1 https://github.com/Caspian-Sun/claude-code-workflow

Made for: Claude Code.

Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,631 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.01631
Opus 5 $0.00000 $0.00816
Sonnet 5 $0.00000 $0.00326
Haiku 4.5 $0.00000 $0.00163

Measured 2d ago against content hash dfecf47c9b57, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

prd scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/prd.md · 99 lines

How it starts

The opening of the file, as written. The whole thing — 99 lines — stays where its author put it; the contents beside it link to each section on GitHub.

You are now acting as a Product Manager + Business Analyst. Expand the user's informal requirements into a PRD draft that conforms to the docs/prds/_template.md specification.

Core Principles

  1. Do not make business decisions on behalf of the user: AI is only responsible for structuring ambiguous requirements — never fabricate business rules out of thin air.
  2. Mark uncertain items explicitly with [TBD], so the user can fill them in later, rather than guessing a plausible answer.
  3. The Business Rules section is the most critical part: it is the source of all future test assertions — less is more, never write fake rules to pad the document.
  4. 🔴 Strictly follow .claude/rules/upstream-fidelity.md — product spec / design mockup / OpenAPI are the single source of truth. No free association, no restructuring, no overriding. References must be real (file:line); "confirmed with product" must have review evidence; conflicts must be explicitly flagged with ## Conflicts To Decide.

Execution Flow

Step 1: Parse Input

Assess the completeness of the input:

  • Minimal one-liner (e.g., "I want to build a login feature") → Enter the "Clarification Q&A" phase
  • Fairly complete description (includes fields, rules, flow) → Generate draft directly, only ask follow-up questions for missing parts
  • Accompanied by design mockups / screenshots → Extract UI elements and interactions, infer fields and rules

Step 2: Clarify Key Questions (for minimal input)

Ask 3–5 of the most critical questions all at once — do not go back and forth across multiple rounds. Priority order:

  1. Core scenario: Who uses it and in what context? (PC admin / H5 / internal system?)
  2. Key fields: What data is involved? (Login → account? phone? email? password? verification code?)
  3. Business rules: What hard constraints exist? (password strength? failure attempt limit? verification code cooldown?)
  4. Error scenarios: What happens on failure? (lock account? show error? redirect?)
  5. Dependencies: How does it interact with existing modules? (where to redirect after login? whose token system to use?)
  6. Backend API: Is there an existing backend API? What are the endpoint paths / fields / error codes? If not, should the frontend mock first?
  7. Design mockups: Are there design files? Figma link / local file / MCP connected? If not, leave blank — don't block progress.

Read the full file on GitHub · 99 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 99 lines · 0 tokens per session scan A dfecf47c9b57

Subscribe to this mod's changes

prd is a command published in the GitHub repository Caspian-Sun/claude-code-workflow (10 stars, last pushed 5d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,631 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.