{"id":"https://openalex.org/W4391282616","doi":"https://doi.org/10.1145/3643674","title":"Refining ChatGPT-Generated Code: Characterizing and Mitigating Code Quality Issues","display_name":"Refining ChatGPT-Generated Code: Characterizing and Mitigating Code Quality Issues","publication_year":2024,"publication_date":"2024-01-27","ids":{"openalex":"https://openalex.org/W4391282616","doi":"https://doi.org/10.1145/3643674"},"language":"en","primary_location":{"id":"doi:10.1145/3643674","is_oa":true,"landing_page_url":"https://doi.org/10.1145/3643674","pdf_url":"https://dl.acm.org/doi/pdf/10.1145/3643674","source":{"id":"https://openalex.org/S142627899","display_name":"ACM Transactions on Software Engineering and Methodology","issn_l":"1049-331X","issn":["1049-331X","1557-7392"],"is_oa":false,"is_in_doaj":false,"is_core":true,"host_organization":"https://openalex.org/P4310319798","host_organization_name":"Association for Computing Machinery","host_organization_lineage":["https://openalex.org/P4310319798"],"host_organization_lineage_names":["Association for Computing Machinery"],"type":"journal"},"license":null,"license_id":null,"version":"publishedVersion","is_accepted":true,"is_published":true,"raw_source_name":"ACM Transactions on Software Engineering and Methodology","raw_type":"journal-article"},"type":"article","indexed_in":["crossref"],"open_access":{"is_oa":true,"oa_status":"bronze","oa_url":"https://dl.acm.org/doi/pdf/10.1145/3643674","any_repository_has_fulltext":true},"authorships":[{"author_position":"first","author":{"id":"https://openalex.org/A5100320074","display_name":"Yue Liu","orcid":"https://orcid.org/0000-0002-5593-5917"},"institutions":[{"id":"https://openalex.org/I56590836","display_name":"Monash University","ror":"https://ror.org/02bfwt286","country_code":"AU","type":"education","lineage":["https://openalex.org/I56590836"]},{"id":"https://openalex.org/I79891267","display_name":"Singapore Management University","ror":"https://ror.org/050qmg959","country_code":"SG","type":"education","lineage":["https://openalex.org/I79891267"]}],"countries":["AU","SG"],"is_corresponding":false,"raw_author_name":"Yue Liu","raw_affiliation_strings":["Monash University, Clayton, Australia and Singapore Management University, Singapore, Singapore"],"raw_orcid":"https://orcid.org/0000-0002-5593-5917","affiliations":[{"raw_affiliation_string":"Monash University, Clayton, Australia and Singapore Management University, Singapore, Singapore","institution_ids":["https://openalex.org/I79891267","https://openalex.org/I56590836"]}]},{"author_position":"middle","author":{"id":"https://openalex.org/A5013306670","display_name":"Thanh Le-Cong","orcid":"https://orcid.org/0000-0002-9566-324X"},"institutions":[{"id":"https://openalex.org/I165779595","display_name":"The University of Melbourne","ror":"https://ror.org/01ej9dk98","country_code":"AU","type":"education","lineage":["https://openalex.org/I165779595"]}],"countries":["AU"],"is_corresponding":false,"raw_author_name":"Thanh Le-Cong","raw_affiliation_strings":["The University of Melbourne, Melbourne, Australia"],"raw_orcid":"https://orcid.org/0000-0002-9566-324X","affiliations":[{"raw_affiliation_string":"The University of Melbourne, Melbourne, Australia","institution_ids":["https://openalex.org/I165779595"]}]},{"author_position":"middle","author":{"id":"https://openalex.org/A5009224648","display_name":"Ratnadira Widyasari","orcid":"https://orcid.org/0000-0001-8190-5458"},"institutions":[{"id":"https://openalex.org/I79891267","display_name":"Singapore Management University","ror":"https://ror.org/050qmg959","country_code":"SG","type":"education","lineage":["https://openalex.org/I79891267"]}],"countries":["SG"],"is_corresponding":false,"raw_author_name":"Ratnadira Widyasari","raw_affiliation_strings":["Singapore Management University, Singapore, Singapore"],"raw_orcid":"https://orcid.org/0000-0001-8190-5458","affiliations":[{"raw_affiliation_string":"Singapore Management University, Singapore, Singapore","institution_ids":["https://openalex.org/I79891267"]}]},{"author_position":"middle","author":{"id":"https://openalex.org/A5081449581","display_name":"Chakkrit Tantithamthavorn","orcid":"https://orcid.org/0000-0002-5516-9984"},"institutions":[{"id":"https://openalex.org/I56590836","display_name":"Monash University","ror":"https://ror.org/02bfwt286","country_code":"AU","type":"education","lineage":["https://openalex.org/I56590836"]}],"countries":["AU"],"is_corresponding":false,"raw_author_name":"Chakkrit Tantithamthavorn","raw_affiliation_strings":["Monash University, Clayton, Australia"],"raw_orcid":"https://orcid.org/0000-0002-5516-9984","affiliations":[{"raw_affiliation_string":"Monash University, Clayton, Australia","institution_ids":["https://openalex.org/I56590836"]}]},{"author_position":"middle","author":{"id":"https://openalex.org/A5106407830","display_name":"Li Li","orcid":"https://orcid.org/0000-0003-2990-1614"},"institutions":[{"id":"https://openalex.org/I82880672","display_name":"Beihang University","ror":"https://ror.org/00wk2mp56","country_code":"CN","type":"education","lineage":["https://openalex.org/I82880672"]}],"countries":["CN"],"is_corresponding":false,"raw_author_name":"Li Li","raw_affiliation_strings":["Beihang University, Beijing, China"],"raw_orcid":"https://orcid.org/0000-0003-2990-1614","affiliations":[{"raw_affiliation_string":"Beihang University, Beijing, China","institution_ids":["https://openalex.org/I82880672"]}]},{"author_position":"middle","author":{"id":"https://openalex.org/A5075260906","display_name":"Xuan-Bach D. Le","orcid":"https://orcid.org/0000-0001-5044-1582"},"institutions":[{"id":"https://openalex.org/I165779595","display_name":"The University of Melbourne","ror":"https://ror.org/01ej9dk98","country_code":"AU","type":"education","lineage":["https://openalex.org/I165779595"]}],"countries":["AU"],"is_corresponding":false,"raw_author_name":"Xuan-Bach D. Le","raw_affiliation_strings":["The University of Melbourne, Melbourne, Australia"],"raw_orcid":"https://orcid.org/0000-0001-5044-1582","affiliations":[{"raw_affiliation_string":"The University of Melbourne, Melbourne, Australia","institution_ids":["https://openalex.org/I165779595"]}]},{"author_position":"last","author":{"id":"https://openalex.org/A5081036622","display_name":"David Lo","orcid":"https://orcid.org/0000-0002-4367-7201"},"institutions":[{"id":"https://openalex.org/I79891267","display_name":"Singapore Management University","ror":"https://ror.org/050qmg959","country_code":"SG","type":"education","lineage":["https://openalex.org/I79891267"]}],"countries":["SG"],"is_corresponding":false,"raw_author_name":"David Lo","raw_affiliation_strings":["Singapore Management University, Singapore, Singapore"],"raw_orcid":"https://orcid.org/0000-0002-4367-7201","affiliations":[{"raw_affiliation_string":"Singapore Management University, Singapore, Singapore","institution_ids":["https://openalex.org/I79891267"]}]}],"institutions":[],"countries_distinct_count":3,"institutions_distinct_count":4,"corresponding_author_ids":[],"corresponding_institution_ids":[],"apc_list":null,"apc_paid":null,"fwci":10.7965,"has_fulltext":true,"cited_by_count":124,"citation_normalized_percentile":{"value":0.98863988,"is_in_top_1_percent":false,"is_in_top_10_percent":true},"cited_by_percentile_year":{"min":89,"max":100},"biblio":{"volume":"33","issue":"5","first_page":"1","last_page":"26"},"is_retracted":false,"is_paratext":false,"is_xpac":false,"primary_topic":{"id":"https://openalex.org/T11636","display_name":"Artificial Intelligence in Healthcare and Education","score":0.9943000078201294,"subfield":{"id":"https://openalex.org/subfields/2718","display_name":"Health Informatics"},"field":{"id":"https://openalex.org/fields/27","display_name":"Medicine"},"domain":{"id":"https://openalex.org/domains/4","display_name":"Health Sciences"}},"topics":[{"id":"https://openalex.org/T11636","display_name":"Artificial Intelligence in Healthcare and Education","score":0.9943000078201294,"subfield":{"id":"https://openalex.org/subfields/2718","display_name":"Health Informatics"},"field":{"id":"https://openalex.org/fields/27","display_name":"Medicine"},"domain":{"id":"https://openalex.org/domains/4","display_name":"Health Sciences"}},{"id":"https://openalex.org/T10028","display_name":"Topic Modeling","score":0.9936000108718872,"subfield":{"id":"https://openalex.org/subfields/1702","display_name":"Artificial Intelligence"},"field":{"id":"https://openalex.org/fields/17","display_name":"Computer Science"},"domain":{"id":"https://openalex.org/domains/3","display_name":"Physical Sciences"}},{"id":"https://openalex.org/T12026","display_name":"Explainable Artificial Intelligence (XAI)","score":0.9577999711036682,"subfield":{"id":"https://openalex.org/subfields/1702","display_name":"Artificial Intelligence"},"field":{"id":"https://openalex.org/fields/17","display_name":"Computer Science"},"domain":{"id":"https://openalex.org/domains/3","display_name":"Physical Sciences"}}],"keywords":[{"id":"https://openalex.org/keywords/computer-science","display_name":"Computer science","score":0.7997386455535889},{"id":"https://openalex.org/keywords/refining","display_name":"Refining (metallurgy)","score":0.6486598253250122},{"id":"https://openalex.org/keywords/code","display_name":"Code (set theory)","score":0.5638751983642578},{"id":"https://openalex.org/keywords/quality","display_name":"Quality (philosophy)","score":0.4369274973869324},{"id":"https://openalex.org/keywords/programming-language","display_name":"Programming language","score":0.21030282974243164},{"id":"https://openalex.org/keywords/chemistry","display_name":"Chemistry","score":0.06707826256752014}],"concepts":[{"id":"https://openalex.org/C41008148","wikidata":"https://www.wikidata.org/wiki/Q21198","display_name":"Computer science","level":0,"score":0.7997386455535889},{"id":"https://openalex.org/C60044698","wikidata":"https://www.wikidata.org/wiki/Q1283324","display_name":"Refining (metallurgy)","level":2,"score":0.6486598253250122},{"id":"https://openalex.org/C2776760102","wikidata":"https://www.wikidata.org/wiki/Q5139990","display_name":"Code (set theory)","level":3,"score":0.5638751983642578},{"id":"https://openalex.org/C2779530757","wikidata":"https://www.wikidata.org/wiki/Q1207505","display_name":"Quality (philosophy)","level":2,"score":0.4369274973869324},{"id":"https://openalex.org/C199360897","wikidata":"https://www.wikidata.org/wiki/Q9143","display_name":"Programming language","level":1,"score":0.21030282974243164},{"id":"https://openalex.org/C185592680","wikidata":"https://www.wikidata.org/wiki/Q2329","display_name":"Chemistry","level":0,"score":0.06707826256752014},{"id":"https://openalex.org/C147789679","wikidata":"https://www.wikidata.org/wiki/Q11372","display_name":"Physical chemistry","level":1,"score":0.0},{"id":"https://openalex.org/C177264268","wikidata":"https://www.wikidata.org/wiki/Q1514741","display_name":"Set (abstract data type)","level":2,"score":0.0},{"id":"https://openalex.org/C111472728","wikidata":"https://www.wikidata.org/wiki/Q9471","display_name":"Epistemology","level":1,"score":0.0},{"id":"https://openalex.org/C138885662","wikidata":"https://www.wikidata.org/wiki/Q5891","display_name":"Philosophy","level":0,"score":0.0}],"mesh":[],"locations_count":2,"locations":[{"id":"doi:10.1145/3643674","is_oa":true,"landing_page_url":"https://doi.org/10.1145/3643674","pdf_url":"https://dl.acm.org/doi/pdf/10.1145/3643674","source":{"id":"https://openalex.org/S142627899","display_name":"ACM Transactions on Software Engineering and Methodology","issn_l":"1049-331X","issn":["1049-331X","1557-7392"],"is_oa":false,"is_in_doaj":false,"is_core":true,"host_organization":"https://openalex.org/P4310319798","host_organization_name":"Association for Computing Machinery","host_organization_lineage":["https://openalex.org/P4310319798"],"host_organization_lineage_names":["Association for Computing Machinery"],"type":"journal"},"license":null,"license_id":null,"version":"publishedVersion","is_accepted":true,"is_published":true,"raw_source_name":"ACM Transactions on Software Engineering and Methodology","raw_type":"journal-article"},{"id":"pmh:oai:ink.library.smu.edu.sg:sis_research-10242","is_oa":true,"landing_page_url":"https://ink.library.smu.edu.sg/sis_research/9242","pdf_url":null,"source":{"id":"https://openalex.org/S4306401925","display_name":"Singapore Management University Institutional Knowledge (InK) (Singapore Management University)","issn_l":null,"issn":null,"is_oa":false,"is_in_doaj":false,"is_core":false,"host_organization":"https://openalex.org/I79891267","host_organization_name":"Singapore Management University","host_organization_lineage":["https://openalex.org/I79891267"],"host_organization_lineage_names":[],"type":"repository"},"license":"cc-by-nc-nd","license_id":"https://openalex.org/licenses/cc-by-nc-nd","version":"submittedVersion","is_accepted":false,"is_published":false,"raw_source_name":"https://doi.org/10.1145/3643674","raw_type":"Journal Article"}],"best_oa_location":{"id":"doi:10.1145/3643674","is_oa":true,"landing_page_url":"https://doi.org/10.1145/3643674","pdf_url":"https://dl.acm.org/doi/pdf/10.1145/3643674","source":{"id":"https://openalex.org/S142627899","display_name":"ACM Transactions on Software Engineering and Methodology","issn_l":"1049-331X","issn":["1049-331X","1557-7392"],"is_oa":false,"is_in_doaj":false,"is_core":true,"host_organization":"https://openalex.org/P4310319798","host_organization_name":"Association for Computing Machinery","host_organization_lineage":["https://openalex.org/P4310319798"],"host_organization_lineage_names":["Association for Computing Machinery"],"type":"journal"},"license":null,"license_id":null,"version":"publishedVersion","is_accepted":true,"is_published":true,"raw_source_name":"ACM Transactions on Software Engineering and Methodology","raw_type":"journal-article"},"sustainable_development_goals":[],"awards":[{"id":"https://openalex.org/G5332036567","display_name":null,"funder_award_id":"NRF-NRFI08-2022-0002","funder_id":"https://openalex.org/F4320320671","funder_display_name":"National Research Foundation"}],"funders":[{"id":"https://openalex.org/F4320320671","display_name":"National Research Foundation","ror":"https://ror.org/05s0g1g46"}],"has_content":{"pdf":true,"grobid_xml":true},"content_urls":{"pdf":"https://content.openalex.org/works/W4391282616.pdf","grobid_xml":"https://content.openalex.org/works/W4391282616.grobid-xml"},"referenced_works_count":48,"referenced_works":["https://openalex.org/W1566773348","https://openalex.org/W1972978214","https://openalex.org/W2011044158","https://openalex.org/W2402612280","https://openalex.org/W2404987555","https://openalex.org/W2600957813","https://openalex.org/W2724374034","https://openalex.org/W2728220450","https://openalex.org/W3083954092","https://openalex.org/W3096150021","https://openalex.org/W3098605233","https://openalex.org/W3103223797","https://openalex.org/W3106063118","https://openalex.org/W3177813494","https://openalex.org/W3198685994","https://openalex.org/W3206570943","https://openalex.org/W4224060952","https://openalex.org/W4224308101","https://openalex.org/W4284676027","https://openalex.org/W4286750487","https://openalex.org/W4287024925","https://openalex.org/W4287674181","https://openalex.org/W4297435087","https://openalex.org/W4297677548","https://openalex.org/W4311165836","https://openalex.org/W4311887664","https://openalex.org/W4312438588","https://openalex.org/W4313547549","https://openalex.org/W4315815628","https://openalex.org/W4318902699","https://openalex.org/W4321472057","https://openalex.org/W4323896452","https://openalex.org/W4366204357","https://openalex.org/W4367000100","https://openalex.org/W4367860052","https://openalex.org/W4381304075","https://openalex.org/W4384345708","https://openalex.org/W4384345745","https://openalex.org/W4386081573","https://openalex.org/W4388090406","https://openalex.org/W4399557965","https://openalex.org/W6782465632","https://openalex.org/W6798182279","https://openalex.org/W6800166007","https://openalex.org/W6810081322","https://openalex.org/W6840793632","https://openalex.org/W6843135089","https://openalex.org/W6851748684"],"related_works":["https://openalex.org/W4391375266","https://openalex.org/W2748952813","https://openalex.org/W1595345252","https://openalex.org/W2392526918","https://openalex.org/W2362540361","https://openalex.org/W2019560916","https://openalex.org/W2361983698","https://openalex.org/W2347697528","https://openalex.org/W2354123794","https://openalex.org/W2372508235"],"abstract_inverted_index":{"Since":[0],"its":[1,13,117,222],"introduction":[2],"in":[3,16,80,233],"November":[4],"2022,":[5],"ChatGPT":[6,48,106,240,273],"has":[7,27],"rapidly":[8],"gained":[9],"popularity":[10],"due":[11],"to":[12,228,284],"remarkable":[14],"ability":[15,220],"language":[17],"understanding":[18],"and":[19,42,87,111,129,135,176,202,204,221,258,274,281],"human-like":[20],"responses.":[21],"ChatGPT,":[22,165],"based":[23],"on":[24,107],"GPT-3.5":[25],"architecture,":[26],"shown":[28],"great":[29],"promise":[30],"for":[31,89,260,278],"revolutionizing":[32],"various":[33],"research":[34,280],"fields,":[35],"including":[36,119],"code":[37,45,63,78,108,193,200,209,247,287],"generation.":[38,64],"However,":[39],"the":[40,58,71,103,113,140,191,230,234,269,286],"reliability":[41],"quality":[43,72,141,248],"of":[44,61,73,77,95,105,142,160,190,272,290],"generated":[46,163,192],"by":[47,164,249],"remain":[49],"unexplored,":[50],"raising":[51],"concerns":[52],"about":[53],"potential":[54,137],"risks":[55],"associated":[56],"with":[57,139,224],"widespread":[59],"use":[60],"ChatGPT-driven":[62],"In":[65],"this":[66,96],"article,":[67],"we":[68,101,133,146,185,216],"systematically":[69],"study":[70,264],"4,066":[74,161],"ChatGPT-generated":[75,143,208],"programs":[76,162,167,172,178],"implemented":[79],"two":[81],"popular":[82],"programming":[83,91,122],"languages,":[84],"i.e.,":[85],"Java":[86],"Python,":[88],"2,033":[90],"tasks.":[92],"The":[93],"goal":[94],"work":[97],"is":[98],"threefold.":[99],"First,":[100],"analyze":[102,187],"correctness":[104],"generation":[109,288],"tasks":[110,126],"uncover":[112],"factors":[114],"that":[115,125,158,206,239],"influence":[116],"effectiveness,":[118],"task":[120],"difficulty,":[121],"language,":[123],"time":[124],"are":[127,168,255],"introduced,":[128],"program":[130],"size.":[131],"Second,":[132],"identify":[134],"characterize":[136],"issues":[138,152],"code.":[144],"Last,":[145],"provide":[147,173],"insights":[148,267],"into":[149,268],"how":[150],"these":[151,244],"can":[153,241],"be":[154],"mitigated.":[155],"Experiments":[156,237],"highlight":[157],"out":[159],"2,756":[166],"deemed":[169],"correct,":[170],"1,082":[171],"wrong":[174],"outputs,":[175],"177":[177],"contain":[179],"compilation":[180],"or":[181],"runtime":[182],"errors.":[183],"Additionally,":[184],"further":[186],"other":[188],"characteristics":[189],"through":[194],"static":[195,225],"analysis":[196,226],"tools,":[197],"such":[198,294],"as":[199,295],"style":[201],"maintainability,":[203],"find":[205],"1,930":[207],"snippets":[210],"suffer":[211],"from":[212],"maintainability":[213],"issues.":[214],"Subsequently,":[215],"investigate":[217],"ChatGPT\u2019s":[218],"self-repairing":[219],"interaction":[223],"tools":[227],"fix":[229],"errors":[231],"uncovered":[232],"previous":[235],"step.":[236],"suggest":[238],"partially":[242],"address":[243],"challenges,":[245],"improving":[246],"more":[250],"than":[251],"20%,":[252],"but":[253],"there":[254],"still":[256],"limitations":[257,271],"opportunities":[259],"improvement.":[261],"Overall,":[262],"our":[263],"provides":[265],"valuable":[266],"current":[270],"offers":[275],"a":[276],"roadmap":[277],"future":[279],"development":[282],"efforts":[283],"enhance":[285],"capabilities":[289],"artificial":[291],"intelligence":[292],"models":[293],"ChatGPT.":[296]},"counts_by_year":[{"year":2026,"cited_by_count":23},{"year":2025,"cited_by_count":70},{"year":2024,"cited_by_count":30},{"year":2023,"cited_by_count":1}],"updated_date":"2026-07-18T07:39:51.176621","created_date":"2025-10-10T00:00:00"}
