Metadata-Version: 2.4
Name: model-action-protocol
Version: 0.1.1
Summary: MAP (Model Action Protocol) — verifiable provenance, self-healing critique, and state rollback for autonomous AI agents
Project-URL: Homepage, https://github.com/DeadpxlStudio/ModelActionProtocol
Project-URL: Repository, https://github.com/DeadpxlStudio/ModelActionProtocol
Project-URL: Specification, https://github.com/DeadpxlStudio/ModelActionProtocol/blob/main/spec/SPEC.md
Project-URL: Changelog, https://github.com/DeadpxlStudio/ModelActionProtocol/blob/main/CHANGELOG.md
Author-email: deadpxl <deadpxlstudio@gmail.com>
License-Expression: MIT
Keywords: agents,ai,model-action-protocol,provenance,rollback,safety,trust
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
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.15,>=3.10
Requires-Dist: pydantic<3,>=2.5
Provides-Extra: all
Requires-Dist: anthropic>=0.40; extra == 'all'
Requires-Dist: fastapi>=0.115; extra == 'all'
Requires-Dist: psycopg[binary]>=3; extra == 'all'
Requires-Dist: uvicorn[standard]>=0.32; extra == 'all'
Provides-Extra: anthropic
Requires-Dist: anthropic>=0.40; extra == 'anthropic'
Provides-Extra: dev
Requires-Dist: build>=1.2; extra == 'dev'
Requires-Dist: hypothesis>=6.100; extra == 'dev'
Requires-Dist: mypy>=1.13; extra == 'dev'
Requires-Dist: pyright>=1.1.380; extra == 'dev'
Requires-Dist: pytest>=8.0; extra == 'dev'
Requires-Dist: respx>=0.21; extra == 'dev'
Requires-Dist: ruff>=0.7; extra == 'dev'
Requires-Dist: twine>=5.1; extra == 'dev'
Provides-Extra: fastapi
Requires-Dist: fastapi>=0.115; extra == 'fastapi'
Requires-Dist: uvicorn[standard]>=0.32; extra == 'fastapi'
Provides-Extra: postgres
Requires-Dist: psycopg[binary]>=3; extra == 'postgres'
Description-Content-Type: text/markdown

# model-action-protocol (Python)

Python implementation of the [Model Action Protocol](../spec/SPEC.md). Cryptographic provenance, self-healing, and state rollback for autonomous AI agents.

This package conforms to MAP spec version `0.1.0`. Both this implementation and the TypeScript reference implementation produce byte-identical hashes for the same inputs, verified by the shared conformance fixtures in `../spec/fixtures/v0.1/`.

## Install

```bash
pip install model-action-protocol
```

Optional extras:

```bash
pip install "model-action-protocol[anthropic]"   # LLM critic via Anthropic SDK
pip install "model-action-protocol[sqlite]"      # async SQLite store
pip install "model-action-protocol[postgres]"    # async Postgres store
pip install "model-action-protocol[fastapi]"     # FastAPI demo deps
pip install "model-action-protocol[all]"
```

## Quickstart

See `examples/quickstart.ipynb` for the full Jupyter walkthrough and `examples/fastapi_app/` for an HTTP service template.

## Specification

The wire format, canonicalization rule (RFC 8785), hash inputs, and chain verification algorithm are defined in [`spec/SPEC.md`](../spec/SPEC.md). Implementation details (Pydantic models, async I/O patterns, anthropic SDK integration) are not part of the spec — they are this implementation's choices.
