Open source · Two engines · Written in Go · v0.1.3

Vector search you embed in Go or serve to any language.

Two engines in one Go module — a vector search engine and a sub-microsecond key-value store.

One Go module — usable together or entirely on their own.
curl -fsSL https://rostamlabs.com/install.sh | sh
Run the server View on GitHub

Or docker run ghcr.io/rostamlabs/rostam · pip install rostam-client · Python quickstart →

Building in Go? Skip the server entirely — go get github.com/rostamlabs/rostam embeds both engines in your binary, no server and no cgo. The embedded path →

Benchmarks

~2× Milvus. ~4× Qdrant. Measured by someone else's harness.

Under VectorDBBench — a third-party harness, maintained by the company behind Milvus — on Cohere-1M (768d, cosine). Six engines, one continuous session, with HNSW build parameters pinned identically on every engine. Every run is reproducible from rostam-bench →

At 0.97 matched recall
2,642 QPS

2.02× Milvus · 2.18× pgvector · 4.16× Qdrant

Load, 1M × 768d
282 s

fastest in the set, least total CPU of any multi-core engine

Highest recall measured
0.9978

the lead holds across the whole curve, not at one point

KV GET, over the wire
726k ops/s

ahead of Memcached, Dragonfly and Aerospike at 64+ conns; RF=2 replicated writes 113.6k/s vs Aerospike 85.9k at 128 conns, replica-ack both sides

Read at matched recall — engines land at different recall for the same ef, so equal ef is not equal work. Every number is same-session, because this hardware drifts up to 42% between sessions on unchanged code, and the benchmark client shares the box, which penalises the fastest engine hardest — so these are floors, not ceilings. Full per-ef curves, the filter case, three paired A/B controls and the complete methodology, including where the data cuts against Rostam, are in rostam-bench/vectordbbench; the key-value comparison, run the same way over the wire against seven engines, is in rostam-bench/netkv.

And inside the engine

SQ8 recall@10 vs exact
≈ 0.98

at 4× smaller

Binary quantization
32×

smaller — recall@10 ≈ 0.96 rescored

AVX2 int8 distance kernel
~2.9–3.3×

faster than scalar

Filter-first planner
0

recall cliff on selective filtered search

Measured with make bench on the same 12-core AMD EPYC Genoa server — directional, not a marketing sheet.

Run it as a server

Any language can call it. Python gets a client.

Start the server once, then call it over REST, gRPC, or a binary TCP protocol — from any language that speaks HTTP. Python gets a first-party, dependency-free client — it pools connections and sends searches over a binary wire, falling back to JSON against older servers (with optional LangChain, LlamaIndex, and Haystack adapters); everything else talks plain REST or gRPC.

1

Install and start the server

curl -fsSL https://rostamlabs.com/install.sh | sh
rostam-server -http 127.0.0.1:8080 -data ./data

That serves REST. Add -grpc 127.0.0.1:9090 and -tcp 127.0.0.1:7000 to serve gRPC and the binary TCP protocol from the same store — a write on any transport is visible on the others, and setting a transport's flag to "" disables it.

The installer verifies the release checksum before installing into ~/.local/bin — add that to your PATH if it is not there already. Prefer a container? docker run -p 127.0.0.1:8080:8080 -e ROSTAM_API_KEY=secret ghcr.io/rostamlabs/rostam:latest — auth is required there, because inside the container it binds a reachable address, so add -H 'Authorization: Bearer secret' to the calls below.

2

Call it from any language

curl localhost:8080/v1/collections -d '{"name":"docs","config":{"dim":4,"metric":"cosine"}}'
curl localhost:8080/v1/collections/docs/points -d '{"id":1,"vector":[0.1,0.2,0.3,0.4],"content":"hello"}'
curl localhost:8080/v1/collections/docs/points/search -d '{"query":[0.1,0.2,0.3,0.4],"k":3}'

