agent-memory-mcp

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Agent 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

安装步骤

  1. Clone the Repository: Clone the
    agentMemory
    project into your agent's workspace or a parallel directory:
    bash
    git clone https://github.com/webzler/agentMemory.git .agent/skills/agent-memory
  2. Install Dependencies:
    bash
    cd .agent/skills/agent-memory
    npm install
    npm run compile
  3. 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:
    bash
    npm run start-server my-project $(pwd)
  1. 克隆仓库: 将
    agentMemory
    项目克隆到你的Agent工作区或并行目录中:
    bash
    git clone https://github.com/webzler/agentMemory.git .agent/skills/agent-memory
  2. 安装依赖:
    bash
    cd .agent/skills/agent-memory
    npm install
    npm run compile
  3. 启动MCP服务器: 使用辅助脚本为当前项目激活内存库:
    bash
    npm run start-server <project_id> <absolute_path_to_target_workspace>
    当前目录示例:
    bash
    npm run start-server my-project $(pwd)

Capabilities (MCP Tools)

功能(MCP工具)

memory_search

memory_search

Search for memories by query, type, or tags.
  • Args:
    query
    (string),
    type?
    (string),
    tags?
    (string[])
  • Usage: "Find all authentication patterns" ->
    memory_search({ query: "authentication", type: "pattern" })
按查询词、类型或标签搜索内存。
  • Args:
    query
    (string),
    type?
    (string),
    tags?
    (string[])
  • 用法: "查找所有认证模式" ->
    memory_search({ query: "authentication", type: "pattern" })

memory_write

memory_write

Record new knowledge or decisions.
  • Args:
    key
    (string),
    type
    (string),
    content
    (string),
    tags?
    (string[])
  • Usage: "Save this architecture decision" ->
    memory_write({ key: "auth-v1", type: "decision", content: "..." })
记录新的知识或决策。
  • Args:
    key
    (string),
    type
    (string),
    content
    (string),
    tags?
    (string[])
  • 用法: "保存此架构决策" ->
    memory_write({ key: "auth-v1", type: "decision", content: "..." })

memory_read

memory_read

Retrieve specific memory content by key.
  • Args:
    key
    (string)
  • Usage: "Get the auth design" ->
    memory_read({ key: "auth-v1" })
通过键值检索特定内存内容。
  • Args:
    key
    (string)
  • 用法: "获取认证设计方案" ->
    memory_read({ key: "auth-v1" })

memory_stats

memory_stats

View 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