专注于内存效率的轻量级向量搜索库
Spheni
A lightweight vector search library focused on memory-efficient approximate nearest neighbor search.
The goal of Spheni is to be focused on memory efficiency rather than accuracy, and act a candidate generation system.
It implements inverted indexing and product quantization with residual encoding to reduce memory usage while supporting fast similarity search.
With Cohere 1M Embeddings, the current benchmark reports up to 213.9x compression (13.69 MB index at M=8) and up to 94.20% Recall@10-in-100 (M=64, nprobe=32), with the baseline at 80.1x compression and 83.25% Recall@10-in-100 (M=32, nprobe=32).
train, add, searchRequirements:
Quick build
chmod +x build.sh
./build.shAfter building, this repository produces build/libspheni.a. You only need the public header (include/spheni.h) and the static library (libspheni.a) to consume Spheni in another project.
Usage
g++ -std=c++20 -O3 main.cpp -I /path/to/spheni/include /path/to/libspheni.a -o mainCheck out examples/ folder for more.
…Detailed public API documentation is available in docs/api-reference.md.
Current Benchmark Report (single-core run, 200 queries, Recall@k-in-100).
Legacy Report is also available.
save/load for seralized dataPapers
Blogs
暂无开放 Issues,或尚未同步最近议题。