query()
:
top_k
: the number of results to return.n_probes
: the number of clusters to search for each query vector.filters
: metadata filters to apply to the query (dictionary format).include
: item fields to return (e.g., ["distance", "metadata"]
).greedy
: whether to perform a greedy search (higher recall but slower).query()
:
age
field is greater than 18
, you can use the following filter:
age
field is greater than 18
. You can also use other comparison operators such as $lt
, $gte
, $lte
, $eq
, and $ne
.
For more details on metadata filters, see the Metadata Filtering guide.
embedding_model
during index creation, you can automatically generate embeddings for queries by providing query_contents
to the query()
call:
get()
, which retrieves and decrypts item added via upsert()
. For more details, see the Get Items guide.