3 ms·
The possibly ironic thing here is I find golang to be one of the best languages for LLMs. It's so verbose that context is usually readily available in the file
by jjcm 10mo ago
The possibly ironic thing here is I find golang to be one of the best languages for LLMs. It's so verbose that context is usually readily available in the file itself. Combined with the type safety of the language it's hard for LLMs to go wrong with it.
- shepherdjerred 10mo agoI haven’t found this to be the case… LLMs just gave me a lot of Nil pointers
- _ea1k 10mo agoIt isn't perfect, but it has been better than Python for me so far. Elixir has also been working surprisingly well for me lately.
- krainboltgreene 10mo agoGod I wish it didn't.
- cyberpunk 10mo agoEh it depends. Properly idiomatic elixir or erlang works very well if you can coax it out — but there is a tendency for it to generate very un-functional like large functions with lots of case and control statements and side effects in my experience, where multiple clauses and pattern matching would be the better way. It does much better with erlang, but that’s probably just because erlang is overall a better language than elixir, and has a much better syntax.
- ipaddr 10mo agoI fould golang to be one of the worst target for llms. PHP seems to always work, python works if the packages are not made up but go fails often. Trying to get inertia and the Buffalo framework to work together gave the llm trama.
- sethammons 10mo agoTwo or so months ago, so maybe it is better now, but I had Claude write, in Go, a concurrent data migration tool that read from several source tables, munged results, and put them into a newer schema in a new db. The code created didn't manage concurrency well. At all. Hanging waitgroups and unmanaged goroutines. No graceful termination. Types help. Good tests help better.
- roryirvine 10mo agoI've found the same. To generalise it a bit, LLMs seem to do particularly well with static types, a well-defined set of idioms, and a culture of TDD.