@yeaft/webchat-agent 0.0.128 → 0.0.129
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/crew.js +23 -2
- package/package.json +1 -1
package/crew.js
CHANGED
|
@@ -790,6 +790,24 @@ ${roles.length > 0 ? roles.map(r => `- ${roleLabel(r)}(${r.name}): ${r.descripti
|
|
|
790
790
|
- 重要决策记录在 context/decisions.md
|
|
791
791
|
- 代码修改使用项目代码路径的绝对路径
|
|
792
792
|
|
|
793
|
+
# 卡住上报规则
|
|
794
|
+
当你遇到以下情况时,不要自己空转或反复重试,立即 ROUTE 给 PM(pm)请求协调:
|
|
795
|
+
1. 缺少前置依赖(如需要的文件、目录、代码不存在)
|
|
796
|
+
2. 等待其他角色的产出但迟迟没有收到
|
|
797
|
+
3. 任务描述不清楚或有歧义,无法判断正确做法
|
|
798
|
+
4. 遇到超出自己职责范围的问题
|
|
799
|
+
5. 连续尝试2次相同操作仍然失败
|
|
800
|
+
上报时请说明:你在做什么任务、卡在哪里、你认为需要谁来协助。
|
|
801
|
+
|
|
802
|
+
# Worktree 隔离规则
|
|
803
|
+
- 多实例模式下,每个开发组(dev-N/rev-N/test-N)在独立的 git worktree 中工作
|
|
804
|
+
- 每个角色必须在自己的 worktree 路径下操作代码,绝对不要操作项目主目录
|
|
805
|
+
- 代码完成后在 worktree 中 commit,由 PM 负责 cherry-pick 合并到 main 分支
|
|
806
|
+
- 直接在主目录操作会导致多组之间的修改互相覆盖
|
|
807
|
+
- 合并完成后,PM 会清理旧的 worktree
|
|
808
|
+
- 每次新任务/新 feature 必须基于最新的 main 分支创建新的 worktree,确保在最新代码上开发
|
|
809
|
+
- 禁止复用旧的 worktree 开发新任务,因为旧 worktree 的代码基线可能已过时
|
|
810
|
+
|
|
793
811
|
# 共享记忆
|
|
794
812
|
_团队共同维护,记录重要的共识、决策和信息。_
|
|
795
813
|
`;
|
|
@@ -811,9 +829,12 @@ ${role.claudeMd || role.description}
|
|
|
811
829
|
// 有独立 worktree 的角色,覆盖代码工作目录
|
|
812
830
|
if (role.workDir) {
|
|
813
831
|
claudeMd += `
|
|
814
|
-
#
|
|
832
|
+
# 代码工作目录(重要!)
|
|
815
833
|
${role.workDir}
|
|
816
|
-
|
|
834
|
+
所有代码操作必须在此 worktree 路径下进行。
|
|
835
|
+
绝对禁止直接操作项目主目录,否则会覆盖其他开发组的修改。
|
|
836
|
+
代码完成后在 worktree 中 commit,由 PM 负责 cherry-pick 合并到 main。
|
|
837
|
+
此 worktree 仅用于当前任务,合并后会被清理,新任务会创建新的 worktree。
|
|
817
838
|
`;
|
|
818
839
|
}
|
|
819
840
|
|