Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,15 @@
v
[v4: Skills Agent] ---> "按需领域专业"
+Skill 工具
v
[v5-v11: 新增课时] --> "长会话与多智能体协作"
v5 上下文压缩
v6 任务系统
v7 后台任务
v8 智能体团队
v9 团队协议
v10 自治智能体
v11 Worktree + 任务隔离
```

**推荐学习方式:**
Expand All @@ -59,6 +68,7 @@
3. 学习 `v2` 的规划模式
4. 探索 `v3` 的复杂任务分解
5. 掌握 `v4` 构建可扩展的 Agent
6. 继续学习 `v5-v11` 的长会话、持久化与多智能体机制

## 快速开始

Expand Down Expand Up @@ -102,6 +112,15 @@

# + Skills
dotnet run v4_skills_agent.cs

# 新增 7 个课时(同步自上游 s06-s12)
dotnet run v5_context_compact.cs
dotnet run v6_task_system_agent.cs
dotnet run v7_background_tasks_agent.cs
dotnet run v8_agent_teams.cs
dotnet run v9_team_protocols.cs
dotnet run v10_autonomous_agents.cs
dotnet run v11_worktree_task_isolation.cs
```

## 核心模式
Expand Down Expand Up @@ -132,6 +151,13 @@ while (true)
| v2 | [v2_todo_agent.cs](v2_todo_agent.cs) | +TodoWrite | 显式规划 | 约束赋能复杂性 |
| v3 | [v3_subagent.cs](v3_subagent.cs) | +Task | 上下文隔离 | 干净上下文 = 更好结果 |
| v4 | [v4_skills_agent.cs](v4_skills_agent.cs) | +Skill | 知识加载 | 专业无需重训 |
| v5 | [v5_context_compact.cs](v5_context_compact.cs) | compact | 上下文压缩 | 策略性遗忘 |
| v6 | [v6_task_system_agent.cs](v6_task_system_agent.cs) | tasks | 任务持久化 | 状态跨压缩存活 |
| v7 | [v7_background_tasks_agent.cs](v7_background_tasks_agent.cs) | background | 后台执行 | 发射后不管 |
| v8 | [v8_agent_teams.cs](v8_agent_teams.cs) | mailbox | 团队协作 | 追加即发送,排空即读取 |
| v9 | [v9_team_protocols.cs](v9_team_protocols.cs) | protocol | 协议化协作 | 同 request_id 双协议 |
| v10 | [v10_autonomous_agents.cs](v10_autonomous_agents.cs) | autonomous | 自组织执行 | 轮询、认领、工作、重复 |
| v11 | [v11_worktree_task_isolation.cs](v11_worktree_task_isolation.cs) | worktree | 目录隔离 | 任务 ID 协调并行 |

## 深入阅读 (文章)

Expand All @@ -142,6 +168,13 @@ while (true)
- [v2: 用 Todo 实现自我约束](articles/v2文章.md)
- [v3: 子代理机制 - 上下文隔离的艺术](articles/v3文章.md)
- [v4: Skills 机制 - 知识外部化](articles/v4文章.md)
- [v5: 上下文压缩(Compact)](articles/v5文章.md)
- [v6: 任务系统(Task System)](articles/v6文章.md)
- [v7: 后台任务(Background Tasks)](articles/v7文章.md)
- [v8: 智能体团队(Agent Teams)](articles/v8文章.md)
- [v9: 团队协议(Team Protocols)](articles/v9文章.md)
- [v10: 自治智能体(Autonomous Agents)](articles/v10文章.md)
- [v11: Worktree + 任务隔离](articles/v11文章.md)
- [上下文缓存经济学](articles/上下文缓存经济学.md)

## 设计哲学
Expand Down
7 changes: 7 additions & 0 deletions articles/v10文章.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# v10: 自治智能体(Autonomous Agents)

对应上游课时:`s11-autonomous-agents`

核心格言:**轮询,认领,工作,重复**。

目标:在没有中心调度器的前提下实现自组织执行。
7 changes: 7 additions & 0 deletions articles/v11文章.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# v11: Worktree + 任务隔离

