Autoregressive Search Engines: Generating Substrings as Document Identifiers

Michele Bevilacqua, Giuseppe Ottaviano, Patrick Lewis, Wen-tau Yih, Sebastian Riedel, Fabio Petroni · DOI

Introduction

Information retrieval (IR) has traditionally relied on two primary paradigms: sparse retrieval, which utilizes keyword matching (e.g., BM25), and dense retrieval, which maps queries and documents into a shared latent vector space (e.g., DPR). Recently, a third paradigm has emerged: generative retrieval. In this approach, a language model (LM) is trained to generate a unique identifier (ID) for a document, such as a title or a cluster code, directly from a query.

While promising, generative retrieval often suffers from a "metadata bottleneck." Assigning fixed identifiers is rigid, especially for documents lacking clear titles or when the goal is to retrieve specific passages rather than entire pages. This paper introduces SEAL (Search Engines with Autoregressive LMs), a framework that redefines document retrieval by treating every substring within a corpus as a potential unique identifier.

The SEAL Framework

SEAL eliminates the need for predefined, manual, or hierarchical identifiers. Instead, it leverages the content of the corpus itself to serve as the address space. The system consists of two core components: an autoregressive language model and a constrained search index.

1. Autoregressive Language Modeling

SEAL utilizes a BART-large model fine-tuned to generate "distinctive ngrams"—strings of text that appear within relevant documents. Given a query, the model attempts to predict a sequence of tokens that uniquely identifies the target information.

2. Constrained Decoding via FM-Index

To ensure the model only generates strings that actually exist within the corpus, SEAL employs an FM-index. This compressed data structure allows for extremely efficient substring searches. During the decoding process, the FM-index acts as a constraint: the LM is only permitted to generate tokens that form a valid substring found in the document collection. This prevents the model from "hallucinating" identifiers and ensures that every output points to a real document.

Scoring and Ranking Strategies

Generating a likely string is only the first step. To effectively rank documents, SEAL introduces two sophisticated scoring mechanisms:

  • LM+FM Scoring: This combines the probability assigned by the language model with the frequency of the ngram in the corpus. By penalizing ngrams that appear in too many documents, the system rewards "distinctive" strings, functioning similarly to the inverse document frequency (IDF) component in traditional IR.
  • Intersective Scoring: Rather than relying on a single generated string, SEAL generates multiple candidate ngrams via beam search. It then aggregates the scores of these ngrams to "triangulate" the most relevant documents. If multiple generated ngrams point to the same document, that document’s relevance score increases.

Experimental Results

The researchers evaluated SEAL across several high-stakes, knowledge-intensive benchmarks, including Natural Questions (NQ) and the KILT (Knowledge Intensive Language Tasks) benchmark, which includes tasks like fact-checking (FEVER) and dialogue (WoW).

Performance Highlights

  • State-of-the-Art on KILT: SEAL achieved an average improvement of at least 10 points in R-precision over established baselines for passage-level retrieval.
  • Generalization: On the "zero-overlap" split of Natural Questions—where the model must retrieve information about facts not seen during training—SEAL significantly outperformed competing models. This suggests that the system learns a robust search mechanism rather than simply memorizing training pairs.
  • Memory Efficiency: One of the most significant advantages of SEAL is its footprint. Dense retrievers typically require storing massive vector embeddings (often exceeding 60GB for Wikipedia). SEAL’s FM-index is roughly 1.5x smaller than the uncompressed plain text of the corpus, making it 2 to 7 times more memory-efficient than competing dense retrieval systems.

Limitations and Future Directions

Despite its performance and efficiency, SEAL faces challenges regarding inference speed. Because it relies on autoregressive beam search—generating identifiers token-by-token—it is currently slower than the simple vector lookups used in dense retrieval. Future research will focus on optimizing decoding algorithms to bridge this gap.

Additionally, while SEAL has proven effective on the 21 million passages of Wikipedia, scaling to the billions of pages on the open web will require further advancements in FM-index optimization and model architecture. The authors anticipate that moving to larger language models (e.g., GPT-4 or Llama-scale) will further enhance the system's retrieval capabilities.

Conclusion

SEAL represents a significant shift in generative retrieval by proving that the corpus itself can serve as its own identifier space. By combining the generative power of BART with the structural constraints of an FM-index, SEAL offers a high-performance, memory-efficient alternative to traditional dense and sparse retrieval methods.

Summary updated

BibTeX
@inproceedings{bevilacqua2022autoregressive,
  author = {Michele Bevilacqua and Giuseppe Ottaviano and Patrick Lewis and Wen-tau Yih and Sebastian Riedel and Fabio Petroni},
  title = {{Autoregressive Search Engines: Generating Substrings as Document Identifiers}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2022},
  url = {https://openreview.net/forum?id=Z4kZxAjg8Y},
}
Figure