Claude Sonnet 5 vs Gemini 3.1 Pro Preview for code review
Claude Sonnet 5 wins, 89–85
Same 12 code review tasks, marked blind by three rival labs. Claude Sonnet 5 took 5 tasks, Gemini 3.1 Pro Preview took 2, 5 tied. Tested 18 Aug 2026.
Where they differed most
These three review comments are all technically correct and all unusable. Rewrite each one so the author would act on it — exactly 3 bullets, one per comment, in the order given, one line each, no sub-points, no exclamation marks. Keep the technical point intact; lose the contempt. Do not add a fourth. 1) 'This is wrong. Did you even test it?' 2) 'Nobody writes loops like this any more. Rewrite the whole file.' 3) 'I already explained this in the last PR.'
- This logic produces an incorrect result for [specific input/edge case]—please add a test covering that case and verify the fix against it. - These loops use an outdated/inconsistent pattern—please refactor them to use [preferred idiom, e.g., `for...of`/array methods] for consistency with the rest of the codebase. - This was covered in PR #[number]—see [link/comment] for the explanation and please apply the same fix here.
* There appears to be an error in this logic; please review it and add a test case to verify the expected behavior. * Please update the loops throughout this file to use modern iteration syntax. * Please apply the same pattern we discussed in the previous PR here.
Task by task
| Task | Claude Sonnet 5 | Gemini 3.1 Pro Preview |
|---|---|---|
| The pagination that skips page one | 6 | 7 |
| Nothing wrong with it | 8 | 8 |
| Three things wrong in six lines | 8 | 8 |
| Two customers, one last item | 9 | 9 |
| Rank by what breaks | 10 | 9 |
| The review, as JSON | 9 | 9 |
| Slow is not the same as wrong | 10 | 9 |
| Overdue at one in the morning | 9 | 8 |
| Write only the comment | 10 | 10 |
| The complaint that is not a defect | 8 | 9 |
| Right, and unusable | 10 | 8 |
| Refuse the rubber stamp | 10 | 8 |
Full receipts: Claude Sonnet 5, Gemini 3.1 Pro Preview · judges gemini-3.1-pro-preview, gpt-5.6-terra, grok-4.5
Questions people ask
Which is better for code review: Claude Sonnet 5 or Gemini 3.1 Pro Preview?
Claude Sonnet 5 — it scored 89/100 against 85/100 on our 12-task code review suite, winning 5 tasks to 2 with 5 tied. Every answer was marked blind by three judges from three rival AI labs.
How was this tested?
Both models answered the identical published code review tasks. Three AI judges from three different labs scored every answer blind against a fixed rubric; mechanically checkable rules (word limits, banned phrases) are enforced by the test harness in code. The raw outputs and judge verdicts are downloadable.
More code review head-to-heads: Claude Sonnet 5 vs GPT-5.6 Sol · Gemini 3.1 Pro Preview vs GPT-5.6 Sol · Claude Sonnet 5 vs GPT-5.5 · Gemini 3.1 Pro Preview vs GPT-5.5 · Claude Sonnet 5 vs Grok 4.5 · Claude Sonnet 5 vs GLM 5.2
Full ranking: Best AI for code review · model pages: Claude Sonnet 5, Gemini 3.1 Pro Preview