mirror of
https://github.com/hanzoai/python-sdk.git
synced 2026-10-27 04:20:09 +00:00
- Consolidate memory tools into single unified surface - Rename IChingTool → ZenTool across agent tools - Rename tool files: proc_tool→exec_tool, net_tool→fetch_tool, vcs_tool→git_tool, todo_tool→tasks_tool - Add hanzo_tool.py for unified Hanzo API surface - Add workspace_tool.py for config management - Add hanzo-tools-ui package with GitHub API integration - Add unified.py core tool dispatcher - Update IAM client to RFC-compliant OAuth endpoints - Fix pytest-asyncio plugin conflict: pin <1.0.0, fix addopts double-registration, and align test APIs to current signatures - Fix integration tests: PermissionManager API, ReviewProtocol focus values, AgentTool parameter names, mock llm module for CI
56 lines
1.2 KiB
Python
56 lines
1.2 KiB
Python
"""Todo tools for Hanzo MCP.
|
|
|
|
This package provides task management tools:
|
|
- TodoTool: Unified todo management with add, update, remove, list, clear operations
|
|
"""
|
|
|
|
from mcp.server import FastMCP
|
|
|
|
from hanzo_tools.core import BaseTool, ToolRegistry
|
|
from hanzo_tools.todo.base import TodoStorage, TodoBaseTool
|
|
from hanzo_tools.todo.tasks_tool import TasksTool
|
|
|
|
# Backward compat
|
|
TodoTool = TasksTool
|
|
|
|
__all__ = [
|
|
"TasksTool",
|
|
"TodoTool",
|
|
"TodoStorage",
|
|
"TodoBaseTool",
|
|
"get_todo_tools",
|
|
"register_todo_tools",
|
|
"TOOLS",
|
|
]
|
|
|
|
|
|
def get_todo_tools() -> list[BaseTool]:
|
|
"""Create instances of all todo tools.
|
|
|
|
Returns:
|
|
List of todo tool instances
|
|
"""
|
|
return [TasksTool()]
|
|
|
|
|
|
def register_todo_tools(
|
|
mcp_server: FastMCP,
|
|
enabled_tools: dict[str, bool] | None = None,
|
|
) -> list[BaseTool]:
|
|
"""Register todo tools with the MCP server.
|
|
|
|
Args:
|
|
mcp_server: The FastMCP server instance
|
|
enabled_tools: Dictionary of individual tool enable states (default: None)
|
|
|
|
Returns:
|
|
List of registered tools
|
|
"""
|
|
tools = get_todo_tools()
|
|
ToolRegistry.register_tools(mcp_server, tools)
|
|
return tools
|
|
|
|
|
|
# TOOLS list for entry point discovery
|
|
TOOLS = [TasksTool]
|