Manuscript Offprint

arXiv:2610.30425

Getting a GRIP on Graph-Based Search for Learned Sparse Retrieval

Vihan Lakshman, Franco Maria Nardini, Cosimo Rulli, Rossano Venturini

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

Learned sparse retrieval (LSR) has recently gained traction in the information retrieval community for the ability to combine the generalization capabilities of neural representations with the interpretability of keyword-based search. A number of recent works have demonstrated that inverted indexes, when appropriately modified for learned sparse embeddings, achieve state-of-the-art recall-latency tradeoffs for LSR, often outperforming graph-based indexes by substantial margins in latency at a fixed recall target. As a result, the community has generally concluded that graph-based approximate nearest neighbor (ANN) search is inferior to inverted indexes for LSR. This paper challenges this conventional wisdom. Our key insight is that, while applying standard graph-based ANN indexes out-of-the-box to sparse vectors leads to uncompetitive performance, we can overcome these shortcomings by infusing the strengths of inverted indexes into graph-based search. In particular, we introduce three techniques to accelerate graph-based LSR: (i) term-based entry point seeding, (ii) approximate routing via sparse sketching, and (iii) sparse partition-based graph construction. We combine these techniques into a new graph-based ANN system for LSR we call GRIP. On the MS MARCO v2 benchmark (138M passages) with SPLADE embeddings, GRIP achieves a 2.5×2.5\times latency improvement over Seismic, a state-of-the-art inverted index tailored for LSR, at 95% recall@10. Ultimately, our results call into question the default choice of inverted indexes for deploying learned sparse retrieval.

1 Introduction

Learned sparse embeddings have recently gained popularity in information retrieval applications by bridging the strengths of dense neural representations and interpretable lexical search. Consequently, a number of works have studied building indexes to enable efficient sparse similarity search at scale. Following the breakthrough success of systems such as Seismic [5], inverted index designs currently constitute the state of the art for sparse vector search, substantially outperforming graph-based methods, which typically achieve the strongest performance on dense retrieval workloads [1].

The intuition behind the success of inverted indexes for learned sparse retrieval is simple and compelling: sparse neural representations maintain many structural similarities to classical bag-of-words and TF-IDF sparse representations of text, and inverted indexes

Franco Maria Nardini

francomaria.nardini@isti.cnr.it

ISTI-CNR

Pisa, Italy

Rossano Venturini

rossano.venturini@unipi.it

University of Pisa

Pisa, Italy

were precisely designed for efficient search over such structures. Graph-based indexes, on the other hand, were conceived to address dense vector retrieval, a fundamentally different problem, and graphs are generally considered ill-suited for learned sparse retrieval due to network traversals incurring many redundant distance computations and poor memory access patterns [22].

MS MARCO v2 (SPLADE-CoCondenser)

Figure

Latency per query ( μ\mus, log scale)

Figure 1: On the MS MARCO v2 search benchmark with SPLADE-CoCondenser embeddings, GRIP outperforms Seismic, a state-of-the-art inverted index system for LSR, by 2.2−3.4×2.2 - 3.4 \times in latency across all fixed recall targets.

This paper challenges this conventional wisdom that graph-based methods are inherently inferior to inverted indexes for learned sparse retrieval. To that end, we present GRIP (Graph Retrieval for Sparse Inner Product Search), a graph-based approximate nearest-neighbor search system for sparse vector search that achieves a 2.2–3.4× latency improvement over Seismic at recall@10 targets between 90% and 98% on the full MS MARCO v2 benchmark (138M passages) with SPLADE-CoCondenser sparse embeddings, including a 2.5× improvement at 95% recall@10. On MS MARCO v1 (8.84M passages), GRIP is 1.4–1.7× faster than Seismic with SPLADE-CoCondenser embeddings at every recall target from 90% to 99%. With SPARSEUP [15], a more recent sparse embedding model, GRIP is 1.2× faster than Seismic at 92–95% recall@10 and on par at 97%, while Seismic retains an edge in the extremely high-recall regime (98–99%).

Our core insight driving the design of GRIP is that we can infuse the strengths of inverted indexes into graph-based search such that we retain the benefits of both index types. First and foremost, the signature feature of inverted indexes is that a sparse query vector only needs to touch the posting lists associated with its non-zero vector components. For sufficiently sparse vectors, this drastically reduces the search space. Standard graph-based indexes discard this structure. GRIP explicitly ports this structural advantage of the inverted index into graph search via a technique we call term-based entry point seeding, which precomputes, for every vocabulary term, the documents with the largest weight on that term, and initializes the graph search from the documents listed under the query's highest-impact terms. Better entry point selection for graph search is a well-studied problem in the vector database literature, both for dense retrieval [30] and by seeding graph traversal with the results of a separate lexical retrieval stage [19]. GRIP differs from prior work in using the sparse embeddings themselves as the entry point selection mechanism, which requires no additional retrieval system and almost no additional work at query time, making graph search 1.95−2.59×1.95 - 2.59 \times faster on its own in our experimental evaluations.

