Live data from Hacker News

How I program with agents

crawshaw.io

131–140 of 308 posts

Re: How I program with agents

#131

Maybe it's because I only code for my own tools, but I still don't understand the benefit of relying on someone/something else to write your code and then reading it, understand it, fixing it, etc. Although asking an LLM to extract and find the thing I'm looking for in an API Doc is super useful and time saving. To me, it's not even about how good these LLMs get in the future. I just don't like reading other people's…

You’re clinging to an old model of work. Today an LLM converted my docker compose infrastructure to Kubernetes, using operators and helm charts as needed. It did in 10 minutes what would take me several days to learn and cobble together a bad solution. I review every small update and correct it when needed. It is so much more productive. I’m driving a tractor while you are pulling an ox cart.

[deleted]

Re: How I program with agents

#132
post #93
post #13

Earlier quoted context omitted.

Here are the cases where it helps me (I promise this isn't ai generated even though im using a list...) - Formulaic code. It basically obviates the need for macros / code gen. The downside is that they are slower and you can't just update the macro and re-generate. The upside is it works for code that is slightly formulaic but has some slight differences across implementations that make macros impossible to use. - Us…

> Using apis I am familiar with but don't have memorized I think you have to be careful here even with a typed language. For example, I generated some Go code recently which execed a shell command and got the output. The generated code used CombinedOutput which is easier to used but doesn't do proper error handling. Everything ran fine until I tested a few error cases and then realized the problem. In other times I a…

You always have to be careful. But worth calling out that using CombinedOutput() like that is also a common flaw in human code.

Re: How I program with agents

#133

Earlier quoted context omitted.

I like your take and the metaphors are good at helping demonstrate by example. One caveat I wonder about is how this kind of constant context switching combines with the need to think deeply (and defensively with non humans). My gut says I'd struggle at also being the brain at the end of the day instead of just the director/conductor. I've actively paired with multiple people at once before because of a time crunch (…

> I've actively paired with multiple people at once That was my favorite part of being a professional cook, working closely on a team. Humans are social animals who haven't -- including how our brains are wired -- changed much physiologically in the past 25,000 years. Smart people today are not much smarter than smart people in Greece 3,000 years ago, except for the sample size of 8B people being larger. We are wired…

I have always found this idea of not being smarter somewhat baffling. Education makes people smarter does it not? At least that is one of the claims it makes. Do you mean that a baby hunter gatherer from 25000 years ago would be on average just as capable of learning stuff when integrated into society compared to someone born nowadays? For human beings 25.000 years is something like 1000 generations. There will be subtle vgenetic variations and evolutions on that scale of generations. But the real gains in "smartness" will be on a societal level. Remember: humans without society are not very different from "dumber" animals like apes and dogs. You can see this very well with the cases of heavy neglect. Feral children are very animal-like and quite incapable of learning very effective...

Re: How I program with agents

#134
I tried code gen for the first time recently. The generated code look great, was commented and ran perfectly. The results were completely wrong. The code was to calculate the cpu temperature from the Raspberry Pi RP2350 in python. The initial value look about right, then I put my finger on the chip and the temp went down! I assume the model had been trained on broken code. This lead me to think how do they validate code does what it says

Re: How I program with agents

#135

Some of my favorite things to use AI for when coding (I swear I wrote this not AI!): - CSS: I don't like working with CSS on any website ever, and all of the kludges added on-top of it don't make it any more fun. AI makes it a little fun since it can remember all the CSS hacks so I don't have to spend an hour figuring out how to center some element on the page. Even if it doesn't get it right the first time, it still…

Interesting, I found AIs annoyingly incapable of writing good CSS. But I understand the appeal of using it for a task that you do not like to do yourself. For me it's writing ticket descriptions which it does way better than me.

Re: How I program with agents

#136

I tried code gen for the first time recently. The generated code look great, was commented and ran perfectly. The results were completely wrong. The code was to calculate the cpu temperature from the Raspberry Pi RP2350 in python. The initial value look about right, then I put my finger on the chip and the temp went down! I assume the model had been trained on broken code. This lead me to think how do they validate c…

Did you review the code itself, or test the code beyond just putting your finger on the chip? Is it possible that your finger was actually cooler than the chip and acted as a heat sink upon contact?

Re: How I program with agents

#137

Earlier quoted context omitted.

> I've actively paired with multiple people at once That was my favorite part of being a professional cook, working closely on a team. Humans are social animals who haven't -- including how our brains are wired -- changed much physiologically in the past 25,000 years. Smart people today are not much smarter than smart people in Greece 3,000 years ago, except for the sample size of 8B people being larger. We are wired…

I have always found this idea of not being smarter somewhat baffling. Education makes people smarter does it not? At least that is one of the claims it makes. Do you mean that a baby hunter gatherer from 25000 years ago would be on average just as capable of learning stuff when integrated into society compared to someone born nowadays? For human beings 25.000 years is something like 1000 generations. There will be su…

there's intelligence and there's wisdom. I may know how, eg Docker works and an ancient Greek man may not, but I can't remember a 12 digit number I've only seen once, or multiply two three digit numbers in my head without difficulty.

Re: How I program with agents

#138

Maybe it's because I only code for my own tools, but I still don't understand the benefit of relying on someone/something else to write your code and then reading it, understand it, fixing it, etc. Although asking an LLM to extract and find the thing I'm looking for in an API Doc is super useful and time saving. To me, it's not even about how good these LLMs get in the future. I just don't like reading other people's…

No different than most practices now. PM write a ticket, dev codes it, PRs it, then someone else reviews it. Not a bad practice. Sometimes a fresh set of eyes really helps.

I am not too familiar with software development inside large organizations as I work for myself - are there any of those steps the AI cannot do well? I mean it seems to me that if the AI is as good as humans at text based tasks you could have an entire software development process with no humans. I.e. user feedback or error messages go to a first LLM that writes a ticket. That ticket goes to a second LLM that writes code. That code goes to a 3rd LLM that reviews the code. That code goes through various automated tests in a CI / CD pipeline to catch issues. If no tests fail the updated software is deployed.

You could insert sanity checks by humans at various points but are any of these tasks outside the capabilities of an LLM?

Re: How I program with agents

#139
post #129

Earlier quoted context omitted.

“ It did in 10 minutes what would take me several days to learn and cobble together a bad solution.” Another way to look at this is you’re outsourcing your understanding to something that ultimately doesn’t think. This means 2 things: your solution could be severely suboptimal in multiple areas such as security and two because you didn’t bother understanding it yourself you’ll never be able to identify that. You migh…

Senior engineers delegate to junior engineers, which have all the same downsides you described, all the time. This pattern seems to work fine for virtually every software company in existence.

Comparing apples to oranges in your response but I’ll address it anyway.

I see this take brought up quite a bit and it’s honestly just plain wrong.

For starters Junior engineers can be held accountable. What we see currently is people leaving gaping holes in software and then pointing at the LLM which is an unthinking tool. Not the same.

Juniors can and should be taught as that is what causes them to progress not only in SD but also gets them familiar with your code base. Unless your company is a CRUD printer you need that.

More closely to the issue at hand this is assuming the “senior” dev isn’t just using an LLM as well and doesn’t know enough to critique the output. I can tell you that juniors aren’t the ones making glaring mistakes in terms of security when I get a call.

So, no, not the same. The argument is that you need enough knowledge of the subject call bs to effectively use these tools.

Re: How I program with agents

#140
post #15

Earlier quoted context omitted.

On one codebase I work with, there are often tasks that involve changing multiple files in a relatively predictable way. Like there is little creativity/challenge, but a lot of typing in multiple parts/files. Tasks like these used to take 3-4 hours complete before just because I had to physically open all these files, find right places to modify, type the code etc. With AI agent I just describe the task, and it does…

Did you ever consider refactoring the code so that you don't have to do shotgun surgery every time you make this kind of change?

A lot of that is inherent in the framework. eg Java and Go spew boilerplate. LLMs are actually pretty good at generating boilerplate.

See, also, testing. There's a lot of similar boilerplate for testing. Giving LLMs a list of "Test these specific items, with this specific setup, and these edge cases." I've been pretty happy writing a bulleted outline of tests and getting ... 85% complete code back? You can see a pretty stark line in a codebase I work on where I started doing this vs comprehensiveness of testing.

Post reply on HN