Have a tricky problem that you think requires a rewrite of your software? Join as a guest on our podcast and we’ll talk you out of it.

1. Keep an AI agent’s rules in your own code

If an AI agent can do something that matters, like spending money or calling someone, the limits on it should live in your own code and not in its prompt. On the bill-pay platform Isaac worked on, an AI voice agent calls billers and pays bills over the phone. The platform decides whether a call is allowed at all (no calls outside business hours, and a biller can be marked do-not-call), and every way a call can fail has its own outcome code. When traffic moved from a vendor’s agent to an in-house one, it went to 10% of calls first and then to 100%, with no rollback. The in-house agent now pays 1,000+ bills a month.

Isaac’s full write-up, from his work at a payments company, is on isaacaskew.com.

2. Off switches first

Before anything we’ve migrated takes real traffic, it gets an off switch (a kill switch) that works without a deploy. When Isaac moved card issuing and ACH to a new sponsor bank across five services, the first step was adding off switches to every path that moves money. After that, both banks’ card programs ran side by side for a while instead of everything riding on one cutover night, and the changes rolled out in a set order. At the end he deleted about 5,900 lines of the old bank’s code. We don’t consider a migration finished while the old path is still there.

Isaac’s full write-up, from his work at a payments company, is on isaacaskew.com.

3. Only delete what the logs say is dead

Legacy code is full of things that look unused. Instead of guessing, we pull the access logs and production traces and only delete what has had zero traffic. On a legacy PHP portal, Isaac did this with 60 days of logs and 119 days of traces. He deleted 245 files, and the repository went from 22.4 MB to 8.6 MB. The same traces also turned up a page that was re-downloading the same bill images on every load (14.96 GB a week) and a bug causing 638 fatal errors a month.

Isaac’s full write-up, from his work at a payments company, is on isaacaskew.com.

4. A refund safety check that isn’t sure should say no

Code that moves money should refuse to act when it isn’t sure (engineers call this failing closed). On the same platform, Isaac replaced three separate refund jobs with one tested library that has several layers of checks. It won’t refund a payment that hasn’t cleared yet, won’t treat a partially paid bill as unpaid, and won’t refund a bill that’s already been paid out to the biller. In 2026 some refunds went out that shouldn’t have, and the cause turned out to be two failures nobody had noticed. The fix was to make the check block the refund whenever the data it depends on is missing, and to send a separate alert when that happens. About 75% of the money was recovered. What Isaac took from it is that any check protecting money needs a test, an alert on the data it depends on, and a default of saying no.

Isaac’s full write-up, from his work at a payments company, is on isaacaskew.com.

5. Gates before autonomy

An AI agent gets to work on its own only after the gates exist that would catch a human making the same mistake. On VenuNite, Isaac’s events platform, that means a pre-push hook on the site, tiered test runs on the data pipeline, and a release process that builds an immutable release from main, verifies it, and only then activates it. The dark factory that runs every eight hours on headless Claude Code, the hourly categorize drain, and the merge lane all open pull requests that go through exactly those gates. Each lane runs in non-interactive mode with a per-run allow list, and each has an off switch. The order matters: gates first, then autonomy, never the other way round.

The harness is described in the VenuNite case study.

6. Every unblock ships three things

When something in an autonomous system gets stuck, fixing the stuck thing is the smallest part of the job. On VenuNite every unblock ships the fix, auto-recovery in the lane that should have caught it, and an alert that fires while the bad state persists. The issue is then reported as fixed, unblocked with the fix in progress, or unfixed, never as “done” when only the symptom moved. Without the second and third parts, the same failure comes back quietly a week later and nobody notices until a user does.

The rule and how it’s enforced are in the VenuNite case study.

7. Label every claim “measured” or “read in code”

A rule that classifies data is a claim about what’s in the table, and green unit tests prove nothing about that. On VenuNite, before any predicate goes live, it’s dry-run read-only on the replica and reported with its fire rate, a sample of what it catches, and a sample of what it excludes. Every other claim is labelled either “measured” (from the database or production) or “read in code” (what the code says should happen). Merged is not deployed, deployed is not serving, and each is verified separately. This is how an AI agent, or a person, earns the right to say something is true.

More on how claims are earned in the VenuNite case study.

8. Keep a refuted list

Ideas that were measured and killed go in a file called REFUTED.md, and anyone, human or agent, checks it before proposing something. On a system where agents generate proposals around the clock, the same plausible-sounding idea comes back again and again unless the evidence against it is written down somewhere it will be read. The list also catches the opposite failure: a “fix” that an earlier measurement already showed makes things worse. It costs a paragraph per entry and saves the re-measurement every time.

The practice is part of the harness in the VenuNite case study.

See these patterns on your system

Book a call and we’ll walk through where each one would fit.

Book a call How we work & pricing

Prefer email? start@ygg.llc