Code summarization (CS) is becoming a promising area in recent language understanding, which aims to generate sensible human language automatically for programming language in the format of source code, serving in the most convenience of programmer developing. It is well known that programming languages are highly structured. Thus previous works attempt to apply structure-based traversal (SBT) or non-sequential models like Tree-LSTM and graph neural network (GNN) to learn structural program semantics. However, it is surprising that incorporating SBT into advanced encoder like Transformer instead of LSTM has been shown no performance gain, which lets GNN become the only rest means modeling such necessary structural clue in source code. To release such inconvenience, we propose structure-induced Transformer, which encodes sequential code inputs with multi-view structural clues in terms of a newly-proposed structure-induced self-attention mechanism. Extensive experiments show that our proposed structure-induced Transformer helps achieve new state-of-the-art results on benchmarks.


翻译:代码总和(CS)正在成为最近语言理解的一个有希望的领域,目的是在源代码格式下自动生成明智的人类语言,用于编程语言,在最方便的程序开发中发挥作用。众所周知,编程语言结构严密。因此,以前的工作试图应用结构基(SBT)或非序列模型,如树-LSTM和图形神经网络(GNN)来学习结构程序语义学。然而,令人惊讶的是,将SBT纳入高级编码器,如变换器而不是LSTM,却没有表现出业绩收益,让GNN成为唯一在源代码中模拟这种必要结构线索的手段。为了释放这种不便,我们提议由结构驱动的变换器,用新的结构驱动自控机制的多视角结构线索编码顺序代码输入。广泛的实验表明,我们拟议的结构驱动变换器有助于在基准上取得新的状态结果。

0
下载
关闭预览

相关内容

专知会员服务
43+阅读 · 2021年5月26日
最新《Transformers模型》教程,64页ppt
专知会员服务
298+阅读 · 2020年11月26日
Transformer文本分类代码
专知会员服务
116+阅读 · 2020年2月3日
【论文】结构GANs,Structured GANs,
专知会员服务
14+阅读 · 2020年1月16日
Stabilizing Transformers for Reinforcement Learning
专知会员服务
57+阅读 · 2019年10月17日
【论文笔记】通俗理解少样本文本分类 (Few-Shot Text Classification) (1)
深度学习自然语言处理
7+阅读 · 2020年4月8日
Hierarchically Structured Meta-learning
CreateAMind
24+阅读 · 2019年5月22日
强化学习的Unsupervised Meta-Learning
CreateAMind
17+阅读 · 2019年1月7日
Unsupervised Learning via Meta-Learning
CreateAMind
41+阅读 · 2019年1月3日
A Technical Overview of AI & ML in 2018 & Trends for 2019
待字闺中
16+阅读 · 2018年12月24日
disentangled-representation-papers
CreateAMind
26+阅读 · 2018年9月12日
Hierarchical Disentangled Representations
CreateAMind
4+阅读 · 2018年4月15日
gan生成图像at 1024² 的 代码 论文
CreateAMind
4+阅读 · 2017年10月31日
Auto-Encoding GAN
CreateAMind
7+阅读 · 2017年8月4日
Heterogeneous Graph Transformer
Arxiv
27+阅读 · 2020年3月3日
Arxiv
13+阅读 · 2019年11月14日
Arxiv
5+阅读 · 2019年8月22日
Star-Transformer
Arxiv
5+阅读 · 2019年2月28日
Arxiv
4+阅读 · 2019年1月1日
VIP会员
相关VIP内容
专知会员服务
43+阅读 · 2021年5月26日
最新《Transformers模型》教程,64页ppt
专知会员服务
298+阅读 · 2020年11月26日
Transformer文本分类代码
专知会员服务
116+阅读 · 2020年2月3日
【论文】结构GANs,Structured GANs,
专知会员服务
14+阅读 · 2020年1月16日
Stabilizing Transformers for Reinforcement Learning
专知会员服务
57+阅读 · 2019年10月17日
相关资讯
【论文笔记】通俗理解少样本文本分类 (Few-Shot Text Classification) (1)
深度学习自然语言处理
7+阅读 · 2020年4月8日
Hierarchically Structured Meta-learning
CreateAMind
24+阅读 · 2019年5月22日
强化学习的Unsupervised Meta-Learning
CreateAMind
17+阅读 · 2019年1月7日
Unsupervised Learning via Meta-Learning
CreateAMind
41+阅读 · 2019年1月3日
A Technical Overview of AI & ML in 2018 & Trends for 2019
待字闺中
16+阅读 · 2018年12月24日
disentangled-representation-papers
CreateAMind
26+阅读 · 2018年9月12日
Hierarchical Disentangled Representations
CreateAMind
4+阅读 · 2018年4月15日
gan生成图像at 1024² 的 代码 论文
CreateAMind
4+阅读 · 2017年10月31日
Auto-Encoding GAN
CreateAMind
7+阅读 · 2017年8月4日
相关论文
Heterogeneous Graph Transformer
Arxiv
27+阅读 · 2020年3月3日
Arxiv
13+阅读 · 2019年11月14日
Arxiv
5+阅读 · 2019年8月22日
Star-Transformer
Arxiv
5+阅读 · 2019年2月28日
Arxiv
4+阅读 · 2019年1月1日
Top
微信扫码咨询专知VIP会员