Efficient and Robust Approximate Nearest Neighbor Search Using Hierarchical Navigable Small World Graphs
Abstract
Domain fit: AI-adjacent · Paper appears method- or tooling-adjacent to AI workflows with partial ecosystem coverage.
We present a new approach for the approximate K-nearest neighbor search based on navigable small world graphs with controllable hierarchy (Hierarchical NSW, HNSW). The proposed solution is fully graph-based, without any need for additional search structures (typically used at the coarse search stage of the most proximity graph techniques). Hierarchical NSW incrementally builds a multi-layer structure consisting of a hierarchical set of proximity graphs (layers) for nested subsets of the stored elements. The maximum layer in which an element is present is selected randomly with an exponentially decaying probability distribution. This allows producing graphs similar to the previously studied Navigable Small World (NSW) structures while additionally having the links separated by their characteristic distance scales. Starting the search from the upper layer together with utilizing the scale separation boosts the performance compared to NSW and allows a logarithmic complexity scaling. Additional employment of a heuristic for selecting proximity graph neighbors significantly increases performance at high recall and in case of highly clustered data. Performance evaluation has demonstrated that the proposed general metric space search index is able to strongly outperform previous opensource state-of-the-art vector-only approaches. Similarity of the algorithm to the skip list structure allows straightforward balanced distributed implementation.
Results and benchmarks
We present a new approach for the approximate K-nearest neighbor search based on navigable small world graphs with controllable hierarchy (Hierarchical NSW, HNSW).
Benchmark evidence is limited
Evidence graph: 3 refs, 3 links.
Utility signals: depth 70/100, grounding 75/100, status medium.
Implementation
No direct implementation yet
Maintained implementation evidence is not confirmed for this paper yet.
Use the implementation status and reproduction sections for the current action plan.
No verified maintained repo yet
There is no verified maintained implementation yet. Use this baseline plan to decide whether to prototype now or defer.
- No maintained paper-verified implementation was found; start with the closest related repositories below.
- Compare repo methods against the paper equations/algorithm before trusting metrics.
- Create a minimal baseline implementation from the paper and use adjacent repos as references.
Time to first repro: a few days
jwasham/coding-interview-university is the closest maintained adjacent implementation (Matches contextual method/domain keyword: computer science). It is not paper-verified; validate algorithm and evaluation setup against the paper before trusting reported metrics. Community adoption signal: 359643 GitHub stars.
- Adjacent implementations are not paper-verified
- Recommended repository is adjacent and not paper-verified.
Reproduction readiness
No repo
No verified implementation available
- No maintained repository has been identified for this paper. Check adjacent implementations or HF artifacts below.
Hardware requirements
- Expect multi-day setup/compute for meaningful reproduction based on current guidance.
Validation caveat
Repositories and ecosystem
Closest related implementations
These are not paper-verified. Use them as reference points when no direct implementation is available.
- jwasham/coding-interview-university Adjacent · Confidence: Medium · 359,643 stars
Matches contextual method/domain keyword: computer science
No additional verified repositories beyond the primary recommendation.
Hugging Face artifacts
No trustworthy direct or curated related Hugging Face artifacts were found yet. Use targeted searches to quickly locate candidate models, datasets, and demos.
Datasets
Tip: start with models, then check datasets and spaces if you need evaluation data or demos.
Research context
1,779
Citations
74
References
Tasks
Nearest neighbor search, Computer science, Logarithm, Hierarchy, Graph, Metric (unit), Scaling, Theoretical computer science
Methods
k-nearest neighbors algorithm, Algorithm
Domains
Mathematics, Artificial intelligence, Computer Vision and Pattern Recognition
Related papers
- Depth-first k-nearest neighbor finding using the MaxNearestDist estimatorSearch on Paper2Code
2004 · Semantic similarity
- An Approximate k-Nearest Neighbor Search Algorithm for Content- Based Multimedia Information RetrievalSearch on Paper2Code
2000 · Semantic similarity
- Research of Bichromatic Reverse Nearest Neighbor Search for Spatial ObjectsSearch on Paper2Code
2009 · Semantic similarity
- Effective nearest neighbor indexing with the euclidean metricSearch on Paper2Code
2001 · Semantic similarity
- Effective nearest neighbor indexing with the euclidean metricSearch on Paper2Code
2001 · Semantic similarity
- Research on k-nearest NeighBor Search Algorithm in P2PSearch on Paper2Code
2009 · Semantic similarity
Open this paper in HFEPX to review benchmark signals, evaluation modes, and human-feedback protocol context.
Open in HFEPXJump to Paper2Code search queries derived from this paper's research context.