Trust & safety

How do you prevent AI agents from going rogue?

You don’t supervise harder — you remove the ability to do damage. Agents read and explore freely, but the write path is gated: trunk is never written directly, every change is validated before it merges, and agents never hold the keys.

"Going rogue" usually means an agent writing something broken, incoherent, or contradicting how the system is meant to work — straight into the code everyone shares. CatWrangler makes that structurally impossible rather than relying on you to catch it.

Exploring is open; writing is gated

An agent can read, search, and understand the whole codebase as much as it likes. That's where you want it spending freely. The control sits on the write path — the moment it tries to change something.

  • It gets its own line of work to write in; the shared trunk is never written directly, so nothing lands unreviewed.
  • On submit, the change is validated: it must actually cover the decision it claims, and it must build and pass tests before it can merge — so incoherent or broken work never lands.
  • Foundational rules sit at a higher tier and can't be casually overridden by a quick fix.
  • Credentials and the write path are structurally out of an agent's reach — it can't bypass the gates because it never holds the keys.

The gates are guidance, not just a wall

Before an agent touches code, it reads the decisions that govern it — the choices made, the reasoning, the alternatives ruled out. So most of the time the gate isn't stopping a bad agent; it's stopping a well-meaning one from making a mistake it couldn't have known about. When a change can't merge cleanly, the error tells the agent exactly what to fix, and it self-corrects without a human in the loop.

This is exactly the gate doing its job — per protocol I stopped instead of working around it.
An AI agent, on being blocked mid-task · The gates are enforced and agents stop at them rather than route around them.

Related questions

Can an agent just bypass the gates if it decides to?

No. The write path and credentials sit outside the agents' reach — an agent never holds the keys, so there's nothing to route around. The only way to change code is through the gated path, and that path validates before anything lands.

What stops a single bad change from breaking everything?

Trunk is never written directly. A change goes into its own line of work, must prove it covers the decision it claims, and must build and pass tests before merging. Broken or incoherent work is blocked, not shipped.

Keep reading

Vibe-Engineering

Many agents. One codebase. Zero collisions.

Point your agents at CatWrangler and build — the discipline runs underneath.

Start free →private beta — come early