Skip to main content
QUICK REVIEW

[Paper Review] Query Expansion by Prompting Large Language Models

Rolf Jagerman, Honglei Zhuang|arXiv (Cornell University)|May 5, 2023
Topic ModelingComputer Science15 citations
TL;DR

The paper uses prompting of open-source LLMs to generate query expansions for IR, finding Chain-of-Thought prompts, especially with PRF context, yield strong recall gains over traditional PRF methods on MS-MARCO and BEIR datasets. Larger models help, CoT prompts perform best, and PRF contexts improve top-heavy metrics.

ABSTRACT

Query expansion is a widely used technique to improve the recall of search systems. In this paper, we propose an approach to query expansion that leverages the generative abilities of Large Language Models (LLMs). Unlike traditional query expansion approaches such as Pseudo-Relevance Feedback (PRF) that relies on retrieving a good set of pseudo-relevant documents to expand queries, we rely on the generative and creative abilities of an LLM and leverage the knowledge inherent in the model. We study a variety of different prompts, including zero-shot, few-shot and Chain-of-Thought (CoT). We find that CoT prompts are especially useful for query expansion as these prompts instruct the model to break queries down step-by-step and can provide a large number of terms related to the original query. Experimental results on MS-MARCO and BEIR demonstrate that query expansions generated by LLMs can be more powerful than traditional query expansion methods.

Motivation & Objective

  • Investigate whether prompting LLMs can generate effective query expansions without retraining.
  • Compare zero-shot, few-shot, and Chain-of-Thought prompts for QE.
  • Assess the role of PRF context and model size in QE effectiveness.
  • Evaluate on MS-MARCO and BEIR to understand domain robustness.

Proposed method

  • Formulate query expansion as concatenating the original query with LLM-generated expansions.
  • Study eight prompts (Q2D, Q2D/ZS, Q2D/PRF, Q2E, Q2E/ZS, Q2E/PRF, CoT, CoT/PRF) with/without PRF context.
  • Use Q2D/Q2E prompts to generate expansion terms; repeat original query five times to emphasize its terms.
  • Evaluate across multiple open-source models (Flan-T5 variants and Flan-UL2) of sizes from 60M to 20B parameters.
  • Use BM25 as the retrieval baseline and Terrier implementations for QE baselines (Bo1, Bo2, KL).
  • Measure Recall@1K as primary metric, with MR R@10 and NDCG@10 for top-heavy performance; significance via paired t-test (p<0.01).

Experimental results

Research questions

  • RQ1Can LLM-generated expansions via prompting improve recall over traditional PRF-based QE on standard IR benchmarks?
  • RQ2Which prompting style (zero-shot, few-shot, Chain-of-Thought) yields best expansion terms for retrieval?
  • RQ3Does incorporating PRF documents into prompts help, and how does model size affect results?
  • RQ4How do LLM-based QE methods perform across MS-MARCO and BEIR domains?
  • RQ5What are practical considerations (model size, cost) for deploying LLM-based QE?

Key findings

  • Chain-of-Thought prompts yield the strongest recall gains on MS-MARCO when used for query expansion.
  • CoT/PRF prompts improve top-heavy metrics (MRR@10, NDCG@10) by leveraging PRF context.
  • Q2D/PRF and CoT variants outperform classical PRF baselines (Bo1, Bo2, KL) on Recall@1K.
  • On MS-MARCO, larger models generally perform better, with CoT achieving parity with BM25+Bo1 around 3B params and best results at 11B+ models.
  • On BEIR, PRF-based classical QE remains strong on domain-specific datasets, while LLM-based QE shines on QA-oriented datasets (fiqa, nq, msmarco, hotpotqa).
  • Using PRF contexts helps stabilize performance for smaller models but may reduce gains at very large sizes; distillation of large models to smaller ones is suggested for practical deployment.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.