Don't make your coding agent read screenshots — assert visuals in code

victormustar · x · 2026-12-01

victor shares an HF dataset containing a practical guide for coding agents: screenshots are for humans, not for the agent. Instead of reading PNGs back to verify UI claims, translate each visual assertion into a code check — e.g. modal visibility via getComputedStyle, animation via canvas hashes 500ms apart, wall bounce via sign flips in velocity, color via getImageData, layout overlap via bounding-rect intersection. Genuinely subjective judgments (does the generative art look pretty) should be saved as screenshots and left to the user.

Original post →

More from coding & agent

coding & agent channel →