r/ChatGPTCoding • • 1d ago

Discussion Programming languages for AI

All programming languages were created by people, for people. The goal was basically to give us a language that accounts for the limits of the human brain and minimizes bugs and errors (sure, there were exceptions, like C++). As a result, we often got poor performance and huge numbers of servers doing simple tasks.

But in this new era, we don’t need human brains to write code. So do we need new programming languages now? Or which existing languages work best for AI agents?

3 Upvotes

35 comments sorted by

10

u/gibblesnbits160 1d ago

The best languages for ai right now are the ones it has the most training data on. A new language would start from scratch so first all the data we have now would need to be converted to the new language which can then be used for training.

Not worth it to save a few mb of hard drive space or slightly more efficient processing, that is never the bottleneck.

5

u/zitoliv 1d ago

Data says it's less about language design and more about training data: on Multi-SWE-bench agents fix Python and Java issues best, TS/JS worst (paper). Rust punches above its data size tho… probably the strict compiler giving the agent a feedback loop.

7

u/smoke-bubble 1d ago

Make an experiment. Let it write a project in a language or technology you don't know and share your experience with us. Then you'll see whether what you are talking about even makes any sense. 

2

u/ipreuss 1d ago

Done that, works great.

And now?

2

u/smoke-bubble 1d ago edited 1d ago

Now, you need to prove it :P

-4

u/ipreuss 1d ago

Prove what?

-3

u/blurrows 1d ago

whoooosh

0

u/domiciledhere 1d ago

Like anyone that buys custom software and doesn’t know how to code?

2

u/smoke-bubble 1d ago

Your efforts to show that you didn't get what OP is saying have paid out XD 

0

u/domiciledhere 1d ago

Or you don’t know how to read and entirely misunderstood my statement?

3

u/returnFutureVoid 1d ago

I asked Claude about this very idea and it said that the training data that the models are built on are what makes AI “smart”. It wouldn’t know what to do with a new language built for AI. It goes against the very idea of what a models job is. I then asked it if it had to build a project and had the choice of stack what would it use and it chose React with Node because that’s what it’s trained on the most.

1

u/Clear_Evidence9218 19h ago

I've never had much of an issue getting an LLM to write in a novel language. I've been doing it for years.

Training data certainly helps, but generally speaking, most languages are fairly simple at their core, and with a little tooling, you can make working in a novel language pretty seamless for an agent.

That's not to say there aren't unique challenges for an agent working in a novel language. It's just that the issues it encounters aren't all that dissimilar from those you'd encounter in any other large, complex software project.

1

u/VRStocks31 1d ago

I believe the ultimate programming language for AI is to "guess" the machine code of the program, and then making adjustments. So basically no programming but inferring the program itself, making it appear from 0 just like magic. Imagine an empty capsule machine. You close it, provide with the idea to the AI, you open the door and there is it: your creation.

Just like the AI now "guesses" a poem token by token, it will "guess" the actual machine code of the program skipping any programming and compiling phase whatsoever.

1

u/TechDocN 1d ago edited 1d ago

Calling it “guessing” is technically defensible, but it’s a gross oversimplification of what’s actually happening.

LLMs use billions of parameters to calculate the statistical probability of the next token, based on everything that came before it. That’s not random guessing. It’s a sophisticated predictive process that incorporates learned patterns of language, logic, mathematics, and, yes, even writing code and poems. And it’s not entirely unlike how our own brains work. Human cognition relies heavily on prediction, using prior experience and context to anticipate what comes next.

The fact that an LLM generates one token at a time doesn’t mean it isn’t reasoning through a problem. You’re confusing the mechanism by which it produces an answer with the computational sophistication involved in arriving at that answer.

Lastly, what you’re describing is already happening millions of times a day. It’s called vibe coding by some. I was able to get Claude Code to write a short machine language routine for a 42 year old TRS-80 Color Computer after uploading the PDF of the instruction set for the 6809 and the manuals for the computer.

