Learning to Describe Solutions for Bug Reports Based on Developer Discussions

Sheena Panthaplackel, Junyi Jessy Li, Milos Gligoric, Raymond J. Mooney

Abstract

This paper introduces a novel NLP task: automatically generating concise, natural language descriptions of bug solutions by analyzing developer discussions on GitHub. By leveraging pre-trained models like PLBART and a novel "noisy supervision" dataset, the authors demonstrate that AI can effectively synthesize complex, bimodal (text + code) dialogues into actionable implementation summaries. Our results show that specialized pre-training and careful data filtering are key to handling the inherent noise in developer communications.

Introduction: The Challenge of Developer Discussions

When a software bug is reported, developers often engage in lengthy, technical discussions to find a fix. While the eventual solution is usually formulated within these threads, it is often buried under mountains of "noise"—logs, stack traces, and tangential debates. For a developer joining the effort late or trying to implement the fix, wading through these archives is a major bottleneck.

Existing tools focus on either summarizing the entire bug report (holistic) or generating commit messages after the code is already written (post-hoc). This research addresses the gap in real-time assistance: synthesizing a concise description of the solution as it emerges in the discussion to help developers implement it faster.

Example of a developer discussion and the generated solution description.

Methodology

The researchers treat this as an abstractive summarization problem over long, bimodal dialogue. Their approach involves several key components:

  1. Noisy Supervision: Since there are no "gold standard" solution descriptions for millions of GitHub issues, the authors used the titles of linked Pull Requests (PRs) and commit messages as proxies for the solution description.
  2. Filtering for Quality: To handle the inherent noise of GitHub data, they applied filters to remove generic descriptions (e.g., "fix issue"), uninformative descriptions that just restate the problem, and context-less discussions where the solution was likely discussed offline.
  3. Model Architectures: They benchmarked several models, including standard Transformer Encoder-Decoders with pointer networks and PLBART, a model pre-trained on massive amounts of both Java code and technical text from StackOverflow.
  4. Real-Time Triggering: They designed a classifier to monitor an ongoing discussion and predict the exact moment ($t_g$) when enough context has emerged to generate a reliable solution description.

Dataset and Experimental Setup

The authors introduced a new dataset mined from the top 1,000 Java projects on GitHub, consisting of a Full Dataset of 12,328 bug-related issues and a Filtered Subset of 5,856 "cleaner" examples. Data was split chronologically (2011–2020) to ensure the models weren't "predicting the past" using future data, mimicking a real-world deployment.

Key Results and Insights

The task is highly abstractive; reference descriptions contain a high percentage of "novel" words not found in the discussion (over 90% for 4-grams). This necessitates true synthesis rather than simple extraction.

Performance comparison of different models on automated metrics across Full and Filtered datasets.

As shown in the results, PLBART outperformed all baselines, achieving 16.6 BLEU and 28.3 ROUGE-L on the full test set. Its success is attributed to its bimodal pre-training, which allows it to navigate both natural language and code snippets effectively. Furthermore, fine-tuning on the smaller, filtered "clean" subset led to better human-judged performance than training on the larger, noisier full dataset. In a study with 8 experienced Java developers, the fine-tuned PLBART model was chosen as the most informative 33.1% of the time—nearly triple the performance of the next best model.

Limitations and Future Work

Despite the strong performance, several challenges remain. PLBART's 1024-token limit can cause it to lose the original problem statement in very long discussions. Additionally, the model occasionally "hallucinates" or incorrectly stitches together code tokens in complex scenarios. Future work aims to move toward a full dialogue agent that doesn't just describe solutions but actively participates in the bug-fixing process, potentially utilizing external knowledge of the repository's file structure.

Summary updated

BibTeX
@inproceedings{panthaplackel2022learning,
  author = {Sheena Panthaplackel and Junyi Jessy Li and Milos Gligoric and Raymond J. Mooney},
  title = {{Learning to Describe Solutions for Bug Reports Based on Developer Discussions}},
  booktitle = {Annual Meeting of the Association for Computational Linguistics},
  year = {2022},
  url = {https://openreview.net/forum?id=_lEzjfkNfe3},
}
Figure