The Ultimate Cognitive Architecture for AI Agents (Vector + Graph Engine)
Welcome to the Genius Three-Layer Memory System v3.0. This is not just another "scratchpad" or simple RAG plugin. It is a complete cognitive upgrade for AI Agents, moving away from fragile markdown files into a real-time, event-driven hybrid database architecture.
- Zero Amnesia: Instant vector embeddings ensure that every rule or event is internalized immediately.
- Logical Reasoning: By building a Knowledge Graph, the AI understands causality and relationships, not just keywords.
- Visual Mind Mapping: Generate a visual snapshot of the AI's current understanding with a single command.
- L1: Working Memory: Handles immediate conversational flow.
- L2: Episodic Memory (ChromaDB): Stores conversational slices and rules as high-dimensional vectors.
- L3: Semantic Memory (NetworkX): A dynamic Knowledge Graph mapping entities and relationships.
1. Install Dependencies
pip install chromadb sentence-transformers networkx matplotlib2. CLI Commands
- Learn:
python memory_v3.py learn "Rule" "Subject" "Object" "Relation" - Think:
python memory_v3.py think "Query" "Target_Node" - Map:
python memory_v3.py map
欢迎来到 Genius 天才三层记忆系统 v3.0。 这绝不是一个简单的"错题本",而是为全能型 AI Agent 打造的终极认知架构。我们彻底抛弃了脆弱的纯文本日志,全面拥抱实时驱动的"向量+图谱"双引擎。
- 拒绝记忆滞后:事件发生即刻向量化存入 ChromaDB,形成"肌肉记忆"。
- 钢铁般的逻辑推理:引入 NetworkX 图数据库,AI 顺着节点理解"因果链"与"实体关系"。
- 一图胜千言:只需一行指令,即可将 AI 认知关系网渲染为可视化拓扑图。
- L1 短期工作记忆: 负责即时对话承接。
- L2 情景记忆库 (ChromaDB): 将有价值的规则转化为高维向量。
- L3 结构化图谱 (NetworkX): 沉淀核心规则、角色权限,构建知识大厦。
1. 安装依赖
pip install chromadb sentence-transformers networkx matplotlib2. 核心指令
- 学习新规:
python memory_v3.py learn "规则" "主体" "客体" "关系动作" - 主动唤醒:
python memory_v3.py think "情景" "核心对象" - 生成脑图:
python memory_v3.py map
Created by Eamon | Powered by OpenClaw Ecosystem