Skip to main content

AER-1 Middleware

Verifiable execution receipts for AI agent frameworks.

Implements IETF draft-zambo-aer1 ��� an IETF Internet-Draft for verifiable AI agent execution receipts.

Status: the framework adapters have been validated end to end against the real framework SDKs (FastMCP, langchain-core, openai-agents, opentelemetry-sdk), and generated receipts pass the AER-1 conformance kit's core check against draft-zambo-aer1-10. The package is not yet published on PyPI.

Installation

Not yet published on PyPI. Install from source:

git clone https://gitlab.com/rambozambodotdev/zambo.git
cd zambo/aer1-middleware
pip install -e .

FastMCP (one line)

from fastmcp import FastMCP
from aer1_middleware.fastmcp import AER1Middleware

mcp = FastMCP("my-server")
mcp.add_middleware(AER1Middleware())  # That's it. Every tool call now generates a receipt.

LangChain (one line)

from langchain_openai import ChatOpenAI
from aer1_middleware.langchain import AER1Callback

llm = ChatOpenAI(callbacks=[AER1Callback()])

OpenAI Agents SDK (one decorator)

from agents import function_tool
from aer1_middleware.openai_agents import with_aer1

@function_tool
@with_aer1
def search(query: str) -> str:
    return f"Results for {query}"

(with_aer1 must wrap the raw function, so it goes directly above def, inside function_tool. Retrieve receipts with from aer1_middleware.openai_agents import get_receipts.)

OpenTelemetry (span exporter)

from aer1_middleware.otel import AER1SpanExporter

exporter = AER1SpanExporter()
exporter.export_receipt(receipt)

Manual usage

from aer1_middleware import create_receipt, verify_receipt

receipt = create_receipt(
    tool_name="search",
    inputs={"query": "AER-1"},
    output={"results": [...]},
)

is_valid, reason = verify_receipt(receipt)

What is AER-1?

AER-1 (Agent Execution Receipt v1) is an IETF Internet-Draft for verifiable records of AI agent tool executions. Each receipt contains:

  • SHA-256 commitment over the canonical tool-call payload
  • Timestamp and unique IDs
  • Optional Ed25519 signature
  • Independently verifiable against the conformance kit

A receipt proves the saved result has not changed. It does not prove the model was right, and it does not by itself prove an external outcome.

License

MIT

Metadata

Release files for aer1-middleware 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for aer1-middleware 0.2.0
File Size Uploaded
aer1_middleware-0.2.0.tar.gz 8.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for aer1-middleware 0.2.0
File Interpreter ABI Platform
aer1_middleware-0.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 18.4 kB

Release files / aer1_middleware-0.2.0.tar.gz

Download URL aer1_middleware-0.2.0.tar.gz
Size 8.2 kB
Tags Source
SHA-256 checksum
How to use checksums
c3285c39c55fa90fea0913a0d9f82ad81db933e6a04090fdb9ea80caa98ee108
BLAKE2b-256 checksum
How to use checksums
3c0258d5692e978afc3f26bf2528049ea10b297bee99fd990f6bd067908841c0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via rambo-pypi-grab/0.1.0

Release files / aer1_middleware-0.2.0-py3-none-any.whl

Download URL aer1_middleware-0.2.0-py3-none-any.whl
Size 10.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6b2119d447425e808b793eea8eaa96492855858599af843f8248a7fa79a88eb8
BLAKE2b-256 checksum
How to use checksums
9c3011bffd1c0df6b44bcef314fd01d6f8990b6c7b6c054e4a0099aa6b2cab24
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via rambo-pypi-grab/0.1.0

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page