A walkthrough of a meta-tooling pattern for building self-extending CLI tools using Amazon Bedrock (Claude Opus 4.6), the Strands Agents SDK, and Model Context Protocol. The approach lets users describe new CLI commands in natural language, which are then generated as working Python code, loaded at runtime without restarts, and versioned via git. Key mechanisms include the @tool decorator for runtime tool registration, AI Functions with post-condition checking for reliable code generation, and automatic MCP server discovery for external API knowledge. The result is a CLI that can create, refine, and revert its own tools conversationally, turning days of manual development into minutes.
Table of contents
I. IntroductionII. Solution OverviewIII. Technical ImplementationIV. ConclusionV. Next StepsAbout the authors63 Impressions