Docs/Guides/Assistants/Safety & approvals

Safety & approvals.

For high-stakes workflows, the right answer is human-in-the-loop. wrxstack ships a first-class approvals system: thresholds, reviewers, escalation, and audit. This guide covers the patterns we recommend and a few we suggest avoiding.

What you will learn
  • When to add an approval gate
  • How to declare thresholds in TOML
  • How approvals appear to reviewers
  • How to audit overrides

When to add an approval

Add an approval gate when one of three things is true:

  1. The action is irreversible (signed contract, paid invoice, sent email to a large list).
  2. The action has financial threshold (anything above a dollar amount your finance team picks).
  3. Someone needs to be accountable by name for the decision.

Don't add approvals for low-stakes actions. Approval fatigue is real; every needless gate trains your team to rubber-stamp the important ones.

Declaring thresholds

[approvals]
above_arr_usd = 100000
require = "role:sales-lead"

[approvals.escalation]
after_minutes = 30
to = "role:cfo"

Two fields drive everything: the predicate (above_arr_usd) and the required reviewer (require). Escalation is optional and is what keeps a sleeping reviewer from blocking the queue forever.

How approvals appear

Reviewers get a notification (email, Slack, in-app, depending on their settings) with a link to the run. The link opens a single-purpose page showing: what's being proposed, the assistant's rationale, the audit trail to this point, and two buttons.

Reviewers can also write a one-line reason for approving or rejecting. The reason is captured in the audit log; we strongly recommend requiring one.

Overrides and audit

Sometimes a workflow needs an override (the reviewer is out, the deadline is now, etc.). Overrides are first-class: they require an explicit "I am overriding because X" entry and the override action itself becomes auditable.

The audit log distinguishes:

  • approved, the standard path.
  • auto_approved, the threshold was not triggered.
  • overridden, a human explicitly bypassed the gate.
  • denied, terminal rejection.

Most compliance reviews ask only for the overridden rows. Filter the audit log accordingly.

Next steps