arXiv:2611.02556cs.DCNov 2026

Manuscript Offprint

arXiv:2611.02556

OctEx: Billion-Scale Vector Search by Precomputed Lattice Neighbor Lists on GPUs

Dongfang Zhao

Abstract

Approximate nearest-neighbor search on GPUs serves retrieval-augmented generation, recommendation, and deduplication over datasets of up to billions of vectors. The fastest GPU indexes at high recall, such as CAGRA, walk proximity graphs in chained rounds, each of which waits for the distances of the previous one. High recall therefore costs many dependent rounds per query. Our insight is to spend the HBM of the GPUs on precomputed neighbor lists, so that a query reads its candidates in one parallel step instead of a chain of rounds. This paper turns the above insight into a GPU vector search system, namely OctEx, which holds hundreds of randomly projected copies of the dataset in GPU memory. Every copy rounds its vectors to the nearest points of a regular grid whose cells are nearly round and stores for every populated cell the list of vectors nearest to its center. A query reads the lists of its cells in all copies at once and then, in a fixed number of waves, the precomputed neighbor lists of its best hits. OctEx ranks the union of all hits by an int8 sketch before one exact rerank. OctEx runs the whole search of a batch as CUDA graphs over all GPUs of a server and places every part of its index in HBM or host memory by its access frequency. On four H100 GPUs at recall 0.95 to 0.995, OctEx outperforms CAGRA by 2.0× to 46.4× on seven datasets of up to one hundred million vectors, and by 1.46× to 2.05× on the one billion vectors of Deep1B and SIFT1B, whose indexes it builds in 44 to 47 minutes. OctEx also outperforms GGNN, PathWeaver, FlowANN, and the cuVS inverted file indexes IVF-PQ and IVF-RaBitQ by 5.4× to 343×.

1 Introduction

Retrieval-augmented generation (RAG) [44], dense passage retrieval such as DPR [40] and ColBERT [41], and the deduplication of training data such as SemDeDup [1] require approximate nearest-neighbor (ANN) search at high recall, because every missed neighbor removes a relevant passage or keeps a duplicate. These applications search datasets of hundreds of

millions to billions of embeddings, for instance the Deep1B benchmark [9] and the billion-scale challenge [61]. A modern GPU server holds several hundred gigabytes of HBM and tens of thousands of cores. The natural target for such a server is a search that turns this memory and this parallelism into throughput at high recall.

Existing GPU indexes follow two designs, of which proximity graphs pay for recall with a chain of dependent rounds and inverted file (IVF) indexes pay with scans of whole inverted lists. Proximity-graph indexes such as CAGRA [53], GGNN [25], SONG [72], and BANG [64] adapt CPU graphs such as HNSW [47], NSG [19], and DiskANN [34] to the GPU. Each of their iterations expands the best unvisited vertices, which depend on the distances of the previous iteration. A query thus advances through a chain of rounds whose length grows with the recall target. IVF indexes such as IVF-PQ in Faiss [37] and cuVS [50] and the recent IVF-RaBitQ [60] avoid the chain, as a query probes a fixed number of inverted lists in one pass. However, IVF indexes scan every compressed code of every probed list, which keeps their throughput on four H100 GPUs one to two orders of magnitude below CAGRA in our measurements. Figure 1(a) quantifies the resulting cost on Deep1B, where CAGRA on four H100 GPUs falls from 156k queries per second (QPS) at recall 0.992 to 87k at recall 0.995 as each further 0.003 of recall needs a longer chain of rounds. On the same GPUs, IVF-RaBitQ remains below 28k QPS.

Breaking the chain requires candidates that do not depend on an earlier round. Precomputed lists of nearest vectors provide such candidates: a query that finds the list stored for its own position reads its neighbors in one step. Lists keyed by positions in the original space are, however, infeasible in hundreds of dimensions, because a ball around the query intersects almost every partition of the space before it reaches the tenth neighbor [11]. The lists must therefore be keyed by cells of low-dimensional projections and computed at build time, since an expansion at query time would reintroduce the chain.

