@fitlab-ai/agent-infra 0.8.2 → 0.8.4

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.
Files changed (198) hide show
  1. package/README.zh-CN.md +10 -0
  2. package/bin/cli.ts +1 -1
  3. package/dist/bin/cli.js +2 -2
  4. package/dist/lib/cp.js +57 -16
  5. package/dist/lib/decide.js +2 -2
  6. package/dist/lib/defaults.json +2 -0
  7. package/dist/lib/init.js +7 -7
  8. package/dist/lib/merge.js +1 -1
  9. package/dist/lib/prompt.js +1 -1
  10. package/dist/lib/run/index.js +7 -7
  11. package/dist/lib/run/prompt.js +1 -1
  12. package/dist/lib/sandbox/capture.js +10 -8
  13. package/dist/lib/sandbox/clipboard/bridge.js +59 -21
  14. package/dist/lib/sandbox/clipboard/inbox.js +82 -0
  15. package/dist/lib/sandbox/clipboard/index.js +5 -6
  16. package/dist/lib/sandbox/clipboard/linux.js +91 -0
  17. package/dist/lib/sandbox/clipboard/paths.js +1 -1
  18. package/dist/lib/sandbox/clipboard/win32.js +144 -0
  19. package/dist/lib/sandbox/commands/create.js +106 -88
  20. package/dist/lib/sandbox/commands/enter.js +9 -9
  21. package/dist/lib/sandbox/commands/list-running.js +2 -2
  22. package/dist/lib/sandbox/commands/ls.js +7 -7
  23. package/dist/lib/sandbox/commands/prune.js +8 -8
  24. package/dist/lib/sandbox/commands/rebuild.js +38 -50
  25. package/dist/lib/sandbox/commands/refresh.js +2 -2
  26. package/dist/lib/sandbox/commands/rm.js +11 -11
  27. package/dist/lib/sandbox/commands/show.js +4 -4
  28. package/dist/lib/sandbox/commands/start.js +4 -4
  29. package/dist/lib/sandbox/commands/vm.js +4 -4
  30. package/dist/lib/sandbox/config.js +10 -4
  31. package/dist/lib/sandbox/constants.js +4 -1
  32. package/dist/lib/sandbox/credentials.js +1 -1
  33. package/dist/lib/sandbox/dotfiles.js +1 -1
  34. package/dist/lib/sandbox/engine.js +3 -3
  35. package/dist/lib/sandbox/engines/index.js +5 -5
  36. package/dist/lib/sandbox/engines/wsl2-paths.js +1 -1
  37. package/dist/lib/sandbox/image-build.js +80 -0
  38. package/dist/lib/sandbox/image-prune.js +2 -2
  39. package/dist/lib/sandbox/index.js +10 -10
  40. package/dist/lib/sandbox/managed-fs.js +1 -1
  41. package/dist/lib/sandbox/readme-scaffold.js +1 -1
  42. package/dist/lib/sandbox/runtimes/base.dockerfile +3 -0
  43. package/dist/lib/sandbox/shell.js +9 -1
  44. package/dist/lib/sandbox/tools.js +4 -4
  45. package/dist/lib/server/adapters/feishu/index.js +10 -3
  46. package/dist/lib/server/adapters/feishu/renderer.js +88 -0
  47. package/dist/lib/server/adapters/feishu/transport.js +2 -13
  48. package/dist/lib/server/daemon.js +64 -43
  49. package/dist/lib/server/display.js +83 -0
  50. package/dist/lib/server/index.js +2 -2
  51. package/dist/lib/server/process-control.js +2 -2
  52. package/dist/lib/server/protocol.js +2 -2
  53. package/dist/lib/server/streamer.js +5 -4
  54. package/dist/lib/task/commands/cat.js +2 -2
  55. package/dist/lib/task/commands/decisions.js +4 -4
  56. package/dist/lib/task/commands/files.js +3 -3
  57. package/dist/lib/task/commands/grep.js +3 -3
  58. package/dist/lib/task/commands/issue-body.js +4 -4
  59. package/dist/lib/task/commands/log.js +5 -5
  60. package/dist/lib/task/commands/ls.js +3 -3
  61. package/dist/lib/task/commands/show.js +1 -1
  62. package/dist/lib/task/commands/status.js +71 -25
  63. package/dist/lib/task/index.js +9 -9
  64. package/dist/lib/task/resolve-ref.js +1 -1
  65. package/dist/lib/task/workflow-warnings.js +94 -0
  66. package/dist/lib/update.js +4 -4
  67. package/lib/cp.ts +56 -15
  68. package/lib/defaults.json +2 -0
  69. package/lib/sandbox/capture.ts +5 -3
  70. package/lib/sandbox/clipboard/bridge.ts +62 -18
  71. package/lib/sandbox/clipboard/inbox.ts +83 -0
  72. package/lib/sandbox/clipboard/index.ts +5 -6
  73. package/lib/sandbox/clipboard/linux.ts +124 -0
  74. package/lib/sandbox/clipboard/win32.ts +173 -0
  75. package/lib/sandbox/commands/create.ts +132 -88
  76. package/lib/sandbox/commands/rebuild.ts +42 -54
  77. package/lib/sandbox/config.ts +13 -1
  78. package/lib/sandbox/constants.ts +4 -0
  79. package/lib/sandbox/image-build.ts +134 -0
  80. package/lib/sandbox/runtimes/base.dockerfile +3 -0
  81. package/lib/sandbox/shell.ts +11 -2
  82. package/lib/sandbox/tools.ts +5 -5
  83. package/lib/server/adapters/_contract.ts +3 -0
  84. package/lib/server/adapters/feishu/index.ts +11 -3
  85. package/lib/server/adapters/feishu/renderer.ts +99 -0
  86. package/lib/server/adapters/feishu/transport.ts +5 -18
  87. package/lib/server/daemon.ts +74 -38
  88. package/lib/server/display.ts +136 -0
  89. package/lib/server/streamer.ts +5 -4
  90. package/lib/task/commands/log.ts +3 -3
  91. package/lib/task/commands/status.ts +102 -21
  92. package/lib/task/workflow-warnings.ts +121 -0
  93. package/package.json +2 -2
  94. package/templates/.agents/README.en.md +3 -0
  95. package/templates/.agents/README.zh-CN.md +3 -0
  96. package/templates/.agents/rules/create-issue.github.en.md +4 -4
  97. package/templates/.agents/rules/create-issue.github.zh-CN.md +4 -4
  98. package/templates/.agents/rules/issue-pr-commands.github.en.md +7 -2
  99. package/templates/.agents/rules/issue-pr-commands.github.zh-CN.md +7 -2
  100. package/templates/.agents/rules/issue-sync.github.en.md +13 -0
  101. package/templates/.agents/rules/issue-sync.github.zh-CN.md +13 -0
  102. package/templates/.agents/rules/next-step-output.en.md +15 -1
  103. package/templates/.agents/rules/next-step-output.zh-CN.md +15 -1
  104. package/templates/.agents/rules/pr-sync.github.en.md +17 -2
  105. package/templates/.agents/rules/pr-sync.github.zh-CN.md +17 -2
  106. package/templates/.agents/rules/review-handshake.en.md +2 -2
  107. package/templates/.agents/rules/review-handshake.zh-CN.md +2 -2
  108. package/templates/.agents/rules/task-management.en.md +1 -1
  109. package/templates/.agents/rules/task-management.zh-CN.md +1 -1
  110. package/templates/.agents/rules/testing-discipline.en.md +3 -41
  111. package/templates/.agents/rules/testing-discipline.zh-CN.md +3 -41
  112. package/templates/.agents/scripts/platform-adapters/platform-sync.github.js +57 -0
  113. package/templates/.agents/scripts/validate-artifact.js +213 -0
  114. package/templates/.agents/scripts/workflow-warnings.js +290 -0
  115. package/templates/.agents/skills/analyze-task/SKILL.en.md +1 -1
  116. package/templates/.agents/skills/analyze-task/SKILL.zh-CN.md +2 -2
  117. package/templates/.agents/skills/archive-tasks/scripts/archive-tasks.sh +1 -1
  118. package/templates/.agents/skills/block-task/SKILL.en.md +1 -1
  119. package/templates/.agents/skills/block-task/SKILL.zh-CN.md +2 -2
  120. package/templates/.agents/skills/cancel-task/SKILL.en.md +1 -1
  121. package/templates/.agents/skills/cancel-task/SKILL.zh-CN.md +2 -2
  122. package/templates/.agents/skills/check-task/SKILL.zh-CN.md +9 -9
  123. package/templates/.agents/skills/close-codescan/SKILL.en.md +1 -1
  124. package/templates/.agents/skills/close-codescan/SKILL.zh-CN.md +2 -2
  125. package/templates/.agents/skills/close-dependabot/SKILL.en.md +1 -1
  126. package/templates/.agents/skills/close-dependabot/SKILL.zh-CN.md +2 -2
  127. package/templates/.agents/skills/code-task/SKILL.en.md +1 -1
  128. package/templates/.agents/skills/code-task/SKILL.zh-CN.md +1 -1
  129. package/templates/.agents/skills/code-task/reference/branch-management.zh-CN.md +2 -2
  130. package/templates/.agents/skills/code-task/reference/fix-mode.en.md +2 -2
  131. package/templates/.agents/skills/code-task/reference/fix-mode.zh-CN.md +2 -2
  132. package/templates/.agents/skills/code-task/reference/output-template.zh-CN.md +1 -1
  133. package/templates/.agents/skills/commit/SKILL.en.md +1 -1
  134. package/templates/.agents/skills/commit/SKILL.zh-CN.md +1 -1
  135. package/templates/.agents/skills/commit/reference/task-status-update.en.md +6 -6
  136. package/templates/.agents/skills/commit/reference/task-status-update.zh-CN.md +6 -6
  137. package/templates/.agents/skills/complete-manual-validation/SKILL.en.md +142 -0
  138. package/templates/.agents/skills/complete-manual-validation/SKILL.zh-CN.md +142 -0
  139. package/templates/.agents/skills/complete-manual-validation/config/verify.en.json +49 -0
  140. package/templates/.agents/skills/complete-manual-validation/config/verify.zh-CN.json +49 -0
  141. package/templates/.agents/skills/complete-manual-validation/reference/report-template.en.md +48 -0
  142. package/templates/.agents/skills/complete-manual-validation/reference/report-template.zh-CN.md +48 -0
  143. package/templates/.agents/skills/complete-manual-validation/reference/summary-update.en.md +60 -0
  144. package/templates/.agents/skills/complete-manual-validation/reference/summary-update.zh-CN.md +87 -0
  145. package/templates/.agents/skills/complete-task/SKILL.en.md +1 -1
  146. package/templates/.agents/skills/complete-task/SKILL.zh-CN.md +1 -1
  147. package/templates/.agents/skills/create-pr/SKILL.en.md +6 -4
  148. package/templates/.agents/skills/create-pr/SKILL.zh-CN.md +6 -4
  149. package/templates/.agents/skills/create-pr/reference/pr-body-template.en.md +1 -1
  150. package/templates/.agents/skills/create-pr/reference/pr-body-template.zh-CN.md +1 -1
  151. package/templates/.agents/skills/create-task/SKILL.en.md +6 -3
  152. package/templates/.agents/skills/create-task/SKILL.zh-CN.md +9 -6
  153. package/templates/.agents/skills/import-codescan/SKILL.en.md +2 -2
  154. package/templates/.agents/skills/import-codescan/SKILL.zh-CN.md +3 -3
  155. package/templates/.agents/skills/import-dependabot/SKILL.en.md +2 -2
  156. package/templates/.agents/skills/import-dependabot/SKILL.zh-CN.md +3 -3
  157. package/templates/.agents/skills/import-issue/SKILL.en.md +2 -2
  158. package/templates/.agents/skills/import-issue/SKILL.zh-CN.md +3 -3
  159. package/templates/.agents/skills/init-labels/SKILL.zh-CN.md +1 -1
  160. package/templates/.agents/skills/init-milestones/SKILL.en.md +3 -2
  161. package/templates/.agents/skills/init-milestones/SKILL.zh-CN.md +4 -3
  162. package/templates/.agents/skills/init-milestones/scripts/init-milestones.github.sh +165 -41
  163. package/templates/.agents/skills/plan-task/SKILL.en.md +1 -1
  164. package/templates/.agents/skills/plan-task/SKILL.zh-CN.md +2 -2
  165. package/templates/.agents/skills/restore-task/SKILL.en.md +1 -1
  166. package/templates/.agents/skills/restore-task/SKILL.zh-CN.md +1 -1
  167. package/templates/.agents/skills/review-analysis/SKILL.en.md +1 -1
  168. package/templates/.agents/skills/review-analysis/SKILL.zh-CN.md +1 -1
  169. package/templates/.agents/skills/review-analysis/reference/output-templates.en.md +5 -5
  170. package/templates/.agents/skills/review-analysis/reference/output-templates.zh-CN.md +5 -5
  171. package/templates/.agents/skills/review-code/SKILL.en.md +8 -4
  172. package/templates/.agents/skills/review-code/SKILL.zh-CN.md +6 -3
  173. package/templates/.agents/skills/review-code/config/verify.en.json +1 -0
  174. package/templates/.agents/skills/review-code/config/verify.zh-CN.json +1 -0
  175. package/templates/.agents/skills/review-code/reference/output-templates.en.md +5 -5
  176. package/templates/.agents/skills/review-code/reference/output-templates.zh-CN.md +5 -5
  177. package/templates/.agents/skills/review-code/reference/report-template.en.md +2 -2
  178. package/templates/.agents/skills/review-code/reference/report-template.zh-CN.md +2 -2
  179. package/templates/.agents/skills/review-plan/SKILL.en.md +1 -1
  180. package/templates/.agents/skills/review-plan/SKILL.zh-CN.md +1 -1
  181. package/templates/.agents/skills/review-plan/reference/output-templates.en.md +5 -5
  182. package/templates/.agents/skills/review-plan/reference/output-templates.zh-CN.md +5 -5
  183. package/templates/.agents/skills/test/SKILL.zh-CN.md +26 -8
  184. package/templates/.agents/skills/update-agent-infra/SKILL.zh-CN.md +1 -1
  185. package/templates/.agents/skills/update-agent-infra/scripts/sync-templates.js +36 -6
  186. package/templates/.agents/skills/watch-pr/SKILL.en.md +2 -2
  187. package/templates/.agents/skills/watch-pr/SKILL.zh-CN.md +2 -2
  188. package/templates/.agents/skills/watch-pr/reference/monitor-and-heal.en.md +8 -1
  189. package/templates/.agents/skills/watch-pr/reference/monitor-and-heal.zh-CN.md +8 -1
  190. package/templates/.agents/templates/task.en.md +7 -0
  191. package/templates/.agents/templates/task.zh-CN.md +7 -0
  192. package/templates/.claude/commands/complete-manual-validation.en.md +9 -0
  193. package/templates/.claude/commands/complete-manual-validation.zh-CN.md +9 -0
  194. package/templates/.gemini/commands/_project_/complete-manual-validation.en.toml +8 -0
  195. package/templates/.gemini/commands/_project_/complete-manual-validation.zh-CN.toml +8 -0
  196. package/templates/.github/workflows/metadata-sync.yml +5 -0
  197. package/templates/.opencode/commands/complete-manual-validation.en.md +11 -0
  198. package/templates/.opencode/commands/complete-manual-validation.zh-CN.md +11 -0
@@ -21,7 +21,7 @@ description: >
21
21
 
22
22
  ## 步骤开始:记录开始时间
23
23
 
24
- 本技能会**创建** task.md,开始时尚无文件可写。先在内存记录开始时间 `started_at`(`date "+%Y-%m-%d %H:%M:%S%:z"`);在最后写活动日志时**一次性补两条**——started 行用 `started_at`、done 行用完成时间,二者同基名(started 行 action 加 ` [started]` 后缀、note 用 `started`)。基名必须跟实际导入场景一致:
24
+ 本技能会**创建** task.md,开始时尚无文件可写。先在内存记录开始时间 `started_at`(`date "+%Y-%m-%d %H:%M:%S%z" | sed 's/\([+-][0-9][0-9]\)\([0-9][0-9]\)$/\1:\2/'`);在最后写活动日志时**一次性补两条**——started 行用 `started_at`、done 行用完成时间,二者同基名(started 行 action 加 ` [started]` 后缀、note 用 `started`)。基名必须跟实际导入场景一致:
25
25
 
26
26
  ```
27
27
  # 场景 B:新 Issue 导入
@@ -127,7 +127,7 @@ assigned_to: {当前 AI 代理}
127
127
  获取当前时间:
128
128
 
129
129
  ```bash
130
- date "+%Y-%m-%d %H:%M:%S%:z"
130
+ date "+%Y-%m-%d %H:%M:%S%z" | sed 's/\([+-][0-9][0-9]\)\([0-9][0-9]\)$/\1:\2/'
131
131
  ```
132
132
 
133
133
  更新 `.agents/workspace/active/{task-id}/task.md`:
@@ -195,7 +195,7 @@ Issue #{number} 已导入。
195
195
 
196
196
  下一步 - 执行需求分析:
197
197
  - Claude Code / OpenCode:/analyze-task {task-ref}
198
- - Gemini CLI:/agent-infra:analyze-task {task-ref}
198
+ - Gemini CLI:/{{project}}:analyze-task {task-ref}
199
199
  - Codex CLI:$analyze-task {task-ref}
200
200
  ```
