SearchHint

Represents a hint to the search index engine.

JSON representation
{

  // The following is a list of mutually exclusive fields. At most one of the
  // fields will be set in a response:
  "useIndex": {
    object (IndexHint)
  },
  "useKnn": boolean,
  "knnHint": {
    object (KnnHint)
  },
  "indexHint": {
    object (IndexHint)
  }
  // End of mutually exclusive fields.
}
Fields
The type of index to use. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response:
useIndex
(deprecated)

object (IndexHint)

Optional. Deprecated: Use indexHint instead. Specifies that the search should use a particular index.

useKnn
(deprecated)

boolean

Optional. Deprecated: Use knnHint instead. If set to true, the search will use the system's default K-Nearest Neighbor (KNN) index engine.

knnHint

object (KnnHint)

Optional. If set, the search will use the system's default K-Nearest Neighbor (KNN) index engine.

indexHint

object (IndexHint)

Optional. Specifies that the search should use a particular index.

End of mutually exclusive fields.

IndexHint

Message to specify the index to use for the search.

JSON representation
{
  "name": string,

  // The following is a list of mutually exclusive fields. At most one of the
  // fields will be set in a response:
  "denseScannParams": {
    object (DenseScannParams)
  }
  // End of mutually exclusive fields.
}
Fields
name

string

Required. The resource name of the index to use for the search. The index must be in the same project, location, and collection. Format: projects/{project}/locations/{location}/collections/{collection}/indexes/{index}

The parameters for the index. The following is a list of mutually exclusive fields. At most one of the fields will be set in a response:
denseScannParams

object (DenseScannParams)

Optional. Dense ScaNN parameters.

End of mutually exclusive fields.

DenseScannParams

Parameters for dense ScaNN.

JSON representation
{
  "searchLeavesPct": integer,
  "initialCandidateCount": integer,
  "targetRecall": number
}
Fields
searchLeavesPct

integer

Optional. Dense ANN param overrides to control recall and latency. The percentage of leaves to search, in the range [0, 100]. Not supported for STORAGE_OPTIMIZED indexes. Cannot be set together with targetRecall.

initialCandidateCount

integer

Optional. The number of initial candidates. Must be a positive integer (> 0). Not supported for STORAGE_OPTIMIZED indexes. Cannot be set together with targetRecall.

targetRecall

number

Optional. The target recall for the search. Must be a double in the range [0, 1]. While the search aims to achieve this level of recall, it is not guaranteed.

KnnHint

This type has no fields.

KnnHint will be used if search should be explicitly done on system's default K-Nearest Neighbor (KNN) index engine.