Skip to main content

Deterministic execution engine with traceable, immutable history

Project description

Anusara

Deterministic orchestration runtime for agent workflows.

CI PyPI version Python Versions License Architecture


What is Anusara?

Anusara is a deterministic runtime for executing agent workflows.

It executes graphs of agents using:

  • deterministic scheduling
  • event-sourced execution history
  • replay-driven state reconstruction

Every execution becomes:

  • replayable
  • inspectable
  • debuggable
  • reproducible

Anusara treats workflow execution as a runtime system problem, not a collection of loosely connected function calls.


The Mental Model

Agent Graph
     ↓
Deterministic Execution Engine
     ↓
Event Log (source of truth)
     ↓
Replay • Debug • Observability

Execution is not hidden state.

It is a recorded, replayable system.


Why Anusara?

Most agent orchestration systems rely on implicit runtime behavior.

This leads to:

  • nondeterministic execution
  • difficult debugging
  • hidden state transitions
  • unreliable retries
  • poor reproducibility

Anusara solves this by enforcing:

  • deterministic execution
  • event log authority
  • replay-based debugging
  • explicit lifecycle guarantees

Design Philosophy

Anusara = Deterministic Event-Sourced Execution Runtime

Not just orchestration.
Not just workflows.

A runtime system for reliable execution.


Architecture Overview

flowchart LR

Client[Client / API / CLI]
Client --> Runtime

Runtime[Execution Runtime]

Runtime --> Graph[Graph Compiler]
Runtime --> Registry[Agent Registry]
Runtime --> Router[Router]
Runtime --> Mutation[Mutation Engine]

Runtime --> EventLog[(Event Log)]

EventLog --> Replay[Replay Engine]
EventLog --> Debugger[Debugger / Analysis]

Runtime --> Observability[Observability]

Core Responsibilities

Layer Responsibility
Runtime deterministic execution of workflows
Event Log authoritative execution history
Router execution decision logic
Mutation Engine controlled graph evolution
Registry agent discovery and lifecycle
Observability debugging, metrics, visualization

Quick Start

Install:

pip install anusara

Minimal example:

from anusara import ExecutionEngine, GraphDefinition

graph = GraphDefinition(
    nodes=[
        {"id": "A", "agent": agent_a},
        {"id": "B", "agent": agent_b},
    ],
    edges=[("A", "B")]
)

engine = ExecutionEngine()
result = engine.run(graph, input_data)

The runtime handles:

  • scheduling
  • retries
  • event logging
  • replay
  • observability

Execution Graph

Workflows are defined as directed graphs.

graph LR
    A --> B
    A --> C

    subgraph Wave_0
        A
    end

    subgraph Wave_1
        B
        C
    end

Execution proceeds in deterministic waves.


Key Features

  • deterministic execution
  • event-sourced execution history
  • replayable workflows
  • graph-based orchestration
  • built-in observability
  • runtime debugging tools
  • controlled workflow mutation

Documentation

Documentation is available in the docs/ directory.

Concepts

  • deterministic execution
  • event sourcing
  • execution waves
  • replay

Guides

  • building workflows
  • running executions
  • debugging with replay

Architecture

  • execution model
  • routing model
  • state machine
  • replay model
  • mutation model

Roadmap

See: docs/roadmap.md


Project Status

Anusara is under active development.

Current focus:

  • developer experience (API & usability)
  • onboarding workflows
  • improved tooling

Contributing

Contributions and discussions are welcome.

  • CONTRIBUTING.md
  • CODE_OF_CONDUCT.md
  • SECURITY.md

License

MIT License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

anusara-1.0.1.tar.gz (79.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

anusara-1.0.1-py3-none-any.whl (122.2 kB view details)

Uploaded Python 3

File details

Details for the file anusara-1.0.1.tar.gz.

File metadata

  • Download URL: anusara-1.0.1.tar.gz
  • Upload date:
  • Size: 79.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.15

File hashes

Hashes for anusara-1.0.1.tar.gz
Algorithm Hash digest
SHA256 7b966703463f23c45c8cf4b74c5768df8efc9d9a7b5b603a934c96e0575565f0
MD5 328e22fa5952d439110e49b0dae28161
BLAKE2b-256 723075cbadc0d42e8363eb902360f5688059d3ec70060dcdc05611c86b840179

See more details on using hashes here.

File details

Details for the file anusara-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: anusara-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 122.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.15

File hashes

Hashes for anusara-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e05382d63ca84228847bbe68f09fd93c94ac7f5f0b1a32af7bda59d10ad023ec
MD5 b9d78272d4da0a92d9e837eed2e623e4
BLAKE2b-256 4f49bf2f53b6e678e9e17a0493de558a261e92f76af366186ea15ff045929aac

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page