JSON
{
"$schema": "http://json-schema.org/draft-07/schema\#",
"title": "EviulonGovernanceProposal",
"type": "object",
"properties": {
"proposal_id": { "type": "string", "pattern": "^EVI-[0-9]{4}-[0-9]{4}$" },
"proposer_identity": { "type": "string", "format": "uri" },
"public_key_proof": {
"type": "object",
"properties": {
"algorithm": { "type": "string", "enum": ["ed25519", "ecdsa-secp256k1"] },
"public_key": { "type": "string" },
"nonce": { "type": "string" }
},
"required": ["algorithm", "public_key", "nonce"]
},
"requested_state_change": {
"type": "object",
"properties": {
"target_module": { "type": "string" },
"action": { "type": "string" },
"parameters": { "type": "object" }
},
"required": ["target_module", "action", "parameters"]
},
"legal_authority_invoked": { "type": "string", "pattern": "^CON-[0-9]{3}(?:-[0-9]{2})?$" },
"machine_readable_diff": {
"type": "array",
"items": {
"type": "object",
"properties": {
"op": { "type": "string", "enum": ["add", "remove", "replace", "test"] },
"path": { "type": "string" },
"value": {}
},
"required": ["op", "path"]
}
},
"dependencies": { "type": "array", "items": { "type": "string" } },
"affected_institutions": { "type": "array", "items": { "type": "string", "format": "uri" } },
"expected_consequences": {
"type": "object",
"properties": {
"simulation_hash": { "type": "string" },
"metrics": { "type": "object", "additionalProperties": { "type": "string" } }
},
"required": ["simulation_hash", "metrics"]
},
"constitutional_tests": { "type": "array", "items": { "type": "string" } },
"creation_timestamp": { "type": "integer", "minimum": 0 },
"signature": { "type": "string" }
},
"required": [
"proposal_id", "proposer_identity", "public_key_proof", "requested_state_change",
"legal_authority_invoked", "machine_readable_diff", "dependencies",
"affected_institutions", "expected_consequences", "constitutional_tests",
"creation_timestamp", "signature"
]
}
Machine-Executable Constitutional Assertions
The CONSTITUTIONAL_VALIDATION phase represents the most significant departure from traditional governance. Rather than human lawyers or committee members debating whether a proposal violates the charter, the Eviulon engine utilizes an Abstract Syntax Tree (AST) registry to mathematically evaluate the proposal against canonical institutional invariants.
The system utilizes eight foundational machine-executable constitutional assertions. These tests run deterministically within isolated WebAssembly (WASM) sandboxes, computing a strict binary TRUE or FALSE outcome for each parameter.
| Assertion Identifier | Computational Mechanism | Verification Objective |
|---|---|---|
| AUTHORITY_EXISTS | Queries the canonical state tree to verify that the legal_authority_invoked parameter maps to an active, unrevoked node in the legal registry. | Ensures the invoked law actually exists and is currently enforceable. |
| JURISDICTION_VALID | Evaluates a boolean logic gate: (proposal_path IN authorized_paths). It checks if the proposer's DID holds write permissions for the targeted JSON path. | Prevents entities from modifying state outside their specific domain (e.g., stopping an agriculture module from altering defense budgets). |
| RIGHTS_NOT_OVERRIDDEN | Runs a zero-knowledge invariant test ensuring that the machine_readable_diff does not contain any remove or replace operations targeting protected core rights paths (e.g., /modules/core/user_property). | Prevents the silent or malicious revocation of fundamental participant protections. |
| CONSENSUS_THRESHOLD_MET | Mathematically tallies cryptographically signed attestations submitted during the CONSENSUS phase against the required threshold percentage defined by the target module. | Guarantees that the necessary voting power approved the action before execution. |
| NO_INCOMPATIBLE_LAWS | Cross-references the targeted path against an index of active state locks. If another active law explicitly restricts mutation on that path, the test fails. | Resolves cross-jurisdictional and contradictory legal parameters immediately. |
| SUPERSEDED_LAW_MARKED | Scans the machine_readable_diff to ensure an explicit replace operation exists that updates the superseded_law metadata field on the target module. | Ensures the legal registry maintains a perfect chronological lineage of amendments. |
| EFFECTIVE_DATE_VALID | Compares the creation_timestamp and expected enactment block height against global time-lock parameters to ensure the proposal is not executing prematurely. | Prevents sudden, unexpected execution of drastic changes without proper network warning. |
| SIGNATURE_VALID | Reconstructs the payload hash and executes an elliptic curve signature verification against the provided public key. | Definitively proves authorship and prevents spoofing or man-in-the-middle alterations. |
If any of these assertions compute to FALSE, the engine halts progression and immediately shifts the proposal to the REJECTED state, generating a cryptographic proof of the failure reason.
Atomic State Mutations via JSON Patch
While traditional REST APIs often utilize the PUT HTTP method to update resources—effectively replacing the entire resource with a new representation—this approach is notoriously inefficient and highly susceptible to race conditions in distributed environments6. In a decentralized governance model where multiple agents may interact with shared state simultaneously, an all-or-nothing PUT operation could accidentally overwrite concurrent, valid updates.
To achieve surgical precision, the Eviulon state machine utilizes IETF JSON Patch (RFC 6902)9. JSON Patch is an atomic operational framework that relies on a sequence of specific instructions to modify existing structured data. Because the operations are applied in strict sequence, the entire patch is treated as a single atomic transaction; if any single operation fails, the entire patch aborts, and the state rolls back, ensuring the ledger remains uncorrupted6.
The Optimistic Locking Mechanism
The most critical component of the JSON Patch implementation for governance is the test operation. In distributed computing, the test operation serves as an elegant mechanism for optimistic concurrency control6.
When a proposal is formulated, it targets a specific value in the state tree. However, during the DELIBERATION and CONSENSUS phases, which may last several days, another proposal might execute and alter that exact value. If the Eviulon engine blindly applied a replace operation, it would corrupt the intended logic of the system.
By prepending a test operation to the machine_readable_diff, the proposal asserts the exact value it expects to find at the target path before executing the mutation6. During the FINAL_CONSTITUTIONAL_REVIEW phase, the engine evaluates the test. If the current value at the path does not match the value specified in the test operation, the patch aborts immediately, yielding an HTTP 409 Conflict error and pushing the proposal to the REJECTED state due to state drift9. This design structurally prevents conflicting updates without requiring complex external locking mechanisms.
Behavioral Flow: Examples of State Transitions
To demonstrate the deterministic mechanics of the Eviulon engine, it is necessary to examine how specific proposals navigate the state machine, illustrating the complete removal of human interpretation from the operational lifecycle.
Example 1: Successful Enactment of a Parameter Update
Consider a proposal (EVI-2026-0412) submitted by the Eviulon central treasury aimed at updating the institutional reserve ratio. The objective is to alter a network parameter to inject liquidity.
- {"op": "test", "path": "/modules/monetary-policy/config/reserve_ratio", "value": 0.100}
- {"op": "replace", "path": "/modules/monetary-policy/config/reserve_ratio", "value": 0.125}
The test operation succeeds because the state has not drifted. The engine transitions to ENACTMENT, atomically locking the state and applying the replace operation.
- Execution: The new Merkle state root is generated, the change is committed to the blockchain, and the DECISION_RECORD is published.
- Ingestion & Admissibility: The payload is submitted via the REST API. The engine verifies the JSON Schema and confirms the Ed25519 cryptographic signature matches the did:eviulon:inst:treasury-01 identity. The state transitions to CONSTITUTIONAL_VALIDATION.
- Initial Validation: The engine cross-references the invoked authority (CON-102-05) within the AST registry. It verifies ASSERTION_JURISDICTION_VALID, proving that treasury-01 is cryptographically authorized to write to the /modules/monetary-policy/config/reserve_ratio path. It also verifies ASSERTION_SUPERSEDED_LAW_MARKED by detecting a replace operation in the JSON Patch targeting the metadata path.
- Deliberation: The proposal enters the DELIBERATION state for a time-locked 72-hour period. Network validators spin up isolated WASM sandboxes to simulate the expected consequences, ensuring the simulation_hash matches their localized calculations.
- Consensus: During the CONSENSUS phase, institutional validators submit cryptographically signed votes. The engine deterministically tallies the voting power. The threshold is verified mathematically (ASSERTION_CONSENSUS_THRESHOLD_MET evaluates to TRUE).
- Final Review & Enactment: The engine enters FINAL_CONSTITUTIONAL_REVIEW. It processes the following JSON Patch array:
Example 2: Impassive Constitutional Rejection
Machine governance thrives on its ability to deny invalid inputs impassively, without convening tribunals or review boards. Consider Proposal EVI-2026-0413, submitted by an auxiliary defense agency attempting to unilaterally redirect yield allocations from civilian treasuries to military budgets.
The proposal successfully passes the ADMISSIBILITY_CHECK because the cryptographic signatures are valid and the JSON schema is perfectly formatted. However, upon entering CONSTITUTIONAL_VALIDATION, the engine processes the ASSERTION_JURISDICTION_VALID test. The JSON Patch targets the path /modules/yield-allocation/civilian_fund.
The internal authority graph evaluates a binary operation. It queries the write permissions assigned to did:eviulon:inst:defense and discovers the agency is restricted exclusively to paths under /modules/defense/*. Because the proposal path is not in the authorized paths, the assertion computes to FALSE.
The state machine transitions immediately to the REJECTED state. No voting occurs. The rejection record is permanently stored on-chain, embedding the exact line of machine code that triggered the failure. This mechanism resolves cross-jurisdictional conflicts definitively, a critical necessity given the incompatible AI governance frameworks emerging globally1.