fn classify_tool_error(tool_name: &str, err: Error) -> AppErrorExpand description
Inspects tool execution errors and maps them to the most appropriate
HTTP status code. This allows built-in tools to signal client errors
(e.g. empty query → 400, document not found → 404) without needing
a custom error type in the Tool trait.