agents/parallel-PRD/.opencode/skill/prd-authoring/SKILL.md
Guide for authoring comprehensive PRDs with parallel planning support. Use for drafting technical specifications, defining requirements, and synthesizing planner outputs. Use proactively when creating PRDs, architecture designs, or implementation plans. Examples: - user: "Draft a PRD for user auth" → create PRD with purpose, requirements, and scenarios - user: "Analyze these PRD requirements" → verify SHALL/MUST usage and scenario structure - user: "Synthesize planner outputs" → merge the strongest parts of multiple generated PRDs - user: "Create a PRD template" → setup standard sections and placeholder content
npx skillsauth add igorwarzocha/opencode-workflows prd-authoringInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
This skill provides comprehensive guidance for creating high-quality Product Requirement Documents (PRDs) that include:
<quality_standards>
A good PRD MUST be:
Every PRD MUST include:
</quality_standards>
<prd_template>
# [Feature Name] - PRD
## Overview
[2-3 sentence summary]
## Problem Statement
[What problem are we solving? Why now? What's the impact of not solving it?]
## Goals
- [ ] [Primary goal 1 - specific and measurable]
- [ ] [Primary goal 2 - specific and measurable]
- [ ] [Secondary goal 3]
## Non-Goals
[What we explicitly will NOT do in this iteration - sets scope boundaries]
## Requirements
### Functional Requirements
- [FR-1] [User stories/use cases as specific requirements]
- [FR-2] [Acceptance criteria for each requirement]
### Non-Functional Requirements
- [NFR-1] **Performance**: [specific metrics, e.g., "API responds in <200ms at p95"]
- [NFR-2] **Security**: [e.g., "All data encrypted at rest and in transit"]
- [NFR-3] **Scalability**: [e.g., "System handles 10k concurrent users"]
- [NFR-4] **Reliability**: [e.g., "99.9% uptime SLA"]
### Technical Requirements
- [TR-1] [Technology stack constraints]
- [TR-2] [Integration requirements]
- [TR-3] [Data retention/compliance requirements]
## Proposed Architecture
### System Design
[High-level architecture - use text diagrams or mermaid]
[Component A] ←→ [Component B] ←→ [Component C] ↓ ↓ ↓ [Database] [Cache Layer] [External API]
### Component Breakdown
- **Component A**: [Responsibility, technology choice, scaling approach]
- **Component B**: [Responsibility, technology choice, scaling approach]
- **Component C**: [Responsibility, technology choice, scaling approach]
### Data Flow
1. [Step-by-step description of how data moves through the system]
2. [Include error handling, retries, fallbacks]
3. [Describe async/sync boundaries]
### API Design (if applicable)
[Include endpoint specifications, request/response schemas]
## Technical Considerations
### Technology Choices
| Technology | Justification | Alternatives Considered |
|------------|---------------|-------------------------|
| [Tech 1] | [Why this choice] | [Alternative 1, Alternative 2] |
| [Tech 2] | [Why this choice] | [Alternative 1, Alternative 2] |
### Trade-offs Analyzed
| Option | Pros | Cons | Decision |
|--------|------|------|----------|
| [Option A] | ... | ... | ✅/❌ |
| [Option B] | ... | ... | ✅/❌ |
### Risks and Mitigations
| Risk | Impact | Probability | Mitigation Strategy |
|------|--------|-------------|---------------------|
| [Risk 1] | High/Med/Low | High/Med/Low | [How to address] |
| [Risk 2] | High/Med/Low | High/Med/Low | [How to address] |
## Implementation Strategy
### Phase 1: Foundation
- [ ] [Task 1.1]
- [ ] [Task 1.2]
- [ ] [Task 1.3]
**Definition of Done**: [Specific criteria for phase completion]
### Phase 2: Core Features
- [ ] [Task 2.1]
- [ ] [Task 2.2]
- [ ] [Task 2.3]
**Definition of Done**: [Specific criteria for phase completion]
### Phase 3: Polish & Launch
- [ ] [Task 3.1]
- [ ] [Task 3.2]
- [ ] [Task 3.3]
**Definition of Done**: [Specific criteria for phase completion]
## Task Breakdown
<task_list_template>
### High Priority (P0) - Blockers for launch
- [ ] **[TASK-1]**: [Actionable task title]
- Complexity: [Simple/Medium/Complex]
- Dependencies: [Task IDs or components that must exist first]
- Parallelizable: [Yes/No - if Yes, specify which tasks can run simultaneously]
- Testing: [Required/Recommended/None - specify type: unit, integration, e2e]
- Acceptance criteria: [Specific, testable criteria]
### Medium Priority (P1) - Important but not blocking
- [ ] **[TASK-2]**: [Actionable task title]
- Complexity: [Simple/Medium/Complex]
- Dependencies: [Task IDs or components that must exist first]
- Parallelizable: [Yes/No - if Yes, specify which tasks can run simultaneously]
- Testing: [Required/Recommended/None - specify type: unit, integration, e2e]
- Acceptance criteria: [Specific, testable criteria]
### Low Priority (P2) - Nice to have
- [ ] **[TASK-3]**: [Actionable task title]
- Complexity: [Simple/Medium/Complex]
- Dependencies: [Task IDs or components that must exist first]
- Parallelizable: [Yes/No - if Yes, specify which tasks can run simultaneously]
- Testing: [Required/Recommended/None - specify type: unit, integration, e2e]
- Acceptance criteria: [Specific, testable criteria]
</task_list_template>
<parallelization_guidance>
### Task Parallelization
Mark tasks as **Parallelizable: Yes** when:
- Task is independent of other in-progress tasks
- Multiple developers/subagents can work on different aspects simultaneously
- Task can be split into independent sub-tasks
**Examples:**
✅ **Parallelizable**
- "Design REST API endpoints" and "Design database schema" - can be done simultaneously with coordination
- "Write frontend user profile component" and "Write frontend settings component" - independent components
- "Set up CI/CD pipeline" and "Set up monitoring infrastructure" - separate infrastructure tasks
❌ **Not Parallelizable**
- "Implement authentication" - blocks on "Design database schema" (dependency)
- "Write API tests" - requires API endpoints to exist first (dependency)
**Format for parallelizable tasks:**
```markdown
- Parallelizable: Yes - Can run concurrently with [TASK-X], [TASK-Y]
</parallelization_guidance>
<complexity_guidance>
Simple
Medium
Complex
</complexity_guidance>
<testing_guidance>
Each task MUST specify testing needs:
Required - Critical functionality, MUST have tests before merging
Recommended - Should have tests but not blocking
None - Tests not applicable
Test Types:
unit - Individual functions/components in isolationintegration - Multiple components working togethere2e - Full user flows from start to finishperformance - Load testing, benchmarkssecurity - Penetration testing, vulnerability scans</testing_guidance>
[Include relevant code examples - see guidelines below]
[Include database schemas, type definitions, etc.]
[Links to UI mockups or wireframes]
</prd_template>
<code_snippet_guidelines>
## When to Include Code Snippets
PRDs SHOULD include code snippets when they clarify technical details. Use for:
### 1. API Design
**Include when**: Defining endpoints, request/response formats
```typescript
// POST /api/users
interface CreateUserRequest {
email: string;
password: string; // Hashed with bcrypt
name: string;
}
interface CreateUserResponse {
id: string;
email: string;
createdAt: Date;
}
Include when: Defining database models, type definitions
// User schema
interface User {
id: string; // UUID
email: string; // Unique, indexed
passwordHash: string; // bcrypt
createdAt: Date;
updatedAt: Date;
}
// Indexes
db.users.createIndex({ email: 1 }, { unique: true });
Include when: Defining feature flags, environment variables
# Environment variables
DATABASE_URL=postgresql://...
JWT_SECRET=your-secret-key
RATE_LIMIT_ENABLED=true
RATE_LIMIT_REQUESTS_PER_MINUTE=100
Include when: Explaining complex logic
// Rate limiting algorithm
function rateLimit(userId: string): boolean {
const requests = redis.get(`ratelimit:${userId}`) || 0;
if (requests >= LIMIT) {
return false; // Rate limited
}
redis.incr(`ratelimit:${userId}`);
redis.expire(`ratelimit:${userId}`, 60);
return true; // Allowed
}
Include when: Showing how components interact
// Example: Service A calling Service B
const response = await fetch('http://service-b/api/process', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ data: payload })
});
❌ Full implementation code - PRDs are for requirements, not implementation ❌ Business logic details - Save for actual development ❌ Boilerplate code - Unless it's configuration
✅ DO include: Interfaces, schemas, examples of architecture ✅ DO include: Configuration, API contracts, data models
</code_snippet_guidelines>
<task_list_guidelines>
Tasks in PRDs MUST be:
❌ "Implement user authentication" ✅ "Implement OAuth 2.0 login with Google and GitHub providers"
❌ "Make it fast" ✅ "API response time <200ms at p95 under 1000 RPS"
❌ "Build the entire checkout flow" ✅ "Build cart summary endpoint" (one of many tasks)
Each task MUST specify testing requirements (Required/Recommended/None)
- [ ] **[TASK-ID]** [Actionable title]
- **Complexity**: [Simple/Medium/Complex]
- **Dependencies**: [Task IDs or components that must exist first]
- **Parallelizable**: [Yes/No - if Yes, specify which tasks]
- **Testing**: [Required/Recommended/None - specify type: unit, integration, e2e]
- **Acceptance Criteria**:
- [ ] [Criterion 1 - must be testable]
- [ ] [Criterion 2 - must be testable]
</task_list_guidelines>
<anti_patterns>
❌ "The system should be scalable" ✅ "System must handle 10,000 concurrent users with <500ms response time"
❌ "Implement search functionality" ✅ "Implement full-text search with filters, returning results in <100ms, supporting 100+ concurrent searches"
❌ "Improve user engagement" ✅ "Increase daily active users from 1,000 to 2,000 within 90 days"
❌ "Build the best e-commerce platform" ✅ "Build MVP with product catalog, cart, and checkout (payments via Stripe)"
❌ "Use a database" ✅ "Use PostgreSQL for relational data, Redis for caching, with proper indexing on email and product_id"
❌ [No risk section] ✅ [Include risks table with mitigations]
</anti_patterns>
<workflow>Understand the Problem
Draft Requirements
Design Architecture
Add Technical Details
Create Task Breakdown
Define Success
Review and Refine
See references/examples.md for complete PRD examples.
development
Handle structured co-authoring of professional documentation. Use for proposals, technical specs, and RFCs. Use proactively when a collaborative drafting process (Gathering -> Refinement -> Testing) is needed. Examples: - user: "Draft a technical RFC for the new API" -> follow Stage 1 context gathering - user: "Refine the introduction of this proposal" -> use iterative surgical edits - user: "Test if this document is clear for readers" -> run reader testing workflow
development
Handle Word document (.docx) creation, editing, and analysis with high-fidelity visual review. Use for professional reports, legal documents, and tracked changes. Use proactively when quality and precise formatting are critical. Examples: - user: "Create a professional report in Word" -> use python-docx with render loops - user: "Draft a legal contract with redlines" -> use ooxml redlining workflow - user: "Extract text from this DOCX while preserving structure" -> use pandoc markdown conversion
testing
Apply professional visual themes to documents and presentations. Use for styling artifacts with consistent color palettes and font pairings. Use proactively to quickly improve the aesthetic quality of deliverables. Examples: - user: "Apply a modern theme to this deck" -> use Modern Minimalist theme - user: "I want a tech aesthetic for this doc" -> apply Tech Innovation theme - user: "Create a custom theme for my project" -> generate new color/font specification
tools
Guide for creating effective opencode skills. Use for creating or updating skills that extend agent capabilities with specialized knowledge, workflows, or tool integrations. Examples: - user: "Create a skill for git workflows" → define SKILL.md with instructions and examples - user: "Add examples to my skill" → follow the user: "query" → action pattern - user: "Update skill description" → use literal block scalar and trigger contexts - user: "Structure a complex skill" → organize with scripts/ and references/ directories - user: "Validate my skill" → check structure, frontmatter, and discovery triggers