1:1 mentoring with Big Tech AI engineers
LLM & Agentic

Tool Surface Design

When an action deserves its own tool instead of bash, how to write a description that raises selection accuracy, and how to scale past a few dozen tools without destroying the prompt cache.

Last updated

Core5 min readFirst readAnatomy of a Tool Call

After this section you can

  • Decide when an action deserves its own tool instead of going through bash, using reversibility as the test
  • Write a tool description that raises selection accuracy, and keep examples and rival-tool instructions out of it
  • Scale a large tool surface with tool search and deferred loading without destroying the prompt cache
02

Tool Surface Design

One bash tool can do almost anything, which is exactly why your harness can do almost nothing with it. Deciding which actions get their own tool is how you buy back the ability to gate, render, audit, and parallelise.

THE CENTRAL IDEA

The model emits tool calls; your harness handles them. So the shape of the tool surface decides what the harness can see and therefore what it can do. A single bash tool gives it one opaque command string for every action — it cannot tell a read from a delete, so it must treat them alike. Promoting an action to its own tool gives the harness typed arguments it can intercept, approve, render, log, or run in parallel. That is the whole trade: breadth from bash, control from dedicated tools.

Same action, two surfaces — what the harness gets to see
VIA BASH — ONE OPAQUE STRING bash(cmd="psql -c 'DELETE FROM …'") HARNESS SEES a string. that’s all. ✗ cannot require approval ✗ cannot render a confirmation ✗ must serialise — a read looks like a write PROMOTED — TYPED ARGUMENTS delete_record( table="orders", id=42) HARNESS SEES an action + its args ✓ gate it behind approval ✓ render a real confirmation dialog ✓ audit it · mark reads parallel-safe Start with bash for breadth. Promote an action when you need to gate, render, audit, or parallelise it. Reversibility is the sharpest test: if undoing it is hard, the harness needs to see it coming.

Related

More in LLM & Agentic

Get full access to all 74+ sections with code examples, diagrams, and interactive animations.

Unlock Premium