20Systems of agents

Guardrails

Screen user input before the agent sees it, and its output and actions before they take effect.

OpenAI, Anthropic, Google, Simon Willison

User inputGuardrail, Model callGuardrailAgentAgentBlockedGuardrail, Model callGuardrailOutput
How to read this

The problem

An agent left unchecked can leak data, take harmful actions or say things that damage your brand.

Uncontrolled agents can pose risks, including executing misaligned or harmful actions, such as data exfiltration, and generating inappropriate content that can impact your brand’s reputation.
GoogleSafety and Security for AI Agents
Well-designed guardrails help you manage data privacy risks (for example, preventing system prompt leaks) or reputational risks (for example, enforcing brand aligned model behavior).
OpenAIA practical guide to building agents

Therefore

Guardrails enable you to do checks and validations of user input and agent output.
OpenAIGuardrails - OpenAI Agents SDK
Filter user input for known injection patterns before it reaches Claude. You can use an LLM to create a generalized validation screen by providing known jailbreaking language as examples.
AnthropicMitigate jailbreaks and prompt injections

In use

Claude Code

Auto mode is a new mode for Claude Code that delegates approvals to model-based classifiers—a middle ground between manual review and no guardrails.
AnthropicHow we built Claude Code auto mode: a safer way to skip permissionsMar 25, 2026

Claude (Constitutional Classifiers)

Our final production-grade system … a linear probe screens all traffic, escalating flagged exchanges to a probe-classifier ensemble for final judgment.
AnthropicNext-generation Constitutional Classifiers: More efficient protection against universal jailbreaksJan 9, 2026

Where it breaks

A model that screens for attacks cannot be shown to catch them all, and a check run in parallel may finish after the model starts.

If you patch a hole with even more AI, you have no way of knowing if your solution is 100% reliable.
Simon WillisonYou can’t solve AI security problems with more AISep 17, 2022
Blocking execution guarantees that the expensive model does not start; with parallel execution, the expensive model may already have started before the guardrail completes.
OpenAIGuardrails - OpenAI Agents SDK

Sources

  1. A practical guide to building agentsOpenAI
  2. How we built Claude Code auto mode: a safer way to skip permissionsJohn Hughes, Anthropic, Mar 25, 2026
  3. Next-generation Constitutional Classifiers: More efficient protection against universal jailbreaksAnthropic, Jan 9, 2026
  4. Guardrails - OpenAI Agents SDKOpenAI
  5. Safety and Security for AI AgentsGoogle
  6. Mitigate jailbreaks and prompt injectionsAnthropic
  7. You can’t solve AI security problems with more AISimon Willison, Sep 17, 2022

Added Nov 14, 2026