← Back to Skills Marketplace
mitchelldavis44

Memory Dream

by Mitch Davis · GitHub ↗ · v1.1.0 · MIT-0
cross-platform ✓ Security Clean
218
Downloads
1
Stars
1
Active Installs
6
Versions
Install in OpenClaw
/install openclaw-memory-dream
Description
Auto-consolidates agent memory files after sessions — like REM sleep for AI agents. Prevents MEMORY.md from growing unbounded by using an LLM to prune stale...
README (SKILL.md)

memory-dream

Auto-consolidates agent memory files after sessions — like REM sleep for AI agents.

What it does

As an AI agent accumulates sessions, its memory files can get cluttered: vague date references ("yesterday", "last week"), stale context that no longer applies, and contradictions where newer information superseded older entries but both remain.

memory-dream runs automatically in the background once enough sessions have passed and enough time has elapsed. It uses the configured LLM to quietly clean up memory files, resolving contradictions, replacing vague date references with actual dates, removing stale entries, and preserving everything that still matters.

Without it: MEMORY.md grows unbounded until it gets truncated on load.
With it: memory stays tight, relevant, and useful automatically.

Works standalone — no other plugins required. Optionally uses lossless-claw session summaries for richer consolidation context if that plugin is also installed.

Installation

openclaw plugins install @mitchelldavis44/openclaw-memory-dream

Configuration (openclaw.json)

{
  "plugins": {
    "entries": {
      "memory-dream": {
        "enabled": true,
        "config": {
          "minSessions": 5,
          "minHours": 24,
          "memoryFiles": ["MEMORY.md"],
          "model": "claude-haiku-4-5"
        }
      }
    }
  }
}
Option Default Description
minSessions 5 Session boundaries since last consolidation before triggering
minHours 24 Hours since last consolidation before triggering
memoryFiles ["MEMORY.md"] Memory files to consolidate (relative to workspace root)
model (agent default) LLM used for consolidation (cheap model recommended)

Both conditions must be met before consolidation triggers.

Session detection in persistent channels: In DM-style channels where there's no discrete session lifecycle (e.g. Slack DMs), the plugin detects session boundaries via inactivity gaps — a gap of 30+ minutes between messages counts as a new session.

Status tool

memory_dream_status

Returns session count, last run time, next trigger estimate, and whether consolidation is currently running.

Usage Guidance
This plugin appears to do what it says: it uses your configured LLM to rewrite and tighten memory files, and it relies on session transcripts and optional lossless-claw summaries to decide what to keep. Before enabling: (1) back up MEMORY.md (or whatever files you configure) so you can review/revert automated edits; (2) review whether you are comfortable with a plugin reading recent .jsonl transcripts from ~/.openclaw/<agentId> and writing state under ~/.openclaw/memory-dream/<agentId>; (3) set conservative triggers (higher minSessions/minHours) if you want fewer automated runs; (4) choose an appropriate (and cost-appropriate) model in config; and (5) if you want to avoid any automatic writes, keep the plugin disabled and run consolidation manually. Overall the components are coherent and proportionate to the described purpose.
Capability Analysis
Type: OpenClaw Skill Name: openclaw-memory-dream Version: 1.1.0 The memory-dream plugin is a utility designed to manage and consolidate AI agent memory files (e.g., MEMORY.md) to prevent context bloat. It functions by monitoring session activity, capturing user preferences/corrections from transcripts (src/transcript.ts), and using a subagent LLM to rewrite memory files with updated, consolidated content (src/consolidate.ts). While the plugin requires access to sensitive conversation transcripts and has the authority to overwrite workspace files, its operations are transparently documented, use standard OpenClaw APIs, and lack any indicators of data exfiltration, unauthorized persistence, or malicious intent.
Capability Assessment
Purpose & Capability
Name/description (auto-consolidate MEMORY.md using an LLM) align with what the code does: detecting session boundaries, reading memory files, optional lossless-claw summaries, recent transcripts, and calling a subagent LLM to rewrite and write back memory files. No unrelated credentials, binaries, or external downloads are requested.
Instruction Scope
SKILL.md and code are consistent but the runtime instructions and implementation access several places beyond the workspace file(s): it reads recent transcript (.jsonl) files from ~/.openclaw/<agentId>, optional lossless-claw summaries in the state directory, and writes a staging file (memory-staging.md) and modifies the configured memory files in the workspace. This behavior is coherent for consolidation but is broader than 'only MEMORY.md' (it draws on session transcripts and stores state under the user's home directory).
Install Mechanism
No install script or remote download is present; the package is plain TypeScript/JS source. There are no external URLs or extraction steps. The code will run as a plugin via the OpenClaw plugin system (normal for this ecosystem).
Credentials
The skill requests no environment variables, no credentials, and no config paths beyond per-agent state in the user's home directory and the agent workspace. Those accesses are justified by the feature (storing plugin state and reading transcripts/context).
Persistence & Privilege
The plugin is capable of autonomous invocation (default platform behavior) and will run background consolidations once trigger conditions are met; it stores state under ~/.openclaw/memory-dream/<agentId> and creates/clears a workspace staging file. It does not use always:true, nor does it modify other plugins' configs, but users should be aware it will autonomously modify workspace files when triggered.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install openclaw-memory-dream
  3. After installation, invoke the skill by name or use /openclaw-memory-dream
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.1.0
Add auto-capture phase: replicates Claude Code auto memory. Haiku scans each turn for corrections/preferences/decisions and stages them in real time. Consolidation now also mines session JSONL transcripts. Added enableCapture, captureModel, intervalHours config fields.
v1.0.4
Docs: lossless-claw is optional — works standalone without it
v1.0.3
Fix: LCM summaries now read from correct agent state dir instead of workspace root
v1.0.2
Session-gap detection for persistent DM channels, corrected config schema, README fixes
v1.0.1
Security fixes: dynamic session key scoped to agentId (no more hard-coded 'main'), transparent logging of file changes before write, agentId passed through full call chain.
v1.0.0
Initial release: auto-consolidates MEMORY.md and daily logs after sessions — like REM sleep for AI agents.
Metadata
Slug openclaw-memory-dream
Version 1.1.0
License MIT-0
All-time Installs 1
Active Installs 1
Total Versions 6
Frequently Asked Questions

What is Memory Dream?

Auto-consolidates agent memory files after sessions — like REM sleep for AI agents. Prevents MEMORY.md from growing unbounded by using an LLM to prune stale... It is an AI Agent Skill for Claude Code / OpenClaw, with 218 downloads so far.

How do I install Memory Dream?

Run "/install openclaw-memory-dream" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Memory Dream free?

Yes, Memory Dream is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Memory Dream support?

Memory Dream is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Memory Dream?

It is built and maintained by Mitch Davis (@mitchelldavis44); the current version is v1.1.0.

💬 Comments