tool_loader
Auto-discover and load tools from a directory of Python scripts.
Each .py file in the tools directory must expose either:
Single-tool format (one tool per file):
TOOL_NAME– unique name for the tool (str).TOOL_DESCRIPTION– human-readable description (str).TOOL_PARAMETERS– JSON Schemaobjectfor accepted args (dict).async def run(**kwargs) -> str– the tool handler.
Multi-tool format (multiple tools per file):
TOOLS– a list of dicts, each with keys:name,description,parameters,handler.
Malformed files are logged as warnings but do not prevent the rest of the tools from loading.