Query rewriting refers to an established family of approaches that are applied to underspecified and ambiguous queries to overcome the vocabulary mismatch problem in document ranking. Queries are typically rewritten during query processing time for better query modelling for the downstream ranker. With the advent of large-language models (LLMs), there have been initial investigations into using generative approaches to generate pseudo documents to tackle this inherent vocabulary gap. In this work, we analyze the utility of LLMs for improved query rewriting for text ranking tasks. We find that there are two inherent limitations of using LLMs as query re-writers -- concept drift when using only queries as prompts and large inference costs during query processing. We adopt a simple, yet surprisingly effective, approach called context aware query rewriting (CAR) to leverage the benefits of LLMs for query understanding. Firstly, we rewrite ambiguous training queries by context-aware prompting of LLMs, where we use only relevant documents as context.Unlike existing approaches, we use LLM-based query rewriting only during the training phase. Eventually, a ranker is fine-tuned on the rewritten queries instead of the original queries during training. In our extensive experiments, we find that fine-tuning a ranker using re-written queries offers a significant improvement of up to 33% on the passage ranking task and up to 28% on the document ranking task when compared to the baseline performance of using original queries.
翻译:查询重写是指一类成熟的方法,用于解决文档排序中因查询表述不充分或歧义导致的词汇不匹配问题。通常,查询在查询处理阶段被重写,以更好地为下游排序器建模查询。随着大语言模型的出现,已有初期研究尝试利用生成式方法生成伪文档来弥合这一固有词汇鸿沟。本文分析了LLM在文本排序任务中优化查询重写的实用性。我们发现,使用LLM作为查询重写器存在两个固有限制——仅以查询作为提示时的概念漂移,以及查询处理过程中的高推理成本。我们采用了一种简单但出奇有效的方法——上下文感知查询重写(CAR),以利用LLM在查询理解方面的优势。首先,我们通过上下文感知提示LLM来重写带有歧义的训练查询,其中仅使用相关文档作为上下文。与现有方法不同,我们仅在训练阶段使用基于LLM的查询重写。最终,排序器在训练时使用重写后的查询替代原始查询进行微调。在大量实验中,我们发现,与使用原始查询的基线性能相比,使用重写查询微调排序器在段落排序任务上最高可提升33%,在文档排序任务上最高可提升28%。