sayr-engine 0.3.0

A high-performance Rust AI agent runtime inspired by the Agno framework
Documentation
use thiserror::Error;

pub type Result<T> = std::result::Result<T, AgnoError>;

#[derive(Debug, Error)]
pub enum AgnoError {
    #[error("tool `{0}` not found")]
    ToolNotFound(String),

    #[error("tool `{name}` invocation failed: {source}")]
    ToolInvocation {
        name: String,
        #[source]
        source: Box<dyn std::error::Error + Send + Sync>,
    },

    #[error("language model error: {0}")]
    LanguageModel(String),

    #[error("protocol error: {0}")]
    Protocol(String),

    #[error("storage error: {0}")]
    Storage(String),

    #[error(transparent)]
    Serde(#[from] serde_json::Error),

    #[error(transparent)]
    Io(#[from] std::io::Error),

    #[error("telemetry error: {0}")]
    Telemetry(String),

    #[error("MCP error: {0}")]
    Mcp(String),
}