Docs · 03
Policy
Rules in policy.yml decide the verdict. No LLM is involved.
Verdict order
pass < warn < needs_human < block. The worst matching rule wins.
- All conditions inside one
whenmust hold (AND). - For OR, write several rules with the same
then. - Unknown conditions are rejected when the policy loads, so a typo can't silently pass a change.
Conditions
table (glob)tagdownstream_tagdownstream_kinddownstream_count_gtremoved_pct_gtadded_pct_gtchanged_pct_gtrow_count_change_pct_gtrow_count_drop_pct_gtcolumn_removedcolumn_addedcolumn_type_changedduplicate_keyssum_change_pct_gt (optionally with column)null_increase_gt (optionally with column)any_changediff_error
Example
default: pass
notify_owners_on: needs_human
rules:
- {name: duplicate-keys, when: {duplicate_keys: true}, then: block}
- {name: certified, when: {downstream_tag: certified}, then: needs_human}
- {name: revenue-moved, when: {column: amount, sum_change_pct_gt: 2}, then: needs_human}
- {name: gold-layer, when: {table: "*.gold.*", any_change: true}, then: needs_human}