Journal article

Refining ChatGPT-Generated Code: Characterizing and Mitigating Code Quality Issues

Y Liu, T Le-Cong, R Widyasari, C Tantithamthavorn, L Li, XBD Le, D Lo

ACM Transactions on Software Engineering and Methodology | ASSOC COMPUTING MACHINERY | Published : 2024

Abstract

Since its introduction in November 2022, ChatGPT has rapidly gained popularity due to its remarkable ability in language understanding and human-like responses. ChatGPT, based on GPT-3.5 architecture, has shown great promise for revolutionizing various research fields, including code generation. However, the reliability and quality of code generated by ChatGPT remain unexplored, raising concerns about potential risks associated with the widespread use of ChatGPT-driven code generation.In this article, we systematically study the quality of 4,066 ChatGPT-generated programs of code implemented in two popular programming languages, i.e., Java and Python, for 2,033 programming tasks. The goal of..

View full abstract

University of Melbourne Researchers

Grants

Awarded by Google


Funding Acknowledgements

This research/project is supported by the National Research Foundation under its Investigatorship Grant (grant no. NRFNRFI08-2022-0002). Chakkrit Tantithamthavorn was supported by the Australian Research Council's Discovery Early Career Researcher Award (DECRA) funding scheme (grant no. DE200100941). Xuan-Bach D. Le is supported by the Australian Government through the Australian Research Council's Discovery Early Career Researcher Award (DECRA) funding scheme (grant no. DE220101057). Thanh Le-Cong is partially supported by Google through its Ph.D. Fellowship program.