arc-prd
Architecture review for a PRD. Analyzes codebase through separation-of-concerns and tactical-ddd lenses, surfaces architectural…
Analyze PR feedback patterns and suggest config updates to catch issues locally
> /plugin marketplace add NTCoding/claude-skillzHow it fires
How this command gets triggered: by you, by Claude, or both.
/learn-from-prsContext preview
What this command does when you run it.
Analyze PR feedback patterns and suggest config updates to catch issues locally
argument-hint: "[--count <n>] [--state merged|closed|all]" description: Analyze PR feedback patterns and suggest config updates to catch issues locally allowed-tools: Bash, Glob, Read, Grep
Analyze feedback from recent PRs (CodeRabbit, SonarQube, developer comments) and suggest updates to project configuration to catch these issues before PR review.
ARGUMENTS: $ARGUMENTS
Check that `gh` CLI is authenticated:
gh auth status
If not authenticated, stop and inform user to run `gh auth login`.
gh pr list --state <state> --limit <count> --json number,title,url,mergedAt,closedAt
If no PRs found, report "No PRs found matching criteria" and stop.
Report:
Found X PRs to analyze: 1. #123: PR title 2. #124: PR title ...
For each PR, fetch ALL comments and reviews:
**PR review comments (inline code comments):**
gh api repos/{owner}/{repo}/pulls/{pr_number}/comments --paginate**PR reviews (approval/request changes with body):**
gh api repos/{owner}/{repo}/pulls/{pr_number}/reviews --paginate**Issue-style comments (general discussion):**
gh api repos/{owner}/{repo}/issues/{pr_number}/comments --paginateExtract from each comment:
**Categorize by source:**
Report:
Collected feedback from PR #X: - [Tool name]: Y comments - Human reviewers: Z comments
Group all collected feedback and identify patterns:
**Look for recurring themes such as:**
For each pattern found:
**Prioritize by:** 1. Frequency (appears in multiple PRs) 2. Source consistency (caught by multiple reviewers/tools) 3. Severity (security > bugs > style)
Report top patterns:
## Feedback Patterns Found ### High Frequency (appeared in 3+ PRs) 1. [Pattern]: [X occurrences] - caught by [sources] Example: "[actual comment snippet]" ### Medium Frequency (appeared in 2 PRs) ... ### Single Occurrence (but notable) ...
Search the project for ANY configuration files that might be relevant:
find . -maxdepth 3 -type f \( \ -name "CLAUDE.md" -o \ -name ".claude" -o \ -name ".*rc" -o \ -name ".*rc.json" -o \ -name ".*rc.yaml" -o \ -name ".*rc.yml" -o \ -name "*.config.js" -o \ -name "*.config.ts" -o \ -name "*.config.json" -o \ -name ".pre-commit-config.yaml" -o \ -name ".editorconfig" -o \ -name "Makefile" -o \ -name "pyproject.toml" -o \ -name "setup.cfg" -o \ -name "tox.ini" -o \ -name ".rubocop.yml" -o \ -name "Gemfile" -o \ -name "go.mod" -o \ -name "Cargo.toml" -o \ -name "composer.json" \ \) 2>/dev/null | head -50
Also check for `.claude/` directory contents.
For each relevant config, note:
Report:
## Current Configuration Found these config files: - [file]: [brief summary of what it controls] ...
For each high-frequency pattern, propose specific config updates:
**Format for each recommendation:**
### [Pattern Name] **Problem:** [What the PR feedback consistently caught] **Frequency:** [X occurrences across Y PRs] **Caught by:** [Tool names, specific reviewers] **Examples from PRs:** - PR #123: "[comment snippet]" - PR #456: "[comment snippet]" **Suggested fixes:** **Option A: CLAUDE.md** (catches during Claude Code sessions) ```markdown [Exact text to add to CLAUDE.md]
**Option B: [Relevant tool/config for this project]**
[Exact config to add, appropriate to the project's language/tooling]
**Option C: Pre-commit hook** (catches before commit)
[Hook configuration if applicable]
**Recommended:** [Which option and why]
### Step 7: Present Summary ```markdown # PR Feedback Analysis Complete ## PRs Analyzed - Count: X - Date range: [oldest] to [newest] - Feedback sources: [list tools and reviewer count] ## Key Findings ### Patterns That Should Be Caught Locally | Pattern | Frequency | Top Source | Recommended Fix | |---------|-----------|------------|-----------------| | [name] | X times | [source] | [config type] | ## Detailed Recommendations [Full recommendations from Step 6] ## Quick Wins (Copy-Paste Ready) ### Add to CLAUDE.md: ```markdown [All CLAUDE.md additions consolidated]
[Additions consolidated by config file]
--- *Analysis based on PRs: #X, #Y, #Z...* *Run `/learn-from-prs` again after implementing changes to verify improvement*
## Notes - This command only suggests changes, never modifies files - Focus recommendations on issues that appeared multiple times - For single-occurrence issues, mention them but deprioritize - Recommend fixes appropriate to the project's actual language and tooling - When a pattern could be caught by multiple tools, recommend the earliest in the pipeline - If feedback is vague or unclear, note it but don't force a recommendation
Reusable skills and composable system prompts for Claude Code.
Architecture review for a PRD. Analyzes codebase through separation-of-concerns and tactical-ddd lenses, surfaces architectural…
Facilitated discussion of all 3 design phases, producing an Architecture Decision Record
Force critical evaluation of proposals from 5 adversarial perspectives