When you build a simulation with a graphical front end, the temptation is to let the world and its drawing live together. It is faster at first. For LIVEX, an experimental multi-agent platform, I did the opposite, and I want to share what that bought me and what it cost.
The three roles
LIVEX is split into three components with distinct jobs.
- SYNE is the simulation engine, built on .NET. It advances the world and its agents, and it is the source of truth.
- ECHOS is the observation and analysis layer, built with Python and Django. It reads what the engine produced.
- PRISM is the rendering module, meant to turn the world into something you can look at.
The rule: information flows one way
The whole design rests on one rule: observation and rendering read the simulation; they never write back into it.
# pseudocode, not actual project code
state = init(seed, config)
for tick in range(n):
state = step(state) # depends only on state and seeded randomness
emit(trace(state)) # observers and renderers consume this
# nothing they do flows back into step()
The loop is deliberately boring. That is the point.
What it bought me
- A single source of truth. When the picture and the numbers disagree, there is no debate: the engine is right and the picture is wrong.
- Replayability. If rendering cannot influence the simulation, the same seed and configuration can replay the same run. That is the foundation for determinism.
- Cheaper tests. Engine tests need no window and no graphics. The project site reports 1,550 passing tests as of November 4, 2026.
- The freedom to rebuild one layer. The rendering module is being rebuilt right now, and the agents' logic does not have to move.
What it cost me
- Contracts to maintain. Layers talk through explicit, versioned interfaces. They need design and care when they change.
- Plumbing. Snapshots and events must be designed and transported. You cannot just reach into the world and draw it.
- Up-front design time. Early on, the shortcut of drawing straight from game state is very tempting, and unavailable.
- Debugging across boundaries. A bug may sit in the engine, in the contract or in the renderer, and you have to know which.
When I would not do it
For a small prototype, or when tight coupling between logic and visuals is the whole point, splitting early is overkill. Start simple; separate when the pain of mixing shows up.
Takeaway
Separation of concerns is easy to say and rarely free. In a simulation meant to be observed, replayed and questioned, I think it paid for itself.
The architecture page walks through each component: https://donovan-dev-web.github.io/LIVEX/en/ (to a precise page after verification). The code is open: https://github.com/donovan-dev-web/LIVEX .
Donovan Chartrain | Creator and developer of LIVEX

Top comments (0)