Most AI agent guardrails today are sentences in a system prompt: "never refund more than $100", "don't email customers about pricing". They work until the day they don't. (This is part of our AI agent security guide.) Once an agent can refund, pay, email or change a system, guardrails need to be rules that are checked outside the model, on every action.

Agents act, so the risk moves

A chatbot answers questions. An agent takes actions: it refunds an order, sends an email, updates a record, restarts a service. The risk moves from what the model says to what the agent does — and the second kind of mistake is much harder to undo.

Why prompt-based guardrails fail

Writing a limit into a prompt is a request, not a rule. Three things break it:

  • Prompt injection. A customer message, a web page or a document the agent reads can contain instructions that override yours.
  • Ambiguity. "Small refunds only" means different things in different conversations. The model decides, not you.
  • Silent drift. A prompt edit, a new model version or a new tool can change behaviour with no record of what changed.

None of these show up in testing reliably, because the model is doing exactly what it was designed to do: follow the most persuasive instruction in front of it.

What real AI agent guardrails look like

Effective guardrails for agents share four properties:

  1. Checked outside the model. The limit is enforced at the moment the agent calls a tool, by code the model can't influence.
  2. Specific to the action. The rule sees the actual action and its arguments — issue_refund, $500, order A-2210 — not just the text of the conversation.
  3. Three possible answers. Allow it, deny it, or hold it for a person to approve.
  4. Recorded. Every decision is logged with the rule that made it, in an audit trail.

Allow, deny, or ask a person

Most agent actions fit one of three outcomes: safe to do automatically, never allowed, or allowed only after a named person agrees — see when an AI agent should ask a person first. Deciding which is which, per action, is the core of agent policy. A refund rule might allow anything under $100, send $100–$1,000 to the finance lead, and deny the rest. See more sample rules by use case.

Content guardrails vs. action guardrails

Content guardrails filter what a model reads and writes: toxic language, off-topic answers, leaked secrets. They're useful, but they don't see the refund amount or the database being deleted. Action guardrails decide whether a tool call may run at all. Most teams running agents in production need both. We compare the options in more detail on why a runtime checkpoint.

Write rules people can read

The people who own a process — finance, support, security — should be able to read and sign off the rules. Engineers should be able to version, test and roll them back like code. If only one side can read the guardrails, the other side is trusting, not checking.

Where Gaten fits

Gaten is a runtime checkpoint between your agents and the tools they call. It checks every action against your rules before it runs, returns allow, deny or require approval, and records each decision. Read how it works or see how policies are written.

Frequently asked questions

Are prompt guardrails useless?

No. Clear instructions make an agent behave better most of the time. They just can't be the only limit on actions with real consequences, because a prompt can be overridden.

Do AI agent guardrails slow agents down?

A well-designed checkpoint adds a policy check to each tool call, designed to stay in the request path without noticeable delay. Only actions your rules hold for approval wait for a person.

What should I put guardrails on first?

Start with actions that move money, touch customer data, contact customers, or change production systems — anything that's hard to reverse.