Campaign Autopilot Braking
A user-authored rule engine that pauses, stops or alerts on a campaign when a metric crosses a threshold — with a simulate mode, an audit trail, and no scheduler.
Runtime state: Built and working, but effectively unused: one rule exists and it is disabled, and there is no ticker or worker that evaluates rules — it fires only when a person clicks. The braking that actually protects production is the orchestration protection engine, which does run on a tick.
- Business objective
- Give an operator a self-service way to express an emergency brake on their own campaigns, without needing a code change to add a rule.
- Trigger
- A human clicking run or simulate against a specific rule.
- Inputs
- A rule of conditions and actions, authored by the operator who owns it
- Live campaign statistics for the targeted or running campaigns
- A simulate flag
- Outputs
- Whether every condition was met, and which campaign triggered it
- Executed pause, stop or alert actions
- A before-and-after audit record
What it is, and what it is not
This is the self-service sibling of the delivery protection rules. The protection engine is fourteen rules in Go, banded by consequence, running on a tick. This is an operator writing their own rule in the interface and running it.
The distinction matters because the two are constantly confused, including by the naming inside the codebase — there is a separate governance component that also carries the word "autopilot" and does something entirely unrelated. This page is about the campaign rule engine.
The workflow
Rule to executed action
Simulate is the only dry run, and it is opt-in per invocation rather than enforced.
- Human action
Operator authors a rule
Conditions of metric, operator and threshold; actions of pause, stop or alert. Scoped to one campaign or to any running campaign.
- Human action
Operator clicks run or simulate
Decision point: There is no scheduler. Nothing evaluates a rule unless a person asks it to — which is the single biggest limitation of this design.
- Approval gate
Ownership check
Decision point: A rule can only be evaluated by the person who created it.
- Automated software
Evaluate each condition
Eleven metrics available: bounce, open, click and unsubscribe rates; complaint, block, hard-bounce, soft-bounce, delivered, sent and deferred counts. Five comparison operators.
- Automated software
Any-campaign matching
Decision point: For a scope of any running campaign, a condition is met if a single campaign satisfies it — and that campaign becomes the action target. Scanning is capped, so the blast radius is bounded.
- Automated software
Combine conditions
Decision point: All conditions must be met. A logical AND across the set, not a score.
- Approval gate
Simulate?
Decision point: If simulating, return the evaluation and execute nothing. This is how a rule is checked before it is trusted.
- Automated software
Execute the actions
Pause the campaign, stop it, or raise an alert. A closed set of three — it cannot change rates, budgets or content.
- Data store
Write the audit record
Before and after: which conditions were met with per-condition results, and which actions executed.
- Human action
- Automated software
- Data store
- Approval gate
Decision points
- Which metric, and against what threshold? Authored by the operator.
- One campaign or any running campaign? Scope determines the blast radius.
- Simulate or execute? Per invocation.
- Which campaign gets the action? The first match, when scoped broadly.
Responsibilities
AI / LLM
- Nothing. This is threshold comparison over campaign statistics.
Deterministic
- Metric extraction from campaign statistics.
- All comparisons and the logical AND across conditions.
- Ownership enforcement.
- The scan cap.
- Action execution, from a closed set of three.
- The before-and-after audit record.
Human approval points
- Authoring the rule.
- Every evaluation — there is no scheduler, so a human is always the trigger.
- Resuming anything it paused.
Failure handling
| Failure | Response |
|---|---|
| Metric unavailable for a campaign | The condition cannot be met and does not fire. |
| Rule scoped too broadly | The scan cap bounds it, and only the first matching campaign is acted on. |
| Statistics stale | Evaluated against whatever the campaign statistics report; there is no freshness check, which is a gap. |
| An action targets a campaign already paused | The action is idempotent in effect. |
Monitoring
Rule count and how many are enabled, evaluations run versus simulated, conditions met, actions executed by type, and audit-record completeness. The most telling metric for this feature is how rarely it is invoked at all.
Business value
Rules an operator can write themselves get written. The value is in removing the code change, not in the automation — which is also why its dormancy matters less than it would elsewhere.
Related projects
Related workflows
- Delivery Protection Rules
Fourteen rules in four priority bands, evaluated on a fixed tick against live delivery signal, able to throttle or pause without waiting for a person.
- Campaign Creation to Delivery
From an operator composing a campaign to messages accepted by receiving providers, through a single mandatory suppression gate and a fail-closed readiness barrier.