Expand description
MCP tool definition to text-tool-simulation bridge
§MCP Tool Bridge
Converts MCP (Model Context Protocol) tool definitions into embacle’s
text-based tool simulation types (FunctionDeclaration, TextToolHandler).
This enables using MCP-compatible tool servers with any embacle CLI runner via the text-based tool loop.
§Async bridging
[create_mcp_tool_handler()] bridges the async McpToolExecutor trait to
the synchronous TextToolHandler callback via tokio::task::block_in_place.
This requires a multi-threaded tokio runtime (rt-multi-thread feature).
Structs§
- McpTool
Definition - An MCP tool definition describing a callable tool
Traits§
- McpTool
Executor - Trait for executing MCP tool calls asynchronously
Functions§
- create_
mcp_ tool_ handler - Create a
TextToolHandlerthat delegates to an asyncMcpToolExecutor. - mcp_
tools_ to_ declarations - Convert MCP tool definitions to embacle
FunctionDeclarationvalues.