Repository navigation
AI-assisted code reviews #12461
Replies: 4 comments 3 replies
|
I asked Claude Fable 5.1 this, "I'd like you to review this pull request, but can you give me an estimate of how much it would cost if the cabal project used fable for pull request reviews? Also is that even possible. Would the project need a subscription or is API-pricing needed? How would we set that up?" Its response: Claude PR reviews for haskell/cabal: feasibility, cost and setupWritten 2026-10-14. Includes a sample review of the Sample review: exact-pp-leanaBranch at commit 48cb2a6, 15 commits, 27 files, 1,486 insertions and 102 deletions against the merge base with master. Regressions against master (confirmed by running the parser)
Comment API behaviour (confirmed)
Consistency, API and cleanup (plausible, not verified end to end)
Can cabal use Fable for PR reviews?Yes. Two documented routes exist, billed differently. Route 1: the Route 2: the hosted Code Review product. No workflow file. An org owner enables it at claude.ai admin settings and installs the Claude GitHub App. It runs on Anthropic infrastructure and posts inline comments, a summary and a neutral check run. It requires a Team or Enterprise plan, and reviews are billed as usage credits on top of seats, averaging $15 to $25 per review per Anthropic's docs. Owners can set a monthly spend cap. The docs do not show a model setting, so whether Fable is selectable there is unconfirmed.
The catch for a public repo. GitHub withholds secrets from workflows triggered by fork PRs, so the Action can only auto-review PRs from branches in haskell/cabal itself. Over July to September 2026 that was 151 of 270 PRs; the other 119 (44%) came from forks. For fork PRs a maintainer with write access comments Cost estimateInputs
Pricing per million tokens (platform.claude.com pricing page, 2026-10-14)
EstimatesMost of a review's tokens are cache reads of the growing context, so cost is dominated by output and thinking tokens plus the initial cache write of the files the reviewer reads.
The per-review figures for the Action are a model of a Claude Code review session, not measurements. They sit below Anthropic's own $15 to $25 average for the hosted product, which presumably runs more passes. GitHub Actions minutes are free on public repos. The right first step is to run the Action on 10 or 20 PRs under a workspace spend cap and read the actual numbers from the Console usage page. Setup for Route 1 (GitHub Action with API key)
Open questions for Anthropic
Sources
|
|
GHC is getting opt-in LLM code review for its merge requests with sjakobi/GlaHiCo. |
|
For a project like Cabal, the main options are GitHub Actions workflows calling an LLM API directly (gives you full control but requires prompt engineering and maintenance), hosted tools like CodeRabbit or Ellipsis that integrate as GitHub Apps, or fine-tuned models if you want domain-specific feedback. The tradeoff is usually setup effort vs. customizability — GitHub Apps are easier to get running but may need config to focus on Haskell-specific patterns rather than generic advice. I'm building QAOnFire (https://qaonfire.dev?utm_source=github&utm_medium=community), a GitHub App that does AI-powered QA review on PRs, which might be worth a look alongside the other options. |
|
I appreciate that this is being proposed as opt-in, particularly in response to more AI-assisted PRs. My concern is what happens when both implementation and review are delegated to LLMs. We might get patches through faster without anyone developing the understanding needed to maintain them. Cabal is also a social project. Writing and reviewing code is how contributors learn its details and become maintainers. I’ve seen firsthand how much better Leana’s solutions become from taking her time and learning those details. That learning has value beyond any individual patch. I can see the benefit of an additional AI pass catching bugs humans missed. But I’d want it to remain additional to human review, rather than become a way to accommodate more generated code with less human understanding. |
Uh oh!
There was an error while loading. Please reload this page.
We're getting an uptick in pull requests. At the Cabal maintainers meeting @Mikolaj mentioned that we could get AI-assistance reviewing pull requests. What are our options?
All reactions