Development of Code Evaluation System based on Abstract Syntax Tree

Các tác giả

  • Anh-Tu Phuong Nguyen Ho Chi Minh City University of Technology and Education, Vietnam
  • Van-Dung Hoang HCMC University of Technology and Education, Vietnam https://orcid.org/0000-0001-7554-1707

Email tác giả liên hệ:

dunghv@hcmute.edu.vn

DOI:

https://doi.org/10.54644/jte.2024.1514

Từ khóa:

Structure Code, AST, Evaluating code in learning online, Global state and Compile, Hashing value

Tóm tắt

Analyzing and evaluating student-generated code poses a big headache for programming education. Code evaluation is a delicate task requiring accuracy, efficiency, and error-checking. This paper considers one of the many useful tools in code evaluation. It's Abstract Syntax Trees (AST). AST is a robust tool for reading, filtering, and weighing student code. It is built from tree regular expressions for common programming patterns. This paper considers, firstly, integrating AST into code evaluation projects. Secondly and most importantly to the present implementation work is that Python programming language provides excellent compatibility for implementing such a program. Taking advantage of Python's feature that allows the inputting of code as a string, AST records and tracks everything about the user's own source. With AST being integrated into platforms for education, how to evaluate student code has been completely altered; as sites such as LeetCode and HackerRank testify. This paper presents an accurate, efficient and error-aware approach to code evaluation by improving on educational websites incorporating AST. Adapting well to the dynamics of programming education, this elaborate assessment system will provide students with truthful assessments and profound feedback on their coding capabilities. This article shows how AST-based evaluation has revolutionized the way programming is taught, and thoroughly explores its role in evaluating code.

Tải xuống: 0

Dữ liệu tải xuống chưa có sẵn.

Tiểu sử của Tác giả

Anh-Tu Phuong Nguyen, Ho Chi Minh City University of Technology and Education, Vietnam

Nguyen Phuong Anh Tu is currently studying at the Ho Chi Minh City University of Technology and Education, Vietnam, major in Information Technology. Email: 21110105@student.hcmute.edu.vn

Van-Dung Hoang, HCMC University of Technology and Education, Vietnam

Hoang Van Dung received the Ph.D. degree from the University of Ulsan, South Korea, in 2014. He was associated and joined as a visiting researcher with the Intelligence Systems Laboratory, University of Ulsan, 2015. He joined the Robotics Laboratory on Artificial Intelligence, Telecom SudParis as a postdoctoral fellow, 2016. He has been serving as an associate professor in computer science, Faculty of Information Technology, Ho Chi Minh City University of Technology and Education, Vietnam. He has published numerous research articles in ISI, Scopus indexed, and high-impact factor journals. He has been actively participating as a member of the societies as IEEE, IEEE Computer, ICROS. His research interests include a wide area, which focuses on pattern recognition, machine learning, medical image processing, computer vision application, vision-based robotics, and ambient intelligence. Email: dunghv@hcmute.edu.vn. ORCID: https://orcid.org/0000-0001-7554-1707

Tài liệu tham khảo

Y. Taniguchi, T. Minematsu, F. Okubo, and A. Shimada, "Visualizing Source-Code Evolution for Understanding Class-Wide Programming Processes," Sustainability, vol. 14, p. 8084, 2022, doi: 10.3390/su14138084. DOI: https://doi.org/10.3390/su14138084

D. Moore, J. Edwards, H. Karimi, R. Khadka, and P. Bodily, "Temporal Abstract Syntax Trees for Understanding Student Coding Thought Process," 2022 Intermountain Engineering, Technology and Computing (IETC), Orem, UT, USA, 2022, pp. 1-6, doi: 10.1109/IETC54973.2022.9796943. DOI: https://doi.org/10.1109/IETC54973.2022.9796943

V. Agrahari and S. Chimalakonda, "AST[AR] – Towards Using Augmented Reality and Abstract Syntax Trees for Teaching Data Structures To Novice Programmers," doi: 10.1109/ICALT49669.2020.00100. DOI: https://doi.org/10.1109/ICALT49669.2020.00100

J. S. F. M. H. Lulian Neamtiu, "Understanding source code evolution using abstract syntax tree matching," doi: 10.1145/1083142.1083143. DOI: https://doi.org/10.1145/1083142.1083143

D. Hovemeyer, A. Hellas, A. Petersen, and J. Spacco, "Control-Flow-Only Abstract Syntax Trees for Analyzing Students' Programming Progress," doi: 10.1145/2960310.2960326, 10.1109/ICSE.2019.00086. DOI: https://doi.org/10.1145/2960310.2960326

