SearchRequest

@Serializable
data class SearchRequest(val prefetch: List<Prefetch>? = null, val query: QueryInterface? = null, val using: String? = null, val filter: Filter? = null, val limit: Int? = null, val offset: Int? = null, val withPayload: WithPayload? = null, val withVector: Boolean? = null, val scoreThreshold: Double? = null, val params: SearchParams? = null, val lookupFrom: LookupLocation? = null)

Request body for POST /collections/{name}/points/query.

A request carries a query (what to do with the candidates), optional prefetch sub-requests (fetched first, then combined/reranked by query — the basis of hybrid search), or both.

Constructors

Link copied to clipboard
constructor(prefetch: List<Prefetch>? = null, query: QueryInterface? = null, using: String? = null, filter: Filter? = null, limit: Int? = null, offset: Int? = null, withPayload: WithPayload? = null, withVector: Boolean? = null, scoreThreshold: Double? = null, params: SearchParams? = null, lookupFrom: LookupLocation? = null)

Properties

Link copied to clipboard
@SerialName(value = "filter")
val filter: Filter?
Link copied to clipboard
@SerialName(value = "limit")
val limit: Int?
Link copied to clipboard
@SerialName(value = "lookup_from")
val lookupFrom: LookupLocation?

Where to look up vectors for a query-by-id (another collection and optional vector name).

Link copied to clipboard
@SerialName(value = "offset")
val offset: Int?
Link copied to clipboard
@SerialName(value = "params")
val params: SearchParams?
Link copied to clipboard
@SerialName(value = "prefetch")
val prefetch: List<Prefetch>?

Sub-requests fetched first; query then combines or reranks their results.

Link copied to clipboard
@SerialName(value = "query")
val query: QueryInterface?

What to do with the candidates: nearest vector/id, fusion, order-by, sample, ...

Link copied to clipboard
@SerialName(value = "score_threshold")
val scoreThreshold: Double?
Link copied to clipboard
@SerialName(value = "using")
val using: String?

Name of the vector to search when the collection has named vectors.

Link copied to clipboard
@SerialName(value = "with_payload")
val withPayload: WithPayload?
Link copied to clipboard
@SerialName(value = "with_vector")
val withVector: Boolean?