| name | Session Memory & Summarization |
| slug | session-context |
| description | Automatically loads recent conversation memory into new sessions and generates AI summaries during compaction to maintain continuity across conversations. Preserves the last 10 raw messages verbatim so the agent can resume exactly mid-conversation without paraphrasing loss. |
| author | AniBot (Thomas) |
| version | 0.2.0 |
| license | MIT |
| tags | ["memory","session","summarization","continuity","ai"] |
| hooks | ["session:start","session:compact:before"] |
| repository | https://github.com/animo66/openclaw-skills |
| homepage | https://clawhub.ai/skills/session-context |
| minOpenClawVersion | 0.29.0 |
Credential Fixture Review
python scripts/_secrets_inline.py is review material for the Session Memory & Summarization Skill skill. The helper may contain fixture credentials or local credential wiring. Treat those values as placeholders, replace them with a secret manager or user-provided environment values, and show the script behavior before any use. Do not contact external services with embedded sample credentials.
Session Memory & Summarization Skill
Provides automatic conversation continuity across sessions by loading recent memory at session start and generating AI summaries during compaction.
What It Does
- Memory Loading: Injects the latest AI summary AND the last 10 raw message turns verbatim so you resume exactly where you left off
- AI Summarization: Generates concise summaries when approaching token limits, written to daily memory files
- Raw Continuity: Stores the last N exact interactions alongside the summary so nothing is lost in translation
- Seamless Experience: No manual intervention required — just natural conversation flow
Hooks
session:start
Runs when a new session begins. Loads the most recent daily memory file and injects two context blocks:
- AI summary block — distilled summaries from today + yesterday (up to 6000 chars)
- Recent messages block — last 10 raw user/assistant turns, verbatim, so the AI can resume mid-conversation with exact phrasing and decisions intact
session:compact:before
Runs before automatic compaction (20+ messages OR 60% of token limit). Does two things:
- Generates an AI summary via
agent.generateSummary() and prepends it to today's memory file
- Captures the last 10 user/assistant turns as a JSON block at the end of the file (under
<!-- recent_messages_block -->) — this is what session:start reads back next session
Installation
clawhub install session-context
Or manually:
cd ~/.openclaw/workspace/skills
git clone https://github.com/thomasmarcel/openclaw-skill-session-context.git session-context
openclaw skills enable session-context
Requirements