通过代码编辑嵌入分析学生调试行为,实现个性化代码建议。
Learning Code-Edit Embedding to Model Student Debugging Behavior
- 用编码器-解码器模型学习连续代码提交间的编辑嵌入。
- 在真实数据集上实现92%的代码重建准确率,提升测试通过率。
- 适合教育AI、智能编程助手研发者使用。
在计算机科学教育中,为编程作业提供有效反馈颇具挑战:学生通过反复提交代码、运行并依据编译器或自动评分器的有限反馈进行调试。分析这一过程中的学生调试行为,可揭示其知识水平,并推动个性化支持工具的发展。本文提出一种基于编码器-解码器的模型,学习连续学生代码提交之间的有意义代码编辑嵌入,以捕捉其调试行为。该模型利用每个测试用例是否通过的信息,微调大语言模型(LLMs)以学习代码编辑表示,从而实现保持学生编码风格的同时提升测试通过率的个性化下一步代码建议。此外,模型结合聚类技术分析学生代码编辑模式,揭示常见错误与调试习惯。在真实学生代码提交数据集上的实验表明,该模型在代码重建和个性化建议方面表现优异,并揭示了有趣的调试行为模式。
原文摘要 · Abstract (English)
Providing effective feedback for programming assignments in computer science education can be challenging: students solve problems by iteratively submitting code, executing it, and using limited feedback from the compiler or the auto-grader to debug. Analyzing student debugging behavior in this process may reveal important insights into their knowledge and inform better personalized support tools. In this work, we propose an encoder-decoder-based model that learns meaningful code-edit embeddings between consecutive student code submissions, to capture their debugging behavior. Our model leverages information on whether a student code submission passes each test case to fine-tune large language models (LLMs) to learn code editing representations. It enables personalized next-step code suggestions that maintain the student's coding style while improving test case correctness. Our model also enables us to analyze student code-editing patterns to uncover common student errors and debugging behaviors, using clustering techniques. Experimental results on a real-world student code submission dataset demonstrate that our model excels at code reconstruction and personalized code suggestion while revealing interesting patterns in student debugging behavior.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。