Spaces:
Running
Running
File size: 1,451 Bytes
75bea1c | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 | """Custom exceptions for the Ask-the-Web Agent."""
class AskTheWebError(Exception):
"""Base exception for Ask-the-Web Agent."""
pass
class ConfigurationError(AskTheWebError):
"""Configuration-related errors."""
pass
class LLMError(AskTheWebError):
"""LLM-related errors."""
pass
class LLMConnectionError(LLMError):
"""LLM connection failed."""
pass
class LLMRateLimitError(LLMError):
"""LLM rate limit exceeded."""
pass
class LLMResponseError(LLMError):
"""Invalid LLM response."""
pass
class ToolError(AskTheWebError):
"""Tool-related errors."""
pass
class ToolNotFoundError(ToolError):
"""Tool not found in registry."""
pass
class ToolExecutionError(ToolError):
"""Tool execution failed."""
pass
class ToolTimeoutError(ToolError):
"""Tool execution timed out."""
pass
class SearchError(ToolError):
"""Search-related errors."""
pass
class SearchNoResultsError(SearchError):
"""Search returned no results."""
pass
class ScrapingError(ToolError):
"""Web scraping errors."""
pass
class AgentError(AskTheWebError):
"""Agent-related errors."""
pass
class MaxIterationsError(AgentError):
"""Maximum iterations reached."""
pass
class PlanningError(AgentError):
"""Workflow planning failed."""
pass
class SynthesisError(AgentError):
"""Response synthesis failed."""
pass
|