2026-10-16

Flat cosine index

  • Replaced the library stub with vector_store.metric.cosineSimilarity and vector_store.flat.FlatIndex.

  • add appends a row. searchTopK ranks by cosine similarity and breaks ties toward the lower row index.

  • The binary file starts with magic HYBRIDVS, then version, dimension, and count. Version 1 stores float32 rows. Version 2 stores a min/max pair and uint8 scalar-quantized values, expanded back to float32 on load.

  • Public imports live in vector_store (package.d).