Преглед изворни кода

add the index field for elasticsearch (#10592)

Jyong пре 5 месеци
родитељ
комит
0b2d51d859
1 измењених фајлова са 1 додато и 0 уклоњено
  1. 1 0
      api/core/rag/datasource/vdb/elasticsearch/elasticsearch_vector.py

+ 1 - 0
api/core/rag/datasource/vdb/elasticsearch/elasticsearch_vector.py

@@ -178,6 +178,7 @@ class ElasticSearchVector(BaseVector):
                         Field.VECTOR.value: {  # Make sure the dimension is correct here
                             "type": "dense_vector",
                             "dims": dim,
+                            "index": True,
                             "similarity": "cosine",
                         },
                         Field.METADATA_KEY.value: {