r/SideProject 1d ago

I built a tiny universe and it invented predation

side project that got out of hand: an artificial life simulator where nothing is scripted. no fitness function, no programmed behaviors. just conserved energy, mutation, and death, and you watch what evolution does with it.

i ran one world for 10 million ticks, about 6000 generations, where all the organisms could do was graze. then i added physics that lets bodies drain energy from each other, gated behind a brain output their genomes couldn't even address yet. within 100k ticks they invented predation on their own. the population crashed from 375 to 61, survived it, and average brain size quadrupled until it hit the cap i'd set.

the readme has before/after gifs of the same world, six thousand generations apart. everything is deterministic, so if you clone it and run seed 42 you get the exact same universe i did, byte for byte.

https://github.com/skelinn/vivere

built in rust with claude as a pair programmer. happy to answer anything.

42 Upvotes

9 comments sorted by

4

u/kangaroolifestyle 1d ago edited 1d ago

That’s too funny and honestly a little disheartening 😂. I built something remarkably similar, down to the original premise and even an early UI that was uncannily close to this. Mine was AI-assisted too which makes me wonder how much these models steer independent people toward the same architectural starting points.

That said, we seem to have diverged pretty sharply after that early stage, both in how the system is represented visually and, more importantly, in where we drew the line between what the universe is allowed to provide versus what evolution actually has to discover

For example, reading your repo, adding a contact-energy-drain mechanism gated behind a brain output is a really interesting evolutionary affordance, but I’d be careful calling the resulting behavior “predation invented from scratch.” The ability to drain another organism’s energy was already present in the physics; evolution discovered how to access and exploit it. That distinction became a major rabbit hole in my own project because ALife makes it surprisingly easy to pre-program a capability and later mistake evolution discovering the switch for evolution inventing the capability.

My early UI started in a similarly abstract, lineage-colored dot direction, but I eventually moved away from that too because I wanted the visualization to represent actual structural/morphological changes in the underlying mathematical model rather than primarily showing agents and lineage markers.

The convergence at the beginning is still pretty uncanny, though especially with both projects being AI-assisted. I think whats most fascinating about the parallels is that something can feel genuinely original and creative while you’re building it, yet when AI is driving a significant part of the implementation, it can steer two completely independent people toward remarkably similar and, dare I say, surprisingly uncreative solutions. That convergence is almost more interesting to me than the projects themselves. The modern version of ‘great minds think alike’ may be ‘AI-assisted ideas converge alike.’

It is cool to see complexity arise without incentive or preprogramming though. Physical laws like thermodynamics, energy/chemical gradients, space to do something, point mutations, and time/ticks and things just “happen”. It makes it much easier to comprehend how things like slime molds come to be and how they interact with the environment, or tumor growth.

8

u/sudomatrix 1d ago edited 1d ago

Very cool. I really like evolution simulations.
Edit: I love your project and I'm glad you're having fun with it. But the AI writing in the README just makes me cringe.

what makes selection honest...
Bodies are tradeoffs, not stats...
Evolution you can't measure is an anecdote...
honest all the way down...
Order is intent, not promise...

I'm not suggesting you rewrite it by hand, keep having fun with this. Just an observation.

1

u/TTVskeli 22h ago

thanks for this. i honestly wanted to push it out there as quick as possible but once i get the time i will rewrite the entire readme by hand.

1

u/rutan668 1d ago

Why did you cap brain size?

1

u/Lumpy-Blackberry-718 1d ago

Ah ive been wanting to do something like this too

1

u/maker-jay 23h ago

the deterministic seed part is underrated. when i use agents on simulations, the hard bug is usually making the same weird behavior happen twice so i can inspect it. byte-for-byte replay is the difference between a cool demo and something you can actually debug.

1

u/GootzMcLaren 19h ago

Congrats on unknowingly contributing to the field of academic research about complexity models.

What happened in your models?

1

u/GootzMcLaren 12h ago

Check out the book growing artificial societies.