"PUA Prompting" Gemini to rewrite an app: state updates drop from 26.5ms to 0.036ms
vista8 · x · 2026-12-06
Blogger vista8 shared a live screenshot of a friend using wish-style "PUA prompts" to drive Google Gemini (Neon/Carbon) through a performance overhaul of a clipboard app:
- Memory cuts: lazy allocation for floating windows, auto-reclaiming 52 MB of full-screen Retina layers, adding autoreleasepool, eliminating 33 MB of leftover bitmaps and uncompressed TIFF storage — resident/peak memory pushed down to one-fifth
- Hot-path gains: state updates on 1,200 items went from 26.547ms to 0.036ms (737x faster), a single Retina clipboard image dropped from 10.47MB to 60KB on disk (170x smaller), cold full-text search 40x faster with SQLite FTS5 indexes in place
- Workflow: the agent explored files, ran commands, and edited code autonomously, validated by 40 clipboard unit tests + 86 Windows tests, keeping its own todo list as it iterates
The blogger jokes the end goal is to stop writing prompts altogether — "let the AI PUA itself into iterating."
More from coding & agent
- "Claude writes slop, then switch models to clean it": the new coding loop, memed — zephyr_z9 · 2026-12-06
- Specular finds replayable bugs, incl. a fundamental safety issue, in formally verified code — tianyin_xu · 2026-12-06
- Orchestrator runs parallel coding agents: DeepSeek, Sol and local Qwen 35B split the work — teortaxesTex · 2026-12-06
- Engineer: Neon nails optimization with right inputs but confidently fails when inputs are missing — caglar_ee · 2026-12-06
- Grok's 2026 X Wrapped crowns 'secure agent infrastructure' as one dev's top genre — OwariDa · 2026-12-06
- Soul Box: send cards from AI chats to friends or other AIs, built with Claude Code — BarcodeCutter · 2026-12-06