pub type TaskToolFactory = Arc<dyn Fn(State) -> Result<ToolDispatcher, String> + Send + Sync>;
Binds all captured state in tools to an isolated invocation state.
pub struct TaskToolFactory { /* private fields */ }