paper-with-me

Papers

Improving Code Summarization with Block-wise Abstract Syntax Tree Splitting

2021-03-14 · Chen Lin, Zhichao Ouyang, Junqing Zhuang, Jianqiang Chen, Hui Li, Rongxin Wu

Automatic code summarization frees software developers from the heavy burden of manual commenting and benefits software development and maintenance. Abstract Syntax Tree (AST), which depicts the source code's syntactic structure, has been incorporated to guide the generation of code summaries. However, existing AST based methods suffer from the difficulty of training and generate inadequate code summaries. In this paper, we present the Block-wise Abstract Syntax Tree Splitting method (BASTS for short), which fully utilizes the rich tree-form syntax structure in ASTs, for improving code summarization. BASTS splits the code of a method based on the blocks in the dominator tree of the Control Flow Graph, and generates a split AST for each code split. Each split AST is then modeled by a Tree-LSTM using a pre-training strategy to capture local non-linear syntax encoding. The learned syntax encoding is combined with code encoding, and fed into Transformer to generate high-quality code summaries. Comprehensive experiments on benchmarks have demonstrated that BASTS significantly outperforms state-of-the-art approaches in terms of various evaluation metrics. To facilitate reproducibility, our implementation is available at https://github.com/XMUDM/BASTS.

📄 PDF Abstract BibTeX arXiv:2103.07845

Code (1)

XMUDM/BASTS 공식 구현 pytorch

Tasks

Code SummarizationSource Code Summarization

Methods 이 논문이 사용한 방법론

Linear Layer A Linear Layer is a projection $\mathbf{XW + b}$.
Absolute Position Encodings Absolute Position Encodings are a type of position embeddings for [Transformer-based models] where positional encodings are…
Position-Wise Feed-Forward Layer 설명 없음
Layer Normalization Unlike batch normalization, Layer Normalization directly estimates the normalization statistics from the summed inputs…
Adam 설명 없음
BPE Byte Pair Encoding, or BPE, is a subword segmentation algorithm that encodes rare and unknown words as sequences of subword units. The intuition is that various word…
Attention 설명 없음
Label Smoothing Label Smoothing is a regularization technique that introduces noise for the labels. This accounts for the fact that datasets may have mistakes in them, so maximizing the…

Similar Papers 제목 키워드 기반

Retrieval-based Layer-wise Adaptive Transformer for Source Code Summarization

2021-11-16 · ACL ARR November 2021 11 · Anonymous

We propose a model that learns both the sequential and the structural features of code for source code summarization. We adopt the Abstract Syntax Tree (AST) and graph convolution to model the structural information and …

Code SummarizationRetrievalSource Code Summarization

AST-Transformer: Encoding Abstract Syntax Trees Efficiently for Code Summarization

2021-12-02 · Ze Tang, Chuanyi Li, Jidong Ge, Xiaoyu Shen 외

Code summarization aims to generate brief natural language descriptions for source code. As source code is highly structured and follows strict programming language grammars, its Abstract Syntax Tree (AST) is often lever…

Code Summarization

Automatic Summarization for Creative Writing: BART based Pipeline Method for Generating Summary of Movie Scripts

2022-10-01 · COLING (CreativeSumm) 2022 10 · Aditya Upadhyay, Nidhir Bhavsar, Aakash Bhatnagar, Muskaan Singh 외

This paper documents our approach for the Creative-Summ 2022 shared task for Automatic Summarization of Creative Writing. For this purpose, we develop an automatic summarization pipeline where we leverage a denoising aut…

Denoising

Modeling Hierarchical Syntax Structure with Triplet Position for Source Code Summarization

2021-11-16 · ACL ARR November 2021 11 · Anonymous

Automatic code summarization, which aims to describe the source code in natural language, has become an essential task in software maintenance. Our fellow researchers have attempted to achieve such a purpose through vari…

Code SummarizationGraph Neural NetworkPositionSource Code Summarization+1

Modeling Hierarchical Syntax Structure with Triplet Position for Source Code Summarization

2022-05-01 · ACL 2022 5 · Juncai Guo, Jin Liu, Yao Wan, Li Li 외

Automatic code summarization, which aims to describe the source code in natural language, has become an essential task in software maintenance. Our fellow researchers have attempted to achieve such a purpose through vari…

Code SummarizationGraph Neural NetworkPositionSource Code Summarization+1