Joy & Curiosity #76

Interesting & joyful things from the previous week

Open on Substack · Markdown

This week I found myself writing code by hand again.

Not a lot, maybe ten, twenty lines in total, which is far less than what I had Amp produce, but still: actual typing out of code. Miracle I didn’t get any blisters.

At our Amp meetup in Singapore I mentioned this on stage and someone in the audience cheekily asked: “You just told us that these agents can now work well when you give them a longer leash and yet you wrote code by hand, how come?”

The answer can probably be boiled down to something that sounds very trite: to build software means to learn.

When you build a new piece of software, you learn what the software is actually supposed to do, how it should do it, and why your pre-building ideas now seem naive. (If you’re thinking “well, can’t we figure out all of that before we build” go ahead and type “waterfall software” into Google.)

Right now, at Amp, we’re building something new. We don’t yet know everything about this thing we’re building. We don’t know how it should behave in this case, or in that case, how the runtime behaves here, or over there.

Writing code by hand is one way (!) to answer these questions, because you truly bump into what you don’t know when you have to type something out. You find yourself picking an array and write down that the type for clients is Client[] and then you wonder: wait a second, do we even need to allow for multiple clients to be connected at the same time? why? when? No, we actually don’t, it should be client: Client.

An agent is happy to pick an answer for you — without telling you. It will just write the code.

That might not be a problem. If you’re not building something new or if you don’t even need to learn how the software works (which is probably more often the case than you might think) or if you already have a good mental model, let the agent rip. In fact, I’d even say that in the majority of cases it’s not a problem, because most software development is not building something new.

But if you need learn, so you can make better engineering tradeoffs and product decisions, it seems to me that one of the most practical ways to do might just still be to get your hands dirty. Let’s see how long that lasts.