Return
Function Call Graph Context Encoding for Neural Source Code Summarization
DOI:10.1109/TSE.2023.3279774.png)
Abstract
En 中文
Source code summarization is the task of writing natural language descriptions of source code. The primary use of these descriptions is in documentation for programmers. Automatic generation of these descriptions is a high value research target due to the time cost to programmers of writing these descriptions themselves. In recent years, a confluence of software engineering and artificial intelligence research has made inroads into automatic source code summarization through applications of neural models of that source code. However, an Achilles' heel to a vast majority of approaches is that they tend to rely solely on the context provided by the source code being summarized. But empirical studies in program comprehension are quite clear that the information needed to describe code much more often resides in the context in the form of Function Call Graph surrounding that code. In this paper, we present a technique for encoding this call graph context for neural models of code summarization. We implement our approach as a supplement to existing approaches, and show statistically significant improvement over existing approaches. In a human study with 20 programmers, we show that programmers perceive generated summaries to generally be as accurate, readable, and concise as human-written summaries.
Keywords:
Codes
Source coding
Context modeling
Decoding
Algorithms
Software engineering
Machine translation
Automatic documentation generation
context-aware models
neural networks
source code summarization
Journal
IF:
5.6
Papers:
2.8K
Citations:
1.1W

