CodeSmith's Tool Architecture: Three Layers Funnel Dozens of Tools Into One Slot
CodeSmith, at version 0.5.0, offers roughly fifty built-in tools plus extension tools from MCP servers, dynamic libraries, and subagents, all plugged into a single interface. The design is organized in three layers: a minimal, host-agnostic framework Tool contract at the bottom, a production ToolSpec that carries most of the functionality, and a ToolDispatcher seam that keeps the engine core independent of the TUI. A central choice is that approval requirements are derived from declared capabilities, so tools that execute code require approval, tools that write files are suggested for approval, and others run automatically. The article notes that the dispatcher exists because the host context carries many terminal-specific services that cannot live in the runtime crate. Together these layers let the engine work against an interface rather than concrete host implementations.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)
Log in to join the discussion and vote.
Log in