| Name | Type | Description |
|---|---|---|
query* | str | Text to look up documents similar to. |
k | int | Default: 4Number of Documents to return. |
fetch_k | int | Default: 20Number of Documents to fetch to pass to MMR algorithm. |
lambda_mult | float | Default: 0.5 |
filter | MetadataFilter | None | Default: None |
search_params | models.SearchParams | None | Default: None |
score_threshold | float | None | Default: None |
consistency | models.ReadConsistency | None | Default: None |
**kwargs | Any | Default: {} |
Return docs selected using the maximal marginal relevance.
Maximal marginal relevance optimizes for similarity to query AND diversity among selected documents.
Number between 0 and 1 that determines the degree
of diversity among the results with 0 corresponding
to maximum diversity and 1 to minimum diversity.
Filter by metadata.
Additional search params
Define a minimal score threshold for the result. If defined, less similar results will not be returned. Score of the returned result might be higher or smaller than the threshold depending on the Distance function used. E.g. for cosine similarity only higher scores will be returned.
Read consistency of the search. Defines how many replicas should be queried before returning the result. Values:
int - number of replicas to query, values should present in all
queried replicas'majority' - query all replicas, but return values present in the
majority of replicas'quorum' - query the majority of replicas, return values present in
all of them'all' - query all replicas, and return values present in all
replicasAny other named arguments to pass through to
AsyncQdrantClient.Search().