A Quantitative and Qualitative Evaluation of LLM-Based Explainable Fault Localization

Fuente: arXiv
Enregistré dans:
Détails bibliographiques
Auteurs principaux: Kang, Sungmin, An, Gabin, Yoo, Shin
Format: Preprint
Publié: 2023
Sujets:
Accès en ligne:
Tags: Ajouter un tag
Pas de tags, Soyez le premier à ajouter un tag!
_version_ 1866916308240564224
author Kang, Sungmin
An, Gabin
Yoo, Shin
author_facet Kang, Sungmin
An, Gabin
Yoo, Shin
contents Fault Localization (FL), in which a developer seeks to identify which part of the code is malfunctioning and needs to be fixed, is a recurring challenge in debugging. To reduce developer burden, many automated FL techniques have been proposed. However, prior work has noted that existing techniques fail to provide rationales for the suggested locations, hindering developer adoption of these techniques. With this in mind, we propose AutoFL, a Large Language Model (LLM)-based FL technique that generates an explanation of the bug along with a suggested fault location. AutoFL prompts an LLM to use function calls to navigate a repository, so that it can effectively localize faults over a large software repository and overcome the limit of the LLM context length. Extensive experiments on 798 real-world bugs in Java and Python reveal AutoFL improves method-level acc@1 by up to 233.3% over baselines. Furthermore, developers were interviewed on their impression of AutoFL-generated explanations, showing that developers generally liked the natural language explanations of AutoFL, and that they preferred reading a few, high-quality explanations instead of many.
format Preprint
id arxiv_https___arxiv_org_abs_2308_05487
institution arXiv
publishDate 2023
record_format arxiv
spellingShingle A Quantitative and Qualitative Evaluation of LLM-Based Explainable Fault Localization
Kang, Sungmin
An, Gabin
Yoo, Shin
Software Engineering
Fault Localization (FL), in which a developer seeks to identify which part of the code is malfunctioning and needs to be fixed, is a recurring challenge in debugging. To reduce developer burden, many automated FL techniques have been proposed. However, prior work has noted that existing techniques fail to provide rationales for the suggested locations, hindering developer adoption of these techniques. With this in mind, we propose AutoFL, a Large Language Model (LLM)-based FL technique that generates an explanation of the bug along with a suggested fault location. AutoFL prompts an LLM to use function calls to navigate a repository, so that it can effectively localize faults over a large software repository and overcome the limit of the LLM context length. Extensive experiments on 798 real-world bugs in Java and Python reveal AutoFL improves method-level acc@1 by up to 233.3% over baselines. Furthermore, developers were interviewed on their impression of AutoFL-generated explanations, showing that developers generally liked the natural language explanations of AutoFL, and that they preferred reading a few, high-quality explanations instead of many.
title A Quantitative and Qualitative Evaluation of LLM-Based Explainable Fault Localization
topic Software Engineering
url https://arxiv.org/abs/2308.05487