Karpathy's Experiment: Vision Feedback is Procedural Gen Bottleneck

MediumCulture6537 · reddit · 2026-08-07

Andrej Karpathy recently shared an experiment giving Opus 5 a 1M token budget to generate 5500 lines of Three.js code for a procedural rendering of the Lord of the Rings opening. He concluded that while models can write massive code blocks, their biggest weakness is auditing their own visual output.

The author validated this by running a similar WebGL generation experiment. In 3D scene generation, initial code drafts are typically filled with visual errors like floating meshes or clipping geometry. Fixing this requires running a headless browser to capture screenshots and passing them back to a vision model for inspection.

The experiment revealed that writing thousands of lines of code was the easy part; the real cost and latency spike came from the iterative vision feedback loop (often requiring 30+ screenshot cycles). Until models can natively perceive video frames, visual verification loops will remain the most expensive step.

Original post →

More from coding & agent

coding & agent channel →