robit-agent 0.1.1

Agent runtime, tool system, skill system, and frontend trait for robit.
Documentation
//! Error types for the robit-agent crate.

use thiserror::Error;

/// Unified error type for Agent operations.
#[derive(Debug, Error)]
pub enum AgentError {
    #[error(transparent)]
    LlmError(#[from] robit_ai::LlmError),

    #[error("Configuration error: {0}")]
    ConfigError(String),

    #[error("Tool execution error: {0}")]
    ToolError(String),

    #[error("Context overflow: current {current} tokens, max {max} tokens")]
    ContextOverflow { current: usize, max: usize },

    #[error("Agent internal error: {0}")]
    InternalError(String),
}

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