A Survey of Automatic Generation of Source Code Comments: Algorithms and Techniques

07/25/2019
by   Xiaotao Song, et al.
0

As an integral part of source code files, code comments help improve program readability and comprehension. However, developers sometimes do not comment on their program code adequately due to the incurred extra efforts, lack of relevant knowledge, unawareness of the importance of code commenting or some other factors. As a result, code comments can be inadequate, absent or even mismatched with source code, which affects the understanding, reusing and the maintenance of software. To solve these problems of code comments, researchers have been concerned with generating code comments automatically. In this work, we aim at conducting a survey of automatic code commenting researches. First, we generally analyze the challenges and research framework of automatic generation of program comments. Second, we present the classification of representative algorithms, the design principles, strengths and weaknesses of each category of algorithms. Meanwhile, we also provide an overview of the quality assessment of the generated comments. Finally, we summarize some future directions for advancing the techniques of automatic generation of code comments and the quality assessment of comments.

READ FULL TEXT
research
10/15/2018

Generating Comments From Source Code with CCGs

Good comments help developers understand software faster and provide bet...
research
07/06/2018

Recommending Insightful Comments for Source Code using Crowdsourced Knowledge

Recently, automatic code comment generation is proposed to facilitate pr...
research
09/10/2019

Automatic Code Summarization: A Systematic Literature Review

Background: During software maintenance and development, the comprehensi...
research
03/24/2021

Learning to Generate Code Comments from Class Hierarchies

Descriptive code comments are essential for supporting code comprehensio...
research
07/22/2021

An Empirical Study on Code Comment Completion

Code comments play a prominent role in program comprehension activities....
research
09/16/2022

A Decade of Code Comment Quality Assessment: A Systematic Literature Review

Code comments are important artifacts in software systems and play a par...
research
03/19/2021

API2Com: On the Improvement of Automatically Generated Code Comments Using API Documentations

Code comments can help in program comprehension and are considered as im...

Please sign up or login with your details

Forgot password? Click here to reset