mirror of
https://github.com/hanzoai/python-sdk.git
synced 2026-10-27 04:20:09 +00:00
- Add hanzo-tools-code: code analysis and transformation tools - Add hanzo-tools-net: network and HTTP tools - Add hanzo-tools-plan: planning and task management tools - Add hanzo-tools-test: testing tools - Add hanzo-tools-vcs: version control tools - Add install command for dependency management - Improve CDP bridge server with better error handling - Add ui_tool for computer tools - Add unified tool loading and id_tool - Add HIP documentation (HIP-0300, HIP-0301)
57 lines
1.3 KiB
Python
57 lines
1.3 KiB
Python
"""Plan orchestration tools for Hanzo AI (HIP-0300).
|
|
|
|
Tools:
|
|
- plan: Unified orchestration tool (HIP-0300)
|
|
- intent: Parse NL → IntentIR
|
|
- route: IntentIR → Plan (canonical chain)
|
|
- compose: Plan → ExecGraph
|
|
- chains: List available canonical chains
|
|
|
|
This is the "permissive input → strict output" layer.
|
|
Turns natural language into canonical operator chains.
|
|
|
|
Effect lattice position: PURE
|
|
All operations are safe to cache and parallelize.
|
|
|
|
Install:
|
|
pip install hanzo-tools-plan
|
|
|
|
Usage:
|
|
from hanzo_tools.plan import register_tools, TOOLS
|
|
|
|
# Register with MCP server
|
|
register_tools(mcp_server)
|
|
|
|
# Or access the unified tool
|
|
from hanzo_tools.plan import PlanTool
|
|
"""
|
|
|
|
from hanzo_tools.core import BaseTool, ToolRegistry
|
|
|
|
from .plan_tool import PlanTool, plan_tool
|
|
|
|
# Export list for tool discovery - HIP-0300 unified tool
|
|
TOOLS = [PlanTool]
|
|
|
|
__all__ = [
|
|
"PlanTool",
|
|
"plan_tool",
|
|
"register_tools",
|
|
"TOOLS",
|
|
]
|
|
|
|
|
|
def register_tools(mcp_server, **kwargs) -> list[BaseTool]:
|
|
"""Register plan tools with the MCP server.
|
|
|
|
Args:
|
|
mcp_server: The FastMCP server instance
|
|
**kwargs: Additional options
|
|
|
|
Returns:
|
|
List of registered tool instances
|
|
"""
|
|
tool = PlanTool()
|
|
ToolRegistry.register_tool(mcp_server, tool)
|
|
return [tool]
|