memledger
Memory governance and trust layer for multi-agent AI systems.
memledger adds attribution, provenance, confidence gating, and quality measurement on top of any vector-backed memory store. Every memory carries a source, a confidence score, a derivation chain, and an audit trail — so when agents share memory, trust transfers become legible instead of invisible.
✅ v2.0.0 — AWS-native release. Stable API; subsequent releases follow SemVer.
Why memledger
Existing memory frameworks (Mem0, Zep, Letta, AgentCore Memory) optimize for recall quality — how accurately the system retrieves relevant memory. None of them address accountability: who wrote this memory, how confident were they, what did they derive it from, and how has it been used since.
In a single-agent system, the accountability gap is academic. In a multi-agent system where agents read and act on each other's beliefs, it is the fault line where systems fail at scale.
What v2.0.0 ships
- Attribution — every memory carries
created_by,confidence,session_id,derived_from,supersedes,workflow_id,triggered_by,hedged,namespace - Weakest-link provenance chain — derivation chains tracked across agent boundaries; effective confidence for retrieval is
min(declared, chain.min_confidence)— a high-conf claim built on a low-conf ancestor cannot outscore its weakest link - Confidence-gated retrieval —
PASS/FLAG/FILTERpolicy applied at search time, against effective confidence - Namespace RBAC — declarative per-agent access control over hierarchical namespaces;
add()andsearch()both gate on it - 3-tier evaluation suite — deterministic Memory Attribution Integrity (record-quality view) + RAGAS LLM-as-judge (provider-agnostic via LiteLLM; verified end-to-end on Bedrock Sonnet) + structural evaluator (OTEL-span based, no LLM)
- AWS-native backends — Aurora PostgreSQL with IAM auth, OpenSearch with SigV4 + faiss + hybrid RRF, Bedrock for embeddings (Titan v2) and the LLM strategy layer (Sonnet)
- OpenTelemetry observability — every operation emits an OTLP span with
memledger.*trust attributes; tier-1 set to OpenInference span kinds so Arize Phoenix categorizes them out of the box - Outcome feedback loop —
record_outcome()updates memory confidence based on observed downstream outcomes - MCP server — framework-agnostic adoption via Model Context Protocol
Full architecture, concepts, and API reference at memledger.com/docs.
Install
The OSS-default install needs no cloud credentials:
pip install 'memledger[oss]'
The AWS-native install:
pip install 'memledger[aws]' # Aurora pgvector + Bedrock
pip install 'memledger[aws,opensearch]' # add OpenSearch backend
Other extras (combine as needed):
| Extra | Use |
|---|---|
[oss] |
Local ONNX embeddings + Postgres + pgvector — no cloud keys |
[aws] |
Aurora pgvector + Bedrock embeddings + Bedrock judge |
[opensearch] |
Amazon OpenSearch backend (SigV4 + faiss + hybrid RRF) |
[eval] |
RAGAS LLM-as-judge (Tier 2 of the eval suite) |
[telemetry] |
Phoenix-OTEL helper on top of the core OTEL stack |
[mcp] |
MCP server for framework-agnostic adoption |
Backend contract: the only required backend is open-source PostgreSQL ≥ 14 with the pgvector extension ≥ 0.5. Aurora, RDS, Supabase, Neon — same backend, only the DSN changes.
Quick start (60 seconds)
# 1. Postgres + pgvector locally
docker run -d -p 5432:5432 -e POSTGRES_PASSWORD=postgres pgvector/pgvector:pg16
# 2. Install
pip install 'memledger[oss]'
# 3. Write + search one memory
import asyncio
from memledger import Memledger
async def main():
ml = await Memledger.create(
backend_name="pgvector",
connection_string="postgresql://postgres:postgres@localhost:5432/postgres",
)
await ml.add(
content="HikariCP maxPoolSize=50 fixes payment-service OOM",
namespace="/ops/incidents/payment-svc",
confidence=0.9,
created_by="ops-agent",
)
results = await ml.search(
query="connection pool fix",
namespace="/ops/incidents/payment-svc",
)
for r in results.records:
print(r.confidence, r.created_by, "::", r.content)
await ml.close()
asyncio.run(main())
For multi-agent walkthroughs (weakest-link gate, contamination interception, eval pipeline), see memledger.com/docs/concepts/provenance-chain.
CLI
memledger init # write a starter memledger.yaml
memledger add "fact" --namespace /n --agent-id a --confidence 0.8
memledger search "query" --namespace /n --confidence-min 0.6
memledger get <memory-id> --chain
memledger eval <session-id>
memledger status
memledger --help for the full surface.
Roadmap
| Version | What |
|---|---|
| v2.0 (this release) | AWS-native trust layer; 3-tier eval suite; weakest-link confidence; namespace RBAC; MCP |
| v2.1 (Jun 15) | DynamoDB backend with composition; LangGraph + OpenAI Agents SDK adapters; memledger lint CLI |
| v2.2 (Jun 30) | Mem0 + Letta backend adapters; DeepEval + Phoenix Evals adapters |
| v3.0 (Jul 15) | Eval feedback flywheel — outcomes drive automated memory promote/demote |
License & support
Apache 2.0. License file ships in the PyPI sdist. For enterprise inquiries, repository access requests, or security disclosures, visit memledger.com.
Metadata
Release files for memledger 2.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| memledger-2.0.1.tar.gz | 2.3 MB | With provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| memledger-2.0.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 2.4 MB
Release files / memledger-2.0.1.tar.gz
| Download URL | memledger-2.0.1.tar.gz |
|---|---|
| Size | 2.3 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ca2eb81dc9f504721c07b48d0f200f06022712c51e2417c36de672ae4f1fd7a9
|
|
BLAKE2b-256 checksum How to use checksums |
035342d642181ae73876b2a016a137975be3581b6a587b827a472440dea0e085
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 28, 2026.
Transparency logRelease files / memledger-2.0.1-py3-none-any.whl
| Download URL | memledger-2.0.1-py3-none-any.whl |
|---|---|
| Size | 192.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
4aeb9e3dfc2eeb4956bab089ec2c7bea92f44e3d2c4b224b2914d3c5f91dd2bf
|
|
BLAKE2b-256 checksum How to use checksums |
fcaeb9c0975cffb10ba56a85275c72fc6bda0cfbf74c5941a0e2c516b9e5f530
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 28, 2026.
Transparency logSecurity for memledger 2.0.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for memledger-2.0.1.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on May 28, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.