Agent skill

Suggest Reviewers

by openshift-eng in openshift-eng/ai-helpers

Git blame analysis helper for the suggest-reviewers command. An agent skill from openshift-eng/ai-helpers.

Apache-2.0Auto-check passedDevelopment

Install Suggest Reviewers

skills CLI
$ npx skills add openshift-eng/ai-helpers --skill suggest-reviewers -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install openshift-eng/ai-helpers suggest-reviewers --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/openshift-eng/ai-helpers.git skills-src && mkdir -p .claude/skills && cp -r skills-src/plugins/git/skills/suggest-reviewers .claude/skills/suggest-reviewers && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
suggest-reviewers
GitHub stars
120
Token cost
~2.4k tokens
SKILL.md length
777 words
Files
2
Skills in repo
118
Repo updated
First seen
Licence
Apache-2.0

At a glance

Git blame analysis helper for the suggest-reviewers command. An agent skill from openshift-eng/ai-helpers.

  • Works in 4 steps: Collect changed files → Invoke the script → Parse the output → …
  • Tasks that involve Git workflow
  • SKILL.md covers When to Use This Skill, Prerequisites, Helper Script: analyze_blame.py and Implementation Steps, plus 5 more sections
  • Runs Python scripts from its folder; calls python3, git and jq

What it does

Suggest Reviewers is an agent skill from openshift-eng/ai-helpers. Git blame analysis helper for the suggest-reviewers command

Its SKILL.md is about 2.4k tokens, which your agent loads only when the skill is triggered. The skill folder holds 1 other file (for example `analyze_blame.py`).

It sits in Development, covering Git workflow. It works with Git. The repository describes itself as: Developer productivity tools for Claude Code & other AI assistants. The licence is Apache-2.0.

When your agent uses it

  • Tasks that involve Git workflow

Example prompts

  • “/suggest-reviewers”

Requirements

  • Python 3

Workflow steps

4 steps, taken from the step headings in SKILL.md.

  1. Collect changed files
  2. Invoke the script
  3. Parse the output
  4. Combine with OWNERS data

What it can do on your machine

Read from SKILL.md and the folder at commit a627176. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships script files (Python), which the agent can run.

    Shell commands in SKILL.md call:

    • python3
    • git
    • jq

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Links to these hosts (documentation or services it may open):

    • git-scm.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Suggest Reviewers loads about 2.4k tokens when it runs. Until then it costs about 19 tokens; SKILL.md has 777 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~19
When it runs · the whole SKILL.md, loaded when a task matches
~2.4k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from openshift-eng/ai-helpers at commit a627176, republished under its Apache-2.0 licence (© openshift-eng). 777 words, ~2,446 tokens.

Download SKILL.mdSave it as .claude/skills/suggest-reviewers/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
suggest-reviewers
description
Git blame analysis helper for the suggest-reviewers command

Suggest Reviewers Helper

This skill provides a Python helper script that analyzes git blame data for the /git:suggest-reviewers command. The script handles the complex task of identifying which lines were changed and who authored the original code.

When to Use This Skill

Use this skill when implementing the /git:suggest-reviewers command. The helper script should be invoked during Step 3 of the command implementation (analyzing git blame for changed lines).

DO NOT implement git blame analysis manually - always use the provided analyze_blame.py script.

Prerequisites

  • Python 3.6 or higher
  • Git repository with commit history
  • Git CLI available in PATH

Helper Script: analyze_blame.py

The analyze_blame.py script automates the complex process of:

  1. Parsing git diff output to identify specific line ranges that were modified
  2. Running git blame on only the changed line ranges (not entire files)
  3. Extracting and aggregating author information with statistics
  4. Filtering out bot accounts automatically
Usage

For uncommitted changes:

bash
python3 ${CLAUDE_PLUGIN_ROOT}/skills/suggest-reviewers/analyze_blame.py \
  --mode uncommitted \
  --file path/to/file1.go \
  --file path/to/file2.py \
  --output json

For committed changes on a feature branch:

bash
python3 ${CLAUDE_PLUGIN_ROOT}/skills/suggest-reviewers/analyze_blame.py \
  --mode committed \
  --base-branch main \
  --file path/to/file1.go \
  --file path/to/file2.py \
  --output json
Parameters
  • --mode: Required. Either uncommitted or committed

    • uncommitted: Analyzes unstaged/staged changes against HEAD
    • committed: Analyzes committed changes against a base branch
  • --base-branch: Required when mode is committed. The base branch to compare against (e.g., main, master)

  • --file: Can be specified multiple times. Each file to analyze for blame information. Only changed files should be passed.

  • --output: Output format. Default is json. Options:

    • json: Machine-readable JSON output
    • text: Human-readable text output
