write-prd

write-prd is a command for Claude Code from mrvladd-d/memobank. It costs 14 tokens per session (1,491 once invoked), scanned A, original, MIT.

A command that turns a product brief or existing product requirements document into a clarified product requirements document, or PRD.

In plain words
What is it for?
It reads the available product and project context, checks the project's constitution and related Memory Bank files, and produces a clarified PRD when the required source material exists.
Why use it?
It resolves important ambiguity before the project is broken into technical designs and implementation tasks.

Command for Claude Code

Written for Claude Code: $ARGUMENTS substitution.

Good fit It reads the available product and project context, checks the project's constitution and related Memory Bank files, and produces a clarified PRD when the required source material exists.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/mrvladd-d/memobank/write-prd
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.

Clone the repo
git clone --depth 1 https://github.com/mrvladd-d/memobank

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for write-prd

README.md
[![agentmods](https://agentmods.dev/badge/commands/mrvladd-d/memobank/write-prd/github.svg)](https://agentmods.dev/commands/mrvladd-d/memobank/write-prd)
Your own site
<a href="https://agentmods.dev/commands/mrvladd-d/memobank/write-prd"><img src="https://agentmods.dev/badge/commands/mrvladd-d/memobank/write-prd/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for write-prd

Your own site · 80×15
<a href="https://agentmods.dev/commands/mrvladd-d/memobank/write-prd"><img src="https://agentmods.dev/badge/commands/mrvladd-d/memobank/write-prd.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 14 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,491 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00014 $0.01491
Opus 5.5 $0.00006 $0.00596
Sonnet 5.5 $0.00003 $0.00298
Haiku 4.5 $0.00001 $0.00149

Measured 1mo ago against content hash 32288db9e5fc, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

write-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 1mo 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.

skills/_shared/references/commands/write-prd.md · 201 lines

How it starts

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

/write-prd - Brief + Constitution -> PRD

/write-prd is the PRD-level clarification loop. It resolves high-impact ambiguity before /spec-init builds the SDD route map and /prd decomposes the PRD into Memory Bank L1-L3 artifacts.

0) Input sources

Read the current PRD source. Accept any one of these as the source input:

  • .memory-bank/analysis/product-brief.md
  • explicit PRD source text or file provided by the user
  • existing prd.md or .memory-bank/prd.md when present and being normalized/clarified

Read as optional context when present and relevant:

  • .memory-bank/constitution.md
  • .memory-bank/analysis/brainstorming/BR-*.md
  • .memory-bank/product.md
  • .memory-bank/requirements.md
  • .memory-bank/glossary.md
  • .memory-bank/invariants.md
  • .memory-bank/spec-index.md
  • .memory-bank/contracts/*
  • .memory-bank/states/*
  • .memory-bank/runbooks/*
  • .memory-bank/testing/*
  • user-provided context in $ARGUMENTS

If no Product Brief, explicit PRD source text/file, or existing prd.md / .memory-bank/prd.md is available, stop and ask for /brief or explicit PRD source text. If the Constitution is missing, stop and ask for /constitution or explicit permission to create the PRD without a Constitution gate.

1) Constitution gate

Compare the PRD source and optional context against .memory-bank/constitution.md.

If the PRD requires changing the Constitution, add this section to .memory-bank/prd.md and stop unless the user explicitly confirms the amendment path:

## Constitution Amendment Candidates

### Candidate 1
- Current principle:
- Conflict:
- Proposed amendment:
- Rationale:

Do not weaken, reinterpret, or silently override the Constitution.

2) Draft PRD

Create or update .memory-bank/prd.md with this frontmatter:

---
description: Product Requirements Document.
status: draft
type: prd
clarification_status: pending
constitution_checked: true
---

Read the full file on GitHub · 201 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. 1mo ago First seen · 201 lines · 14 tokens per session scan A 32288db9e5fc

Subscribe to this mod's changes

write-prd is a command published in the GitHub repository mrvladd-d/memobank (56 stars, last pushed 4mo ago), licensed MIT. It adds 14 tokens to every session and 1,491 once invoked, about $0.0001 per session on Opus 5.5. 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-30.