Defines a search operation using a query vector.
| JSON representation |
|---|
{ "searchField": string, "filter": { object }, "outputFields": { object ( |
| Fields | |
|---|---|
searchField |
Required. The vector field to search. |
filter |
Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, represented as a google.protobuf.Struct. |
outputFields |
Optional. Mask specifying which fields to return. |
searchHint |
Optional. Sets the search hint. If no strategy is specified, the service will use an index if one is available, and fall back to the default KNN search otherwise. |
distanceMetric |
Optional. The distance metric to use for the KNN search. If not specified, DOT_PRODUCT will be used as the default. |
Union field
|
|
vector |
A dense vector for the query. |
sparseVector |
A sparse vector for the query. |
topK |
Optional. The number of nearest neighbors to return. |