pub enum SerdesAiError {
Show 15 variants
AgentRun(AgentRunError),
ModelRetry(ModelRetry),
ModelApi(ModelApiError),
ModelHttp(ModelHttpError),
User(UserError),
UsageLimit(UsageLimitExceeded),
UnexpectedBehavior(UnexpectedModelBehavior),
ToolRetry(ToolRetryError),
ApprovalRequired(ApprovalRequired),
CallDeferred(CallDeferred),
IncompleteToolCall(IncompleteToolCall),
FallbackGroup(FallbackExceptionGroup),
Serialization(Error),
Configuration(String),
Internal(String),
}Expand description
The main error type for serdes-ai operations.
Variants§
AgentRun(AgentRunError)
Error during agent execution.
ModelRetry(ModelRetry)
Model requested a retry.
ModelApi(ModelApiError)
API error from the model provider.
ModelHttp(ModelHttpError)
HTTP-level error.
User(UserError)
User-defined error from tools or validators.
UsageLimit(UsageLimitExceeded)
Usage limits exceeded.
UnexpectedBehavior(UnexpectedModelBehavior)
Unexpected model behavior.
ToolRetry(ToolRetryError)
Tool requested a retry.
ApprovalRequired(ApprovalRequired)
Tool requires user approval.
CallDeferred(CallDeferred)
Tool call was deferred.
IncompleteToolCall(IncompleteToolCall)
Incomplete tool call from model.
FallbackGroup(FallbackExceptionGroup)
Multiple errors occurred.
Serialization(Error)
Serialization/deserialization error.
Configuration(String)
Configuration error.
Internal(String)
Internal error.
Trait Implementations§
Source§impl Debug for SerdesAiError
impl Debug for SerdesAiError
Source§impl Display for SerdesAiError
impl Display for SerdesAiError
Source§impl Error for SerdesAiError
impl Error for SerdesAiError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl From<AgentRunError> for SerdesAiError
impl From<AgentRunError> for SerdesAiError
Source§fn from(source: AgentRunError) -> Self
fn from(source: AgentRunError) -> Self
Converts to this type from the input type.
Source§impl From<ApprovalRequired> for SerdesAiError
impl From<ApprovalRequired> for SerdesAiError
Source§fn from(source: ApprovalRequired) -> Self
fn from(source: ApprovalRequired) -> Self
Converts to this type from the input type.
Source§impl From<CallDeferred> for SerdesAiError
impl From<CallDeferred> for SerdesAiError
Source§fn from(source: CallDeferred) -> Self
fn from(source: CallDeferred) -> Self
Converts to this type from the input type.
Source§impl From<Error> for SerdesAiError
impl From<Error> for SerdesAiError
Source§impl From<FallbackExceptionGroup> for SerdesAiError
impl From<FallbackExceptionGroup> for SerdesAiError
Source§fn from(source: FallbackExceptionGroup) -> Self
fn from(source: FallbackExceptionGroup) -> Self
Converts to this type from the input type.
Source§impl From<IncompleteToolCall> for SerdesAiError
impl From<IncompleteToolCall> for SerdesAiError
Source§fn from(source: IncompleteToolCall) -> Self
fn from(source: IncompleteToolCall) -> Self
Converts to this type from the input type.
Source§impl From<ModelApiError> for SerdesAiError
impl From<ModelApiError> for SerdesAiError
Source§fn from(source: ModelApiError) -> Self
fn from(source: ModelApiError) -> Self
Converts to this type from the input type.
Source§impl From<ModelHttpError> for SerdesAiError
impl From<ModelHttpError> for SerdesAiError
Source§fn from(source: ModelHttpError) -> Self
fn from(source: ModelHttpError) -> Self
Converts to this type from the input type.
Source§impl From<ModelRetry> for SerdesAiError
impl From<ModelRetry> for SerdesAiError
Source§fn from(source: ModelRetry) -> Self
fn from(source: ModelRetry) -> Self
Converts to this type from the input type.
Source§impl From<ToolRetryError> for SerdesAiError
impl From<ToolRetryError> for SerdesAiError
Source§fn from(source: ToolRetryError) -> Self
fn from(source: ToolRetryError) -> Self
Converts to this type from the input type.
Source§impl From<UnexpectedModelBehavior> for SerdesAiError
impl From<UnexpectedModelBehavior> for SerdesAiError
Source§fn from(source: UnexpectedModelBehavior) -> Self
fn from(source: UnexpectedModelBehavior) -> Self
Converts to this type from the input type.
Source§impl From<UsageLimitExceeded> for SerdesAiError
impl From<UsageLimitExceeded> for SerdesAiError
Source§fn from(source: UsageLimitExceeded) -> Self
fn from(source: UsageLimitExceeded) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for SerdesAiError
impl !RefUnwindSafe for SerdesAiError
impl Send for SerdesAiError
impl Sync for SerdesAiError
impl Unpin for SerdesAiError
impl !UnwindSafe for SerdesAiError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more