Download Latest Version ruvector-core 2.3.0 + ruvector-extensions 0.1.2 -- Lattice embeddings, CVE cleanup source code.zip (126.0 MB)
Email in envelope

Get an email when there's a new version of RuVector

Home / ruvector-wasm-v0.1.31
Name Modified Size InfoDownloads / Week
Parent folder
@ruvector_wasm 0.1.31 -- corrected WASM adapter source code.tar.gz 2026-06-15 117.4 MB
@ruvector_wasm 0.1.31 -- corrected WASM adapter source code.zip 2026-06-15 124.5 MB
README.md 2026-06-15 1.6 kB
Totals: 3 Items   241.9 MB 0

@ruvector/wasm 0.1.31

Ships the RuvectorWasmAdapter (@ruvector/wasm/adapter) from [#568] and restores a functional published package — 0.1.30 had shipped with only package.json (empty pkg/); 0.1.31 includes the built web pkg/ (WASM + JS bindings) plus the adapter.

The adapter corrects three behaviours of the raw WASM build

  1. HNSW not active — the wasm32 target compiles without the hnsw feature and falls back to a flat (brute-force) index. The adapter surfaces this via indexType / WASM_HNSW_AVAILABLE instead of letting callers assume O(log n).
  2. score was a cosine distance (lower is better), contradicting the .d.ts. The adapter exposes a real similarity = 1 - distance (per-metric) so "higher is better" holds, with the raw distance preserved.
  3. Metadata did not round-tripsearch/get returned {}. The adapter keeps an in-process metadata sidecar keyed by id and re-attaches it on the way out.

Usage

:::js
import { RuvectorWasmAdapter } from '@ruvector/wasm/adapter';
const index = await RuvectorWasmAdapter.create({ dimensions: 384, metric: 'cosine' });
index.insert({ id: 'doc_1', vector: embedding, metadata: { title: 'My Document' } });
const results = index.search({ vector: query, k: 10 });
// results[i].similarity (higher better), .distance (raw), .metadata (round-trips), index.indexType ('flat')
Source: README.md, updated 2026-06-15