Part of a series on | ||||
Network science | ||||
---|---|---|---|---|
Network types | ||||
Graphs | ||||
|
||||
Models | ||||
|
||||
| ||||
The Hierarchical navigable small world (HNSW) algorithm is a graph-based approximate nearest neighbor search technique used in many vector databases.[1][2] Nearest neighbor search without an index involves computing the distance from the query to each point in the database, which for large datasets is computationally prohibitive. For high-dimensional data, tree-based exact vector search techniques such as the k-d tree and R-tree do not perform well enough because of the curse of dimensionality. To remedy this, approximate k-nearest neighbor searches have been proposed, such as locality-sensitive hashing (LSH) and product quantization (PQ) that trade performance for accuracy.[2] The HNSW graph offers an approximate k-nearest neighbor search which scales logarithmically even in high-dimensional data.
It is an extension of the earlier work on navigable small world graphs presented at the Similarity Search and Applications (SISAP) conference in 2012 with an additional hierarchical navigation to find entry points to the main graph faster.[3] HNSW-based libraries are among the best performers in the approximate nearest neighbors benchmark.[4][5][6]
Use in vector databases
[edit]HNSW is a key method for approximate nearest neighbor search in high-dimensional vector databases, for example in the context of embeddings from neural networks in large language models. Databases that use HNSW as search index include:
- Apache Lucene Vector Search
- Chroma
- FAISS
- Qdrant
- Vespa
- Vearch Gamma
- Weaviate
- pgvector
- MariaDB[7]
Several of these use the hnswlib library[8] provided by the original authors.
References
[edit]- ^ Malkov, Yu A.; Yashunin, D. A. (2016). "Efficient and robust approximate nearest neighbor search using Hierarchical Navigable Small World graphs". arXiv:1603.09320 [cs.DS].
- ^ a b Malkov, Yury A; Yashunin, Dmitry A (1 April 2020). "Efficient and robust approximate nearest neighbor search using Hierarchical Navigable Small World graphs". IEEE Transactions on Pattern Analysis and Machine Intelligence. 42 (4): 824–836. arXiv:1603.09320. doi:10.1109/TPAMI.2018.2889473. PMID 30602420.
- ^ Malkov, Yury; Ponomarenko, Alexander; Logvinov, Andrey; Krylov, Vladimir (2012). "Scalable Distributed Algorithm for Approximate Nearest Neighbor Search Problem in High Dimensional General Metric Spaces". In Navarro, Gonzalo; Pestov, Vladimir (eds.). Similarity Search and Applications. Lecture Notes in Computer Science. Vol. 7404. Berlin, Heidelberg: Springer. pp. 132–147. doi:10.1007/978-3-642-32153-5_10. ISBN 978-3-642-32153-5.
- ^ Aumüller, Martin; Bernhardsson, Erik; Faithfull, Alexander (2017). "ANN-Benchmarks: A Benchmarking Tool for Approximate Nearest Neighbor Algorithms". In Beecks, Christian; Borutta, Felix; Kröger, Peer; Seidl, Thomas (eds.). Similarity Search and Applications. Lecture Notes in Computer Science. Vol. 10609. Cham: Springer International Publishing. pp. 34–49. arXiv:1807.05614. doi:10.1007/978-3-319-68474-1_3. ISBN 978-3-319-68474-1.
- ^ Aumüller, Martin; Bernhardsson, Erik; Faithfull, Alexander (2020). "ANN-Benchmarks: A benchmarking tool for approximate nearest neighbor algorithms". Information Systems. 87: 101374. arXiv:1807.05614. doi:10.1016/j.is.2019.02.006.
- ^ "ANN-Benchmarks". ann-benchmarks.com. Retrieved 2024-03-19.
- ^ "MariaDB Vector". MariaDB.org. Retrieved 2024-07-30.
- ^ nmslib/hnswlib, nmslib, 2024-03-18, retrieved 2024-03-19
Well, that’s interesting to know that Psilotum nudum are known as whisk ferns. Psilotum nudum is the commoner species of the two. While the P. flaccidum is a rare species and is found in the tropical islands. Both the species are usually epiphytic in habit and grow upon tree ferns. These species may also be terrestrial and grow in humus or in the crevices of the rocks.
View the detailed Guide of Psilotum nudum: Detailed Study Of Psilotum Nudum (Whisk Fern), Classification, Anatomy, Reproduction