feat: add high-performance HNSW RaBitQ index - #1
Draft
CLiqing wants to merge 1 commit into
Draft
Conversation
CLiqing
force-pushed
the
codex/pr-hnsw-rabitq
branch
2 times, most recently
from
August 27, 2026 09:45
5defc9d to
e778c24
Compare
Introduce HNSW_RABITQ with 1-9 bit database codes, request-local query quantization, optional refinement, and round-trip serialization. Use a dense-packed multi-bit layout and optimized scalar, AVX2, AVX-512, and Sapphire Rapids single/batch-4 distance kernels with BMI2 runtime gating. Add correctness tests and microbenchmarks for the public index and SIMD paths. Signed-off-by: ChenLiqing <23721160+CLiqing@users.noreply.github.com>
CLiqing
force-pushed
the
codex/pr-hnsw-rabitq
branch
from
August 28, 2026 02:15
e778c24 to
aae6c99
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this PR does
Adds an end-to-end
HNSW_RABITQindex to Knowhere together with the embedded Faiss RaBitQ kernels required for competitive graph-search performance.Scope and limitations
This PR is intentionally scoped to HNSW. The dense-packed layout is selected by
HNSW_RABITQ; DiskANN and IVF integration are not included.The initial implementation does not support cosine, scalar partition builds, mmap, incremental add after construction, or direct graph construction from RaBitQ code-to-code distances.
Validation
[hnsw_rabitq]: 6 test cases, 377,568 assertions passedRaBitQ*: 16 SIMD correctness tests passedknowhere_teststarget built successfully on the latestmain(a337f6a7)