Transformer-Based Multi-Label Classification for Code Smell Detection in Software Engineering
Detecting code smell in software engineering is a key task, in which developers can find suboptimal code which may cause various problems such as trouble in maintenance of the code in the future. This paper examines the use of pre-trained transformer models, RoBERTa, TinyBERT, DistillBERT, ALBERT & DistillRoberta to perform accurate multi label classification of code smells in a class level dataset. In this paper, a modern approach is presented to preprocess class-level code smell data offered in CSV format by applying standard techniques, such as feature normalization and tokenization, to make the dataset amenable to the transformer-based models. The processed data is then fine tuned to leverage the ability of these transformers to capture contextual dependencies in the code. The performance of the model is evaluated using the classification report, loss curve & accuracy curve which shows their effectiveness for multi-label classification tasks. The best accuracy was found in ALBERT, RoBERTa & DistilRoBERTa which is 95%. The use of transformers is a new way for code smell detection and presents a promising direction for automated software quality analysis.
Authors
- Tanvir Azhar (ORCID: https://orcid.org/0009-0004-4248-2172)
- Muhaimin Bin Habib
- Aklima Tul Jannat
Institutions
- East Delta University (BD)
Publication Details
- Published
- 2025-05-23
- DOI
- https://doi.org/10.1109/incet64471.2025.11140264
- Primary Topic
- Software Engineering Research
- Type
- article
- Field-Weighted Citation Impact
- 0.00