Stevenic/vectra

Vectra is a local vector database for Node.js with features similar to pinecone but built using local files.

What it solves

Vectra provides a lightweight, local way to store and search high-dimensional vectors (embeddings) without needing a heavy external database server. It allows developers to maintain a file-backed index on disk while keeping queries fast through in-memory operations, making it ideal for local-first applications or small-to-medium scale datasets.

How it works

It functions as a local vector database where each index is stored as a folder on disk. It supports cosine similarity ranking for searches and MongoDB-style metadata filtering to narrow down results. To handle embeddings, it can connect to external APIs like OpenAI or run models locally using HuggingFace via LocalEmbeddings and TransformersEmbeddings. For cross-language support, it includes an optional gRPC server that exposes 19 RPCs, allowing other languages to interact with the index.

Who it’s for

Developers building local AI applications, RAG (Retrieval-Augmented Generation) pipelines, or browser-based tools (via IndexedDB support) who need a simple, file-based vector storage solution.

Highlights

  • Local-first design: File-backed storage with in-memory performance and sub-millisecond latency for small indexes.
  • Flexible Embeddings: Supports both cloud APIs and local HuggingFace models for privacy and offline use.
  • Cross-platform: Works in Node.js, the browser, and Electron apps.
  • Extensible Access: Includes a gRPC server and generated language bindings for 6 different languages.
  • Automated Sync: Features a FolderWatcher to automatically sync local directories into a document index.

Related

  • Project
  • Project
  • Project
  • Project
  • Project