mirror of
https://github.com/qdrant/landing_page.git
synced 2026-10-02 01:18:30 +02:00
fix filtering example
This commit is contained in:
@@ -115,7 +115,7 @@ client.upsert(
|
|||||||
|
|
||||||
## Retrieve data via filters
|
## Retrieve data via filters
|
||||||
|
|
||||||
The access control setup is completed as you specify the criteria for data retrieval. When searching for vectors, you need to use a `query_filter` along with `group_id` to filter vectors for each user. Additionally specifying the `shard_key_selector` will look for data in the region of your choosing. In this case, your query is based on `user_1` and data dedicated to the Canadian region.
|
The access control setup is completed as you specify the criteria for data retrieval. When searching for vectors, you need to use a `query_filter` along with `group_id` to filter vectors for each user.
|
||||||
|
|
||||||
```python
|
```python
|
||||||
client.search(
|
client.search(
|
||||||
@@ -128,12 +128,6 @@ client.search(
|
|||||||
value="user_1",
|
value="user_1",
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
models.FieldCondition(
|
|
||||||
key="shard_key_selector",
|
|
||||||
match=models.MatchValue(
|
|
||||||
value="canada"
|
|
||||||
,)
|
|
||||||
),
|
|
||||||
]
|
]
|
||||||
),
|
),
|
||||||
query_vector=[0.1, 0.1, 0.9],
|
query_vector=[0.1, 0.1, 0.9],
|
||||||
|
|||||||
Reference in New Issue
Block a user