Output Format (JSON)
json
{
  "Author Name": {
    "line_count": 45,
    "most_recent_date": "2024-10-15T14:23:10",
    "files": ["file1.go", "file2.go"],
    "email": "author@example.com"
  },
  "Another Author": {
    "line_count": 23,
    "most_recent_date": "2024-09-20T09:15:33",
    "files": ["file3.py"],
    "email": "another@example.com"
  }
}
Output Fields
  • line_count: Total number of modified lines authored by this person
  • most_recent_date: ISO 8601 timestamp of their most recent contribution to the changed code
  • files: Array of files where this author has contributions in the changed lines
  • email: Author's email address from git commits
Bot Filtering

The script automatically filters out common bot accounts:

  • GitHub bots (e.g., dependabot[bot], renovate[bot])
  • CI bots (e.g., openshift-ci-robot, k8s-ci-robot)
  • Generic bot patterns (any name containing [bot] or ending in -bot)

Implementation Steps

Step 1: Collect changed files

Before invoking the script, collect the list of changed files based on the scenario:

Uncommitted changes:

bash
# Get staged and unstaged files
files=$(git diff --name-only --diff-filter=d HEAD)
files+=" $(git diff --name-only --diff-filter=d --cached)"

Committed changes:

bash
# Get files changed from base branch
files=$(git diff --name-only --diff-filter=d ${base_branch}...HEAD)
Step 2: Invoke the script

Build the command with the appropriate mode and all changed files:

bash
# Start building the command
cmd="python3 ${CLAUDE_PLUGIN_ROOT}/skills/suggest-reviewers/analyze_blame.py"

# Add mode
if [ "$has_uncommitted" = true ] || [ "$on_base_branch" = true ]; then
  cmd="$cmd --mode uncommitted"
else
  cmd="$cmd --mode committed --base-branch $base_branch"
fi

# Add each file
for file in $files; do
  cmd="$cmd --file $file"
done

# Add output format
cmd="$cmd --output json"

# Execute and capture JSON output
blame_data=$($cmd)
Step 3: Parse the output

The JSON output can be parsed using Python, jq, or any JSON parser:

bash
# Example using jq to get top contributor
echo "$blame_data" | jq -r 'to_entries | sort_by(-.value.line_count) | .[0].key'

# Example using Python
python3 << EOF
import json
import sys

data = json.loads('''$blame_data''')

# Sort by line count
sorted_authors = sorted(data.items(), key=lambda x: x[1]['line_count'], reverse=True)

for author, stats in sorted_authors:
    print(f"{author}: {stats['line_count']} lines, last modified {stats['most_recent_date']}")
EOF
Step 4: Combine with OWNERS data

After getting blame data, merge it with OWNERS file information to produce the final ranked list of reviewers.

Error Handling

No changed files

If no files are passed to the script:

Error: No files specified. Use --file option at least once.

Resolution: Ensure you've detected changed files (via git diff --name-only) before invoking the script.

Invalid mode

If an invalid mode is specified:

Error: Invalid mode 'invalid'. Must be 'uncommitted' or 'committed'.

Resolution: Use either --mode uncommitted or --mode committed.

Missing base branch in committed mode

If --mode committed is used without --base-branch:

Error: --base-branch is required when mode is 'committed'.

Resolution: Provide the base branch: --base-branch main

Show full SKILL.md (323 more words)Show less
File not in repository

If a specified file is not tracked by git:

Warning: File 'path/to/file' is not tracked by git, skipping.

Resolution: This is a warning and can be safely ignored. The script will skip untracked files.

No blame data found

If git blame returns no data for any files:

json
{}

Resolution: This can happen if:

  • All changed files are newly created (no blame history)
  • All changes are in binary files
  • Git blame is unable to run

In this case, fall back to OWNERS-only suggestions.

Examples

Example 1: Analyze uncommitted changes
bash
$ python3 analyze_blame.py --mode uncommitted --file src/main.go --file src/utils.go --output json
{
  "Alice Developer": {
    "line_count": 45,
    "most_recent_date": "2024-10-15T14:23:10",
    "files": ["src/main.go", "src/utils.go"],
    "email": "alice@example.com"
  },
  "Bob Engineer": {
    "line_count": 12,
    "most_recent_date": "2024-09-20T09:15:33",
    "files": ["src/main.go"],
    "email": "bob@example.com"
  }
}
Example 2: Analyze committed changes on feature branch
bash
$ python3 analyze_blame.py --mode committed --base-branch main --file pkg/controller/manager.go --output json
{
  "Charlie Contributor": {
    "line_count": 78,
    "most_recent_date": "2024-10-01T11:42:55",
    "files": ["pkg/controller/manager.go"],
    "email": "charlie@example.com"
  }
}
Example 3: Text output format
bash
$ python3 analyze_blame.py --mode uncommitted --file README.md --output text

