High Risk:This skill has significant security concerns. Review the findings below before installing.

smart-memory

Caution·Scanned 2/17/2026

High-risk skill: provides local context-aware memory via smart_memory.js and memory_search for OpenClaw. It installs and runs remote code (curl ... | bash, git clone), uses programmatic shell execution (execSync), and requires network access to https://github.com/BluePointDigital/smart-memory and external model downloads.

from clawhub.ai·vaa66418·121.2 KB·0 installs
Scanned from 2.1.2 at aa66418 · Transparency log ↗
$ vett add clawhub.ai/bluepointdigital/smart-memoryReview security findings before installing

Smart Memory for OpenClaw

Context-aware memory system with dual retrieval modes — fast vector search when you need speed, curated Focus Agent when you need depth.

# Install and it just works
npx clawhub install smart-memory

# Optional: sync for better quality
node smart-memory/smart_memory.js --sync

✨ The Magic

Same function call. Two modes. You choose.

// Fast mode (default): Direct vector search
memory_search("User principles values")

// Focus mode: Multi-pass curation for complex decisions
memory_mode('focus')
memory_search("What did we decide about the architecture?")
ModeBest ForHow It Works
FastQuick lookups, factsDirect vector similarity (~10ms)
FocusDecisions, synthesisRetrieve → Rank → Synthesize (~100ms)

🚀 Quick Start

From ClawHub (Recommended)

npx clawhub install smart-memory

Done. memory_search now works with automatic mode selection.

From GitHub

curl -sL https://raw.githubusercontent.com/BluePointDigital/smart-memory/main/install.sh | bash

Manual

git clone https://github.com/BluePointDigital/smart-memory.git
cd smart-memory/smart-memory && npm install

🎯 How It Works

Dual Retrieval Modes

User searches
      │
      ▼
┌─────────────┐
│  Fast Mode? │
└──────┬──────┘
   Yes │    │ No (Focus Mode)
      ▼     ▼
┌────────┐ ┌─────────────┐
│ Vector │ │ Retrieve 20+│
│ Search │ │ chunks      │
└────┬───┘ └──────┬──────┘
     │            ▼
     │     ┌─────────────┐
     │     │ Rank &      │
     │     │ Synthesize  │
     │     └──────┬──────┘
     │            ▼
     │     ┌─────────────┐
     │     │ Curated     │
     │     │ Narrative   │
     └─────┴──────┬──────┘
                  ▼
           ┌────────────┐
           │  Results   │
           └────────────┘

Zero Config Philosophy

  1. Install → Works immediately (built-in fallback)
  2. Sync → Gets better (vector embeddings)
  3. Choose mode → Fast for speed, Focus for depth
  4. Use → Always best available

🎛️ Toggle Modes

# Enable Focus mode (curated retrieval)
node smart-memory/smart_memory.js --focus

# Disable Focus mode (back to fast)
node smart-memory/smart_memory.js --unfocus

# Check current mode
node smart-memory/smart_memory.js --mode

📊 Before & After

QueryWithout SkillWith Skill (Fast)With Skill (Focus)
"User collaboration style"⚠️ Weak✅ Better✅ "work with me, not just for me" + context
"What did we decide?"⚠️ Scattered✅ Related chunks✅ Synthesized decision narrative
"Compare options A and B"⚠️ Manual work✅ Related hits✅ Structured comparison with sources

🛠️ Usage

In OpenClaw

// Fast search (default)
const results = await memory_search("deployment config", 5);

// Enable focus for complex queries
memory_mode('focus');
const deepResults = await memory_search("architecture decisions", 5);
// Returns: { synthesis, facts, sources, confidence }

CLI

# Search (uses current mode)
node smart-memory/smart_memory.js --search "your query"

# Search with mode override
node smart-memory/smart_memory.js --search "your query" --focus
node smart-memory/smart_memory.js --search "your query" --fast

# Toggle modes
node smart-memory/smart_memory.js --focus      # Enable focus
node smart-memory/smart_memory.js --unfocus    # Disable focus

# Check status
node smart-memory/smart_memory.js --status

📁 What's Included

smart-memory/
├── smart_memory.js        ← Main entry (auto-selects mode)
├── focus_agent.js         ← Curated retrieval engine
├── memory_mode.js         ← Mode toggle commands
├── db.js                  ← SQLite + hybrid search
├── memory.js              ← OpenClaw wrapper
├── package.json           ← Dependencies
└── references/
    ├── integration.md     ← Setup guide
    └── pgvector.md        ← Scale guide

skills/
└── vector-memory/         ← OpenClaw skill manifest
    ├── skill.json
    └── README.md

🔧 Requirements

  • Node.js 18+
  • ~80MB disk space (for model, cached after download)
  • OpenClaw (or any Node.js agent)

🎛️ Tools

ToolPurpose
memory_searchSmart search with mode awareness
memory_getRetrieve full content
memory_syncIndex for vector search
memory_modeToggle fast/focus modes
memory_statusCheck mode and database stats

🔄 Auto-Sync (Optional)

Add to HEARTBEAT.md:

if [ -n "$(find memory MEMORY.md -newer smart-memory/.last_sync 2>/dev/null)" ]; then
    node smart-memory/smart_memory.js --sync && touch smart-memory/.last_sync
fi

📈 Performance

ModeQualitySpeedBest For
Fast⭐⭐⭐⭐~10msQuick lookups, facts
Focus⭐⭐⭐⭐⭐~100msDecisions, synthesis, planning

🐛 Troubleshooting

IssueSolution
"Vector not ready"Run: node smart_memory.js --sync
No results foundCheck that MEMORY.md exists; try broader query
First sync slowNormal - downloading ~80MB model; subsequent syncs fast
Focus mode too slowSwitch to fast: node smart_memory.js --unfocus
Want pure built-in?Don't sync - built-in always available as fallback

🧪 Verify Installation

node smart-memory/smart_memory.js --status

Checks: dependencies, vector index, search functionality, memory files, current mode.

📋 For Agent Developers

Add to your AGENTS.md:

## Memory Recall
Before answering about prior work, decisions, preferences:
1. Run memory_search with relevant query
2. Use memory_get for full context
3. Enable focus mode for complex decisions: memory_mode('focus')
4. If low confidence, say you checked

See full template in AGENTS.md.

🗂️ Suggested Memory Structure

workspace/
├── MEMORY.md              # Curated long-term memory
└── memory/
    ├── logs/              # Daily activity (YYYY-MM-DD.md)
    ├── projects/          # Project-specific notes
    ├── decisions/         # Important choices
    └── lessons/           # Mistakes learned

See MEMORY_STRUCTURE.md for templates.

🔗 Links

📜 License

MIT

🙏 Acknowledgments

  • Embeddings: Xenova Transformers
  • Model: sentence-transformers/all-MiniLM-L6-v2
  • Inspired by OpenClaw's memory system and Cognee's knowledge graphs