ai.clients.Fallback
Streaming fallback advances in member order only for a typed, safely retryable failure that occurs before the first text delta is returned.
Reference version
Signature
class ai.clients.FallbackStreaming fallback advances in member order only for a typed, safely retryable failure that occurs before the first text delta is returned.
Source:<builtin>/ai/ns_clients/clients.bamlbytes 16030–20634
Fields
members
Instance methods
function
_try
() -> ai.ModelTurn throws baml.errors.Timeout | baml.errors.UnknownError | reflect.errors.CompilationError | ai.errors.Failure
Implementations
ai.Client for ai.clients.Fallback
Instance methods
function
id
(self) -> stringfunction
invoke
(self,
input: ai.ModelTurnInput
) -> ai.ModelTurn throws baml.errors.Timeout | baml.errors.UnknownError | reflect.errors.CompilationError | ai.errors.Failure
function
render
(self,
input: ai.ModelTurnInput
) -> baml.http.Request throws baml.errors.Timeout | baml.errors.UnknownError | reflect.errors.CompilationError | ai.errors.Failure
Rendering previews the first fallback member. It never probes later members because request construction itself must remain pure.
Source:<builtin>/ai/ns_clients/clients.bamlbytes 17239–18800
ai.stream.StreamingClient for ai.clients.Fallback
Instance methods
Source:<builtin>/ai/ns_clients/clients.bamlbytes 18806–20632