turboquant-wasm 0.2.1 → 0.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -5
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
# TurboQuant WASM
|
|
2
2
|
|
|
3
|
-
[](https://github.com/teamchong/turboquant-wasm/actions/workflows/ci.yml)
|
|
4
|
+
[](https://www.npmjs.com/package/turboquant-wasm)
|
|
5
|
+
[](https://www.npmjs.com/package/turboquant-wasm)
|
|
5
6
|
[](https://github.com/teamchong/turboquant-wasm/blob/main/LICENSE)
|
|
6
7
|
|
|
7
8
|
WASM + relaxed SIMD build of [botirk38/turboquant](https://github.com/botirk38/turboquant) for browsers and Node.js.
|
|
8
9
|
|
|
9
|
-
Based on the paper "TurboQuant: Online Vector Quantization with Near-optimal Distortion Rate".
|
|
10
|
+
Based on the paper ["TurboQuant: Online Vector Quantization with Near-optimal Distortion Rate"](https://arxiv.org/abs/2504.19874) (Google Research, ICLR 2026).
|
|
10
11
|
|
|
11
12
|
## What this adds
|
|
12
13
|
|
|
@@ -34,7 +35,7 @@ import { TurboQuant } from "turboquant-wasm";
|
|
|
34
35
|
|
|
35
36
|
const tq = await TurboQuant.init({ dim: 1024, seed: 42 });
|
|
36
37
|
|
|
37
|
-
// Compress a vector (~
|
|
38
|
+
// Compress a vector (~4.5 bits/dim, ~6x compression)
|
|
38
39
|
const compressed = tq.encode(myFloat32Array);
|
|
39
40
|
|
|
40
41
|
// Decode back
|
|
@@ -85,7 +86,7 @@ Encoding preserves inner products — verified by golden-value tests and distort
|
|
|
85
86
|
## Credits
|
|
86
87
|
|
|
87
88
|
- [botirk38/turboquant](https://github.com/botirk38/turboquant) — original Zig implementation
|
|
88
|
-
-
|
|
89
|
+
- [TurboQuant paper](https://arxiv.org/abs/2504.19874) (Google Research, ICLR 2026) — algorithm design
|
|
89
90
|
|
|
90
91
|
## License
|
|
91
92
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "turboquant-wasm",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.3",
|
|
4
4
|
"description": "TurboQuant WASM SIMD vector compression — 3 bits/dim with fast dot product. Requires relaxed SIMD (Chrome 114+, Firefox 128+, Safari 18+, Node 20+)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
"type": "git",
|
|
47
47
|
"url": "git+https://github.com/teamchong/turboquant-wasm.git"
|
|
48
48
|
},
|
|
49
|
-
"homepage": "https://github.
|
|
49
|
+
"homepage": "https://teamchong.github.io/turboquant-wasm/",
|
|
50
50
|
"author": "Steven Chong",
|
|
51
51
|
"license": "MIT",
|
|
52
52
|
"devDependencies": {
|