agentleFS
Cor-IncorporatedCor-Incorporated/claude-code-skills/skills/review-loop/SKILL.md

review-loop

Skill5 starsChanged 2 months agoMITView on GitHub

CI green + claude-review LGTM まで自動ループ。push → CI待ち → 全レビューソースチェック → 修正 → 再push を繰り返す

  • Commits and pushes

54 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use motion-design, polish and 10 more.

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.
  • soilmassSkill

    motion-design

    Create animations and motion graphics using industry standards. Use when asked to animate UI elements, create video content, implement transitions, or build motion systems. Implements W3C Design Tokens, Material Design 3 baseline, and Lottie specification compliance.

    Also in 5 projects that use this

  • HK-hubSkill

    polish

    Performs a final quality pass fixing alignment, spacing, consistency, and micro-detail issues before shipping. Use when the user mentions polish, finishing touches, pre-launch review, something looks off, or wants to go from good to great.

    Also in 3 projects that use this

  • GoogleSkill

    to-spec

    Turn the current conversation into a spec and publish it to the project issue tracker — no interview, just synthesis of what you've already discussed.

    Also in 4 projects that use this

  • GoogleSkill

    improve-codebase-architecture

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

    Also in 5 projects that use this

  • AWSSkill

    ship

    Finalize dev work on an issue branch — update docs, push, and open a PR.

    Also in 4 projects that use this

  • MicrosoftSkill

    council

    Convene the persona panel — six orthogonal review lenses — on a target. Cold independent fan-out, debate-to-consensus, synthesized verdict with recorded dissent and a roster manifest.

    Also in 3 projects that use this

  • +4 more from google

The file

Files
SKILL.md

/review-loop — CI + Review 自動修正ループ

PR の CI/CD が全てグリーンになり、かつ claude-review の指摘が全て解消されるまで自動的にループする。

使い方

/review-loop 218          # 単一PR
/review-loop --all-prs    # 全open PRをチェック

ループの流れ

┌─────────────────────────────────────────────┐
│ 1. CI/CD チェック (gh pr checks)             │
│    ├─ FAIL → build-error-resolver で修正     │
│    └─ PASS → 次へ                           │
├─────────────────────────────────────────────┤
│ 2. レビュー全ソースチェック                    │
│    ├─ Source 1: /pulls/{pr}/reviews (body)   │
│    ├─ Source 2: /pulls/{pr}/comments (inline)│
│    └─ Source 3: /issues/{pr}/comments (summary)│
├─────────────────────────────────────────────┤
│ 3. 指摘分類                                  │
│    ├─ MUST FIX → エージェントで並列修正       │
│    ├─ SHOULD FIX → エージェントで修正         │
│    └─ OBSERVATION → コメントのみ、修正不要     │
├─────────────────────────────────────────────┤
│ 4. 修正 commit & push                       │
│    └─ ステップ1に戻る                        │
├─────────────────────────────────────────────┤
│ 5. ALL GREEN + NO MUST/SHOULD FIX           │
│    → ✅ LGTM宣言、merge可能                  │
└─────────────────────────────────────────────┘

実行手順

<important if="running CI checks or diagnosing CI failures on a PR">

Step 1: CI/CDステータス確認

gh pr checks {PR_NUMBER}
  • 全て pass → Step 2 へ
  • fail あり → 失敗ログを取得し、build-error-resolver エージェントで修正
  • pending → 待機(最大10分)
</important><important if="collecting review comments from GitHub PR or checking review coverage">

Step 2: 全レビューソースチェック(3箇所必須)

bash ~/.claude/scripts/check-pr-reviews.sh {PR_NUMBER}

このスクリプトは以下の3箇所全てを確認する:

  1. gh api repos/{owner}/{repo}/pulls/{pr}/reviews — レビューbody
  2. gh api repos/{owner}/{repo}/pulls/{pr}/comments — インラインコメント
  3. gh api repos/{owner}/{repo}/issues/{pr}/comments — レビューサマリ(issue comments)

重要: /issues/{pr}/comments のレビューサマリを見落とさないこと! claude-review は以下の3つの方法でコメントを残す:

  • レビューbody(空のことが多い)
  • インラインコメント(特定行への指摘)
  • issue comment(全体サマリ、MUST FIX / SHOULD FIX の分類あり)

Step 3: 最新レビューの指摘内容を取得

# 最新のレビューサマリ(最重要)
gh api "repos/{owner}/{repo}/issues/{pr}/comments" \
  --jq '[.[] | select(.user.login == "claude[bot]")] | last | .body'

# 最新pushのインラインコメント
gh api "repos/{owner}/{repo}/pulls/{pr}/comments" \
  --jq '[.[] | select(.user.login == "claude[bot]")] | last(5) | {path, line, body}'
</important><important if="processing review feedback and classifying review findings for a PR">

Step 4: 指摘を分類して修正

  • MUST FIX / 🔴 / Bug: 必ず修正。エージェントに委任可能
  • SHOULD FIX / 🟠: 修正推奨。エージェントに委任可能
  • OBSERVATION / 🟡 / Minor / Nit: 修正不要。次のPRで対応可

Step 5: 修正 → commit → push → ループ

# 修正をコミット
git add -A && git commit -m "fix: address claude-review round N findings"
git push origin {branch}

→ Step 1 に戻る

</important><important if="determining whether a PR is ready to merge or declaring LGTM">

Step 6: LGTM判定

以下の条件を全て満たした場合にLGTM:

  • gh pr checks が全て pass
  • 最新レビューサマリに MUST FIX が 0
  • 最新インラインコメントに未対応の指摘が 0
  • ruff format / gofmt / eslint がクリーン
</important>

ルール

  • 最大ループ回数: 5回。5回で収束しない場合はユーザーに報告
  • エージェント活用: 修正は必ずバックグラウンドエージェントに委任(コンパクティング回避)
  • 並列修正: 複数PRの修正は並列エージェントで実行
  • ruff/gofmt: 修正commitの前に必ずフォーマッタを実行
  • レビュータイムスタンプ検証: pushごとに最新レビューが最新pushより後であることを確認

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.