Repairing Bugs in Python Assignments Using Large Language Models
Not on the map. Why?
Abstract (arXiv)
Students often make mistakes on their introductory programming assignments as part of their learning process. Unfortunately, providing custom repairs for these mistakes can require a substantial amount of time and effort from class instructors. Automated program repair (APR) techniques can be used to synthesize such fixes. Prior work has explored the use of symbolic and neural techniques for APR in the education domain. Both types of approaches require either substantial engineering efforts or large amounts of data and training. We propose to use a large language model trained on code, such as Codex, to build an APR system -- MMAPR -- for introductory Python programming assignments. Our system can fix both syntactic and semantic mistakes by combining multi-modal prompts, iterative querying, test-case-based selection of few-shots, and program chunking. We evaluate MMAPR on 286 real student programs and compare to a baseline built by combining a state-of-the-art Python syntax repair engine, BIFI, and state-of-the-art Python semantic repair engine for student assignments, Refactory. We find that MMAPR can fix more programs and produce smaller patches on average.
Key facts. Cited by 28 papers in the map (data through 7 Oct 2026). Builds on 19 of its 50 references that are in the map. First posted on arXiv 29 Sep 2022.
Builds on
19 of 50 references.
References · 19
- 2020Language Models are Few-Shot Learnerscited by 32,199
- 2021Evaluating Large Language Models Trained on Codecited by 8,053
- 2021Pre-train, Prompt, and Predict: A Systematic Survey of Prompting Methods in Natural Language Processingcited by 2,222
- 2022Competition-Level Code Generation with AlphaCodecited by 1,427
- 2022Synchromesh: Reliable code generation from pre-trained language modelscited by 156
- 2022Less Training, More Repairing Please: Revisiting Automated Program Repair via Zero-shot Learningcited by 76
- 2021Break-It-Fix-It: Unsupervised Learning for Program Repaircited by 71
- 2022Repair Is Nearly Generation: Multilingual Program Repair with LLMscited by 68
- 2021TOGA: A Neural Method for Test Oracle Generationcited by 57
- 2017Dynamic Neural Program Embedding for Program Repaircited by 23
- 2016Automated Clustering and Program Repair for Introductory Programming Assignmentscited by 21
- 2016Learning Syntactic Program Transformations from Examplescited by 17
7 more
- 2021Multi-modal Program Inference: a Marriage of Pre-trainedLanguage Models and Component-based Synthesiscited by 12
- 2016sk_p: a neural program corrector for MOOCscited by 10
- 2017Data-Driven Feedback Generation for Introductory Programming Exercisescited by 9
- 2021Verifix: Verified Repair of Programming Assignmentscited by 7
- 2022Automated Feedback Generation for Competition-Level Codecited by 7
- 2021FAPR: Fast and Accurate Program Repair for Introductory Programming Coursescited by 4
- 2020MACER: A Modular Framework for Accelerated Compilation Error Repaircited by 2
Built on by
Citing papers per year: 2022: 1; 2023: 14; 2024: 9; 2025: 2; 2026: 2.
28 papers.
Sort:
By area:
- 2023Code Llama: Open Foundation Models for Codecited by 2,105
- 2024Large Language Models for Education: A Survey and Outlookcited by 185
- 2023OctoPack: Instruction Tuning Code Large Language Modelscited by 178
- 2022Large Language Models Meet NL2Code: A Surveycited by 135
- 2023RLTF: Reinforcement Learning from Unit Test Feedbackcited by 110
- 2024Large Language Model (LLM) for Telecommunications: A Comprehensive Survey on Principles, Key Techniques, and Opportunitiescited by 83
- 2023Is ChatGPT the Ultimate Programming Assistant -- How far is it?cited by 72
- 2023Generative AI for Programming Education: Benchmarking ChatGPT, GPT-4, and Human Tutorscited by 38
- 2023Generating High-Precision Feedback for Programming Syntax Errors using Large Language Modelscited by 34
- 2023Automating Human Tutor-Style Programming Feedback: Leveraging GPT-4 Tutor Model for Hint Generation and GPT-3.5 Student Model for Hint Validationcited by 29
- 2023Exploring the Potential of Large Language Models to Generate Formative Programming Feedbackcited by 28
- 2023Refactoring Programs Using Large Language Models with Few-Shot Examplescited by 27
16 more
- 2024Performance-Aligned LLMs for Generating Fast Codecited by 20
- 2023Evaluating ChatGPT and GPT-4 for Visual Programmingcited by 13
- 2024Generative AI for Education (GAIED): Advances, Opportunities, and Challengescited by 13
- 2024A review on the use of large language models as virtual tutorscited by 13
- 2024How Novice Programmers Use and Experience ChatGPT when Solving Programming Exercises in an Introductory Coursecited by 11
- 2023Large Language Models in Introductory Programming Education: ChatGPT's Performance and Implications for Assessmentscited by 10
- 2023Large Language Models for In-Context Student Modeling: Synthesizing Student's Behavior in Visual Programmingcited by 8
- 2024Analyzing Chat Protocols of Novice Programmers Solving Introductory Programming Tasks with ChatGPTcited by 8
- 2023Neuron Patching: Semantic-based Neuron-level Language Model Repair for Code Generationcited by 4
- 2023Toward Reproducing Network Research Results Using Large Language Modelscited by 3
- 2024Chain of Targeted Verification Questions to Improve the Reliability of Code Generated by LLMscited by 3
- 2025PRIMG : Efficient LLM-driven Test Generation Using Mutant Prioritizationcited by 1
- 2024Peer-aided Repairer: Empowering Large Language Models to Repair Advanced Student Assignmentscited by 0
- 2025Navigating Pitfalls: Evaluating LLMs in Machine Learning Programming Educationcited by 0
- 2026Bug-Report-Driven Fault Localization: Industrial Benchmarking and Lesson Learned at ABB Roboticscited by 0
- 2026An Explainable AI Assistant for Introductory Programming Education: Improving Feedback Reliability with Instructor-AI Collaborationcited by 0
- 2026An Explainable AI Assistant for Introductory Programming Education: Improving Feedback Reliability with Instructor-AI Collaboration12 May 2026
- 2026Bug-Report-Driven Fault Localization: Industrial Benchmarking and Lesson Learned at ABB Robotics28 Apr 2026
- 2025Navigating Pitfalls: Evaluating LLMs in Machine Learning Programming Education23 May 2025
- 2025PRIMG : Efficient LLM-driven Test Generation Using Mutant Prioritization8 May 2025
- 2024How Novice Programmers Use and Experience ChatGPT when Solving Programming Exercises in an Introductory Course30 Jul 2024
- 2024Analyzing Chat Protocols of Novice Programmers Solving Introductory Programming Tasks with ChatGPT29 May 2024
- 2024Chain of Targeted Verification Questions to Improve the Reliability of Code Generated by LLMs22 May 2024
- 2024A review on the use of large language models as virtual tutors20 May 2024
- 2024Large Language Model (LLM) for Telecommunications: A Comprehensive Survey on Principles, Key Techniques, and Opportunities17 May 2024
- 2024Performance-Aligned LLMs for Generating Fast Code29 Apr 2024
- 2024Peer-aided Repairer: Empowering Large Language Models to Repair Advanced Student Assignments2 Apr 2024
- 2024Large Language Models for Education: A Survey and Outlook26 Mar 2024
16 more
- 2024Generative AI for Education (GAIED): Advances, Opportunities, and Challenges2 Feb 2024
- 2023Neuron Patching: Semantic-based Neuron-level Language Model Repair for Code Generation8 Dec 2023
- 2023Refactoring Programs Using Large Language Models with Few-Shot Examples20 Nov 2023
- 2023Large Language Models for In-Context Student Modeling: Synthesizing Student's Behavior in Visual Programming15 Oct 2023
- 2023Automating Human Tutor-Style Programming Feedback: Leveraging GPT-4 Tutor Model for Hint Generation and GPT-3.5 Student Model for Hint Validation5 Oct 2023
- 2023Toward Reproducing Network Research Results Using Large Language Models9 Sep 2023
- 2023Exploring the Potential of Large Language Models to Generate Formative Programming Feedback31 Aug 2023
- 2023Code Llama: Open Foundation Models for Code24 Aug 2023
- 2023Large Language Models in Introductory Programming Education: ChatGPT's Performance and Implications for Assessments15 Aug 2023
- 2023OctoPack: Instruction Tuning Code Large Language Models14 Aug 2023
- 2023Evaluating ChatGPT and GPT-4 for Visual Programming30 Jul 2023
- 2023RLTF: Reinforcement Learning from Unit Test Feedback10 Jul 2023
- 2023Generative AI for Programming Education: Benchmarking ChatGPT, GPT-4, and Human Tutors29 Jun 2023
- 2023Is ChatGPT the Ultimate Programming Assistant -- How far is it?24 Apr 2023
- 2023Generating High-Precision Feedback for Programming Syntax Errors using Large Language Models24 Jan 2023
- 2022Large Language Models Meet NL2Code: A Survey19 Dec 2022
- 2024Large Language Models for Education: A Survey and Outlookcited by 185
- 2023OctoPack: Instruction Tuning Code Large Language Modelscited by 178
- 2022Large Language Models Meet NL2Code: A Surveycited by 135
- 2023RLTF: Reinforcement Learning from Unit Test Feedbackcited by 110
- 2023Is ChatGPT the Ultimate Programming Assistant -- How far is it?cited by 72
- 2023Generative AI for Programming Education: Benchmarking ChatGPT, GPT-4, and Human Tutorscited by 38
- 2023Generating High-Precision Feedback for Programming Syntax Errors using Large Language Modelscited by 34
- 2023Automating Human Tutor-Style Programming Feedback: Leveraging GPT-4 Tutor Model for Hint Generation and GPT-3.5 Student Model for Hint Validationcited by 29
- 2023Exploring the Potential of Large Language Models to Generate Formative Programming Feedbackcited by 28
- 2023Refactoring Programs Using Large Language Models with Few-Shot Examplescited by 27
- 2024Performance-Aligned LLMs for Generating Fast Codecited by 20
- 2023Evaluating ChatGPT and GPT-4 for Visual Programmingcited by 13
12 most cited of 26 All 26 (JSON)
- 2026An Explainable AI Assistant for Introductory Programming Education: Improving Feedback Reliability with Instructor-AI Collaboration12 May 2026
- 2026Bug-Report-Driven Fault Localization: Industrial Benchmarking and Lesson Learned at ABB Robotics28 Apr 2026
- 2025Navigating Pitfalls: Evaluating LLMs in Machine Learning Programming Education23 May 2025
- 2025PRIMG : Efficient LLM-driven Test Generation Using Mutant Prioritization8 May 2025
- 2024How Novice Programmers Use and Experience ChatGPT when Solving Programming Exercises in an Introductory Course30 Jul 2024
- 2024Analyzing Chat Protocols of Novice Programmers Solving Introductory Programming Tasks with ChatGPT29 May 2024
- 2024Chain of Targeted Verification Questions to Improve the Reliability of Code Generated by LLMs22 May 2024
- 2024A review on the use of large language models as virtual tutors20 May 2024
- 2024Performance-Aligned LLMs for Generating Fast Code29 Apr 2024
- 2024Peer-aided Repairer: Empowering Large Language Models to Repair Advanced Student Assignments2 Apr 2024
- 2024Large Language Models for Education: A Survey and Outlook26 Mar 2024
- 2024Generative AI for Education (GAIED): Advances, Opportunities, and Challenges2 Feb 2024
12 newest of 26 All 26 (JSON)