Hacker News new | ask | show | jobs
by cc62cf4a4f20 456 days ago
After spending some time vibe coding, I think this article is pretty accurate in that it aligns with a) how poor AI agents work in practice and b) the fact that non-coders are expecting magic from AI (which to be fair is what the AI companies are promising with all of their hype).

Where I have found vibe coding as an approach really shine is if I need to write some sort of quick utility to get a task done. Something that might take an hour or more to slap together to solve some menial task that I need to do on a bunch of files. Here I can definitely throw it together quicker than manually and don't care if it is messy code.

Larger, more complicated apps that are meant for production are painful to try to get AI tools to build. Spend so much time prompting the AI to get the task done without breaking something else that I doubt I'm any faster than just hand coding it alongside a co-pilot

1 comments

Claude Code released a little while ago and I've been using it on a production codebase at work. It's really good at repetitive tasks like filling out JSON schemas, cloning boilerplate logic, and so on. It's also honestly not half bad at helping point me to the right locations when bugs can be found.

I find that it works best when used by an actual programmer who has a good idea of exactly what they want to do and how they want it done. I often find myself telling it extremely specific things like, add a switch case in this callback in this file. Add a command in this file after this other one. Create a new file in this directory that follows the convention of all the others. And so on. If you instruct it well, you can then tell it to repeat what it just did for every item in a list that is like 20 items long and you will have saved hours of development time. Very rarely does it spit out fully functional code but it's very good at saving you the time it takes to constantly repeat yourself.

(This codebase isn't that good at DRY, I try my best with things like higher-order functions but there's only so much I can do, I still need to repeat myself in many cases.)

What do you mean cloning boiler plate logic? Don't you just write it once and then call the function? Need to change things? Okay do a little abstraction. But I thought a big part of coding was to reduce repetition
> What do you mean cloning boiler plate logic?

As an example, each tool callable by the AI needs its own input JSON schema, and in its execute function needs to send a request to the client, client needs to have a callback that handles that request, etc. it is very boilerplatey, bridges across multiple implementation languages, in completely different parts of the codebase, and Claude knocks it out in like 30 seconds flat so I can focus on the parts of the implementation that it slightly fucked up, but it usually gets the boilerplate bang-on.

So why not write something to generate that file? Or if you don't need to write to disk, just the data?
I'm not really sure what you mean. It saves me time to ask Claude Code to clone a file for me and repurpose it for a new tool compared to doing it all manually. And iterating on it can also be faster because I can tell it what transformations to make to the file and it tends to be faster than doing those transformations myself.

I still do a bit of manual post-processing but the end-to-end latency is a lot lower than if I had done all of the processing that manually.

Another relatively common pattern for me is to do a certain transformation manually once and then tell Claude Code to repeat it on all of the related tools. It does a good job at that too. I don't even have to manually tab through each file in my editor, or come up with some cursed find and replace pattern, or anything like that. It's just more time-efficient for me.

Note that I don't use an LLM to save mental effort. It's purely for saving time. People who try to use an LLM to save mental effort are usually using it wrong. You still need to know what you're doing in order to properly tell the LLM to do that.