Recommending insightful comments for source code using crowdsourced knowledge
Citations Over TimeTop 10% of 2015 papers
Abstract
Recently, automatic code comment generation is proposed to facilitate program comprehension. Existing code comment generation techniques focus on describing the functionality of the source code. However, there are other aspects such as insights about quality or issues of the code, which are overlooked by earlier approaches. In this paper, we describe a mining approach that recommends insightful comments about the quality, deficiencies or scopes for further improvement of the source code. First, we conduct an exploratory study that motivates crowdsourced knowledge from Stack Overflow discussions as a potential resource for source code comment recommendation. Second, based on the findings from the exploratory study, we propose a heuristic-based technique for mining insightful comments from Stack Overflow Q & A site for source code comment recommendation. Experiments with 292 Stack Overflow code segments and 5,039 discussion comments show that our approach has a promising recall of 85.42%. We also conducted a complementary user study which confirms the accuracy and usefulness of the recommended comments.
Related Papers
- → CloCom: Mining existing source code for automatic comment generation(2015)166 cited
- → Recognizing lines of code violating company-specific coding guidelines using machine learning(2019)21 cited
- → Analysis of the Tools for Static Code Analysis(2021)16 cited
- → A Survey on Research of Code Comment(2019)21 cited
- → Chapter 8 Recognizing Lines of Code Violating Company-Specific Coding Guidelines Using Machine Learning(2019)3 cited