Skip to main content

Module tools

Module tools 

Source
Expand description

Tool system — trait, registry, and built-in tool implementations.

All tools implement the Tool trait and are registered in ToolRegistry. Subagents get ToolRegistry::without_subagent() to prevent recursion.

Re-exports§

pub use crate::runtime::subagent::SubagentResult;
pub use crate::runtime::subagent::SubagentHandle;
pub use crate::runtime::subagent::SubagentRegistry;
pub use crate::runtime::subagent::SubagentStatus;
pub use crate::runtime::subagent::SubagentState;
pub use watcher_exit::WatcherExitTool;
pub use shell::ShellStartTool;
pub use shell::ShellSendTool;
pub use shell::ShellEndTool;
pub use respond::RespondTool;
pub use send_channel::SendChannelTool;

Modules§

respond
RespondTool — reply to an event through its original source channel.
send_channel
SendChannelTool — proactively send a message to a specific channel.
shell
Interactive PTY-based shell sessions for agents.
watcher_exit

Structs§

BashTool
EditTool
ExtensionTool
FindTool
GrepTool
LsTool
ReadTool
SecretPromptHandle
UI-only secret prompt plumbing for interactive tools.
SecretPromptQueue
SecretPromptRequest
SubagentCollectTool
SubagentResumeTool
SubagentStartTool
SubagentStatusTool
SubagentSteerTool
SubagentTool
ToolCapabilities
Runtime capability handles — shared services a tool may require.
ToolChannels
Streaming channels — carry partial tool output and stream events.
ToolContext
Context passed to tool execution — composition of channels, capabilities, and limits.
ToolLimits
Configuration limits and timeouts.
ToolRegistry
Registry of available tools. Maintains a name→tool map and a cached JSON schema array that gets sent to the API. Thread-safe via Arc<RwLock<ToolRegistry>>.
WriteTool

Traits§

Tool
The core trait for all tools. Implement this to add a new tool.

Functions§

resolve_agent_prompt
Resolve an agent name to a system prompt.