by aidos · 3mo ago · 0 comments
Meanwhile, one peak at the code and you can already see the state starting to become a bit of a spaghetti mess.
It’s a funny time to live through. A lot of code is being written and a lot of it is going to be a real future burden.
This assumes that the models of the future won't find it easier to just throw the code away and rebuild it
This also assumes that the same application build by humans wouldn't become a "spaghetti mess".
I have noticed this with co-workers also, when you have the ability to read/write/understand things very quickly, you tend to spend much less time on making things tidy, clear and maintainable.
Compare that to clean, organized code where patterns and extensibility are established. I’ve seen product manager surprised at how fast a new feature was added when everything is laid out well.
sometimes starting from scratch just faster and/or easier.
You use another AI to document the spaghetti.
You use the third AI to make a spicy meatball from the spec.
What about all the undocumented "adjustments" ("bug fixes" in a professional context) that were made to make it actually useful?
nah, it reflects on how applications built by humans usually do become spaghetti messes with all the resulting brittleness and unintended negative side effects of changes that result
but it probably doesn't matter for a little toy piano app
ed sp
Sometimes it seems like they're moving very slowly. That makes sense: It's easy to get used to how they work today and it is also easy to forget how much worse they were last year.
When we look back and realize that just 4 years ago these tools didn't really exist at all, it becomes clear that the rate of progress is rather amazing.
In 4 years, we've gone from "hah, good luck with that crap!" to "little kids writing music-learning games on their own in a few minutes"
That's pretty friggin' awesome, and it's not finished yet. :)
Since this is Claude, the models of the future might be more expensive, or more locked down, or might decide your 8yo is actually trying to build a cleverly disguised bomb so her request gets silently downgraded to a dumber model, etc.
I remember when they would always hallucinate APIs that wasn't there or make up fields that didn't exist.. those problems are virtually solved now.
So with that in mind, why wouldn't AI be able to write better code?
The code would have to be maintainable by AI itself (operating based on the assumption that the future will be Agentic Engineering)
Not you, of course. You write exceptional code with zero errors that never needs rework. I'm talking about the rest of us.
i write pretty good code when i need or want to, yeah. sadly LLM code gives me a headache so the current psychosis standard has made work a bit painful.
the codebases are becoming LLM-first human-second so even if i wanted to be natty it's not really viable. might as well spend my employer's money.
Today I don't always need to understand the code. When I do, I can ask the LLM to explain the code or to specify the algorithm in pseudocode or even re-write the code until I can understand it.
I think, as an industry, we haven't yet fully grasped the impact of agentic coding. We don't yet know what software engineering is going to be like in 5 to 10 years.
then ... in some places (maybe cars that people care about working on) it became cleaner again. In the other places, they added a second hood to hide the mess.
There is some clean code out there, like maybe the seL4 kernel:
https://en.wikipedia.org/wiki/SeL4
"with an explicit goal of enabling comprehensive formal verification..." (and lots more stuff)
maybe we can still have niches like this.
The purpose of a car itself didn't change. But the massive inflated demand, as our city planners decided every adult must be put in a rolling metal cage to participate in society, changed the environment it was originally designed for.
Now it's a matter of geopolitical stability, or even basic human habitability of these spaces, that a car converts as much of that chemical energy into movement, and releases as little toxic byproducts in the process. Whereas before, that cost, at scale, was small enough to neglect.
Just like a modern CPU evolved into an incomprehensible mess, even though the basic consumer needs hadn't changed much, because the politics of computing forced them to run expanding institutional cruft at reasonable speeds, on battery-powered always-on addiction machines.
Those cleaner looking engine bays are usually worse to work on. Not better.
When you open up the hood and immediately see lines everywhere, that also means they’re within reach. This is great.
The engine bays that look nice and clean for the showroom still have those same lines. They’re just buried in there. If you need to work on them you’re going to be reaching underneath things, climbing under the car, or even removing other parts to access something simple.
Also, it’s not all about emissions. A lot of those lines are for modern comforts like cruise control and improvements like features that make cold starts easier or make the engine behave better at extreme temperatures. Some of those have been superseded by electronically controlled versions which is why some of those lines are disappearing on modern cars, but the overall complexity has increased further.
another analogy would be opening some computers to add memory/ssd/hd, as judged by ifixit
I remember installing seventy-two individual DIP chips onto an Everex 2-megabyte 8-bit ISA EMS expansion card and downloading software to make it work in MS-DOS from Intel's dial-up BBS. I remember chains of MFM drives being made to work by keying obscure commands into debug to run programs that were built into the hard drive controller card.
Oh, so many fun evenings working out which devices could share IRQs and configuring software to work around the corner cases that developed. Serial mice, PS/2 mice, plus bus mice of several different varieties. XT, AT, and PS/2 keyboards. The veritable plethora of mutually-incompatible CD-ROM interfaces.
A clock card: A whole friggin' card with a clock chip and a battery, just to keep track of wall time. (And the software to make it work.)
I even remember SCSI, which was famously renowned for the number of goat sacrifices that were required to to make it work. (Except, I remember SCSI very fondly. CD burner, reader, 7-disc Nakamichi changer, flatbed scanner, DDS tape, and a few IBM Ultrastar 9ES hard drives all sharing the same bus? Sure, why not? It worked. But it took some care to get there.)
It's simple today. Want more storage? SATA is easy (and everyone will make fun of you, but USB 3 works great for a hard drive in a desktop rig). m.2 is compact, and only has a couple of variations. Video cards -- even multiples of them -- just slot right into motherboards and they don't even have jumbers to configure. Sound cards are forgotten. RAM comes in standard forms that only change once every decade or so. Input devices, basic NICs, and video capture stuff can just plug in with USB. The USB ports themselves can be multiplied using hubs.
It's pretty good today, isn't it? Am I missing something?
That is how compiler-generated assembly looks to humans, as well. Human-produced is typically much more readable. Yet, here we are. Most programmers only know the very basics of assembly programming, but the world keeps spinning just fine.
2. Compilers and building tool chains change all the time. CI and automated testing catch any regressions. Tye same can be done with LLMs.
3. LLM code generation, with some work, can be made deterministic, if that mattered to somebody.
Tests are not a one time thing. They need to be maintained, and if you use same LLM to do it, it will happily delete failing ones, so better use a seaparate agent, and be prepared for the bill.
Even the implicit claim that they could deterministically produce "the" correct answer with 100% certainty doesn't withstand any scrutiny.
Nevermind problems posed in English prose, complicated or philosophical questions. Is the correct answer to 2+2 four, or is it 1+3? When you you have 2 apples and give me one apple, how many apples do you have now; one, or half as many as before? What is the correct answer? Without a spaghetti of arbitrary axioms in the system prompt? Even if you come up with something clever about apples, it even fails at "when is your birthday". When it is today, should I say "today" or say the date? Not even God could decide that.
Arguably, the specifications for a compiler is also such a mess of axioms, and you can split hairs and say "it's all random anyway", but you'll still use a seatbelt instead of silly string, so what gives?
For compilers, give or take, there is a correct output for a given input (under which I'll include config, options, the targeted architecture, whatever). With LLM there is no such thing even if you do infinite mental backflips, and there won't be, because there can't be. Even if you could perfect the compilers that are needed to make the software that trains and drives LLM deterministic, you cannot make LLM fully deterministic without making them not an LLM.
If you can find a way to encode what a compiler would do to programs into the weights of a model so that produces the output of a compiler that would be a cool and completely useless feat, because it would probably be bigger, slower and impossible to reason about. But it would still be cool and I would still try it out.
Well in this case, for the idea it was already in the training data. User said was out of ideas...trying to prop up the LLM smartness...
https://www.lifewire.com/how-to-find-a-lost-bluetooth-device...
https://android.stackexchange.com/questions/194584/locating-...
https://forums.macrumors.com/threads/i-lost-my-cellphone-som...
https://discussions.apple.com/thread/3317786?
And about the code...well...
- Complete Android code example specifically explains that Bluetooth RSSI can be used, cautiously, as a distance indicator. - https://mobile.fhstp.ac.at/development/rssi-messungen-von-bl...
- android-Bluetooth-RSSI-Scanner - https://github.com/TimingJL/android-Bluetooth-RSSI-Scanner
- https://stackoverflow.com/questions/22914532/ble-continuous-...
- https://github.com/alt236/Bluetooth-LE-Library---Android
These LLMs are mainly knowledge bases and compression engines.
And we thought it would be _visual programming_ that brought children to programming. Cool. Its logic.
If you're trying to get away from the burden of syntax or other onerous aspects of coding, well then just use an AI coding assistant. OTOH, if you (for some reason) want to learn a textual programming language, then write code in that language yourself.
Coding is a solution waiting for a problem kids don’t have yet. The answer is always “try a game”. But llm and logic can help children engage with the actual problems they have and what is flying around their little imaginations. Syntax and other code _constraints_ should not be the cost of entry.
I am, here, not counting time for separate instances of Claude (so 10 instances running for a year is not 10 years). So, I think the 8yo is still older.
Full disclosure, I am not a neurologist or computer scientist (although I find both interesting). I would consider fair criticism of this fair and would even like to see what those in those fields would have to say.
I honestly think people on here are very much overstating 'spaghetti code' when AI does it... first, it works correct? The reason I say that if the AI can continue to upgrade code that might not always look 'the prettiest' (to you..) because it doesn't care about what some of us consider to look like clean code. If it can continue to manage, document, and upgrade the code successfully.. does you calling it spaghetti code actually matter? Maybe you have a hard time reading it but the AI certainly doesn't.. I think that's worth consideration.
Every one of us has our own conventions and ideas of what 'clean' code looks like sometimes. And honestly 95% of the time we only thing it's clean if we wrote it ourselves.
On the other hand an engineer might take a couple hours and build this in a clean way with the right prompting
These “got ‘em” ai criticism comments are getting so old
The fact that this is possible and works at all is mind blowing - even more mind blowing is that my 8 yo is growing up in a world where they can talk to a machine to produce a custom application in seconds and they don’t realise how mind blowing it is!
In terms of the code, it would take even less time than that to tidy it up. For this application you wouldn’t bother. That’s almost a form of “premature optimisation” unless you’re actually planning on doing more work on it.
My hunch is that what the world is about to see a lot of is much bigger bits of work, or changes to other bigger existing systems done by people without the skills to know how to contain the complexity. That’s going to come with a burden.
However, the latter is an exercise that lets you become an expert. The former – not at all.
A novice writing code by hand could also write spaghetti code
If you've worked in enterprise software, you might have seen that even competent professionals can write spaghetti code
At this point AI really is just garbage in garbage out
Wild to me that we see this even in what is a relatively more “sophisticated” forum
I can absolutely prompt AI to following established patterns and produce nice, clean output in a legacy codebase. I also have a completely separate set of skill files that I’ve been building organically by allowing the agent to do make most decisions about conventions. The latter produces code that would be a nightmare to modify by hand, but I’m still able to iterate on it many times faster than I could in the codebase where code quality is a requirement.
“Code quality” is mostly “human readability”, and I’m simply not sure that’s a valuable attribute anymore.
I don't think we'll be looking at code at all within the next few years. I know I already don't anymore. The code is not the product for me, and as long as any model, commercial or local, can maintain it (or recreate it), I'm fine. When I make a drawing in a vector drawing program I don't export to PostScript to see if they calculated the bezier curves correctly either.
I'm convinced most code will be ephemeral in a few years.
So it's on par with humans, then.
And also the 1980s electronic toy, “Simon”