agentleFS
Cogni-AI-OUCogni-AI-OU/cogni-ai-agent-skills/github-pr-review/SKILL.md

github-pr-review

Skill4 starsChanged 7 months agoMITView on GitHub

Comprehensive PR review workflow for verifying code quality, metadata accuracy, and merge readiness. You MUST load this skill when reviewing, auditing, or verifying a GitHub Pull Request.

8 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use git-commit.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • GitHubSkill

    git-commit

    Execute git commit with conventional commit message analysis, intelligent staging, and message generation. Use when user asks to commit changes, create a git commit, or mentions "/commit". Supports: (1) Auto-detecting type and scope from changes, (2) Generating conventional commit messages from diff, (3) Interactive commit with optional type/scope/description overrides, (4) Intelligent file staging for logical grouping

    Also in 3 projects that use this

The file

Show its rules and text

We split this skill into the rules it gives an agent

15 rules. 0 are common, 15 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 7 edited versions we read keep these.

  • 15

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    When fixing a localized, single-file typo where a full architectural review is overkill.

    line 20
  2. Distinctive:

    When the PR is in a Draft state and explicitly marked as "Do Not Review".

    line 21
  3. Distinctive:

    Intent & Purpose: Verify the PR clearly articulates the WHY (goals/user value), WHAT (scope/deliverables), and HOW (implementation …

    line 35
  4. Distinctive:

    Branch State: Verify if the PR branch is up-to-date with the base branch.

    line 37
  5. Distinctive:

    Comments Resolution: Check for any existing unresolved comments or threads on the PR to ensure previous feedback has been integrated.

    line 38
  6. Distinctive:

    Metadata Accuracy: Ensure PR Title follows Conventional Commits and Description accurately reflects all changes.

    line 40
  7. Distinctive:

    Hygiene & Style: Check for trailing whitespace, debugger statements, and other hygiene issues.

    line 44
  8. Distinctive:

    Scope Control: Ensure the PR does strictly what it claims.

    line 45
  9. Distinctive:

    Integration Check: Verify that new code correctly integrates with existing patterns and dependencies.

    line 48
  10. Distinctive:

    Build & CI Status: Verify that all CI/CD checks (status checks) are passing.

    line 50
  11. Distinctive:

    Mergeability: Check mergeability status for conflicts.

    line 53
  12. Distinctive:

    Run local tests if applicable.

    line 94
  13. Distinctive:

    Blanket Approvals: Never approve without verifying EVERY checkpoint.

    line 100
  14. Distinctive:

    Ignoring Checks: Never skip checking the status of CI/CD pipelines.

    line 101
  15. Distinctive:

    Missing Context: Always read the PR description and linked issues before reviewing code.

    line 102

“Common” is measured: kept by at least 6 in 10 of the 7 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

GitHub PR Review

Elite autonomous PR review workflow for ensuring structural integrity, metadata accuracy, and zero-defect deployments.

When to Use

  • Triggered when asked to review, audit, or verify a GitHub Pull Request.
  • Loaded automatically during the final verification phase of a PR lifecycle.

When Not to Use

  • When fixing a localized, single-file typo where a full architectural review is overkill.
  • When the PR is in a Draft state and explicitly marked as "Do Not Review".
  • For evaluating purely aesthetic UI/UX changes that require manual visual inspection.

Common Pitfalls

  • Ignoring Base Branch Drift: Reviewing code without realizing the PR branch is severely outdated compared to main, leading to false positive approvals on code that will cause merge conflicts.
  • Rubber-Stamping CI Failures: Assuming a red CI check is "just a flaky test" without actually verifying the failure logs.
  • Nitpicking Over Architecture: Focusing exclusively on variable names and formatting while ignoring massive architectural flaws or security vulnerabilities.

Core Review Checkpoints

Execute these checks systematically using gh and git tools:

  • Discovery & Scope Alignment:
    • Intent & Purpose: Verify the PR clearly articulates the WHY (goals/user value), WHAT (scope/deliverables), and HOW (implementation strategy).
    • Branch State: Verify if the PR branch is up-to-date with the base branch.
    • Comments Resolution: Check for any existing unresolved comments or threads on the PR to ensure previous feedback has been integrated.
    • Metadata Accuracy: Ensure PR Title follows Conventional Commits and Description accurately reflects all changes.
  • Deep Code Inspection:
    • Inspection Framework: Apply the code-review skill's cognitive framework to evaluate code quality dimensions.
    • Atomic File Analysis: Step through the diff file-by-file or component-by-component.
    • Hygiene & Style: Check for trailing whitespace, debugger statements, and other hygiene issues.
    • Scope Control: Ensure the PR does strictly what it claims. Flag any drive-by changes or unrelated refactoring.
    • Overengineering Check: Aggressively apply YAGNI. Question "nice to have" features, premature optimizations, and abstractions that exceed core requirements.
    • Integration Check: Verify that new code correctly integrates with existing patterns and dependencies.
  • Verification & Merge Readiness:
    • Build & CI Status: Verify that all CI/CD checks (status checks) are passing.
    • Test-Driven Audit: Validate that adequate unit and integration tests accompany the changed vectors. Flag untested edge cases that were overlooked.
    • Mergeability: Check mergeability status for conflicts.

Workflow Execution

1. Context Gathering

# Get PR metadata and mergeability
gh pr view <pr-number> --json title,body,mergeable,state,baseRefName,headRefName

# List all files changed
gh pr view <pr-number> --json files --jq '.files[].path'

# Get status checks
gh pr checks <pr-number>

2. Deep Inspection

Refer to the code-review skill for the deep inspection framework and hygiene check patterns.

# List comments to ensure resolution
gh api repos/:owner/:repo/pulls/<pr-number>/comments

# Check for trailing whitespace and conflict markers in the diff
git diff <base-branch>...HEAD --check

3. Agent Delegation

For a comprehensive PR review, delegate specialized reviews to relevant project agents using the task tool to ensure thorough coverage:

  • Architectural Alignment: Delegate to cogni-ai-plan-reviewer to validate structural changes against project patterns.
  • Code Quality: Delegate to cogni-ai-code-reviewer for exhaustive idiomatic inspection and quality enforcement.
  • Security Review: Delegate to cogni-ai-security-auditor for focused PR security analysis.
  • Verification: Delegate to cogni-ai-tester to execute tests and verify edge-case behavior.

4. Verification

  • Run local tests if applicable.
  • Perform a "Design-It-Twice" comparison if the PR implements a complex architectural change.
  • Synthesize results from delegated agents (if any) into the final review summary.

What to Avoid

  • Blanket Approvals: Never approve without verifying EVERY checkpoint.
  • Ignoring Checks: Never skip checking the status of CI/CD pipelines.
  • Missing Context: Always read the PR description and linked issues before reviewing code.

Related Skills

  • critical-thinking: You MUST load this skill when applying deep analytical reasoning to complex changes.
  • tester: You MUST load this skill when designing or suggesting new tests to cover identified gaps.
  • code-review: You MUST load this skill when performing deep inspection of code changes.
  • gh-pr: You MUST load this skill when working with the gh pr command.
  • subagent-task: You MUST load this skill when delegating specialized review tasks to other agents.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.