Expand description
In-core implementations of the VectorCodec plane: Fp32, Fp16, Int8,
and the Turbo4 adapter over ruvector-turboquant (ADR-297 §1).
Fp32/Fp16/Int8 score by decoding — they are the verification / hot tiers, where fidelity matters more than per-candidate cost. Turbo4 scores directly on packed codes (never reconstructs), as required by ADR-296.
Structs§
- Fp16
Codec - IEEE 754 binary16: 2 bytes/dim. Hot-tier codec (~1e-3 relative error).
Conversion is implemented in-crate (no
halfdependency) with round-to-nearest-even, matching hardware semantics. - Fp32
Codec - Identity codec: 4 bytes/dim, exact. The verification anchor of the plane.
- Int8
Codec - Per-vector min/scale uniform int8:
[min f32 | scale f32 | D bytes]. Same scheme as the legacyScalarQuantized, but blob-oriented so the plane can move it around like any other representation. - Turbo4
Plane Codec VectorCodecadapter overruvector_turboquant::Turbo4Codec— scores on packed codes, never reconstructs (ADR-296).
Functions§
- f16_
bits_ to_ f32 - binary16 bits → f32 (exact).
- f32_
to_ f16_ bits - f32 → binary16 bits, round-to-nearest-even; overflow → ±inf.