MCPInstall

pr-retro

Learn from PR outcomes.

Installs
607
Last 24h
—
Trending rank
—
Security
Not audited

Install

Works with every agent the skills CLI supports.

npx skills add https://github.com/boshu2/agentops --skill pr-retro
  1. 01

    Install

    Run the command in your project. The CLI asks which agents to install for.

  2. 02

    Describe the task

    Ask your agent for something this skill covers. It loads pr-retro automatically when relevant.

  3. 03

    Review the result

    The agent follows the SKILL.md steps, scripts and references bundled with the skill.

SKILL.md

The instructions your agent reads when the skill is triggered.

PR Retro Skill

Learn from PR outcomes by analyzing accept/reject patterns.

Overview

After a PR is merged or rejected, analyze what worked and what didn't to improve future contributions.

Output: .agents/learnings/YYYY-MM-DD-pr-{repo}-{outcome}.md

When to Use:

  • After a PR is merged (capture success patterns)
  • After a PR is rejected (understand why)
  • After receiving significant review feedback
  • Periodically to review contribution patterns

Workflow

1.  PR Discovery    -> Find the PR to analyze
2.  Outcome Analysis -> Merged/rejected/changes requested
3.  Feedback Extraction -> What did reviewers say?
4.  Pattern Identification -> What worked/didn't
5.  Lesson Extraction -> Reusable learnings
6.  Output -> Write retro document

Phase 1: PR Discovery

# If PR number provided
gh pr view <number> --json state,reviews,comments,mergedAt,closedAt

# Find recent PRs by you
gh pr list --state all --author @me --limit 10

# Find PRs to a specific repo
gh pr list -R <owner/repo> --state all --author @me --limit 10

Phase 2: Outcome Analysis

OutcomeMeaningFocus
MergedSuccessWhat worked?
Closed (not merged)RejectedWhy?
Open (stale)Ignored/abandonedWhat went wrong?
Changes requestedNeeds workWhat feedback?
# Get PR outcome
gh pr view <number> --json state,mergedAt,closedAt,reviews

Phase 3: Feedback Extraction

# Get all review comments
gh pr view <number> --json reviews --jq '.reviews[] | "\(.author.login): \(.body)"'

# Get all comments
gh api repos/<owner>/<repo>/pulls/<number>/comments --jq '.[].body'

# Get requested changes
gh pr view <number> --json reviews --jq '.reviews[] | select(.state == "CHANGES_REQUESTED")'

Feedback Categories

CategoryExamples
StyleNaming, formatting, conventions
TechnicalAlgorithm, architecture, patterns
ScopeToo big, scope creep, unrelated changes
TestingMissing tests, coverage, edge cases
DocumentationMissing docs, unclear comments
ProcessWrong branch, missing sign-off

Phase 4: Pattern Identification

Success Patterns (If Merged)

What WorkedEvidence
Small, focused PR< 5 files
Followed conventionsNo style comments
Good testsNo "add tests" requests
Clear descriptionQuick approval

Failure Patterns (If Rejected)

What FailedEvidence
Too large"Please split this PR"
Scope creep"This is out of scope"
Missing tests"Please add tests"
Wrong approach"Consider using X instead"

Phase 5: Lesson Extraction

Lesson Template

## Lesson: [Title]

**Context**: [When does this apply?]
**Learning**: [What did we learn?]
**Action**: [What to do differently?]

**Evidence**:
- PR #N: [quote or summary]

Common Lessons

LessonAction
PR too largeSplit PRs under 200 lines
Missing contextAdd "## Context" section
Style mismatchRun linter before PR
Missing testsAdd tests for new code
Slow reviewPing after 1 week

Phase 6: Output

Write to .agents/learnings/YYYY-MM-DD-pr-{repo}-{outcome}.md

# PR Retro: {repo} #{number}

**Date**: YYYY-MM-DD
**PR**: {url}
**Outcome**: Merged / Rejected / Stale

## Summary

{What was the PR about? What happened?}

## Timeline

| Date | Event |
|------|-------|
| {date} | PR opened |
| {date} | First review |
| {date} | {outcome} |

