Evaluating LLM-generated Worked Examples in an Introductory Programming Course
Top Cited Papers
Open Access
- 29 January 2024
- conference paper
- Published by Association for Computing Machinery (ACM)
- p. 77-86
Abstract
Worked examples, which illustrate the process for solving a problem step-by-step, are a well-established pedagogical technique that has been widely studied in computing classrooms. However, creating high-quality worked examples is very time-intensive for educators, and thus learners tend not to have access to a broad range of such examples. The recent emergence of powerful large language models (LLMs), which appear capable of generating high-quality human-like content, may offer a solution. Separate strands of recent work have shown that LLMs can accurately generate code suitable for a novice audience, and that they can generate high-quality explanations of code. Therefore, LLMs may be well suited to creating a broad range of worked examples, overcoming the bottleneck of manual effort that is currently required. In this work, we present a novel tool, ‘WorkedGen’, which uses an LLM to generate interactive worked examples. We evaluate this tool with both an expert assessment of the content, and a user study involving students in a first-year Python programming course (n = ~400). We find that prompt chaining and one-shot learning are useful strategies for optimising the output of an LLM when producing worked examples. Our expert analysis suggests that LLMs generate clear explanations, and our classroom deployment revealed that students find the LLM-generated worked examples useful for their learning. We propose several avenues for future work, including investigating WorkedGen’s value in a range of programming languages, and with more complex questions suitable for more advanced courses.Keywords
This publication has 21 references indexed in Scilit:
- Cracking the code: Co-coding with AI in creative programming education2022
- AI Chains: Transparent and Controllable Human-AI Interaction by Chaining Large Language Model Prompts2022
- Expectation vs. Experience: Evaluating the Usability of Code Generation Tools Powered by Large Language Models2022
- The Robots Are Coming: Exploring the Implications of OpenAI Codex on Introductory Programming2022
- Reducing withdrawal and failure rates in introductory programming with subgoal labeled worked examplesInternational Journal of STEM Education, 2020
- Exploring the Impact of Worked Examples in a Novice Programming Environment2019
- Exploring Design Characteristics of Worked Examples to Support Programming and Algorithm DesignThe Journal of Computational Science Education, 2015
- The Example-Problem-Based Learning Model: Applying Cognitive Load TheoryProcedia - Social and Behavioral Sciences, 2015
- Tracking Student Learning from Class to Exam using Isomorphic Questions2015
- What's the best way to teach computer science to beginners?Communications of the ACM, 2015