SQUARE: Unsupervised Retrieval Adaptation via Synthetic Data

Jinsung Yoon, Junhao Zeng, Sercan Ö. Arık2025

TL;DR

This paper introduces SQUARE, a novel method for adapting pre-trained retrieval models to specific corpora without requiring any labeled data. By leveraging large language models (LLMs) to generate synthetic query-answer pairs from a corpus, SQUARE effectively fine-tunes retrieval models, leading to significant performance improvements over zero-shot and other unsupervised methods.

What Problem Does This Paper Address?

Retrieval-augmented generation (RAG) is crucial for enhancing the capabilities of large language models (LLMs) in question answering. A key component of RAG is the retrieval model, which needs to accurately fetch relevant information from a large text corpus. While pre-trained dense embedding models show strong zero-shot performance, their effectiveness can degrade when the target corpus differs significantly from their training data. Traditional methods to adapt these models often rely on costly and time-consuming labeled query-document pairs. Existing unsupervised methods, like Promptagator and Document Expansion, have limitations such as handling only one-to-one query-document mappings or suffering from scalability issues and potential retrieval bias. This paper addresses the need for an effective, unsupervised method to customize retrieval models for specific corpora, bridging the gap between zero-shot performance and the need for domain-specific adaptation.

Methods

SQUARE's core innovation lies in its unsupervised approach to generating high-quality synthetic data for fine-tuning retrieval models. The process involves:

  1. Synthetic Query-Answer Generation: For a given document from the target corpus, an LLM is prompted to generate a synthetic query and its corresponding answer. This ensures the generated data is grounded in the corpus.
  2. Answer-Based Filtering: A crucial step involves using the generated answers to filter out low-quality synthetic query-answer pairs. This is achieved by comparing the embedding of the synthetic answer with the embeddings of documents in the corpus. Pairs where the answer's embedding is not sufficiently similar to the document's embedding are discarded.
  3. Multi-Document Relevance Expansion: To address the limitation of one-to-one mappings, SQUARE expands the set of relevant documents for a synthetic query. If another document in the corpus exhibits higher similarity to the synthetic answer than the original document, it's also considered relevant.
  4. Fine-tuning: The filtered and expanded set of synthetic query-document pairs is then used to fine-tune the retrieval model using standard supervised techniques.

The authors highlight that SQUARE does not require generating data for every document, making it scalable for large corpora.

Datasets

The paper evaluates SQUARE on three retrieval benchmarks from the MTEB leaderboard:

  • BRIGHT [17]: A benchmark designed for reasoning-intensive retrieval, including both short and long document settings.
  • LongEmbed [24]: Focuses on retrieval with long documents.
  • MTEB-Law [19]: A domain-specific benchmark for legal retrieval.

These datasets were chosen because they are relatively new and have not been extensively used in pre-trained embedding model training, allowing for a clearer assessment of SQUARE's unsupervised adaptation capabilities.

Key Insights and Ideas

  • Unsupervised Adaptation is Powerful: The most significant insight is that effective retrieval model adaptation can be achieved without any human-labeled data, relying solely on the target corpus and LLMs.
  • Answer-Based Filtering is Key: The authors emphasize that filtering based on the synthetic answer's relevance to the document is critical for ensuring the quality of the training data and achieving robust performance gains. This is a key differentiator from previous methods.
  • Handling Multi-Document Relevance: SQUARE's ability to associate a single query with multiple relevant documents addresses a common limitation in previous unsupervised methods, making it more practical for diverse and heterogeneous corpora.
  • LLM-Agnostic and Retriever-Agnostic: The method is shown to be effective with different LLMs for generation and compatible with various dense retriever architectures, highlighting its broad applicability.

Key Results

SQUARE consistently outperforms zero-shot baselines and other unsupervised methods across all tested benchmarks.

  • BRIGHT Datasets: SQUARE shows significant performance gains, with improvements noted for both short and long document settings. For instance, on the BRIGHT-Short datasets, SQUARE achieved an average nDCG@10 of 0.3136, compared to 0.2642 for the zero-shot baseline.
  • LongEmbed and MTEB-Law: Similar substantial improvements were observed on these datasets, demonstrating SQUARE's generalizability.
  • Retriever Compatibility: Experiments with different retrievers (Gecko-004, OpenAI-embedding-3-small, GTE-Large) show that SQUARE enhances their performance across the board.
  • Fine-tuning Methods: While SQUARE's synthetic data can be used with various fine-tuning methods (Search-Adaptor, LoRA, OpenAI Cookbook), Search-Adaptor consistently showed the most robust improvements.

Limitations and Future Work

The authors acknowledge several limitations and suggest future research directions:

  • LLM Size: While state-of-the-art LLMs were used, future work could explore the performance of SQUARE with smaller, open-source LLMs to assess accessibility and broader applicability.
  • Dataset Bias: BEIR datasets were excluded due to extensive pre-training on them, which could obscure SQUARE's true impact. Future work could investigate performance on such datasets.
  • Multilingual Adaptation: Expanding SQUARE's capabilities to include multilingual data expansion is identified as an important future avenue.
  • Prompt Sensitivity: While the paper suggests SQUARE is not highly sensitive to prompts, further exploration with more complex prompts is presented, showing nuanced performance differences across datasets.
  • Two-Stage Generation: An exploration into a two-stage LLM generation process (query first, then answer) showed minimal performance differences compared to the one-stage approach.

Summary updated

BibTeX
@misc{yoon2025square,
  author = {Jinsung Yoon and Junhao Zeng and Sercan Ö. Arık},
  title = {{SQUARE: Unsupervised Retrieval Adaptation via Synthetic Data}},
  year = {2025},
  doi = {10.18653/v1/2025.findings-emnlp.384},
}
Figure