Interface: VectorFilterBuilder<Document, VectorIndexConfig>
server.VectorFilterBuilder
An interface for defining filters for vector searches.
This has a similar interface to FilterBuilder, which is used in database queries, but supports only the methods that can be efficiently done in a vector search.
Type parameters
| Name | Type |
|---|---|
Document | extends GenericDocument |
VectorIndexConfig | extends GenericVectorIndexConfig |
Methods
eq
▸ eq<FieldName>(fieldName, value): FilterExpression<boolean>
Is the field at fieldName equal to value
Type parameters
| Name | Type |
|---|---|
FieldName | extends string |
Parameters
| Name | Type |
|---|---|
fieldName | FieldName |
value | FieldTypeFromFieldPath<Document, FieldName> |
Returns
FilterExpression<boolean>
Defined in
or
▸ or(...exprs): FilterExpression<boolean>
exprs[0] || exprs[1] || ... || exprs[n]
Parameters
| Name | Type |
|---|---|
...exprs | FilterExpression<boolean>[] |
Returns
FilterExpression<boolean>