Skip to main content

VecLite: A production-grade, zero-config, single-file embedded AI memory engine

Project description

VecLite

CI Crates.io PyPI Go Reference License: MIT

VecLite is an embedded vector database. It runs in-process and stores data in a single file.

It provides exact and approximate nearest neighbor search, metadata filtering, and a vector-native SQL dialect. It is designed for applications that require vector search without operating a separate database server.

Features

  • Embedded architecture (no server required)
  • Single-file storage
  • SIMD-accelerated vector metrics (Cosine, L2, Dot Product, Manhattan)
  • HNSW indexing
  • SQL query layer
  • Hybrid search (vector similarity combined with metadata filters)
  • Cross-language support via C ABI

Language Bindings

VecLite is written in Rust. It provides native bindings for multiple languages.

Rust

The core database.

  • Status: Stable
  • Install: cargo add veclite-db

Python

Native Python module using PyO3. Releases the Global Interpreter Lock (GIL) during search operations.

  • Status: Stable
  • Install: pip install veclite-db

Go

CGO wrapper over the C ABI.

  • Status: Stable
  • Install: go get github.com/rithulkamesh/veclite/bindings/go@v1.0.5

C / C++

Standard C header and C++ RAII wrapper.

  • Status: Stable
  • Install: Copy bindings/c/veclite.h or bindings/cpp/veclite.hpp.

Zig

Zig wrapper over the C ABI.

  • Status: Experimental
  • Install: Import bindings/zig/veclite.zig.

Example

use veclite_db::VecLite;

let mut db = VecLite::open("memory.vec").unwrap();
db.insert("doc_1", vec![0.1, 0.2, 0.3], None).unwrap();

let results = db.search(vec![0.1, 0.2, 0.3]).top_k(5).execute().unwrap();

SQL Example

VecLite supports a custom SQL dialect for vector operations.

CREATE TABLE memory;
INSERT INTO memory VALUES ('doc_1', '[0.1, 0.2, 0.3]', '{"tag":"note"}');
SELECT * FROM memory WHERE metadata.tag = 'note' ORDER BY vector <-> '[0.1, 0.2, 0.3]' LIMIT 5;

Installation

Use the package manager for your target language. For the CLI and HTTP server:

cargo install veclite-cli

Status

VecLite is under active development.

Roadmap

  • SQL execution engine completion
  • Compaction and retention policies
  • Node.js bindings

License

MIT

Star History

Star History Chart

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

veclite_db-1.0.7-cp38-abi3-win_amd64.whl (290.2 kB view details)

Uploaded CPython 3.8+Windows x86-64

veclite_db-1.0.7-cp38-abi3-manylinux_2_34_x86_64.whl (527.6 kB view details)

Uploaded CPython 3.8+manylinux: glibc 2.34+ x86-64

veclite_db-1.0.7-cp38-abi3-macosx_11_0_arm64.whl (406.4 kB view details)

Uploaded CPython 3.8+macOS 11.0+ ARM64

File details

Details for the file veclite_db-1.0.7-cp38-abi3-win_amd64.whl.

File metadata

  • Download URL: veclite_db-1.0.7-cp38-abi3-win_amd64.whl
  • Upload date:
  • Size: 290.2 kB
  • Tags: CPython 3.8+, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for veclite_db-1.0.7-cp38-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 17422b6fca9f90227b8de00075e17d6b871deb79d7e5f0ad28f1712d09346945
MD5 3b145eea8e6b8cd95c6b37aa0e6e9f4f
BLAKE2b-256 a4b6aaf3cd5f96fa4b517b4c1f96bc1e4d61d37dc3db9f3bd071990d2cb36919

See more details on using hashes here.

Provenance

The following attestation bundles were made for veclite_db-1.0.7-cp38-abi3-win_amd64.whl:

Publisher: publish-pypi.yml on rithulkamesh/veclite

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file veclite_db-1.0.7-cp38-abi3-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for veclite_db-1.0.7-cp38-abi3-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 9b4c563789cfe727d0144814716a94051d805d631ce06c6740b1978c3446fcf7
MD5 b69ff2ae6fd54996ffb5abbcfa1ec6b9
BLAKE2b-256 3860927e43dafd65b486cc064d629744a78c59421641c5d5924d348fe58cfe55

See more details on using hashes here.

Provenance

The following attestation bundles were made for veclite_db-1.0.7-cp38-abi3-manylinux_2_34_x86_64.whl:

Publisher: publish-pypi.yml on rithulkamesh/veclite

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file veclite_db-1.0.7-cp38-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for veclite_db-1.0.7-cp38-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 620b7ddd638a5ae92ed95dd219b18b14bd4b2bc4fed24abd0b0fa81783a14a2f
MD5 cea5ae13258dae1ccf3cb1c242cef2b7
BLAKE2b-256 4d2aed89a09691e7719936388ef6e552afe95a48c98dfe6a3c0d6b4f306e7d3b

See more details on using hashes here.

Provenance

The following attestation bundles were made for veclite_db-1.0.7-cp38-abi3-macosx_11_0_arm64.whl:

Publisher: publish-pypi.yml on rithulkamesh/veclite

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page