POST
/v1/knowledge-base/files/searchSearch knowledge base files by vector similarity
Searches knowledge base files using vector similarity. Supply knowledgeBaseFileIds and a 768-value queryEmbedding; use limit and similarityThreshold to control the results.
- IdempotentThe SDK sends
Idempotency-Key, so a retried request is only applied once.
Vector search criteria for the knowledge base.
knowledgeBaseFileIdsarray<string>required
The identifiers of the knowledge base files to search.
limitintegeroptional
The maximum number of results to return. Must be between 1 and 100; defaults to 5 when omitted.
queryEmbeddingarray<number>required
The numeric embedding to search with. Must contain exactly 768 values.
similarityThresholdnumberoptional
The minimum similarity score for returned results. Must be between 0 and 1.
200Returns the results of the vector similarity search.
Error handling
knowledgeBaseFileIds and queryEmbedding are required. queryEmbedding must contain exactly 768 numeric values; limit must be between 1 and 100 and defaults to 5, and similarityThreshold must be between 0 and 1 when supplied.