Abstract
Graph-based Approximate Nearest Neighbor Search (ANNS) methods like HNSW are widely used for their efficiency, yet they suffer from redundant distance calculations during graph traversal. This paper introduces PEOs (Partitioned Extreme Order Statistics), a novel routing algorithm that provides a probabilistic guarantee for neighbor exploration. By estimating neighbor proximity through space partitioning and extreme order statistics, PEOs reduces unnecessary distance calculations by up to 80%, achieving 1.6x to 2.5x higher throughput than state-of-the-art graph indexes.
Introduction
Approximate Nearest Neighbor Search (ANNS) is critical for modern vector databases and recommendation systems. Graph-based methods are the current standard, but their "routing" phase is often inefficient. During traversal, algorithms typically calculate exact distances for every neighbor of a node to decide which path to follow. While heuristics exist to prune these neighbors, they often lack theoretical backing and consistent performance across diverse datasets. PEOs addresses this by bridging the gap between the theoretical rigor of Locality-Sensitive Hashing (LSH) and the empirical speed of graph-based search.
Methods
The PEOs routing test estimates whether a neighbor is "close enough" to warrant an exact distance calculation using several key techniques:
- Space Partitioning: The vector space is divided into $L$ orthogonal subspaces. This "divide and conquer" approach reduces the variance of distance estimations compared to full-vector analysis.
- Extreme Order Statistics: Within each subspace, random projections identify "extreme" values (max/min), which are highly informative of the actual angle between vectors.
- Probabilistic Guarantee: PEOs is designed as a $(\delta, 1-\epsilon)$-routing test. If a neighbor is within distance threshold $\delta$, it is guaranteed to be checked with a probability of at least $1-\epsilon$.
- Hardware Optimization: The implementation utilizes SIMD instructions and pre-calculated lookup tables to estimate distances for 16 neighbors simultaneously, ensuring the pruning process is significantly faster than exact distance computation.
Evaluation and Results
The researchers evaluated PEOs across seven large-scale datasets, including GloVe (text), SIFT, GIST, and Tiny5M (images), as well as the 100-million-scale DEEP100M dataset.
Key Insights
- Partitioning Stability: Increasing the number of subspaces $L$ (typically to 8 or 16) stabilizes estimations, allowing for safer neighbor skipping without accuracy loss.
- Tunable Performance: The probabilistic formulation provides a "knob" ($\epsilon$) for practitioners to balance speed and recall with mathematical confidence.
Performance Metrics
- Efficiency: PEOs consistently reduced exact distance calculations by 70% to 80%.
- Throughput: Integration with HNSW and NSSG increased Queries Per Second (QPS) by 1.6x to 2.5x.
- Competitive Edge: PEOs outperformed FINGER, the previous leading routing technique, by 1.1x to 1.4x across various recall levels.
Conclusion and Future Work
While PEOs significantly boosts search efficiency, it introduces some memory overhead due to the storage of additional projection data. A "compact" version mitigates this, achieving a 30% performance gain on DEEP100M with only 3% extra memory. Future work includes extending PEOs to other search metrics like Maximum Inner Product Search (MIPS) and handling highly skewed, non-isotropic data distributions more effectively.
Summary updated