Secondly, we further accelerate GRIP via an optimization we call approximate routing via sparse sketching that is also inspired by inverted index designs for LSR. Learned sparse embeddings exhibit concentration of importance [5]: a small number of components carry most of each vector's weight. We exploit this property by sketching each document as its R largest-magnitude components and running the graph traversal entirely on these sketches, then reranking the final candidates against the full vectors. Because learned sparse weights are non-negative, a sketched score is always a lower bound on the exact score, so only the navigation of the graph is approximate, and the returned results are scored exactly. This sketching is complementary to quantizing the stored weights, which we also apply; sketching reduces how many components each distance computation touches, while quantization reduces the cost of each one.

Our final key optimization is not related to accelerating the query time of GRIP but rather the graph index construction. Traditionally, graph-based vector search indexes are constructed by calling the query function as a subroutine, inserting each new node by searching for its nearest neighbors among the documents already in the graph and adding edges according to a set of heuristics. As we show in this paper, sparse vectors are ill-suited to this search-based construction approach: while graphs over dense embeddings typically see diminishing returns beyond a construction beam width (ef_construction) of roughly 200 [14], we observe that HNSW graphs over learned sparse embeddings require a beam width of 2000 to achieve competitive search quality (when combined with our other aforementioned optimizations). However, this increase blows up the graph construction time by roughly an order of magnitude, and on the MS MARCO v2 dataset, we estimate that we would require several days to build the graph. To solve this problem, we take inspiration from PiPNN [31], a recently proposed index construction algorithm that replaces the incremental search-based procedure of prior systems with vector partitioning and hashing. PiPNN's partitioning step, which assigns points to randomly sampled leaders, closely mirrors the shallow k-means clustering that Seismic uses to organize its posting lists, and we find that it partitions learned sparse vectors effectively.

However, we cannot apply PiPNN to learned sparse vectors out-of-the-box because PiPNN computes nearest neighbors within each partition using dense matrix multiplication, which is wasteful for sparse vectors spanning tens of thousands of dimensions. Again taking inspiration from inverted index designs for LSR, we instead compute these inner products from a small inverted index built over each partition. We apply this approach to develop a sparse variant of PiPNN we call sparse partition-based graph construction, followed by a single refinement pass in which each document searches the finished graph from its own term seeds. This reduces the time to construct a GRIP graph from 5.5 hours (with HNSW) to 47 minutes on the 8.8M MS MARCO v1 collection with SPLADE-CoCondenser embeddings. While we show that GRIP's sparse PiPNN graph is somewhat weaker than an HNSW graph under standard search, the order-of-magnitude improvement in construction time allows us to build the graph for MS MARCO v2 in hours (7.3 hours) as opposed to days.

In addition to improving our scientific understanding of index design for learned sparse retrieval, enabling graph-based indexes to be more efficient for sparse vector workloads also has important practical implications. Many modern retrieval systems now deploy so-called hybrid search strategies where dense and sparse retrieval are combined to produce a final list of results. Since such systems already typically deploy graph-based indexes for dense retrieval, they may be able to consolidate and simplify their infrastructure by reusing the same components for sparse search as opposed to having to maintain separate inverted index logic. Moreover, the popularity of graph-based indexes has led to a mature ecosystem of high-performance libraries and remains an active area of research. Thus, efficient graph-based search for LSR can enable the sparse retrieval community to also take advantage of these ongoing developments.

In summary, this paper makes the following contributions:

  • End-to-End System: We challenge the conventional wisdom that graph-based indexes for sparse vector similarity search are uncompetitive with inverted indexes at practically relevant document collection sizes. We support this claim by presenting GRIP, a new system for graph-based learned sparse retrieval that achieves substantial performance improvements over standard graph-based search designed for dense retrieval via three algorithmic techniques which we highlight further below. These results call into question the default choice of inverted indexes for deploying learned sparse retrieval.

  • Term-based Entry Point Seeding: We present a new approach for selecting entry points for graph-based similarity search tailored to the structure of learned sparse embeddings. In particular, we precompute a list of documents with the largest weights per vocabulary term and initialize graph search at the nodes associated with the query's highest-impact components.

• Approximate Routing: Inspired by the concentration of importance property of learned sparse embeddings, we propose a simple and effective sketching technique that retains a document embedding’s R largest-magnitude components and performs graph traversal entirely on the sketched vectors. We observe that this reduces query latency with negligible loss in search quality.

  • Sparse PiPNN: We find that the traditional search-based iterative graph construction procedures used by popular indexes such as HNSW and DiskANN are especially poor fits for LSR because sparse embeddings require searching a much larger pool of candidates to build sufficiently navigable graphs. While applying traditional graph-based construction methods, in conjunction with our aforementioned optimizations, can produce competitive performance with inverted indexes, the build time is prohibitively expensive at scale. To remedy this bottleneck, we take inspiration from the recently proposed PiPNN construction algorithm [31] and adapt PiPNN to the sparse setting by utilizing inverted indexes in the construction process.

References (9)