atlas

Research map / Large language models / Agents, code and math

Execution Guided Line-by-Line Code Generation

NeurIPS 2025 · Large language models › Agents, code and math · approach: Execution-based code verification · 1 citations (OpenAlex)

Read the paperCheck your idea against 108,967 papers

AI-extracted summary. Written by AI from the paper's full text. Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.

Proposes EG-CFG, an inference-time method that samples line-level code continuations, executes them against tests, and injects execution traces into the prompt via classifier-free guidance, reaching SOTA on several code benchmarks with DeepSeek models.

Problem

LLM code generation typically ignores execution feedback during inference; existing feedback methods operate in coarse, sequential generate-execute-refine cycles rather than token-level guidance.

Approach

Line-by-line generation where beam-sampled candidate continuations are executed, their execution traces are injected into the prompt, and classifier-free guidance interpolates between the unconditional solution prompt and the execution-conditioned prompt; multiple configured agents run in parallel on each task.

Key results

Measured effects reported in the paper

What was changedWhereMeasuredEffect
add line-by-line execution-guided CFG generationDeepSeek-V3-0324 · MBPPaccuracy: 82.8 -> 96.6Helped
add line-by-line execution-guided CFG generationDeepSeek-V3-0324 · MBPP-ETaccuracy: 64.8 -> 73.0Helped
add line-by-line execution-guided CFG generationDeepSeek-V3-0324 · HumanEvalaccuracy: 82.92 -> 99.4Helped
add line-by-line execution-guided CFG generationDeepSeek-V3-0324 · HumanEval-ETaccuracy: 79.20 -> 89.02Helped
add line-by-line execution-guided CFG generationDeepSeek-V3-0324 · DS-1000accuracy: 38.9 -> 69.9Helped
add line-by-line execution-guided CFG generationDeepSeek-V3-0324 · CodeContestsaccuracy: 41.81 -> 60.6Helped
add beam search to generate multiple candidate continuations (ablation)EG-CFG on DeepSeek-Coder 1.3b · MBPPaccuracy: 58.2 -> 83.2Helped
add beam search to generate multiple candidate continuations (ablation)EG-CFG on DeepSeek-Coder 1.3b · MBPP-ETaccuracy: 43.6 -> 59.8Helped
use CFG guidance rather than the gamma=1 ablation (ablation)EG-CFG on DeepSeek-Coder 1.3b · MBPPaccuracy: 75.2 -> 83.2Helped
use CFG guidance rather than the gamma=1 ablation (ablation)EG-CFG on DeepSeek-Coder 1.3b · MBPP-ETaccuracy: 48.2 -> 59.8Helped
use detailed execution traces instead of the final event only (ablation)EG-CFG on DeepSeek-Coder 1.3b · MBPPaccuracy: 76.4 -> 83.2Helped
use detailed execution traces instead of the final event only (ablation)EG-CFG on DeepSeek-Coder 1.3b · MBPP-ETaccuracy: 51.2 -> 59.8Helped

Surprising findings

Limitations

Experimental setup

Datasets: MBPP MBPP-ET HumanEval HumanEval-ET DS-1000 CodeContests

Benchmarks: MBPP MBPP-ET HumanEval HumanEval-ET DS-1000 CodeContests

Metrics: accuracy (pass all tests) relative success rate (RSR)

Baselines: Baseline LLM MGDebugger MapCoder QualityFlow LPW CodeSim LDB CONLINE SelfEvolve

Builds on: Classifier-Free Guidance Self-Debugging LPW MapCoder MGDebugger

Closest papers by meaning

Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.

Open scime draft

Get the next scime Dispatch and a monthly field update

Free. We send a confirmation link first; every email has a one-click unsubscribe. Privacy