wiki-ingest: 4 Agent Use Cases (autonomous PM, content factory, product factory, knowledge base RAG) - 2026-04-15 evening batch

This commit is contained in:
2026-04-15 20:35:29 +08:00
parent b2e7c5bb9a
commit 9688f3f54b
34 changed files with 1227 additions and 23 deletions

View File

@@ -0,0 +1,27 @@
---
title: "Pattern-Key"
type: concept
tags: [self-improving, memory, pattern, tracking]
last_updated: 2026-04-15
---
## Definition
经验记录LEARNINGS.md的唯一标识键格式为 domain.subdomain如 cron.telegram-delivery用于发现重复踩坑和追踪系统性错误。
## Core Mechanism
- 格式:点分层级,如 cron.daily-self-review / cron.telegram-delivery / cron.naming-convention
- 用途:通过相同 Pattern-Key 发现同一问题的多次记录
- 决策信号Pattern-Key 重复出现 = 系统性问题需系统性解决,而非单点修复
## Example
| Pattern-Key | 出现次数 | 含义 |
|---|---|---|
| cron.daily-self-review | 9次 | 每日复盘,持续活跃优化领域 |
| cron.telegram-delivery | 2次 | Telegram 通知配置,第一次记了第二次解决 |
## Key Insight
Pattern-Key 重复本身是信号——第一次记了第二次就该解决了。Recurrence-Count ≥ 2 说明这不是偶发错误。
## Connections
- [[Self-Improving Skill]] ← 核心机制 ← [[Pattern-Key]]
- [[Recurrence-Count]] ← 量化 ← [[Pattern-Key]]

View File

@@ -0,0 +1,23 @@
---
title: "Recurrence-Count"
type: concept
tags: [self-improving, memory, tracking, systematic-error]
last_updated: 2026-04-15
---
## Definition
经验记录的重复次数计数器,记录同一 Pattern-Key 出现的次数,用于区分偶发一次性错误与需系统性解决的重复问题。
## Core Mechanism
- 初始值1新记录
- 递增:同一 Pattern-Key 再次出现时 +1
- 决策阈值Recurrence-Count ≥ 2 说明这是重复问题,不是偶发错误
## Key Insight
- Recurrence-Count = 1一次性错误记录后不再出现关注 Suggested Action 即可
- Recurrence-Count ≥ 2系统性重复需要检查上一次是否真正解决了根本原因
- 高 Recurrence-Count9次如 cron.daily-self-review说明这是持续活跃的优化领域每次复盘都在积累
## Connections
- [[Pattern-Key]] ← 追踪 ← [[Recurrence-Count]]
- [[Self-Improving Skill]] ← 量化机制 ← [[Recurrence-Count]]

View File

@@ -0,0 +1,41 @@
---
title: "STATE.yaml"
type: concept
tags: [coordination, multi-agent, state-management]
last_updated: 2026-04-15
---
## Summary
去中心化项目协调文件格式YAML 结构定义任务 ID、状态in_progress/done/blocked、owner、开始时间、备注、blocked_by 依赖关系。所有 agent 读写同一文件实现协调。
## Format Structure
```yaml
project: project-name
updated: ISO-timestamp
tasks:
- id: task-id
status: in_progress | done | blocked
owner: agent-label
started: ISO-timestamp
completed: ISO-timestamp
blocked_by: other-task-id
notes: "描述"
next_actions:
- "agent-label: 具体下一步行动"
```
## Key Properties
- 单一事实来源Single Source of Truth
- Git 版本控制可获取完整变更历史
- blocked_by 字段实现自动依赖触发
## Compared To
- [[Multi-Agent Hierarchy]]:层级架构 vs 平铺协调
- [[共享内存模式]]:内存读写 vs 文件持久化
## Key Connections
- [[Autonomous Project Management]] ← 核心协调机制
- [[GitOps]] ← 审计日志集成
- [[去中心化协调]] ← 协调模式

View File

