# OpenRath v2.0.0 Quickstart This quickstart runs the Stable OpenRath v2.0.0 release in an embedded local process. It uses SQLite and does not require an LLM, PostgreSQL, Redis, or object storage. ## Install the release asset Install the exact Stable `2.0.0` release wheel: ```bash python -m venv .venv source .venv/bin/activate python -m pip install \ "openrath @ https://github.com/Rath-Team/OpenRath/releases/download/v2.0.0/openrath-2.0.0-py3-none-any.whl" ``` OpenRath supports CPython 3.10 through 3.13. ## Run one durable workflow Save this as `durable_quickstart.py`: ```python from pathlib import Path from uuid import uuid4 from rath.context import RunContext from rath.definition import EffectClass, step from rath.flow import Workflow from rath.runtime import LocalRuntime, RunStatus, SQLiteRunStore from rath.session import Session class DurableHello(Workflow): @step(entry=True, effects=EffectClass.READ_ONLY) def finish(self, state, context): return {**state, "message": "hello from OpenRath v2"} # The v1 callable façade remains available in v2.0.0. def forward(self, session: Session) -> Session: return session store = SQLiteRunStore(Path("openrath-quickstart.db")) runtime = LocalRuntime(store) revision_id = uuid4() submitted = runtime.submit( DurableHello(), session_id=uuid4(), context=RunContext.local(revision_id=revision_id), state={"requested_by": "local-test"}, idempotency_key="durable-hello-1", ) completed = runtime.work_once(worker_id="local-worker") assert completed is not None assert completed.id == submitted.id assert completed.status is RunStatus.SUCCEEDED print(completed.state) print(store.list_checkpoints(completed.id)) store.close() ``` Run it: ```bash python durable_quickstart.py ``` The runtime compiles the explicit step into an immutable plan, creates a durable Run, leases it to the local worker, commits a checkpoint, and marks the Run succeeded. Reopening the same SQLite file preserves the Run, events, and checkpoints. ## Move toward the Agent Server profile The production-oriented reference profile requires the server and PostgreSQL extras: ```bash python -m pip install \ "openrath[server,postgres] @ https://github.com/Rath-Team/OpenRath/releases/download/v2.0.0/openrath-2.0.0-py3-none-any.whl" ``` Before serving traffic: 1. Set an explicit PostgreSQL DSN and use a separate DDL-capable identity. 2. Run `openrath-migrate`, then `openrath-migrate --check`. 3. Configure tokens with explicit action grants; the reference server rejects wildcard grants. 4. Wire a durable audit collector and a fail-closed policy. 5. Use immutable image digests and validate backup, restore, rollout, and rollback in the target environment. Continue with [Operations](operations.md) and the tagged [reference application](https://github.com/Rath-Team/OpenRath/blob/v2.0.0/examples/v2_server_app.py).