[Paper Review] Reasoning Distillation for Lightweight Automated Program Repair
The paper shows that lightweight symbolic reasoning supervision distilled from a large teacher improves fix-type classification in a compact CodeT5-based student without increasing model size, with stronger gains on rare bug categories.
We study whether lightweight symbolic reasoning supervision can improve fix type classification in compact automated program repair models. Small code models are attractive for resource-constrained settings, but they typically produce only a single prediction, making it unclear whether they learn meaningful program structure or rely on shallow correlations. We propose a reasoning distillation approach in which a large teacher model provides structured symbolic reasoning tags alongside fix-type labels. These tags capture high-level causal properties of bugs without relying on free-form explanations. We train a CodeT5-based student model under label-only and reasoning-distilled settings on the IntroClass benchmark. Reasoning supervision consistently improves macro averaged performance, particularly on less frequent bug categories, without increasing model size or complexity. We further analyze the relationship between reasoning accuracy and fix-type prediction, showing that correct reasoning traces strongly correlate with correct predictions, while not fully determining them. Our results suggest that symbolic reasoning distillation is a practical way to improve interpretability and robustness in lightweight program repair models.
Motivation & Objective
- Motivate lightweight debugging tools for resource-constrained environments.
- Investigate whether symbolic reasoning supervision distillation improves fix-type prediction for compact models.
- Evaluate the impact of reasoning supervision on accuracy, macro-F1, and reasoning quality.
- Assess whether reasoning traces correlate with improved defect-type classification.
Proposed method
- Use a large instructor model to generate fix-type labels and compact symbolic reasoning tags.
- Train a CodeT5-based student under two conditions: label-only versus joint prediction of fix-type and reasoning tags.
- Evaluate on the IntroClass dataset with a fixed train/validation split.
- Compare accuracy and macro-F1 for fix-type prediction and assess reasoning trace fidelity to the teacher.
- Analyze per-fix-type gains and conditioning of fix-type accuracy on reasoning correctness.
Experimental results
Research questions
- RQ1Can lightweight symbolic reasoning supervision, distilled from a large instructor model, improve fix-type classification in compact automated program repair models without increasing model size or complexity?
- RQ2Does joint supervision over fix-type labels and structured symbolic reasoning tags yield better performance than label-only training, and how does reasoning accuracy relate to fix-type prediction?
- RQ3How well can a small model reproduce teacher-generated symbolic reasoning traces and how does that relate to downstream bug classification?
- RQ4Are gains concentrated in less frequent or more complex bug categories, and what are the limitations of reasoning distillation in this setting?
Key findings
- The reasoning-distilled student achieves higher fix-type accuracy (0.544 vs 0.491) and macro-F1 (0.249 vs 0.213) than the label-only baseline.
- Reasoning supervision yields stronger macro-averaged improvements, helping less frequent bug categories.
- Reasoning traces are reproduced with high fidelity, with reasoning macro-F1 0.545 and exact match 0.789; most major tags exceed 0.87 accuracy.
- Per-fix-type gains are largest for WRONG_CONDITION, LOOP_BOUND, WRONG_OPERATOR, and MISSING_CASE, with improvements over the baseline.
- There are cases where correct reasoning does not imply correct fix-type, indicating reasoning aids internal representations but does not fully resolve classification ambiguity.
- An auxiliary JSON-based distillation study shows JSON supervision is more expressive but harder for small models in low-data regimes.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.