#32 · Primary category: Vector Databases

NGT

approximate-nearest-neighbor-search k-nearest-neighbors knn-search nearest-neighbor-search nearest-neighbors vector-database vector-search

Nearest Neighbor Search with Neighborhood Graph and Tree for High-dimensional Data

Project last updated:07/27/26

GitHub Stars

1.4K

Forks

130

Contributors

22

License

Apache-2.0

Why we included this project

NGT comes out of Yahoo Japan's research lab, so it has had real production scrutiny that a lot of newer search libraries skip. It builds a graph-and-tree index over high-dimensional vectors and offers a few flavors: the base NGT, plus quantized graph and quantized blob graph methods that trade a little accuracy for faster search on large datasets. You get a C++ library and command-line tools, with Python bindings and community drivers for Ruby, Go, Rust, and Node, so it fits into mixed stacks without much setup. The index can be memory-mapped, which helps when you have millions of vectors that don't all fit in RAM, and the distance metrics cover L1, L2, cosine, angular, Hamming, Jaccard, and inner product for recommendation-style scoring. If you're building semantic search, recommendations, or image matching, NGT's balance of speed and flexible memory handling is worth a look.

Articles for this project

No articles for this project yet.

To suggest a topic or contribute an article, contact us.

Related projects in this category