ChatBackend
Produces one assistant turn as a cold stream of ChatEvents.
The flow is collected by ChatController; cancelling the collection (the user pressed stop) must cancel the underlying request. Failures are reported by throwing — the controller turns them into dev.ai.elements.core.model.ChatStatus.ERROR.
The history is the whole conversation so far, ending with the new user message.