Live data from Hacker News

Using AI for Coding: My Journey with Cline and LLMs

pgaleone.eu

61–70 of 97 posts

Re: Using AI for Coding: My Journey with Cline and LLMs

#61

I like looking at stack overflow for coding examples and seeing a couple of nerds getting angry at each other about the best way to do stuff. or some interesting other ways of doing stuff. this is also why i come to HN! so its weird when people want to drop that small joy from their workday

hard disagree. the amount of snobbiness and rude closing of threads as power trips was unbearable. I'm glad LLMs learned off them and we are where we are now

I've often heard this often and I don't buy it. Granted some mods could give some more time for users to rewrite but that's all. Users write bad questions or don't look up answers already solving it. It's a skill issue. Regardless trusting an LLM that's confidentiality incorrect a bit too offen is not really a trade up.

If you consider most of the questions may not be actually "new questions" and have answers already, sometimes if it's important enough it's worth actually putting the effort in to understand the problem and solve it yourself. The over dependance that people are developing on LLMs is a little concerning.

Re: Using AI for Coding: My Journey with Cline and LLMs

#62
post #47

Prompt quality and knowing your domain is critical. One issue I had early on was experimenting with LLMs to generate a frontend application in a brand new framework I was unfamiliar with (Svelte at the time) which lead to situations where I would cruise along and get stuck in a loop. The other issue came from the increasing context size that led to more unpredictable behaviors (i would ask it to change the color of a…

By that time you can have your personal humanoid robot clean your gutter. You just do nothing but prompt, what a life that’s gonna be.

Can't prompting be automated?

Re: Using AI for Coding: My Journey with Cline and LLMs

#63
post #57

Earlier quoted context omitted.

Impossible of yesterday became mundane today and obsolete tomorrow. Pace of progress is borderline debilitating, when you aren’t deafened by the woosh of goalposts flying past you. I can confidently say the way I code today is completely different from the way I was coding in late 2022 and it changed a couple times in between then and now, too.

"Isn't Lean just the same Six Sigma stuff you were selling us a year ago?" "No no no no no. This has a totally different name"

Yeah except throwing shit together for an internal react ui is now a pleasant couple hours instead of painful couple days.

Re: Using AI for Coding: My Journey with Cline and LLMs

#64
post #33
post #15

Earlier quoted context omitted.

The way to fix that is to find an example of correct usage of that API and paste that example in at the start of the prompt. This technique can reliably make any good LLM fluent in an API that it's never seen in its training data.

Begs the question again: if you need to go out of your way to find an example of correct usage of the api to paste into the prompt, why are you even bothering? I find copilot useful when I already know what I want and start typing it out, at a certain point the scope of the problem is narrowed sufficiently for the LLM to fill the rest in. Of course this is more in line of “glorified autocomplete” than “replacing juni…

Because it still takes 5 mins for it to output the minimum viable change whereas it’d take me an hour

Re: Using AI for Coding: My Journey with Cline and LLMs

#65
post #8

Anyone got a line on a local first AI Tooling. Happy to pay100$. Don't want a subscription.

continue.dev, aider, Zed’s AI assistant are all free and will work with a local Ollama installation. You will of course need an insanely beefy and expensive machine to run any useful models at reasonable speeds, which would likely cover API usage costs for many, many years (an entire lifetime, likely).

Unless you want to fine tune your custom model and/or have strict on prem requirements… shit gets expensive fast, but it’s probably worth it for some

Re: Using AI for Coding: My Journey with Cline and LLMs

#66
post #47

Earlier quoted context omitted.

By that time you can have your personal humanoid robot clean your gutter. You just do nothing but prompt, what a life that’s gonna be.

Can't prompting be automated?

Welcome to the agentic age, where prompting can be just barely automated, but tokens are so cheap it doesn’t matter. Fresh off the presses as of last week

Re: Using AI for Coding: My Journey with Cline and LLMs

#67
post #58

Earlier quoted context omitted.

As opposed to wondering if the llm is hallucinating? You have to expend a mental effort to think about your solutions anyway; I guess it’s pick your poison really.

Thats the issue, people just copy and paste code from llms thinking "yeah, looks fine to me". It might be a skill issue, but personally it takes me a while to understand the code its giving me and even more on how to actually implement it with all the edge cases that might happen.

Before: I’m a lazy developer so I find the best libraries and abstract logic to write the least code and do least maintenance work.

Now: I’m a lazy developer, so I get a glorified autocomplete to write 10x code than what I have the willpower to. Of course, I won’t read all of it.

Re: Using AI for Coding: My Journey with Cline and LLMs

#68
post #54

Earlier quoted context omitted.

Same experience with context size and prompt quality. Some other things I picked up: - If you formulate a good prompt with small (but sufficient) context and it still makes mistakes after one attempt to feed the error message back to it, it's probably not going to be able to ever get it, no matter how many iterations you do with it. It will get stuck in a rut forever. Better not to argue with it. - o1-2024-12-17 is g…

When I catch an agent falling into a “debug loop” I ask it to summarize its understanding of the error. Next, I ask it to shift its context to a higher level in the code and look for patterns across my files which would impact {summary of error). It isn’t foolproof but it has a much better success rate for me than letting it spin.

Nice dude

Re: Using AI for Coding: My Journey with Cline and LLMs

#69
post #2

I did a similar thing but with backend-heavy code, and I agree with this assessment: > In particular, I asked ChatGPT to write a function by knowing precisely how I would have implemented it. This is crucial since without knowing the expected result and what every line does, I might end up with a wrong implementation. In my eyes, it makes the whole idea of AI coding moot. If I need to explain every step in detail - a…

There are tons of use cases. E.g. if you know an algorithm (take any pseudocode description from a moderately complex algorithm on Wikipedia for example) and you know the programming language, you still may be looking at an hour or two of typing just to get that pseudocode down into code using your own language, variable names, libraries.

But this is the kind of thing a LLM excels at. It gives you 200 lines of impl right away, you have a good understanding of both what it should look like and how it should work.

Slow and error prone to type but, but quick and easy to verify once done, that's the key use case for me.

Re: Using AI for Coding: My Journey with Cline and LLMs

#70
Anecdotal but here's how I described using the likes of Copilot to my sceptical colleagues (they were late to the party!):

It's like having a senior software dev over your shoulder. He knows pretty much everything about coding but he often comes to work drunk...

And that was the best analogy I could come up with: I think it's sped up my work enormously because I limit what it does, rather than let it loose... if that makes sense.

As an example, I was working on a C# project with a repository layer with a bunch of methods that just retrieved one or two values from the database, e.g. GetUsernameFromUserGuid, GetFirstnameFromUserGuid and so on. They each had a SQL query in them (I don't use ORM's...).

They weren't hard to write but there were quite a few of them.

Copilot learned after the first couple what I was doing so I only needed to type in "GetEmail" and it finished it off, (GetEmailAddressFromUserGuid) did the rest, including the SQL query and the style I used etc.

To me, that's where it shines!

Once you figure out where it works best and its limits, it's brilliant imo.

Post reply on HN