# 从 PyPI 安装(生产环境推荐) uv pip install "powermem[cli,server,mcp,seekdb]" # 或从源码安装(开发环境) git clone https://github.com/oceanbase/powermem.git cd powermem uv pip install -e ".[cli,server,mcp,seekdb]"
# 交互式生成 .env 配置文件 pmem config init
# DATABASE_PROVIDER=oceanbase DATABASE_PROVIDER=sqlite SQLITE_PATH=/root/data/package/powermem/powermem.db # LLM_PROVIDER=anthropic LLM_PROVIDER=openai # ANTHROPIC_LLM_BASE_URL=https://token-plan-cn.xiaomimimo.com/anthropic # LLM_API_KEY=tp-xxx # LLM_MODEL=mimo-v2.5-pro LLM_API_KEY=xxx LLM_MODEL=step-3.7-flash OPENAI_LLM_BASE_URL=https://api.stepfun.com/step_plan/v1 EMBEDDING_PROVIDER=siliconflow EMBEDDING_API_KEY=sk-xx EMBEDDING_MODEL=BAAI/bge-m3 # OCEANBASE_EMBEDDING_MODEL_DIMS=1024 # EMBEDDING_DIMS=1024
powermem-server --host 0.0.0.0 --port 8848
curl http://localhost:8848/api/v1/system/health
# 返回 {"status":"ok"} 即成功
http://<服务器IP>:8848/dashboard/
POWERMEM_SERVER_AUTH_ENABLED=true POWERMEM_SERVER_API_KEYS=your-secret-key
http://<服务器IP>:8848/docs
/plugin marketplace add oceanbase/powermem /plugin install memory-powermem@powermem /reload-plugins
如果网络不通,也可以从源码安装: claude --plugin-dir /path/to/powermem/apps/claude-code-plugin
/memory-powermem:init
C:\Users\<你的用户名>\.claude\plugins\cache\powermem\memory-powermem\0.1.0\hooks\hooks.json
"command": "powershell.exe -NoProfile -ExecutionPolicy Bypass -File \"${CLAUDE_PLUGIN_ROOT}/hooks/run-hook.ps1\""
{
"hooks": {
"UserPromptSubmit": [
{
"hooks": [
{
"type": "command",
"command": "powershell.exe -NoProfile -ExecutionPolicy Bypass -File \"${CLAUDE_PLUGIN_ROOT}/hooks/run-hook.ps1\"",
"timeout": 120
}
]
}
],
"SessionEnd": [
{
"hooks": [
{
"type": "command",
"command": "powershell.exe -NoProfile -ExecutionPolicy Bypass -File \"${CLAUDE_PLUGIN_ROOT}/hooks/run-hook.ps1\""
}
]
}
],
"PostCompact": [
{
"matcher": "auto|manual",
"hooks": [
{
"type": "command",
"command": "powershell.exe -NoProfile -ExecutionPolicy Bypass -File \"${CLAUDE_PLUGIN_ROOT}/hooks/run-hook.ps1\""
}
]
}
]
}
}
{
"env": {
"POWERMEM_BASE_URL": "http://<服务器IP>:8848",
"POWERMEM_API_KEY": "your-secret-key"
}
}
export POWERMEM_BASE_URL=http://<服务器IP>:8848 export POWERMEM_API_KEY=your-secret-key
通过 memory-powermem 帮我安装一下 powermem 记忆引擎插件
openclaw plugins install memory-powermem
EMBEDDING_PROVIDER=siliconflow EMBEDDING_API_KEY=sk-xxx EMBEDDING_MODEL=BAAI/bge-m3 EMBEDDING_DIMS=1024
根据实际使用的嵌入服务调整 provider、model 和维度。
http://<服务器IP>:8848
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/69909943/viewspace-3174943/ ,如需转载,请注明出处,否则将追究法律责任。