PlanetScale vectors now supports quantization
PlanetScale vectors now supports quantization. Quantization is a form of vector compression that allows your vector indexes to consume less space.
This change brings support for product_quantization
and fixed_quantization
. You can configure these for your indexes by specifying them in the SECONDARY_ENGINE_ATTRIBUTE
when creating your indexes. For example:
CREATE VECTOR INDEX embedding_index ON table_1(embedding) SECONDARY_ENGINE_ATTRIBUTE='{"type":"spann", "distance":"l2", "product_quantization":{"dimensions":96}}';
CREATE VECTOR INDEX embedding_index ON table_1(embedding) SECONDARY_ENGINE_ATTRIBUTE='{"type":"spann", "distance":"l2", "fixed_quantization":"bfloat16"}';
Learn more in our vectors documentation.