Metadata-Version: 2.5
Name: caura-rail
Version: 1.0.1
Summary: Memory operations around every agent turn, for managed and self-hosted Caura.
Project-URL: Homepage, https://github.com/caura-ai/caura-rail
Project-URL: Documentation, https://github.com/caura-ai/caura-rail/tree/main/docs
Project-URL: Repository, https://github.com/caura-ai/caura-rail
Project-URL: Changelog, https://github.com/caura-ai/caura-rail/blob/main/CHANGELOG.md
Project-URL: Issues, https://github.com/caura-ai/caura-rail/issues
Author: Caura
License-Expression: Apache-2.0
License-File: LICENSE
Keywords: agents,caura,governance,llm,memory,recall
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Topic :: Software Development :: Libraries
Classifier: Typing :: Typed
Requires-Python: >=3.10
Requires-Dist: httpx<1,>=0.27
Provides-Extra: dev
Requires-Dist: build>=1.2; extra == 'dev'
Requires-Dist: mypy>=1.14; extra == 'dev'
Requires-Dist: pytest-asyncio>=0.24; extra == 'dev'
Requires-Dist: pytest>=8; extra == 'dev'
Requires-Dist: ruff>=0.11; extra == 'dev'
Requires-Dist: twine>=6; extra == 'dev'
Description-Content-Type: text/markdown

# Caura Rail for Python

[![PyPI](https://img.shields.io/pypi/v/caura-rail?label=PyPI&color=0E6B5A)](https://pypi.org/project/caura-rail/) [![Python](https://img.shields.io/pypi/pyversions/caura-rail?label=Python)](https://pypi.org/project/caura-rail/) [![CI](https://img.shields.io/github/actions/workflow/status/caura-ai/caura-rail/ci.yml?label=CI)](https://github.com/caura-ai/caura-rail/actions/workflows/ci.yml) [![License](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](https://github.com/caura-ai/caura-rail/blob/main/LICENSE)

Memory operations around agent turns: fetch governance rules and relevant facts
from [Caura](https://caura.ai) before your agent runs, then extract and store
facts from the completed turn. Fully typed, synchronous and asynchronous.

```bash
python -m pip install caura-rail
```

```python
from caura_rail import MemoryScope, Rail, RestMemoryStore

with RestMemoryStore.from_env() as store:  # CAURA_URL, CAURA_API_KEY
    rail = Rail(store, MemoryScope(agent_id="support-1"))
    with rail.turn("Remember: We deploy in eu-west-1.") as turn:
        turn.reply = "Noted. " + turn.context.text  # pass context to your model
    print(turn.reply, [w.status for w in turn.writes])
```

Full documentation, including the guide, API reference, and reliability
semantics, lives in the
[repository](https://github.com/caura-ai/caura-rail#readme).
A TypeScript package with the same semantics is published as `@caura/rail`.

Licensed under Apache-2.0.
