파이썬을 위한 신경망 디버거를 향하여
Towards a Neural Debugger for Python
March 10, 2026
저자: Maximilian Beck, Jonas Gehring, Jannik Kossen, Gabriel Synnaeve
cs.AI
초록
대규모 언어 모델(LLM)을 Python 실행 추적 데이터로 학습시키면 코드 실행에 기반을 둔 모델을 구축할 수 있으며, 전체 Python 프로그램의 라인별 실행 결과를 예측하는 신경망 인터프리터로 발전시킬 수 있습니다(FAIR CodeGen Team et al., 2025). 그러나 개발자들은 프로그램을 단계별로 실행하는 경우는 드물며, 대신 디버거를 사용하여 특정 중단점에서 실행을 멈추고 관련 부분만을 단계적으로 실행하면서 프로그램 변수를 검사하거나 수정합니다. 기존 신경망 인터프리터 접근법은 이러한 상호작용적 제어 기능이 부족합니다. 이러한 한계를 해결하기 위해 우리는 신경망 디버거를 소개합니다. 이는 기존 디버거를 모방한 언어 모델로, 함수 내부 단계 실행, 함수 넘어가기, 함수 빠져나오기, 특정 소스 코드 줄에 중단점 설정과 같은 작업을 지원합니다. 우리는 대규모 LLM을 미세 조정하거나 더 작은 모델을 처음부터 사전 학습하여 얻은 신경망 디버거가 디버거 동작을 조건으로 전방 실행(향후 상태 및 출력 예측)과 역방향 실행(이전 상태 또는 입력 추론)을 모두 안정적으로 모델링할 수 있음을 보여줍니다. CruxEval에서 평가한 결과, 우리 모델은 출력 및 입력 예측 과제 모두에서 강력한 성능을 달성하며 견고한 조건부 실행 모델링 능력을 입증했습니다. 우리의 연구는 신경망 디버거가 시뮬레이션된 디버깅 환경을 위한 월드 모델 역할을 하여 실행 피드백을 제공하거나 에이전트가 실제 디버깅 도구와 상호작용할 수 있도록 하는 미래의 자율적 코딩 시스템을 위한 첫걸음입니다. 이 능력은 더 강력한 코드 생성, 프로그램 이해 및 자동화된 디버깅의 기초를 마련합니다.
English
Training large language models (LLMs) on Python execution traces grounds them in code execution and enables the line-by-line execution prediction of whole Python programs, effectively turning them into neural interpreters (FAIR CodeGen Team et al., 2025). However, developers rarely execute programs step by step; instead, they use debuggers to stop execution at certain breakpoints and step through relevant portions only while inspecting or modifying program variables. Existing neural interpreter approaches lack such interactive control. To address this limitation, we introduce neural debuggers: language models that emulate traditional debuggers, supporting operations such as stepping into, over, or out of functions, as well as setting breakpoints at specific source lines. We show that neural debuggers -- obtained via fine-tuning large LLMs or pre-training smaller models from scratch -- can reliably model both forward execution (predicting future states and outputs) and inverse execution (inferring prior states or inputs) conditioned on debugger actions. Evaluated on CruxEval, our models achieve strong performance on both output and input prediction tasks, demonstrating robust conditional execution modeling. Our work takes first steps towards future agentic coding systems in which neural debuggers serve as a world model for simulated debugging environments, providing execution feedback or enabling agents to interact with real debugging tools. This capability lays the foundation for more powerful code generation, program understanding, and automated debugging.