| ▲ | iroddis 2 hours ago | |||||||
> For the person who only wants the notes, the sampler wins the job outright, completely. It will never play the wrong thing or at the wrong moment. For the person playing, it fails, because driving it costs more than playing, and it never touches the art at all. This entire essay could be about AI adoption as well. Some programmers love to program, and while AI is great at producing the code, it doesn’t really viscerally appeal if one loves coding itself. | ||||||||
| ▲ | klibertp 44 minutes ago | parent | next [-] | |||||||
> AI is great at producing the code It's not. The latest-and-greatest models on $200/mo subscriptions routinely produce bloated code full of boilerplate. They are incapable of producing elegant, concise, readable, correct-by-design code - they literally can't do it, even with the smallest samples, and it gets much worse as the scale of the implementation increases. You can't will the capability into them through prompts. You probably could do so with fine-tuning or other techniques, but I suspect that would just make the variance higher - and the average code quality would be much lower than it already is. The code generated by LLMs is passable, but never truly good. The same is true for LLM-generated designs and architectures, just even more so. They are trained on all the code out there, and the percentage of really good code is so vanishingly small that it's incredibly hard to replicate even for humans after a lifetime of learning. LLMs would need to reach a next level of capability to consistently recognize good code. Generating it consistently is out of the question for at least the next few generations of the AI. Not all code has to, or needs to, be good. LLM-generated code is useful and helpful. It's an incredible time-saver for one-off scripts, and you can make an LLM implement and maintain parts of the program you need, but don't care to make good at the moment. LLMs are very efficient (if we ignore externalities) and easy-to-use code generators, which is huge in itself. However, they are not great or even good at generating code. Last weekend, there was a post showcasing a Rust library with utility functions for writing parsers. It featured a simple line-by-line INI file parser. I decided to rewrite it in Python with PyParsing, a library I happen to know well. GPT-5.6-Sol High wrote the grammar that worked. It was tragically bloated, poorly factored, and multiple grammar problems were masked by parse actions. It worked, but it was decidedly bad code. I then rewrote the grammar by hand, getting it down to 1/3 of the length, eliminating all parse actions, and improving error messages in the process. I then spent 2 hours trying to convince the model to perform the same refactorings I did, but had to give up: no matter what I tried, the model couldn't get all the needed changes to coexist at the same time. When it got the terseness right, it inevitably ruined error handling. When it got the grammar right, it ruined the factoring. And so on. Later on, I decided to make the model rewrite the PyParsing grammar in Smalltalk's PetitParser - a pretty close match in terms of capabilities. I gave the model my version of the grammar. I told it to translate that Python code. It still butchered more than half of it, doing "optimizations" (the model's words) that replaced a cached production with a literal + 3 message sends in 8 places in the (trivial!) grammar. I explained what I value in the original code, why those are important features to keep, and tried again. It still couldn't give me an idiomatic Smalltalk translation, though it did get significantly closer. I concluded that the model has a very limited understanding of how concepts I wanted can manifest in actual code and called it a day. To give you an idea of the scale: excluding blank lines and imports, the grammar is exactly 10 lines of Python... So no - LLMs are not good at generating code. They are just fast and convenient, and again - that's huge. But it's nowhere near a level where it can be steered to produce good code - much less being able to generate good code by default. (I realize this post is a bit off topic and it's just an anecdote - but I've experienced this daily for the past half a year; I'm not basing my opinion on just that last attempt.) | ||||||||
| ||||||||
| ▲ | jottinger 2 hours ago | parent | prev | next [-] | |||||||
OP here. Yeah, you're not wrong. A lot of what IS driving AI code is that the writing code part isn't the intriguing aspect: it's designing, and the code generation is the grunt work that makes the design happen. And then you find out that most humans aren't that great at design: most programmers handwave their way through specifications, and thus the AIs do what they're told, and generate utter dreck, a lot like some of the "melody generators" do - they get handed very artificial constraints about what "good melodies" sound like, so they all sound very ordinary, because they STILL lack soul and replace inspiration with algorithm. | ||||||||
| ▲ | an hour ago | parent | prev [-] | |||||||
| [deleted] | ||||||||