pub fn require_non_empty_response<T>(
items: Vec<T>,
) -> Result<Vec<T>, CompletionError>Expand description
require_non_empty with the shared response-direction rejection — the
one-line guard for a provider decode whose converted choice is empty.
Pairing the guard with EMPTY_RESPONSE_ERROR here keeps the wording
from forking per wire. A decode with a legal empty case (anthropic’s
documented empty end_turn) branches around the guard for that case and
still routes every other empty through it.