## Feedback Analysis

### Positive Feedback
- {quote}

### Requested Changes
- {quote}

### Rejection Reasons (if applicable)
- {quote}

## Lessons Learned

### Lesson 1: {title}
**Context**: {when this applies}
**Learning**: {what we learned}
**Action**: {what to do differently}

## Updates to Process

{Any changes to make to pr-prep, pr-plan, or other skills}

## Next Steps

{Future actions based on this retro}

Anti-Patterns

DON'TDO INSTEAD
Skip retros on merged PRsLearn from success too
Blame maintainersFocus on what YOU can change
Generic lessonsSpecific, actionable learnings
Skip rejected PRsMost valuable learning source

Examples

Learn From Rejected PR

User says: "Run a retro on why this PR was rejected."

What happens:

  1. Analyze reviewer feedback and timeline.
  2. Identify preventable process and scope issues.
  3. Capture reusable lessons for future PRs.

Learn From Successful Merge

User says: "Extract what worked from this merged PR."

What happens:

  1. Identify patterns that sped review/approval.
  2. Distill actionable playbook updates.
  3. Save lessons for future contribution flows.

Troubleshooting

ProblemCauseSolution
Retro is genericFeedback not tied to evidenceCite specific comments/decisions and outcomes
No clear lesson extractedAnalysis stayed descriptiveConvert observations into behavior changes
Maintainer signal is mixedContradictory review commentsSeparate hard blockers from preference feedback
Process changes not adoptedLessons not operationalizedAdd explicit updates to prep/plan/validate workflow

FAQ

What does the pr-retro skill do?

Learn from PR outcomes.

How do I install pr-retro?

Run npx skills add https://github.com/boshu2/agentops --skill pr-retro in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/pr-retro/ (personal) or .claude/skills/pr-retro/ (project).

Which AI agents can use pr-retro?

Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.

Is pr-retro safe to install?

No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.

Who maintains pr-retro?

It is published by boshu2 in boshu2/agentops. It has 607 recorded installs.

More from boshu2/agentops

View all →

council

boshu2/agentops

Compare independent opinions from several models or contexts without inflating agreement. Use when: wanting a second opinion or debate, or summarizing several reviewers' results.

3K installs

doc

boshu2/agentops

Write source-checked docs, READMEs, change descriptions and handoffs. Use when: documenting a change, leaving or resuming a handoff, or drafting a questionnaire for someone else.

research

boshu2/agentops

Answer one cited question on code, history, claims or patterns. Use when: asked how it works, why it changed, if a claim or done/shipped report holds, or a pattern warrants a rule.

plan

boshu2/agentops

Shape a request into one end-to-end slice with observable behavior; review write scope and reversible decisions. Use when: planning, breaking down or scoping a change.

swarm

boshu2/agentops

Dispatch explicit disjoint packets exactly once through a caller-selected executor. Triggers: "swarm", "dispatch disjoint packets", "parallel explicit tasks".

1.5K installs

rpi

boshu2/agentops

Drive one accepted change through implementation and checks to done, with one fresh review only where a mistake is costly. Use when: asked to run or orchestrate work through RPI.

Popular code quality & workflow skills

View category →

grill-me

mattpocock/skills

A relentless interview to sharpen a plan or design.

Scan a codebase for deepening opportunities, present them as a visual HTML report, then grill through whichever one you pick.

handoff

mattpocock/skills

Compact the current conversation into a handoff document for another agent to pick up.

domain-modeling

mattpocock/skills

Build and sharpen a project's domain model. Use when discussing codebase terminology, writing or editing a GLOSSARY.md, or recording or editing an ADR.

codebase-design

mattpocock/skills

Shared vocabulary for designing deep modules. Use when the user wants to design or improve a module's interface, find deepening opportunities, decide where a seam goes, make code more testable or AI-navigable, or when another skill needs the deep-module vocabulary.

diagnosing-bugs

mattpocock/skills

Diagnosis loop for hard bugs and performance regressions. Use when the user says "diagnose"/"debug this", or reports something broken/throwing/failing/slow.