Enterprise-grade persistent memory for OpenClaw agents with self-improvement capabilities.
This project is in active development. Core features are implemented but may have bugs or incomplete functionality.
What's Working:
- β Four-layer memory architecture (L1-L4)
- β Keyword search
- β Basic semantic search
- β Session Bridge
- β Self-improvement system
- β Auto Python installation
In Progress:
- π§ HNSW vector index optimization
- π§ ONNX embedding model integration
- π§ Complete test coverage
- π§ Performance benchmarking
Contributions Welcome! See CONTRIBUTING.md for areas needing help.
- L1 Capture: Real-time detection of 5-class learnings
- L2 Batch: Automatic archiving every 30 minutes
- L3 Detect: Threshold alerts and upgrade recommendations
- L4 Refine: Weekly pattern analysis and knowledge promotion
- Auto-Capture: Detects learn/decision/milestone/fix/error automatically
- Keyword Optimization: Self-improves capture keywords
- Threshold Adaptation: Self-adjusts based on usage patterns
- Weekly Evolution Report: Generates improvement recommendations
- Auto-Download: 20MB model downloaded on first use (~30 seconds)
- No API Keys: Fully local, no external dependencies
- Auto-Install Python: Automatically installs Python if missing
- Graceful Degradation: Works without Python (keyword search only)
- Hybrid Search: Keyword + semantic with intelligent fallback
- Session Bridge: Automatic cross-session memory recovery
- Three Memory Types: Episodic, Semantic, Procedural
# Via ClawHub (recommended)
clawhub install persistent-memory-pro
# Via GitHub
clawhub install github.com/openclaw/persistent-memory-pro# Initialize
memory setup
# Search memories
memory search "previous discussion about QMS"
# Index new content
memory index "Important knowledge..." --category=regulations
# Check stats
memory stats
# Health check
memory health| Tier | Requirements | PDF Support |
|---|---|---|
| Basic | Node.js v18+ | Metadata only |
| Standard | + Python 3.10+ | Text PDFs (PyPDF2) |
| Complete | + Tesseract + Poppler | All PDFs (OCR) |
Text PDFs (Scheme A):
pip install PyPDF2 pdfplumberAll PDFs (Scheme B - OCR):
# Windows (Conda)
conda install -c conda-forge poppler tesseract
pip install pytesseract pdf2image Pillow
# macOS
brew install poppler tesseract
pip install pytesseract pdf2image Pillow
# Linux
sudo apt install poppler-utils tesseract-ocr
pip install pytesseract pdf2image PillowAuto-detects best available scheme.
User Input
β
βΌ
βββββββββββββββββββ
β L1 Capture β β Real-time 5-class detection
ββββββββββ¬βββββββββ
β
βΌ
βββββββββββββββββββ
β L2 Batch β β Process every 30 min
ββββββββββ¬βββββββββ
β
βΌ
βββββββββββββββββββ βββββββββββββββββββ
β Daily Memory ββββββΆβ Vector DB β
ββββββββββ¬βββββββββ ββββββββββ¬βββββββββ
β β
βΌ βΌ
βββββββββββββββββββ βββββββββββββββββββ
β L3 Detect β β Query Engine β
ββββββββββ¬βββββββββ ββββββββββ¬βββββββββ
β β
βΌ βΌ
βββββββββββββββββββ βββββββββββββββββββ
β L4 Refine β β Search Results β
βββββββββββββββββββ βββββββββββββββββββ
{
"skills": {
"entries": {
"persistent-memory-pro": {
"enabled": true,
"config": {
"embedding": {
"provider": "auto"
},
"selfImprovement": {
"enabled": true,
"autoOptimize": true,
"weeklyReport": true
}
}
}
}
}
}| Command | Description |
|---|---|
memory search <query> |
Search memories |
memory index <content> |
Index new content |
memory stats |
Show statistics |
memory health |
Check system health |
memory setup |
Initialize system |
memory config |
Manage configuration |
| Operation | Latency | Throughput |
|---|---|---|
| Keyword Search | 0.24ms | 4,166 QPS |
| Semantic Search | 50ms | 20 QPS |
| Hybrid Search | 5-10ms | 1,000+ QPS |
| Concurrent (50) | 3.71ms | 12,500 QPS |
- β Fully Local: All data stored locally
- β No API Keys: Runs without external services by default
- β Optional Cloud: Can upgrade to OpenAI/Moonshot (requires key)
- β Session Bridge: Local recovery, no external transmission
The skill will automatically try to install Python. If it fails:
# Install manually
# Windows: https://python.org/downloads
# macOS: brew install python@3.11
# Linux: sudo apt install python3# Retry download
memory setup --retry
# Or use keyword-only mode
memory config set embedding.provider=noneContributions welcome! Please read CONTRIBUTING.md first.
MIT License - see LICENSE file.
Made with β€οΈ for the OpenClaw community