201
201
 
@@ -94,7 +94,7 @@ bash .agents/skills/init-labels/scripts/init-labels.sh
94
94
  ```
95
95
  下一步 - 初始化 Milestones(可选):
96
96
  - Claude Code / OpenCode:/init-milestones
97
- - Gemini CLI:/agent-infra:init-milestones
97
+ - Gemini CLI:/{{project}}:init-milestones
98
98
  - Codex CLI:$init-milestones
99
99
  ```
100
100
 
@@ -30,7 +30,7 @@ bash .agents/skills/init-milestones/scripts/init-milestones.sh "$ARGUMENTS"
30
30
  The script and `.agents/rules/label-milestone-setup.md` are responsible for:
31
31
  - Creating and cleaning up a temporary workspace
32
32
  - Detecting whether `--history` was requested
33
- - Resolving the version baseline from the latest `v*` Git tag, then `package.json`, then defaulting to `0.1.0`
33
+ - Scanning all `v*` Git tags, selecting the highest valid version by SemVer precedence, and using compatibility default `0.1.0` when none is valid, without reading ecosystem manifests
34
34
  - Listing current milestones with the platform-specific milestone query command
35
35
  - Building the desired milestone set and creating only the missing titles
36
36
  - Printing the final execution summary
@@ -50,6 +50,7 @@ When `--history` is present, each historical `vX.Y.Z` tag additionally contribut
50
50
 
51
51
  The summary must include:
52
52
  - Version baseline
53
+ - Version baseline source
53
54
  - Whether `--history` was enabled
54
55
  - Created and skipped milestone counts
55
56
  - Newly created milestone titles
@@ -81,6 +82,6 @@ Next step - initialize labels (optional):
81
82
  - Authentication failed: prompt "the platform CLI is not authenticated"
82
83
  - Repository access failed: prompt "Unable to access the current repository with the platform CLI"
83
84
  - Version detection failed: prompt "Unable to determine current version baseline"
