Revisiting Code Smell Severity Prioritization using learning to rank techniques

被引:3
|
作者
Liu, Lei [1 ]
Lin, Guancheng [2 ]
Zhu, Lin [3 ]
Yang, Zhen [4 ]
Song, Peilin [1 ]
Wang, Xin [5 ]
Hu, Wenhua [6 ]
机构
[1] Xi An Jiao Tong Univ, Fac Elect & Informat Engn, Minist Educ, Key Lab Phys Elect & Devices, Xian 710049, Shaanxi, Peoples R China
[2] Wuhan Univ, Sch Cyber Sci & Engn, Wuhan 430072, Hubei, Peoples R China
[3] Wuhan Qingchuan Univ, Sch Comp, Wuhan 430204, Hubei, Peoples R China
[4] Shandong Univ, Sch Comp Sci & Technol, Qingdao 266237, Shandong, Peoples R China
[5] Wuhan Univ, Sch Comp Sci, Wuhan 430072, Hubei, Peoples R China
[6] Wuhan Univ Technol, Sch Comp Sci & Artificial Intelligence, Wuhan 430070, Hubei, Peoples R China
基金
中国博士后科学基金; 中国国家自然科学基金;
关键词
Code smell; Severity prioritization; Learning to rank; Empirical study; COMPANY DEFECT PREDICTION;
D O I
10.1016/j.eswa.2024.123483
中图分类号
TP18 [人工智能理论];
学科分类号
081104 ; 0812 ; 0835 ; 1405 ;
摘要
Code Smell Severity Prioritization (CSSP) is crucial in helping software developers minimize software maintenance costs and enhance software quality, particularly when faced with limited refactoring resources. Traditional code smell prioritization methods rely heavily on manual and semi -automatic approaches based on developer experience, often demanding considerable time and effort from experienced experts. Leveraging automated machine learning techniques can effectively overcome these limitations. However, most existing machine learning -based CSSP works have only considered limited pointwise Learning To Rank (LTR) algorithms and have used inappropriate metrics (e.g., Accuracy, Spearman, and MAE) to assess the performance of models. To address these limitations, we make a comprehensive comparison of 41 pointwise, 4 pairwise, and 4 listwise LTR algorithms for CSSP on four code smell severity datasets. Furthermore, we propose the adoption of Severity@20% and Cumulative Lift Chart (CLC) as the primary evaluation metrics to assess CSSP models more effectively. The results show that: (1) The ordinal Bagging (O -Bagging) algorithm demonstrates the highest performance for CSSP, achieving superior results in Severity@20% and CLC. (2) The ordinal classification method can help the top -performing base classification algorithms Bagging and XGBoost achieve better performance for CSSP tasks. (3) A higher (lower) Accuracy, higher (lower) Spearman, and lower (higher) MAE do not reliably indicate better (worse) performance for CSSP. This further underscores that Accuracy, Spearman, and MAE are unsuitable metrics for evaluating CSSP models' effectiveness. To summarize, our study suggest that developers employ the O -Bagging algorithm for CSSP, with Severity@20% and CLC serving as the primary evaluation metrics.
引用
收藏
页数:19
相关论文
共 50 条
  • [1] Revisiting "code smell severity classification using machine learning techniques"
    Hu, Wenhua
    Liu, Lei
    Yang, Peixin
    Zou, Kuan
    Li, Jiajun
    Lin, Guancheng
    Xiang, Jianwen
    2023 IEEE 47TH ANNUAL COMPUTERS, SOFTWARE, AND APPLICATIONS CONFERENCE, COMPSAC, 2023, : 840 - 849
  • [2] Code smell severity classification using machine learning techniques
    Fontana, Francesca Arcelli
    Zanoni, Marco
    KNOWLEDGE-BASED SYSTEMS, 2017, 128 : 43 - 58
  • [3] Interpretable Deep Learning for Efficient Code Smell Prioritization in Software Development
    Rashid, Maaeda M.
    Osman, Mohd Hafeez
    Sharif, Khaironi Yatim
    Zulzalil, Hazura
    IEEE ACCESS, 2025, 13 : 45290 - 45311
  • [4] DeepCSS: severity classification for code smell based on deep learning
    Zhang, Yang
    Zhang, Chunhui
    Zheng, Kun
    Meredith, Grant
    EMPIRICAL SOFTWARE ENGINEERING, 2025, 30 (03)
  • [5] Developer-Driven Code Smell Prioritization
    Pecorelli, Fabiano
    Palomba, Fabio
    Khomh, Foutse
    De Lucia, Andrea
    2020 IEEE/ACM 17TH INTERNATIONAL CONFERENCE ON MINING SOFTWARE REPOSITORIES, MSR, 2020, : 220 - 231
  • [6] Towards a Prioritization of Code Debt: A Code Smell Intensity Index
    Fontana, Francesca Arcelli
    Ferme, Vincenzo
    Zanoni, Marco
    Roveda, Riccardo
    2015 IEEE 7TH INTERNATIONAL WORKSHOP ON MANAGING TECHNICAL DEBT (MTD) PROCEEDINGS, 2015, : 16 - 24
  • [7] Comparing and experimenting machine learning techniques for code smell detection
    Francesca Arcelli Fontana
    Mika V. Mäntylä
    Marco Zanoni
    Alessandro Marino
    Empirical Software Engineering, 2016, 21 : 1143 - 1191
  • [8] IDENTIFICATION OF CODE SMELL USING MACHINE LEARNING
    Jesudoss, A.
    Maneesha, S.
    durga, T. Lakshmi naga
    PROCEEDINGS OF THE 2019 INTERNATIONAL CONFERENCE ON INTELLIGENT COMPUTING AND CONTROL SYSTEMS (ICCS), 2019, : 54 - 58
  • [9] Comparing and experimenting machine learning techniques for code smell detection
    Fontana, Francesca Arcelli
    Mantyla, Mika V.
    Zanoni, Marco
    Marino, Alessandro
    EMPIRICAL SOFTWARE ENGINEERING, 2016, 21 (03) : 1143 - 1191
  • [10] A review of code smell mining techniques
    Rasool, Ghulam
    Arshad, Zeeshan
    JOURNAL OF SOFTWARE-EVOLUTION AND PROCESS, 2015, 27 (11) : 867 - 895