Mid-Stream
If generation fails after the stream has begun, a chunk carries a top-levelerror and a terminal choice:
Content streamed before this chunk is partial. Treat the error chunk as the end of the stream:
[DONE] may not follow it.
Before the First Byte
A request rejected before any byte is written (auth, validation, limits) returns a normal HTTP error with the standard envelope. See Error format. A streaming client therefore handles two shapes: a non-200 response with a JSON body, and a 200 stream that later carries an error chunk.

