SmellCC, a Visual Studio Code extension that augments SonarQube with an LLM-based pipeline to automatically detect and refactor Python code smells, provides in-place, one-click remediation for the top-10 most frequent smells, effectively preventing the accumulation of technical debt during development.
Abstract
Code smells significantly threaten software maintainability by accumulating technical debt, yet developers often lack the resources to manually address these flaws under tight release schedules. While static analysis tools like SonarQube provide precise detection, they function largely as passive alert systems, leaving the burden of refactoring on developers. To bridge this gap, we present a novel cleaning tool, namely SmellCC, a Visual Studio Code extension that augments SonarQube with an LLM-based pipeline to automatically detect and refactor Python code smells. By employing Chain-of-Thought (CoT) and few-shot learning, SmellCC provides in-place, one-click remediation for the top-10 most frequent smells, effectively preventing the accumulation of technical debt during development. Our quantitative evaluation demonstrates that our SmellCC is promising in helping developers effectively eliminate code smells (96.8\% cleaning rate) with high accuracy (i.e., 91.3\%), ensuring that the refactored code remains syntactically correct and behavior-preserving, thereby significantly improving long-term software maintainability.
This study investigates the application of UniXcoder, a pre-trained transformer model for source code, to classify Java source code methods across multiple projects as smell or clean, with a particular focus on the Switch Statements smell, and confirms that pre-trained transformer models, particularly UniXcoder, are ca...
Hanson Prihantoro Putro, Umi Laili Yuhana, E. M. Yuniarno et al.· IEEE Access· 0 citations
This paper focuses on four common smells and considers five prompts of diverse complexity, asking the model for detecting and removing the identified code smells, and suggests that general-purpose LLMs cannot be reliably used for that.
Giorgia Paisi, Francesca Arcelli Fontana, Bartosz Walter· WiPiEC Journal - Works in Pr...· 0 citations
The study highlights the potential of intelligent, data-driven approaches to enhance software quality and support continuous code improvement by leveraging code metrics, syntactic and semantic features, and historical refactoring data.
Emily Johnson· International Journal of Mac...· 0 citations
Continuous Integration and Continuous Delivery (CI/CD) pipelines accelerate software evolution but complicate the timely assessment of structural degradation. While code smells effectively indicate maintainability risks, their detection remains largely confined to isolated static analysis rather than being actively int...
J. Domingues, D. Duarte, António Sousa et al.· International Conference on...· 0 citations
Recently, Developers have been relying on AI tools to support them in their daily work by generating code. While the use of large language model-based AI tools has improved productivity, the quality of the generated code wasn't always optimal. In a lot of cases, the code includes design issues known as code smells, whi...
Y. Younes, Yousef Elsheikh· IEEE Jordan Conference on Ap...· 0 citations
A high-quality benchmark of 1,000 code refinement instances from 328 Python, Java, and JavaScript repositories that focused on one of the most challenging code refinement scenarios that strictly requires repository-level knowledge reasoning, and a straightforward method, RepoRefiner, which retrieves repository-level co...
Ke Wang, Peng Lan, Jia-Kun Liu et al.· ACM Transactions on Software...· 1 citation
We use cookies to run the site and, with your consent, for analytics and to show ads.
See our Cookie Policy.