Local persistent memory for OpenClaw agents. Captures conversations, extracts structured facts via LLM, and auto-recalls relevant knowledge before each turn. Privacy-first, all stored data stays local in SQLite.
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
A direct command skips the review prompt. Inspect the source before running it.
Local persistent memory for OpenClaw agents. Captures conversations, extracts structured facts via LLM, and auto-recalls relevant knowledge before each turn. Privacy-first, all stored data stays local in SQLite.
Memento — Local Persistent Memory for OpenClaw Agents
Memento gives your agents long-term memory. It captures conversations, extracts structured facts using an LLM, and auto-injects relevant knowledge before each AI turn.
All stored data stays on your machine — no cloud sync, no subscriptions. Extraction uses your configured LLM provider; use a local model (Ollama) for fully air-gapped operation.
⚠️ Privacy note: When autoExtract is enabled, conversation segments are sent to your configured LLM provider for fact extraction. If you use a cloud provider (Anthropic, OpenAI, Mistral), that text leaves your machine. For fully local operation, set extractionModel to ollama/<model> and keep Ollama running locally.
What It Does
Captures every conversation turn, buffered per session
structured facts (preferences, decisions, people, action items) via configurable LLM (opt-in — see Privacy section)
Extracts
Recalls relevant facts before each AI turn using FTS5 keyword search + optional semantic embeddings (BGE-M3)
Respects privacy — facts are classified as shared, private, or secret based on content, with hard overrides for sensitive categories (medical, financial, credentials)
Cross-agent knowledge — shared facts flow between agents with provenance tags; private/secret facts never cross boundaries
Quick Start
Install the plugin, restart your gateway, and Memento starts capturing automatically. Extraction is off by default — enable it explicitly when ready.
Optional: Semantic Search
Download a local embedding model for richer recall:
autoExtract: true is an explicit opt-in (default: false). When enabled, conversation segments are sent to the configured extractionModel for LLM-based fact extraction. Omit or set to false to keep everything local.
Data Storage
Memento stores all data locally:
Path
Contents
~/.engram/conversations.sqlite
Main database: conversations, facts, embeddings
~/.engram/segments/*.jsonl
Human-readable conversation backups
~/.engram/migration-config.json
Optional: migration workspace paths (only for bootstrapping)
The ~/.engram directory name is a legacy from when the project was called Engram. It will not change to avoid breaking existing installations.
Privacy & Data Flow
Feature
Data leaves machine?
Details
autoCapture (default: true)
❌ No
Writes to local SQLite + JSONL only
autoExtract (default: false)
⚠️ Yes, if cloud LLM
Sends conversation text to configured provider. Use ollama/* for local.
autoRecall (default: true)
❌ No
Reads from local SQLite only
Secret facts
❌ Never
Filtered from extraction context — never sent to any LLM
Migration
❌ No
Reads local workspace files, writes to local SQLite
Migration (Bootstrap from Existing Memory Files)
To bootstrap Memento from existing agent memory files:
Create ~/.engram/migration-config.json or set MEMENTO_WORKSPACE_MAIN: