LLM-generated code that seemingly went without much review or design is always such an interesting dive into just how bloated you can make code. In this repository, multiple files are close to 10K LOC, one file contains a switch statement that has so many case statements it spans more than 1000 lines, and lots of other fun stuff.

I guess it depends on the model you're trying to use, but seems most of them prefer smaller codebases, they work a lot better with less code, which kind of makes sense. With that in mind, I'd probably aim for something way smaller to bootstrap a self-improving agent. Then I'd use this "Prime Agent" as an example to my self-improving agent for what it should not evolve to.

> one file contains a switch statement that has so many case statements it spans more than 1000 lines

Probably best to leave YandereDev's code out of the training data.

here is a take on a smol agent ("smol")

  - 21 lines of Go
  - no 3rd party dependencies
https://github.com/smol-env/smol

easier to add and customize stuff when you start from a small base

think of it as your starter dough

I dig the spirit, but if I'm meant to understand it in an afternoon, why is it codegolfed to such an extent? It's like reading the output of a minifier, not idiomatic Go.

got one in typescript? or node.js with javascript?

I'm adding python in a few minutes and then looking into other languages including javascript and typescript

all with the same zero 3rd party dependencies approach

also want to do clojure, unfortunately it looks like java does not come with json support out of the box

> also want to do clojure, unfortunately it looks like java does not come with json support out of the box

Clojure has clojure.data.json (https://clojure.github.io/data.json/), should be easy to use albeit not blazing fast exactly, doesn't really matter here though. Otherwise, you could use Babashka, comes with Cheshire (and others) out of the box.

ty for the pointers

I like the babashka angle!

The stuff 99% of agents are coded in? Please tell me this was sarcasm.

> In this repository, multiple files are close to 10K LOC, one file contains a switch statement that has so many case statements it spans more than 1000 lines, and lots of other fun stuff.

Pft. Over multiple cases?

I've seen 1000 lines inside a single if-block. The clause was always true. I was not able to break that thing up in my time at that company.

Human wrote that nonsense.

Thing is, the app was pretty successful despite all the stuff wrong with the code. And this success is why I've been bullish on GenAI code itself, even though I'm also bearish on AI companies being able to profit from that.

At all feels a bit like being bullish on the adjustable wrench, to me.

It has lots of utility. Very broad… but not the best for a lot of things. It will be a ubiquitous tool. Outcomes will depend heavily on the quality of the mechanic unless you’re tightening a bolt on your fence gate.

Bash is all you need.

https://minimal-agent.com/

[dead]

Literally says who. Swe are the least credible "engineers". "It depends" "No you cant track us" "No we have no credentials system other than big company shill certs"

How on Earth do we solve this bloat and death-by-a-thousand-cuts issue with frontier LLMs? Are there any actual solutions or attempts at solutions to this problem that I can try? Any tools or frameworks? I've tried re-architecture skills, dedicated cleanup sessions, and a bunch of other stuff, but nothing really works well.

Add Sentrux to the LLM loop. https://github.com/sentrux/sentrux

It's an offline coding grader. It works well: You ask for a new module, LLM starts spitting out bloated crap, the code score goes down. LLM keep looping until code score is back up.

Not a substitute for human code review, but keeps things within tight guard rails.

Don't try to "run as fast as possible" and just add code willy-nilly, think about the design, refactor as you add new features/fixes and intentionally be a bit slower and more considerate.

It's not a technical problem, if you steer the LLMs enough and actually review what they do, you can build proper and clean software with them.

Yeah, but that's boring. :)

Don't have it write the whole thing in one session.

Interesting, so they shipped slop? Succumbed to their own AI psychosis?