Policy Modes
Policy modes determine whether decisions are enforced or just observed:Mode Precedence
Modes can be set at multiple levels. Higher precedence wins:- Per-request override —
ctx.modein the evaluation context - Policy bundle mode — Set by governance team in signed bundle
- Engine constructor —
modein TealEngineOptions - Default —
MONITOR(safe for testing)
Enforcement Behavior by Mode
ENFORCE Mode
MONITOR Mode
MONITOR_MODE_VIOLATION reason code. This lets you observe what WOULD be blocked without actually blocking.
PLAN_ONLY Mode
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:Fail-Closed vs Fail-Open
When a module throws an exception during evaluation:Related Documentation
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

