arrow
Return

What are the differences between student and ChatGPT-generated pseudocode? Detecting AI-generated pseudocode in high school programming using explainable machine learning

delete2025-02-01
delete0
PRE
AI
Z
Zifeng Liu
邢婉丽 cover
邢婉丽 (Wanli Xing) *
X
Xinyue Jiao
C
Chenglu Li
W
Wangda Zhu
DOI:10.1007/s10639-025-13385-zdelete
deleteOriginal
deleteOriginal request for help
deleteShare
deleteSave
Abstract

Abstract

En 中文
The ability of large language models (LLMs) to generate code has raised concerns in computer science education, as students may use tools like ChatGPT for programming assignments. While much research has focused on higher education, especially for languages like Java and Python, little attention has been given to K-12 settings, particularly for pseudocode. This study seeks to bridge this gap by developing explainable machine learning models for detecting pseudocode plagiarism in online programming education. A comprehensive pseudocode dataset was constructed, comprising 7,838 pseudocode submissions from 2,578 high school students enrolled in an online programming foundations course from 2020 to 2023, along with 6,300 pseudocode samples generated by three versions of ChatGPT. An ensemble model (EM) was then proposed to detect AI-generated pseudocode and was compared with six other baseline models. SHapley Additive exPlanations were used to explain how these models differentiate AI-generated pseudocode from student submissions. The results show that students' submissions have higher similarity with GPT-3 than with the other two GPT models. The proposed model can achieve a high accuracy score of 98.97%. The differences between AI-generated pseudocode and student submissions lies in several aspects: AI-generated pseudocode often begins with more complex verbs and features shorter sentence lengths. It frequently includes clear numerical or word-based indicators of sequence and tends to incorporate more comments throughout the code. This research provides practical insights for online programming and contributes to developing educational technologies and methods that strengthen academic integrity in such courses.
Keywords:
Pseudocode
Generative AI
Explainable
Plagiarism detection
Online programming education
ChatGPT

Journal

Education and Information Technologies cover
Education and Information Technologies
IF:
5.4
Papers:
932
Citations:
1.7W

Organization

U
Univ Florida
Scholars:
2.8K
Papers: 2.0K
Citations: 556
N
NYU
Scholars:
1.8K
Papers: 1.1K
Citations: 390
U
Univ Utah
Scholars:
2.0K
Papers: 1.4K
Citations: 436
researcher View more organizations