Rampart Zero
A strategy game with an AI commander that lives on the player’s device.

Can the commander become a game mechanic?
I wanted to know whether an AI commander could be a genuine game mechanic. A player needs immediate feedback. The system needs to understand an instruction, determine whether it is legal, and do something useful under pressure. Every extra second matters. Paying a remote inference provider each time somebody asks a unit to move creates another constraint: the operating cost grows with use.
Rampart Zero is a browser-native fortress-defense strategy game built around that problem. You can give spoken instructions to build, move and defend, ask for a situation report, or interrupt an instruction that no longer makes sense. The Commander is another way to operate the game, with the same underlying rules as the ordinary controls.
Three local models and an explicit command language
Speech recognition uses Moonshine Small Streaming. Language understanding runs through a fine-tuned, quantized LFM2.5-350M model in wllama, with grammar-constrained decoding. Kokoro supplies local voice output. The player does not configure an API key or send each command to a hosted language model.
The language model produces a compact line-based command language. A parser compiles that into tool arguments, then the tool runner checks argument schemas, policy and execution budgets. Common control words and explicit requests can take a deterministic path, reserving model inference for the instructions that need it.

The first visit pays a different cost
Local inference moves work onto the device. The current model set is approximately 505 MB, including recognition and voice. A first visit has to download, cache and initialize it alongside a running 3D game. A warm browser cache and a first launch can feel very different.
The deliberately small language model makes the command vocabulary, grammar and deterministic shortcuts more important. Memory and CPU are shared with gameplay, and devices have different performance envelopes. The exchange is useful: per-command inference cost becomes something I can address through the design of the game rather than a remote bill that rises with engagement.
The model interprets intent; the game owns the state
Generated text cannot decide a unit’s location, a resource balance or whether construction is allowed. The deterministic simulation and the game’s command executors remain responsible for those outcomes. The model interprets the request; the application validates it and applies the game rules.
That boundary is one of the most useful design decisions in an AI-native experience. A new input method can expand what the player expresses without quietly handing it ownership of the world state.
A working capability still has to earn its place
The Commander can turn speech into game actions. The game also has to teach a player why and when to use it. That is an onboarding and interaction problem as well as a model problem. The first-run briefing and in-game tutorial are part of making the capability discoverable.
Rampart Zero is still evolving. The question is no longer just whether a small model can run locally and turn an instruction into a valid command. The question is whether that capability makes a better strategy game: one players understand, enjoy and want to return to.
From speech to a game action
- Moonshine: speech to text
- Deterministic route or local LFM model
- Grammar and command parser
- Validated tools and game rules
- Simulation result and Kokoro response
Commander architecture reviewed November 11, 2026. Model-download size follows the packaged release record; startup and inference performance depend on the device and cache.