agent-memory-mcp
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseAgent Memory Skill
Agent Memory Skill
This skill provides a persistent, searchable memory bank that automatically syncs with project documentation. It runs as an MCP server to allow reading/writing/searching of long-term memories.
该技能提供一个持久化、可搜索的内存库,可自动与项目文档同步。它作为MCP服务器运行,支持对长期内存进行读、写和搜索操作。
Prerequisites
前提条件
- Node.js (v18+)
- Node.js (v18+)
Setup
安装步骤
-
Clone the Repository: Clone theproject into your agent's workspace or a parallel directory:
agentMemorybashgit clone https://github.com/webzler/agentMemory.git .agent/skills/agent-memory -
Install Dependencies:bash
cd .agent/skills/agent-memory npm install npm run compile -
Start the MCP Server: Use the helper script to activate the memory bank for your current project:bash
npm run start-server <project_id> <absolute_path_to_target_workspace>Example for current directory:bashnpm run start-server my-project $(pwd)
-
克隆仓库: 将项目克隆到你的Agent工作区或并行目录中:
agentMemorybashgit clone https://github.com/webzler/agentMemory.git .agent/skills/agent-memory -
安装依赖:bash
cd .agent/skills/agent-memory npm install npm run compile -
启动MCP服务器: 使用辅助脚本为当前项目激活内存库:bash
npm run start-server <project_id> <absolute_path_to_target_workspace>当前目录示例:bashnpm run start-server my-project $(pwd)
Capabilities (MCP Tools)
功能(MCP工具)
memory_search
memory_searchmemory_search
memory_searchSearch for memories by query, type, or tags.
- Args: (string),
query(string),type?(string[])tags? - Usage: "Find all authentication patterns" ->
memory_search({ query: "authentication", type: "pattern" })
按查询词、类型或标签搜索内存。
- Args: (string),
query(string),type?(string[])tags? - 用法: "查找所有认证模式" ->
memory_search({ query: "authentication", type: "pattern" })
memory_write
memory_writememory_write
memory_writeRecord new knowledge or decisions.
- Args: (string),
key(string),type(string),content(string[])tags? - Usage: "Save this architecture decision" ->
memory_write({ key: "auth-v1", type: "decision", content: "..." })
记录新的知识或决策。
- Args: (string),
key(string),type(string),content(string[])tags? - 用法: "保存此架构决策" ->
memory_write({ key: "auth-v1", type: "decision", content: "..." })
memory_read
memory_readmemory_read
memory_readRetrieve specific memory content by key.
- Args: (string)
key - Usage: "Get the auth design" ->
memory_read({ key: "auth-v1" })
通过键值检索特定内存内容。
- Args: (string)
key - 用法: "获取认证设计方案" ->
memory_read({ key: "auth-v1" })
memory_stats
memory_statsmemory_stats
memory_statsView analytics on memory usage.
- Usage: "Show memory statistics" ->
memory_stats({})
查看内存使用情况分析数据。
- 用法: "显示内存统计信息" ->
memory_stats({})
Dashboard
控制面板
This skill includes a standalone dashboard to visualize memory usage.
bash
npm run start-dashboard <absolute_path_to_target_workspace>Access at:
http://localhost:3333该技能包含一个独立的控制面板,用于可视化内存使用情况。
bash
npm run start-dashboard <absolute_path_to_target_workspace>访问地址:
http://localhost:3333