Blame Analysis Results:
=======================

Alice Developer (alice@example.com)
  Lines: 23
  Most recent: 2024-10-15T14:23:10
  Files: README.md

Bob Engineer (bob@example.com)
  Lines: 5
  Most recent: 2024-08-12T16:30:21
  Files: README.md
Example 4: Multiple files with mixed results
bash
$ python3 analyze_blame.py --mode committed --base-branch release-4.15 \
    --file vendor/k8s.io/client-go/kubernetes/clientset.go \
    --file pkg/controller/node.go \
    --file docs/README.md \
    --output json
{
  "Diana Developer": {
    "line_count": 156,
    "most_recent_date": "2024-09-28T13:15:42",
    "files": ["vendor/k8s.io/client-go/kubernetes/clientset.go", "pkg/controller/node.go"],
    "email": "diana@example.com"
  },
  "Eve Technical Writer": {
    "line_count": 34,
    "most_recent_date": "2024-10-10T10:22:18",
    "files": ["docs/README.md"],
    "email": "eve@example.com"
  }
}

Technical Details

How the script works
  1. Determine diff range: Based on mode, calculates what to compare:

    • uncommitted: Compares working directory against HEAD
    • committed: Compares HEAD against base branch
  2. Parse diff output: Runs git diff with unified format to identify:

    • Which files changed
    • Which line ranges were added/modified
    • Ignores deleted lines (can't blame what doesn't exist)
  3. Run git blame: For each file and line range:

    • Runs git blame -L start,end --line-porcelain file
    • Parses porcelain format to extract author, email, and timestamp
    • Aggregates data across all changed lines
  4. Filter and aggregate:

    • Removes bot accounts
    • Groups by author name
    • Counts total lines per author
    • Tracks most recent contribution date
    • Lists all files each author contributed to
  5. Output results: Formats as JSON or text based on --output parameter

Performance considerations
  • Only blames changed line ranges, not entire files (much faster for small changes to large files)
  • Processes files in parallel when possible
  • Caches git commands where appropriate
  • Skips binary files automatically

Limitations

  • Does not handle file renames/moves (treats as delete + add)
  • Bot filtering is based on common patterns; custom bots may not be filtered
  • Requires git history; newly initialized repos may not have useful data
  • Does not consider commit message content or PR review history

See Also

© openshift-eng, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 1 other file in plugins/git/skills/suggest-reviewers of openshift-eng/ai-helpers.

  • SKILL.md
  • analyze_blame.py

Open the folder on GitHubat commit a627176

Compare with similar skills

Suggest Reviewers next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Suggest Reviewers compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Suggest Reviewers this skillopenshift-eng/ai-helpers120—~2.4kAutomated safety check: PassApache-2.0
Finishing a Development Branchobra/superpowers297k5 repos~1.9kAutomated safety check: PassMIT
Contributor-First PR MergeHKUDS/OpenHarness16k1 repos~847Automated safety check: PassMIT
Migrate Internal Package into GhostTryGhost/Ghost56k—~3.8kAutomated safety check: PassMIT
Create Pull Requestcline/cline70k1 repos~1.6kAutomated safety check: PassApache-2.0
Git Merge Conflict Resolvertailcallhq/forgecode7.6k1 repos~4.5kAutomated safety check: PassApache-2.0

Similar skills

  • Walks the last step of a branch: confirm tests pass, detect the git environment, ask how to integrate, carry out your choice and clean up the worktree.

    297k GitHub starsUsed in 5 repos~1.9k tokens
    DevelopmentAuto-check passed
  • Merges external GitHub pull requests while keeping the original author credited, and fixes conflicts after the merge instead of rewriting the contribution.

    16k GitHub starsUsed in 1 repo~847 tokens
    DevelopmentAuto-check passed
  • Moves a package from another TryGhost repository into Ghost as an internal workspace package while keeping its Git history, with checkpoints for the steps that need an administrator.

    56k GitHub stars~3.8k tokensUpdated today
    DevelopmentAuto-check passed
  • Opens a GitHub pull request from your current branch with the gh CLI, after reviewing the commits and diff and gathering the details the PR needs.

    70k GitHub starsUsed in 1 repo~1.6k tokens
    DevelopmentAuto-check passed
  • Git Merge Conflict Resolver

    tailcallhq/forgecode

    Resolves Git merge conflicts with a plan-first workflow that keeps both sides' intent, regenerates lock files and backs up deleted-but-modified files.

    7.6k GitHub starsUsed in 1 repo~4.5k tokens
    DevelopmentAuto-check passed
  • Git Branch Naming

    makeplane/plane

    Names a new Git branch with a type prefix, the lowercased work item ID and a short kebab-case description, so the ID can be extracted later from the branch name.

    61k GitHub stars~594 tokensUpdated 2 days ago
    DevelopmentAuto-check passed