Our insight is to precompute the nearest vectors per lattice

Figure

Figure 1: OctEx against baselines on four H100 GPUs.

cell and per random projection, so that a query reads them in parallel. This paper turns the above insight into a GPU vector search system, namely OctEx (Octa Explosion), which spends the HBM of the GPUs on these lists. OctEx projects the dataset into hundreds of random copies and rounds every block of eight projected coordinates to the nearest point of the E8E_8 lattice [14], a regular grid whose cells are the roundest known in eight dimensions. For every populated cell, OctEx stores the list of the vectors nearest to its center. At search time, a query decodes its own cell in every copy and reads the stored lists of these cells. The best hits become start points, whose precomputed neighbor lists the search reads in a fixed number of waves. Finally, OctEx ranks the union of all hits by an int8 sketch of every vector before it returns the top kk by one exact rerank in half precision.

We implement OctEx for one server with four H100 GPUs, on which OctEx outperforms proximity-graph baselines (CAGRA [53], GGNN [25], FlowANN [71], and PathWeaver [42]) and inverted file indexes (cuVS IVF-PQ [37, 50] and IVF-RaBitQ [60]) on nine datasets from one million to one billion vectors. Figure 1(b) presents the speedup over CAGRA across all nine datasets, which shows three results. First, the speedup of OctEx over CAGRA grows with the recall target, because OctEx keeps a fixed number of dependent steps while CAGRA needs a longer candidate list and more rounds per query. For example, on the MS MARCO passage embeddings that retrieval-augmented generation searches, the gain over CAGRA grows from 5.9×5.9\times at recall 0.95 to 32.6×32.6\times at recall 0.99. On ImageNet DINOv2, OctEx reaches recall 0.998, which CAGRA does not reach. Second, the gain holds on high-dimensional vectors, with 11.0×11.0\times and 14.2×14.2\times on GIST1M and 4.1×4.1\times and 12.8×12.8\times on DINOv2 at recall 0.95 and 0.99. Third, on the one billion vectors of Deep1B and SIFT1B, OctEx keeps the rows that every wave reads in HBM and moves only the half-precision vectors of the final rerank to host memory. There, OctEx outperforms CAGRA by 1.46×1.46\times to 2.05×2.05\times and cuVS IVF-RaBitQ by 20.2×20.2\times to 38.9×38.9\times.

In summary, this work makes the following contributions:

• We propose an ANN search by stored ripples, which

replaces the chained rounds of graph walks with precomputed lists of nearest vectors at two kinds of sources. A query reads the ripples of its lattice fragments in hundreds of random projections in one parallel step. It then reads the neighbor rows of its best hits, with reverse edges, in a fixed number of waves ( §3§3).

• We implement OctEx as an open-source CUDA C++ module of cuVS [50], which builds the index of one billion vectors in 44 to 47 minutes by sorting instead of searching and runs the search of a batch as CUDA graphs over all GPUs of a server in one process. The release replaces the search calls of cuVS and Faiss in one line of Python ( §4§4).

• We evaluate OctEx on nine datasets of up to one billion vectors against CAGRA, GGNN, FlowANN, PathWeaver, cuVS IVF-PQ, and IVF-RaBitQ on four H100 GPUs. OctEx outperforms CAGRA on every dataset at recall 0.95 to 0.995 and the other GPU graph systems GGNN, FlowANN, and PathWeaver by 5.4×5.4\times to 27.9×27.9\times. Against the inverted file indexes cuVS IVF-PQ and IVF-RaBitQ, the gain reaches 7.0×7.0\times to 343×343\times. At 100 to 1,000 queries per batch, OctEx answers a batch 2.2×2.2\times to 6.0×6.0\times faster than CAGRA on Deep100M and Deep1B. On one A100 of the previous generation, OctEx outperforms CAGRA on five datasets by 1.14×1.14\times to 16.3×16.3\times ( §5§5).

References (68)