Reasoning Trajectories for Socratic Debugging of Student Code: From Misconceptions to Contradictions and Updated Beliefs
On the map: LLM reasoning → Reasoning for agents, planning and code
Abstract (arXiv)
In Socratic debugging, instructors guide students towards identifying and fixing a bug on their own, instead of providing the bug fix directly. Most novice programmer bugs are caused by programming misconceptions, namely false beliefs about a programming concept. In this context, Socratic debugging can be formulated as a guided Reasoning Trajectory (RT) leading to a statement about the program behavior that contradicts the bug-causing misconception. Upon reaching this contradiction, the ensuing cognitive dissonance is expected to lead the student to identify the false belief on their own, followed by an enduring belief update. In this paper, we introduce the task of reasoning trajectory generation, together with a dataset of debugging problems annotated with RTs that are manually created or LLM-generated. We then describe LLM-based solutions for generating RTs and Socratic conversations that are anchored on them. A large-scale LLM-as-judge evaluation shows that large language and reasoning models can generate up to 91% correct reasoning trajectories and 98.7% valid conversation turns.
Key facts. Cited by 1 paper in the map (data through 14 Oct 2026). Placed in Reasoning for agents, planning and code, one of 17 directions in LLM reasoning. Builds on 4 of its 36 references that are in the map. First posted on arXiv 1 Nov 2025.
Builds on
4 of 36 references.
References · 4
- 2025MathTutorBench: A Benchmark for Measuring Open-ended Pedagogical Capabilities of LLM Tutorscited by 49
- 2025TeachLM: Post-Training LLMs for Education Using Authentic Learning Datacited by 9
- 2025LeanTutor: Towards a Verified AI Mathematical Proof Tutorcited by 4
- 2025McMining: Automated Discovery of Misconceptions in Student Codecited by 1
Built on by
Citing papers per year: 2026: 1.
1 paper.
Similar, not cited
Close in wording, no citation either way
- 2025DebugTA: An LLM-Based Agent for Simplifying Debugging and Teaching in Programming Education
- 2026ProDebug: An Automated Debugging System for Prolog ↗
- 2025Dual-Process Scaffold Reasoning for Enhancing LLM Code Debugging
- 2023Can Language Models Employ the Socratic Method? Experiments with Code Debugging
- 2025Demystifying Errors in LLM Reasoning Traces: An Empirical Study of Code Execution Simulation
- 2025textttReMind: Understanding Deductive Code Reasoning in LLMs
- 2025Generating Verifiable Chain of Thoughts from Exection-Traces
- 2024NExT: Teaching Large Language Models to Reason about Code Execution