[UPDATE: I have rewritten most of the utility in Rust. I was pleasantly surprised that even the Rust has no garbage collector, not much time has to be spend on memory management. The real pain-point, compared to Python, has been interfacing with Sqlite; doing so is far less time-consuming in Python. But the overall conclusion, in bold below, remains the same.]
I wrote a terminal-based utility in Python that I’m thinking of releasing publicly (I’ve been using it myself for years). But the footprint seems very big for a terminal utility.
So I’ve been looking at converting it to a compiled language. One with memory management. I like F#, but its executable footprint is surprisingly large.
I played with OCaml, and I basically like the language, but its tooling is not great and I’m finding that ChatGPT isn’t good at writing OCaml code particularly when using libraries, because there just isn’t much code out there using most OCaml ecosystem libraries.Which finally led me to look at Rust. It has features I want like match statements, and even has macros that do pipelining. Obviously, it’s usually considered a systems programming language, although there are things like web frameworks.
One might ask, however: For applications where efficiency isn’t a major issue, why would you use a language where you have to manually deal with things like memory management, meaning that it will take significantly more code to accomplish the same thing as you could in a non-systems language?
An answer I’m considering: There is a lot of Rust code out there for training LLMs. My guess is that to the degree that a developer is willing to invoke an LLM to write Rust code, it can handle the memory management pretty much painlessly.I’m not advocating turning programming tasks entirely over to LLMs. We should still read and understand any LLM-generated code we use, carefully consider the structure and tools it uses, etc..
But what I’m suspecting is that a language like Rust may get more use in the future. The time expenditure that goes with its programming overhead is greatly reduced when LLMs are used to generate code. Maybe there will be less traction going to languages whose main advantage is that they require fewer lines of code for the same results when those lines are often written by an LLM.
So I make a tentative prediction: LLM use will cause the Rust community to grow even more quickly than has already been the case.
nyway, I’m going to be moving from Python to Rust, making substantial use of LLMs, and see how it feels.