Live data from Hacker News

The hidden cost of AI coding

terriblesoftware.org

441–450 of 475 posts

Re: The hidden cost of AI coding

#441

Earlier quoted context omitted.

I love coding but I also love AI. I don't know if I'm a minority but I'd like to think there are a lot of folks like me out there. You can compare it to someone who is writing assembly code and now they've been introduced to C. They were happy writing assembly but now they're thrilled they can write things more quickly. Sure, AI could lead us to write buggier code. Sure, AI could make us dumber because we just have A…

We're the silent majority, I'm pretty sure. If you love coding, you probably love technology, and if you love technology, you probably love AI, which is inarguably the most interesting tech advancement in this decade. The others, who are not like us? They've got other priorities. If you hate coding but you love AI, you're probably into software engineering because of the money, not love of technology. If you love cod…

> If you love coding and you hate AI, you're probably more committed to some sort of ideology than you are the love of technology.

As someone that you may characterize as one of these people, I can share some perspective.

First, I would question the premise that “love of technology” is not itself an ideology.

I do love technology, but not for its own sake. I love solving problems, I love tinkering, and I love craftsmanship and invention.

But technology can also be dangerous, it can set us backwards and not forwards, and its progress is never as inevitable as its evangelists claim. You need to view technology with a critical eye, and remember that tools are tools, and not panaceas.

So I guess I’d ask you — what’s so wrong with choosing to live in a cabin in the woods without a cellphone?

Re: The hidden cost of AI coding

#442
post #191

Earlier quoted context omitted.

> flawed enough starting premise That's where we start to disagree what future looks like, then. It's not there yet, in that the LLM-clone isn't good enough. But amusingly a not nearly good enough clone of me already made me more productive, in that I'm able to deliver more while maintaining the same level of personal satisfaction with my code.

The question of increasing productivity and what that means for us as laborers is another entire can of worms, but that aside, I have never yet found LLM-gen'd code that met my personal standards, and sped up my total code output. If I want to spend my time refactoring and bugfixing and rewriting and integrating, rather than writing from scratch and bugfixing, I can definitely achieve that by using LLM code, but the…

This has been my experience as well, and really leaves me puzzled as to what anyone is gushing about.

Can I just about corral the LLM into producing working output? Yea, sometimes. From a technology perspective, that’s pretty cool!

But is it a productivity boost? Absolutely not. Like not even close. Every time it would have been faster for me to just write the code myself.

I really don’t know how to square the vast gulf between my experiences and many other peoples’.

Re: The hidden cost of AI coding

#443

Some people love programming, for the sake of programming itself. They love the CS theory, they love the tooling, they love most everything about it. Other people see all that as an means to an end - and find no joy from the technical aspect of creating something. They're more interested in the end result / product, rather than the process itself. I think that if you're in group A, it can be difficult to understand g…

> Some people love programming, for the sake of programming itself.

And this is what is causing the friction against LLM's (which are quite useful for getting up to speed with a new concept / language ), the programming itself is the fun bit - I still want to do that bit!

Re: The hidden cost of AI coding

#444

Earlier quoted context omitted.

You are just bad with prompting or working with very obscure language/framework or bad coding pattern or all of it. I had a talk with a seasoned engineer who has been coding for 50 years and has created many amazing things over lifetime about him having really bad results with AI tools I suggested for him. When I use AI for the same purposes in the same repo he's working on, it works nicely. When he does it, results…

I've had the same experience as the person to whom you're responding. After reading your post, I have to ask: if you're putting so much effort into prompting it with specific points, correcting it often, etc., why not just write the code yourself? It sounds like you're putting a good deal of effort into prompting it. Aren't you worried that overtime you'll rely on it too much and your offhand knowledge will get worse…

I'm still spending less effort/time. A very significant amount.

I do write plenty of things myself. Sometimes, I ignore AI completely and write 100s of lines. Sometimes, I take copilot suggestions every other line, as I'm writing something "common" and copilot can "read" my mind. And sometimes, I write 100s of lines purely by prompting. It is a fine line when to do which; also depends on mood.

I am not worried about that as I spend hours everyday reading. I'm also the type of person who, when something is needed in a document, do not search for it using CTRL+F, but manually look thru it. It always takes more time but I also learn adjacent things to the topic I need.

And I never commit a single line from AI without reading and understanding it myself. So it might come up with 100 line solution for me, but I probably already know what I wanted and off chance it came up with something correct but in a way I did not know, I do read and learn it.

Ultimately, to me, the knowledge that I can !reset null in docker compose override is important. Remembering if it is !null reset or reset !null or !reset null (i.e., syntax) is not important. My offhand knowledge is not getting worse as I am constantly learning things; I just focus less on specific syntaxes or API signatures now.

You can apply the same argument with IDE. Almost all developers will fail to write proper JS/TS/Java etc without IDE help.

Re: The hidden cost of AI coding

#445

Earlier quoted context omitted.

I've had the same experience as the person to whom you're responding. After reading your post, I have to ask: if you're putting so much effort into prompting it with specific points, correcting it often, etc., why not just write the code yourself? It sounds like you're putting a good deal of effort into prompting it. Aren't you worried that overtime you'll rely on it too much and your offhand knowledge will get worse…

I have read somewhere, that LLMs are mostly helpful to junior developers. Is it possible the person claiming success with all these languages/tools/technologies is just on a junior level and is subjectively correct but has no point of reference how fast coding is for seniors and how quality code looks like?

1. You have read somewhere...but you don't have any experience. LLMs are really bad for Junior developers.

  A. They have no skills/exp to judge AI output
  B. They don't learn from sudden magical wall of code output
  C. They don't get to explore; thus don't learn.
  D. Ultimately, LLMs act as a bad drug to them that keeps them dependent and stagnant.
  E. LLMs are really good for higher end of senior devs. This also means, they don't need as many Juniors anymore and they don't mentor juniors much. This is the biggest loss for Juniors.
2. I think you are absolutely right. I became a Staff Engineer with junior level LLM coding. More power to me I guess :(

Re: The hidden cost of AI coding

#446

Earlier quoted context omitted.

You are just bad with prompting or working with very obscure language/framework or bad coding pattern or all of it. I had a talk with a seasoned engineer who has been coding for 50 years and has created many amazing things over lifetime about him having really bad results with AI tools I suggested for him. When I use AI for the same purposes in the same repo he's working on, it works nicely. When he does it, results…

I do not rule out, that I am just very bad with prompting. It just surprises me, that you write you had massive successes with "java, js/TS, html css, go, rust, python, bitbucket pipelines/GitHub actions, cdk, docker compose, SQL, flutter/dart, swift etc.", if you include the usual libraries/frameworks and the diverse application areas for these technologies, even with LLMs support it seems to me crazy to be able to…

Unfortunately, I'm at a stage of personal life where I do not have time to blog. I'd love to but :(

The stuff I work on for company is confidential and even getting authorization to use AI was such a hassle.

Based on some of your replies, I think you have an impression of current generation AIs that is 100% wrong. I can not blame you as the impression you have, is what the AI companies want you to have, that's what they are hyping.

In another comment, you mentioned someone should demo how AI can add a non-leaf feature to a non-trivial LOC codebase. This is what AI companies say AI can do. But the truth is, (current gen) AIs can not do this except a few rare cases. I can not demo this to you as I can't do this and do not attempt to do it either on day to day tasks.

The issue is context. What you are asking requires AI to have a huge amount of context that it simply is not equipped to handle (at least not right now).

What AIs are really good at is to do small fragment of a task given enough clear requirements.

When I want AI to write a Handler in my Controller, I don't just ask it to "write a function to handle POST call for entity E."

I write the javadoc /* */ comment that defines the signature and explains a little about how the core process of this handling works. I can even copy/paste similar handler from another controller if I think that will help.

Ultimately, my brain already knows the input, output and key transformations that needs to happen in this function. I just write minimal amount (esp comments) and get AI to complete the rest.

So if I need to write a non-leaf feature, I will break it down to several leaf features and then pass it on to AI and if needed, manually assemble them.

I had to write 500LOC bash script to handle a software deployment. This is not the way to do it but I was forced by circumstances created by someone else. Anyways, if I had to write the whole thing by hand, it'd take multiple days as bash syntax is not forgiving and the stuff I needed to do in the script were quite complex/crazy (and stupid).

I think I wrote about 50+ lines of text describing the whole process, which you can think of as a requirement document.

With a few tries, I was able to get the whole script with near accuracy. My reading revealed some issues. Pointed them to AI. It fixed them. Tests revealed some other issues. Again, AI fixed them after pointing out. I was able to get the whole thing done in just an hour or so.

Re: The hidden cost of AI coding

#447

Earlier quoted context omitted.

> It is a stubborn refusal to see that one could be programming something much more sophisticated if they could use these iteration loops efficiently Programming something more sophisticated with AI? AI is pretty much useless if you're doing anything somewhat novel. What it excels at is vomiting code that has already been written a million times so you can build yet another Electron cross-platform app.

what sort existing of projects do you think couldn't have been created with an AI-heavy workflow?

AI?

Re: The hidden cost of AI coding

#448

Earlier quoted context omitted.

> I think it’s fair to say a lot of gig workers, especially those with families, are having a very difficult time economically. Great point. I wonder if this has to do with the current housing crisis and cost of utilities... Food has never been more affordable, in fact free with food banks and soup kitchens. But (IMHO) onerous zoning has really slowed down development and driven up prices. Another cost is it's pretty…

I suspect it has to do with a lot of things: * Everything is more expensive. You say "food has never been more affordable" but I'll absolutely challenge that. Food banks and kitchens are heavily locale-dependent type resources, and are not distributed according to the needs of the populace, but rather according to the ability and willingness of given communities to sustain them. * You skated right past the need for a…

I'm really struggling to understand your argument, are you trying to argue in short-term or long-term trends? I'm trying to argue that in aggregate, life is getting better for people, while also awknowledging that there's not an equal distribution. For example, food has decreased in price 4x since 1900 in real terms[1]. I don't see how that's not more affordable.

> You skated right past the need for a smartphone.

Hmm? Like when I said "Another cost is it's pretty much impossible to do anything without a smartphone and internet"?

> a good Uber Eats driver can make about $13 to $16 an hour

Source? That doesn't line up with what I found.

> A performance, mind, that is subject to dozens of factors entirely outside the control of the driver.

This is just FUD if you haven't cited your sources on average/median/distribution of pay in whatever area.

You have a very good point on liability issues though.

> The solution is I think quite simple here

Thus increasing prices of rides, causing users to stop using the service, further shrinking pay? Uber just started being profitable after dumping billions of dollars in subsidies, on top of bad pay. If you make them full-time employees, you may just shut off the one source of income they have.

Uber won because they offered a superior service to taxis. I'm not going to open the can of worms of their predatory behavior, but there was still a significant part that was a better service.

Again, I am planning on helping these people, I think they should be helped, but you really need to think through what could happen if you force a company to become insolvent.

[1] https://ourworldindata.org/grapher/long-term-prices-food?foc...

Re: The hidden cost of AI coding

#449
post #63

Earlier quoted context omitted.

The output of the LLM is probabilistic. The code you actually commit or merge is not.

Exactly. If LLMs were like higher level languages you'd be committing the prompt. LLMs are actually like auto-complete, snippets, stackoverflow and rosetta code. It's not a higher level of abstraction, it's a tool for writing code.

It's not a higher-level language, I mean it's a productivity tool. It's not going to take away the joy or demand for coding, like how C didn't ruin things by cheapening assembly creation.

Re: The hidden cost of AI coding

#450

Earlier quoted context omitted.

> You don’t invest in your future ... the average tenure of a software developer is 3 years and at any time an employee can leave. Well this is a 2 stage problem and I think the response is bad for multiple reasons. 1) Tragedy of the Commons: If we all act like this, then no one gets invested in. If we all invest in our employees then when they leave another company gets the rewards. That's still true when "we" are t…

I agree with you, but I think that there's one area of the argument that is worth figuring out how to strengthen. > If we all invest in our employees then when they leave another company gets the rewards. That's still true when "we" are the "other company". You still benefit regardless. Under the condition that most companies (or rather at least the big companies) collude in this way. They have good reason to as coal…

  > However, in that world, a company that chooses not to contribute
I swore I addressed this point, but I can't find it. You're right. I should have addressed this.

But this is still not an optimal strategy. It can give you a short term edge, but you're completely right that it destroys the natural coalition equilibrium. The result is that this destroys the coalition. You get the benefit for a small time period but it doesn't take long for the coalition to be abandoned and once that is done, you no longer gain from this strategy. In this situation the total utility in the system decreases! Not just globally, but each player's utility drops! That's a major problem! It is sacrificing long term rewards for short term ones. Importantly, those long term rewards are quite significant while the short term ones are not.

  > How do we adjust the incentives so that bad actors are not motivated to cheat the system?
My answer? The government. I'm not a fan of big government, but they definitely have a role to play in the economy. A third party actor that serves as a moderator. Regulation to ensure that (near) globally beneficial (yet unstable) equilibria are maintained. Such regulation is beneficial to all parties involved, even the one that wants to undermine the coalition. I mean we can't just have shit being fucked up every time there's a dumb or malicious actor. A lot of things are unstable equilibria and it does take work to maintain them. A third party (especially one that benefits from global utility as opposed to individual utility) is necessary for stability. The other answer is, of course "The People". But this is a much more chaotic group, more easily influenced by nearsighted actors who can often convince them to also be shortsighted, especially when dealing with more abstract concepts..

  > this is similar to playing Iterated Prisoners' Dilemma
It's worth noting here that Tit-for-tat strategies are optimal in this game AND maximal utility to any party is achieved when all parties cooperate continuously. But it is worth noting that humans are a bit irrational and have memory. Also worth noting that human actors are not rational. Hence the need for a third party moderator, which logically benefits both parties by saying "Stop being dumb and shooting yourself in the foot. This is an iterative game."

For some reason people think zero-sum games are common. Lump of Labor (Fixed-Pie) Fallacy is really common[0]. I do see high rates of zero-sum thinking around here on HN and in CS communities, and I'm not sure why it is so common. While I don't have the same expectations for the general public, we create things out of essentially limitless resources. We frequently create value that does not require additional compute or meaningful consumption of current resources (which is also increasing as time marches on). Our whole job is built on the fact that the pie continually grows in size and we are strongly rewarded for making the pie larger in the first place!

[0] https://en.wikipedia.org/wiki/Lump_of_labour_fallacy

Post reply on HN