From sdk-bridge
Convert markdown PRDs into prd.json execution format for SDK Bridge autonomous agents. Use when a PRD document exists and needs to be converted to SDK Bridge's JSON format. Trigger on 'convert prd', 'convert to prd.json', 'turn this PRD into sdk-bridge format', 'create prd.json from this PRD'. Also used internally by /sdk-bridge:start at the conversion checkpoint. Do NOT trigger on general JSON conversion or plan execution requests.
npx claudepluginhub joshuarweaver/cascade-ai-ml-agents-misc-2 --plugin flight505-sdk-bridgeThis skill uses the workspace's default tool permissions.
Converts existing PRDs to the prd.json format that SDK Bridge uses for Agent Teams execution.
Searches, retrieves, and installs Agent Skills from prompts.chat registry using MCP tools like search_skills and get_skill. Activates for finding skills, browsing catalogs, or extending Claude.
Searches prompts.chat for AI prompt templates by keyword or category, retrieves by ID with variable handling, and improves prompts via AI. Use for discovering or enhancing prompts.
Checks Next.js compilation errors using a running Turbopack dev server after code edits. Fixes actionable issues before reporting complete. Replaces `next build`.
Converts existing PRDs to the prd.json format that SDK Bridge uses for Agent Teams execution.
Take a PRD (markdown file or text) and convert it to prd.json in your project directory.
{
"project": "[Project Name]",
"branchName": "sdk-bridge/[feature-name-kebab-case]",
"description": "[Feature description from PRD title/intro]",
"userStories": [
{
"id": "US-001",
"title": "[Story title]",
"description": "As a [user], I want [feature] so that [benefit]",
"acceptanceCriteria": [
"Criterion 1",
"Criterion 2 with verification",
"Typecheck passes"
],
"priority": 1,
"passes": false,
"notes": "",
"depends_on": [],
"related_to": [],
"implementation_hint": "",
"check_before_implementing": []
}
]
}
["US-001", "US-005"])["US-002"])["grep cabin_class api.py"])When to use each:
depends_on: Hard dependency - this story CANNOT be done until dependency completesrelated_to: Soft dependency - check this story for similar code or patternsimplementation_hint: Free-form text guidance for the agentcheck_before_implementing: Specific search commands to detect existing implementationEach story should be independently implementable by one teammate in a single session.
SDK Bridge uses Agent Teams — multiple teammates run in parallel, each claiming and implementing one story at a time. Stories must be self-contained: a teammate implementing US-003 cannot rely on in-progress work from another teammate implementing US-002.
Data Layer:
Logic Layer:
Presentation Layer:
Pattern: "Build entire [subsystem]"
Pattern: "Add complex [feature]"
Pattern: "Refactor [large module]"
Rule of thumb: If you cannot describe the change in 2-3 sentences, it is too big.
Validation Rules:
After converting, check for oversized stories:
jq '.userStories[] | select((.acceptanceCriteria | length) > 7) | "\(.id): \(.title) - \(.acceptanceCriteria | length) criteria (TOO LARGE)"'
If you find stories with 8+ criteria, recommend splitting them in your output.
Stories execute in priority order. Earlier stories must not depend on later ones.
Correct order:
Wrong order:
Each criterion must be something SDK Bridge can CHECK, not something vague.
status column to tasks table with default 'pending'""Typecheck passes"
For stories with testable logic, also include:
"Tests pass"
"Verify in browser using dev-browser skill"
Frontend stories are NOT complete until visually verified. SDK Bridge will use the dev-browser skill to navigate to the page, interact with the UI, and confirm changes work.
passes: false and empty notessdk-bridge/depends_on, related_to, and add hints (see below)Auto-detect depends_on:
⚠️ Avoid False Dependencies:
depends_on for TRUE blocking dependenciesTrue Dependencies (add depends_on):
False Dependencies (NO depends_on, use related_to):
Auto-detect related_to:
Generate implementation_hint:
related_to is not empty: "Check US-XXX for similar implementation patterns"Generate check_before_implementing:
Extract key identifiers from acceptance criteria and create search commands:
For data models: grep -rn "[ModelName]\|[field_name]" src/models/
For API/services: grep -rn "[endpoint_name]\|[function_name]" src/api/ src/services/
For UI components: grep -rn "[ComponentName]" src/components/ src/pages/
For configuration: grep -rn "[config_key]" config/ .env
Use actual identifiers from the story (class names, function names, field names), not generic terms.
Scenario: Feature requiring data model, API endpoint, and UI
PRD Stories:
### US-010: Add status field to data model
### US-011: Create filtering API endpoint
### US-012: Build filter UI component
Dependency Analysis:
depends_on: ["US-010"]depends_on: ["US-011"]related_to: ["US-010"]Converted to JSON:
{
"id": "US-012",
"title": "Build filter UI component",
"depends_on": ["US-011"],
"related_to": ["US-010"],
"implementation_hint": "US-010 added the status field to the data model. US-011 implemented the filtering endpoint. Review both for field names and API contract.",
"check_before_implementing": [
"grep -rn 'status' src/models/",
"grep -rn 'filter.*status' src/api/"
]
}
Apply systematic decomposition when features have 8+ acceptance criteria:
Pattern 1: Layer-Based Split
Monolithic: "Add [feature] system"
↓
Decomposed:
1. "Implement [feature] data model"
2. "Create [feature] business logic"
3. "Build [feature] API endpoints"
4. "Design [feature] UI components"
5. "Add [feature] user workflows"
Pattern 2: Capability-Based Split
Monolithic: "Build advanced [feature]"
↓
Decomposed:
1. "Implement basic [feature] functionality"
2. "Add [feature] configuration options"
3. "Implement [feature] batch operations"
4. "Add [feature] export capability"
Pattern 3: Journey-Based Split
Monolithic: "Implement [workflow]"
↓
Decomposed:
1. "Implement [workflow] step 1: [action]"
2. "Implement [workflow] step 2: [action]"
3. "Implement [workflow] step 3: [action]"
4. "Add [workflow] error recovery"
Each story focuses on one responsibility and can be verified independently.
Input PRD:
# Task Status Feature
Add ability to mark tasks with different statuses.
## Requirements
- Toggle between pending/in-progress/done on task list
- Filter list by status
- Show status badge on each task
- Persist status in database
Output prd.json:
{
"project": "TaskApp",
"branchName": "sdk-bridge/task-status",
"description": "Task Status Feature - Track task progress with status indicators",
"userStories": [
{
"id": "US-001",
"title": "Add status field to tasks table",
"description": "As a developer, I need to store task status in the database.",
"acceptanceCriteria": [
"Add status column: 'pending' | 'in_progress' | 'done' (default 'pending')",
"Generate and run migration successfully",
"Typecheck passes"
],
"priority": 1,
"passes": false,
"notes": ""
},
{
"id": "US-002",
"title": "Display status badge on task cards",
"description": "As a user, I want to see task status at a glance.",
"acceptanceCriteria": [
"Each task card shows colored status badge",
"Badge colors: gray=pending, blue=in_progress, green=done",
"Typecheck passes",
"Verify in browser using dev-browser skill"
],
"priority": 2,
"passes": false,
"notes": "",
"depends_on": ["US-001"],
"related_to": [],
"implementation_hint": "Reuse existing badge component if available, just add status color variants.",
"check_before_implementing": [
"grep -r 'Badge' components/",
"grep status tasks/"
]
},
{
"id": "US-003",
"title": "Add status toggle to task list rows",
"description": "As a user, I want to change task status directly from the list.",
"acceptanceCriteria": [
"Each row has status dropdown or toggle",
"Changing status saves immediately",
"UI updates without page refresh",
"Typecheck passes",
"Verify in browser using dev-browser skill"
],
"priority": 3,
"passes": false,
"notes": ""
},
{
"id": "US-004",
"title": "Filter tasks by status",
"description": "As a user, I want to filter the list to see only certain statuses.",
"acceptanceCriteria": [
"Filter dropdown: All | Pending | In Progress | Done",
"Filter persists in URL params",
"Typecheck passes",
"Verify in browser using dev-browser skill"
],
"priority": 4,
"passes": false,
"notes": ""
}
]
}
Before writing a new prd.json, check if there is an existing one from a different feature:
prd.json if it existsbranchName differs from the new feature's branch nameprogress.jsonl exists and is non-empty:
archive/YYYY-MM-DD-feature-name/prd.json and progress.jsonl to archiveprogress.jsonl (it will be recreated fresh by implementer teammates)If you are manually updating prd.json between runs, archive first.
After writing prd.json, output a dependency analysis to help the team lead decide how many teammates to spawn:
## Dependency Graph
Parallel groups (can run simultaneously):
- Group 1: US-001 (no deps)
- Group 2: US-002, US-003 (depend on US-001, independent of each other)
- Group 3: US-004 (depends on US-002, US-003)
Suggested teammate count: 2 (max parallelism in Group 2)
Total stories: 4 | Parallelizable: 2 | Sequential: 2
This helps the start command calculate min(max_teammates, max_parallel_group_size).
Before writing prd.json, verify: