We gratefully acknowledge support from
the Simons Foundation and member institutions.
Full-text links:

Download:

Current browse context:

cs.LG

Change to browse by:

References & Citations

DBLP - CS Bibliography

Bookmark

(what is this?)
CiteULike logo BibSonomy logo Mendeley logo del.icio.us logo Digg logo Reddit logo

Computer Science > Machine Learning

Title: Automatic Code Summarization via Multi-dimensional Semantic Fusing in GNN

Abstract: Source code summarization aims to generate natural language summaries from structured code snippets for better understanding code functionalities. Recent works attempt to encode programs into graphs for learning program semantics and yield promising results. However, these methods only use simple code representations(e.g., AST), which limits the capability of learning the rich semantics for complex programs. Furthermore, these models primarily rely on graph-based message passing, which only captures local neighborhood relations. To this end, in this paper, we combine diverse representations of the source code (i.e., AST, CFG and PDG)into a joint code property graph. To better learn semantics from the joint graph, we propose a retrieval-augmented mechanism to augment source code semantics with external knowledge. Furthermore, we propose a novel attention-based dynamic graph to capture global interactions among nodes in the static graph and followed a hybrid message passing GNN to incorporate both static and dynamic graph. To evaluate our proposed approach, we release a new challenging benchmark, crawledfrom200+diversified large-scale open-source C/C++projects. Our method achieves the state-of-the-art performance, improving existing methods by1.66,2.38and2.22in terms of BLEU-4, ROUGE-L and METEOR metrics.
Subjects: Machine Learning (cs.LG); Artificial Intelligence (cs.AI)
Cite as: arXiv:2006.05405 [cs.LG]
  (or arXiv:2006.05405v1 [cs.LG] for this version)

Submission history

From: Shangqing Liu [view email]
[v1] Tue, 9 Jun 2020 17:09:29 GMT (424kb,D)
[v2] Sun, 4 Oct 2020 08:06:49 GMT (121kb,D)
[v3] Mon, 23 Nov 2020 11:38:37 GMT (520kb,D)
[v4] Thu, 26 Nov 2020 05:33:27 GMT (519kb,D)
[v5] Thu, 13 May 2021 03:41:22 GMT (571kb,D)

Link back to: arXiv, form interface, contact.