84
- - No `v*` tags found in `--history` mode: prompt "No history tags found matching v*; only standard milestones will be created"
85
+ - No valid SemVer `v*` tags found in `--history` mode: prompt "No valid SemVer history tags found matching v*; only standard milestones will be created"
85
86
  - Permission error: prompt "No permission to manage milestones in this repository"
86
87
  - API rate limit: prompt "platform API rate limit reached, please retry later"
@@ -30,7 +30,7 @@ bash .agents/skills/init-milestones/scripts/init-milestones.sh "$ARGUMENTS"
30
30
  脚本与 `.agents/rules/label-milestone-setup.md` 共同负责:
31
31
  - 创建并清理临时工作目录
32
32
  - 检测是否传入 `--history`
33
- - 按“最新 `v*` Git tag `package.json` 默认 `0.1.0`”解析版本基线
33
+ - 扫描所有 `v*` Git tag,按 SemVer precedence 选择最高合法版本;没有合法版本时使用兼容默认值 `0.1.0`,且不读取任何生态 manifest
34
34
  - 使用平台对应的 milestones 查询命令读取当前里程碑
35
35
  - 构建目标里程碑集合,并且只创建缺失标题
36
36
  - 输出最终执行摘要
@@ -50,6 +50,7 @@ bash .agents/skills/init-milestones/scripts/init-milestones.sh "$ARGUMENTS"
50
50
 
51
51
  摘要必须包含:
52
52
  - 版本基线
53
+ - 版本基线来源
53
54
  - 是否启用 `--history`
54
55
  - 创建与跳过的里程碑数量
55
56
  - 新创建的里程碑标题
@@ -71,7 +72,7 @@ bash .agents/skills/init-milestones/scripts/init-milestones.sh "$ARGUMENTS"
71
72
  ```
72
73
  下一步 - 初始化 Labels(可选):
73
74
  - Claude Code / OpenCode:/init-labels
74
- - Gemini CLI:/agent-infra:init-labels
75
+ - Gemini CLI:/{{project}}:init-labels
75
76
  - Codex CLI:$init-labels
76
77
  ```
77
78
 
@@ -81,6 +82,6 @@ bash .agents/skills/init-milestones/scripts/init-milestones.sh "$ARGUMENTS"
81
82
  - 认证失败:提示 "the platform CLI is not authenticated"
82
83
  - 仓库访问失败:提示 "Unable to access the current repository with the platform CLI"
83
84
  - 版本解析失败:提示 "Unable to determine current version baseline"
84
- - `--history` 模式下未找到任何 `v*` git tags:提示 "No history tags found matching v*; only standard milestones will be created"
85
+ - `--history` 模式下未找到合法 SemVer `v*` git tags:提示 "No valid SemVer history tags found matching v*; only standard milestones will be created"
85
86
  - 权限不足:提示 "No permission to manage milestones in this repository"
86
87
  - API 限流:提示 "platform API rate limit reached, please retry later"
@@ -33,34 +33,171 @@ esac
33
33
 
34
34
  echo "History mode: $history_mode"
35
35
 