Plain REST over HTTP — or gRPC. Any client works: JavaScript, Rust, Java, curl.

3

Or use the first-party Python client

pip install rostam-client

On PyPI as rostam-client.

See the Python quickstart ↓
  • Clustering — per-shard Raft replication with online resharding.
  • Auth — RBAC, JWT, and mTLS.
  • TLS end to end.
  • S3 backups and Prometheus metrics.

Quickstart

First results in a minute.

Create a collection, insert vectors with metadata, and run an exact filtered search — call a running server from Python, or embed the engine directly in Go.

Python client is stdlib-only, with optional LangChain / LlamaIndex / Haystack integrations.

The vector engine

Three indexes, quantization, hybrid and filters — one import.

  • hnsw · ivf · vamana

    Three indexes

    HNSW graphs, IVF centroids, and Vamana — pick the index that fits each workload, mmap-resident.

  • sq8 · bq1 · pq · prq

    Quantization

    From SQ8 at 4× smaller to binary at 32× — quantized codes stay mmap-resident, off the heap.

  • rrf · weighted · dbsf

    Hybrid retrieval

    Dense + sparse fusion resolved in a single query, with BM25 full-text search built in.

  • filter-first

    Exact filtering

    Metadata filters run through an exact filter-first query planner — no recall cliff.

  • mmr · recommend · discover

    Beyond kNN

    MMR diversification, recommendation, and discovery retrieval for RAG pipelines.

  • tenants · quotas · ttl

    Multi-tenancy

    Per-tenant isolation with quotas, TTL, and a payload index for fast metadata filters.

  • avx2

    Vectorized kernels

    The AVX2 int8 distance kernel runs ~2.9–3.3× faster than scalar code (VNNI adds ~1.3× on top).

  • cuda

    GPU, optional

    An optional CUDA build moves the exact-KNN scan onto the GPU when you have one.

  • pure go

    Embeddable

    A pure-Go library — no server, no cgo, no dependencies. Or run it as a server.

Filtered search

No recall cliff on selective filters.

Selective metadata filters are where approximate search quietly falls apart. Rostam plans filtered queries exactly: the payload index narrows candidates first, then search runs over what actually matches — so recall holds as filters get sharper.

query plan
  1. payload indexresolve tenant = "acme"
  2. filter-firstexact candidate set — nothing approximated away
  3. searchtop-k over the matches · 0 recall cliff

Deployment

Embed it. Serve it. Shard it.

Embedded

Import the engine as a pure-Go library — no server, no cgo, no dependencies. Search runs inside your binary.

import ".../rostam/vector"

Server

Run it as a service and reach it from any language — see the server + Python guide above for the full protocol and auth story.

REST · gRPC · binary TCP

Cluster

Scale out with per-shard Raft replication and online resharding — grow without rewriting your application.

per-shard Raft · online resharding

The second engine

A key-value store that answers in nanoseconds.

The same module ships a sub-microsecond KV store behind one Store interface — Direct in-process (the fastest), Embedded with per-shard Raft replication, or Client over TCP to a running cluster. Same API throughout.

~29ns Get (hit) — Direct, in-process, 0 allocs
Key-value store latency measurements
OperationLatency
Get (hit) — Direct, in-process~29 ns · 0 allocs
Put — Direct~240 ns
Get — TCP loopback (Direct server)~1.7 µs
Put — TCP loopback (Direct server)~1.8 µs

Measured with make bench on the same 12-core AMD EPYC Genoa server as the comparisons above — except the loopback rows, which come from a multi-queue host, because that box's NIC has a single queue and would measure the adapter rather than the storage path. Directional, not a marketing sheet.

  • Atomic server-side ops

    Read-modify-write under the shard lock — no CAS loops.

  • WASM stored procedures

    Sandboxed and fuel-capped — run your logic next to the data.

  • Replicated & resharded online

    Per-shard Raft, online resharding — served over REST, gRPC, and binary TCP.