Skip to content

Float vectors are stored incorrectly #3827

@Nick-S-2018

Description

@Nick-S-2018

Bug Description:

If a table contains float vector fields with and without auto embeddings, the field without auto embedding is stored incorrectly:

mysql> CREATE TABLE test (title TEXT, vector FLOAT_VECTOR KNN_TYPE='hnsw' HNSW_SIMILARITY='l2' knn_dims='2');
mysql> INSERT INTO test(title, vector) values('a', (0.1,0.2) );
mysql> SELECT vector FROM test;
+-------------------+
| vector            |
+-------------------+
| 0.100000,0.200000 |
+-------------------+
mysql> DROP TABLE test;
mysql> CREATE TABLE test (title TEXT, vector FLOAT_VECTOR KNN_TYPE='hnsw' HNSW_SIMILARITY='l2' knn_dims='2', embedding_vector FLOAT_VECTOR KNN_TYPE='hnsw' HNSW_SIMILARITY='l2' MODEL_NAME='sentence-transformers/all-MiniLM-L6-v2' FROM='title');
mysql> INSERT INTO test(title, vector) values('a', (0.1,0.2) );
mysql> SELECT vector FROM test;
+----------+
| vector   |
+----------+
| 0.100000 |
+----------+

Manticore Search Version:

Manticore 13.13.4 0bc5a9641@25101507 dev (columnar 8.1.0 e1522a2@25100213) (secondary 8.1.0 e1522a2@25100213) (knn 8.1.0 e1522a2@25100213) (embeddings 1.0.1)

Operating System Version:

Ubuntu 22.04

Have you tried the latest development version?

Yes

Internal Checklist:

To be completed by the assignee. Check off tasks that have been completed or are not applicable.

  • Implementation completed
  • Tests developed
  • Documentation updated
  • Documentation reviewed

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions