A Comprehensive Evaluation of Parameter-Efficient Fine-Tuning on Code Smell Detection

Fuente: arXiv
Saved in:
Bibliographic Details
Main Authors: Zhang, Beiqi, Liang, Peng, Zhou, Xin, Zhou, Xiyu, Lo, David, Feng, Qiong, Li, Zengyang, Li, Lin
Format: Preprint
Published: 2024
Subjects:
Online Access:
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866910077153181696
author Zhang, Beiqi
Liang, Peng
Zhou, Xin
Zhou, Xiyu
Lo, David
Feng, Qiong
Li, Zengyang
Li, Lin
author_facet Zhang, Beiqi
Liang, Peng
Zhou, Xin
Zhou, Xiyu
Lo, David
Feng, Qiong
Li, Zengyang
Li, Lin
contents Automated code smell detection faces persistent challenges due to the subjectivity of heuristic rules and the limited performance of traditional ML/DL models. While Large Language Models (LLMs) offer a promising alternative, their adoption is impeded by high fine-tuning costs and a lack of "LM-ready" benchmarks. To bridge these gaps, we present a study with two synergistic contributions. First, we constructed a high-quality benchmark for Complex Conditional, Complex Method, Feature Envy, and Data Class, validated through a rigorous two-stage manual review. Second, leveraging this benchmark, we systematically evaluated four Parameter-Efficient Fine-Tuning (PEFT) methods across nine LMs of varying parameter sizes. Their performance is compared against a comprehensive suite of baselines, including heuristics-based detectors, Deep Learning (DL)-based approaches, and state-of-the-art general-purpose LLMs under multiple In-Context Learning (ICL) settings. Our results demonstrate that PEFT methods achieve effectiveness comparable to or surpassing full fine-tuning while substantially reducing peak GPU memory usage for code smell detection. Furthermore, PEFT-tuned LMs consistently outperform all baselines, yielding MCC improvements ranging from 0.33% to 13.69%, with particularly notable gains for specific smell categories. These findings highlight PEFT techniques as effective and scalable solutions for advancing code smell detection.
format Preprint
id arxiv_https___arxiv_org_abs_2412_13801
institution arXiv
publishDate 2024
record_format arxiv
spellingShingle A Comprehensive Evaluation of Parameter-Efficient Fine-Tuning on Code Smell Detection
Zhang, Beiqi
Liang, Peng
Zhou, Xin
Zhou, Xiyu
Lo, David
Feng, Qiong
Li, Zengyang
Li, Lin
Software Engineering
Automated code smell detection faces persistent challenges due to the subjectivity of heuristic rules and the limited performance of traditional ML/DL models. While Large Language Models (LLMs) offer a promising alternative, their adoption is impeded by high fine-tuning costs and a lack of "LM-ready" benchmarks. To bridge these gaps, we present a study with two synergistic contributions. First, we constructed a high-quality benchmark for Complex Conditional, Complex Method, Feature Envy, and Data Class, validated through a rigorous two-stage manual review. Second, leveraging this benchmark, we systematically evaluated four Parameter-Efficient Fine-Tuning (PEFT) methods across nine LMs of varying parameter sizes. Their performance is compared against a comprehensive suite of baselines, including heuristics-based detectors, Deep Learning (DL)-based approaches, and state-of-the-art general-purpose LLMs under multiple In-Context Learning (ICL) settings. Our results demonstrate that PEFT methods achieve effectiveness comparable to or surpassing full fine-tuning while substantially reducing peak GPU memory usage for code smell detection. Furthermore, PEFT-tuned LMs consistently outperform all baselines, yielding MCC improvements ranging from 0.33% to 13.69%, with particularly notable gains for specific smell categories. These findings highlight PEFT techniques as effective and scalable solutions for advancing code smell detection.
title A Comprehensive Evaluation of Parameter-Efficient Fine-Tuning on Code Smell Detection
topic Software Engineering
url https://arxiv.org/abs/2412.13801