By Abhijith N M · Reviewed 24 October 2026 · Editorial standards
A support agent went live with five tools: search the help centre, read a ticket, read a customer, draft a reply, and send the reply. Eight months later the same agent advertises nineteen tools.
Two came from a data migration that ended in March. A third arrived when someone needed a report: a SQL tool that runs any query the service account allows. The incident review found no model bug. The tool was the fastest path, and nobody removed it afterwards.
The design question is the one the exam will ask: which of these nineteen tools should exist?
A tool set is least-privilege when each tool grants the smallest capability the task needs, on the smallest data surface, for the shortest time. The test is blunt: point at every tool and name the step that needs it.
Capability bloat is the gap between that set and the set you actually have. It appears in three shapes.
One rule decides most reviews. A prompt instruction is not an access control. If a tool is present, the model can call it, and no sentence in the prompt makes that call impossible. You remove the capability or you accept it.
That rule explains why Design B fails. Three tools feel tidier than twelve, but run_sql carries every right the database account holds. Twelve bounded read-only tools expose less, even though the list is longer.
Three moves exist, and they cost different things. Apply them in order, because the earlier ones are cheaper.
| Lever | Question that decides it | Typical case | What it costs |
|---|---|---|---|
| Remove | Does any task step need this tool? | An admin tool copied from a template | Nothing to build; re-review after every change |
| Scope down | Can the same capability be limited by parameter or by identity? | run_sql becomes get_open_orders(customer_id) | A wrapper to maintain, less flexibility |
| Replace | Can the agent get the answer without the capability? | A whole-table read becomes a summary or search tool | Design work, often a new index |
Replacement is the option teams forget. A tool that returns one pre-aggregated number is not a weaker run_sql. It is a different contract, and it removes the ability to read anything else.
Least privilege is about the data surface, and the data surface includes the response. A tool named get_orders looks narrow. If it returns every order for every customer, it spends the context window, adds latency, and buries the one record the agent needed.
Prefer tools that take a filter and return a bounded, structured result. This is the context-efficient access pattern: the caller states what it wants, and the tool refuses to return more.
{
"name": "get_open_orders",
"description": "Return up to 20 open orders for one customer.",
"input_schema": {
"type": "object",
"properties": {
"customer_id": {"type": "string"},
"limit": {"type": "integer", "maximum": 20}
},
"required": ["customer_id"],
"additionalProperties": false
}
}If the agent pages through results to find one row, the tool is wrong, not the model. A paging model is usually working around a bad contract.
An agent summarises a support ticket and proposes a reply. It has five tools: search_docs, get_ticket, get_customer, send_email and run_sql.
Most architects remove run_sql, scope get_customer, and keep the rest. If you also removed send_email, you made a delegation decision. Say who approves the send instead.
Key takeaways
A tool set is least-privilege when every tool maps to a task step on the smallest data surface.
Capability bloat has three shapes: unused, over-broad and wrong-shaped tools.
A prompt instruction is not an access control. If the tool exists, the model can call it.
Apply remove, then scope down, then replace; removal is the only lever with no ongoing cost.
A narrow tool that returns a whole table is still a wide data surface.
Re-review the set on every new tool, and schedule the removal when you add it.
Written and edited by the nexGenCoders team. Spotted a mistake? Tell us and we will fix it.
Don't lose this lesson
Create a free account to save your progress, keep your streak, and work toward a shareable certificate.