Pruning the Unsurprising: Efficient Code Reasoning via First-Token Surprisal
Wenhao Zeng, Yaoning Wang, Chao Hu, Yuling Shi, Chengcheng Wan, Hongyu Zhang, Xiaodong Gu
2025-08-11
Summary
This paper talks about a new method called ASAP that makes AI models better at solving coding problems by focusing only on the important parts of the thinking process. It reduces the amount of work the model needs to do while keeping the key steps that lead to the right answer.
What's the problem?
The problem is that when AI models try to solve code-related problems, they often generate long, detailed thought steps that include a lot of obvious or unnecessary parts. This wastes time and computer power because the model spends effort on unsurprising or less important details.
What's the solution?
The paper introduces ASAP, a system that looks at the first part of each step to decide if it’s surprising or important. If the step is not surprising, meaning it’s predictable or obvious, ASAP skips it or shortens it. By cleaning up the thinking process this way, the model focuses on the essential reasoning steps and works faster and cheaper.
Why it matters?
This matters because by making AI models more efficient at reasoning in code, we save time and computing resources. That allows these models to solve problems faster and can be used in more practical applications where speed and cost are important.
Abstract
ASAP, a novel coarse-to-fine framework, compresses Chain-of-Thought in code reasoning by preserving core structure and essential steps, reducing costs and improving efficiency.