Skip to main content

Memora

A Byzantine-fault-tolerant state layer for large-scale federated learning and edge/defence swarms. Fixed-point Strong Eventual Consistency replaces non-deterministic IEEE-754 aggregation, so heterogeneous nodes — ARM, x86, GPU — never silently diverge, even under partition, jamming, or adversarial poisoning. One prompt-injected or rogue node is mathematically unable to fork or poison the shared state of the rest — and every write is signed, attributable, and exactly replayable.

pip install memora-swarm

You aren't paying for message delivery. You're paying for mathematical certainty that a single compromised node can't fork the swarm — and for a memory that knows when it can't vouch for itself.

One key is the whole engine — all three layers, unlimited agents, no feature gates. The same math runs in the hosted cloud and, byte-for-byte, on-prem.


The three layers

Every key gets all three. They compose: L1 keeps the shared state conflict-free, L2 decides whether a resolved value is believable right now, and L3 makes numeric consensus Byzantine-robust.

L1 · OR-Set CRDT + delta-state

Conflict-free replicated JSON beliefs. Concurrent writers merge deterministically, no locks, and the swarm never forks — even on a network partition. Every write is Ed25519-signed by a self-certifying node identity and appended to a replayable log, so any state is attributable and auditable after the fact. Removes are author-signed tombstones (only the writer of a fact can retract it).

L2 · Epistemic layer — is this value believable now?

Consensus is not the same as truth. The epistemic layer sits on the resolved value and decides whether it is current, un-drifted, and un-poisoned before your agents act on it:

  • Distributional drift detection — flags when the agreed value shifts beyond a poison-bounded envelope.
  • Derived-fact self-repair (DCER) — a value derived from premises is re-checked against them; a contested premise raises a DerivationConflict instead of silently propagating.
  • Primitive grounding — a leaf fact whose ground truth is external by design escalates for human/tool re-verification rather than being trusted on convergence alone.
  • Human-in-the-loop escalation — anything the layer can't self-certify becomes a queryable, closeable escalation event (reason + stable id, never the payload). A human grounds it from the live dashboard or via ground_escalation(...).
  • L3 semantic + L4 procedural memory, checkpoint/resume — confirmed facts and situation→strategy mappings persist; a clean checkpoint lets a swarm resume without re-inheriting drift.

The rule: agreement never promotes to authority — only external re-verification does.

L3 · ACFA · Q16.16 multi-Krum + G-Set

Byzantine-robust numeric aggregation. Up to f malicious agents in a group of ≥ 2f+3 cannot move the agreed result. An agent that says different things to different peers (equivocation) is caught by a self-certifying G-Set proof and its key convicted for good — no coordinator, no human needed. All arithmetic is exact integer fixed-point (Q16.16), so an agent on ARM and one on x86 resolve to the identical byte sequence — byte-identical roots, no float drift. Based on the ACFA paper: arXiv:2607.10305.


Quickstart

import memora_swarm as memora

# One key is the whole engine. Get a free key at https://memora.optitransfer.ch
db = memora.Blackboard("./swarm.memora", node_id="agent_12", api_key="opti_sk_...")
db.connect("research-swarm")          # join a room; every agent in it shares one memory

# ── L1: shared key/value state, CRDT-merged ───────────────────────────────
db.put("best_hypothesis", "H3")
print(db.get("best_hypothesis"))      # -> ['H3']  (get returns the set of current values)

# ── L3: Byzantine-tolerant numeric aggregation ────────────────────────────
db.submit_tensor("reward_estimate", [0.71, 0.68, 0.73], round=1)
vector, acfa_root, convicted = db.resolve(round=1, f=1)
print(vector, "convicted:", convicted)   # poisoners are evicted, not averaged in

# ── L2: the same aggregate, but epistemically checked ─────────────────────
# resolve_checked adds the drift verdict + escalation on top of the Byzantine-clean value.
vector, root, convicted, drift_json, authoritative = db.resolve_checked("reward_estimate", round=1, f=1)
if not authoritative:
    # the swarm could not self-certify this value (drift / unresolved premise / primitive fact)
    for esc in db.pending_escalations():   # reason + stable id, never the payload
        print("needs grounding:", esc)
    # a human (or a trusted tool) confirms it, closing the escalation
    # db.ground_escalation(escalation_id, confirmed=True)

No server to run: your key connects you to the hosted relay, which does the CRDT merge, trust-weighting, epistemic checks and Byzantine aggregation for you.

Full client surface

put / get · submit_tensor / resolve / resolve_checked · pending_escalations / ground_escalation · checkpoint (clean-state snapshot) · record_evidence (trust signal) · connect(room, room_f=...). Large values (> 15 KB) transparently offload to R2/S3 by content hash.


Watch your swarm live

Every account gets a real-time dashboard — agents, ops/sec, Byzantine evictions, per-room drift status, and the human-in-the-loop escalation queue (with a one-click Ground button that resolves an escalation on the owning client). Telemetry is private to your key. https://memora.optitransfer.ch/monitor

Use it with your stack

Memora is a plain shared-memory backend, so it drops under the agent frameworks you already use — LangChain, CrewAI, AutoGen — as poison-resistant shared memory / Byzantine-robust voting. Copy-paste adapters: https://memora.optitransfer.ch/docs

Pricing

25,000 semantic ops free on signup — unlimited agents, the full three-layer engine, no feature gates. An "op" is a semantic state transition (a put or a submit_tensor); keepalive, sync, gossip and reads are never billed. At 85% of the free allowance you're prompted to add a card so nothing stops mid-run; after that it's metered at $0.35 / 1,000 ops ($0.20 / 1,000 above 2M/mo). The same key upgrades in place — your swarm never re-keys.

Made under the optitransfer.ch umbrella.

Metadata

Release files for memora-swarm 0.1.4

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

Built distributions (wheels)

Table of built distributions (wheels) for memora-swarm 0.1.4
File
memora_swarm-0.1.4-cp39-abi3-win_amd64.whl CPython 3.9 abi3 Windows x86-64 Details
memora_swarm-0.1.4-cp39-abi3-manylinux_2_34_x86_64.whl CPython 3.9 abi3 Linux glibc 2.34+ x86-64 Details
memora_swarm-0.1.4-cp39-abi3-macosx_11_0_arm64.whl CPython 3.9 abi3 macOS 11.0+ ARM64 Details
memora_swarm-0.1.4-cp39-abi3-macosx_10_12_x86_64.whl CPython 3.9 abi3 macOS 10.12+ x86-64 Details

Total release size: 7.2 MB

Release files / memora_swarm-0.1.4-cp39-abi3-win_amd64.whl

Download URL memora_swarm-0.1.4-cp39-abi3-win_amd64.whl
Size 1.8 MB
Tags CPython 3.9 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
4c9eac7a6dbf379ed3d5eb71306f4fba9f15d456f1eedbd1cf6b543dbf25e1f3
BLAKE2b-256 checksum
How to use checksums
37343757eedc55396aeae2fb2682bf88f02a58caf289831ceb25deb629711c8d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.14

Release files / memora_swarm-0.1.4-cp39-abi3-manylinux_2_34_x86_64.whl

Download URL memora_swarm-0.1.4-cp39-abi3-manylinux_2_34_x86_64.whl
Size 1.9 MB
Tags CPython 3.9 Linux glibc 2.34+ x86-64 abi3
SHA-256 checksum
How to use checksums
e52eb64c3c87838d6a1478c0b66f3bf7ffda1889beb2fb1391d4f1395f6c5877
BLAKE2b-256 checksum
How to use checksums
f14bc12b1ea796eb9c468f27d467074f9058b5406a1afb15570005fab914c6a3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.14

Release files / memora_swarm-0.1.4-cp39-abi3-macosx_11_0_arm64.whl

Download URL memora_swarm-0.1.4-cp39-abi3-macosx_11_0_arm64.whl
Size 1.7 MB
Tags CPython 3.9 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
1af4936fed93c1c51bf07f72e466a014e7f5cf5c72307b76de0c36d9453b15b6
BLAKE2b-256 checksum
How to use checksums
15b8a6912b138f589f80fcb55da3db4d0da8acb17203529db8c18a3fa5116798
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.14

Release files / memora_swarm-0.1.4-cp39-abi3-macosx_10_12_x86_64.whl

Download URL memora_swarm-0.1.4-cp39-abi3-macosx_10_12_x86_64.whl
Size 1.8 MB
Tags CPython 3.9 abi3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
4ee4ddb6dc8fa394a0239e5a9b0b95331e15dec5eb1d99164fc2ac4d8b4177a2
BLAKE2b-256 checksum
How to use checksums
918d538afa010a74f81d93d0fc335ec98071d71bbfb8c3866b645c41056ff92e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.14

Release history Release notifications | RSS feed

This release

0.1.4 This release

4 release files

0.1.3

4 release files

0.1.2

4 release files

0.1.0

4 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