论文标题

低资源特定项目代码摘要

Low-Resources Project-Specific Code Summarization

论文作者

Xie, Rui, Hu, Tianxiang, Ye, Wei, Zhang, Shikun

论文摘要

代码摘要生成了简短的自然语言描述,对源代码件,可以帮助开发人员理解代码并减少文档工作负载。关于代码摘要的最新神经模型将在由独立代码 - 苏格尔对组成的大规模多项目数据集上进行训练和评估。尽管有技术的进步,但很少探索它们对特定项目的有效性。但是,在实际情况下,开发人员更关心为其工作项目生成高质量的摘要。而且这些项目可能无法保持足够的文档,因此很少有历史代码 - 苏格尔对。为此,我们研究了低资源项目特定的代码摘要,这是一项与开发人员要求更一致的新任务。为了更好地通过有限的培训样本来表征特定于项目的知识,我们通过将轻量级的微调机制纳入元学习框架来提出一种元转移学习方法。对九个现实世界项目的实验结果验证了我们方法的优越性,而不是替代方法,并揭示了如何学习项目特定知识。

Code summarization generates brief natural language descriptions of source code pieces, which can assist developers in understanding code and reduce documentation workload. Recent neural models on code summarization are trained and evaluated on large-scale multi-project datasets consisting of independent code-summary pairs. Despite the technical advances, their effectiveness on a specific project is rarely explored. In practical scenarios, however, developers are more concerned with generating high-quality summaries for their working projects. And these projects may not maintain sufficient documentation, hence having few historical code-summary pairs. To this end, we investigate low-resource project-specific code summarization, a novel task more consistent with the developers' requirements. To better characterize project-specific knowledge with limited training samples, we propose a meta transfer learning method by incorporating a lightweight fine-tuning mechanism into a meta-learning framework. Experimental results on nine real-world projects verify the superiority of our method over alternative ones and reveal how the project-specific knowledge is learned.

扫码加入交流群

加入微信交流群

微信交流群二维码

扫码加入学术交流群,获取更多资源