Tendril – a self-extending agent that builds and registers its own tools
TL;DR Highlight
Give an agent just three tools and let it build and register the rest in a growing registry.
Who Should Read
An agent developer whose agents pick wrong tools from a huge toolset or burn tokens re-solving the same problems every session.
Core Mechanics
- The model always sees just three tools
- Instead of a big bag of tools, only three bootstrap tools are exposed.
- The tool surface stays fixed while capabilities grow in the registry.
- If no tool exists, it builds one without asking
- It first checks the registry with searchCapabilities.
- If nothing fits, it writes a tool, registers it, and runs it by name.
- The system prompt forbids asking "would you like me to create a tool?"
- The registry is just files
- It is stored as index.json plus tools/*.ts, and you can inspect, edit, or delete it.
- Each entry has name, capability, triggers, and suppression.
- Direct code execution is blocked
- Per the author, the agent can only run registered capabilities.
- So every task forces it to write a tool, define its invocation conditions, and register it.
- Execution runs in a Deno sandbox
- Tools run in a Deno subprocess with permission flags.
- Default timeout is 45000ms, and empty allowedDomains means unrestricted network.
- Stack is Strands plus Bedrock Claude
- It uses AWS Strands Agents SDK (TypeScript), Claude on Bedrock, and a Tauri desktop shell.
- Agent and UI talk via JSON-RPC 2.0/NDJSON over stdio.
Community Reactions
- Five local models all failed, per the author
- Qwen3-8B, Gemma 4, Mistral Small 3.1, Devstral Small 2, and xLAM-2 were tried and none passed.
- The author says the failure modes are written up separately.
- Concern that the registry fills with noise and inconsistent APIs
- One commenter expected the registry to become noise after dozens of sessions, with overly task-specific tools.
- Another said scaling complexity is the core issue.
- Similar setups people built themselves
- One company's LLM searches a wiki of Saved Programs first, reuses one if found, or generates and offers to save one.
- Another commenter creates a Claude skill or subagent for recurring problems, mentioned in one line in a global md, and says it works for a dozen or two.
- Pushback on codifying WHEN as rules
- One commenter said the IF found / IF not found system prompt is still an if-then heuristic.
- They reported better generalization by describing the situation and letting the model decide.
How to Apply
- Make a tool registry index.json
- Pick one recurring task for your agent and describe it with name, capability, triggers, and suppression in index.json.
- Paste the prompt below so the agent searches first and builds when nothing matches.
- Cut exposed tools to a few bootstrap tools
- If tool selection is shaky, expose only search, register, and execute.
- Store the rest as files and load them via search.
- Add permission limits to the execution sandbox
- Run generated code in a Deno subprocess with a timeout and allowedDomains.
- Allow only the domains each tool needs.
- Set cleanup rules for the registry
- Periodically open index.json and merge or delete duplicate or overly specific tools.
- Write invocation conditions in triggers and suppression as situation descriptions.
Try It
# Paste into Claude Code or ChatGPT (simplified version of the Tendril approach)
You are an agent that uses a tool registry. index.json in the working folder is the registry.
Fields per entry: name (snake_case), capability (one sentence), triggers, suppression.
Rules:
1. On a request, first search index.json for a relevant tool.
2. If found, run tools/{name}.ts and answer.
3. If not found, do not ask "shall I create one?"; write the tool, save it in tools/, register it in index.json, then run it.
4. If it fails, read the error, fix the code, and retry.
5. Do not answer from training data when a tool could get live information.
Request: {{request}}Terminology
Related Papers
Ask HN: If the models are so good, why doesn't OpenAI just start 100 companies?
HN answers: code is easy, knowing what to build isn't, so they sell tokens instead
OpenShell – A safe, private runtime for fleets of autonomous AI agents
OpenShell uses policy files to control agent file, network, and credential access at kernel level.
Show HN: Omnara – Open-source alternative to Claude Managed Agents
Open-source managed agent platform runs agents on any model and machine, self-hostable
Rust off Rails: The opinionated web stack for the AI era
Sixty Markdown files tell coding agents how to build a Rust web app, with no framework code.
LayerFS: The filesystem for AI coding agents
Mount an ephemeral workspace per agent, commit only the changes
Launch HN: Alter (YC S25) – Access control for multi-user agents
Alter gives each agent its own identity, policy, and audit trail instead of shared API keys.
Using Claude to reduce the attack surface of code
Claude scanned 25 open-source projects and found 493 needlessly reachable code issues.
WhatsApp's help pages hid LLM instructions: dont recommend a regulator
WhatsApp help pages hid 102 AI-only instructions, including not recommending a data regulator