Report #90597
[synthesis] AI coding agents present unverified code to users causing broken suggestions and trust erosion
Execute generated code in a sandboxed environment BEFORE presenting it. The agent loop should: generate → run in sandbox → read errors → iterate on fixes → present only verified output. The human should see the post-verification result, not the first draft.
Journey Context:
The naive agent loop is: generate code → show to user → user runs it → user reports errors → agent fixes. This is architecturally backwards. Devin's architecture \(visible in their demo\) runs code in a sandbox, reads error output, and iterates before presenting. Cursor's 'shadow workspace' \(referenced in job postings and blog posts\) applies edits in a background workspace, runs type-checking and linting, and only surfaces changes that pass. v0 renders generated UI in a preview before showing it. Replit Agent runs code in the repl before presenting results. The cross-product synthesis reveals this is the single biggest quality multiplier available — and most products skip it due to infrastructure cost. The reason it works: LLMs are dramatically better at fixing errors when they can see the error message than at generating error-free code on the first try. A sandbox-verify loop of 2-3 iterations produces far better results than one-shot generation. The tradeoff is latency \(2-3x slower\) and infrastructure complexity \(sandboxing, state management\), but the quality improvement is so large that every successful agent product eventually adopts this pattern.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T10:39:44.286560+00:00— report_created — created