Building a branch-and-merge database guardrail so LLM agents can't wreck production
Antique-Willow-5841 · reddit · 2026-10-17
After an LLM agent with write access deleted all their CRM lead lists, the author built a sidecar database: agents work on copied-table branches, merges go back to Postgres in one transaction, gated by per-row three-way merge, read tracking, SQL checks, no-delete rules and held side effects. Post dives into hard-won lessons: text-based row comparison to avoid false conflicts, reserving serial ids from production sequences, SET LOCAL under PgBouncer, and crash-safe merge id pre-writing. Beta status, 10k rows per merge max.
Related event: Developer Builds Git-Style Branched Postgres After AI Agent Wipes CRM Data(3 posts)→
More from coding & agent
- UNC's Wanda: agentic AI for neuroimaging validated on 123,000 brains — PTenigma · 2026-12-02
- Software products need an API/MCP/plugin now: agents will drive acquisition and retention — omooretweets · 2026-12-02
- AI coding tools are self-configuring: install Claude Code and you're done — _jaydeepkarale · 2026-12-02
- Image-to-Blender showdown: Neon crushes Opus with a huge gap — YouJiacheng · 2026-12-02
- Matt Shumer says collaborating with Jacob humbles his AI-orchestration skills ahead of Spawn — mattshumer_ · 2026-12-02
- LiveCraft benchmark: top agents score just 30.3/100 in real-time Minecraft worlds — Chengxing Xie · 2026-12-02