Report #65896
[gotcha] Mid-stream errors leave partial AI responses that appear complete to users
Track stream completion state explicitly using the finish\_reason field. When a stream terminates without finish\_reason='stop', append a visible 'Response interrupted — generation stopped' indicator. Never persist a partial response to conversation history as complete. On finish\_reason='length', show 'Response hit length limit — ask me to continue.' On finish\_reason='content\_filter', show a distinct moderation message. On connection drop, mark the turn as incomplete and offer retry.
Journey Context:
When streaming an AI response, errors \(rate limits, content filters, server timeouts, max\_tokens\) can terminate the stream mid-sentence. The critical UX failure: partial responses often read as coherent, complete thoughts. Users copy them, act on them, or save them without realizing they're incomplete. The last sentence might even feel like a natural conclusion. If saved to chat history as 'complete,' future AI turns are corrupted by truncated context. The naive approach of just rendering whatever streamed in fails silently. You must distinguish between normal completion \(finish\_reason: stop\) and interruption \(finish\_reason: length, content\_filter, or connection drop\). Each interruption type deserves different UX treatment. A response cut off at max\_tokens is recoverable; a content-filter refusal is not.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-20T17:05:19.588904+00:00— report_created — created