Understanding and Mitigating Library-Related Issues in LLM-Generated Code
Software developers increasingly rely on Large Language Models (LLMs) to generate code that uses external libraries to accelerate development and avoid reinventing the wheel. However, LLMs struggle with the correct use of external libraries, particularly during the import of libraries, and frequently introduce errors that lead to time-consuming debugging and reduced developer productivity.
This work focuses on reducing library-related errors in LLM-generated code. Our contributions are twofold: first, we conduct an exploratory study to identify and quantify the main error patterns LLMs produce during library imports; second, we propose an agentic approach to address these issues. In a preliminary evaluation with 50 Python code generation tasks derived from real-world scripts and using GPT-5.2, our agentic system nearly halved library–related errors, demonstrating its potential to improve LLM-generated code reliability.
Mon 13 AprDisplayed time zone: Brasilia, Distrito Federal, Brazil change
09:45 - 10:30 | |||
09:45 5mTalk | Understanding and Mitigating Library-Related Issues in LLM-Generated Code Journal Ahead Workshop (JAWs) Yacine Majdoub University of Gabes, Rinad Hamid University of Calgary, Canada, Eya Ben Charrada University of Gabes, Ahmad Abdellatif University of Calgary, Haifa Touati IReSCoMath Research Lab, Faculty of Sciences, University Of Gabes, Tunisia | ||
09:50 5mTalk | Magnifying Inefficiency: How LLMs Amplify Performance Anti-Patterns in Mobile Development Journal Ahead Workshop (JAWs) | ||
09:55 5mTalk | BRACE: Unified Benchmarking of Accuracy and Energy for Code Language Models Journal Ahead Workshop (JAWs) Mohammadjavad Mehditabar Dalhousie University, Saurabhsingh Rajput Dalhousie University, Antonio Mastropaolo William and Mary, USA, Tushar Sharma Dalhousie University Pre-print File Attached | ||
10:00 5mTalk | Learning Model Mutations From Faults in Deep Learning Journal Ahead Workshop (JAWs) Zaheed Ahmed Institute of Computer Science, University of Göttingen, Lower Saxony, Germany, Philip Makedonski Institute of Computer Science, University of Göttingen, Lower Saxony, Germany, Jens Grabowski Media Attached | ||
10:05 5mTalk | Artificial or Just Artful? Do LLMs Bend the Rules in Programming? Journal Ahead Workshop (JAWs) Oussama Ben Sghaier Queen's University, Kévin Delcourt Université de Montréal, Houari Sahraoui DIRO, Université de Montréal | ||
10:10 5mTalk | Towards Automated User Story Quality Assessment with LLMs: An Empirical Study on Syntactic and Pragmatic QUS Criteria Journal Ahead Workshop (JAWs) Izabella Silva Federal University of Campina Grande - ISE/VIRTUS, Emanuel Dantas Filho Federal University of Campina Grande - ISE/VIRTUS, Ademar Sousa Neto VIRTUS/UFCG, Mirko Perkusich VIRTUS, Danyllo Albuquerque VIRTUS/UFCG, Kyller Costa Gorgônio Federal University of Campina Grande, Angelo Percusich Federal University of Campina Grande - ISE/VIRTUS | ||
10:15 5mTalk | MARS: Few-Shot Android Malware Detection with RAG-Enhanced LLMs Journal Ahead Workshop (JAWs) Guangquan Xu School of Cybersecurity, Tianjin University, Minhong Dong School of Cybersecurity, Tianjin University, Qi Guo Tianjin University, Hongpeng Bai School of Cybersecurity, Tianjin University, Yao Zhang Tianjin University, Ruitao Feng Southern Cross University, Wenying He Hebei University of Technology, Yude Bai Tianjin University, Ji Zhang University of Southern Queensland | ||
10:20 5mTalk | A Closer Look at the Malicious Pre-Trained Models on Hugging Face Journal Ahead Workshop (JAWs) Junwei Zhang Zhejiang University, Xing Hu Zhejiang University, Xin Xia Zhejiang University, David Lo Singapore Management University, Shanping Li Zhejiang University | ||