News for hackers. Stuff that matters.
Re:Micro-agent: make an AI write code until it passes an uni... by benve on Monday July 08, 2024 @09:08AM (#40905094)
A very sad future awaits us if a developer's only job is to write tests
Re:Micro-agent: make an AI write code until it passes an uni... by awwaiid on Monday July 08, 2024 @10:23AM (#40905708)
I knew declarative languages would eventually win!
Re:Micro-agent: make an AI write code until it passes an uni... by root_axis on Monday July 08, 2024 @10:00AM (#40905510)
I've tried these LLM "code from test" things (and vice-versa) dozens of times over the last couple of years... they're not even close to approaching being practical.
Re:Micro-agent: make an AI write code until it passes an uni... by tiborsaas on Monday July 08, 2024 @09:11AM (#40905105)
It's worse, it starts by writing the test so you have to verify if the tests work :)
Re:Micro-agent: make an AI write code until it passes an uni... by philote on Monday July 08, 2024 @09:41AM (#40905358)
That's what I don't get about this. Instead of writing code that may or may not be correct, it's writing tests that may or may not be correct.
Re:Micro-agent: make an AI write code until it passes an uni... by TuringNYC on Monday July 08, 2024 @09:25AM (#40905212)
Perhaps a minority opinion, but i LOVE writing tests. I write them before I write the code, it is like playing chess with yourself.
Re:Micro-agent: make an AI write code until it passes an uni... by benve on Monday July 08, 2024 @11:08AM (#40906107)
I appreciate that your workflow is so linear. I often write tests, then the implementation, then I realize that the tests need to be corrected, then I change the implementation, then I change the tests, then I add other tests etc... etc...

I don't really like maintaining tests, it's often a lot of code that needs to be understood and changed carefully

Re:Micro-agent: make an AI write code until it passes an uni... by _flux on Monday July 08, 2024 @09:52AM (#40905452)
Maybe in the future developers will be able to write just specifications.
Re:Micro-agent: make an AI write code until it passes an uni... by benve on Monday July 08, 2024 @11:25AM (#40906246)
this already happens, in many companies mid-level managers write the specifications (ambiguously) and other low-cost people implement them.

And when things don't work they call people like me, to try to understand the performance problems of something poorly defined and worse written.

Re:Micro-agent: make an AI write code until it passes an uni... by jacamera on Monday July 08, 2024 @09:59AM (#40905503)
That's exactly what we do now.
Re:Micro-agent: make an AI write code until it passes an uni... by _flux on Monday July 08, 2024 @10:06AM (#40905565)
Arguably we write instructions: instead of writing out the problem and what the solution looks like, we describe a set of steps we go through—and if those steps are incorrect, there's nothing to compare against, because that was what we called the "specification".

Whether there's a difference there is in the eye of the beholder, but it does look like that specification languages such as TLA+/PlusCal/Squint or Alloy, or theorem proving languages like Coq (to be renamed Rocq) or Lean look a lot different from the likes of C, JavaScript or even Haskell.

Re:Micro-agent: make an AI write code until it passes an uni... by autonomousErwin on Monday July 08, 2024 @10:30AM (#40905773)
Really it's just validator code instead of feature code. I think this is the only realistic way forward for production level code written by AI, don't ask it to write code - ask it to pass your validation tests.

Essentially, everyone becomes a red team member trying to think of clever ways they can outwit the AI's code which I for one think this is going to be a lot of fun in the future - though we're still quite a way from there yet!

Re:Micro-agent: make an AI write code until it passes an uni... by colechristensen on Monday July 08, 2024 @09:38AM (#40905320)
Why? It will evolve into a slightly higher level language where the compiler is an ML model. Was it a tragedy when developers mostly didn’t have to write assembly any more?
Re:Micro-agent: make an AI write code until it passes an uni... by benve on Monday July 08, 2024 @11:16AM (#40906176)
I think it's different... I like high level languages, but this is not a programming language, this is a technique for writing tests in an existing language and leaving the implementation to the AI.

I like programming for problem solving, I don't really like writing tests, but that's personal taste, a lot of people like to just use PowerPoint and Jira and tell others what they need to implement, but these people are not software developers.

Re:Micro-agent: make an AI write code until it passes an uni... by selcuka on Monday July 08, 2024 @09:43AM (#40905378)
> Was it a tragedy when developers mostly didn’t have to write assembly any more?

It wasn't, but for starters compilers have always been generally deterministic.

I'm not saying that this is completely useless (I personally think code completion tools such as GitHub CoPilot are fantastic), but it is still early to compare it to a compiler.