36
- current_version=""
37
- latest_tag="$(git tag --list 'v*' --sort=-v:refname | head -1)"
38
-
39
- if [ -n "$latest_tag" ]; then
40
- current_version="${latest_tag#v}"
41
- elif [ -f package.json ]; then
42
- current_version="$(node -p "const version = require('./package.json').version || ''; version.replace(/^v/, '').replace(/-.*/, '')")"
43
- fi
44
-
45
- if [ -z "$current_version" ]; then
46
- current_version="0.1.0"
47
- fi
48
-
49
- major="${current_version%%.*}"
50
- rest="${current_version#*.}"
51
- minor="${rest%%.*}"
52
- patch="${rest#*.}"
53
- patch="${patch%%[^0-9]*}"
36
+ parse_semver_tags() {
37
+ LC_ALL=C awk -v mode="$1" '
38
+ function valid_core_number(value) {
39
+ return value ~ /^(0|[1-9][0-9]*)$/
40
+ }
41
+
42
+ function valid_identifiers(value, prerelease, count, index_, identifiers) {
43
+ if (value == "") return 0
44
+ count = split(value, identifiers, ".")
45
+ for (index_ = 1; index_ <= count; index_++) {
46
+ if (identifiers[index_] !~ /^[0-9A-Za-z-]+$/) return 0
47
+ if (prerelease && identifiers[index_] ~ /^[0-9]+$/ && identifiers[index_] !~ /^(0|[1-9][0-9]*)$/) return 0
48
+ }
49
+ return 1
50
+ }
51
+
52
+ function parse_version(tag, version, main, core, plus_at, dash_at, count) {
53
+ if (substr(tag, 1, 1) != "v") return 0
54
+ version = substr(tag, 2)
55
+ main = version
56
+ parsed_build = ""
57
+ plus_at = index(main, "+")
58
+ if (plus_at > 0) {
59
+ parsed_build = substr(main, plus_at + 1)
60
+ main = substr(main, 1, plus_at - 1)
61
+ if (!valid_identifiers(parsed_build, 0)) return 0
62
+ }
63
+
64
+ parsed_prerelease = ""
65
+ dash_at = index(main, "-")
66
+ if (dash_at > 0) {
67
+ parsed_prerelease = substr(main, dash_at + 1)
68
+ main = substr(main, 1, dash_at - 1)
69
+ if (!valid_identifiers(parsed_prerelease, 1)) return 0
70
+ }
71
+
72
+ count = split(main, core, ".")
73
+ if (count != 3) return 0
74
+ if (!valid_core_number(core[1]) || !valid_core_number(core[2]) || !valid_core_number(core[3])) return 0
75
+
76
+ parsed_tag = tag
77
+ parsed_major = core[1]
78
+ parsed_minor = core[2]
79
+ parsed_patch = core[3]
80
+ return 1
81
+ }
82
+
83
+ function compare_decimal(left, right, index_, left_digit, right_digit) {
84
+ if (length(left) != length(right)) return length(left) > length(right) ? 1 : -1
85
+ for (index_ = 1; index_ <= length(left); index_++) {
86
+ left_digit = substr(left, index_, 1) + 0
87
+ right_digit = substr(right, index_, 1) + 0
88
+ if (left_digit != right_digit) return left_digit > right_digit ? 1 : -1
89
+ }
90
+ return 0
91
+ }
92
+
93
+ function compare_ascii(left, right, alphabet, limit, index_, left_rank, right_rank) {
94
+ alphabet = "+-.0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"
95
+ limit = length(left) < length(right) ? length(left) : length(right)
96
+ for (index_ = 1; index_ <= limit; index_++) {
97
+ left_rank = index(alphabet, substr(left, index_, 1))
98
+ right_rank = index(alphabet, substr(right, index_, 1))
99
+ if (left_rank != right_rank) return left_rank > right_rank ? 1 : -1
100
+ }
101
+ if (length(left) == length(right)) return 0
102
+ return length(left) > length(right) ? 1 : -1
103
+ }
104
+
105
+ function compare_prerelease(left, right, left_count, right_count, limit, index_, comparison, left_numeric, right_numeric, left_ids, right_ids) {
106
+ if (left == "" || right == "") {
107
+ if (left == right) return 0
108
+ return left == "" ? 1 : -1
109
+ }
110
+
111
+ left_count = split(left, left_ids, ".")
112
+ right_count = split(right, right_ids, ".")
113
+ limit = left_count < right_count ? left_count : right_count
114
+ for (index_ = 1; index_ <= limit; index_++) {
115
+ left_numeric = left_ids[index_] ~ /^[0-9]+$/
116
+ right_numeric = right_ids[index_] ~ /^[0-9]+$/
117
+ if (left_numeric && right_numeric) {
118
+ comparison = compare_decimal(left_ids[index_], right_ids[index_])
119
+ } else if (left_numeric != right_numeric) {
120
+ comparison = left_numeric ? -1 : 1
121
+ } else {
122
+ comparison = compare_ascii(left_ids[index_], right_ids[index_])
123
+ }
124
+ if (comparison != 0) return comparison
125
+ }
126
+
127
+ if (left_count == right_count) return 0
128
+ return left_count > right_count ? 1 : -1
129
+ }
130
+
131
+ function candidate_is_higher( comparison) {
132
+ comparison = compare_decimal(parsed_major, best_major)
133
+ if (comparison != 0) return comparison > 0
134
+ comparison = compare_decimal(parsed_minor, best_minor)
135
+ if (comparison != 0) return comparison > 0
136
+ comparison = compare_decimal(parsed_patch, best_patch)
137
+ if (comparison != 0) return comparison > 0
138
+ comparison = compare_prerelease(parsed_prerelease, best_prerelease)
139
+ if (comparison != 0) return comparison > 0
140
+ return compare_ascii(parsed_tag, best_tag) > 0
141
+ }
142
+
143
+ function increment_decimal(value, index_, digit, output) {
144
+ output = ""
145
+ for (index_ = length(value); index_ >= 1; index_--) {
146
+ digit = substr(value, index_, 1) + 0
147
+ if (digit < 9) return substr(value, 1, index_ - 1) (digit + 1) output
148
+ output = "0" output
149
+ }
150
+ return "1" output
151
+ }
152
+
153
+ parse_version($0) {
154
+ if (mode == "history") {
155
+ printf "%s\t%s\t%s\n", parsed_major, parsed_minor, parsed_patch
156
+ next
157
+ }
158
+
159
+ if (!have_best || candidate_is_higher()) {
160
+ have_best = 1
161
+ best_tag = parsed_tag
162
+ best_major = parsed_major
163
+ best_minor = parsed_minor
164
+ best_patch = parsed_patch
165
+ best_prerelease = parsed_prerelease
166
+ }
167
+ }
168
+
169
+ END {
170
+ if (mode == "history") exit
171
+ if (!have_best) {
172
+ best_tag = "-"
173
+ best_major = "0"
174
+ best_minor = "1"
175
+ best_patch = "0"
176
+ }
177
+ printf "%s\t%s\t%s\t%s\t%s\n", best_tag, best_major, best_minor, best_patch, increment_decimal(best_patch)
178
+ }
179
+ '
180
+ }
181
+
182
+ selection="$(git tag --list 'v*' | parse_semver_tags select)"
183
+ previous_ifs="$IFS"
184
+ IFS="$(printf '\t')" read -r selected_tag major minor patch next_patch <<EOF
185
+ $selection
186
+ EOF
187
+ IFS="$previous_ifs"
54
188
 
55
- if ! printf '%s %s %s\n' "$major" "$minor" "$patch" | grep -Eq '^[0-9]+ [0-9]+ [0-9]+$'; then
56
- echo "Unable to determine current version baseline"
57
- exit 1
189
+ current_version="$major.$minor.$patch"
190
+ if [ "$selected_tag" = "-" ]; then
191
+ version_source="compatibility default"
192
+ else
193
+ version_source="git tag $selected_tag"
58
194
  fi
59
195
 
60
196
  line_milestone="$major.$minor.x"
61
- next_version="$major.$minor.$((patch + 1))"
197
+ next_version="$major.$minor.$next_patch"
62
198
 
63
199
  echo "Detected version baseline: $current_version"
200
+ echo "Version baseline source: $version_source"
64
201
  echo "Line milestone: $line_milestone"
65
202
  echo "Next version milestone: $next_version"
66
203
 
@@ -80,26 +217,12 @@ $next_version Issues that we want to release in v$next_version. open
80
217
  EOF
81
218
 
82
219
  if [ "$history_mode" = "true" ]; then
83
- git tag --list 'v*' --sort=v:refname > "$tmpdir/history-tags.txt"
220
+ git tag --list 'v*' | parse_semver_tags history > "$tmpdir/history-versions.tsv"
84
221
 
85
- if [ ! -s "$tmpdir/history-tags.txt" ]; then
86
- echo "No history tags found matching v*; only standard milestones will be created."
222
+ if [ ! -s "$tmpdir/history-versions.tsv" ]; then
223
+ echo "No valid SemVer history tags found matching v*; only standard milestones will be created."
87
224
  else
88
- while IFS= read -r tag; do
89
- [ -n "$tag" ] || continue
90
-
91
- ver="${tag#v}"
92
- h_major="${ver%%.*}"
93
- h_rest="${ver#*.}"
94
- h_minor="${h_rest%%.*}"
95
- h_patch="${h_rest#*.}"
96
- h_patch="${h_patch%%[^0-9]*}"
97
-
98
- if ! printf '%s %s %s\n' "$h_major" "$h_minor" "$h_patch" | grep -Eq '^[0-9]+ [0-9]+ [0-9]+$'; then
99
- echo "Skip non-semver tag: $tag"
100
- continue
101
- fi
102
-
225
+ while IFS="$(printf '\t')" read -r h_major h_minor h_patch; do
103
226
  printf '%s\t%s\t%s\n' \
104
227
  "$h_major.$h_minor.x" \
105
228
  "Issues that we want to resolve in $h_major.$h_minor line." \
@@ -109,7 +232,7 @@ if [ "$history_mode" = "true" ]; then
109
232
  "$h_major.$h_minor.$h_patch" \
