Фильтр прокрутки клиента Qdrant не работает ⇐ Python
-
Гость
Фильтр прокрутки клиента Qdrant не работает
I'm using Qdrant database through its Python client. I need to find entries in the database that have some metadata field set to a certain value (without using vector similarity). I'm trying to do it this way:
from qdrant_client.http import models condition = models.FieldCondition(key="field_name", match=models.MatchValue(value="some_value")) scroll_filter = models.Filter(must=[condition]) results = client.scroll(collection_name="my_collection", scroll_filter=scroll_filter) I know that there are points that have metadata "field_name=some_value", but the response is ([], None) no matter what I try. Is there a way to query the database based on metadata only?
(Note: client.scroll(collection_name="my_collection") indeed returns results, some of them having the required key/value pair in the metadata. It's the filter that doesn't seem to work.)
Источник: https://stackoverflow.com/questions/781 ... s-not-work
I'm using Qdrant database through its Python client. I need to find entries in the database that have some metadata field set to a certain value (without using vector similarity). I'm trying to do it this way:
from qdrant_client.http import models condition = models.FieldCondition(key="field_name", match=models.MatchValue(value="some_value")) scroll_filter = models.Filter(must=[condition]) results = client.scroll(collection_name="my_collection", scroll_filter=scroll_filter) I know that there are points that have metadata "field_name=some_value", but the response is ([], None) no matter what I try. Is there a way to query the database based on metadata only?
(Note: client.scroll(collection_name="my_collection") indeed returns results, some of them having the required key/value pair in the metadata. It's the filter that doesn't seem to work.)
Источник: https://stackoverflow.com/questions/781 ... s-not-work