arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2208.11523cs.SEcs.CL
收藏

基于多采样增强型Transformer的栈溢出帖的多标题生成

Diverse Title Generation for Stack Overflow Posts with Multiple Sampling Enhanced Transformer

Wuhan University(武汉大学);Huazhong University of Science and Technology(华中科技大学);Wuhan University of Technology(武汉理工大学);Deakin University(迪肯大学);City University of Hong Kong(香港城市大学)

Fengji Zhang, Jin Liu, Yao Wan, Xiao Yu, Xiao Liu, Jacky Keung

摘要:

Stack Overflow是最受欢迎的编程社区之一,开发人员可以在这里为遇到的问题寻求帮助。然而,如果没有经验的开发人员不能清楚地描述他们的问题,他们很难引起足够的注意并得到预期的答案。我们提出了M $_3$ NSCT 5,一种新的方法来自动生成多个职位的标题从给定的代码片段。开发人员可以使用生成的标题来查找密切相关的帖子并完成其问题描述。M $_3$ NSCT 5采用CodeT5主干,这是一个预先训练的Transformer模型,具有出色的语言理解和生成能力。为了减轻歧义问题,相同的代码片段可以对齐不同的标题在不同的上下文,我们提出了最大边际多核抽样策略,以产生多个高质量和多样化的标题候选人在同一时间供开发人员选择。我们构建了一个包含890,000个问题帖子的大规模数据集,涵盖8种程序设计语言,以验证M $_3$ NSCT 5的有效性。BLEU和ROUGE指标的自动评估结果证明了M $_3$ NSCT 5优于六种最先进的基线模型。此外,具有值得信赖的结果的人类评估也证明了我们的方法在现实世界中应用的巨大潜力。

英文摘要:

Stack Overflow is one of the most popular programming communities where developers can seek help for their encountered problems. Nevertheless, if inexperienced developers fail to describe their problems clearly, it is hard for them to attract sufficient attention and get the anticipated answers. We propose M$_3$NSCT5, a novel approach to automatically generate multiple post titles from the given code snippets. Developers may use the generated titles to find closely related posts and complete their problem descriptions. M$_3$NSCT5 employs the CodeT5 backbone, which is a pre-trained Transformer model having an excellent language understanding and generation ability. To alleviate the ambiguity issue that the same code snippets could be aligned with different titles under varying contexts, we propose the maximal marginal multiple nucleus sampling strategy to generate multiple high-quality and diverse title candidates at a time for the developers to choose from. We build a large-scale dataset with 890,000 question posts covering eight programming languages to validate the effectiveness of M$_3$NSCT5. The automatic evaluation results on the BLEU and ROUGE metrics demonstrate the superiority of M$_3$NSCT5 over six state-of-the-art baseline models. Moreover, a human evaluation with trustworthy results also demonstrates the great potential of our approach for real-world application.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