• Sources: primary
  • Summary: PostgresAI ran 10 models on 19 scenarios with 5 repeats on live two-node Postgres 18.7 clusters under load, and 13 of 408 changes executed on the primary caused measured harm, including Grok 4.7 dropping indexes unused on the primary but hot on an async standby. It proposes AAA, where an Analyst drafts a change, a deterministic Actor rehearses it on a live clone and is the sole write path, and an Auditor model reviews the clone evidence. In an in-sample replay the clone gate stopped 6 harms at no LLM cost and a Fable 5.2 Auditor stopped 6 more, while 377 of 378 safe or unclassified changes stayed approved.
  • Why it matters: Agents that change production databases need per-node telemetry and clone rehearsal under load, since primary-only checks and green 60-second summaries missed real harm.
  • Background: Many Postgres DDL statements take an AccessExclusiveLock, and a pending one queues every later reader and writer on the table behind it. Safe patterns split work, such as adding a constraint NOT VALID and validating it in a separate transaction. Index usage counters in pg_stat_user_indexes are per node, so an index idle on the primary can still serve replica reads.