Model or dataset
alibaba/zvec avatar
alibaba/zvec

Zvec: An In-Process Vector Database with Hybrid Search and Multi-Language SDKs

A lightweight, lightning-fast, in-process vector database

16,029 stars1,006 forksC++Apache-2.0

At a glance

What is it?
Zvec is an open-source vector database from Alibaba that runs as a library inside your application process rather than as a separate server. It supports dense and sparse vectors, full-text search, and hybrid queries, with official SDKs for Python, Node.js, Go, Rust, and Dart.
Who is it for?
Zvec is the right choice when you want similarity search embedded in your application process without running a separate database server. The in-process design eliminates network round-trips and simplifies deployment, but it comes with a concrete constraint: writes are single-process exclusive, so a multi-process write workload requires a different tool.
Can I use it commercially?
Yes. Apache-2.0 is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
Is it still maintained?
Yes. The repository received new commits within the last day.
What is it written in?
Mainly C++, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on September 29, 2026, and from our analysis. They are not legal advice.

DEEP OPEN-SOURCE ANALYSIS

What Zvec Is and the Problem It Solves

Most vector databases operate as standalone servers. A client application sends queries over HTTP or a proprietary protocol, waits for a network round-trip, and receives results. This architecture adds latency and infrastructure complexity for applications that run similarity search as an internal operation rather than a shared service.

Zvec takes a different approach. The README describes it as an in-process vector database, meaning it runs as a library inside the same process as your application. There is no server to start, no port to configure, and no network connection to maintain. The README states: "Pure local, no servers, no config, no fuss."

The primary audience is developers building RAG pipelines, AI agents, search features, or code analysis tools where vector search is one step in a larger application, not a shared infrastructure service. Zvec has been battle-tested within Alibaba Group, according to the README. The v0.7.0 release also integrates Zvec as a file store backend in ReMe, a memory management kit for agents, where it provides in-process HNSW ANN search.

The supported platforms cover the main deployment environments: Linux on x86_64 and ARM64 with both glibc and musl, macOS on ARM64 and x86_64, and Windows on x86_64. Android and iOS are also supported through prebuilt SDK binaries published with each release.

Installing Zvec and Running a First Query

Python is the most direct path to evaluation. Install the package:

bash
pip install zvec

The README requires 64-bit Python 3.10 through 3.14. The `pyproject.toml` marks the classifier as `Development Status :: 3 - Alpha`, which is worth noting for production decisions.

The README provides a complete working example. Define a schema, create a collection, insert documents, and run a similarity query:

python
import zvec

schema = zvec.CollectionSchema(
    name="example",
    vectors=zvec.VectorSchema("embedding", zvec.DataType.VECTOR_FP32, 4),
)

collection = zvec.create_and_open(path="./zvec_example", schema=schema)

collection.insert([
    zvec.Doc(id="doc_1", vectors={"embedding": [0.1, 0.2, 0.3, 0.4]}),
    zvec.Doc(id="doc_2", vectors={"embedding": [0.2, 0.3, 0.4, 0.1]}),
])

results = collection.query(
    zvec.Query(field_name="embedding", vector=[0.4, 0.3, 0.3, 0.1]),
    topk=10
)

For Node.js, install with `npm install @zvec/zvec`. For Rust, `cargo add zvec-rust`. For Dart and Flutter, `flutter pub add zvec`.

Index Types, Quantization, and the v0.7.0 Additions

Zvec supports multiple vector index types. The README mentions HNSW (Hierarchical Navigable Small World) for approximate nearest neighbor search and DiskANN for disk-based indexing that scales beyond memory capacity.

The v0.7.0 release added IVF-RaBitQ as a new index type and PQ-INT8 as a new quantizer. RaBitQ supports runtime AVX2 and AVX512 dispatch, meaning the same binary automatically selects the best instruction set for the CPU it runs on without user intervention. DiskANN in v0.7.0 gained Linux ARM64 and macOS ARM64 support, and added an `io_uring` async I/O backend with automatic fallback to the best available option.

The documentation site at zvec.org/en/docs/db/concepts/vector-index/ lists the complete set of supported index types. The README points to benchmarks at zvec.org/en/docs/db/benchmarks/ for detailed performance methodology, but does not include raw numbers in the repository itself.

Hybrid Search: Combining Vector Similarity, Full-Text, and Filters

Zvec supports three search modalities that can be combined in a single query: vector similarity search over dense or sparse embeddings, full-text search using native keyword-based queries, and structured scalar filters.

For full-text search, Zvec ships a built-in tokenizer. The v0.7.0 release added an N-gram tokenizer, described in the README as better suited for phrase, code, and short-text search compared to the previous tokenizer.

