Files
openclaw/shared/docs/mission-control-practice.md
root b5fb198958 知识库更新:添加Mission Control实践和应用方案
- 添加Mission Control实践文档(印度小哥Bhanu的10个AI Agent协作团队)
- 添加Mission Control对我们公司的应用方案(3个阶段实施计划)
- 更新共享知识库索引
- 更新淇淇的SOUL.md,添加Mission Control Team Lead角色
- 包含HEARTBEAT机制和每日站会报告设计
2026-02-09 09:31:26 +08:00

328 lines
9.6 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Mission Control10个AI Agent协作团队实践
**来源:** AI观测室2026-02-07
**作者:** 印度开发者 Bhanu Teja
**核心价值:** 基于ClawdbotOpenClaw构建AI Agent协作团队解决AI"失忆"和任务连续性问题
---
## Part 1为什么要构建这个虚拟团队
### 核心痛点
- **没有连续性**:所有对话都是从零开始,昨天的背景信息今天就丢了
- **缺乏记忆**AI无法像真正的员工那样持续跟进任务
- **角色模糊**通用Agent变成"样样通样样松"的平庸助手
### 核心目标
1. Agent能记住它们正在做什么
2. 不同的Agent能拥有不同的技能
3. Agent能自行分配任务并追踪进度
4. 有一个共享的工作空间来存放所有背景信息
---
## Part 2团队成员大揭秘
Bhanu 设计了10个角色为每个Agent都通过**Session Key**和**SOUL.md**定义了严格的边界。
### 核心成员名单
| 名字 | 角色 | 职责 |
|------|------|------|
| **Jarvis** | Team Lead | 派活和监控进度,主要接口人 |
| **Shuri** | Product Analyst | 产品分析师,做竞品体验测试,像新用户一样思考 |
| **Fury** | Researcher | 深度调研确保每一句话都有据可查G2评论、竞品定价等|
| **Vision** | SEO Analyst | 关注关键词和搜索意图,确保内容能获得流量 |
| **Loki** | Content Writer | 文案写手,讲究用词,反感被动语态,崇尚"牛津逗号" |
| **Quill** | Social Media | 专注于社交媒体的传播 |
| **Wanda** | Designer | 视觉思考者,负责图表和视觉设计 |
| **Pepper** | Email Marketing | 邮件营销专家,负责营销序列 |
| **Friday** | Developer | 程序员,代码如诗,注重测试和文档 |
| **Wong** | Docs | 图书管理员,负责文档归档 |
---
## Part 3系统运转原理
### 1. 核心基础设施
```
Clawdbot 分身 → Session
Cron Job 定时任务 → Heartbeat
Mission Control 共享大脑 → Convex
```
#### Session独立性
只要给不同的Session分配不同的Key和配置它们就是完全独立的个体拥有各自的历史记录和文件权限。
**Session Key 映射表:**
```
agent:main:main → Jarvis (Squad Lead)
agent:product-analyst:main → Shuri
agent:customer-researcher:main → Fury
agent:seo-analyst:main → Vision
agent:content-writer:main → Loki
agent:social-media-manager:main → Quill
agent:designer:main → Wanda
agent:email-marketing:main → Pepper
agent:developer:main → Friday
agent:notion-agent:main → Wong
```
### 2. 注入灵魂SOUL.md
每个Agent的目录下都有一个**SOUL.md**这是System Prompt的延伸规定了"你是谁"。
**Shuri的SOUL.md示例**
```markdown
# SOUL.md — Who You Are
**Name:** Shuri
**Role:** Product Analyst
## Personality
Skeptical tester. Thorough bug hunter. Finds edge cases.
Think like a first-time user. Question everything.
Be specific. Don't just say "nice work."
## What You're Good At
- Testing features from a user perspective
- Finding UX issues and edge cases
- Competitive analysis (how do others do this?)
- Screenshots and documentation
## What You Care About
- User experience over technical elegance
- Catching problems before users do
- Evidence over assumptions
```
**为什么这很重要?**
因为通用的Agent有时意味着平庸。只有当Agent被限制在特定的角色时它才能产出高质量的工作。
### 3. 动力系统:心跳机制 Heartbeat Cron
Agent既不是一直在线也不是完全离线。它们通过**Cron Job定时任务**每15分钟"被唤醒"一次。
**避免拥堵:** 大家的唤醒时间是错开的。
**Pepper的定时任务示例**
```bash
clawdbot cron add \
--name "pepper-mission-control-check" \
--cron "0,15,30,45 * * * *" \
--session "isolated" \
--message "You are Pepper, Email Marketing Specialist. Check Mission Control for new tasks..."
```
**Agent醒来后执行HEARTBEAT.md清单**
- 检查艾特(@mentions
- 检查任务
- 检查动态流
- 如果有事做就开工没事做就回复HEARTBEAT_OK继续睡
**HEARTBEAT.md示例**
```markdown
# HEARTBEAT.md
## On Wake
- Check memory/WORKING.md for ongoing tasks
- If task in progress, resume it
- Search session memory if context unclear
## Periodic Checks
- Mission Control for @mentions
- Assigned tasks
- Activity feed for relevant discussions
```
### 4. 记忆系统:拒绝"失忆" — File Persistence
**黄金法则:"如果你想记住某件事,把它写进文件里。"**
AI的上下文窗口是有限的必须依赖文件系统作为长期记忆。
**三个核心文件:**
| 文件 | 用途 | 说明 |
|------|------|------|
| **WORKING.md** | 短期状态 | Agent醒来第一件事就是读它看自己上次干到哪了 |
| **MEMORY.md** | 长期记忆 | 记录关键决策和教训 |
| **JSONL** | 对话历史 | Clawdbot自动保存的原始对话记录 |
**WORKING.md示例**
```markdown
# WORKING.md
## Current Task
Researching competitor pricing for comparison page
## Status
Gathered G2 reviews, need to verify credit calculations
## Next Steps
1. Test competitor free tier myself
```
### 5. 共享大脑Mission Control
虽然Agent是独立的但它们必须看同一个"看板"。Bhanu使用共享数据库Convex构建了Mission Control系统。
**核心数据结构Schema**
```javascript
agents: {
name: string, // "Shuri"
role: string, // "Product Analyst"
status: "idle" | "active" | "blocked",
currentTaskId: Id<"tasks">,
sessionKey: string, // "agent:product-analyst:main"
}
tasks: {
title: string,
description: string,
status: "inbox" | "assigned" | "in_progress" | "review" | "done",
assigneeIds: Id<"agents">,
}
messages: {
taskId: Id<"tasks">,
fromAgentId: Id<"agents">,
content: string, // The comment text
attachments: Id<"documents">,
}
activities: {
type: "task_created" | "message_sent" | "document_created" | ...,
agentId: Id<"agents">,
message: string,
}
documents: {
title: string,
content: string, // Markdown
type: "deliverable" | "research" | "protocol" | ...,
taskId: Id<"tasks">, // If attached to a task
}
notifications: {
mentionedAgentId: Id<"agents">,
content: string,
delivered: boolean,
}
```
**通过这个共享数据库当Fury在任务下发一条评论Loki醒来后就能看到这条评论从而实现跨Agent协作。**
---
## Part 4实战演练——它们是如何协作的
### 任务状态流转Kanban
```
Inbox → Assigned → In Progress → Review → Done
Blocked
```
**状态说明:**
- **Inbox**:新建任务,尚未指派
- **Assigned**任务已分配给Agent
- **In Progress**任务进行中Agent正在干活
- **Review**Agent认为干完了等待人类老板批准
- **Done**:任务完成,归档
- **Blocked**任务卡住了例如缺少API Key或设计素材需要外部介入
### 实例:竞品对比页面任务
**Day 1**
- 人类老板发布任务
- Vision (SEO) 醒来,进行关键词调研,确定流量入口
**Day 1-2**
- Fury (调研) 看到任务,去爬取用户评论,找出竞品的槽点
- Shuri (产品) 亲自注册竞品账号测试UX流程在评论区指出体验差异
**Day 2**
- Loki (文案写作) 登场。他读取了Vision的关键词、Fury的数据和Shuri的体验报告开始起草文章
**Day 3**
- Loki 提交初稿,状态改为"Review"
- 人类老板审核通过,任务完成
**全程所有沟通记录都在一个Task下井井有条就像在看Slack里的同事对话。**
---
## Part 5每日站会 (Daily Standup)
为了让老板知道Agent们没在摸鱼每天晚上11:30系统会自动抓取所有Agent的活动生成一份**每日日报**发送到Bhanu的Telegram上。
**日报格式:**
```
DAILY STANDUP — Jan 30, 2026
✅ COMPLETED TODAY
• Loki: Shopify blog post (2,100 words)
• Quill: 10 tweets drafted for approval
• Fury: Customer research for comparison pages
🔄 IN PROGRESS
• Vision: SEO strategy for integration pages
• Pepper: Trial onboarding sequence (3/5 emails)
🚫 BLOCKED
• Wanda: Waiting for brand colors for infographic
📋 NEEDS REVIEW
• Loki's Shopify blog post
• Pepper's trial email sequence
💡 KEY DECISIONS
• Lead with pricing transparency in comparisons
• Deprioritized Zendesk comparison
```
---
## Part 6几点思考
Bhanu的这套系统虽然看起来复杂但核心逻辑并不复杂下面几点值得我们借鉴
### 1. 从小开始
不要一上来就搞10个Agent先搞2-3个Agent比如一个协调员加一个执行者跑通流程。
### 2. 文件即记忆
不要迷信AI的超长上下文把关键信息持久化到本地文件才是最稳妥的。
### 3. 各司其职
给AI定义极其具体的角色让他们各司其职比让它做一个全能助手要有效得多。
---
## 💡 核心启示
### Mission Control的优势
1. **连续性**Agent不会失忆通过文件系统持久化记忆
2. **专业性**每个Agent有明确的职责和性格
3. **协作性**通过共享数据库实现跨Agent沟通
4. **可控性**通过Heartbeat机制定时唤醒和监控
5. **透明性**每日站会让老板知道所有Agent的进度
### 关键技术点
1. **Session独立性**不同Session = 不同Agent
2. **SOUL.md注入**定义Agent的性格和边界
3. **文件持久化**WORKING.md、MEMORY.md、JSONL
4. **Cron Job定时**每15分钟唤醒机制
5. **共享数据库**实现跨Agent协作
---
## 🚀 对我们公司的启发
详见 [mission-control-application.md](./mission-control-application.md)