Add Claude PR review workflow#4423
Merged
Merged
Conversation
Re-introduces an automated Claude code review after #4381 dropped the previous version for runaway cost (~$10-15 per PR). Key changes from the old workflow: - Drops the `/code-review` plugin's multi-agent fanout. A single agent with a plain "Review this PR" prompt is enough and avoids the parallel subagent context blow-up that drove most of the old spend. - Caps the agent loop with `--max-turns 10` so a single review can't wander through the whole workspace. - Adds a `concurrency` group so back-to-back `@claude` comments cancel the previous in-flight run instead of paying twice. - Adds a `skip-claude-review` label escape hatch and skips bot-authored PRs. - Triggers on `opened` in addition to `ready_for_review`, plus `@claude` comments on PRs (not issues). Not using https://github.com/colbymchenry/codegraph for now: it replaces grep/Read exploration with a pre-built tree-sitter symbol graph, but (a) tree-sitter is weakest on Rust (no trait/macro/generic resolution), (b) the index would need rebuilding or caching on every CI run, and (c) the model choice and turn cap are far bigger cost levers here than exploration tokens. Worth revisiting if we move off Opus and exploration becomes the dominant share of spend. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Contributor
|
Note Gemini is unable to generate a review for this pull request due to the file types involved not being currently supported. |
jmg-duarte
reviewed
May 19, 2026
MartinquaXD
approved these changes
May 20, 2026
Contributor
MartinquaXD
left a comment
There was a problem hiding this comment.
Looks reasonable to me. 👌
AryanGodara
reviewed
May 20, 2026
jmg-duarte
reviewed
May 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Re-introduces an automated Claude code review after #4381 dropped the previous version for cost reasons (~$10-15 per PR).
Key changes from the old workflow:
/code-reviewplugin's multi-agent fanout. A single agent with a plain "Review this PR" prompt is enough and avoids the parallel subagent context (which leads to spend similar to the integrated Claude review that's currently running)--max-turns 10.concurrencygroup so back-to-back@claudecomments cancel the previous in-flight run instead of paying twice.skip-claude-reviewlabel escape hatch and skips bot-authored PRs (we may want to inverse this logic later and make it review only certain PRs).Not using https://github.com/colbymchenry/codegraph for now, because:
Only people that are part of our org can trigger the review.
How to test
Monitor API key spend