Back to Prompting

How Do You Prompt a Model That Can Use Tools?

How Do You Prompt a Model That Can Use Tools?
AI Tutorials Team 12 June 2026

Once a model can search, run code or query a system, the prompt has a different job. It is no longer only about the shape of the answer; it is about when to reach for something else instead of answering from memory, which is a decision the model makes and frequently makes badly.

What does the model actually see?

A list of available tools with names, descriptions and parameters, alongside your instructions. It produces a structured call rather than prose when it decides one is needed, the surrounding system runs it, and the result is inserted into the context before generation continues.

The tool descriptions are therefore part of the prompt, and they are usually written as an afterthought.

What makes a good tool description?

  • What it does, plainly. Not what it is called internally.
  • When to use it. The conditions that should trigger it.
  • When not to. The adjacent cases where a different tool or no tool is right.
  • What it returns. So the model knows whether it got what it needed.
  • What it costs. Slow or expensive tools deserve a note saying so.

Why does the negative case matter?

Because tool selection errors are mostly over-triggering. A search tool with an enthusiastic description gets called for questions the model already knows, adding latency and cost, and occasionally producing a worse answer from a poor result.

Stating when not to use something removes more errors than describing when to use it.

How do you control when tools are used?

Through the system prompt and through provider settings. Most APIs offer a mode forcing a tool call, one preventing it, and one leaving the decision to the model. Forcing is useful when you know a lookup is required and unhelpful as a default.

In the prompt, an explicit rule works: search before answering anything about current prices, versions or events, and answer directly for definitions and explanations.

Should the model know what happened previously?

Only what it needs. Carrying every previous tool result forward fills the context with material that is no longer relevant, and the reasoning then has to compete with it.

Summarising or discarding earlier results once they have been used keeps the working context focused. This is the same discipline as passing forward only what the next stage needs in a chain, and it matters more here because tool outputs are frequently verbose.

How many tools is too many?

Beyond roughly ten, selection accuracy degrades noticeably. Descriptions start overlapping, the model picks plausible neighbours, and debugging becomes difficult.

Where a system needs more, grouping them behind a smaller number of coarser tools, or routing to a subset before the model sees them, works better than presenting everything at once.

What should the prompt say about results?

How to handle failure and emptiness, which is the case nobody writes instructions for. A search returning nothing, a query returning zero rows or a tool erroring should produce a statement to that effect rather than an answer assembled from general knowledge.

Without that instruction, an empty result is frequently filled in.

What is the risk that comes with tools?

Everything the tool can do becomes reachable by whatever the model reads. A tool that sends email, in a system that processes untrusted documents, is a tool that a document can cause to send email.

Permissions and approval steps are the control here, and no wording in the prompt substitutes for them.

How many tool calls should one request make?

Fewer than the model would choose. Left unconstrained, a model with a search tool will run several queries where one would do, and each result consumes context that the actual reasoning then has to compete with.

Setting a limit in the prompt helps, and so does asking it to state what it is looking for before searching. That single instruction reduces redundant calls noticeably, because a stated objective is harder to satisfy with three overlapping queries than an unstated one is.

What should you check when it goes wrong?

The trace rather than the answer. Which tools were called, with what arguments, and what came back. Most tool failures are a badly formed query or a misread result, and both are obvious in the trace and invisible in the final response.