HTTP client - answer_stream()
MoorchehEdgeApiClient.answer_stream() calls POST /answer/stream and yields raw response bytes (SSE chunks). Use this when you need token-by-token output; for a one-shot answer, use answer_text() or answer() instead.
The high-level MoorchehEdge SDK does not wrap streaming yet - use MoorchehEdgeApiClient directly.
_sse.iter_sse_events helper if you build tooling inside the package.
Optional prompts and history
Same optional fields asanswer_text():
SSE events
See API: Answer stream for themeta, token, done, and error event shapes.
When no passages are retrieved, you get one token event with I don’t have enough information to answer that question. then done with context_count: 0 - the LLM is not called.
Requirements
- Store must contain uploaded documents (text or vector mode).
- Ollama must be running with
qwen2.5:0.5b-instruct(usemoorcheh-edge up --with-llmon Linux).
Related
- API: Answer stream
- Python: answer_text()
- Voice server - streams through
/ask/streamon edge hardware