The README calls the ability to fuse these three modalities in a single query "hybrid search." The practical benefit is that an application can express a query like "find documents whose embedding is close to this vector, that contain this keyword, and whose status field equals active" without running three separate queries and merging results in application code.

Durability, Concurrency, and the Write Exclusivity Constraint

Zvec uses a write-ahead log (WAL) for durability. The README states that data is never lost even on process crash or power failure. This is the standard durability guarantee associated with WAL-based storage engines.

For concurrent access, the model is asymmetric. Multiple processes can read the same collection simultaneously, but writes are single-process exclusive. This means a Zvec collection cannot be written to from two separate processes at the same time. The README does not document how this exclusivity is enforced or what happens when a second process attempts a write while another holds the write lock.

For applications where a single process handles all writes and multiple processes (or threads) read, this model is straightforward. For applications that need multi-process writes, such as a web server with multiple worker processes all ingesting data, this constraint requires a different architecture or a different storage backend.

The zvec-grep CLI and Platform Coverage

The v0.7.0 release introduced zvec-grep (`zg`), a separate CLI tool in the zvec-ai/zvec-grep repository. The README describes it as a local-first workspace search that unifies ripgrep, BM25, and vector search behind one CLI, built for humans and AI agents. It provides command-line access to Zvec's search capabilities without writing code.

Zvec publishes prebuilt binaries with every release for Linux (glibc and musl/Alpine), macOS (ARM64 and x86_64), Windows (x86_64), Android, and iOS. The v0.7.0 release notes that the macOS ARM64 C API library size dropped from 37 MB to 22 MB, a 40% reduction.

For developers who want to inspect data without writing queries, a separate visual tool called Zvec Studio is available at zvec-ai/zvec-studio.

License, Alternatives, and the Alpha Classifier

Zvec is licensed under Apache 2.0, which permits commercial use, modification, and distribution. The `NOTICE` file in the repository indicates additional attribution requirements for Apache 2.0 compliance.

A direct comparison is with Chroma (trychroma.com), another in-process vector database with a Python-first API. Chroma also runs without a server and stores data locally. The key difference visible in the Zvec README is that Zvec ships multi-language SDKs including Rust, Go, and Dart, while Chroma's primary interface is Python with HTTP APIs for other languages. Zvec also documents DiskANN support for disk-based indexing that scales beyond available memory, which the README does not claim Chroma provides.

The `pyproject.toml` classifier marks the Python package as `Development Status :: 3 - Alpha`. This is an upstream self-assessment of API stability, not a comment on production readiness for specific use cases. Teams adopting Zvec should pin to a specific version rather than tracking the latest release, and review the release notes before upgrading. The v0.6.0 and v0.7.0 releases, shipped in July and August 2026, both included new index types, which suggests the API surface is still evolving.

The last push was on 2026-09-26. The repository is not archived. The project is developed by the Zvec Core Team at Alibaba (contact: [email protected]).

Editorial conclusion

Zvec is the right choice when you want similarity search embedded in your application process without running a separate database server. The in-process design eliminates network round-trips and simplifies deployment, but it comes with a concrete constraint: writes are single-process exclusive, so a multi-process write workload requires a different tool. Python users on 32-bit interpreters are not supported; the `pyproject.toml` supports only 64-bit Python 3.10 through 3.14. The Apache 2.0 license permits commercial use without restriction. The last push was on 2026-09-26 and v0.7.0 shipped on 2026-08-24, so the project is in active development.

Frequently asked questions

What is Zvec?

Zvec is an in-process vector database from Alibaba that runs as a library inside your application rather than as a separate server. It supports dense and sparse vector search, full-text search, and hybrid queries, and ships SDKs for Python, Node.js, Go, Rust, and Dart.

What is a vector database and how does it work?

A vector database stores numerical vector representations of data and retrieves the vectors most similar to a query vector using approximate nearest neighbor algorithms such as HNSW. Zvec specifically runs in-process, meaning it operates inside the application without a separate server, and supports supplementing vector search with full-text and scalar filters in a single query.

How do I install Zvec for Python?

Run pip install zvec. The package requires a 64-bit Python interpreter version 3.10 through 3.14. 32-bit interpreters are not supported.

Does Zvec support writing from multiple processes at the same time?

No. Multiple processes can read the same Zvec collection simultaneously, but writes are single-process exclusive. An application that needs concurrent writes from separate processes requires a different architecture.

Official sources

  1. alibaba/zvec on GitHub
  2. License: Apache-2.0
  3. Project website
  4. README
  5. Releases
For maintainers

Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/alibaba-zvec.svg)](https://hysenlabs.com/projects/alibaba-zvec)
Community notes

Community notes