Chapter 7. Agent Management and Governance
Deploying an agent is the beginning, not the end, of your responsibility as an AI engineer. Once an agent is running in production, you need to answer a growing set of operational questions:
-
Is it staying on task?
-
Is it generating unsafe content?
-
Who owns it?
-
What is it costing?
-
Does it comply with your organization’s policies?
-
When something goes wrong at 2 a.m. with a fleet of fifty agents spread across three projects, do you have a single place to see what’s wrong?
Guardrails and Controls
Guardrails are Foundry’s runtime safety layer. They sit between user inputs, tool calls, tool responses, and model outputs, scanning each for a configurable set of risks and blocking or annotating content that exceeds your thresholds. Think of them as runtime type-checkers for AI behavior (i.e., they do not prevent you from building whatever you want, but they will surface violations at the exact point in the pipeline where they occur).
Controls, Risks, and Actions
A Guardrail is a named, reusable collection of Controls. Each control specifies three things:
- Risk
-
What to detect: hate speech, prompt injection, task drift
- Intervention point
-
Where in the pipeline to scan for that risk: user input, tool call, tool response, output
- Action
-
What to do when the risk is detected: annotate or block
Let’s have a look at where you go to define Guardrails in the Foundry portal, and then we’ll unpack the concepts in more detail. Navigate ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access