The Imitation Game: When LLMs Learn to Reason Like Programs via Code-Centric Reasoning Data Synthesis
On the map: LLM reasoning → Reasoning for agents, planning and code
Abstract (arXiv)
Large Language Models (LLMs) excel at programming tasks but frequently fail at deterministic, fine-grained reasoning in natural language, relying heavily on semantic approximations rather than robust symbolic execution. To bridge this gap, we propose MIMIC, a framework that leverages executable code as a rigorous medium for reasoning data synthesis. MIMIC fundamentally transforms algorithms into verifiable reasoning trajectories through narrative fusion, code-guided test synthesis, and dynamic code instrumentation. Crucially, these explicit intermediate execution states naturally form a Code-Instrumented Reward (CIR), providing dense, high-fidelity process supervision for reinforcement learning without external reward models. Extensive evaluations reveal that models trained via SFT and GRPO on our synthesized dataset achieve substantial, consistent gains. Our method significantly elevates accuracy across general reasoning, complex mathematical benchmarks, and fine-grained deterministic tasks, demonstrating that the procedural rigor of executable code can effectively unlock and enhance the generalized reasoning capabilities of LLMs. Our code and data are available at https://github.com/zjy1298/MIMIC.
Key facts. No citing papers in the map yet (data through 14 Oct 2026). Placed in Reasoning for agents, planning and code, one of 17 directions in LLM reasoning. Builds on 33 of its 75 references that are in the map. First posted on arXiv 13 Sep 2026.
Builds on
33 of 75 references.
References · 33
- 2021Training Verifiers to Solve Math Word Problemscited by 10,109
- 2024DeepSeekMath: Pushing the Limits of Mathematical Reasoning in Open Language Modelscited by 9,379
- 2025Qwen3 Technical Reportcited by 8,820
- 2025DeepSeek-R1: Incentivizing Reasoning Capability in LLMs via Reinforcement Learningcited by 6,330
- 2018Think you have Solved Question Answering? Try ARC, the AI2 Reasoning Challengecited by 4,886
- 2024GPT-4o System Cardcited by 4,588
- 2021Program Synthesis with Large Language Modelscited by 3,637
- 2023GPQA: A Graduate-Level Google-Proof Q&A Benchmarkcited by 2,879
- 2024HybridFlow: A Flexible and Efficient RLHF Frameworkcited by 2,057
- 2024LlamaFactory: Unified Efficient Fine-Tuning of 100+ Language Modelscited by 1,464
- 2022Program of Thoughts Prompting: Disentangling Computation from Reasoning for Numerical Reasoning Taskscited by 1,076
- 2019DROP: A Reading Comprehension Benchmark Requiring Discrete Reasoning Over Paragraphscited by 903
21 more
- 2024DeepSeek-V3 Technical Reportcited by 811
- 2025SFT Memorizes, RL Generalizes: A Comparative Study of Foundation Model Post-trainingcited by 672
- 2023WizardMath: Empowering Mathematical Reasoning for Large Language Models via Reinforced Evol-Instructcited by 625
- 2025LIMO: Less is More for Reasoningcited by 498
- 2025The Lessons of Developing Process Reward Models in Mathematical Reasoningcited by 415
- 2022CodeT: Code Generation with Generated Testscited by 384
- 2024CRUXEval: A Benchmark for Code Reasoning, Understanding and Executioncited by 300
- 2024ProcessBench: Identifying Process Errors in Mathematical Reasoningcited by 292
- 2024Tokenization counts: the impact of tokenization on arithmetic in frontier LLMscited by 115
- 2024Why Do Large Language Models (LLMs) Struggle to Count Letters?cited by 38
- 2025AlphaMaze: Enhancing Large Language Models' Spatial Intelligence via GRPOcited by 33
- 2024Counting Ability of Large Language Models and Impact of Tokenizationcited by 32
- 2024Unleashing LLM Reasoning Capability via Scalable Question Synthesis from Scratchcited by 24
- 2025Frontier LLMs Still Struggle with Simple Reasoning Taskscited by 21
- 2024CodeACT: Code Adaptive Compute-efficient Tuning Framework for Code LLMscited by 15
- 2026EvoRubrics: Dynamic Rubrics as Rewards via Adversarial Co-Evolution for LLM Reinforcement Learningcited by 14
- 2024Learning Beyond Pattern Matching? Assaying Mathematical Understanding in LLMscited by 9
- 2026Do VLMs Perceive or Recall? Probing Visual Perception vs. Memory with Classic Visual Illusionscited by 8
- 2025Teaching LLM to Reason: Reinforcement Learning from Algorithmic Problems without Codecited by 3
- 2026The Tell-Tale Norm: ℓ2 Magnitude as a Signal for Reasoning Dynamics in Large Language Modelscited by 2
- 2026Search for Truth from Reasoning: A Dynamic Representation Editing Framework for Steering LLM Trajectoriescited by 1
Built on by
Not cited yet.
Similar, not cited
Close in wording, no citation either way
- 2026Exploring Extrinsic and Intrinsic Properties for Effective Reasoning with Code Interpreter
- 2026Enhancing the Code Reasoning Capabilities of LLMs via Consistency-based Reinforcement Learning
- 2026ExecVerify: White-Box RL with Verifiable Stepwise Rewards for Code Execution Reasoning
- 2025CodeReasoner: Enhancing the Code Reasoning Ability with Reinforcement Learning
- 2025R1-Code-Interpreter: LLMs Reason with Code via Supervised and Multi-stage Reinforcement Learning
- 2025Loong: Synthesize Long Chain-of-Thoughts at Scale through Verifiers
- 2024RLEF: Grounding Code LLMs in Execution Feedback with Reinforcement Learning
- 2025CodeARC: Benchmarking Reasoning Capabilities of LLM Agents for Inductive Program Synthesis