skillfed

voyager

Easy-to-use, fast, simple multi-platform approximate nearest-neighbor search library.

voyager v2.1.0 118.0K downloads/30d#12,140 on PyPI1,589
Permissive license Active released

What it is and what it does

Voyager is a production-grade library for approximate nearest-neighbor search on vector embeddings, built on the HNSW algorithm and used at Spotify to handle hundreds of millions of queries daily. It wraps the open-source hnswlib with additional convenience features and maintains feature parity between Python and Java implementations, making it suitable for both single-machine and distributed systems that need fast similarity lookups on embedding data.

The library is designed for in-memory operation, meaning vectors are loaded into RAM for query speed. It supports multiple distance metrics (e.g., cosine, Euclidean) and is optimized for recall-accuracy tradeoffs typical of approximate search. Installation is straightforward via pip on supported platforms (Linux, macOS, Windows), with pre-built wheels for Python 3.7–3.12, though it does depend on numpy and compiled C++ bindings.

Use it for:

  • Powering recommendation systems by finding similar user embeddings or item embeddings in real time.
  • Semantic search over document embeddings to retrieve relevant results faster than exact similarity.
  • Duplicate detection by indexing embeddings and querying for near-neighbors to identify similar content.
  • Machine learning feature retrieval, retrieving nearest neighbors in embedding space for classification or clustering tasks.
  • Real-time personalization by querying user preference embeddings against product or content embeddings.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Voyager performs fast approximate nearest-neighbor searches on in-memory vector collections using the HNSW algorithm, enabling efficient similarity queries on embedding data.

Yes. Voyager is production-ready, actively maintained, permissively licensed, and has no known vulnerabilities. It offers a clean API for a common and performance-critical task (approximate nearest-neighbor search). Install it if you need fast vector similarity queries on embeddings; the medium install friction is offset by broad platform coverage and proven scale at Spotify.

Install

voyager on PyPI

pip

pip install voyager

uv

uv add voyager

poetry

poetry add voyager

Installing voyager

Before you install

Medium install friction due to compiled C++ bindings, but pre-built wheels cover Python 3.7–3.12 across Linux (x86_64, ARM), macOS (Intel, ARM), and Windows (x86_64). Actively maintained with recent commits and production use at scale.

License in practice

Licensed under Apache 2, a permissive open-source license allowing commercial and private use with minimal restrictions—suitable for most projects without legal concern.

Quickstart

pip install voyager
import voyager
import numpy

index = voyager.Index(space='cosine')
index.add(vectors)
nearest = index.query(query_vector, k=10)

Requires numpy; compiled wheels are available for common platforms, but installation may require a C++ compiler on unsupported architectures.

Verify before relying

  • Whether the package supports dynamic index updates (add/remove vectors after initial build) or requires rebuild.
  • Memory overhead and scalability limits for very large vector collections.
  • Tuning guidance for HNSW parameters (M, ef_construction, ef) for different use cases.
  • Performance comparison specifics with other approximate nearest-neighbor libraries beyond the ann-benchmarks reference.

Package facts

License not declared (permissive)
Python support not specified
Install friction medium — platform-specific wheel
Runtime dependencies 1 — numpy
Maintenance actively maintained — 609 days since the last release
Last repo commit
First released
Downloads 117,976/month — #12,140 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: voyager-2.1.0-cp310-cp310-macosx_10_13_universal2.whl; voyager-2.1.0-cp310-cp310-macosx_10_13_x86_64.whl; voyager-2.1.0-cp310-cp310-macosx_11_0_arm64.whl; voyager-2.1.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; voyager-2.1.0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; voyager-2.1.0-cp310-cp310-win_amd64.whl; voyager-2.1.0-cp311-cp311-macosx_10_13_universal2.whl; voyager-2.1.0-cp311-cp311-macosx_10_13_x86_64.whl; voyager-2.1.0-cp311-cp311-macosx_11_0_arm64.whl; voyager-2.1.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; voyager-2.1.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; voyager-2.1.0-cp311-cp311-win_amd64.whl; voyager-2.1.0-cp312-cp312-macosx_10_13_universal2.whl; voyager-2.1.0-cp312-cp312-macosx_10_13_x86_64.whl; voyager-2.1.0-cp312-cp312-macosx_11_0_arm64.whl; voyager-2.1.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; voyager-2.1.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl; voyager-2.1.0-cp312-cp312-win_amd64.whl; voyager-2.1.0-cp37-cp37m-macosx_10_13_x86_64.whl; voyager-2.1.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Development Status :: 5 - Production/StableLicense :: OSI Approved :: Apache Software LicenseOperating System :: MacOSOperating System :: Microsoft :: WindowsOperating System :: POSIX :: LinuxProgramming Language :: C++Programming Language :: PythonProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.7Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9Topic :: Database :: Database Engines/Servers

Tags

approximate nearest neighbor searchvector similarity searchembedding search libraryHNSW vector indexfast vector retrievalin-memory vector databasenearest neighbor lookup
vector-searchembeddingssimilarity-search

More Database Engines/Servers packages

Further reading