Metadata-Version: 2.4
Name: llama-agents-dbos
Version: 0.3.1
Summary: DBOS durable runtime plugin for LlamaIndex Workflows
License-Expression: MIT
Requires-Dist: dbos>=2.18.0
Requires-Dist: llama-agents-server[asyncpg]>=0.5.0
Requires-Dist: llama-index-workflows>=2.19.1,<3.0.0
Requires-Python: >=3.10
Description-Content-Type: text/markdown

# LlamaAgents DBOS Runtime

DBOS durable runtime plugin for LlamaIndex Workflows.

## Installation

```bash
pip install llama-agents-dbos
```

## Usage

```python
import asyncio
from llama_agents.dbos import DBOSRuntime
from dbos import DBOS, DBOSConfig
from workflows import Workflow, step, StartEvent, StopEvent

# Configure DBOS
config: DBOSConfig = {
    "name": "my-app",
    "system_database_url": "postgresql://...",
}
DBOS(config=config)

# Create runtime and workflow
runtime = DBOSRuntime()

class MyWorkflow(Workflow):
    @step
    async def my_step(self, ev: StartEvent) -> StopEvent:
        return StopEvent(result="done")

workflow = MyWorkflow(runtime=runtime)

# launch_sync() works outside async contexts; use await runtime.launch() inside one
runtime.launch_sync()

async def main():
    result = await workflow.run()

asyncio.run(main())
```

## Features

- Durable workflow execution backed by DBOS
- Automatic step recording and replay
- Distributed workers and recovery support
