Skip to main content

Cryptographically verified, relational, persistent memory for AI agents.

Project description

cryptomem

Cryptographically verified, relational, persistent memory for AI agents.

This package is the Python engine. Every fact is SHA-256 hashed and Ed25519 signed at write time; at read time each node is re-verified, and tampered or unsigned facts are dropped so the agent abstains rather than guessing.

from cryptomem import MemoryClient

mem = MemoryClient()
mem.archive("Project Phoenix", "Budget approved at $4.2M for FY26.")

for hit in mem.query("What budget did Project Phoenix get?"):
    print(hit.node.content, hit.confidence)

print(mem.answer("What budget did Project Phoenix get?"))

Runs on CPU-only hardware with zero model downloads via the default stub embedder and in-memory SQLite store. See the repository docs/ for the full architecture and roadmap.

Beyond retrieval

  • mem.respond(...) — answer plus a provenance block (injected node ids, verification status, Merkle root).
  • mem.proof(node_id) — a verifiable Merkle inclusion proof against the current ledger root.
  • mem.confidence(...) — semantic-entropy confidence over sampled answers.
  • mem.verify_answer(draft) — Chain-of-Verification re-check of a draft.
  • mem.contradictions() — same-entity nodes whose content diverges.
  • mem.suggest(...), mem.triggers(), mem.stage_facts(...), mem.pending(), mem.confirm(node_id) — proactive planner, triggers, and write-back of staged (pending) facts that you later confirm.

Store backends

Selected via CRYPTOMEM_MODE (or Settings(mode=...)):

  • sqlite (default) — zero-config local store; Python-side vector search.
  • neo4j — graph-native store over the Bolt driver (pip install "cryptomem[neo4j]", CRYPTOMEM_NEO4J_URI=...).
  • remote — signs locally and POSTs verbatim to a /cmem/v1/* backend (CRYPTOMEM_BACKEND_URL=...); falls back to SQLite if the backend is down.

Optional extras

pip install "cryptomem[local]" (MiniLM embeddings), [serve] (FastAPI Ollama-compatible sidecar + CLI), [neo4j] (graph store), [dev] (tooling).

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cryptomem-0.1.0.tar.gz (31.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cryptomem-0.1.0-py3-none-any.whl (39.4 kB view details)

Uploaded Python 3

File details

Details for the file cryptomem-0.1.0.tar.gz.

File metadata

  • Download URL: cryptomem-0.1.0.tar.gz
  • Upload date:
  • Size: 31.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for cryptomem-0.1.0.tar.gz
Algorithm Hash digest
SHA256 7865786fd31f40d8902c0a82acf4dc60546432fffe4156df3c9ca5b1100fa9c9
MD5 08a0e63f5daa138985ff9fa33c10c737
BLAKE2b-256 5c50f1f21e13851db153643f0bb7ffcf0d6565b1c8bd7c80e949d67cc42897af

See more details on using hashes here.

File details

Details for the file cryptomem-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: cryptomem-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 39.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for cryptomem-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 211aa11fde1c1e06316fcb014e02d06e94ae26796471ddf5bd17e315a56323ec
MD5 26f8af2c20338f86be7b9ea64eaadc1d
BLAKE2b-256 84923b3a7562abf62fcea0cbb130eeb5ad24d6aaa51c79c90e3b13bf920dac31

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page