Track 06 · Security & risk reviewLesson 01 of 10

Guardrails the risk team can sign

Layered safety checks, each with an action, a threshold and a log.

What you'll be able to do

What you'll be able to do

01
  1. Classify guardrails by where they act (input, retrieval, tool call, output, dialogue) and by how they decide (deterministic validator, classifier, model judge).
  2. Design a guardrail policy for a use case, with an action per check (allow, filter, mask, escalate, block) and thresholds set by risk tier.
  3. Implement a layered guardrail pipeline that runs independent checks concurrently and logs every decision.
  4. Measure guardrails like any other model: false positives, false negatives, latency and cost, per language and segment.
  5. Present the guardrail design to a risk team as a document they can review, test and sign.
Before you start

Before you start

The short version

The short version

A guardrail is a check, outside the model's own judgement, that inspects something entering or leaving the model and decides what happens next. Production systems use several, placed at different points: input rails on what the user sends (abuse, self-harm, injection attempts, personal data), retrieval rails on what evidence enters the context (untrusted sources, injected instructions), tool-call rails on what the agent tries to do (allow-listed tools, valid arguments, gated writes), output rails on what the user receives (groundedness, scope, leaked identifiers, unsafe advice), and dialogue rails that keep a conversation on its permitted topics. Each check is either deterministic (regex, schema, allow-list), a trained classifier (Llama Guard-style models, cloud content-safety APIs) or a model judge, and each has an action, not just a verdict. Guardrails are models too: they have false positives that frustrate users and false negatives that reach them, they cost latency and money, and they must be evaluated per language. The risk team wants to see the whole design on one page, with test results.

Key takeaways:

  • Put deterministic controls first and strongest: tool allow-lists, schemas and parameter limits beat any classifier.
  • Every guardrail needs an action and a user experience, not just a flag.
  • Run independent checks in parallel; put cheap checks before expensive ones only when they can short-circuit.
  • Evaluate guardrails with labelled data, per slice. Vendor accuracy claims do not transfer to your users.
  • Guardrails reduce risk; they do not prove safety. Pair them with red-teaming and monitoring.

Practise this in the lab

Pro lesson

The rest of this lesson is in Pro.

The mental model, worked example, field note, failure table, exercise and self-check, with the voice tutor.

  • Every stage and specialisation, in full
  • Every lab and every role project
  • Halden weeks 2–10, on your record
  • Every drill, live in the playground
  • All solutions, plus the server judge
  • Lab Assistant and every Teach with AI