LLM-readable documentation index

Search a Collection

Hand off to an LLM

Run a vector/keyword search against a collection and return the raw retrieval hits (distinct, best match first). Uses the same retrieval as an enrich step — semantic, hybrid (weighted Reciprocal Rank Fusion), or exact — but does NOT apply the LLM re-rank that a full enrich step layers on top.

POST
/v3/collections/search
x-api-key<token>

Authenticate using API Key in request header

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X POST "https://api.bem.ai/v3/collections/search" \  -H "Content-Type: application/json" \  -d '{    "collectionName": "string",    "query": "string"  }'
{
  "collectionName": "string",
  "searchMode": "string",
  "results": [
    {
      "data": "string",
      "cosineDistance": 0.1,
      "hybridScore": 0.1,
      "rank": 0,
      "confidence": 0.1,
      "reasoning": "string"
    }
  ]
}
Empty
Empty

See also