@cv-forever

Memory Enhancement

BGE-M3记忆增强插件,为OpenClaw添加长期记忆功能

当前版本
v1.0.1
code-plugin社区source-linked

Memory Enhancement Plugin

BGE-M3 based long-term memory enhancement plugin for OpenClaw.
Automatically retrieves relevant historical memories and injects them into conversation context.

Features

  • Automatic memory retrieval — On each session start, queries the BGE-M3 API server for memories relevant to the current context, injects them into before_prompt_build
  • Long-term memory storageadd_memories tool to save important conversations, decisions, and discoveries
  • Memory searchretrieve_memories tool to query stored memories on demand
  • Configurable — threshold, topK, cache, debug logging, all tunable via OpenClaw plugin config

How it works

Session Start
  │
  ▼
before_prompt_build hook
  │
  ├── Extract recent conversation text
  ├── Query BGE-M3 API (POST /retrieve)
  ├── Inject top-K relevant memories into prompt
  │
  ▼
Agent response with memory context

Installation

openclaw plugins install @cv/memory-enhancement
openclaw gateway restart

Configuration

FieldDefaultDescription
enabledtrueEnable/disable the plugin
apiHost127.0.0.1BGE-M3 API server host
apiPort8080BGE-M3 API server port
threshold0.5Similarity threshold (0.0–1.0)
topK3Max memories to inject
timeout15000API call timeout (ms)
maxRetries2Max retries on failure
cacheEnabledtrueEnable query cache
cacheTTL300Cache TTL (seconds)
debugfalseVerbose debug logging

Prerequisites

  • BGE-M3 API server running on the configured host:port
  • OpenClaw >= 2026.4.0

Version

1.0.0 — Initial stable release

Author

小爪 🐾

源码与版本

源码仓库

cv-forever/memory-enhancement

打开仓库

源码提交

5764c1ec925cc0e95ace7a646d37b3ec9bc64001

查看提交

安装命令

openclaw plugins install clawhub:@cv-forever/memory-enhancement

元数据

  • 包名: @cv-forever/memory-enhancement
  • 创建时间: 2026/05/23
  • 更新时间: 2026/05/23
  • 执行代码:
  • 源码标签: 5764c1ec925cc0e95ace7a646d37b3ec9bc64001

兼容性

  • 构建于 OpenClaw: 1.0.0
  • 插件 API 范围: >=2026.2.18
  • 标签: bge-m3, latest, long-term-memory, memory
  • 文件数: 5