Oracle Omen is a production-grade Rust framework for deterministic, auditable, replayable autonomous agents with governed self-evolution.
- Determinism is mandatory - Same inputs always produce same outputs
- Side effects must be explicit - All IO goes through capability-gated tools
- All tool calls are logged - Every action has an audit trail
- All state transitions are logged - Full history reconstruction is possible
- No silent mutation - All changes are recorded
- No global state - State is explicit and passed around
- No implicit permissions - Capabilities are checked before every tool call
- No opaque magic - Everything is transparent and inspectable
- No panics in runtime paths - Errors are data, not crashes
- No unordered iteration where it matters - Use BTreeMap for deterministic ordering
oracle_omen/
├── oracle_omen_core # Pure logic, no IO
├── oracle_omen_plan # Planning DSL and DAG compilation
├── oracle_omen_runtime # IO, tools, scheduler, capability enforcement
├── oracle_omen_memory # CRDT, provenance, retrieval ordering
└── oracle_omen_cli # Interface and presentation
An agent is a pure state machine:
Input: prior state, observation, tool responses, injected deterministic context
Output: next state, planned actions, patch proposals
Agents cannot directly perform IO. All IO goes through tools.
Append-only log of all events:
- event_id: stable identifier (run_id:sequence)
- parent_event_id: causal linkage
- timestamp: injected logical time
- kind: event type
- payload: event data
- payload_hash: for verification
- state_hash_before/after: for state tracking
Agent state is a typed container:
- version: increments on each transition
- data: BTreeMap<String, StateData> for deterministic ordering
- state_hash: for verification
Tools declare:
- name and version
- input schema and output schema
- required capabilities
- side effect declaration (Pure/Impure)
- determinism declaration
- timeout and resource bounds
Capabilities grant permission:
- Format: domain:action:scope
- Example: fs:read:*, network:http:get
- Immutable during execution run
- Checked before tool execution
- Event ordering: Events are ordered by sequence within a run
- Hash stability: Same data always produces same hash
- Serialization stability: BTreeMap ensures stable key ordering
- Time monotonicity: Logical time only increases
- State transition validity: Transitions are logged and verifiable
- Capability enforcement: Tools cannot run without capabilities
- Detection: Hash mismatch on replay
- Recovery: Restore from last valid snapshot
- Prevention: Atomic writes, hash verification
- Detection: Different hash on replay
- Recovery: Diff tool identifies divergence point
- Prevention: Deterministic tools, seeded randomness
- Detection: Audit log shows tool without capability
- Recovery: Event marked as denied, execution stops
- Prevention: Strict capability checking at runtime
- Detection: Different outputs on replay
- Recovery: Tool marked as non-deterministic
- Prevention: Tool declarations, testing
┌─────────────────────────────────────────────────────────────────┐
│ Agent │
│ ┌─────────────┐ ┌─────────────┐ ┌─────────────────────┐ │
│ │ State │ -> │ Planning │ -> │ Decision │ │
│ └─────────────┘ └─────────────┘ └─────────────────────┘ │
└───────────────────────────────┬─────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────────┐
│ Runtime │
│ ┌─────────────┐ ┌─────────────┐ ┌─────────────────────┐ │
│ │ Capabi- │ -> │ Tool │ -> │ Event │ │
│ │ lity Check │ │ Execution │ │ Logging │ │
│ └─────────────┘ └─────────────┘ └─────────────────────┘ │
└───────────────────────────────┬─────────────────────────────────┘
│
▼
┌─────────────────────────────────────────────────────────────────┐
│ Memory Store │
│ ┌─────────────┐ ┌─────────────┐ ┌─────────────────────┐ │
│ │ CRDT │ <- │ Provenance │ <- │ Causal Links │ │
│ │ Documents │ │ Tracking │ │ │ │
│ └─────────────┘ └─────────────┘ └─────────────────────┘ │
└─────────────────────────────────────────────────────────────────┘
- Initialize: Create initial state, event log, capability set
- Observe: Read input from environment (logged as event)
- Decide: Agent produces decision based on state + observation
- Execute: Run tools with capability checks (logged as events)
- Update: Apply tool responses to state (logged as event)
- Repeat: Go to step 2 until termination
- Snapshot: Save state and event position for efficient replay
- Load event log
- Load snapshot (if available) to skip early events
- Replay events from snapshot position
- Verify each event hash
- Reconstruct state
- Compare final state hash with original