AI Agent Memory System — coordinate-based memory management with 30M parameter models
Project description
LightHouseOS
AI Agent 记忆系统 — 让小模型管理记忆,让记忆永不丢失、越用越精准
LightHouseOS 是一个轻量级 AI Agent 记忆系统,基于 坐标索引(而非向量检索)和 三个 33M 参数的小模型 实现长期记忆管理。
核心思路
与所有主流记忆系统(Mem0、MemGPT、RAG)不同,LightHouseOS 不用向量检索:
传统方案: 对话 → 嵌入向量 → 向量数据库 → 余弦相似度检索 → 注入提示词
LightHouseOS: 对话 → 小模型分类 → pin 坐标 → 哈希索引查找 → 直接返回
三个模型各自专攻一个环节:
- 输入模型 (33M) — 对话 → pin坐标(event, entity, topic) + importance
- 召回模型 (33M) — 查询 → pin坐标 + precision
- 整理模型 (33M) — 修正错误的 pin 标注
快速开始
pip install lighthouse-memory
# 写入记忆
lh write "我刚把 update_query 的返回值从 Vec<Row> 改成 usize" \
--event 代码修改 --entity src/db.rs --topic 数据库层
# 查询记忆
lh recall "刚才改了啥"
# 列出最近记忆
lh list
集成到 Claude Code
lh serve
然后在 Claude Code 的 MCP 配置中指向这个服务,即可通过 tools 读写记忆。
项目结构
lighthouse-memory/
├── lighthouse/
│ ├── memory/ # TF Database (pin index + fragment archive)
│ ├── models/ # 模型推理(计划中)
│ ├── cli/ # 命令行工具
│ └── server/ # MCP 服务器
├── Models/ # 训练代码
├── Docs/ # 设计文档
└── scripts/ # 工具脚本
设计文档
- 总纲 — 顶层架构
- TECH_SPEC.md — TF Database 详细设计
- ROADMAP.md — 开发路线图
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file lighthouse_memory-0.1.0-py3-none-any.whl.
File metadata
- Download URL: lighthouse_memory-0.1.0-py3-none-any.whl
- Upload date:
- Size: 23.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.4
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
05e24f576230028000162e335af795dc8dae736685d6596c999220ab36b5b007
|
|
| MD5 |
7c93feafeca2f245e8500d79e9f63525
|
|
| BLAKE2b-256 |
a71b9f5e49edc4ff519ec747b198432d079165b647812d3203e7cd442f432b48
|