Keeps the calendar of obligations attached to our bank facilities — reporting deadlines, review dates, monthly self-checks — collects a signed-off confirmation each month, and escalates if one goes unanswered.
A monthly checklist to Shahbaz on the 1st business day; every reply is logged into an attestation ledger — the audit trail banks like to see. If a month goes unanswered, it escalates to Rajiv.
Real money rides on facility covenants nobody was systematically checking. The turnover-measurement source isn't machine-readable to us, so v1 is deliberately a calendar + evidence collector, not a calculator — with quantitative routing checks unlocked later by the invoice data. Facility details are deliberately kept off this page.
Monthly rhythm
What's due this month, what's approaching
“Confirm the self-checks — reply with figures”
Into the attestation ledger
A missed month goes to Rajiv
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 |
|---|---|
| Private covenant configfin2_config.json | The real facility terms, in a file with restricted permissions on the server. The public site and the code repository never contain them. |
| NetSuite warehousePostgres on our server | Our nightly read-only copy of NetSuite (ERP) data — items, stock, transactions — refreshed by the ETL sync every morning. The loop queries this copy, never NetSuite itself. |
| Postgres “loops” schemareporting database | A small dedicated schema where loops keep snapshots and history that need SQL (week-over-week diffs, mirrors for drill-down links). Scoped role; Metabase can read it for the clickable aggregate links. |
| 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. |
| Loop chassisloop_common.py | Shared plumbing every loop reuses instead of reinventing: state files, run-over-run diffing, Metabase drill-down link building, quiet-on-green notify logic. |
| 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. |
The attestation ledger — month, checklist, reply, figures — plus mute flags per obligation.
Monthly email checklist; escalation email on silence. Later: a finance feed card for retention/compliance headlines.
No bank credentials exist anywhere in this system. The loop knows dates and rules, not balances. Escalation is built in so silence can't become drift.