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
Long story short, I'm accidentally running pgvetor 0.3-alpha and the app I'm using (immich) requires 0.2. I have not run into any issues apart from creating this index:
CREATE INDEX IF NOT EXISTS face_index ON asset_faces
USING hnsw (embedding vector_cosine_ops)
WITH (ef_construction = 300, m = 16);
where I get the error access method "hnsw" does not exist.
Indeed it does not exist:
SELECT amname AS index_method FROM pg_am WHERE amtype = 'i'
index_method:
btree
hash
gist
gin
spgist
brin
vectors
I've tried SET vectors.pgvector_compatibility=on too.
How do I create this index access method? Thank you
The text was updated successfully, but these errors were encountered:
Hello, thanks for your report.
Yes, the access method hnsw does not exist in pgvecto.rs.
We support it by vectors.pgvector_compatibility and rewrite hnsw to vectors internally.
This feature requires SET vectors.pgvector_compatibility=on in current session.
Do you set it in the same session of CREATE INDEX like:
postgres=# CREATE TABLE t (val vector(3));
CREATE TABLE
postgres=# INSERT INTO t (val) SELECT ARRAY[random(), random(), random()]::real[] FROM generate_series(1, 1000);
INSERT 01000
postgres=# CREATE INDEX hnsw_l2_index ON t USING hnsw (val vector_l2_ops);
ERROR: access method "hnsw" does not exist
postgres=# SET vectors.pgvector_compatibility=on;SET
postgres=# CREATE INDEX hnsw_l2_index ON t USING hnsw (val vector_l2_ops);
CREATE INDEX
postgres=#
Or ALTER SYSTEM SET vectors.pgvector_compatibility=on may help you to set it globally.
If that not worked, could you please show us some steps to reproduce?
Hi,
Long story short, I'm accidentally running pgvetor 0.3-alpha and the app I'm using (immich) requires 0.2. I have not run into any issues apart from creating this index:
where I get the error
access method "hnsw" does not exist.
Indeed it does not exist:
index_method:
btree
hash
gist
gin
spgist
brin
vectors
I've tried
SET vectors.pgvector_compatibility=on
too.How do I create this index access method? Thank you
The text was updated successfully, but these errors were encountered: