langchain-aotrust
LangChain tools for AOTrust notarization — cryptographic proof-of-existence for AI agent outputs. Free tier (no wallet required), PDRs signed with Ed25519, Merkle-included and anchored on NEAR.
Works with any agent built on langchain-core (LangChain, LangGraph,
CrewAI via the standard BaseTool interface, pydantic-ai adapters).
Install
pip install langchain-aotrust
Quickstart
from langchain_aotrust import (
aotrust_notarize_free,
aotrust_verify,
aotrust_status,
)
# 1. Notarize an artifact (free tier — no API key, no wallet)
print(aotrust_notarize_free.invoke({"artifact_text": "analysis v3: portfolio risk moderate"}))
# Notarized (tier=free). shield_id=9f2c... job_id=7a1b... work_hash=...
# Verify later at https://verify.aotrust.link or with aotrust_verify(job_id).
# 2. Check pipeline status
print(aotrust_status.invoke({"job_id": "<job_id>"}))
# Status for job_id=7a1b...: status=anchored, anchored=yes, payment_hash=...
# 3. Full cryptographic verification
print(aotrust_verify.invoke({"job_id": "<job_id>"}))
# Verification for job_id=7a1b...: valid=True, payment_anchor_type=0, ...
Wiring into a LangChain agent:
from langchain_aotrust import aotrust_notarize_free, aotrust_verify
from langchain.agents import create_tool_calling_agent # any agent works
tools = [aotrust_notarize_free, aotrust_verify, aotrust_status]
Async agents (LangGraph) can await the plain functions directly:
from langchain_aotrust import aotrust_notarize_free_async
result = await aotrust_notarize_free_async(artifact_text="...")
Configuration (optional — defaults to the public endpoint):
from langchain_aotrust import configure
configure(base_url="https://api.aotrust.link") # NO /v1 suffix — the SDK appends paths
What the proofs mean
| Horizon | Guarantee |
|---|---|
| Instant | SHA-256 work_hash bound into a signed PDR (Ed25519, notary key) — tamper-evident from notarization time |
| Python | PDR bytes verifiable offline by anyone with the notary public key |
| Forever | Daily Merkle root anchored on NEAR blockchain — proof survives even if the service disappears |
Free tier
- No API key, no wallet, no payment.
- Rate limited per IP (5 notarizations / 24h) — paid x402 tier ($0.01) in a future release for higher throughput.
Links
- Docs: https://docs.aotrust.link
- Live verifier: https://verify.aotrust.link
- SDK: https://pypi.org/project/aotrust-protocol/
License
MIT
Metadata
Release files for langchain-aotrust 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| langchain_aotrust-0.1.0.tar.gz | 7.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| langchain_aotrust-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 14.3 kB
Release files / langchain_aotrust-0.1.0.tar.gz
| Download URL | langchain_aotrust-0.1.0.tar.gz |
|---|---|
| Size | 7.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
80a5c44aa024301bcd8ed46e57411843cddea47d50bda974d66d14e68af02b1a
|
|
BLAKE2b-256 checksum How to use checksums |
020600d09cf297a9ab2f072528baedfbc5ace18849663ae047695d48813cb300
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.3
|
Release files / langchain_aotrust-0.1.0-py3-none-any.whl
| Download URL | langchain_aotrust-0.1.0-py3-none-any.whl |
|---|---|
| Size | 6.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d4e8f13fae7f356b44d1837fbb26494bc2432f5c36623bf04cc7c313de944c29
|
|
BLAKE2b-256 checksum How to use checksums |
0e1d7afec8eb648a76ed3d9f714ba518ed541e5f53c8dc314fe817f8e5bd1ece
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.12.3
|