Lune

ICSE2023Top-tier venue

Explaining Software Bugs Leveraging Code Structures in Neural Machine Translation

Parvez Mahbub, Ohiduzzaman Shuvo, Mohammad Masudur Rahman

Abstract

Software bugs claim ≈ 50 % of development time and cost the global economy billions of dollars. Once a bug is reported, the assigned developer attempts to identify and understand the source code responsible for the bug and then corrects the code. Over the last five decades, there has been significant research on automatically finding or correcting software bugs. However, there has been little research on automatically explaining the bugs to the developers, which is essential but a highly challenging task. In this paper, we propose Bugsplainer, a transformer-based generative model, that generates natural language explanations for software bugs by learning from a large corpus of bug-fix commits. Bugsplainer can leverage structural information and buggy patterns from the source code to generate an explanation for a bug. Our evaluation using three performance metrics shows that Bugsplainer can generate understandable and good explanations according to Google's standard, and can outperform multiple baselines from the literature. We also conduct a developer study involving 20 participants where the explanations from Bugsplainer were found to be more accurate, more precise, more concise and more useful than the baselines.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

9 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Spotting Code Mutation for Predictive Mutation Testing cites CodeT5: Identifier-aware Unified Pre-trained Encoder-Decoder Models for Code Understanding and Generation
  • VulAdvisor: Natural Language Suggestion Generation for Software Vulnerability Repair cites CodeT5: Identifier-aware Unified Pre-trained Encoder-Decoder Models for Code Understanding and Generation
  • VulAdvisor: Natural Language Suggestion Generation for Software Vulnerability Repair cites Out of Sight, Out of Mind: Better Automatic Vulnerability Repair by Broadening Input Ranges and Sources
  • Out of Sight, Out of Mind: Better Automatic Vulnerability Repair by Broadening Input Ranges and Sources cites CodeT5: Identifier-aware Unified Pre-trained Encoder-Decoder Models for Code Understanding and Generation
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers9

  1. A Quantitative and Qualitative Evaluation of LLM-Based Explainable Fault LocalizationSungmin Kang, Gabin An, Shin YooFSE 2024 · 69 citations
  2. Out of Sight, Out of Mind: Better Automatic Vulnerability Repair by Broadening Input Ranges and SourcesXin Zhou, Kisub Kim, Bowen Xu, DongGyun Han et al.ICSE 2024 · 32 citations
  3. VulAdvisor: Natural Language Suggestion Generation for Software Vulnerability RepairJian Zhang, Chong Wang, Anran Li, Wenhan Wang et al.ASE 2024 · 7 citations
  4. Improved Detection and Diagnosis of Faults in Deep Neural Networks Using Hierarchical and Explainable ClassificationSigma Jahan, Mehil B. Shah, Parvez Mahbub, Mohammad Masudur RahmanICSE 2025 · 2 citations
  5. Spotting Code Mutation for Predictive Mutation TestingYifan Zhao, Yizhou Chen, Zeyu Sun, Qingyuan Liang et al.ASE 2024 · 2 citations

Builds on7

  1. CodeT5: Identifier-aware Unified Pre-trained Encoder-Decoder Models for Code Understanding and GenerationYue Wang, Weishi Wang, Shafiq R. Joty, Steven C. H. HoiEMNLP 2021 · 1,224 citations
  2. Retrieve and Refine: Exemplar-based Neural Comment GenerationBolin Wei, Yongmin Li, Ge Li, Xin Xia et al.ASE 2020 · 68 citations
  3. CommentFinder: a simpler, faster, more accurate code review comments recommendationYang Hong, Chakkrit Tantithamthavorn, Patanamon Thongtanunam, Aldeida AletiFSE 2022 · 57 citations
  4. PyExplainer: Explaining the Predictions of Just-In-Time Defect ModelsChanathip Pornprasit, Chakkrit Tantithamthavorn, Jirayus Jiarpakdee, Michael Fu et al.ASE 2021 · 52 citations
  5. A large-scale study of usability criteria addressed by static analysis toolsMarcus Nachtigall, Michael Schlichtig, Eric BoddenISSTA 2022 · 38 citations

Related papers

  1. Using Developer Discussions to Guide Fixing Bugs in SoftwareSheena Panthaplackel, Milos Gligoric, Junyi Jessy Li, Raymond J. MooneyEMNLP Findings 2022 · 4 citations
  2. Learning to Reduce False Positives in Analytic Bug DetectorsAnant Kharkar, Roshanak Zilouchian Moghaddam, Matthew Jin, Xiaoyu Liu et al.ICSE 2022 · 33 citations
  3. Fast Changeset-based Bug Localization with BERTAgnieszka Ciborowska, Kostadin DamevskiICSE 2022 · 53 citations
  4. A Comparative Study of Transformer-Based Neural Text Representation Techniques on Bug TriagingAtish Kumar Dipongkor, Kevin MoranASE 2023 · 9 citations
  5. Learning to Describe Solutions for Bug Reports Based on Developer DiscussionsSheena Panthaplackel, Junyi Jessy Li, Milos Gligoric, Raymond J. MooneyACL Findings 2022 · 6 citations
Dusk over the sea between two cliffs drawn in fine vertical lines