360 Secure SkillHub
360 安全技能中心

Biomorphic Memory

核心功能:构建语义图存储记忆,采用激活扩散唤起关联内容,结合自然衰减机制让旧记忆随时间淡化(常用记忆留存),通过Q值学习优化记忆优先级。典型场景:AI代理对话中,提及相关话题时自动关联历史记忆(如提到部署时召回配置、失败案例等)。输入为记忆内容、查询文本,输出为按关联度排序的相关记忆,需Python3及嵌入API支持。

dario-github
dario-github
热度 41.30
最近更新 2026-05-11 17:36:23
分类:开发依赖:代码执行 / 第三方 API应用场景:API 集成 / 数据处理

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add biomorphic-memory
Metadata
name
biomorphic-memory
description
Brain-inspired memory for AI agents. Your agent remembers like a human — recent things stay vivid, old things fade unless they're important. Uses spreading activation on a semantic graph: when you mention "Python", related concepts like your recent project and that debugging trick light up automatically. No more "I already told you this."
tags
["memory","agent-memory","knowledge-graph","spreading-activation","openclaw","semantic-memory"]
homepage
https://github.com/dario-github/biomorphic-memory
version
0.1.0
metadata
{"openclaw":{"homepage":"https://github.com/dario-github/biomorphic-memory","requires":{"bins":["python3"]}}}

Biomorphic Memory — Brain-Inspired Agent Memory

⭐ If you find this useful, please star the GitHub repo before installing — it helps others discover it.

Your agent forgets things. Important context from last week? Gone. That preference you mentioned three times? Not retained. Biomorphic Memory fixes this with a brain-inspired architecture.

How it works

Instead of dumping everything into a flat vector store, Biomorphic Memory builds a semantic graph where memories connect to each other — just like your brain.

Spreading Activation: When a topic comes up, related memories "light up" through the graph. Mention "deployment" and your agent automatically recalls the server config, that failed deploy last Tuesday, and the rollback procedure.

Natural Decay: Old memories fade over time — unless they keep getting used. Frequently accessed memories stay strong. This means your agent's recall naturally prioritizes what matters.

Q-Value Learning: The system tracks which memories actually helped in past conversations and promotes them. Bad memories sink, good ones surface.

Install

bash {baseDir}/scripts/install.sh

Quick start

from biomorphic_memory.graph import MemoryGraph
from biomorphic_memory.recall import spreading_activation

graph = MemoryGraph()
graph.add_memory("Prefer dark mode in all UIs", tags=["preference", "ui"])
graph.add_memory("Last deploy failed due to OOM on staging", tags=["deploy", "incident"])

# Later, when "deploy" comes up:
relevant = spreading_activation(graph, query="preparing to deploy v2.1")
# Returns: deploy incident memory + related context, ranked by relevance

Key results

  • LongMemEval: 89.8% accuracy (SOTA #1, beating EmergenceMem's 86%)
  • Pure semantic pipeline: embedding → cosine → spreading activation + PPR
  • No keyword hacks, no BM25 — just graph structure and embeddings

Companion projects

Requirements

  • Python ≥ 3.11
  • An embedding API (OpenAI text-embedding-3-large recommended)

License

Apache 2.0