Skip to content

Docs & Control-Flow Hardening - #795

Merged
ashvardanian merged 6 commits into
mainfrom
main-dev
Oct 5, 2026
Merged

ashvardanian merged 6 commits into
mainfrom
main-dev

Conversation

@ashvardanian

Copy link
Copy Markdown
Member

No description provided.

toyeshhm and others added 6 commits October 5, 2026 14:36
`ScalarKind` has no `B1x8` variant, so the binary example did not compile.
`view_from_buffer` is an unsafe API, and the cosine note used a similarity
formula with a missing parenthesis instead of the distance the enum documents.

Co-authored-by: Toyeshh Medikonda <[email protected]>
Co-authored-by: Ash Vardanian <[email protected]>
The brute-force path passed the packed byte count where binary metrics
expect bits, so exact distances on `b1` vectors were wrong. Convert that
count before constructing the metric, & lock it with a fixed-vector comparison.

Closes #527

Co-authored-by: Chi-Wei Lee <[email protected]>
Co-authored-by: Chi-Wei Lee <[email protected]>
Co-authored-by: Stefano Taverni <[email protected]>
Co-authored-by: Stefano Taverni <[email protected]>
Add GreptimeDB, KurrentDB, Chroma, MemMachine, Arm MCP, GPT4All, Ente,
Tracy, Copilot for Xcode, LLM for Unity, and Music Assistant.
Normalize the binding quickstarts so the snippets match the SDKs and run.
`compact()` moves every member to a new slot and moves the vectors with it,
but `slot_lookup_` and `free_keys_` kept the old slots. `get(key)` then
returned another member's vector, and the next `add` reused a slot that was
live again. Search still worked because the nodes carry their own keys.

Rebuild both structures with `reindex_keys_()`, as `load()` and `view()`
already do.

Co-authored-by: Vividh Yadav <[email protected]>
GCC ignores every update after a comma in an `omp simd` reduction.
Split those sums so a `bf16` vector stays nearest to itself.
The `i8` and `u8` cosine fallbacks returned distance 0 when the dot product was 0.
Match the NumKong tail so an orthogonal vector cannot outrank the query.
@ashvardanian
ashvardanian merged commit 295485b into main Oct 5, 2026
29 checks passed
xet7 pushed a commit to xet7/usearch that referenced this pull request Nov 12, 2026
The 2.x line released v2.25.2 through v2.26.6 after 3.0 branched at
v2.25.1, and its public main ends at 33d3ab6. Installs place headers
under GNUInstallDirs' include directory (14f9807, unum-cloud#800), the README
lists the integrations 2.x added (0fd2f32, unum-cloud#795), and CONTRIBUTING
states the commit conventions in place of stale links (06ad060, unum-cloud#748).

Its correctness fixes already hold on 3.0's code:

- Keys move with their entries when `compact` permutes slots
  (0a4baa6, unum-cloud#795), and the insert-only key table never rehashes
  (1633e25, unum-cloud#822; 9d77be5, unum-cloud#759)
- File loads bound every column slice from the header (9c25176, unum-cloud#824;
  64d10d8, unum-cloud#776), and allocation sizes are checked (89da7c5, unum-cloud#763)
- JavaScript keys are range-checked (b65a420, unum-cloud#812), Go filters ride
  `cgo.Handle`s (ad77fe7, unum-cloud#825), `splitmix64_t` survives `windows.h`
  (0f1c5f2, unum-cloud#806), and integer key hashes mix with SplitMix64
  (9fc3500, unum-cloud#773)
- C install targets and relocatable pkg-config (4160e47, 679e190,
  unum-cloud#800), the GIL released in long calls (d8be67d, unum-cloud#764), and graph
  cursors in C and Rust (55c43f7, unum-cloud#748)

Thread-context reserves, tombstones, renames, `change_metric`, OpenMP
metrics and hand-written BF16 casts are absent from 3.0, so their
fixes have nothing to land on. The Rust `compact()` binding (749d03b,
unum-cloud#771) waits for all bindings to wrap `usearch_dense_compact`.

The README's performance lead now quotes the SIFT 100M rows at 99%
recall on a B300 and on 192 Graviton5 cores beside FAISS HNSW, and
the verification notes link ForkUnion's `main`.

The sibling pins move to the libraries' own merges with their released
lines, so this line builds against them.

Co-Authored-By: Jonathan Ringer <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants