一句话:利用 Stack Overflow 查询日志训练 Transformer,为开发者自动生成更有效的搜索查询。
Stack Overflow 上的海量问答使开发者难以高效定位所需信息。用户意图与文本查询之间存在差距,查询与帖子内容之间也存在语义差距,开发者不得不反复改写查询,例如纠正错词或补充编程语言/平台限制,对新手尤其繁琐。本文提出面向软件领域的自动化查询重构方法:基于 Stack Overflow 查询日志构建大规模查询重构语料(原始查询与对应重构查询),并训练 Transformer 模型,在给定原始查询时自动生成候选重构查询。评估显示该方法优于五个最先进基线,ExactMatch 提升 5.6% 至 33.5%,GLEU 提升 4.8% 至 14.4%。
As a popular Q&A site for programming, Stack Overflow is a treasure for developers. However, the amount of questions and answers on Stack Overflow make it difficult for developers to efficiently locate the information they are looking for. There are two gaps leading to poor search results: the gap between the user's intention and the textual query, and the semantic gap between the query and the post content. Therefore, developers have to constantly reformulate their queries by correcting misspelled words, adding limitations to certain programming languages or platforms, etc. As query reformulation is tedious for developers, especially for novices, we propose an automated software-specific query reformulation approach based on deep learning. With query logs provided by Stack Overflow, we construct a large-scale query reformulation corpus, including the original queries and corresponding reformulated ones. Our approach trains a Transformer model that can automatically generate candidate reformulated queries when given the user's original query. The evaluation results show that our approach outperforms five state-of-the-art baselines, and achieves a 5.6% to 33.5% boost in terms of ExactMatch and a 4.8% to 14.4% boost in terms of GLEU.
DOI 原文 · arXiv · PDF(开放获取) · DBLP
@inproceedings{abs-2102-00826,
title = {Automated Query Reformulation for Efficient Search Based on Query Logs From Stack Overflow},
author = {Kaibo Cao and Chunyang Chen and Sebastian Baltes and Christoph Treude and Xiang Chen},
booktitle = {ICSE},
year = {2021},
doi = {10.1109/icse43902.2021.00116}
}