VM-ENGINE
A deterministic electoral simulation core. It is not a "black box" in the opaque sense, but a pure function: it accepts canonical inputs and produces byte-identical outputs across any operating system or architecture.
The "Pure Function" Contract
Universe of units & options
Votes per unit/option
Algorithm config & variables
Canonical outcome & labels
Cryptographic audit trail
Byte-Identical Determinism
With identical inputs and seeds, the engine produces outputs that are bit-for-bit identical on any machine. We achieve this by enforcing a strictly canonical JSON format with sorted keys and stable array ordering.
Offline & Hermetic
The engine performs no network I/O during official runs. It is a self-contained binary that verifies its own input hashes and fails hard upon any spec violation.
Formula ID (FID)
We separate "outcomes" from "presentation". Outcome-affecting rules are hashed into aFormula ID. Changing a visual label does not change the FID; changing a rounding rule does.
Pinned Randomness
Tie-breaking is not arbitrary. When random policy is selected, the engine uses a frozen RNG profile seeded once per run. A k-way tie consumes exactly k draws.