Agentic search over documents in a namespace.
When stream: true is set in the request, the response is returned as
Server-Sent Events (SSE).
The connection uses Content-Type: text/event-stream.
status - Progress updates during the search process.
event: status
data: {"message": "Searching documents..."}
result - Final search results (sent once at the end).
event: result
data: {"results": [...]}
event: status
data: {"message": "Mounting namespace with 150 documents..."}
event: status
data: {"message": "Searching for relevant documents..."}
event: status
data: {"message": "Analyzing document: SEC 10-K Filing 2023"}
event: result
data: {"results": [{"id": "doc_1", ...}]}
ID of the namespace to search within.
Search request parameters.
Natural-language search query. May include guidance about preferred sources or freshness.
Applies a retrieval strategy tailored to specific retrieval tasks.
"chronology" — Optimizes search for building timelines. Optimizes retrieval for constructing timelines by prioritizing temporally informative documents and adjusting ranking/recall defaults to surface a coherent sequence of events.
chronology Upper bound on the number of results to return.
Whether to stream the response as server-sent events.
Successful response. When stream: false (default), returns JSON.
When stream: true, returns Server-Sent Events.
Output for the Search API.
A list of SearchResult objects, ordered by decreasing relevance.