Filter

@Serializable
data class Filter(val must: List<Condition>? = null, val should: List<Condition>? = null, val mustNot: List<Condition>? = null, val minShould: MinShould? = null)

A Qdrant filter: four independent, combinable clauses. Each holds a list of Conditions and clauses can nest recursively (a condition can itself be a whole Filter — see Condition.Sub), so any boolean expression is expressible.

Request-only: filters are sent to Qdrant but never returned, so this type is serialized but does not round-trip (its Conditions cannot be deserialized).

Constructors

Link copied to clipboard
constructor(must: List<Condition>? = null, should: List<Condition>? = null, mustNot: List<Condition>? = null, minShould: MinShould? = null)

Properties

Link copied to clipboard
@SerialName(value = "min_should")
val minShould: MinShould?

At least MinShould.minCount of the given conditions must match.

Link copied to clipboard
@SerialName(value = "must")
val must: List<Condition>?

All conditions must match (AND).

Link copied to clipboard
@SerialName(value = "must_not")
val mustNot: List<Condition>?

No condition may match (NOR).

Link copied to clipboard
@SerialName(value = "should")
val should: List<Condition>?

At least one condition must match (OR).