110
233
  "Issues that we want to release in v$h_major.$h_minor.$h_patch." \
111
234
  "closed" >> "$tmpdir/desired.tsv"
112
- done < "$tmpdir/history-tags.txt"
235
+ done < "$tmpdir/history-versions.tsv"
113
236
  fi
114
237
  fi
115
238
 
@@ -143,6 +266,7 @@ echo "GitHub Milestones initialized."
143
266
  echo
144
267
  echo "Summary:"
145
268
  echo "- Version baseline: $current_version"
269
+ echo "- Version baseline source: $version_source"
146
270
  echo "- History mode: $history_mode"
147
271
  echo "- Created milestones: $created_count"
148
272
  echo "- Skipped existing milestones: $skipped_count"
@@ -117,7 +117,7 @@ Create `.agents/workspace/active/{task-id}/{plan-artifact}`.
117
117
  Get the current time:
118
118
 
119
119
  ```bash
120
- date "+%Y-%m-%d %H:%M:%S%:z"
120
+ date "+%Y-%m-%d %H:%M:%S%z" | sed 's/\([+-][0-9][0-9]\)\([0-9][0-9]\)$/\1:\2/'
121
121
  ```
122
122
 
123
123
  Update `.agents/workspace/active/{task-id}/task.md`:
@@ -116,7 +116,7 @@ tail .agents/workspace/active/{task-id}/task.md
116
116
  获取当前时间:
117
117
 
118
118
  ```bash
119
- date "+%Y-%m-%d %H:%M:%S%:z"
119
+ date "+%Y-%m-%d %H:%M:%S%z" | sed 's/\([+-][0-9][0-9]\)\([0-9][0-9]\)$/\1:\2/'
120
120
  ```
121
121
 
122
122
  更新 `.agents/workspace/active/{task-id}/task.md`:
@@ -183,7 +183,7 @@ node .agents/scripts/validate-artifact.js gate plan-task .agents/workspace/activ
183
183
 
184
184
  下一步 - 审查技术方案:
185
185
  - Claude Code / OpenCode:/review-plan {task-ref}
186
- - Gemini CLI:/agent-infra:review-plan {task-ref}
186
+ - Gemini CLI:/{{project}}:review-plan {task-ref}
187
187
  - Codex CLI:$review-plan {task-ref}
188
188
  ```
189
189
 
@@ -95,7 +95,7 @@ Write only files that were actually recovered from Issue comments. Do not invent
95
95
  Get the current time:
96
96
 
97
97
  ```bash
98
- date "+%Y-%m-%d %H:%M:%S%:z"
98
+ date "+%Y-%m-%d %H:%M:%S%z" | sed 's/\([+-][0-9][0-9]\)\([0-9][0-9]\)$/\1:\2/'
99
99
  ```
100
100
 
101
101
  Update the restored `task.md`:
@@ -94,7 +94,7 @@ description: >
94
94
  获取当前时间:
95
95
 
96
96
  ```bash
97
- date "+%Y-%m-%d %H:%M:%S%:z"
97
+ date "+%Y-%m-%d %H:%M:%S%z" | sed 's/\([+-][0-9][0-9]\)\([0-9][0-9]\)$/\1:\2/'
98
98
  ```
99
99
 
100
100
  更新恢复出的 `task.md`:
@@ -73,7 +73,7 @@ Create `.agents/workspace/active/{task-id}/{review-artifact}`.
73
73
  Get the current time:
74
74
 
75
75
  ```bash
76
- date "+%Y-%m-%d %H:%M:%S%:z"
76
+ date "+%Y-%m-%d %H:%M:%S%z" | sed 's/\([+-][0-9][0-9]\)\([0-9][0-9]\)$/\1:\2/'
77
77
  ```
78
78
 
79
79
  Set `current_step` to `requirement-analysis-review`, refresh task metadata, and append:
@@ -79,7 +79,7 @@ tail .agents/workspace/active/{task-id}/task.md
79
79
  获取当前时间:
80
80
 
81
81
  ```bash
