Skip to content
BENIBIX Learn

Guardrail (AI)

Also known as AI Guardrails, LLM Guardrails, Safety Filter

A check around an AI model. It blocks bad requests and bad answers.

Think of it like

It is like the rail on a mountain road. You can drive freely, but it stops you going over the edge.

Example

Emma's bank chatbot has an output guardrail. If an answer contains a full card number, the guardrail masks it before it reaches the user.

Why it matters

Models make mistakes and can be tricked. A guardrail catches some of that before it reaches a person.

Definition

A guardrail is a check placed around an AI model to stop bad input and output. An input guardrail looks at a request before the model sees it. It can block attacks or requests that are off topic. An output guardrail looks at the answer before the user sees it. It can block harm, hide private data, or check the format. Guardrails can be simple rules, or a second, smaller model that sorts the text.
One check before the model, and one after it.

Common mistake

Relying on guardrails alone. They catch a lot, but clever attacks get past them, so keep the model's power limited too.

Key takeaways

  1. 1
    Check the input. Before the model.
  2. 2
    Check the output. Before the user.
  3. 3
    An extra layer. Not the only one.

Compare