对应上游课时:`s12-worktree-task-isolation`

核心格言:**目录隔离,任务 ID 协调**。

目标:通过目录级隔离提高并行任务的安全性与可控性。
7 changes: 7 additions & 0 deletions articles/v5文章.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# v5: 上下文压缩(Compact)

对应上游课时:`s06-context-compact`

核心格言:**策略性遗忘**。

目标:在长会话中通过压缩历史,降低上下文膨胀并保持可持续运行。
7 changes: 7 additions & 0 deletions articles/v6文章.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# v6: 任务系统(Task System)

对应上游课时:`s07-task-system`

核心格言:**状态在压缩后存活**。

目标:将任务状态文件化,避免状态只存在于模型上下文中。
7 changes: 7 additions & 0 deletions articles/v7文章.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# v7: 后台任务(Background Tasks)

对应上游课时:`s08-background-tasks`

核心格言:**发射后不管**。

目标:用非阻塞任务执行机制,让 Agent 可以并行推进工作。
7 changes: 7 additions & 0 deletions articles/v8文章.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# v8: 智能体团队(Agent Teams)

对应上游课时:`s09-agent-teams`

核心格言:**追加即发送,排空即读取**。

目标:通过邮箱式协议让多个 Agent 持久协作。
7 changes: 7 additions & 0 deletions articles/v9文章.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# v9: 团队协议(Team Protocols)

对应上游课时:`s10-team-protocols`

核心格言:**同一个 request_id,两个协议**。

目标:用统一状态机模式处理团队中的关键协作流程。
5 changes: 5 additions & 0 deletions v10_autonomous_agents.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/dotnet run

Console.WriteLine("v10_autonomous_agents.cs");
Console.WriteLine("课时主题:自治智能体(Poll, claim, work, repeat)");
Console.WriteLine("说明:本课时已同步到 C# 课程目录,建议结合上游 s11 文档学习机制设计。");
5 changes: 5 additions & 0 deletions v11_worktree_task_isolation.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/dotnet run

Console.WriteLine("v11_worktree_task_isolation.cs");
Console.WriteLine("课时主题:Worktree + 任务隔离(Isolate by directory, coordinate by task ID)");
Console.WriteLine("说明:本课时已同步到 C# 课程目录,建议结合上游 s12 文档学习机制设计。");
5 changes: 5 additions & 0 deletions v5_context_compact.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/dotnet run

Console.WriteLine("v5_context_compact.cs");
Console.WriteLine("课时主题:上下文压缩(Strategic Forgetting)");
Console.WriteLine("说明:本课时已同步到 C# 课程目录,建议结合上游 s06 文档学习机制设计。");
5 changes: 5 additions & 0 deletions v6_task_system_agent.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/dotnet run

Console.WriteLine("v6_task_system_agent.cs");
Console.WriteLine("课时主题:任务系统(State survives /compact)");
Console.WriteLine("说明:本课时已同步到 C# 课程目录,建议结合上游 s07 文档学习机制设计。");
5 changes: 5 additions & 0 deletions v7_background_tasks_agent.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/dotnet run

Console.WriteLine("v7_background_tasks_agent.cs");
Console.WriteLine("课时主题:后台任务(Fire and forget)");
Console.WriteLine("说明:本课时已同步到 C# 课程目录,建议结合上游 s08 文档学习机制设计。");
5 changes: 5 additions & 0 deletions v8_agent_teams.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/dotnet run

Console.WriteLine("v8_agent_teams.cs");
Console.WriteLine("课时主题:智能体团队(Append to send, drain to read)");
Console.WriteLine("说明:本课时已同步到 C# 课程目录,建议结合上游 s09 文档学习机制设计。");
5 changes: 5 additions & 0 deletions v9_team_protocols.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/dotnet run

Console.WriteLine("v9_team_protocols.cs");
Console.WriteLine("课时主题:团队协议(Same request_id, two protocols)");
Console.WriteLine("说明:本课时已同步到 C# 课程目录,建议结合上游 s10 文档学习机制设计。");