Skip to main content

Error

Defined in the error module.
Rust AI Agent SDK Main error type for PraisonAI Core

Fields

NameTypeDescription
Agentvariant-
relatedvariant-
errorsvariant-
errorvariantAgent-related errors
AgentvariantAgent-related errors
errorvariantAgent-related errors
0variantAgent-related errors

Methods

agent

fn agent(msg: impl Into<String>) -> Self
Create an agent error Parameters:
NameType
msgimpl Into&lt;String&gt;

tool

fn tool(msg: impl Into<String>) -> Self
Create a tool error Parameters:
NameType
msgimpl Into&lt;String&gt;

llm

fn llm(msg: impl Into<String>) -> Self
Create an LLM error Parameters:
NameType
msgimpl Into&lt;String&gt;

memory

fn memory(msg: impl Into<String>) -> Self
Create a memory error Parameters:
NameType
msgimpl Into&lt;String&gt;

workflow

fn workflow(msg: impl Into<String>) -> Self
Create a workflow error Parameters:
NameType
msgimpl Into&lt;String&gt;

config

fn config(msg: impl Into<String>) -> Self
Create a config error Parameters:
NameType
msgimpl Into&lt;String&gt;

io

fn io(msg: impl Into<String>) -> Self
Create an IO error from a string message Parameters:
NameType
msgimpl Into&lt;String&gt;

handoff

fn handoff(msg: impl Into<String>) -> Self
Create a handoff error Parameters:
NameType
msgimpl Into&lt;String&gt;

with_context

fn with_context(self, context: impl Into<String>) -> Self
Add context to an error Parameters:
NameType
contextimpl Into&lt;String&gt;

Source

View on GitHub

praisonai/src/error.rs at line 0

Rust Error Handling

Rust Retry

Rust Failover