82
- date "+%Y-%m-%d %H:%M:%S%:z"
82
+ date "+%Y-%m-%d %H:%M:%S%z" | sed 's/\([+-][0-9][0-9]\)\([0-9][0-9]\)$/\1:\2/'
83
83
  ```
84
84
 
85
85
  更新 task.md:
@@ -27,7 +27,7 @@ Task {task-id} requirement analysis review completed. Verdict: approved.
27
27
 
28
28
  Next step - write the technical plan:
29
29
  - Claude Code / OpenCode: /plan-task {task-ref}
30
- - Gemini CLI: /agent-infra:plan-task {task-ref}
30
+ - Gemini CLI: /{{project}}:plan-task {task-ref}
31
31
  - Codex CLI: $plan-task {task-ref}
32
32
 
33
33
  [When manual-validation > 0, append:]
@@ -43,12 +43,12 @@ Task {task-id} requirement analysis review completed. Verdict: approved.
43
43
 
44
44
  Next step - revise analysis before continuing (recommended):
45
45
  - Claude Code / OpenCode: /analyze-task {task-ref}
46
- - Gemini CLI: /agent-infra:analyze-task {task-ref}
46
+ - Gemini CLI: /{{project}}:analyze-task {task-ref}
47
47
  - Codex CLI: $analyze-task {task-ref}
48
48
 
49
49
  Or proceed directly to planning:
50
50
  - Claude Code / OpenCode: /plan-task {task-ref}
51
- - Gemini CLI: /agent-infra:plan-task {task-ref}
51
+ - Gemini CLI: /{{project}}:plan-task {task-ref}
52
52
  - Codex CLI: $plan-task {task-ref}
53
53
 
54
54
  [When manual-validation > 0, append:]
@@ -64,7 +64,7 @@ Task {task-id} requirement analysis review completed. Verdict: changes requested
64
64
 
65
65
  Next step - revise requirement analysis:
66
66
  - Claude Code / OpenCode: /analyze-task {task-ref}
67
- - Gemini CLI: /agent-infra:analyze-task {task-ref}
67
+ - Gemini CLI: /{{project}}:analyze-task {task-ref}
68
68
  - Codex CLI: $analyze-task {task-ref}
69
69
 
70
70
  [When manual-validation > 0, append:]
@@ -80,7 +80,7 @@ Task {task-id} requirement analysis review completed. Verdict: rejected, fresh a
80
80
 
81
81
  Next step - re-analyze:
82
82
  - Claude Code / OpenCode: /analyze-task {task-ref}
83
- - Gemini CLI: /agent-infra:analyze-task {task-ref}
83
+ - Gemini CLI: /{{project}}:analyze-task {task-ref}
84
84
  - Codex CLI: $analyze-task {task-ref}
85
85
 
86
86
  [When manual-validation > 0, append:]
@@ -27,7 +27,7 @@
27
27
 
28
28
  下一步 - 编写技术方案:
29
29
  - Claude Code / OpenCode:/plan-task {task-ref}
30
- - Gemini CLI:/agent-infra:plan-task {task-ref}
30
+ - Gemini CLI:/{{project}}:plan-task {task-ref}
31
31
  - Codex CLI:$plan-task {task-ref}
32
32
 
33
33
  [当 manual-validation > 0 时,在最后附加一行:]
@@ -43,12 +43,12 @@
43
43
 
44
44
  下一步 - 修订分析后继续(推荐):
45
45
  - Claude Code / OpenCode:/analyze-task {task-ref}
46
- - Gemini CLI:/agent-infra:analyze-task {task-ref}
46
+ - Gemini CLI:/{{project}}:analyze-task {task-ref}
47
47
  - Codex CLI:$analyze-task {task-ref}
48
48
 
49
49
  或直接进入方案设计:
50
50
  - Claude Code / OpenCode:/plan-task {task-ref}
51
- - Gemini CLI:/agent-infra:plan-task {task-ref}
51
+ - Gemini CLI:/{{project}}:plan-task {task-ref}
52
52
  - Codex CLI:$plan-task {task-ref}
53
53
 
54
54
  [当 manual-validation > 0 时,在最后附加一行:]
@@ -64,7 +64,7 @@
64
64
 
65
65
  下一步 - 修订需求分析:
66
66
  - Claude Code / OpenCode:/analyze-task {task-ref}
67
- - Gemini CLI:/agent-infra:analyze-task {task-ref}
67
+ - Gemini CLI:/{{project}}:analyze-task {task-ref}
68
68
  - Codex CLI:$analyze-task {task-ref}
69
69
 
70
70
  [当 manual-validation > 0 时,在最后附加一行:]
@@ -80,7 +80,7 @@
80
80
 
81
81
  下一步 - 重新分析:
82
82
  - Claude Code / OpenCode:/analyze-task {task-ref}
83
- - Gemini CLI:/agent-infra:analyze-task {task-ref}
83
+ - Gemini CLI:/{{project}}:analyze-task {task-ref}
84
84
  - Codex CLI:$analyze-task {task-ref}
85
85
 
86
86
  [当 manual-validation > 0 时,在最后附加一行:]
@@ -74,9 +74,10 @@ Read the highest-round code artifact and, if present, the highest-round fix arti
74
74
  ### 4. Perform the Review
75
75
 
76
76
  Follow `.agents/workflows/feature-development.yaml` and inspect the full change context:
77
- - `git diff --binary HEAD -- <post-review-globs>` for tracked changes
77
+ - Capture `R=$(git rev-parse HEAD)` exactly once; reuse that R for this round's report, fingerprint, and task review fact, and do not re-read HEAD later as a substitute
78
+ - `git diff --binary "$R" -- <post-review-globs>` for tracked changes
78
79
  - `git ls-files -o --exclude-standard -z -- <post-review-globs>` for untracked new files
79
- - `node .agents/scripts/review-diff-fingerprint.js worktree HEAD` for the reviewed diff fingerprint; write it into the report
80
+ - `node .agents/scripts/review-diff-fingerprint.js worktree "$R"` for the reviewed diff fingerprint; write it into the report
80
81
 
81
82
  > Detailed review criteria, severity rules, and reviewer expectations live in `reference/review-criteria.md`. Read `reference/review-criteria.md` before reviewing.
82
83
  > Test review gate: when `git diff` touches test files, read `.agents/rules/testing-discipline.md` first and check it item by item, especially "do not add negative assertions when a positive assertion already covers the behavior".
@@ -92,10 +93,13 @@ Create `.agents/workspace/active/{task-id}/{review-artifact}`.
92
93
  Get the current time:
93
94
 
94
95
  ```bash
95
- date "+%Y-%m-%d %H:%M:%S%:z"
96
+ date "+%Y-%m-%d %H:%M:%S%z" | sed 's/\([+-][0-9][0-9]\)\([0-9][0-9]\)$/\1:\2/'
96
97
  ```
97
98
 
98
- Update task.md and append:
99
+ Update task.md:
100
+ - When this round's `Overall Verdict` / `总体结论` is `Approved` / `通过`, write `last_reviewed_commit: {R}`; the presence of a worktree diff does not affect this write, and repeating the same R is idempotent
101
+ - When this round is not Approved, preserve the existing `last_reviewed_commit`; do not advance or clear it
102
+ - Append:
99
103
  `- {YYYY-MM-DD HH:mm:ss±HH:MM} — **Review Code (Round {N})** by {agent} — Verdict: {Approved/Changes Requested/Rejected}, blockers: {n}, major: {n}, minor: {n}, Manual-validation: {n} → {artifact-filename}`
100
104
 
101
105
  Always include the `Manual-validation: {n}` field in the done log, including when it is 0.
@@ -73,9 +73,10 @@ tail .agents/workspace/active/{task-id}/task.md
73
73
  ### 4. 执行审查
74
74
 
75
75
  遵循 `.agents/workflows/feature-development.yaml`,并同时检查完整变更上下文:
76
- - `git diff --binary HEAD -- <post-review-globs>` 覆盖已跟踪变更
76
+ - 一次性记录 `R=$(git rev-parse HEAD)`;本轮报告、指纹和任务审查事实都复用该 R,禁止稍后重新读取 HEAD 代替
77
+ - `git diff --binary "$R" -- <post-review-globs>` 覆盖已跟踪变更
77
78
  - `git ls-files -o --exclude-standard -z -- <post-review-globs>` 覆盖未跟踪新文件
78
- - `node .agents/scripts/review-diff-fingerprint.js worktree HEAD` 生成审查差异指纹,并写入报告
79
+ - `node .agents/scripts/review-diff-fingerprint.js worktree "$R"` 生成审查差异指纹,并写入报告
79
80
 
80
81
  > 详细审查标准、严重程度划分和 reviewer 关注点见 `reference/review-criteria.md`。执行此步骤前先读取 `reference/review-criteria.md`。
81
82
  > 测试审查硬门禁:当 `git diff` 触及测试文件时,必须先读取 `.agents/rules/testing-discipline.md` 并逐条核对(尤其"正向已覆盖时不应再加反向断言")。
@@ -91,13 +92,15 @@ tail .agents/workspace/active/{task-id}/task.md
91
92
  获取当前时间:
92
93
 
93
94
  ```bash
