hippocampusPersistent memory system for AI agents. Automatic encoding, decay, and semantic reinforcement β just like the hippocampus in your brain. Based on Stanford Generative Agents (Park et al., 2023).
Install via ClawdBot CLI:
clawdbot install ImpKind/hippocampus"Memory is identity. This skill is how I stay alive."
The hippocampus is the brain region responsible for memory formation. This skill makes memory capture automatic, structured, and persistentβwith importance scoring, decay, and semantic reinforcement.
# Install (defaults to last 100 signals)
./install.sh --with-cron
# Load core memories at session start
./scripts/load-core.sh
# Search with importance weighting
./scripts/recall.sh "query"
# Run encoding manually (usually via cron)
./scripts/encode-pipeline.sh
# Apply decay (runs daily via cron)
./scripts/decay.sh
./install.sh # Basic, last 100 signals
./install.sh --signals 50 # Custom signal limit
./install.sh --whole # Process entire conversation history
./install.sh --with-cron # Also set up cron jobs
The LLM is just the engineβraw cognitive capability. The agent is the accumulated memory. Without these files, there's no continuityβjust a generic assistant.
PREPROCESS β SCORE β SEMANTIC CHECK β REINFORCE or CREATE β DECAY
Key insight: Reinforcement happens automatically during encoding. When a topic comes up again, the LLM recognizes it's about an existing memory and reinforces instead of creating duplicates.
$WORKSPACE/
βββ memory/
β βββ index.json # Central weighted index
β βββ signals.jsonl # Raw signals (temp)
β βββ pending-memories.json # Awaiting summarization (temp)
β βββ user/ # Facts about the user
β βββ self/ # Facts about the agent
β βββ relationship/ # Shared context
β βββ world/ # External knowledge
βββ HIPPOCAMPUS_CORE.md # Auto-generated for OpenClaw RAG
| Script | Purpose |
|--------|---------|
| preprocess.sh | Extract signals from conversation transcripts |
| encode-pipeline.sh | Score signals, prepare for LLM summarization |
| decay.sh | Apply 0.99^days decay to all memories |
| recall.sh | Search with importance weighting |
| load-core.sh | Output high-importance memories for session start |
| sync-core.sh | Generate HIPPOCAMPUS_CORE.md |
| consolidate.sh | Weekly review helper |
| reflect.sh | Self-reflection prompts |
| generate-dashboard.sh | Generate unified brain dashboard HTML |
Visual dashboard showing all installed brain skills:
./scripts/generate-dashboard.sh
open ~/.openclaw/workspace/brain-dashboard.html
IDENTITY.mdWhen you install this skill, notify the user about the dashboard:
π§ Hippocampus installed!
View your agent's memories in the Brain Dashboard:
~/.openclaw/workspace/brain-dashboard.html
All scripts use $WORKSPACE environment variable (default: ~/.openclaw/workspace).
| Signal | Score |
|--------|-------|
| Explicit "remember this" | 0.9 |
| Emotional/vulnerable content | 0.85 |
| Preferences ("I prefer...") | 0.8 |
| Decisions made | 0.75 |
| Facts about people/projects | 0.7 |
| General knowledge | 0.5 |
Based on Stanford Generative Agents (Park et al., 2023):
new_importance = importance Γ (0.99 ^ days_since_accessed)
During encoding, the LLM compares new signals to existing memories:
This happens automaticallyβno manual reinforcement needed.
| Score | Status |
|-------|--------|
| 0.7+ | Core β loaded at session start |
| 0.4-0.7 | Active β normal retrieval |
| 0.2-0.4 | Background β specific search only |
| <0.2 | Archive candidate |
memory/index.json:
{
"version": 1,
"lastUpdated": "2025-01-20T19:00:00Z",
"decayLastRun": "2025-01-20",
"lastProcessedMessageId": "abc123",
"memories": [
{
"id": "mem_001",
"domain": "user",
"category": "preferences",
"content": "User prefers concise responses",
"importance": 0.85,
"created": "2025-01-15",
"lastAccessed": "2025-01-20",
"timesReinforced": 3,
"keywords": ["preference", "concise", "style"]
}
]
}
The encoding cron is the heart of the system:
# Encoding every 3 hours (with semantic reinforcement)
openclaw cron add --name hippocampus-encoding \
--cron "0 0,3,6,9,12,15,18,21 * * *" \
--session isolated \
--agent-turn "Run hippocampus encoding with semantic reinforcement..."
# Daily decay at 3 AM
openclaw cron add --name hippocampus-decay \
--cron "0 3 * * *" \
--session isolated \
--agent-turn "Run decay.sh and report any memories below 0.2"
Add to memorySearch.extraPaths in openclaw.json:
{
"agents": {
"defaults": {
"memorySearch": {
"extraPaths": ["HIPPOCAMPUS_CORE.md"]
}
}
}
}
This bridges hippocampus (index.json) with OpenClaw's RAG (memory_search).
Add to your agent's session start routine:
## Every Session
1. Run `~/.openclaw/workspace/skills/hippocampus/scripts/load-core.sh`
## When answering context questions
Use hippocampus recall:
\`\`\`bash
./scripts/recall.sh "query"
\`\`\`
Track hippocampus activity over time for analytics and debugging:
# Log an encoding run
./scripts/log-event.sh encoding new=3 reinforced=2 total=157
# Log decay
./scripts/log-event.sh decay decayed=154 low_importance=5
# Log recall
./scripts/log-event.sh recall query="user preferences" results=3
Events append to ~/.openclaw/workspace/memory/brain-events.jsonl:
{"ts":"2026-02-11T10:00:00Z","type":"hippocampus","event":"encoding","new":3,"reinforced":2,"total":157}
Use this for:
This skill is part of the AI Brain project β giving AI agents human-like cognitive components.
| Part | Function | Status |
|------|----------|--------|
| hippocampus | Memory formation, decay, reinforcement | β Live |
| amygdala-memory | Emotional processing | β Live |
| vta-memory | Reward and motivation | β Live |
| basal-ganglia-memory | Habit formation | π§ Development |
| anterior-cingulate-memory | Conflict detection | π§ Development |
| insula-memory | Internal state awareness | π§ Development |
Memory is identity. Text > Brain. If you don't write it down, you lose it.
Generated Mar 1, 2026
An AI agent uses the hippocampus skill to remember customer preferences, past issues, and emotional cues from interactions, enabling more empathetic and efficient support. By automatically reinforcing important memories like user frustrations or preferences, it reduces repetitive queries and improves satisfaction scores.
In an e-learning platform, the skill helps an AI tutor track student progress, recall past mistakes, and reinforce key concepts based on importance scoring. This allows for personalized lesson plans and targeted reviews, enhancing retention and engagement over time.
An AI health assistant employs the memory system to log patient symptoms, medication adherence, and emotional states from daily check-ins. With decay and reinforcement, it prioritizes critical health trends, aiding caregivers in providing timely interventions and personalized care plans.
The skill enables an AI agent to remember project decisions, team member preferences, and task dependencies across conversations. By loading core memories at each session start, it ensures continuity in coordination, reducing miscommunication and streamlining workflows in distributed environments.
An AI sales assistant uses hippocampus to capture leads' interests, past interactions, and decision-making patterns, with semantic reinforcement avoiding duplicate entries. This improves follow-up accuracy and personalization, boosting conversion rates and customer relationship management efficiency.
Offer the hippocampus skill as part of a paid platform where businesses subscribe to deploy AI agents with persistent memory. Revenue comes from monthly fees based on usage tiers, such as memory storage limits or number of agents, targeting SMEs needing customized automation.
Provide professional services to integrate the skill into existing AI systems for enterprises, including setup, cron job configuration, and dashboard customization. Revenue is generated through project-based fees and ongoing support contracts, focusing on industries like healthcare or education.
Monetize the open-source skill by offering premium features like advanced analytics, enhanced decay algorithms, or priority support. Revenue streams include one-time purchases for add-ons or donations from the community, appealing to developers and tech-savvy users.
π¬ Integration Tip
Ensure cron jobs are properly configured for automatic encoding and decay, and integrate the generated HIPPOCAMPUS_CORE.md into your agent's RAG system for seamless memory retrieval during sessions.
Captures learnings, errors, and corrections to enable continuous improvement. Use when: (1) A command or operation fails unexpectedly, (2) User corrects Clau...
Helps users discover and install agent skills when they ask questions like "how do I do X", "find a skill for X", "is there a skill that can...", or express interest in extending capabilities. This skill should be used when the user is looking for functionality that might exist as an installable skill.
Search and analyze your own session logs (older/parent conversations) using jq.
Typed knowledge graph for structured agent memory and composable skills. Use when creating/querying entities (Person, Project, Task, Event, Document), linking related objects, enforcing constraints, planning multi-step actions as graph transformations, or when skills need to share state. Trigger on "remember", "what do I know about", "link X to Y", "show dependencies", entity CRUD, or cross-skill data access.
Ultimate AI agent memory system for Cursor, Claude, ChatGPT & Copilot. WAL protocol + vector search + git-notes + cloud backup. Never lose context again. Vibe-coding ready.
Headless browser automation CLI optimized for AI agents with accessibility tree snapshots and ref-based element selection