Pith. sign in

REVIEW 2 cited by

Prompt Learning for Multi-Label Code Smell Detection: A Promising Approach

Not yet reviewed by Pith; the record is open.

This paper has not been read by Pith yet. Machine review is queued; the pith claim, tier, and objections will appear here once it completes.

SPECIMEN: schema-true, not a live event

T0 review · schema-true

One-sentence machine reading of the paper's core claim.

pith:XXXXXXXX · record.json · timestamp

arxiv 2402.10398 v1 pith:VPM3RULQ submitted 2024-02-16 cs.SE

classification cs.SE
keywords codelearningmulti-labelpromptsmelltextitapproachapproacheslanguage
verification ladder T0 review T1 audit T2 compute T3 formal

Signed reviews

No signed human review yet.

0 comments
abstract

Code smells indicate the potential problems of software quality so that developers can identify refactoring opportunities by detecting code smells. State-of-the-art approaches leverage heuristics, machine learning, and deep learning to detect code smells. However, existing approaches have not fully explored the potential of large language models (LLMs). In this paper, we propose \textit{PromptSmell}, a novel approach based on prompt learning for detecting multi-label code smell. Firstly, code snippets are acquired by traversing abstract syntax trees. Combined code snippets with natural language prompts and mask tokens, \textit{PromptSmell} constructs the input of LLMs. Secondly, to detect multi-label code smell, we leverage a label combination approach by converting a multi-label problem into a multi-classification problem. A customized answer space is added to the word list of pre-trained language models, and the probability distribution of intermediate answers is obtained by predicting the words at the mask positions. Finally, the intermediate answers are mapped to the target class labels by a verbalizer as the final classification result. We evaluate the effectiveness of \textit{PromptSmell} by answering six research questions. The experimental results demonstrate that \textit{PromptSmell} obtains an improvement of 11.17\% in $precision_{w}$ and 7.4\% in $F1_{w}$ compared to existing approaches.

Discussion (0). Continue with ORCID to comment.

Forward citations

Cited by 2 Pith papers

Reviewed papers in the Pith corpus that reference this work. Sorted by Pith novelty score. Full citation record

  1. How Propense Are Large Language Models at Producing Code Smells? A Benchmarking Study

    cs.SE 2024-12 reject novelty 6.0 of 10

    A new benchmark scores LLMs' tendency to generate code smells by aggregating token-level probabilities over smell locations in existing code.

  2. Optimizing Token Consumption in LLMs: A Nano Surge Approach for Code Reasoning Efficiency

    cs.SE 2025-04 conditional novelty 3.0 of 10

    Refactoring smelly Java code and adding context, role, or token-limit prompts cut LLM chain-of-thought token use by roughly 15-50% in this study, but the 'no quality loss' claim rests only on shallow similarity metrics.

Pith tools