Skip to main content
Policy modes and automation levels control what happens AFTER a governance evaluation produces a decision. Understanding enforcement flow helps you safely roll out policies from testing to production.

Policy Modes

Policy modes determine whether decisions are enforced or just observed:

Mode Precedence

Modes can be set at multiple levels. Higher precedence wins:
  1. Per-request overridectx.mode in the evaluation context
  2. Policy bundle mode — Set by governance team in signed bundle
  3. Engine constructormode in TealEngineOptions
  4. DefaultMONITOR (safe for testing)

Enforcement Behavior by Mode

ENFORCE Mode

MONITOR Mode

In MONITOR mode, the decision is computed identically to ENFORCE, but DENY decisions are downgraded to ALLOW with the MONITOR_MODE_VIOLATION reason code. This lets you observe what WOULD be blocked without actually blocking.

PLAN_ONLY Mode

PLAN_ONLY is for agent planning loops. The decision tells you what would happen, but nothing is enforced or recorded.

Automation Levels (v1.3)

Automation levels add a second dimension to enforcement — they determine HOW the decision is applied:

Interaction with Policy Modes


FREEZE Rules and Enforcement

FREEZE rules bypass the mode system entirely. They ALWAYS enforce, regardless of the policy mode: FREEZE rules are the only controls that override MONITOR and REPORT_ONLY modes. This ensures critical safety controls are never observational.

Graduated Rollout Pattern

The recommended approach for introducing new governance controls:
Use FREEZE rules from day one for critical safety controls (database.drop, system.shutdown). These don’t need a graduated rollout — they should always enforce.

Fail-Closed vs Fail-Open

When a module throws an exception during evaluation:
fail_open means an attacker could potentially bypass governance by triggering module failures. Only use for non-security workloads where availability is more important than enforcement.

Evaluation Flow

How the 3-stage pipeline works

Automation Levels

The 4 automation levels in detail

FREEZE Rules

Immutable controls that bypass modes

Phased Adoption

Graduated rollout strategy