Search
Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Body
collection_idsinteger[] · max: 100OptionalDefault:
List of collections ID.
[]document_idsinteger[] · max: 100OptionalDefault:
List of document IDs
[]metadata_filtersany of · nullableOptional
Metadata filters to apply to the search.
or
limitinteger · max: 100OptionalDefault:
Number of results to return.
10offsetintegerOptionalDefault:
Offset for pagination, specifying how many results to skip from the beginning.
0methodstring · enumOptionalDefault:
Search method to use.
semanticPossible values: rff_kinteger · max: 16384OptionalDefault:
Smoothing constant for Reciprocal Rank Fusion (RRF) algorithm in hybrid search (recommended: from 10 to 100).
60score_thresholdnumber · max: 1OptionalDefault:
Score of cosine similarity threshold for filtering results, only available for semantic search method.
0querystring · min: 1 · nullableOptional
Query related to the search.
Other propertiesanyOptional
Responses
200
Successful Response
application/json
objectconst: listOptionalDefault:
The type of the object.
listOther propertiesanyOptional
422
Validation Error
application/json
post/v1/search
POST /v1/search HTTP/1.1
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 264
{
"collection_ids": [
1
],
"document_ids": [
1
],
"metadata_filters": {
"key": "text",
"type": "eq",
"value": "text",
"ANY_ADDITIONAL_PROPERTY": "anything"
},
"limit": 10,
"offset": 0,
"method": "semantic",
"rff_k": 60,
"score_threshold": 0,
"query": "text",
"ANY_ADDITIONAL_PROPERTY": "anything"
}{
"object": "list",
"data": [
{
"method": "hybrid",
"score": 1,
"chunk": {
"object": "chunk",
"id": 1,
"collection_id": 1,
"document_id": 1,
"content": "text",
"metadata": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"created": 1,
"ANY_ADDITIONAL_PROPERTY": "anything"
},
"ANY_ADDITIONAL_PROPERTY": "anything"
}
],
"ANY_ADDITIONAL_PROPERTY": "anything"
}Last updated
Was this helpful?