Dsml.StreamSourceDecode a completion as it is generated, token by token, emitting reasoning and content text as it arrives and tool calls once each block completes. This is the primitive an interactive agent feeds with model output.
type event = | Reasoning of stringa chunk of <think> reasoning
| Content of stringa chunk of reply text
*)| Tool_call of tool_calla completed tool call
*)| Doneend of turn (EOS reached)
*)A piece of decoded output.
An incremental decoder.
create mode is a fresh decoder.
feed d chunk decodes the next chunk of generated text, in order. Partial markers spanning chunk boundaries are held back until complete.