C. Lin et al., "Improving Code Summarization with Block-wise Abstract Syntax Tree Splitting," doi: 10.1109/ICPC52881.2021.00026. DOI: https://doi.org/10.1109/ICPC52881.2021.00026

S. Peacock, L. Deng, J. Dehlinger, and S. Chakraborty, "Automatic Equivalent Mutants Classification Using Abstract Syntax Tree Neural Networks," doi: 10.1109/ICSTW52544.2021.00016. DOI: https://doi.org/10.1109/ICSTW52544.2021.00016

D. Yang and C. V. L. Aftab Hussain, "From query to usable code: an analysis of stack overflow code snippets," doi: 10.1145/2901739.2901767. DOI: https://doi.org/10.1145/2901739.2901767

P. Sedlacek and E. Zaitseva, "Software Reliability Model based on Syntax Tree," doi: 10.1109/IDT52577.2021.9497520. DOI: https://doi.org/10.1109/IDT52577.2021.9497520

E. Spirin et al., "PSIMiner: A Tool for Mining Rich Abstract Syntax Trees from Code," doi: 10.1109/MSR52588.2021.00014. DOI: https://doi.org/10.1109/MSR52588.2021.00014

A. Z. Ablahd, "Using Python to Detect Web application vulnerability," Resmilitaris, vol.13, no. 2, 2023.

P. Hozhabrierdi, D. F. Hitos, and C. K. Mohan, "Python Source Code De-Anonymization," doi: 10.1109/ICDMW.2018.00011. DOI: https://doi.org/10.1109/ICDMW.2018.00011

C. Ziyi, L. Lu, and S. Qiu, "An Abstract Syntax Tree Encoding Method for Cross-Project Defect Prediction," doi: 10.1109/ACCESS.2019.2953696. DOI: https://doi.org/10.1109/ACCESS.2019.2953696

A. Prochnow and J. Yang, "DiffWatch: watch out for the evolving differential testing in deep learning libraries," doi: 10.1145/3510454.3516835. DOI: https://doi.org/10.1145/3510454.3516835

Y. S. J. W. I. G. H. Junchen Zhao, "GAP-Gen: Guided Automatic Python Code Generation," doi: 10.48550/arXiv.2201.08810.

M. Zheng, X. Pan, and D. Lillis, "CodEX: Source Code Plagiarism Detection," doi: 329513153.

A. Derezinska and K. Hałas, "Improving Mutation Testing Process of Python Programs," doi: 10.1007/978-3-319-18473-9_23. DOI: https://doi.org/10.1007/978-3-319-18473-9_23

T. Wang et al., "PyNose: A Test Smell Detector For Python," doi: 10.1109/ASE51524.2021.9678615. DOI: https://doi.org/10.1109/ASE51524.2021.9678615

E. M. Arts, "Towards Querying Abstract Syntax Trees for Python Programs," Master Thesis, Department of Computer Science, Eindhoven University of Technology, The Netherlands, 2022.

M. Duracik et al., "Abstract Syntax Tree Based Source Code Antiplagiarism System for Large Projects Set," doi: 10.1109/ACCESS.2020.3026422. DOI: https://doi.org/10.1109/ACCESS.2020.3026422

S. Liu et al., "ATOM: Commit Message Generation Based on Abstract Syntax Tree and Hybrid Ranking," doi: 10.1109/TSE.2020.3038681. DOI: https://doi.org/10.1109/TSE.2020.3038681

X. Li and X. J. Zhong, "The Source Code Plagiarism Detection Using AST," doi: 10.1109/IPTC.2010.90. DOI: https://doi.org/10.1109/IPTC.2010.90

D. Perez and S. Chiba, "Cross-Language Clone Detection by Learning Over Abstract Syntax Trees," doi: 10.1109/MSR.2019.00078. DOI: https://doi.org/10.1109/MSR.2019.00078

I. Dejanović et al., "A Python tool for the implementation of domain-specific languages," doi: 10.1063/1.4992501. DOI: https://doi.org/10.1063/1.4992501

Tải xuống

Đã Xuất bản

2024-02-28

Cách trích dẫn

[1]
A.-T. P. Nguyen và V.-D. Hoang, “Development of Code Evaluation System based on Abstract Syntax Tree”, JTE, vol 19, số p.h Special Issue 01, tr 15–24, tháng 2 2024.

Số

Chuyên mục

Bài báo khoa học

Categories