You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
CREATE VECTOR INDEX ... quantization='ternary' | 'opq' is accepted by the DDL parser and implied by docs, but no query path serves these codecs: the rerank gating returns RerankError::BadInput, and the ANN path warns 'no match' then proceeds with the actual codec. Advertised capability is unreachable.
Steps to reproduce
CREATE a vector index with quantization = 'ternary' (accepted), then run any search using it — rerank gating errors BadInput; ANN path substitutes silently. (static verification at the pin; runtime repro pending)
Expected behavior
Either the codecs are served end-to-end, or DDL/docs reject them explicitly until implemented.
Actual behavior
Parser/docs advertise; gating rejects (BadInput); ANN warns and substitutes.
What actually happened? (severity facts)
Acknowledged/committed data was lost, corrupted, or silently wrong
The server crashed, hung, or failed to start
A security or isolation boundary was crossed
Core functionality is broken with no acceptable workaround
Reproduced on a released tag or current main build (pending) — code path verified at e235fe55c.
This is not a security vulnerability.
Additional evidence (origin/main @ e235fe55c)
What:parse_quantization accepts "ternary"/"opq" (vector_primary.rs:430-431, listed in VALID_QUANTIZATIONS:21-23); docs/vectors.md and nodedb-codec/README.md list them as tiers. map_collection_quant returns RerankError::BadInput for both (gating.rs:141,147) and quantization_matches maps them to false (vector_search_ann.rs:75).
Impact: a user creates a collection/index with quantization='ternary' (accepted at DDL), then a search with the same hint fails with BadInput, or (via the SQL ANN hint path) silently proceeds with a different codec after a warning. The advertised capability is unreachable.
Fix (claim direction): remove ternary/opq from the parser grammar and docs until HNSW integration exists, or wire the codecs through end to end.
Prior-art:#25 (closed by PR [#27](fix(pgwire): wire quantization params through CREATE/ALTER VECTOR INDEX DDL #27)) made PQ reachable from SQL; it did not cover ternary/opq, which remain parser-accepted but unroutable. No open issue covers it.
Why: users can declare quantization='ternary'|'opq' in DDL and read docs implying support, but no query path serves the codec (rerank gating returns BadInput; the ANN hint merely warns and proceeds with the actual codec).
Steps to test: create an index with quantization = 'ternary', run any search -> rerank path errors BadInput (gating.rs); ANN path warns and substitutes. Either back the codecs or reject them at DDL.
Version / build tested against
origin/main @ e235fe5 (2026-09-29)
Deployment mode
Origin — single node (local)
Engine(s) involved
Vector
Summary
CREATE VECTOR INDEX ... quantization='ternary' | 'opq'is accepted by the DDL parser and implied by docs, but no query path serves these codecs: the rerank gating returnsRerankError::BadInput, and the ANN path warns 'no match' then proceeds with the actual codec. Advertised capability is unreachable.Steps to reproduce
CREATE a vector index with
quantization = 'ternary'(accepted), then run any search using it — rerank gating errorsBadInput; ANN path substitutes silently. (static verification at the pin; runtime repro pending)Expected behavior
Either the codecs are served end-to-end, or DDL/docs reject them explicitly until implemented.
Actual behavior
Parser/docs advertise; gating rejects (
BadInput); ANN warns and substitutes.What actually happened? (severity facts)
Proposed severity
SEV-3 — Medium: advertised feature unusable; workaround exists.
Reproducibility
Always — every attempt
Last known-good version / commit (if a regression)
(unknown / not a regression)
Environment & logs
Linux x86_64; Verified by static code reading at the pin above; runtime reproduction pending.
Code references:
Before submitting
mainbuild (pending) — code path verified ate235fe55c.Additional evidence (origin/main @
e235fe55c)parse_quantizationaccepts"ternary"/"opq"(vector_primary.rs:430-431, listed inVALID_QUANTIZATIONS:21-23);docs/vectors.mdandnodedb-codec/README.mdlist them as tiers.map_collection_quantreturnsRerankError::BadInputfor both (gating.rs:141,147) andquantization_matchesmaps them tofalse(vector_search_ann.rs:75).nodedb-sql/src/ddl_ast/parse/vector_primary.rs:426-431;nodedb-vector/src/rerank/gating.rs:141,147;nodedb/src/data/executor/handlers/vector_search_ann.rs:75;docs/vectors.md:18,20,77,141,145;nodedb-codec/README.md:5.quantization='ternary'(accepted at DDL), then a search with the same hint fails withBadInput, or (via the SQL ANN hint path) silently proceeds with a different codec after a warning. The advertised capability is unreachable.ternary/opqfrom the parser grammar and docs until HNSW integration exists, or wire the codecs through end to end.ternary/opq, which remain parser-accepted but unroutable. No open issue covers it.Why: users can declare
quantization='ternary'|'opq'in DDL and read docs implying support, but no query path serves the codec (rerank gating returnsBadInput; the ANN hint merely warns and proceeds with the actual codec).Steps to test: create an index with
quantization = 'ternary', run any search -> rerank path errorsBadInput(gating.rs); ANN path warns and substitutes. Either back the codecs or reject them at DDL.