94
- date "+%Y-%m-%d %H:%M:%S%:z"
95
+ date "+%Y-%m-%d %H:%M:%S%z" | sed 's/\([+-][0-9][0-9]\)\([0-9][0-9]\)$/\1:\2/'
95
96
  ```
96
97
 
97
98
  - `current_step`:code-review
98
99
  - `assigned_to`:{当前代理}
99
100
  - `updated_at`:{当前时间}
100
101
  - `agent_infra_version`:按 `.agents/rules/version-stamp.md` 取值
102
+ - 若本轮 `总体结论` / `Overall Verdict` 为 `通过` / `Approved`,写入 `last_reviewed_commit: {R}`;是否存在工作区 diff 不影响写入,重复写同一 R 幂等
103
+ - 若本轮结论不是 Approved,保留既有 `last_reviewed_commit`,不得推进或清空
101
104
  - 追加:
102
105
  `- {YYYY-MM-DD HH:mm:ss±HH:MM} — **Review Code (Round {N})** by {agent} — Verdict: {Approved/Changes Requested/Rejected}, blockers: {n}, major: {n}, minor: {n}, Manual-validation: {n} → {artifact-filename}`
103
106
 
@@ -36,6 +36,7 @@
36
36
  ],
37
37
  "freshness_minutes": 30
38
38
  },
39
+ "review-fact": {},
39
40
  "activity-log": {
40
41
  "expected_action_pattern": "(Review Code|Code Review) \\(Round \\d+\\)",
41
42
  "freshness_minutes": 30
@@ -36,6 +36,7 @@
36
36
  ],
37
37
  "freshness_minutes": 30
38
38
  },
39
+ "review-fact": {},
39
40
  "activity-log": {
40
41
  "expected_action_pattern": "(Review Code|Code Review) \\(Round \\d+\\)",
41
42
  "freshness_minutes": 30
@@ -29,7 +29,7 @@ Task {task-id} review completed. Verdict: approved.
29
29
 
30
30
  Next step - commit the code:
31
31
  - Claude Code / OpenCode: /commit
32
- - Gemini CLI: /agent-infra:commit
32
+ - Gemini CLI: /{{project}}:commit
33
33
  - Codex CLI: $commit
34
34
 
35
35
  [When manual-validation > 0, append this final line:]
@@ -45,12 +45,12 @@ Task {task-id} review completed. Verdict: approved.
45
45
 
46
46
  Next step - fix before commit (recommended):
47
47
  - Claude Code / OpenCode: /code-task {task-ref}
48
- - Gemini CLI: /agent-infra:code-task {task-ref}
48
+ - Gemini CLI: /{{project}}:code-task {task-ref}
49
49
  - Codex CLI: $code-task {task-ref}
50
50
 
51
51
  Or commit directly (skip fix):
52
52
  - Claude Code / OpenCode: /commit
53
- - Gemini CLI: /agent-infra:commit
53
+ - Gemini CLI: /{{project}}:commit
54
54
  - Codex CLI: $commit
55
55
 
56
56
  [When manual-validation > 0, append this final line:]
@@ -66,7 +66,7 @@ Task {task-id} review completed. Verdict: changes requested.
66
66
 
67
67
  Next step - fix the findings:
68
68
  - Claude Code / OpenCode: /code-task {task-ref}
69
- - Gemini CLI: /agent-infra:code-task {task-ref}
69
+ - Gemini CLI: /{{project}}:code-task {task-ref}
70
70
  - Codex CLI: $code-task {task-ref}
71
71
 
72
72
  [When manual-validation > 0, append this final line:]
@@ -82,7 +82,7 @@ Task {task-id} review completed. Verdict: rejected, re-design the technical plan
82
82
 
83
83
  Next step - re-design the technical plan:
84
84
  - Claude Code / OpenCode: /plan-task {task-ref}
85
- - Gemini CLI: /agent-infra:plan-task {task-ref}
85
+ - Gemini CLI: /{{project}}:plan-task {task-ref}
86
86
  - Codex CLI: $plan-task {task-ref}
87
87
 
88
88
  > Note: Rejected means the implementation direction needs to be reworked end-to-end, not patched locally. `code-task/scripts/detect-mode.js` branch #7 refuses a direct `/code-task` and requires a fresh plan first.
@@ -29,7 +29,7 @@
29
29
 
30
30
  下一步 - 提交代码:
31
31
  - Claude Code / OpenCode:/commit
32
- - Gemini CLI:/agent-infra:commit
32
+ - Gemini CLI:/{{project}}:commit
33
33
  - Codex CLI:$commit
34
34
 
35
35
  [当 manual-validation > 0 时,在最后附加一行:]
@@ -45,12 +45,12 @@
45
45
 
46
46
  下一步 - 修复问题后提交(推荐):
47
47
  - Claude Code / OpenCode:/code-task {task-ref}
48
- - Gemini CLI:/agent-infra:code-task {task-ref}
48
+ - Gemini CLI:/{{project}}:code-task {task-ref}
49
49
  - Codex CLI:$code-task {task-ref}
50
50
 
51
51
  或直接提交(跳过修复):
52
52
  - Claude Code / OpenCode:/commit
53
- - Gemini CLI:/agent-infra:commit
53
+ - Gemini CLI:/{{project}}:commit
54
54
  - Codex CLI:$commit
55
55
 
56
56
  [当 manual-validation > 0 时,在最后附加一行:]
@@ -66,7 +66,7 @@
66
66
 
67
67
  下一步 - 修复问题:
68
68
  - Claude Code / OpenCode:/code-task {task-ref}
69
- - Gemini CLI:/agent-infra:code-task {task-ref}
69
+ - Gemini CLI:/{{project}}:code-task {task-ref}
70
70
  - Codex CLI:$code-task {task-ref}
71
71
 
72
72
  [当 manual-validation > 0 时,在最后附加一行:]
@@ -82,7 +82,7 @@
82
82
 
83
83
  下一步 - 重新设计技术方案:
84
84
  - Claude Code / OpenCode:/plan-task {task-ref}
85
- - Gemini CLI:/agent-infra:plan-task {task-ref}
85
+ - Gemini CLI:/{{project}}:plan-task {task-ref}
86
86
  - Codex CLI:$plan-task {task-ref}
87
87
 
88
88
  > 注意:Rejected 表示实现方向需要整体重做,不是局部修复。`code-task/scripts/detect-mode.js` 分支 #7 会拒绝直接 `/code-task`,要求先重新方案设计。