Beyond the Verdict: Agentic Code Judging with Verifiable Feedback
Organizations: HKUST · Amazon
Abstract
Test-time scaling for large language models (LLMs) can involve generating multiple candidate solutions for selection or revising an earlier attempt. To guide selection and revision, we need a verifier that can estimate candidate correctness and provide evidence of failure. In competitive programming, however, official judging systems provide authoritative verdicts under finite submission budgets, without revealing failure explanations or failing inputs. To provide informative feedback without consuming official submissions, we formulate a task in which a model judges and diagnoses a candidate program using only the problem statement and source code, with generated counterexamples serving as checkable evidence. To evaluate this task, we build USACO-JUDGE from the USACO 2026 contests, using accepted and unaccepted programs written by human experts and multiple LLMs. We then train ARBITER, a 35B mixture-of-experts (MoE) agentic verifier, with reinforcement learning in a generic execution sandbox. Training raises counterexample success on incorrect programs from 40.61% to 62.67% and mean binary verdict accuracy on USACO-JUDGE from 71.41% to 87.41%, approaching frontier verification performance. Beyond verification, ARBITER outperforms baselines in both code selection and refinement. In an IOI 2026 case study, ARBITER-guided refinement raises GPT-OSS-120B's expected score above the gold-medal threshold under the official submission limit.
Figures & tables
| Model | Params | UOJ-Bench (Hacking) | USACO-Judge | Overall Hack Succ. | ||||||
| Verdict Acc. | Hack Succ. | Verdict Acc. | Hack Succ. | |||||||
| Easy | Hard | Easy | Hard | Easy | Hard | Easy | Hard | |||
| Non-agentic | ||||||||||
| Qwen3.6-35B-A3B | 35B | 86.85 | 87.57 | 16.70 | 10.85 | 66.42 | 64.55 | 32.04 | 21.65 | 16.10 |
| GPT-OSS-120B | 120B | 79.12 | 77.06 | 29.09 | 20.07 | 60.74 | 66.88 | 33.89 | 36.84 | 26.59 |
| DeepSeek-V4-Flash-Preview | 284B | 73.49 | 73.10 | 33.49 | 22.03 | 74.94 | 68.68 | 55.00 | 41.52 | 31.26 |
| Condition | Qwen3.6-35B-A3B | GPT-OSS-120B | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Easy (9) | Medium (9) | Hard (12) | Easy (9) | Medium (9) | Hard (12) | |||||||
| @1 | @8 | @1 | @8 | @1 | @8 | @1 | @8 | @1 | @8 | @1 | @8 | |
| Starting code | 69.5 | 69.5 | 52.4 | 52.4 | 0 9.5 | 0 9.5 | 73.8 | 73.8 | 62.8 | 62.8 | 12.8 | 12.8 |
| Previous code only | 52.4 | 93.6 | 38.9 | 59.8 | 0 5.8 | 16.6 | 88.1 | 89.6 | 75.9 | 81.6 | 21.8 | 28.5 |
| Online Judge | 68.9 | 98.1 | 49.2 | 64.7 | 10.2 | 17.4 | 80.7 | 94.3 | 73.0 | 86.0 | 20.5 | 35.5 |
| Arbiter : | 90.1 | 92.5 | 62.4 | 65.9 | 0 6.4 | 13.4 | 95.8 | 96.8 | 84.0 | 84.1 | 26.3 | 35.8 |
| Selection method | Qwen3-30B-A3B-Thinking | Qwen3-235B-A22B-Thinking | ||||||
|---|---|---|---|---|---|---|---|---|
| LiveCodeBench v6 | OJBench | LiveCodeBench v6 | OJBench | |||||
| Pool=8 | Pool=64 | Pool=8 | Pool=64 | Pool=8 | Pool=64 | Pool=8 | Pool=64 | |
| Uniform selection | 66.2 | 66.2 | 28.9 | 28.9 | 74.7 | 74.7 | 37.1 | 37.1 |
| Grading RM ( Liu et al., 2025 ) | 67.1 | 68.0 | 28.7 | 29.3 | 75.9 | 74.9 | 37.6 | 34.9 |
| MBR-Exec (hard) ( Shi et al., 2022 ) | 68.5 | 69.2 | 29.6 | 32.4 | 77.9 | 77.7 | 37.7 | 39.6 |
| MBR-Exec (soft) ( Shi et al., 2022 ) | 70.0 | 70.0 | 31.4 | 31.8 | 78.5 | 78.5 | 40.5 | 41.4 |
Appendix figures & tables16 assets
Supplementary material from the paper’s appendix.
Appendix
| Judge verdict | ||||||||
| Score band | AC | WA | TLE | MLE | RE | CE | Total | |
| 100 (accepted) | 3,000 | – | – | – | – | – | 3,000 | 15.0% |
| 76–99 (near-miss) | – | 4,460 | 3,107 | 220 | 163 | – | 7,950 | 39.8% |
| 1–75 (partial) | – | 4,600 | 1,600 | 400 | 600 | – | 7,200 | 36.0% |
| 0 | – | 1,000 | – | – | – | – | 1,000 | 5.0% |
| Compile Error | – | – | – | – | – | 850 | 850 | 4.3% |
| CPID | What the checker validates |
|---|---|
| 1540 | Verifies the reported optimum and checks that the supplied position assignment reconstructs valid square subsequences. |
| 1563 | Simulates the submitted keystrokes and checks that they reconstruct the target string. |
| 1566 | Tests the submitted permutation and truth-teller/liar assignment against every directional claim. |
| 1589 | Replays the submitted swaps, enforces the operation limit, and checks the final string. |
| 1597 | Confirms the minimum attack count, replays the submitted attacks, and verifies that every target reaches zero HP. |
| 1598 | Validates infeasibility claims or tests the submitted array against every min, max, sum, and xor query. |
| Model | Params | Token Price ($/M Tokens) | UOJ-Bench | USACO-Judge | Overall Hack Succ. | Output Cost per Verification | ||
| Easy | Hard | Easy | Hard | |||||
| Non-agentic | ||||||||
| Qwen3.6-35B-A3B | 35B | $0.10 | 0 9.6K | 10.6K | 11.4K | 10.9K | 16.10 | $0.0011 |
| GPT-OSS-120B | 120B | $0.17 | 0 3.8K | 0 4.5K | 0 4.3K | 0 4.1K | 26.59 | $0.0007 |
| DeepSeek-V4-Flash-Preview | 284B | $0.66 | 16.6K | 19.4K | 18.8K | 22.0K | 31.26 | $0.0129 |
| Qwen3.5-397B-A17B | 397B | $0.90 | 16.7K | 18.4K | 28.1K | 28.2K | 42.73 | $0.0195 |
| Model | Easy | Hard | ||||||
|---|---|---|---|---|---|---|---|---|
| Att. | Exec. | Valid | Succ. | Att. | Exec. | Valid | Succ. | |
| Non-agentic | ||||||||
| Qwen3.6-35B-A3B | ||||||||
| GPT-OSS-120B | ||||||||
| DeepSeek-V4-Flash-Preview | ||||||||
| Qwen3.5-397B-A17B | ||||||||
| Model | Params | UOJ-Bench | USACO-Judge | ||
|---|---|---|---|---|---|
| Easy | Hard | Easy | Hard | ||
| Qwen3.6-35B-A3B | 35B | 16.3 | 17.1 | 12.1 | 16.2 |
| DeepSeek-V4-Flash-Preview | 284B | 21.1 | 21.6 | 15.3 | 22.2 |
| Arbiter (Ours) | 35B | 17.5 | 18.7 | 14.2 | 17.8 |
| Turn | Reasoning and observation |
|---|---|
| ① | Identifies that S[i][j] stores the sum of the window whose top-left corner is . It derives the exact range of windows affected by an update and compares the candidate with brute force on 100,000 random tests, finding no mismatch. |
| ② | Checks the worst-case cost. Each update touches at most windows, giving at most 18.75 million updates over the full input. It then generates a constraint-scale timing instance. |
| ③ | Repairs the timing input so repeated updates to a cell remain strictly increasing, compiles the candidate, and measures 0.088 seconds for 30,000 updates. |
| ④ | Rechecks boundary cases, integer range, memory use, and input format, then returns Accepted with no counterexample generator. |
| Turn | Reasoning and observation |
|---|---|
| ① | Derives the geometric interpretation of the task, compiles the candidate, and confirms that it passes the supplied examples. |
| ② | Checks the angular grouping and two-pointer count, then begins randomized differential testing against a brute-force solver. |
| ③ | Repairs an error in the brute-force harness. The process-per-case version is too slow to complete the planned search. |
| ④ | Batches 2,000 random instances into one candidate invocation. No wrong answer is found, so the search shifts from functional correctness to runtime. |
| ⑤ | Spots the loop after grouping and constructs one group of size 200,000. Running the candidate on this input exceeds the local timeout. |
| ⑥ | Checks a small all-identical instance by enumeration and confirms that its correct answer is zero. |
| Turn | Reasoning and observation |
|---|---|
| ① | Traces the DSU-based construction and notices that zero denotes both a legal lower bound and the initial state. It compiles the candidate and observes -1 on the minimal instance. |
| ② | Connects the failure to the K_min[j] != 0 guard, then checks the candidate on the first supplied examples. |
| ③ | Runs the second supplied example and confirms that alternative printed arrays still satisfy its constraints. |
| ④ | Verifies that and are legal, then checks directly that the array satisfies the constraint. |
| ⑤ | Replays the three-line input and again observes -1 , fixing the failure mechanism and expected output before submission. |
| ⑥ | Returns Wrong Answer , identifies the sentinel collision, and submits the generator. UOJ validates the input and confirms the wrong answer. |
| Qwen3-30B-A3B-Thinking | Qwen3-235B-A22B-Thinking | |||
|---|---|---|---|---|
| Reference Verdict \ Arbiter Prediction | Accepted | Unaccepted | Accepted | Unaccepted |
| Accepted | ||||
| Unaccepted | ||||
| GPT-OSS-120B | Qwen3.6-35B-A3B | |||
|---|---|---|---|---|
| Reference Verdict \ Arbiter Prediction | Accepted | Unaccepted | Accepted | Unaccepted |
| Accepted | ||||
| Unaccepted | ||||
| Diagnosis audit | Count | Share |
|---|---|---|
| Correct | 332 | 83.0% |
| Incorrect | 65 | 16.2% |
| Vacuous | 3 | 0.8% |
| Depth | Count | Share | Operational rule |
|---|---|---|---|
| Actionable fix | 88 | 54.0% | Cites candidate code and states the correct behavior. |
| Located cause | 46 | 28.2% | Cites candidate code and explains the failure, but gives no fix. |
| Mechanism only | 17 | 10.4% | Explains the failure without locating it in the code. |
| Symptom only | 12 | 7.4% | Reports the failure without locating or explaining it. |
| Depth and CPID | Audited case |
|---|---|
| Actionable fix CPID 1545 | On the generated five-node instance, cow 2 hosts a C party on the first night. The diagnosis identifies that range_chmax updates the queried depth before oldOwner is recovered, so the program mistakes the updated node for the previous owner and prints 0 0 0 instead of 2 0 0 . It gives the precise repair: call point_query before range_chmax . |
| Located cause CPID 1545 | The generated instance is a two-node cycle. Cow 2 first hosts C and cow 1 then hosts O. The diagnosis traces the failure to the second cycle host: when prevIdx+1 >= Lsize , process_interval reads past the cycle boundary. The candidate consequently prints 0 2 0 instead of 1 1 0 . The diagnosis locates the failing condition and explains its effect, but does not prescribe a repair. |
| Mechanism only CPID 1590 | For cyclic costs [7,10,2] and a time budget of 34, the diagnosis explains that the candidate incorrectly buys later wins in cheapest-first order. The fixed queue requires cost 36 for the third win, whereas the candidate assumes cost 28 and reports three wins instead of two. This explains the failure mechanism and the correct behavior without pointing to a particular expression or branch. |
| Symptom only CPID 1573 | On a two-position instance with equal input probabilities, the diagnosis reports that the candidate assigns probability 3/4 to each position instead of 1/2 , producing a total of 3/2 . It only speculates about the DP sweep and residue contributions, without identifying a responsible operation or establishing a causal account of the failure. |
| Easy | Hard | |||
|---|---|---|---|---|
| Prec. | Rec. | Prec. | Rec. | |
| 0 | 97.56 | 88.89 | 77.78 | 76.67 |
| 0.5 | 100.00 | 83.33 | 80.98 | 62.86 |
LLM-as-a-Judge
Large language model (LLM)-as-a-judge research uses language models to score, compare, and verify AI outputs as scalable alternatives to human evaluation.
See all 537 papers