skills/mp-prd-to-issues/SKILL.md
Break a PRD GitHub issue into vertical-slice sub-issues with blocking relationships. Use when: "break down PRD", "create sub-issues", "PRD to issues"
npx skillsauth add MartinoPolo/mpx-claude-code mp-prd-to-issuesInstall 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.
Break a PRD GitHub issue into independently implementable vertical slices. $ARGUMENTS
Issue body format: @skills/shared/GITHUB_ISSUE_TEMPLATE.md
gh CLI for all GitHub operationstask and either HITL or AFK (create labels if missing)addSubIssue GraphQL mutationgh issue view <number> --json title,body,labels
If the issue doesn't exist or has no body, stop and report.
Fetch all comments (these often contain clarifications, updates, or revised decisions that override the original body):
gh issue view <number> --json comments --jq '.comments[].body'
Fetch the PRD issue's node ID for later use in the addSubIssue mutation:
gh api graphql -f query='{ repository(owner: "OWNER", name: "REPO") { issue(number: <number>) { id } } }' --jq '.data.repository.issue.id'
Get owner/repo from gh repo view --json nameWithOwner --jq '.nameWithOwner'.
Before any decomposition, review the PRD body and comments for ambiguous or contradictory requirements, missing details, unresolved decisions, and open questions or TBDs.
If there are no unresolved questions: skip to Step 3 — most or all sub-issues will be AFK.
If there are unresolved questions: grill the user before proceeding:
Exception — question-heavy sub-issue: if a large cluster of questions applies to one specific slice (not the PRD overall), defer those questions by creating that sub-issue as HITL with the unanswered questions listed in its blockquote.
Use Glob/Grep to find files related to the PRD's domain. Identify existing patterns, services, components, data models, and architectural boundaries that inform slice design.
Break the PRD into vertical slices using the tracer-bullet concept:
For each sub-issue, define:
feat():, fix:, chore():)task plus area labels (e.g., area:api, area:ui, area:db)HITL is exclusively for situations resolved by asking the user. Visual inspection, manual testing, code review, and QA verification are NOT reasons for HITL.
When all questions were resolved in Step 2, most or all slices should be AFK.
Show the user:
Ask for explicit approval before creating anything. Accept feedback and revise.
gh label list --limit 100
Create missing labels (task, HITL, AFK, area labels):
gh label create "task" --description "Implementation task" --color "0E8A16" --force
gh label create "HITL" --description "Requires human interaction" --color "FBCA04" --force
gh label create "AFK" --description "Can be implemented autonomously" --color "0E8A16" --force
Create each sub-issue via gh issue create, then link as a native sub-issue using GraphQL.
# 1. Create the issue (HITL example — include blockquote with specific questions; omit for AFK)
ISSUE_URL=$(gh issue create --title "Short descriptive title" --label "task,HITL,area:api" --assignee @me --body "$(cat <<'EOF'
> **Unanswered questions:**
> - Should the API use cursor-based or offset pagination?
> - What's the rate limit for external callers?
## Description
[What and why]
## Requirements
- REQ-1: [Imperative statement mapped from PRD]
## Acceptance Criteria
- [ ] [Testable condition — maps to requirements above]
## Blocking Relationships
- Blocks #M (reason)
- Blocked by #N (reason)
## Notes
[Implementation hints, relevant files, constraints]
EOF
)")
# 2. Link as native sub-issue of the PRD
gh api graphql -f query="
mutation {
addSubIssue(input: {
issueId: \"<PRD_NODE_ID>\",
subIssueUrl: \"$ISSUE_URL\"
}) {
issue { number }
subIssue { number }
}
}
"
Use HITL or AFK label (not both) based on Step 4b classification. After all issues are created, update issue bodies with correct blocking cross-references if forward references were needed.
PRD: #<number> — <title>
Sub-issues created: <count>
Dependency Graph:
#A — Title A [HITL]
-> #B — Title B [AFK] (blocked by #A)
-> #C — Title C [AFK] (blocked by #A)
Issues:
- <url> — <title> [HITL]
- <url> — <title> [AFK]
development
Audit all active skills for consistency, convention drift, and common issues. Auto-fixes where possible, reports remaining issues. Use when: "audit skills", "skill audit", "check skills", "lint skills"
testing
Ship finished work: sync base, commit, push, PR, wait for CI green, merge. Use when: "ship it", "ship and merge", "ship this"
development
Scan recent Claude Code sessions for grilling/design discussions, extract decisions, and update CONTEXT.md + DECISIONS.md. Use when: "harvest decisions", "extract decisions from sessions", "update docs from sessions", "sync decisions"
tools
Consolidate CONTEXT.md: remove duplicates, outdated items, tighten language. Use when: "consolidate context", "clean up context", "simplify context", "consolidate requirements"