ai.clients.Retry
class in the ai package.
Signature
class ai.clients.RetrySource:<builtin>/ai/ns_clients/clients.bamlbytes 10942–16586
Fields
Static methods
new
(Instance methods
_attempt
(The safety gate is not overridable; the judgment is. retry_if judges
typed failures; a member timeout passes the gate and is always retried.
Implementations
ai.Client for ai.clients.Retry
Instance methods
default_cache_args
(self) -> baml.json.json throws neverThe args this client uses for a ${cache()} written with none (or
with null): the object its wire's cache marker carries. Null when the
client has no cache marker on its wire, or when the model it is
configured for would reject one; a ${cache()} then sends nothing.
A client that sends cache markers passes this to
ai.wire.prompt_parts(message, default_cache_args).
id
(self) -> string throws neverinvoke
(render
(Rendering is a pure preview of the inner client. It deliberately does not apply retry policy or backoff because no request is sent.
Source:<builtin>/ai/ns_clients/clients.bamlbytes 13337–14287
ai.stream.StreamingClient for ai.clients.Retry
Instance methods
Source:<builtin>/ai/ns_clients/clients.bamlbytes 14293–16584