Ebb
Ebb — 面向智能体的知识图谱
为 AI 智能体构建的长期记忆,以图的形式实现。相关性是基于近期性的加权连接强度:重复使用的知识保持活跃,未使用的知识会衰减并被归档,除非人类确认,否则不会删除任何内容。可嵌入式运行(零基础设施)或运行在 Neo4j 上(生产环境)。
它围绕的两个机制——连接加权相关性和时间衰减——都是原生图操作,并且两者都有深厚的先例(PageRank/中心性;认知科学中的 ACT-R 基级激活和扩散激活;间隔重复遗忘曲线)。这是对该谱系的一个小而诚实的实现,专门针对智能体记忆。
为什么这样构建
1. 引擎和接口是分离的。 图存储位于一个小接口(GraphStore)之后。智能体和评分逻辑从不接触特定数据库,因此你今天可以在嵌入式引擎上运行完全相同的图,以后只需一个环境变量即可切换到 Neo4j。
2. 相关性是基于近期性的,而不是原始连接数。 “连接越多 = 越相关”会永远奖励旧的、被大量引用的数据——这正是系统要消除的过时数据问题。在这里,每条边对相关性的贡献都乘以一个时间衰减因子,该因子取决于连接上次被强化的时间。昨天被强化的边几乎算作满值;六个月前最后接触的边几乎不算。重用连接(recall/reinforce)会重置其时钟——因此相关性跟踪实际活跃的内容,过时的知识会自行沉没。
证明,来自演示种子图(python -m ebb.demo):
node raw# activation
decision:outcome-pricing 3 6.116 <- fresh, few links, ranks #1
decision:seat-pricing 11 3.077 <- MOST links, ranks #3
...
note:analysis-* (x10) 1 0.051 <- decayed -> archived (tier 4)被取代的按席位决策拥有图中最高的原始连接数,但仍然排名第三,落后于一个链接数只有其三分之一的新决策。原始计数输了;近期性赢了。
Related MCP server: Memory Engine MCP
包含什么
图模型 — 每个笔记、决策、会议、人员、客户、事实都是一个节点;每个引用都是一条带时间戳、类型化、加权的边。
评分引擎(
scoring.py)— 基于近期性的激活、指数衰减(可配置半衰期)、一跳扩散激活(PageRank 的可移植替代品)以及层级分配。纯函数,完全单元测试。四个归档层级 — 1 热(默认召回)· 2 温(更深召回)· 3 冷(已归档,仅按需)· 4 冻结(删除前需人工确认)。固定节点永远不会自动归档。
MCP 服务器(
mcp_server.py)— 智能体接口:remember、recall、connect、reinforce、forget、neighbors、pin、maintain、review_queue、stats。两个后端 —
KuzuStore(嵌入式,默认)和Neo4jStore(生产环境),相同的接口,相同的 Cypher 形状。
快速开始(嵌入式 — 零基础设施)
python -m venv .venv && source .venv/bin/activate
pip install -r requirements.txt
python -m ebb.demo # narrated end-to-end walkthrough
pytest -q # 11 tests, all green无需 Docker,无需服务器,无需端口。Kùzu 是一个进程内图数据库,因此 Ebb 只是一个文件夹(./ebb_db)。
将其接入 MCP 客户端(例如 Claude Desktop)
将
claude_desktop_config.example.json中的ebb块复制到客户端的 MCP 配置中,并修正绝对路径。重启客户端。ebb 工具会出现在工具菜单中。
智能体现在可以跨会话
remember内容,recall相关内容,并reinforce它持续使用的内容——衰减和归档由系统自动处理。
生产模式(Neo4j)
docker compose up -d # Neo4j + Graph Data Science + APOC
EBB_BACKEND=neo4j NEO4J_PASSWORD=brainbrain python -m ebb.demo相同的代码,相同的行为。在 Neo4j 上,你还可以获得 GDS 库,因此当规模需要时,scoring.py 中的扩散激活过程可以升级为真正的 PageRank / 中心性 / 社区检测。(Neo4j 后端的 Cypher 镜像了经过完全测试的 Kùzu 后端;在生产环境中信任它之前,请对实时实例运行 pytest。)
模型简述
节点的激活值 = Σ (edge.weight × decay(age_since_last_reinforced)) + read-recency-bonus,再加上来自其邻居的同一衰减一跳。衰减是半衰期(默认 30 天,可调)。层级根据相对于最活跃的非固定节点归一化的激活值进行划分。recall 将此激活值与查询文本匹配相结合,并返回每个结果出现的原因。所有内容都可以在一个地方调整 — ebb/scoring.py::Config。
编写摄取适配器
Ebb 与来源无关:任何调用 remember/connect 的内容都可以为其提供数据。一个来源(笔记文件夹、wiki、问题跟踪器)通过将文档映射到节点、链接/提及映射到边、编辑时间戳映射到近期性时钟,从而成为图。将适配器及其数据保留在仓库之外。
目录结构
src/ebb/
model.py # Node, Edge, tiers
scoring.py # decay, activation, spreading, tiering <- the core
store.py # GraphStore interface
kuzu_store.py # embedded backend (default)
neo4j_store.py # production backend
engine.py # Brain: remember/recall/connect/reinforce/maintain/...
mcp_server.py # agent-facing MCP tools
seed.py # fictional demo graph
demo.py # narrated walkthrough
tests/ # 11 tests: scoring + end-to-end
docker-compose.yml许可证
MIT — 参见 LICENSE。
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceEnables AI agents to manage and query a temporally-aware knowledge graph memory, supporting episode tracking, entity relationships, and semantic search via MCP tools.1
- AlicenseNot gradedqualityAmaintenanceEnables AI assistants to have a living memory with atomic knowledge storage, multi-factor recall, organic decay, automatic learning, and graph traversal via MCP.1MIT
- AlicenseNot gradedqualityBmaintenanceEnables AI agents to have persistent, self-managing memory with bi-temporal supersession, timely forgetting, and recall under a limited context window, using MCP protocol.MIT

Hebbrix MCP Serverofficial
AlicenseAqualityAmaintenanceProvides long-term memory and a temporal knowledge graph for AI agents, enabling persistent memory and reasoning across sessions.261MIT
Related MCP Connectors
Your memory, everywhere AI goes. Build knowledge once, access it via MCP anywhere.
Shared long-term memory vault for AI agents with 20 MCP tools.
Shared, governed long-term memory for AI agents across tools and sessions via MCP and REST.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/jochemverheul/ebb-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server