| name | memory-sync |
|---|---|
| description | Sync context and memory across all OpenClaw channels (Discord, Telegram, webchat, etc.) so nothing gets lost between sessions. Activates on "sync my memory", "what did I say on [channel]", "pull in context from other sessions", or when the agent detects a channel switch and needs cross-channel context. |
Bridge the gap between siloed channel sessions in OpenClaw.
When triggered by the sync cron, follow these steps:
Use sessions_list with messageLimit: 5 to get all active sessions.
Filter to sessions updated in the last 4 hours.
Skip cron/isolated sessions β only scan user-facing sessions.
For each active session, use sessions_history (limit: 20) to read recent messages.
Pull out:
- Decisions β "I decided to go with X" / "Let's use Y"
- Tasks & action items β "Remind me to..." / "I need to..."
- Preferences β "I prefer X" / "Always do Y"
- Personal info β Names, dates, plans, events
- Project context β What they're working on, blockers, progress
Skip: greetings, filler, routine tool calls, credentials/secrets.
Read today's memory/YYYY-MM-DD.md. Compare against extracted items. Only write genuinely new information.
Append to memory/YYYY-MM-DD.md:
## Session Sync β HH:MM
- [channel] extracted item 1
- [channel] extracted item 2For significant long-term info (preferences, personal details, recurring patterns), also update MEMORY.md.
When user says "sync my memory" or asks about context from another channel:
- Run the full workflow above
- Report what was found and synced
- Mention which channels had new context
Add these to your AGENTS.md for real-time capture:
When the user tells you anything meaningful β a preference, decision, task, request, personal info, opinion, or new context β write it to memory RIGHT NOW in the same turn. Do NOT rely on session context. Sessions are siloed per channel. If you don't write it down, other sessions will never know.
When you detect the user is coming from a different channel than last time (or mentions something you don't have context for), proactively check:
memory/YYYY-MM-DD.md(today + yesterday)- Recent session histories via
sessions_list+sessions_history
This catches context that may have come from another channel.