Say an internal agent is asked to tidy up a test project. It does exactly that. It also deletes the shared fixtures directory three other projects import, because the directory sits inside its working path and nothing says it is off limits.

There is no jailbreak, no injection and no bug, just a correctly executed action with a blast radius nobody had measured.

Narrow the tool before you narrow the prompt

Excessive agency is usually an interface problem. A generic run_sql or write_file tool inherits every capability of the system underneath it, and then a paragraph of prompt is asked to hold the line. That paragraph is guidance that happens to work most of the time.

Workflow-shaped tools beat general ones. Ship refund_order(order_id, amount) with a server-side cap rather than execute_transaction. The narrow signature is easier to log, easier to rate limit, and easier to argue about at review time, because its worst case can be written down in a sentence. The price is more tools to build, version and describe well enough that the model picks the right one.

For anything with real consequences, split the action in two. The agent produces a diff, a preview, a staged record. A separate call commits it. Staging turns an irreversible operation into a reviewable artefact, and it makes the approval question concrete: a human sees what will change rather than a description of intent. Make the commit check that the target has not changed since the preview, with a version number or an ETag, or the reviewer approves one diff and the system applies another.

Attach approval to properties of the request, evaluated in code. Amount over a threshold, records touched above a count, an external recipient, a first-time destination. Never attach it to the model's own assessment of how important the action is.

Containment gets built before you need it

Sandbox the execution environment as if the agent were untrusted code, because functionally it is. Explicit workspace root, no ambient credentials in the environment, an egress allowlist, and bounds on CPU and wall clock. That fixtures directory would have survived a workspace root one level tighter.

Rate limit per user, per workflow and per tool over a rolling window, then alert on the shape of the traffic rather than the totals. Repeated near-identical calls, a sudden widening of argument ranges, or a burst against a rarely used tool are the signals that arrive before the damage.

Two things stay ready. One is a kill switch per tool that operations can flip without a deployment, and that gets exercised on a schedule so nobody discovers it is broken during an incident. The other is a documented compensating action for every write path. Where an action genuinely cannot be undone, that is precisely the action that requires a human signature.

List the actions your agent can take today without a person seeing them first, and rank them by damage and by time to undo. Put the top one behind staging and approval before you add another tool.

Terms in this piece

About this explainer

Format
Explainer
Level
Practitioner
Read
2 min read
Published
Aug 27, 2026

Short mental models: one idea, why it matters, what to do about it.

Checklist · · 18 checks

When to bring in a compliance review

The changes that should pull legal, privacy or compliance into an AI project early, and what to have ready when you do. Not legal advice; a way to ask at the right time.