Memory bank write-ahead log (audit / rollback)
memory_walInspect and manage the WAL audit log of memory-bank writes, detect anomalies, and create or restore filesystem snapshots for rollback.
Instructions
Inspect or manage the memory-bank WAL (JSONL audit log and snapshots).
USE WHEN: You need an audit trail of memory-bank writes, anomaly hints, or
a filesystem snapshot/restore of .cortex/memory-bank/*.md (not a git
substitute).
DO NOT: Treat WAL as authoritative security auditing; it is best-effort and can be disabled by disk errors (writes still proceed).
EXAMPLES:
memory_wal(operation="read") — last 50 WAL entries
memory_wal(operation="anomalies") — heuristic warnings
memory_wal(operation="snapshot", label="backup-2026-04-15")
memory_wal(operation="restore", label="backup-2026-04-15")
Pre-compact automation: there is no bundled Claude PreCompact hook in
this repo; run memory_wal(operation="snapshot", label="pre-compact-…")
manually before risky compaction if you want a rollback point.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| label | No | ||
| since | No | ||
| operation | No | read |