Files

5 lines
425 B
SQL

-- The HNSW index the tests build on the chunk table (20,000 rows, 64 dimensions).
-- Hibernate's schema generator cannot create it (see output/08-failures.txt), so it lives in a migration like this one.
-- vector_cosine_ops must match the operator the queries use: cosine_distance(..) in HQL is "<=>" in SQL.
create index chunk_hnsw_cos on chunk using hnsw (embedding vector_cosine_ops) with (m = 16, ef_construction = 64);