MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / ToolExecutor

Interface ToolExecutor

atomic-repository/src/ai/tools.rs:145–153  ·  view source on GitHub ↗

Synchronous tool executor. Implementations provide tool definitions and execute tool calls against concrete backends (repository, filesystem, etc.).

Source from the content-addressed store, hash-verified

143/// Synchronous tool executor. Implementations provide tool definitions and
144/// execute tool calls against concrete backends (repository, filesystem, etc.).
145pub trait ToolExecutor: Send + Sync {
146 /// Return the set of tools this executor provides.
147 fn tool_definitions(&self) -> Vec<ToolDefinition>;
148
149 /// Execute a tool call and return the result as a string.
150 /// Errors are represented as `Err(message)` and surfaced to the LLM
151 /// as `ToolResult { is_error: true }`.
152 fn execute(&self, call: &ToolCall) -> Result<String, String>;
153}
154
155// ── LlmProvider: tool-aware chat ────────────────────────────────
156

Callers

nothing calls this directly

Implementers 1

tools.rsatomic-repository/src/ai/tools.rs

Calls

no outgoing calls

Tested by

no test coverage detected