←back to thread

416 points floverfelt | 2 comments | | HN request time: 0.014s | source
Show context
ares623 ◴[] No.45056350[source]
> Other forms of engineering have to take into account the variability of the world.

> Maybe LLMs mark the point where we join our engineering peers in a world on non-determinism.

Those other forms of engineering have no choice due to the nature of what they are engineering.

Software engineers already have a way to introduce determinism into the systems they build! We’re going backwards!

replies(6): >>45056412 #>>45056449 #>>45056511 #>>45056669 #>>45056797 #>>45059375 #
tptacek ◴[] No.45056669[source]
'potatolicious says we're going forwards: https://news.ycombinator.com/item?id=44978319
replies(3): >>45056747 #>>45056812 #>>45057894 #
ants_everywhere ◴[] No.45056747[source]
adding to this, software deals with non-determinism all the time.

For example, web requests are non-deterministic. They depend, among other things, on the state of the network. They also depend on the load of the machine serving the request.

One way to think about this is: how easy is it for you to produce byte-for-byte deterministic builds of the software you're working on? If it's not trivial there's more non-determinism than is obvious.

replies(2): >>45056820 #>>45057213 #
skydhash ◴[] No.45056820[source]
Mostly the engineering part of software is dealing with non-determinism, by avoiding it or enforcing determinism. Take something like TCP, it's all about guaranteeing the determinism that either the message is sent and received or it is not. And we have a lot of algorithms that tries to guarantee consistency of information between the elements of a system.
replies(2): >>45056858 #>>45056960 #
ares623 ◴[] No.45056960[source]
But there is an underlying deterministic property in the TCP example. A message is either received within a timeout or not.

How can that be extralopated with LLMs? How does a system independently know that it's arrived at a correct answer within a timeout or not? Has the halting problem been solved?

replies(2): >>45057228 #>>45059115 #
skydhash ◴[] No.45059115[source]
> How can that be extralopated with LLMs? How does a system independently know that it's arrived at a correct answer within a timeout or not?

That's the catch 22 with LLM. You're supposed to be both the asker and the verifier. Which in practice, it's not that great. LLMs will just find the snippets of code that matches somehow and just act on it (It's the "I'm feeling Lucky" button with extra steps)

In traditional programming, coding is a notation too more than anything. You supposed to have a solution before coding, but because of how the human brain works, it's more like a blackboard, aka an helper for thinking. You write what you think is correct, verify your assumptions, then store and forget about all of it when that's true. Once in a while, you revisit the design and make it more elegant (at least you hope you're allowed to).

LLM programming, when first started, was more about a direct english to finished code translation. Now, hope has scaled down and it's more about precise specs to diff proposal. Which frankly does not improve productivity as you can either have a generator that's faster and more precise (less costly too) or you will need to read the same amount of docs to verify everything as you would need to do to code the stuff in the first place (80% of the time spent coding).

So no determinism with LLMs. The input does not have any formal aspects, and the output is randomly determined. And the domain is very large. It is like trying to find a specific grain of sand on a beach while not fully sure it's there. I suspect most people are doing the equivalent of taking a handful of sand and saying that's what they wanted all along.

replies(2): >>45059274 #>>45059449 #
tptacek ◴[] No.45059274[source]
No? These kinds of analyses all seem to rely on the notion that the LLM-caller needs to accept whatever output the LLM provides. In practice, they discard all the outputs that don't compile, and then a further subset of the ones that don't --- those outputs that aren't instantly clear to the caller.

My intuition for the problem here is that people are fixated on the nondeterminism of the LLM itself, which is of limited importance to the actual problem domain of code generation. The LLM might spit out ancient Egyptian hieroglyphics! It's true! The LLM is completely nondeterministic. But nothing like that is ever going to get merged into `main`.

It's fine if you want to go on about how bad "vibe coding" is, with LLM-callers that don't bother to read LLM output, because they're not competent. But here we're assuming an otherwise competent developer. You can say the vibe coder is the more important phenomenon, but the viber doesn't implicate the halting problem.

replies(1): >>45059450 #
skydhash ◴[] No.45059450[source]
Valid programs are almost infinite. Context free grammars (which describe valid programs) are generative. When you're programming, you are mostly restricting the set of valid program to include only the few that satisfy the specs. Adding an extra 0 to a number is valid, but put that in the context of money transactions, it's a "hell breaks loose" situation.

SO that's why "it compiles" is worthless in a business settings. Of course it should compile. That's the bare minimum of expectations. And even "it passes the tests" is not that great. That just means you have not mess things up. So review and quality (accountability for both) is paramount, so that the proper stuff get shipped (and fixed swiftly if there was a mistake).

replies(2): >>45059485 #>>45059535 #
tptacek ◴[] No.45059485{4}[source]
It feels like you stopped reading before "and then a further subset of those".

Again: my claim is simply that whatever else is going on, the halting problem doesn't enter into it, because the user in this scenario isn't obligated to prove arbitrary programs. Here, I can solve the halting problem right now: "only accept branchless programs with finite numbers of instructions". Where's my Field Medal? :)

It always feels like the "LLMs are nondeterministic" people are relying on the claim that it's impossible to tell whether an arbitrary program is branchless and finite. Obviously, no, that's not true.

replies(1): >>45059556 #
1. skydhash ◴[] No.45059556{4}[source]
> It feels like you stopped reading before "and then a further subset of those".

Pretty sure you've just edited to add that part.

replies(1): >>45059621 #
2. tptacek ◴[] No.45059621[source]
No, I'd have indicated that in my comment if I had. Sorry, I think you just missed it.

I did add the last paragraph of the comment you just responded to (the one immediately above this) about 5 seconds after I submitted it, though. Doesn't change the thread.