whatisgithub

What is zvec?

alibaba/zvec — explained in plain English

Analysis updated 2026-06-24

9,722C++Audience · developerComplexity · 3/5LicenseSetup · easy

In one sentence

Zvec is an embeddable vector database from Alibaba that you add to your Python or Node.js app like a library, no server to run, for fast similarity search and AI-powered memory features.

Mindmap

mindmap
  root((zvec))
    What It Does
      Store AI vectors
      Similarity search
      No external server
    Vector Types
      Dense vectors
      Sparse vectors
      Hybrid search
    Use Cases
      Semantic search
      RAG chatbot memory
      Embedding lookup
    Tech
      Python pip install
      Node.js package
      Disk persistence
    Platforms
      Linux macOS Windows
      Python 3.10 to 3.14
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Add semantic search to a Python app by storing and querying AI-generated embeddings with a single pip install.

USE CASE 2

Build a retrieval-augmented generation system where an AI looks up relevant documents before answering a question.

USE CASE 3

Store and search millions of vectors in a Node.js app without running or managing a separate database server.

USE CASE 4

Combine vector similarity search with structured field filters for hybrid AI-powered search in one query.

What is it built with?

PythonC++Node.js

How does it compare?

alibaba/zvecdiasurgical/devilutionxcxasm/notepad--
Stars9,7229,4859,469
LanguageC++C++C++
Setup difficultyeasyeasymoderate
Complexity3/52/52/5
Audiencedevelopergeneralgeneral

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · easy Time to first run · 30min

Works on Python 3.10-3.14, install via pip with no external services or servers required.

Free to use, modify, and distribute including for commercial purposes, as long as you keep the copyright and license notice.

So what is it?

Zvec is an open-source vector database from Alibaba that runs inside your application rather than as a separate server. A vector database stores and searches data by mathematical similarity rather than by exact keyword matches, which is how AI-powered search and memory systems find relevant content. Zvec is designed to be embedded directly into Python scripts, Node.js applications, notebooks, or any other program without requiring any external infrastructure to install or configure. The main thing Zvec does is let you store lists of numbers called vectors, which are typically generated by AI models to represent text, images, or other content as a numerical description. Once stored, you can search for the closest matches to a new vector very quickly, even across collections of millions or billions of items. This is the underlying mechanism behind features like semantic search, AI chat memory, and retrieval-augmented generation, where an AI looks up relevant documents before answering a question. Zvec supports both dense vectors, which are the standard fixed-length arrays produced by most AI embedding models, and sparse vectors, which are used by keyword-based approaches. You can combine both in a single query for hybrid search. It also supports filtering by structured fields alongside vector similarity, so you can search for the most similar items that also match specific conditions. Data is persisted to disk with write-ahead logging, meaning nothing is lost if the process crashes. Multiple processes can read the same data at the same time, though only one process can write at a time. The Python package installs with a single pip command and works on Python 3.10 through 3.14. A Node.js package is also available. Zvec runs on Linux, macOS, and Windows. It is released under the Apache 2.0 license and was battle-tested inside Alibaba before being open-sourced.

Copy-paste prompts

Prompt 1
Using Zvec in Python, show me how to store 1000 text embeddings from OpenAI and run a similarity search to find the 5 most semantically relevant results.
Prompt 2
I want to build a RAG chatbot using Zvec. How do I embed my documents, store them in Zvec, and query the closest matches before sending context to an LLM?
Prompt 3
Help me set up hybrid search in Zvec that combines dense vector similarity with a filter on a category field so I only get results from a specific topic.
Prompt 4
I'm using Zvec in a multi-process Python app. Explain the read and write concurrency rules and how to safely handle simultaneous access from multiple processes.

Frequently asked questions

What is zvec?

Zvec is an embeddable vector database from Alibaba that you add to your Python or Node.js app like a library, no server to run, for fast similarity search and AI-powered memory features.

What language is zvec written in?

Mainly C++. The stack also includes Python, C++, Node.js.

What license does zvec use?

Free to use, modify, and distribute including for commercial purposes, as long as you keep the copyright and license notice.

How hard is zvec to set up?

Setup difficulty is rated easy, with roughly 30min to a first successful run.

Who is zvec for?

Mainly developer.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.