Streams cited Markdown responses, sourced exclusively from corporate disclosures, as server-sent events in response to natural language queries. This endpoint provides real-time streaming of AI-generated answers, making it ideal for interactive chat interfaces where users can see responses as they’re generated.
Server-Sent Events (SSE) Structure:
event: thinking
- Agent’s thinking process with stage information
data: {"type": "message", "role": "assistant", "content": "...", "stage": "search"}
event: message
- Content chunks and warnings
data: {"type": "message", "role": "assistant", "content": "..."}
- Response content chunksdata: {"type": "warning", "message": "..."}
- Warning when no documents foundevent: message/partial
- Partial response content (streaming)
data: {"type": "message", "role": "assistant", "content": "..."}
event: metadata
- Source document information
data: {"type": "sources", "content": {"#ref_id": {"content": "...", "pageNumber": 123, "excerpt": "...", "documentMetadata": {"id": "...", "documentCategory": "...", "formType": "...", "tickers": ["..."], "companyName": "...", "date": "...", "fiscalQuarter": 1, "fiscalYear": 2025}}}}}
- Document sources and citationsevent: done
- Stream completion
data: {}
The natural language query
Stream started successfully
The response is of type any
.