Skip to main content
Euca turns “did the world end up how it should?” into data. You write an assertion — a named, typed expectation over world state (at least one hero exists, the hero's health is above 100) — and the engine evaluates it against the live world. Probe advances the simulation and checks assertions in one call; a manifest links a build’s features to the assertions that define “done,” so the build grades itself. This page writes a contract for a world and grades it end to end; every command is real and runnable against a local server, with output captured from one.

Write and evaluate an expectation

Spawn two units to assert over, then create two assertions. An assertion is a name, a condition, and an optional severity (error / warning / info, default error). The condition is a shorthand string with sibling parameters (filter, min, field, op, value, …).
Each assertion is itself an entity (note entity_id:3, 4). Evaluate them all against the live world:
Each result carries a human-readable message explaining why it passed or failed. The result is also cached on the assertion (read it back later with GET /assert/results, without re-running). There are 10 condition kinds and 5 filter kinds: Filters are any, team:N, role:NAME, tag:NAME, and component:NAME; join several with + for AND (team:1+role:hero).

Probe — advance and check in one call

probe runs the simulation forward ticks steps, then evaluates assertions — atomically, in one request. It answers “if I run 30 ticks, do these still hold?” Pass assertions to check only named ones.
probe runs on the real world and advances it — it is not a rollback. To check a hypothetical and then discard it, probe a fork instead (POST /fork/{id}/probe).

Grade a build with a manifest

A manifest describes what the build is — a name, genre, description, and a list of features. Each feature links to the assertion names that define “done” for it. Here, combat links to the two assertions we already evaluated (cached as passing); economy links to one that doesn’t exist yet.
Reading the manifest resolves each feature’s status against current assertion results and rolls up a completion percentage:
combat reads as verified even though it was declared inprogress — when every linked assertion has a passing result, the manifest upgrades the effective status. economy stays planned: its assertion was never created, so it reads not_evaluated and doesn’t count. completion_pct is verified features ÷ total — here, 1 of 2 = 50%.

Behavior and gotchas

The things you only find out by running it:
  • probe mutates the real world; it does not roll back. “Atomic” means step-and-evaluate in one call, not a safe peek. The before_snapshot/after_snapshot flags capture summaries but don’t restore state. To check-then-discard, probe a fork.
  • Assertions are entities, and any counts them. Creating an assertion spawns an entity, so an entity-count with filter:"any" includes your assertions in the total. Filter by role, team, or component to count only gameplay entities.
  • entity:N is not a valid assertion filter — it silently becomes any. A bad filter string doesn’t error; it falls back to “match everything.” Create entity-count with filter:"entity:1" and it returns Count 6 (every entity, assertions included), not Count 1. Use the five real filter kinds. (Per-entity targeting by id is a rule filter, not an assertion filter.)
  • Manifest status is lowercase, no underscore — inprogress, not in_progress. Posting in_progress returns {"ok":false,"error":"Invalid manifest: unknown variant \in_progress`, expected one of `planned`, `inprogress`, `complete`, `verified`“}. (POST /manifest/feature*does* acceptin_progress; only POST /manifest` is strict — name them deliberately.)
  • The manifest grades against cached results. A feature reads verified only after its assertions have been evaluated (via /assert/evaluate or /probe). Until then they’re not_evaluated and the feature can’t pass.

Endpoints

Status

  • Shipped — typed assertions (10 condition kinds, 5 filter kinds), evaluation, cached results, probe (including on forks), and a feature manifest with completion tracking. All headless.
  • Caveat — probe advances the real world; it does not roll back. To check then discard, probe a fork instead.

Assertion & manifest endpoints

Assertion, probe, and manifest endpoints with request and response schemas.