C++ / Storage / Vector Search

AtlasVector

AtlasVector is a C++20 mutable vector-search engine built around an in-house approximate-nearest-neighbour graph, mmap-backed storage, SIMD distance kernels, durable mutations, and atomic compaction.

  • C++20
  • ANN
  • mmap
  • ARM NEON
  • gRPC

Measured Results

1,514

Queries per second on the tuned 100K-vector graph.

98.3%

Recall@10 against the exact-search ground truth.

3.05×

Speedup over AtlasVector’s exact top-100 scan.

4.52×

NEON distance speedup over optimized strict C++.

96.62%

Product-quantization payload compression.

Why I built it

Vector databases look simple at the API boundary, but the difficult work sits underneath: balancing recall and speed, keeping writes durable, serving reads during compaction, laying data out for the operating system, and proving every optimization against a baseline.

AtlasVector keeps those internals visible. The graph, WAL, mapped segment, SIMD dispatch, and publication rules are all part of one inspectable engine rather than hidden behind an external service.

System Diagram

AtlasVector API, query coordinator, WAL, mutable segment, mapped graph, and compaction

How a query works

1

Snapshot fresh state

The coordinator snapshots mutable vectors and tombstones so newly acknowledged writes are immediately query-visible.

2

Traverse the mapped graph

Multi-entry best-first search explores promising neighbours while SIMD kernels compute vector distances.

3

Merge generations

Exact mutable candidates and ANN persisted candidates are merged, with stale IDs and tombstoned records removed.

4

Return one ranked result

The unified candidate set is sorted by distance, filtered, and truncated to the requested top-k.

Key engineering choices

Durability before visibility

Each mutation is framed, checksummed, and fsynced before it is applied to memory, preserving one recovery order.

Immutable search generations

Compaction builds outside the query path and atomically publishes a validated segment through a versioned manifest.

Optimize only with evidence

Scalar, compiler-vectorized, and explicit SIMD kernels share equivalence tests and reproducible microbenchmarks.

Boundaries

AtlasVector is a single-node storage engine, not a claim of parity with a production distributed database. The mapped benchmark is page-cache-backed, compaction rewrites one full segment, and the PQ result describes compressed payload rather than total process memory because full vectors remain resident for reranking.

Hire me!

You still here?

It’s over

Karan Bhaskar