Automatic Library Migration Using Large Language Models: First Results
Despite being proposed only a few years ago, Large Language Models (LLMs) are being used daily by developers for code generation. However, their use for automating other Software Engineering activities is less clear. Thus, in this paper, we report the preliminary results of a study in which we are exploring the use of ChatGPT to support API migration tasks, an important problem that demands manual effort and attention from developers. Specifically, in the paper, we share our initial results involving the use of ChatGPT to migrate a client application to use a newer version of SQLAlchemy, an ORM (Object Relational Mapping) library widely used in Python. We evaluate the use of three types of prompts (Zero-Shot, One-Shot, and Chain Of Thoughts) and show that the best results are achieved by the One-Shot prompt, followed by the Chain Of Thoughts. Particularly, with the One-Shot prompt we were able to successfully migrate all columns of our target application and upgrade its code to use new functionalities enabled by SQLAlchemy’s latest version, such as Python’s asyncio and typing modules, while preserving the original code functionality.
Fri 25 OctDisplayed time zone: Brussels, Copenhagen, Madrid, Paris change
11:00 - 12:30 | Large language models in software engineering IESEM Technical Papers / ESEM Emerging Results, Vision and Reflection Papers Track at Telensenyament (B3 Building - 1st Floor) Chair(s): Phuong T. Nguyen University of L’Aquila | ||
11:00 20mFull-paper | Optimizing the Utilization of Large Language Models via Schedule Optimization: An Exploratory Study ESEM Technical Papers Yueyue Liu The University of Newcastle, Hongyu Zhang Chongqing University, Zhiqiang Li Shaanxi Normal University, Yuantian Miao The University of Newcastle | ||
11:20 20mFull-paper | A Comparative Study on Large Language Models for Log Parsing ESEM Technical Papers Merve Astekin Simula Research Laboratory, Max Hort Simula Research Laboratory, Leon Moonen Simula Research Laboratory and BI Norwegian Business School | ||
11:40 20mFull-paper | Are Large Language Models a Threat to Programming Platforms? An Exploratory Study ESEM Technical Papers Md Mustakim Billah University of Saskatchewan, Palash Ranjan Roy University of Saskatchewan, Zadia Codabux University of Saskatchewan, Banani Roy University of Saskatchewan Pre-print | ||
12:00 15mVision and Emerging Results | Automatic Library Migration Using Large Language Models: First Results ESEM Emerging Results, Vision and Reflection Papers Track Aylton Almeida UFMG, Laerte Xavier PUC Minas, Marco Tulio Valente Federal University of Minas Gerais, Brazil | ||
12:15 15mVision and Emerging Results | Evaluating Large Language Models in Exercises of UML Class Diagram Modeling ESEM Emerging Results, Vision and Reflection Papers Track Daniele De Bari Politecnico di Torino, Giacomo Garaccione Politecnico di Torino, Riccardo Coppola Politecnico di Torino, Marco Torchiano Politecnico di Torino, Luca Ardito Politecnico di Torino |