coco-research/prd mastery: context-aware, expert-driven, and token-efficient refinement
A skill that blends the wisdom of top industry experts, ensures token-efficient PRDs, and organizes outputs in a clear folder structure.
npx skills add https://github.com/coco-research/coco --skill PRD Mastery: Context-Aware, Expert-Driven, and Token-Efficient Refinement
Status: Production Ready
Package Manager: pnpm
Key Focus: Context-aware PRD creation, token efficiency, expert-driven guidance
Official References:
The PRD Mastery skill helps AI agents create high-quality, context-aware Product Requirements Documents (PRDs) that are:
✅ Automated repository reconnaissance to understand project context
✅ Adaptive questioning based on project stage
✅ Expert-guided user interviews to extract requirements
✅ Token-optimized output format
✅ Structured organization system for PRD management
✅ Reusable templates and examples
# Node.js 20.9+ for running reconnaissance scripts
node --version
# pnpm (recommended)
pnpm --version
node .claude/skills/ba-prd-skills/repo_scan.js
cat prelim_summary.md
Follow the workflow steps below to guide the PRD creation process.
Goal: Automatically determine if the project is new or existing, identify tech stack, and document context.
Process:
repo_scan.js to analyze:prelim_summary.md with:Example Output:
# Preliminary Project Summary
**Project Type**: Existing
**Tech Stack**: Next.js 16, React, TypeScript, Prisma ORM
**Architecture**: App Router with server components
**Key Observations**:
- Well-structured authentication system using Auth.js
- Vector database integration with Upstash
- MCP server pattern implementation
Goal: Understand where the project is in its lifecycle and whether architecture changes are needed.
Context-Aware Questions:
For New Projects:
For Existing Projects:
Adaptive Follow-ups:
Goal: Use proven questioning techniques to move from broad ideas to specific, outcome-focused PRDs.
Inspired by "Inspired", focus on outcomes over features:
Based on "Continuous Discovery Habits":
Focus on clarity and completeness:
Goal: Create a token-efficient PRD and organize it in a clear folder structure.
prds/
├── README.md # Index of all PRDs
├── prd-001-user-authentication/
│ ├── prd.md # Main PRD document
│ ├── research.md # User research findings
│ ├── technical-specs.md # Technical specifications
│ ├── mockups/ # Design mockups
│ └── decisions.md # Architecture decisions
├── prd-002-vector-search/
│ ├── prd.md
│ ├── research.md
│ ├── technical-specs.md
│ └── decisions.md
└── templates/
└── prd-template.md # Template for new PRDs
Each PRD follows a token-efficient format:
# [Feature Name] - PRD
**ID**: PRD-XXX
**Status**: Draft | In Review | Approved | Implemented
**Owner**: [Name]
**Created**: YYYY-MM-DD
**Last Updated**: YYYY-MM-DD
## Summary
[2-3 sentence overview optimized for AI parsing]
## Problem Statement
- User need: [Specific user problem]
- Business goal: [Why this matters]
- Success metric: [How we measure success]
## Target Users
- Primary: [Who benefits most]
- Secondary: [Additional users]
## Key Outcomes
1. [Outcome 1 - user benefit]
2. [Outcome 2 - business benefit]
3. [Outcome 3 - technical benefit]
## Requirements
### Must Have
- [ ] Requirement 1
- [ ] Requirement 2
### Should Have
- [ ] Requirement 3
### Could Have
- [ ] Requirement 4
## Technical Approach
- Stack: [Tech stack]
- Architecture: [High-level approach]
- Integration points: [Key integrations]
## Risks & Assumptions
- Risk: [Risk] | Mitigation: [Plan]
- Assumption: [Assumption] | Validation: [How to test]
## Success Criteria
- Metric 1: [Target]
- Metric 2: [Target]
## Implementation Plan
1. Phase 1: [Scope] - [Timeline]
2. Phase 2: [Scope] - [Timeline]
## Resources
- Design: [Link]
- Research: [Link]
- Technical specs: [Link]
Combine expert approaches into a cohesive discovery process:
Questions to Ask:
Output: Clear problem statement
Questions to Ask:
Output: Prioritized opportunities with testable assumptions
Questions to Ask:
Output: Scoped solution with clear success metrics
❌ Avoid: "The authentication system needs to support multiple providers including Google OAuth, GitHub, and email/password authentication. It should also handle session management and provide secure token storage."
✅ Prefer:
**Authentication Requirements**:
- Providers: Google OAuth, GitHub, email/password
- Session management: Required
- Token storage: Secure, encrypted
Must Have: Critical requirementsShould Have: Important but not blockingCould Have: Nice to haveWon't Have: Out of scope## Requirements
**Auth**: Multi-provider (Google, GitHub, email)
**Session**: JWT, 24h expiry, refresh tokens
**Security**: HTTPS only, CSRF protection, rate limiting
**UX**: Social login buttons, password reset flow
This format is:
Create a dedicated PRD management system:
# Create PRD directory structure
mkdir -p prds/templates
mkdir -p prds/archive
# Initialize README
cat > prds/README.md << 'EOF'
# Product Requirements Documents
## Active PRDs
- [PRD-001: User Authentication](./prd-001-user-authentication/prd.md)
- [PRD-002: Vector Search](./prd-002-vector-search/prd.md)
## Status Legend
- 🟡 Draft
- 🔵 In Review
- 🟢 Approved
- ✅ Implemented
- 📦 Archived
EOF
prd-NNN-kebab-case-name/Each PRD should be:
See repo_scan.js for the full implementation. Key features:
// Detect project type
const isNewProject = !fs.existsSync('package.json');
// Identify tech stack
const techStack = {
framework: detectFramework(),
language: detectLanguage(),
database: detectDatabase(),
deployment: detectDeployment()
};
// Analyze architecture
const architecture = {
pattern: detectPattern(),
structure: analyzeStructure(),
integrations: findIntegrations()
};
# Use the helper script
node .claude/skills/ba-prd-skills/create_prd.js "User Authentication"
# Or manually
mkdir prds/prd-001-user-authentication
cp prds/templates/prd-template.md prds/prd-001-user-authentication/prd.md
templates/prd-template.md)templates/research-template.md)templates/technical-specs-template.md)Marty Cagan:
Teresa Torres:
George Biddle:
The authentication system will need to support multiple authentication
providers to give users flexibility in how they log in. We should support
Google OAuth because many users have Google accounts, GitHub OAuth for
developers, and also traditional email and password authentication for
users who prefer not to use third-party providers.
Token count: ~60 tokens
**Auth Providers**:
- Google OAuth (most users have accounts)
- GitHub OAuth (developer audience)
- Email/password (privacy-conscious users)
Token count: ~25 tokens
Savings: ~58% reduction while maintaining clarity
When creating a new PRD:
repo_scan.js)prelim_summary.md)See examples/prd-example.md for a complete example of a token-efficient, expert-driven PRD following this framework.
Built with ❤️ by Callum Bir
Inspired by the product wisdom of Marty Cagan, Teresa Torres, and George Biddle
Take coco-research/prd mastery: context-aware, expert-driven, and token-efficient refinement from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.