mirror of
https://github.com/zhayujie/chatgpt-on-wechat.git
synced 2026-07-20 13:47:15 +08:00
docs(memory): update long-term memory docs
This commit is contained in:
@@ -39,20 +39,25 @@ The memory system supports hybrid retrieval modes:
|
|||||||
|
|
||||||
The Agent automatically triggers memory retrieval during conversation as needed, incorporating relevant historical information into context. Results are ranked by a combined score (default: 0.7 vector weight + 0.3 keyword weight). Daily memory scores decay over time (30-day half-life), while core memory does not decay.
|
The Agent automatically triggers memory retrieval during conversation as needed, incorporating relevant historical information into context. Results are ranked by a combined score (default: 0.7 vector weight + 0.3 keyword weight). Daily memory scores decay over time (30-day half-life), while core memory does not decay.
|
||||||
|
|
||||||
## First Launch
|
## Related Files
|
||||||
|
|
||||||
On first launch, the Agent will proactively ask the user for key information and save it to the workspace (default `~/cow`):
|
Files related to memory in the workspace (default `~/cow`):
|
||||||
|
|
||||||
| File | Description |
|
| File | Description |
|
||||||
| --- | --- |
|
| --- | --- |
|
||||||
| `system.md` | Agent system prompt and behavior settings |
|
| `AGENT.md` | Agent personality and behavior settings |
|
||||||
| `user.md` | User identity information and preferences |
|
| `USER.md` | User identity information and preferences |
|
||||||
|
| `RULE.md` | Custom rules and constraints |
|
||||||
| `MEMORY.md` | Core memory (long-term) |
|
| `MEMORY.md` | Core memory (long-term) |
|
||||||
| `memory/YYYY-MM-DD.md` | Daily memory (created on demand) |
|
| `memory/YYYY-MM-DD.md` | Daily memory (created on demand) |
|
||||||
| `memory/dreams/YYYY-MM-DD.md` | Dream diary (auto-generated by Deep Dream) |
|
| `memory/dreams/YYYY-MM-DD.md` | Dream diary (auto-generated by Deep Dream) |
|
||||||
|
|
||||||
|
## Web Console
|
||||||
|
|
||||||
|
The memory management page in the Web console allows browsing memory files and dream diaries, with tab switching support:
|
||||||
|
|
||||||
<Frame>
|
<Frame>
|
||||||
<img src="https://cdn.link-ai.tech/doc/20260203000455.png" width="800" />
|
<img src="https://cdn.link-ai.tech/doc/20260414171014.png" width="800" />
|
||||||
</Frame>
|
</Frame>
|
||||||
|
|
||||||
## Configuration
|
## Configuration
|
||||||
|
|||||||
@@ -30,20 +30,25 @@ Agent は以下のメカニズムにより、会話内容を長期記憶に自
|
|||||||
|
|
||||||
すべての記憶書き込みはバックグラウンドスレッドで非同期に実行され(LLM の要約 + ファイル書き込み)、通常の会話応答をブロックしません。
|
すべての記憶書き込みはバックグラウンドスレッドで非同期に実行され(LLM の要約 + ファイル書き込み)、通常の会話応答をブロックしません。
|
||||||
|
|
||||||
## 初回起動
|
## 関連ファイル
|
||||||
|
|
||||||
初回起動時に、Agent はユーザーに主要な情報を積極的に尋ね、ワークスペース(デフォルト `~/cow`)に保存します:
|
ワークスペース(デフォルト `~/cow`)内の記憶関連ファイル:
|
||||||
|
|
||||||
| ファイル | 説明 |
|
| ファイル | 説明 |
|
||||||
| --- | --- |
|
| --- | --- |
|
||||||
| `system.md` | Agent のシステムプロンプトと動作設定 |
|
| `AGENT.md` | Agent のパーソナリティと動作設定 |
|
||||||
| `user.md` | ユーザーの身元情報と好み |
|
| `USER.md` | ユーザーの身元情報と好み |
|
||||||
|
| `RULE.md` | カスタムルールと制約 |
|
||||||
| `MEMORY.md` | コア記憶(長期) |
|
| `MEMORY.md` | コア記憶(長期) |
|
||||||
| `memory/YYYY-MM-DD.md` | 日次記憶(オンデマンドで作成) |
|
| `memory/YYYY-MM-DD.md` | 日次記憶(オンデマンドで作成) |
|
||||||
| `memory/dreams/YYYY-MM-DD.md` | 夢日記(Deep Dream で自動生成) |
|
| `memory/dreams/YYYY-MM-DD.md` | 夢日記(Deep Dream で自動生成) |
|
||||||
|
|
||||||
|
## Web コンソール
|
||||||
|
|
||||||
|
Web コンソールの記憶管理ページで、記憶ファイルと夢日記を閲覧できます。タブ切り替えに対応:
|
||||||
|
|
||||||
<Frame>
|
<Frame>
|
||||||
<img src="https://cdn.link-ai.tech/doc/20260203000455.png" width="800" />
|
<img src="https://cdn.link-ai.tech/doc/20260414171014.png" width="800" />
|
||||||
</Frame>
|
</Frame>
|
||||||
|
|
||||||
## 設定
|
## 設定
|
||||||
|
|||||||
@@ -39,20 +39,25 @@ Agent 通过以下机制自动将对话内容持久化为长期记忆:
|
|||||||
|
|
||||||
Agent 会在对话中根据需要自动触发记忆检索,将相关历史信息纳入上下文。检索结果按混合评分排序(默认向量权重 0.7、关键词权重 0.3),日级记忆会随时间衰减(半衰期 30 天),核心记忆不衰减。
|
Agent 会在对话中根据需要自动触发记忆检索,将相关历史信息纳入上下文。检索结果按混合评分排序(默认向量权重 0.7、关键词权重 0.3),日级记忆会随时间衰减(半衰期 30 天),核心记忆不衰减。
|
||||||
|
|
||||||
## 首次启动
|
## 相关文件
|
||||||
|
|
||||||
首次启动 Agent 时,Agent 会主动向用户询问关键信息,并记录至工作空间(默认 `~/cow`)中:
|
工作空间(默认 `~/cow`)中与记忆相关的文件:
|
||||||
|
|
||||||
| 文件 | 说明 |
|
| 文件 | 说明 |
|
||||||
| --- | --- |
|
| --- | --- |
|
||||||
| `system.md` | Agent 的系统提示词和行为设定 |
|
| `AGENT.md` | Agent 的人格和行为设定 |
|
||||||
| `user.md` | 用户身份信息和偏好 |
|
| `USER.md` | 用户身份信息和偏好 |
|
||||||
|
| `RULE.md` | 自定义规则和约束 |
|
||||||
| `MEMORY.md` | 核心记忆(长期) |
|
| `MEMORY.md` | 核心记忆(长期) |
|
||||||
| `memory/YYYY-MM-DD.md` | 日级记忆(按需创建) |
|
| `memory/YYYY-MM-DD.md` | 日级记忆(按需创建) |
|
||||||
| `memory/dreams/YYYY-MM-DD.md` | 梦境日记(Deep Dream 自动生成) |
|
| `memory/dreams/YYYY-MM-DD.md` | 梦境日记(Deep Dream 自动生成) |
|
||||||
|
|
||||||
|
## Web 控制台
|
||||||
|
|
||||||
|
在 Web 控制台的记忆管理页面中,可浏览记忆文件和梦境日记,支持通过 Tab 切换查看:
|
||||||
|
|
||||||
<Frame>
|
<Frame>
|
||||||
<img src="https://cdn.link-ai.tech/doc/20260203000455.png" width="800" />
|
<img src="https://cdn.link-ai.tech/doc/20260414171014.png" width="800" />
|
||||||
</Frame>
|
</Frame>
|
||||||
|
|
||||||
## 相关配置
|
## 相关配置
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ description: CowAgent 2.0.6 - 知识库系统、梦境记忆蒸馏、上下文
|
|||||||
|
|
||||||
## 📚 知识库系统
|
## 📚 知识库系统
|
||||||
|
|
||||||
新增个人知识库系统,Agent 可自主构建和维护结构化知识,并在对话中按需检索引用:
|
新增个人知识库系统,Agent 可自主构建和维护结构化知识,并在对话中按需检索引用。
|
||||||
|
|
||||||
- **索引驱动的自组织结构**:知识库采用 `knowledge/` 目录,按分类自动组织,每个知识页面为独立的 Markdown 文件
|
- **索引驱动的自组织结构**:知识库采用 `knowledge/` 目录,按分类自动组织,每个知识页面为独立的 Markdown 文件
|
||||||
- **自动写入**:向 Agent 发送文件、链接等知识,或在讨论中识别到有价值的知识时,自动创建或更新知识页面
|
- **自动写入**:向 Agent 发送文件、链接等知识,或在讨论中识别到有价值的知识时,自动创建或更新知识页面
|
||||||
@@ -22,9 +22,10 @@ description: CowAgent 2.0.6 - 知识库系统、梦境记忆蒸馏、上下文
|
|||||||
|
|
||||||
<img src="https://cdn.link-ai.tech/doc/20260413105435.png" width="750" />
|
<img src="https://cdn.link-ai.tech/doc/20260413105435.png" width="750" />
|
||||||
|
|
||||||
|
|
||||||
相关文档:[知识库](https://docs.cowagent.ai/knowledge)
|
相关文档:[知识库](https://docs.cowagent.ai/knowledge)
|
||||||
|
|
||||||
|
Inspired by Karpathy's [LLM Wiki](https://gist.github.com/karpathy/442a6bf555914893e9891c11519de94f).
|
||||||
|
|
||||||
## 🌙 梦境记忆蒸馏(Deep Dream)
|
## 🌙 梦境记忆蒸馏(Deep Dream)
|
||||||
|
|
||||||
全新的记忆整理机制,每日自动将分散的对话记忆蒸馏为精炼的长期记忆:
|
全新的记忆整理机制,每日自动将分散的对话记忆蒸馏为精炼的长期记忆:
|
||||||
|
|||||||
Reference in New Issue
Block a user