More from openshift-eng/ai-helpers

All 118 skills in this repo
  • Investigate CI Reliability

    openshift-eng/ai-helpers

    Find and independently validate actionable reliability defects across OpenShift release jobs and presubmits, then export portable issue handoffs.

    120 GitHub stars~1.9k tokensUpdated 4 days ago
    Auto-check passed
  • Address Review PR

    openshift-eng/ai-helpers

    Fetch and address all PR review comments — categorize by priority, make code changes, post replies, and push.

    120 GitHub stars~2.9k tokensUpdated 4 days ago
    Auto-check passed
  • Categorize Activity Types

    openshift-eng/ai-helpers

    Categorize Jira issues into Red Hat Sankey Activity Type categories using MCP Jira tools.

    120 GitHub stars~2.4k tokensUpdated 4 days ago
    Auto-check passed
  • Has Review Work

    openshift-eng/ai-helpers

    Decide whether a GitHub PR has unanswered authorized review comments or new required CI failures worth a follow-up agent.

    120 GitHub stars~1.9k tokensUpdated 4 days ago
    Auto-check passed
  • Must Gather Analyzer

    openshift-eng/ai-helpers

    Analyze OpenShift must-gather diagnostic data including cluster operators, pods, nodes, and network components.

    120 GitHub stars~2.3k tokensUpdated 4 days ago
    Auto-check passed
  • Payload Autodl JSON

    openshift-eng/ai-helpers

    Schema for the autodl JSON data file produced by payload-analysis for database ingestion — you must use this skill whenever generating the autodl JSON file

    120 GitHub stars~2.6k tokensUpdated 4 days ago
    Auto-check passed

Works with

Categories

Questions about Suggest Reviewers

What does Suggest Reviewers do?

Git blame analysis helper for the suggest-reviewers command. An agent skill from openshift-eng/ai-helpers. Suggest Reviewers is an agent skill from openshift-eng/ai-helpers.

When should I use Suggest Reviewers?

Suggest Reviewers fits situations like: tasks that involve Git workflow.

How do I install Suggest Reviewers in Claude Code?

Run `npx skills add openshift-eng/ai-helpers --skill suggest-reviewers -a claude-code`. Or copy the skill folder (plugins/git/skills/suggest-reviewers in openshift-eng/ai-helpers) into .claude/skills/suggest-reviewers in your project. Claude Code loads it when a task matches its description.

How do I install Suggest Reviewers in Codex?

Run `npx skills add openshift-eng/ai-helpers --skill suggest-reviewers -a codex`. Or copy the skill folder (plugins/git/skills/suggest-reviewers in openshift-eng/ai-helpers) into .agents/skills/suggest-reviewers in your project. Codex loads it when a task matches its description.

Can I use Suggest Reviewers in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add openshift-eng/ai-helpers --skill suggest-reviewers -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/suggest-reviewers, .gemini/skills/suggest-reviewers, .github/skills/suggest-reviewers and .opencode/skills/suggest-reviewers in your project.

What does Suggest Reviewers need to run?

Going by SKILL.md and its folder, Suggest Reviewers needs Python for the scripts in its folder and the command-line tools its instructions call (python3, git and jq). Our summary lists: Python 3.

Does Suggest Reviewers access the network?

SKILL.md names 1 domain. As links in the text: git-scm.com. This is read from the text; nothing was executed.

Is Suggest Reviewers safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Suggest Reviewers use?

Suggest Reviewers is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Suggest Reviewers use?

About 2.4k tokens (SKILL.md is roughly 9.8k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Suggest Reviewers?

Skills that share tags, products or a category with Suggest Reviewers: Finishing a Development Branch (obra/superpowers, 297k stars), Contributor-First PR Merge (HKUDS/OpenHarness, 16k stars), Migrate Internal Package into Ghost (TryGhost/Ghost, 56k stars) and Create Pull Request (cline/cline, 70k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Suggest Reviewers?

openshift-eng (a GitHub organization) maintains it in openshift-eng/ai-helpers, which has 120 GitHub stars. The repository holds 118 skills in this directory. The repository was last updated on October 6, 2026.

Source: openshift-eng/ai-helpers on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.