Skip to content

Guardrails

A guardrail is a rule an agent's turn must satisfy. It's a check, a function you write over the turn (its answer, its tool calls and their results), and an action: what happens when the check fails. Kindgi runs an agent's guardrails once per turn, on its final answer, before the answer is stored.

The examples use the quickstarts' pack, my-pack, whose agent answers with dev-echo until you connect a model.