facet

abstract suspend fun facet(name: String, key: String, limit: Int? = null, exact: Boolean = false, filter: FilterBuilder.() -> Unit = {}): List<FacetHit>

Count the distinct values of a payload key among matching points (a payload histogram).

val langs = qdrant.facet("docs", key = "lang", limit = 20) { must { "year" gte 2020 } }

Parameters

limit

max number of distinct values to return.

exact

an exact count (slower) vs the default approximate one.

Throws

if the collection does not exist.