PreprintCited by 16Teaching and Learning ProgrammingSoftware Engineering ResearchIntelligent Tutoring Systems and Adaptive Learning

Generating High-Precision Feedback for Programming Syntax Errors using Large Language Models

Open access
Phung, Tung, Cambronero, José, Gulwani, Sumit, Kohn, Tobias, Majumdar, Rupak, Singla, Adish, Soares, Gustavo·2023·arXiv

Abstract

Large language models (LLMs), such as Codex, hold great promise in enhancing programming education by automatically generating feedback for students. We investigate using LLMs to generate feedback for fixing syntax errors in Python programs, a key scenario in introductory programming. More concretely, given a student's buggy program, our goal is to generate feedback comprising a fixed program along with a natural language explanation describing the errors/fixes, inspired by how a human tutor would give feedback. While using LLMs is promising, the critical challenge is to ensure high precision in the generated feedback, which is imperative before deploying such technology in classrooms. The main research question we study is: Can we develop LLMs-based feedback generation techniques with a tunable precision parameter, giving educators quality control over the feedback that students receive? To this end, we introduce PyFiXV, our technique to generate high-precision feedback powered by Codex. The key idea behind PyFiXV is to use a novel run-time validation mechanism to decide whether the generated feedback is suitable for sharing with the student; notably, this validation mechanism also provides a precision knob to educators. We perform an extensive evaluation using two real-world datasets of Python programs with syntax errors and show the efficacy of PyFiXV in generating high-precision feedback.

The claims and statistics of this paper haven’t been checked yet.

Run the check — free, no account needed. It reads the open-access text and checks the sources it cites.

A few free checks a day · papers already verified open instantly · results are public

Integrity signals

Registry

DataCite · 10.48550/arxiv.2302.04662

Cites

Statistics

Claims the paper makes

The claims and statistics of this paper haven’t been checked yet.

Run the check — free, no account needed. It reads the open-access text and checks the sources it cites.

A few free checks a day · papers already verified open instantly · results are public

Self-check

Percentages, sums and reported differences re-computed from the paper’s own numbers.

The self-check needs the paper’s full text.

Cites

No references could be resolved yet.

Research works printed but not linked: 19

  1. Mark Chen and et al. Evaluating Large Language Mod- els Trained on Code. CoRR, abs/2107.03374, 2021. · arXiv
  2. Tom B. Brown and et al. Language Models are Few- Shot Learners. In NeurIPS, 2020.
  3. Brett A. Becker. What Does Saying That 'Program- ming is Hard' Really Say, and About Whom? Commu- nications of ACM, 64(8):27-29, 2021.
  4. Rishabh Singh, Sumit Gulwani, and Armando Solar- Lezama. Automated Feedback Generation for Intro- ductory Programming Assignments. In PLDI, 2013.
  5. Sumit Gulwani, Ivan Radicek, and Florian Zuleger. Au- tomated Clustering and Program Repair for Introduc- tory Programming Assignments. In PLDI, 2018.
  6. Sahil Bhatia, Pushmeet Kohli, and Rishabh Singh. Neuro-Symbolic Program Corrector for Introductory Programming Assignments. In ICSE, 2018.
  7. Rahul Gupta, Aditya Kanade, and Shirish K. Shevade. Deep Reinforcement Learning for Syntactic Error Re- pair in Student Programs. In AAAI, 2019.
  8. Jialu Zhang, José Cambronero, Sumit Gulwani, Vu Le, Ruzica Piskac, Gustavo Soares, and Gust Verbruggen. Repairing Bugs in Python Assignments Using Large Language Models. CoRR, abs/2209.14876, 2022. · arXiv
  9. Harshit Joshi, José Pablo Cambronero Sánchez, Sumit Gulwani, Vu Le, Ivan Radicek, and Gust Verbruggen. Repair is Nearly Generation: Multilingual Program Re- pair with LLMs. In AAAI, 2023.
  10. Björn Hartmann, Daniel MacDougall, Joel Brandt, and Scott R. Klemmer. What Would Other Programmers Do: Suggesting Solutions to Error Messages. In CHI, 2010.
  11. Darren Key, Wen-Ding Li, and Kevin Ellis. I Speak, You Verify: Toward Trustworthy Neural Program Syn- thesis. CoRR, abs/2210.00848, 2022. · arXiv
  12. Sergey Edunov, Myle Ott, Michael Auli, and David Grangier. Understanding Back-Translation at Scale. In EMNLP, 2018.
  13. Yewen Pu, Kevin Ellis, Marta Kryven, Josh Tenen- baum, and Armando Solar-Lezama. Program Synthesis with Pragmatic Communication. In NeurIPS, 2020.
  14. Zhiyu Fan, Xiang Gao, Abhik Roychoudhury, and Shin Hwei Tan. Automated Repair of Programs from Large Language Models. In ICSE, 2022.
  15. Rohan Bavishi, Harshit Joshi, José Cambronero, Anna Fariha, Sumit Gulwani, Vu Le, Ivan Radicek, and Ashish Tiwari. Neurosymbolic Repair for Low-Code Formula Languages. Proceedings ACM Programming Languages, 6(OOPSLA2), 2022.
  16. Kishore Papineni, Salim Roukos, Todd Ward, and Wei- Jing Zhu. BLEU: A Method for Automatic Evaluation of Machine Translation. In ACL, 2002.
  17. Matthijs J Warrens. Five Ways to Look at Cohen's Kappa. Journal of Psychology & Psychotherapy, 5(4): 1, 2015.
  18. William G Cochran. The χ2 Test of Goodness of Fit. The Annals of Mathematical Statistics, 1952.
  19. OpenAI. GPT-4 Technical Report. CoRR, abs/2303.08774, 2023. · arXiv

Cited by

Sorted by citations

Authors
Phung, T., Cambronero, J., Gulwani, S., Kohn, T., Majumdar, R., Singla, A., & Soares, G.
Affiliations
  • TU Wien (AT)
  • Microsoft (United States) (US)
Venue
arXiv
Publisher
arXiv
Published
2023
ISSN
2331-8422 (ISSN-L)
OpenAlex
W4320342797
Cited by
16
References
0
Citations by year
2026: 1 · 2025: 10 · 2024: 4 · 2023: 1
Type
posted content
Language
en
Open access
Locations
  • arXiv (Cornell University) (submittedVersion)
  • arXiv (Cornell University)
Funders
  • European Commission
  • HORIZON EUROPE European Research Council (101039090)
Topics
  • Physical Sciences › Computer Science › Computer Science Applications › Teaching and Learning Programming
  • Physical Sciences › Computer Science › Information Systems › Software Engineering Research
  • Physical Sciences › Computer Science › Artificial Intelligence › Intelligent Tutoring Systems and Adaptive Learning
Keywords
large language models, codices, automated feedback, syntactic errors, Python programming, introductory programming education, precision control, program repair, natural language explanations

About these checks

Registry, retraction, Cites and statistics results are computed, not judged, with one exception: a printed reference that no index lists is read once by a model before it counts as a citation error. Claims are extracted by a model and kept only when their quote appears verbatim in the text; each cited source is then checked, with a model’s help, for whether it says what the claim relies on. Those verdicts can be wrong — read the claim’s quote and the cited source before relying on one.

Statistics and arithmetic are recomputed, not judged.

Confidence bands are shown only for fields calibrated on our annotated test set. None is calibrated yet, so no band is shown.

What counts as a claim ›How we measure confidence ›How we check this ›

Are you an author, or do you see a problem with this page? Request a review