I've got an agent in a loop optimizing a renderer with the goal to minimize frame times (and tests to measure). It got times down from 88ms to 2ms and allocations down from ~150K to 500. Sounds good, right? Wrong. This is exactly why agent psychosis is a big fucking problem.
As an experiment, I rewrote the Ghostty core render state in Go, with access to identically laid out data structures as Ghostty and the exact same validation tests. I made a purposely naive renderer (simple, correct, but slow). 88ms per frame with 150,000 allocations (horrendous, lol)!
I then kickstarted a Ralph loop to bring the frame times down. I told it it can't modify input data structures or the public API or tests (they're correct), but it can do anything else it wants. It got to work.
It has worked for about 4 hours. I've spent around $350 on this experiment so far. The results?
88ms => 1.5ms
150K allocs => ~500 allocs
Incredible right? Nope.
My hand-written renderer I ported has frame times (same benchmark) of ~20us (0.020ms) and 0 allocations in the update path.
This is the problem with psychosis and lacking systems understanding. If you don't understand the system, you're going to accept that this is an incredible result. If you understand the system, you'll see better solutions immediately and can do roughly 75x better on throughput.
The people who blindly trust agent output are in the former camp. They're sheeple, overdrinking from a fountain of mediocrity.
Standard disclaimer: I use AI all the time. I like AI. The point I'm making is to not blindly accept results. Think. Analyze. Learn.
Fork your dependencies, trim them to only your use case, never update unless it breaks for your users. Iโve been vocal about this for 10+ years. Iโve always said that updating is way riskier than latent bugs (which can be tracked and CVEs monitored).
If you are updating a dependency, itโs on you to analyze every single commit in the full transitive set of dependencies. If you dont see anything compelling, dont update!
I remember at HashiCorp once in awhile an engineer would try to update a dep or replace a DIY lib with an external one and id always ask โshow me the commit we need.โ Dont update for the sake of it.
Feeling pretty swell about this mentality with all the supply chain attacks happening.
Activist: "Wool is cruel. The sheep should be left alone."
Farmer: "Alone where?"
Activist: "In a sanctuary."
Farmer: "Doing what."
Activist: "Just being a sheep."
Farmer: "Sheep have been bred for ten thousand years to grow a fleece that doesn't stop. If I don't shear her, she overheats, gets fly strike, and dies in her own coat with maggots eating her from the skin down."
Activist: "Then breed sheep that don't grow wool."
Farmer: "We did. They're called mouflon. They live on cliffs in Sardinia and would last forty minutes on a Welsh hillside before something ate them."
Activist: "I just don't think we should use animals for clothing."
Farmer: "What's your jumper made of."
Activist: "...recycled polyester."
Farmer: "Plastic, then. Sheds microfibre into the washing machine every wash. The fibres go through the filter, into the river, into the fish, into you. When you're done with it, it sits in a landfill for four hundred years. My sheep's fleece composts in a hedge in eighteen months and grew back on her this spring."
Activist: "But the sheep didn't consent."
Farmer: "She was lying down with her eyes closed when I finished. She got up and went back to eating. I'd suggest you ask her how she feels, but she's busy, and I think she's already given her answer."
My dear front-end developers (and anyone whoโs interested in the future of interfaces):
I have crawled through depths of hell to bring you, for the foreseeable years, one of the more important foundational pieces of UI engineering (if not in implementation then certainly at least in concept):
Fast, accurate and comprehensive userland text measurement algorithm in pure TypeScript, usable for laying out entire web pages without CSS, bypassing DOM measurements and reflow
@om_patel5 - LSP is enabled by default
- Sadly, it doesnโt make Claude 600x faster
- it is kind of popula but probably too hard to use. It works well in some codebases.
Whoever loses their engineering jobs to AI, probably dead weight, just ticket draggers. Iโd fire anyone who isnโt averaging 10 concurrent instances of ai agents on the spot, without a damn good reason for not doing so. At previous companies. I know for a fact youโd be able to cut headcount by 80% and either arm or replace the last 20% with devs who can wield a handful of coding agents very, very well. Get good, or gone.
This has been said a thousand times before, but allow me to add my own voice: the era of humans writing code is over. Disturbing for those of us who identify as SWEs, but no less true. That's not to say SWEs don't have work to do, but writing syntax directly is not it.