|
Download artifacts/wiki-vector-bench/README.md from SpecStreamAI/web-infrastructure-papers-2026: direct link, hf CLI and curl.
- Browser
- Download file 1.14 kB
-
https://huggingface.co/datasets/SpecStreamAI/web-infrastructure-papers-2026/resolve/main/artifacts/wiki-vector-bench/README.md
- Command line
-
hf download hf://datasets/SpecStreamAI/web-infrastructure-papers-2026/artifacts/wiki-vector-bench/README.md
-
curl -L -o README.md https://huggingface.co/datasets/SpecStreamAI/web-infrastructure-papers-2026/resolve/main/artifacts/wiki-vector-bench/README.md
1.14 kB
Binary Hamming + Int8 Rescore Vector Retrieval Benchmark
Clean, standalone C + Python reproduction benchmark accompanying SpecStream's engineering paper: "Millisecond semantic retrieval over 47 million Wikipedia paragraphs in 6 GB of RAM" Canonical paper: https://specstream.ai/blog/millisecond-semantic-retrieval-47m-wikipedia-6gb-ram
What this benchmark demonstrates
At 47,018,430 paragraphs x 1,024 dimensions (BAAI/bge-m3, from Upstash/wikipedia-2024-06-bge-m3):
- Raw
float32: 192.59 GB (179.36 GiB) - Stage 1 binary sign bits (
128 B/vec, 16 xuint64_tlittle-endian): 6.018 GB (5.605 GiB), 32x RAM compression,mlock()pinned in RAM - Stage 2 scalar
int8(1,024 B/vec,clip(round(v * 127), -127, 127)): 48.147 GB (44.840 GiB),mmap()on local NVMe, read only for the topcandHamming candidates (default 3,000 = 3.07 MB read per query)
Build and run
make
python3 bench.py --n 1000000 --dim 1024 --cand 3000 --k 10 --queries 20
Set --n to match available RAM (1,000,000 vectors = 128 MB binary + 1 GB int8; 10,000,000 vectors = 1.28 GB binary + 10 GB int8).
License
MIT