Learning new programming skills requires tailored guidance. With the emergence of advanced Natural Language Generation models like the ChatGPT API, there is now a possibility of creating a convenient and personalized tutoring system with AI for computer science education. This paper presents GPTutor, a ChatGPT-powered programming tool, which is a Visual Studio Code extension using the ChatGPT API to provide programming code explanations. By integrating Visual Studio Code API, GPTutor can comprehensively analyze the provided code by referencing the relevant source codes. As a result, GPTutor can use designed prompts to explain the selected code with a pop-up message. GPTutor is now published at the Visual Studio Code Extension Marketplace, and its source code is openly accessible on GitHub. Preliminary evaluation indicates that GPTutor delivers the most concise and accurate explanations compared to vanilla ChatGPT and GitHub Copilot. Moreover, the feedback from students and teachers indicated that GPTutor is user-friendly and can explain given codes satisfactorily. Finally, we discuss possible future research directions for GPTutor. This includes enhancing its performance and personalization via further prompt programming, as well as evaluating the effectiveness of GPTutor with real users.
翻译:学习新的编程技能需要量身定制的指导。随着ChatGPT API等先进自然语言生成模型的出现,如今已有可能为计算机科学教育创建便捷且个性化的AI辅导系统。本文介绍GPTutor——一款基于ChatGPT的编程工具,作为Visual Studio Code扩展,通过ChatGPT API提供编程代码解释。通过整合Visual Studio Code API,GPTutor能够参考相关源代码,对提供的代码进行全面分析。因此,GPTutor可利用预设提示词,以弹出消息形式解释所选代码。目前,GPTutor已发布至Visual Studio Code扩展市场,其源代码在GitHub上公开可访问。初步评估表明,与原始ChatGPT和GitHub Copilot相比,GPTutor能提供最简洁准确的解释。此外,来自学生和教师的反馈显示,GPTutor用户友好且能令人满意地解释给定代码。最后,我们讨论了GPTutor未来的研究方向,包括通过进一步提示工程提升其性能与个性化程度,以及使用真实用户评估GPTutor的有效性。