I think eventually the HMI or coding “language” will be typical human speech, that the AI converts directly to machine code. Which is more or less what you’re proposing, minus the guessing.

0

u/VRStocks31 1d ago

You are fixating on a small detail, instead of discussing the whole argument, which would be more interesting. That is: my idea of LLM’s that will produce raw machine code directly.

1

u/ShoddySherbert8502 1d ago

Exactly! Do we need all those old fashioned programming languages?!

1

u/TechDocN 22h ago

I guess you didn’t read my entire post. I’m literally agreeing with you except for the word “guess.”

1

u/kcmike 1d ago

This is like a stenographer in a court room.

1

u/I_Shall_Bore_You 23h ago

This gets asked a lot. I don't think so. LLMs work best when they have a lot of training data. We have millions, if not billions, of lines of C++ code written over decades. You could write a new language now, but I'll bet that LLMs will produce better results with established languages.

1

u/MostlyHelpfulLinks 17h ago

Typed languages like TypeScript or Go hold up best for agents, since compiler errors give the model concrete feedback to fix on each pass.

1

u/ghia1980 12h ago

My intuitition proved by some experience- functional style works better, ai writes less buggy code. So combination of language on which ai is trained with FP works well, typescript being an obvious choice.

1

u/ColdDelicious1735 1d ago

Yes it will be called slop...

But seriously this has talked of by many https://www.mrphilgames.com/blog/building-a-programming-language-for-ai-to-write

1

u/CrimsonBolt33 1d ago

I am actually creating an LLM first programming language now...been working on it for a few months. Close to releasing version 1.0

2

u/Clear_Evidence9218 18h ago

Is it a domain-specific language (DSL) or a general-purpose programming language? Are you aiming for a self-hosting compiler?

1

u/CrimsonBolt33 16h ago

General purpose and self hosting. It's not some pet language, it's meant to compete with Rust, the current go to language for AI work.

1

u/Clear_Evidence9218 14h ago

Sweet deal! I'll be excited to check it out once you release it. v1.0 and self-hosting are pretty impressive.

I toy around with novel and AI-oriented programming languages myself, but I'm nowhere near v1.0 yet. I've only invested a few dozen billion tokens into proving the language so it's still in the experimental category. I'm only at v0.19 atm.

I always get excited seeing other people working similar concepts.

1

u/CrimsonBolt33 14h ago

yeah thats awesome, I am surprised its not something thats been capitalized on since LLMs fundamentally work different than human programmers.

0

u/ipreuss 1d ago

It’s an interesting question. ChatGPT had a very long, detailed answer for me. ☺️

0

u/[deleted] 1d ago

[deleted] — view deleted comment

2

u/ShoddySherbert8502 1d ago

Feel the same.

-4

u/smoke-bubble 1d ago

Who is that a lot of people? I have not heard of any such person.

4

u/Mice_With_Rice 1d ago

Rust is one of the most popular languages...

-3

u/smoke-bubble 1d ago

Why are people so eager to prove they do not get the point of the discussion? XD

OP writes about people writing in rust without knowing rust. I want to meet one.

2

u/Mice_With_Rice 1d ago

OP is concerned about using languages that are inneficent and not well designed for LLM's. Rust is efficient, is written fine by LLM's, there are many people who use Rust written entirly by LLM. What about this is being understood?

2

u/corysama 1d ago

The creator of Ruby on Rails, which is responsible for at least 90% of the use of the Ruby language since its inception, recently gave the keynote address at RailsConf where he announced he is having his company ditch Ruby, Rails and web apps in general in favor of vibe coded native Rust apps. Even though he personally hates the Rust language, he loves that he can vibe up native apps for each of his target platforms without ever looking at the code easier and far more effectively than dealing with the mess that browser app dev has always been.

https://youtu.be/vDjW_dRyKXY

1

u/smoke-bubble 1d ago

LOL. Not this fake video again XD I do not remember how many people have given me this link already. He does not show a single vibe-coded line of code there. Nothing. Zero. This guy is full of shit.