from __future__ import annotations


class AgentError(Exception):
    def __init__(self, code: str, stage: str, message: str):
        super().__init__(message)
        self.code = code
        self.stage = stage
        self.message = message


class ValidationError(AgentError):
    pass


class ToolExecutionError(AgentError):
    pass
