Weekly: takes the watchdog's list of search queries that spent money and produced zero sales, shows Sherif the evidence, and — on his Approve — adds them as exclusions, so we permanently stop paying for searches that never buy.
Weekly exclusion list with spend evidence per query. On Approve — and only then — the exclusions are applied via the API.
The graduation doctrine says writes unlock smallest-blast-radius first. This is the smallest that exists in advertising: the worst case is that we stop paying for a junk search, and it's reversible in one click. Every other kind of ad edit stays human-only.
After L3's Monday ritual
Zero-conversion queries with spend evidence
Per-query spend, clicks, zero results
Batch-by-batch, never automatic
Via the API — the one sanctioned edit
For implementers and the technically curious. The full build sheet — verified queries, thresholds, and build notes — lives on the specs page.
| System | Role in this loop |
|---|---|
| Ads adapter layerads_common.py | One shared, environment-gated adapter for Google and Meta data, used by all four ads loops. It has a fixture mode, so every threshold was provable with synthetic data before any credential existed. |
| Agent Vaultcredential store | Where API keys live. Loops get read-only credentials from the vault; nothing is hardcoded in scripts. |
| Hermesagent runtime on our server | The scheduler that wakes the loop up. Each loop is a cron job under a Hermes profile; the planned bizops profile will host the business digests (IT loops run under vpsops). |
| Healthcheckshealthchecks.huxapps.com | The dead-man's switch. The loop pings it only after a clean run — if the loop dies or errors, the ping stops and Healthchecks raises the alarm independently. This is how 'never silent' is enforced by machinery, not promises. |
| Email renderer + gwsrender_email.py | All digests pass through one shared renderer: Huxberry-branded HTML, tables for repeated rows, a coral 'needs your response' box when the loop has questions, and an arrow link on every record. Sent from the loops mailbox via the Google Workspace CLI. |
| Google Ads APIthe gated write | Negative-keyword additions only — the narrowest write the platform offers, unlocked by trust, reversible in one click. |
| Model / brain | What it does here |
|---|---|
| None at run timedeterministic script | A normal cycle is a plain Python script — no AI tokens are spent unless a diagnosis or judgment step is actually needed. AI wrote the script; the script does the rounds. |
| GPT-5.5 via Codexthe bulk-work model | Wrote and maintains the mechanical parts — SQL, diffing, digest assembly. Effectively free on our existing subscription, so routine cycles cost almost nothing. |
| Claude Opusthe judgment model | Reviews alert wording, thresholds, and anything a human will read and act on. Post-Fable, Opus owns everything that ships. |
Approved/rejected history per query — rejections teach the thresholds; approved exclusions never re-nominate.
Weekly evidence list; a confirmation note after an approved batch is applied.
The write does not exist in code yet — that's the safety rail. When built: scoped to negative keywords, per-batch approval forever, full audit trail of who approved what.