An engine that thinks.A game that stays yours.
Janus is the AI-native game engine. A deterministic Rust core holds canonical reality; asynchronous AI cognition makes your world react and remember; one audited gateway joins the two. The AI does the plumbing. You keep authorship.
Deterministic ECS
Canonical reality. Every gameplay fact, Epoch-versioned, fixed-point, replayable.
Semantic Action Compiler
Every intent from every source passes the same seven stages. The audit entry is written before anything commits.
Asynchronous cognition
Characters, the Director and the content pipeline think off the frame loop and propose, never mutate.
AI-native ECS + Semantic Action Compiler
Janus has two faces. One is a deterministic Entity Component System that holds every gameplay fact. The other is asynchronous AI cognition that makes the world feel alive. They meet at exactly one place: the Semantic Action Compiler. NPCs, the Director, players, systems and mods all speak the same typed intent language, and every intent runs the same seven-stage pipeline before it commits.
- Constrained decoding makes malformed intents physically un-emittable
- Epoch-versioned snapshots for rollback, save/load and replay
- Structured, stage-tagged rejections so agents never loop on a doomed plan
- Games and mods extend the intent language through the same gate
- 1Constrained decodingVerify the intent came from an active, signed cognition profile.
- 2Schema validationParse into typed Rust; enforce cross-field invariants.
- 3Capability checkVerify the token covers the action and only ever narrows.
- 4Epoch validationReject thoughts that ran on a rolled-back world.
- 5World-state legalityResolve references; run engine and game-registered rules.
- 6Consequence forecastSimulate significant intents ahead; reject second-order damage.
- 7Commit + auditWrite the audit entry first, then commit atomically.
Cognition Tier Scheduler
The scheduler decides when each character thinks, on which tier, and on whose budget. Moment-to-moment decisions run on small local models; long-horizon reasoning and narrative pacing escalate to frontier cloud models. The render thread never waits on a thought, and under load the engine degrades in a fixed, predictable order.
- Six dispatch tiers, from the frame loop to the Director
- Semantic level of detail: attention follows narrative weight, not just distance
- Separate compute and token budgets you control
- Deterministic graceful degradation and automatic recovery
| Tier | Cadence | Runs on |
|---|---|---|
| 1Render / PhysicsFrame loop · reads cache | 60–144 Hz | Frame loop · reads cache |
| 2Animation hintLocal heuristics | 15–30 Hz | Local heuristics |
| 3TacticalLocal model | 5–10 Hz | Local model |
| 4StrategicHybrid local + cloud | 1–2 Hz | Hybrid local + cloud |
| 5World simulationDeterministic + cloud | 0.1–1 Hz | Deterministic + cloud |
| 6DirectorFrontier cloud + local fallback | Event-driven | Frontier cloud + local fallback |
NPC memory
Janus persists memory at character granularity. Working memory is assembled per thought; episodic memory records what each character lived through; long-term beliefs live as ECS components on the character itself. Nothing becomes a belief without passing a five-stage consolidation pipeline built to resist memory poisoning.
- Working, episodic and long-term layers, isolated per character
- Provenance on every memory entry
- Consolidation with anomaly detection and population-level coherence checks
- Monotonic skepticism: trust is earned back, never assumed
- 1 Provenance verification
- 2 Anomaly detection
- 3 Population coherence
- 4 Sandboxed validation
- 5 Cryptographic commit
The Director
The Director reasons outside the frame budget to keep an emergent world dramatically coherent: when to raise the pressure, when to let the player breathe, which thread to escalate. Its authority is a closed allow-list of seven intent types with hard caps, and it can never touch player-owned state.
- Seven allow-listed intents: spawn events, surface opportunities, modulate tension and more
- Hard caps on scope and intensity per action
- Reads snapshots, never writes directly; every decision audited
- Player stats, inventory and agency are out of reach by design
- SpawnNarrativeEvent
- SurfaceOpportunity
- ModulateTension
- AdjustNarrativeThread
- AdjustNarrativeSignificance
- RegisterForeshadowing
- RequestOperatorAttention
- anything else → rejected
Generative content pipeline
The content pipeline orchestrates the best image, audio, video and language models into game-ready content that fits Janus component contracts. Describe what you want, compose proven building blocks, then refine any single knob. The same pipeline powers all 17 tools in Janus Studio, with prompt-IP lint, AI marking, fingerprints and a provenance record on every asset.
- Describe → compose → refine, with every module explicit and editable
- Vendor-agnostic service ports with multi-provider fallback
- Provenance record per asset: model, prompt, settings and cost
- Exports to Bevy, Phaser and Godot
Identity Anchor
Identity Anchor pairs AI-native characters with cryptographically verified players. It ships standalone with Ed25519 signatures and post-quantum Dilithium ready, and plugs into the IDFire Identity Platform when you want it. It is opt-in and configured at runtime, so a single-player prototype pays nothing for it.
- Standalone Ed25519 by default; Dilithium for post-quantum readiness
- Opt-in, runtime-configured
- Integrates with the IDFire Identity Platform
- Capability tokens that only ever narrow when delegated
- Ed25519Default signatures. Standalone, fast, battle-tested.Default
- DilithiumPost-quantum signatures, ready when you are.PQ-ready
- IDFire Identity PlatformVerified-real players across your games, when you want it.Optional
Audit-anchored AI decisions
Audit-before-commit is non-negotiable in Janus: if the audit entry cannot be written, the change does not happen. Standalone, decisions go to a local append-only signed log with checkpoint rotation; integrated, they anchor to a Merkle transparency log. You can always answer "why did that character do that?"
- Audit completeness is exactly one entry per committed intent
- Fail-closed by default
- Local signed log or Merkle transparency anchoring
- Built for regulated markets and trust-critical games
{
"epoch": 184223,
"intent": "SurfaceOpportunity",
"origin": "director",
"capability": "narrative.surface:region",
"stages": ["decode", "schema", "capability", "epoch", "legality", "forecast", "commit"],
"forecast": {
"epochs": 5,
"invariants": "ok"
},
"committed": true,
"signature": "ed25519:9f2c…41ab",
"prev": "sha256:7d1e…c09f"
}Rust + Bevy foundation
Janus is written in Rust and stands on Bevy and Rapier, behind trait surfaces Janus owns, so the core stays fast, memory-safe and swappable. Gameplay state uses fixed-point transforms for bit-identical replays on the same architecture. Game definitions and module manifests are text, so git just works.
- Rust core on Bevy with Rapier physics
- Fixed-point transforms; deterministic replays
- Machine-readable module manifests: pick the what, defer the how
- Text-based, git-mergeable game definitions
# Every module describes itself, so Janus can pick it from a sentence [module] name = "grudge-memory" purpose = "Characters remember who wronged them, and act on it" triggers = ["hold grudges", "remember insults"] capability = "memory.long_term" [presets.forgiving] decay_days = 3 [presets.never_forgets] decay_days = 0
Ship where your players are.
Janus builds on Bevy's cross-platform foundation, and Janus Studio exports straight into the engines you already use.
The engine is ours. Everything you make with it is yours.
Your game, your IP
Everything you build and everything Janus generates for you belongs to you. Commercial use included.
Never retroactive
License terms you ship under are the terms you keep. No surprise runtime fees, no per-install or per-player charges.
Text all the way down
Game definitions and module manifests are plain text. Diff them, review them, merge them. Git just works.
Inspectable AI
No black boxes: every module stays explicit and editable, and every authority-bearing AI decision is on the record.
Free until your game earns $1M, then a simple 5% royalty, or a custom license. See licensing →
Build your world on Janus.
Get engine access for your studio, or start making in Janus Studio right now.