use std::sync::Arc; use forge_app::McpClientInfra; use forge_app::domain::{ToolName, ToolOutput}; #[derive(Clone)] pub struct McpExecutor { pub client: Arc, pub tool_name: ToolName, } impl McpExecutor { pub fn new(tool_name: ToolName, client: Arc) -> anyhow::Result { Ok(Self { client, tool_name }) } pub async fn call_tool(&self, input: serde_json::Value) -> anyhow::Result { self.client.call(&self.tool_name, input).await } }