← Latest papers
💬 NLP

Scaling Agentic Verifier for Competitive Coding

The paper introduces Agentic Verifier, an execution-based agent that actively generates discriminative test inputs through multi-turn reasoning and reinforcement learning to significantly improve the accuracy of large language models in competitive programming by effectively identifying and filtering out incorrect candidate solutions.

Original authors: Zeyao Ma, Jing Zhang, Xiaokang Zhang, Jiaxi Yang, Zongmeng Zhang, Jiajun Zhang, Yuheng Jing, Lei Zhang, Hao Zheng, Wenting Zhao, Junyang Lin, Binyuan Hui

Published 2026-02-05
📖 5 min read🧠 Deep dive

Original authors: Zeyao Ma, Jing Zhang, Xiaokang Zhang, Jiaxi Yang, Zongmeng Zhang, Jiajun Zhang, Yuheng Jing, Lei Zhang, Hao Zheng, Wenting Zhao, Junyang Lin, Binyuan Hui

Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

The Big Problem: The "One-Shot" Guessing Game

Imagine you are a genius chef (a Large Language Model) trying to recreate a complex dish based on a recipe description. Sometimes, you get it perfect on the first try. But often, you might miss a subtle detail, like using salt instead of sugar, or forgetting a step.

In the world of competitive programming (solving hard logic puzzles with code), even the smartest AI chefs struggle to get the answer right 100% of the time in a single attempt.

To fix this, researchers usually ask the AI to cook the dish 64 times (generating 64 different solutions) and then pick the best one. But how do you know which one is actually good if you don't have the "official answer key" handy?

The Old Way: Throwing Darts Blindly

The traditional method for checking these 64 solutions is called Execution-Based Verification. You take the 64 code recipes and run them against some test ingredients (inputs).

  • The Flaw: The old method was like throwing darts at a giant wall of possible ingredients to see which ones reveal a mistake. It just picked random ingredients (e.g., "What if the number is 5?" "What if it's 100?").
  • The Result: Most of these random ingredients are too easy. They don't catch the subtle mistakes. You might run 64 tests, and all 64 wrong solutions still look perfect because none of the tests were tricky enough to expose their errors. It's like trying to find a crack in a diamond by tapping it with a feather; you need a hammer.

The New Solution: The "Detective Chef" (Agentic Verifier)

The authors of this paper built a new tool called the Agentic Verifier. Think of this not as a random dart-thrower, but as a super-smart detective or a tough food critic.

Instead of guessing random ingredients, this detective:

  1. Looks at two different solutions side-by-side.
  2. Thinks deeply about how they work.
  3. Actively hunts for the one specific ingredient that will make the two solutions behave differently.

If Solution A says "The answer is 10" and Solution B says "The answer is 12," the detective doesn't just pick a random number. It asks, "What specific input will force Solution A to crash or give a wrong answer while Solution B stays correct?" It keeps asking questions and testing until it finds that "smoking gun" input.

How They Trained the Detective

You can't just tell a computer to "be smart." You have to train it. The authors used a three-step training camp:

  1. Data Synthesis (The Practice Kitchen): They created thousands of fake cooking problems and pairs of "good" and "bad" solutions.
  2. Rejection Fine-Tuning (The Elimination Round): They let the AI try to find the tricky ingredients. If it failed to find a difference, that attempt was thrown in the trash. Only the successful attempts were kept to teach the AI what "good detective work" looks like.
  3. Agentic Reinforcement Learning (The Championship): They gave the AI a reward system. If it found an input that exposed a difference between two solutions, it got a point. If it failed, it got a penalty. Over time, the AI learned to become incredibly efficient at finding those "smoking gun" inputs.

The Results: Smarter Tests, Better Winners

When they tested this new "Detective Chef" against the old "Random Dart-Thrower":

  • Efficiency: The detective found the mistakes much faster. It didn't need to run hundreds of tests; it found the right test to run.
  • Accuracy: On hard puzzles (like those from the USACO or ICPC competitions), the new method improved the AI's success rate by 10–15%. That is a massive jump in this field.
  • Scaling: The more "thinking time" and test inputs they gave the detective, the better it got. It didn't hit a wall like the old methods did.

A Bonus Discovery: The "Imperfect Judge"

The paper also found something interesting about the competitions themselves. The official test cases used by these competitions are actually imperfect.

Sometimes, a solution is technically "wrong" (it fails on inputs the competition didn't test), but it passes the official tests and gets a gold medal. The Agentic Verifier acts like a truth-teller that can find these "fake winners" by generating new, tricky tests that the official judges missed. It shows that even the "answer keys" in these competitions aren't perfect, and this new tool can help find the truly correct code.

Summary

In short, the paper says: "Stop guessing random test cases to check AI code. Instead, train an AI detective to actively hunt for the specific, tricky tests that reveal the truth. This makes finding the best code much faster and much more accurate."

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →