use thiserror::Error;
#[derive(Debug, Error)]
pub enum Error {
#[error("config error: {0}")]
Config(#[from] crate::config::ConfigError),
#[error("fetcher error: {0}")]
Fetcher(#[from] crate::fetcher::FetcherError),
#[error("extractor error: {0}")]
Extractor(#[from] crate::extractor::ExtractorError),
#[error("storage error: {0}")]
Storage(#[from] crate::storage::StorageError),
#[error("tokenizer error: {0}")]
Tokenizer(#[from] crate::tokenizer::TokenizerError),
#[error("mcp error: {0}")]
Mcp(#[from] crate::mcp::McpError),
#[error("io error: {0}")]
Io(#[from] std::io::Error),
}
pub type Result<T> = std::result::Result<T, Error>;