Skip to main content

Module error

Module error 

Source
Expand description

Error types and handling

Enums§

GuardrailPhase
Phase where a guardrail violation occurred.
LLMError
Error types that can occur when interacting with LLM providers.

Constants§

MAX_ERROR_BODY_DISPLAY_BYTES
Maximum bytes of a provider response body included in Display output.

Functions§

is_fallbackable
Default fallbackability predicate shared by the fallback layer.
is_http_status_retryable
Returns true when an HTTP status code represents a retryable server/transient error.
is_retryable
Default retryability predicate shared by the retry layer.
is_transport_retryable_message
Returns true when a transport error message represents a retryable failure.
truncate_for_display
Truncates a response body for safe inclusion in log-oriented display output.