Máy chủ MCP Local Memory | PlugMCP
Chuyển tới nội dung Local Memory MCP Server for Coding/AI Agents
This project is a local MCP (Model Context Protocol) server that exposes a small set of tools:
memory.search – semantic search over stored memories
memory.save – store a new memory
memory.supersede – mark an old memory as superseded
memory.delete – permanently remove a memory by id
Local Memory MCP Server for Coding Agents
Cắm mọi công cụ vào mọi agent. Thư mục MCP cho người không viết server.
Sản phẩm
Thư mục
Nhà phát triển
Công ty
—
memory.ping – sanity check / version output
What you can do with this project
Keep durable coding context across chat sessions (decisions, preferences, gotchas, API contracts).
Retrieve relevant past context semantically (not only keyword matching).
Scope memory per project using WORKSPACE_KEY while keeping one shared local database.
Correct memory over time by superseding outdated entries or deleting irrelevant ones.
Run everything locally (no external vector DB required).
Typical workflow
User asks a question in chat.
Agent calls memory.search to fetch relevant context.
Agent answers using retrieved memory + current codebase context.
New durable insight is stored via memory.save.
Old memory is updated via memory.supersede or removed via memory.delete.
Prerequisites
Bun installed
Ollama installed and running locally
Pull the embedding model:
ollama pull embeddinggemma
Install
Run This runs an MCP server over stdio .
Test
tests/embed.test.ts – validates Ollama embedding response parsing and error handling
tests/memory-db.test.ts – validates save, search, supersede, and delete on the Zvec-backed store
Environment variables
MEMORY_DB_PATH (default ./data/memory.zvec)
OLLAMA_BASE_URL (default http://localhost:11434)
OLLAMA_EMBED_MODEL (default embeddinggemma)
EMBEDDING_DIM (default 768, must match your embedding model)
WORKSPACE_KEY (default default)
VS Code
Workspace setup This repo includes .vscode/mcp.json that registers this server:
command: bun
args: run start
You can adjust environment variables in that file.
Always-on across all projects If you want this MCP server available in all workspaces, add it to your User MCP configuration instead of only .vscode/mcp.json:
Open Command Palette: MCP: Open User Configuration
Add a server entry that starts this repo from a fixed directory.
{
"servers": {
"local-memory-mcp": {
"type": "stdio",
"command": "bun",
"args": ["--cwd", "/path/to/local-memory-mcp", "run", "start"],
"env": {
"MEMORY_DB_PATH": "/path/to/local-memory-mcp/data/memory.zvec",
"OLLAMA_BASE_URL": "http://localhost:11434",
"OLLAMA_EMBED_MODEL": "embeddinggemma",
"EMBEDDING_DIM": "768",
"WORKSPACE_KEY": "${workspaceFolderBasename}"
}
}
}
}
Use an absolute MEMORY_DB_PATH so all projects use the same database.
WORKSPACE_KEY=${workspaceFolderBasename} keeps memories separated per project automatically.
Enable VS Code setting chat.mcp.autoStart (Experimental) to auto-start/restart MCP servers when needed.
Claude Code Add this server to Claude Code as a local stdio MCP server.
This repository already includes:
.mcp.json for project-scoped Claude MCP configuration
CLAUDE.md for memory-first agent behavior guidelines
User scope (all projects) claude mcp add --transport stdio --scope user \
--env MEMORY_DB_PATH=/absolute/path/to/local-memory-mcp/data/memory.zvec \
--env OLLAMA_BASE_URL=http://localhost:11434 \
--env OLLAMA_EMBED_MODEL=embeddinggemma \
--env EMBEDDING_DIM=768 \
--env WORKSPACE_KEY=default \
local-memory-mcp -- bun --cwd /absolute/path/to/local-memory-mcp run start
Project scope (shared in repository) claude mcp add --transport stdio --scope project \
--env MEMORY_DB_PATH=./data/memory.zvec \
--env OLLAMA_BASE_URL=http://localhost:11434 \
--env OLLAMA_EMBED_MODEL=embeddinggemma \
--env EMBEDDING_DIM=768 \
--env WORKSPACE_KEY=${PWD##*/} \
local-memory-mcp -- bun run start
Project .mcp.json example:
{
"mcpServers": {
"local-memory-mcp": {
"type": "stdio",
"command": "bun",
"args": ["run", "start"],
"env": {
"MEMORY_DB_PATH": "./data/memory.zvec",
"OLLAMA_BASE_URL": "http://localhost:11434",
"OLLAMA_EMBED_MODEL": "embeddinggemma",
"EMBEDDING_DIM": "768",
"WORKSPACE_KEY": "${PWD##*/}"
}
}
}
}
--scope project writes to .mcp.json in the project root.
--scope user stores the server in your user Claude configuration.
Keep all Claude flags before the server name, and put -- before the server command.
claude mcp list
claude mcp get local-memory-mcp
claude mcp remove local-memory-mcp
Tool usage (examples)
Search {
"tool": "memory.search",
"arguments": {
"query": "What is our policy for multi-session memory?",
"topK": 8,
"workspaceKey": "my-repo"
}
}
Save {
"tool": "memory.save",
"arguments": {
"workspaceKey": "my-repo",
"type": "decision",
"summary": "We use zvec with Ollama embeddinggemma for long-term memory.",
"text": "Decision: The Copilot/agent memory sidecar stores vectors in zvec and generates embeddings via Ollama /api/embed using embeddinggemma.",
"tags": ["memory", "zvec", "ollama", "embeddinggemma"],
"importance": 0.8
}
}
Delete {
"tool": "memory.delete",
"arguments": {
"workspaceKey": "my-repo",
"id": 42
}
}
Implementation notes
The DB uses one Zvec collection with:
dense vector field embedding
scalar fields for metadata (workspaceKey, type, summary, etc.)
KNN queries are executed through Zvec querySync with metadata filters.
Tests
tests/embed.test.ts
parses successful Ollama /api/embed responses into Float32Array
verifies error handling when Ollama returns non-2xx responses
tests/memory-db.test.ts
validates save + search behavior with workspace/type filtering
validates supersede behavior (superseded items are excluded from search)
validates delete behavior and returned payload semantics
Điểm thư mục 6/100 Đã liệt kê 10 trên 10
Có trong MCP Registry chính thức 0 trên 18
Đã được người bảo trì nhận 0 trên 8
Trả về danh sách công cụ 0 trên 12
Sao GitHub 4 trên 16
Lượt tải hằng tuần 0 trên 10
Graphify Turn any codebase, with its docs, SQL schemas, configs, and PDFs, into a queryable knowledge graph. A /graphify skill for Claude Code, Cursor, Codex, and Gemini CLI: local deterministic AST parsing, e Understand Anything Graphs that teach > graphs that impress. Turn any code into an interactive knowledge graph you can explore, search, and ask questions about. Works with Claude Code, Codex, Cursor, Copilot, Gemini CLI, Sequential Thinking Step-by-step problem solving for agents: break a problem into thoughts, revise them and branch. The reference server from the Model Context Protocol project. Memory Persistent memory for agents as a local knowledge graph of entities, relations and observations. The reference server from the Model Context Protocol project. Ruflo 🌊 The original agent harness. Deploy intelligent multi-player swarms, coordinate autonomous workflows, and build conversational AI systems. Features adaptive memory, self-learning intelligence, feder Codegraph Pre-indexed code knowledge graph, auto syncs on code changes, for Claude Code, Codex, Gemini, Cursor, OpenCode, AntiGravity, Kiro, CoPilot, and Hermes Agent — fewer tokens, fewer tool calls, 100% loca Codebase Memory Local code intelligence for developers and AI agents. Connect code, docs and infrastructure in a persistent graph, with CBM Lens, MCP tools, agent integrations and change-aware test selection. Codebase Memory Codebase knowledge graph for AI agents — 162 languages, sub-ms queries, 99% fewer tokens. Codebase Memory Local code intelligence for developers and AI agents. Connect code, docs and infrastructure in a persistent graph, with CBM Lens, MCP tools, agent integrations and change-aware test selection. Context Mode Free, local plugin that keeps tool output out of your coding agent's context window. Sandbox and SQLite FTS5 search, 99% fewer bytes in context. Works with Claude Code, Codex, Pi, OMP, OpenCode, Gemin MaxKB 🔥 MaxKB is an open-source platform for building enterprise-grade agents. 强大易用的开源企业级智能体平台。 Xerj AI search engine and MCP server for bots and agents. One Rust binary indexes code, docs, logs, JSONL/CSV and PDFs for BM25 full-text, vector and hybrid search, code search without grep, agent memory a Máy chủ MCP Knowledge and memory Máy chủ MCP Knowledge and memory tốt nhất
Chưa có danh sách công cụ. Máy chủ từ xa sẽ có danh sách sau lần kiểm tra tình trạng đầu tiên.
Câu hỏi thường gặp
Câu hỏi Làm thế nào để cài đặt Local Memory? Sao chép cấu hình stdio cho Cursor, Claude Desktop, Claude Code hoặc VS Code trên trang này. Cấu hình dùng bản cài đặt của nhà phát hành, không phải proxy của PlugMCP.
Local Memory có cần khóa API không? Bản ghi này không liệt kê biến môi trường bắt buộc nào.
Local Memory dùng giao thức truyền tải nào? Local Memory chạy cục bộ qua stdio.
Local Memory được kiểm tra lần cuối khi nào? Kiểm tra lần cuối: 2026-10-28. Local Memory MCP Server for Coding Agents
Sẵn sàng cho thoại 0 trên 3
Không thấy trong ba ngày -8