@@ -0,0 +1,42 @@
---
title: "Self-Improving Skill"
type: concept
tags: [openclaw, self-improvement, memory, agent, learning]
last_updated: 2026-04-15
---
## Definition
OpenClaw 自改进技能,通过结构化经验记录系统让 Agent 在错误中学习、持续进化,避免同一错误重复出现。
## Core Mechanism
- 工具self_improvement_log写入 LEARNINGS.md 或 ERRORS.md
- 固定格式Summary + Details + Suggested Action + MetadataPattern-Key/Recurrence-Count/See Also
- 记录类型correction错误修正/ workflow流程改进/ config配置发现/ best_practice最佳实践
## Key Insight
- 错误只犯一次Pattern-Key 相同的问题第二次出现时应直接应用 Suggested Action
- Recurrence-Count 是核心指标:重复次数高的 Pattern-Key 需要系统性解决,而非单点修复
- Pattern-Key 重复本身是信号:第一次记了,第二次就该解决了
## LEARNINGS.md 格式示例
```markdown
## [LRN-20260325-001] correction
**Logged**: 2026-03-25T14:09:53+08:00
**Priority**: high
**Status**: pending
**Area**: config
### Summary
Telegram chat ID 在 cron job 配置中不应使用 "user:" 前缀
### Details
使用了 `--to user:5038825565` 格式,导致报错
### Suggested Action
使用纯数字 chat ID`--to 5038825565`
### Metadata
- Pattern-Key: cron.telegram-delivery
- Recurrence-Count: 1
```
## Connections
- [[双层记忆架构]] ← 包含 ← [[Self-Improving Skill]]
- [[Pattern-Key]] ← 核心机制 ← [[Self-Improving Skill]]
- [[每日复盘]] ← 触发 ← [[Self-Improving Skill]]

View File

