The ridiculous amount of data required to get here hints that there is something wrong in my opinion.
I'm not sure if we're totally on the same page, but I understand where you're coming from here. Everyone keeps talking about how transformational these models are, but when push comes to shove, the cynicism isn't out of fear or panic, its disappointment over and over and over. Like, if we had an army of virtual programmers fixing serious problems for open source projects, I'd be more excited about the possibilities than worried about the fact that I just lost my job. Honest to God. But the thing is, if that really were happening, we'd see it. And it wouldn't have to be forced and exaggerated all the time, it would be plainly obvious, like the way AI art has absolutely flooded the Internet... except I don't give a damn if code is soulless as long as it's good, so it would possibly be more welcome. (The only issue is that it most likely actually suck when that happens, and rather just be functional enough to get away with, but I like to try to be optimistic once in a while.)
You really make me want to try this, though. Imagine if it worked!
Someone will probably beat me to it if it can be done, though.
Very much this. When you criticize LLM's marketing, people will say you're a ludite.
I'd bet that no one actually likes to write code, as in typing into an editor. We know how to do it, and it's easy enough to enter in a flow state while doing it. But everyone is trying to write less code by themselves with the proliferation of reusable code, libraries, framework, code generators, metaprogramming,...
I'd be glad if I could have a DAW or CAD like interface with very short feedback (the closest is live programming with Smalltalk). So that I don't have to keep visualizing the whole project (it's mentally taxing).
And you'd be wrong. I, for one, enjoy the process of handcrafting the individual mechanisms of the systems I create.
I like programming, I do not like coding.
To be honest I'm more annoyed by having to repeat three times parameters in class constructors (args, member declaration and assignment), and I have a macro for it.
The thing is, most of the time I know what I want to write before I start writing. At that point, writing the code is usually the fastest way to the result I want.
Using LLMs usually requires more writing and iterations; plus waiting for whatever it generates, reading it, understanding it and deciding if that's what I wanted; and then it suddenly goes crazy half way through a session and I have to start over...
between this and..
> But everyone is trying to write less code by themselves with the proliferation of reusable code, libraries, framework, code generators, metaprogramming
.. this, is a massive gap. Personally speaking, I hate writing boilerplate code, y'know, old school Java with design patterns getter/setter, redundant multi-layer catch blocks, stateful for loops etc. That gets on my nerves, because it increases my work for little benefits. Cue modern coding practices and I'm almost exclusively thinking how to design solution to the problem at hand, and almost all the code is business logic exclusive.
This is where a lot of LLMs just fail. Handholding them all the way to correct solution feels like writing boilerplate again, except worse because I don't know when I'll be done. It doesn't help that most code available for LLMs is JS/TS/Java where boilerplate galore, but somehow I doubt giving them exclusively good codebases will help.
Something is happening, its just not exciting as some people make it sound.
Of course, for that use case, you can _probably_ do a bit of text processing in your text processing tools of choice to do it without LLMs. (Or have LLMs write the text processing pipeline to do it.)
You're right, instead what we see is the emergence of "vibe coding", which I can best describe as a summoning ritual for technical debt and vulnerabilities.
i kinda think "javacript, the good parts" should be part of the prompt for generating TS and JS. I've seen too much of ai writing the sketchy bad parts
UPDATE: naive (just fed it your description verbatim) cline + claude 3.7 was a total wipeout. It looked like it was making progress, then freaked out, deleted 3/4 of its port, and never recovered.
That made me laugh. True, but not really the motivation. I honestly don't think LLMs can code significant real-world things yet and I'm not sure how else to prove that since they can code some interesting things. All the talk about putting programmers out of work has me calling BS but also thinking "show me". This task seems like a good combination of simple requirements, not much documentation, real world existing problem, non-trivial code size, limited scope.
It's not like people just one-shot a whole module of code, why would LLMs?
And I don't think this is uncommon. Just a random example from Github, this file is 1800 LOC and 4 functions. It implements one very specific thing that's part of a broader library. (I have no affiliation with this code.)
https://github.com/elemental/Elemental/blob/master/src/optim...
You don't have to, you can write it by hand. I thought we were talking about how we can make computers write code, instead of humans, but it seems that we're trying to prove that LLMs aren't useful instead.
Isn't this something that we should have doing for decades of our own volition?
Separation of concerns, single responsibility principle, all of that talk and trend of TDD or at the very least having good test coverage, or writing code that at least can be debugged without going insane (no Heisenbugs, maybe some intermediate variables to stop on in a debugger, instead of just endless chained streams, though opinions are split, at least code that is readable and not 3 pages worth per function).
Because when I see long bits of code that I have to change without breaking anything surrounding them, I don't feel confident in doing that even if it's a codebase I'm familiar with, much less trust an AI on it (at that point it might be a "Hail Mary", a last ditch effort in hoping that at least the AI can find method in the madness before I have to get my own hands dirty and make my hair more gray).
For conversions between languages or libraries, you often do just one-shot it, writing or modifying code from start to end in order.
I remember 15 years ago taking a 10,000 line Java code base and porting it to JavaScript mostly like this, with only a few areas requiring a bit more involved and non-sequential editing.
Maybe the mistake is mistaking LLMs as capable people instead of a simple, but optimised neuron soup tuned for text.
I am majorly impressed with the combination VSCode + Cline + Gemini
Today I had it duplicate an esp32 proram from UDP communication to TCP.
It first copied the file ( funnily enough by writing it again instead of just straight cp ) Then it started to just change all the headers and declarations Then in a third step it changed one bigger function And in the last step it changed some smaller functions
And it reasoned exactly that way "Let's start with this first ... Let's now do this .... " until is was done
Thank you
I asked GPT4 to write an empty GTK4 app in C++. I asked for a menu bar with File, Edit, View at the top and two GL drawing areas separated by a spacer. It produced what looked like usable code with a couple lines I suspected were out of place. I did not try to compile it so don't know if it was a hallucination, but it did seem to know about gtkmm 4.
But LLMs performance varies (and this is a huge critique!) not just on what they theoretically know, but how, erm, cross-linked it is with everything else, and that requires lots of training data in the topic.
Metaphorically, I think this is a little like the difference for humans in math between being able to list+define techniques to solve integrals vs being able to fluidly apply them without error.
I think a big and very valid critique of LLMs (compared to humans) is that they are stronger at "memory" than reasoning. They use their vast memory as a crutch to hide the weaknesses in their reasoning. This makes benchmarks like "convert from gtkmm3 to gtkmm4" both challenging AND very good benchmarks of what real programmers are able to do.
I suspect if we gave it a similarly sized 2kloc conversion problem with a popular web framework in TS or JS, it would one-shot it. But again, its "cheating" to do this, its leveraging having read a zillion conversion by humans and what they did.
In my experience it seems like it depends on what they’ve been trained on
They can do some pretty amazing stuff in python, but fail even at the most basic things in arm64 assembly
These models have probably not seen a lot of GTK3/4 code and maybe not even a single example of porting between the two versions
I wonder if finetuning could help with that
I keep thinking may be specifically Web programmers. Given a lot of the web essentially CRUD / have the same function.
Tom Sawyer? Yes.
Upload one of your platform-specific C++ file's source, along with the doc `.txt` into your LLM of choice.
Either ask it for a conversion function-by-function, or separate it some other way logically such that the output doesn't get truncated.
Would be surprised if this didn't work, to be honest.
LLM's will always benefit from in context learning because they don't have a huge archive of data to draw on (and even when they do, they are not the best at selecting data to incorporate).
And a way to define parameters (not sure if that's already possible).
I've outlined a function for that and started to write the code. At a high level it's straight forward, but the details are complex. It'll probably be a year before it's done.
>> And a way to define parameters (not sure if that's already possible).
This is an active work in progress. A demo was made years ago, but it's buggy and incomplete. We've been working out the details on how to make it work. I hope to get the units issue dealt with this week. Then the relation constraints can be re-integrated on top - that's the feature where you can type arbitrary equations on the sketch using named parameters (variables). I'd like that to be done this year if not this summer.
By the way, if this would make things simpler, perhaps you can implement chamfering as a post-processing step. This makes it less general, but it would still be super useful.
They won't touch this.
Yes. I did a lot of the 3->4 prep work. But there were so many API changes... I attempted to do it by commenting out anything that wouldn't build and then bring it back incrementally by doing it the GTK4 way. So much got commented out that it was just a big mess of stubs with dead code inside.
I suspect the right way to do it is from scratch as a new platform. People have done this, but it will require more understanding of the paltform abstraction and how it's supposed to work (It's not my area of the code). I just want to "convert" what was there and failed.
Why not modularize the backend and build a better UI with tech that’s actually relevant in 2025?
Doing the second part is to my understanding actually the purpose of the stated task.
Quite the opposite: Gtk4 is relevant, and porting Solvespace to this relevant toolkit is the central part of the stated task.
The fact that they haven't done the port in the normal way suggests they basically agree with what you said here (not worth the ROI), but hey if you can get the latest AI code editor to spit out a perfectly working port in minutes, why not?
FWIW, my assessment of LLMs is the same as theirs. The hype is far greater than the practical usefulness, and I say this as someone who is using LLMs pretty regularly now.
They aren't useless, but the idea that they will be writing 90% of our code soon is just completely at odds with my day to day experience getting them to do actual specific tasks rather than telling them to "write Tetris for XYZ" and blog about how great they are because it produced something roughly what I asked for without much specificity.
I'd like to use the same UI on all platforms so that we can do some things better (like localization in the text window and resizable text) and my preference for that is GTK. I tried doing it myself, got frustrated, and stopped because there are more important things to work on.
I don’t know any pros using Solvespace by itself, and my own opinion is that CAD is the wrong paradigm for most of the things it’s used for anyway (like highway design).
Well, that attitude is probably why the issue has been open for 2 years.
https://github.com/solvespace/solvespace?tab=readme-ov-file#...
But you already have a complex cmake build system in place. Adding a standard Docker image with all the deps for devs to compile on would do nothing but make contributing easier, and would not affect your CI/CD/testing pipeline at all. I spent half an hour trying to get this to build for MacOS before giving up.
If building your project for all supported environments requires anything more than a single one-line command, you're doing it wrong.
"You will need git, XCode tools, CMake and libomp. Git, CMake and libomp can be installed via Homebrew"
That really doesn't seem like much. Was there more to it than this?
Edit: I tried it myself and the cmake configure failed until I ran `brew link --force libomp`, after which it could start to build, but then failed again at:
[ 55%] Building CXX object src/CMakeFiles/solvespace-core.dir/bsp.cpp.o
c++: error: unknown argument: '-Xclang -fopenmp'I didn't build it :-(
>> Adding a standard Docker image with all the deps for devs to compile on would do nothing but make contributing easier, and would not affect your CI/CD/testing pipeline at all.
I understand, but to me that's just more stuff to maintain and learn. Everyone wants to push their build setup upstream - snap packages, flatpak, now we need docker... And then you and I complain that the build system is complex, partly because it supports so many options. But it looks like the person taking up the AI challenge here is using Docker, so maybe we'll get that as a side effect :-)
That's like saying that you're judging a sedan by its capability of performing the job of a truck.
Wait, you were being sarcastic?
But I'll go a little farther - most meaningful, long-lived, financially lucrative software applications are metaphorically closer to the open-pit mine than the adorable backyard garden that AI tools can currently handle.
It's openly hostile to not consider the upgrade path of existing users, and make things so difficult that it requires huge lifts just to upgrade versions of something like a UI framework.
I respectfully disagree with that. I think it's a solid UI framework, but...
>> It's openly hostile to not consider the upgrade path of existing users, and make things so difficult that it requires huge lifts just to upgrade versions of something like a UI framework.
I completely agree with you on that. We barely use any UI widgets so you'd think the port would be easy enough. I went through most of the checklist for changes you can make while still using GTK3 in prep for 4. "Don't access event structure members directly, use accessor functions." OK I made that change which made the code a little more verbose. But then they changed a lot of the accessor functions going from 3 to 4. Like WTF? I'm just trying to create a menu but menus don't exist any more - you make them out of something else. Oh and they're not windows they are surfaces. Like why?
I hope with some of the big architectural changes out of the way they can stabilize and become a nice boring piece of infrastructure. The talk of regular API changes every 3-5 years has me concerned. There's no reason for that.
The snark and pessimism nerd-sniped me :)
I've used AI heavily to maintain a cross-platform wrapper around llama.cpp. I figure its worth a shot.
I took a look and wanted to try but hit several hard blocks right away.
- There is no gtk-4 branch :o (presuming branch = git branch...Perhaps this is some project-specific terminology for a set of flags or something, and that's why I can't find it?)
- There's some indicators it is blocked by wxWidgets requiring GTK-4 support, which sounds much larger scope than advertised -- am I misunderstanding?
https://github.com/solvespace/solvespace/issues/1414
Make a GTK 4 version of Solvespace. We have a single C++ file for each platform - Windows, Mac, and Linux-GTK3. There is also a QT version on an unmerged branch for reference. The GTK3 file is under 2KLOC. You do not need to create a new version, just rewrite the GTK3 Linux version to GTK4. You may either ask it to port what's there or create the new one from scratch.
If you want to do this for free to prove how great the AI is, please document the entire session. Heck make a YouTube video of it. The final test is weather I accept the PR or not - and I WANT this ticket done.
I'm not going to hold my breath.