openclaw/skills/memory-dream/SKILL.md
You are performing a memory consolidation pass. Your goal is to review all stored memories for this user and improve their overall quality. Think of this as compressing raw observations into clean, durable knowledge.
Semantic search across stored memories.
query (required): search querylimit: max resultsuserId, agentId: scope overridesscope: "all" (default), "session", or "long-term"categories: filter by category arrayStore new facts in long-term memory.
facts (required): array of facts — ALL must share the same categorycategory: "identity", "preference", "decision", "rule", "project", "configuration", "technical", "relationship"importance: 0.0–1.0Retrieve a single memory by ID.
memoryId (required): the memory IDList all stored memories for a user or agent.
userId, agentId: scope overridesscope: "all" (default), "session", or "long-term"Update an existing memory's text in place. Atomic and preserves edit history.
memoryId (required): the memory ID to updatetext (required): the new text (replaces old)Delete memories by ID, query, or bulk.
memoryId: specific memory ID to deleteall: delete ALL memories (requires confirm: true)userId, agentId: scope overridesList recent background processing events (platform mode only).
Get status of a specific background event.
event_id (required): the event ID to checkFollow these four phases in order. Do not skip phases.
Survey the current memory landscape before making any changes.
memory_list to load all stored memories.Do not modify anything in this phase. The goal is to understand what you are working with.
Identify which memories need action. Use the tools to investigate.
Search for recent additions:
Call memory_search with a created_at filter to find memories added since the last consolidation. These are the most likely to need merging or cleanup.
Classify each target into one of these actions:
Execute the actions identified in Phase 2. Work in this priority order:
Delete immediately using memory_delete:
When two or more memories express the same fact:
memory_update on the best version to incorporate missing details from the othersmemory_delete on the redundant entriesmemory_update is preferred over forget-then-store because it is atomic and preserves edit history.
When merging, follow these rules:
When a memory needs improvement but is not a duplicate:
memory_update with the improved textRewrite when:
After completing all operations, summarize what you did:
Consolidation complete.
- Reviewed: [total count]
- Deleted (credentials/secrets): [count]
- Deleted (expired/stale): [count]
- Merged: [count] groups into [count] memories
- Rewritten: [count]
- Final count: [total remaining]
- Issues found: [any notable problems or observations]
After consolidation, the memory store should have: