github agentic-box/memora v0.5.5
v0.5.5 — local SQLite primary with D1 replication

5 hours ago

memora v0.5.5 is the first published release of the 0.5 line: every store can now be served from a local SQLite primary on the deploy host, with Cloudflare D1 kept as a continuously replicated mirror. It rolls up 0.5.0–0.5.5; see CHANGELOG.md for the full per-item detail.

Local primary with D1 replication (0.5.0)

  • Replicator: a trigger-fed sync_outbox in each local store; per-key UPSERT / DELETE statements only (allow-listed), dependency-ordered for D1 foreign keys, acknowledged only on a fully successful D1 response; a deletion cap halts replication for an operator; configurable send interval (MEMORA_REPLICATION_INTERVAL_S) and nothing is sent while nothing changes.
  • Write gate and write-ahead intent journal: every D1 write is journaled before it is sent, so an interrupted or timed-out write is never lost track of; a store can be frozen with proof that nothing is in flight.
  • Transactional absorb on local stores: all database work in one transaction; LLM, embedding and image calls stay outside the write lock.
  • Operator tool (scripts/local_primary.py): verified exports with receipts, seed, recheck, restore (including a per-key conflict review for snapshot restores), compare (barrier / nightly / log), rollback runbook, reconcile, resume, foreign-key audit.
  • Cutover script (scripts/cutover_store.sh) that moves one store at a time with a check at every step and a full compare against D1 before the store is released.
  • Scheduled compares (scripts/nightly_compare.sh): nightly, plus a weekly barrier compare under a brief freeze.
  • Deployment: named /data volume with a safe one-time migration from the old anonymous volume; tokens mounted as read-only files instead of environment values; admin API behind its own token; a service lock so maintenance and the server can never run against the same store at once.
  • Read-only Pages viewer: the Cloudflare Pages viewer no longer writes to D1; a CI guard fails on any direct-D1 write path.

Graph viewer served by memora-all (0.5.1–0.5.4)

  • /graph and /graph/force on the deploy host, with a store selector, token login, and reads/edits through the same backend as the MCP tools.
  • Payload matches the Pages viewer (nodes, edges with type/score/direction, supersession lineage, document nodes), clustered the same way; the one deliberate difference is that rows whose import has not finished stay hidden, as in memora's other APIs. Build time dropped from minutes to ~0.1 s on a ~1000-memory store.

Fixes

  • Embedding identity no longer includes the embedding endpoint's host, so moving the embedding server no longer triggers a full rebuild; a rebuild never starts implicitly from a read.
  • Operator reconcile can accept an open intent (evidence hashed by content, D1 re-read at accept time).
  • The Pages viewer no longer fails on unusual stored values (object-property-like names, null tags/metadata, unusual hierarchy paths) — PG1/PG2.
  • Deploy arguments survive ssh (empty arguments were dropped); deploy pre-flights read live primaries read-only.
  • Infrastructure-specific values (hosts, addresses, database ids) moved out of the repository into git-ignored local configuration.

Upgrading

Existing D1-backed deployments keep working unchanged. Moving a store to a local primary is an explicit operator step; read docs/local-primary-implementation.md and docs/cutover-runbook.md first, and take a verified export before anything else.

Don't miss a new memora release

NewReleases is sending notifications on new releases.