@@ -0,0 +1,26 @@
---
title: "Vibe-Kanban"
type: concept
tags: [vibe-coding, kanban, opencode, ubuntu, ai-pair-programming]
last_updated: 2026-04-15
---
## Definition
AI 结对编程任务看板,通过 Web UIPORT 9999管理编程任务自动 spawn OpenCode Executor 在随机端口执行 AI 编程。
## Core Mechanism
- 启动RUST_LOG=debug HOST=0.0.0.0 PORT=9999 npx vibe-kanban
- 自动 spawnvibe-kanban 启动后自动 spawn executor随机端口无需手动启动
- 工作目录:/var/tmp/vibe-kanban/worktrees/(需 shenwei 用户权限)
- 配置目录:~/.vibe-kanban
- 清理rm -rf /var/tmp/vibe-kanban/worktrees/* ~/.vibe-kanban解决权限/端口问题)
## Key Constraints
- 不要用 root 启动 OpenCode serve
- I/O error 通常是 executor 没启动或端口被占用
- executor 随 vibe-kanban 进程一起管理,不单独用 pm2 管理
## Connections
- [[Vibe-Kanban]] ← spawns ← [[OpenCode Executor]]
- [[nvm]] ← 提供 Node ← [[Vibe-Kanban]]
- [[pm2]] ← 管理进程 ← [[Vibe-Kanban]]

21
wiki/concepts/nvm.md Normal file
View File

@@ -0,0 +1,21 @@
---
title: "nvm"
type: concept
tags: [node, version-manager, ubuntu, installation]
last_updated: 2026-04-15
---
## Definition
Node Version Manager通过 curl -fsSL 安装,管理多个 Node.js 版本,解决系统包版本冲突问题。
## Core Mechanism
- 安装curl -fsSL https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.7/install.sh | bash
- 环境变量export NVM_DIR="$HOME/.nvm"[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"
- 常用命令nvm install 20 / nvm use 20 / nvm alias default 20
## Use Case
Ubuntu Server 安装 Node 20 以支持 Vibe-Kanban 和 OpenCode避免系统包管理器版本过旧。
## Connections
- [[Node 20]] ← 版本 ← [[nvm]]
- [[Vibe-Kanban]] ← 依赖 ← [[nvm]]

24
wiki/concepts/pm2.md Normal file
View File

@@ -0,0 +1,24 @@
---
title: "pm2"
type: concept
tags: [process-manager, node, ubuntu, vibe-coding]
last_updated: 2026-04-15
---
## Definition
Node.js 进程管理器,提供进程守护、日志管理、开机自启功能,适合生产环境长期运行 Node 服务。
## Core Mechanism
- 安装npm install -g pm2
- 启动pm2 start "command" --name <app-name>
- 日志pm2 logs <app-name>
- 保存pm2 save保存当前进程列表
- 开机自启pm2 startup systemd -u <user> --hp <home-dir>
- 进程列表pm2 status
## Use Case
管理 Ubuntu Server 上的 Vibe-Kanban Web UI 进程PORT 9999确保服务持续运行并开机自启。
## Connections
- [[pm2]] ← 管理 ← [[Vibe-Kanban]]
- [[OpenCode Executor]] ← spawn by ← [[Vibe-Kanban]]

View File

@@ -0,0 +1,32 @@
---
title: "个人知识库"
type: concept
tags: [rag, memory, knowledge-management, agent]
last_updated: 2026-04-15
---
## Summary
基于 RAG 的个人第二大脑系统:自动从任意 URL 摄取内容(文章/tweets/YouTube/PDF向量嵌入存储语义搜索返回 ranked 结果+来源引文。支持其他 agent 工作流查询。
## Architecture
```
URL Drop → Content Fetch → Chunking → Embedding → Vector Store
Query → Semantic Search → Ranked Results + Citations
```
## Key Properties
- 零摩擦摄入Telegram/Slack 发 URL 即可
- 语义搜索:自然语言查询,非关键词匹配
- Source-grounding每个回答附带原文引文
- 主动供给:其他工作流可自动查询知识库
## Compared To
- [[NotebookLM]]NotebookLM 侧重已有文档管理,本概念侧重实时 URL 摄入+语义搜索
- [[双层记忆架构]]本概念是外部知识管理vs 双层记忆是 agent 自身经验积累
## Key Connections
- [[Personal Knowledge Base RAG]] ← 应用场景
- [[RAG]] ← 技术基础
- [[向量数据库]] ← 存储基础设施
- [[Embedding]] ← 语义表示

View File

@@ -0,0 +1,27 @@
---
title: "产品工厂"
type: concept
tags: [agent, product, entrepreneurship, automation]
last_updated: 2026-04-15
---
## Summary
市场研究到 MVP 构建的自动化管线Last30Days 挖掘 Reddit/X 真实用户痛点 → ranked pain points → 选择痛点 → OpenClaw 构建 MVP → 用户验证。零技术要求,全流程通过对话完成。
## Pipeline
```
Last30Days 研究 → 痛点排名 → 选择痛点 → OpenClaw 构建 MVP → 分享验证
```
## Key Properties
- 真实数据驱动:用户帖子而非调查数据
- 无需编码OpenClaw 完成研究和构建
- 每周定时研究保持市场洞察持续更新
- 可从小痛点开始验证市场需求
## Key Connections
- [[Market Research Product Factory]] ← 应用场景
- [[Last30Days]] ← 研究能力
- [[Content Factory]] ← 共享研究基础设施
- [[AI产品经理]] ← 能力要求
- [[超级个体]] ← 适用人群

View File

@@ -0,0 +1,29 @@
---
title: "内容工厂"
type: concept
tags: [agent, content, workflow, automation]
last_updated: 2026-04-15
---
## Summary
多 agent 链式协作的内容创作管线Research Agent 扫描趋势 → Writing Agent 生成脚本 → Thumbnail Agent 生成配图,全流程定时自动执行,结果输出到 Discord channel 供人工 review。
## Architecture
```
Research Agent → [趋势报告] → Writing Agent → [脚本/文章] → Thumbnail Agent → [配图]
↓ ↓ ↓
#research #scripts #thumbnails
```
## Key Properties
- 链式 agent前序输出自动喂给后序
- 平台无关:可适配 tweets/newsletter/LinkedIn/posts/podcast/blog
- 定时执行:每日 8AM 自动运行
- 本地模型Nano Banana降低图像生成成本
## Key Connections
- [[Content Factory]] ← 应用场景
- [[Market Research Product Factory]] ← 共享研究基础设施
- [[Last30Days]] ← Research Agent 数据来源
- [[baoyu-imagine]] ← 图像生成能力
- [[Discord 集成]] ← 输出 channel

View File

@@ -0,0 +1,29 @@
---
title: "去中心化协调"
type: concept
tags: [multi-agent, coordination, architecture]
last_updated: 2026-04-15
---
## Summary
多 agent 系统中无中央 orchestrator各 agent 通过共享状态文件自主协调的架构模式。与中央协调模式相对,优势在于无单点瓶颈、高扩展性、高韧性。
## Key Properties
- 无中央 orchestrator各 agent 自主读写共享状态
- 状态文件(如 [[STATE.yaml]])作为协调媒介
- Agent 间无需直接通信,降低耦合
- 失败隔离:一个 agent 崩溃不影响其他 agent
## Trade-offs
| 维度 | 去中心化协调 | 中央 orchestrator |
|------|------------|----------------|
| 扩展性 | 高(线性扩展) | 低(主节点瓶颈) |
| 全局控制 | 弱 | 强 |
| 失败韧性 | 高 | 低(单点故障) |
| 实现复杂度 | 中(需状态管理) | 低(结构简单) |
## Key Connections
- [[Autonomous Project Management]] ← 应用场景
- [[STATE.yaml]] ← 协调媒介
- [[Multi-Agent Hierarchy]] ← 对比:层级协调
- [[Multi-Agent Consensus]] ← 对比:共识协调

View File

@@ -0,0 +1,36 @@
---
title: "双层记忆架构"
type: concept
tags: [openclaw, memory, agent, long-term, short-term]
last_updated: 2026-04-15
---
## Definition
OpenClaw Agent 的记忆体系,由短期记忆层、长期记忆层和 self-improving 层三层构成,各司其职实现上下文连续性和持续进化。
## 三层架构
### 短期记忆层
- 媒介memory/YYYY-MM-DD.md 每日文件
- 职责:保存当天对话记录、操作、遇到的问题、未完成事项
- 触发:每次 Session 启动时检查并创建当天文件(修复无对话日记忆断层问题)
### 长期记忆层
- 媒介memory-lancedb-pro基于 LanceDB 的向量数据库)
- 职责:重要的决策、用户偏好、反复使用的流程,通过语义搜索找回
- 机制hybrid retrieval向量 + BM25Weibull 衰减
### Self-Improving 层
- 媒介LEARNINGS.md / ERRORS.md
- 职责每次踩坑都记录Pattern-Key 追踪重复Recurrence-Count 量化系统性
- 触发:每日 23:00 定时复盘
## 分工原则
- 每日文件:管上下文(接上昨天的工作)
- 向量数据库:管知识(语义搜索)
- self-improving管成长错误不重复
## Connections
- [[Self-Improving Skill]] ← 成长层 ← [[双层记忆架构]]
- [[memory-lancedb-pro]] ← 长期层 ← [[双层记忆架构]]
- [[记忆断层]] ← 问题 ← [[双层记忆架构]]

View File

@@ -0,0 +1,29 @@
---
title: "每日复盘"
type: concept
tags: [openclaw, cron, self-improving, habit, agent]
last_updated: 2026-04-15
---
## Definition
OpenClaw Agent 每天 23:00北京时间自动执行的自我复盘流程通过 self-improving skill 记录学习、检查重复、同步长期记忆。
## 复盘流程
1. 读取当天的 memory/YYYY-MM-DD.md 文件
2. 调用 self_improvement_log 记录今日学习
3. 检查 Pattern-Key 是否与之前重复(重复踩坑信号)
4. 把有价值的经验同步到 memory-lancedb-pro长期记忆
5. 通过 Telegram 发送复盘摘要
## 触发方式
OpenClaw cron job每天 23:00 执行,每个 Agent 独立运行自己的复盘流程。
## 关键价值
- 从"每次重新教"变为"记得上次错哪"
- 推动流程优化(如发现 3 月 27 日无 memory 文件 → 修改为 Session 启动时强制创建)
- Recurrence-Count 累积让系统性问题和偶发错误清晰分层
## Connections
- [[Self-Improving Skill]] ← 工具 ← [[每日复盘]]
- [[双层记忆架构]] ← 架构 ← [[每日复盘]]
- [[OpenClaw cron]] ← 触发 ← [[每日复盘]]

View File

@@ -0,0 +1,28 @@
---
title: "记忆断层"
type: concept
tags: [memory, openclaw, agent, bug, self-improvement]
last_updated: 2026-04-15
---
## Definition
由于设计缺陷导致某些日期完全没有 memory 文件记录,造成 Agent 无法回溯特定时期工作的问题。根源是"第一次对话时创建文件"的逻辑,无对话日不触发文件创建。
## 问题表现
- 3月27日 memory 文件为空 → 复盘时发现当天没有任何记录
- Agent 后续无法回溯该日的工作内容
- 知识孤岛:该日学到的经验没有积累
## 根因
原设计:只在"第一次对话时"检查并创建 memory 文件 → 无对话日文件不创建 → 记忆断层
## 解决方案
修改为:每次 Session 启动时都检查并创建当天 memory 文件,无论是否有对话
## 发现机制
每日复盘时 Agent 主动检查前一天的文件,发现问题后记录为 LRN 并推动流程优化。
## Connections
- [[双层记忆架构]] ← 存在于 ← [[记忆断层]]
- [[Self-Improving Skill]] ← 发现机制 ← [[记忆断层]]
- [[每日复盘]] ← 发现场景 ← [[记忆断层]]