@fitlab-ai/agent-infra 0.11.3 → 0.11.5
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/README.md +17 -8
- package/README.zh-CN.md +17 -8
- package/dist/bin/internal-cli.js +1 -6
- package/dist/lib/decide.js +4 -41
- package/dist/lib/git/branch-worktree.js +45 -0
- package/dist/lib/internal/cli-route-inventory.js +1 -4
- package/dist/lib/internal/task-activity.js +7 -40
- package/dist/lib/internal/task-artifact.js +1 -1
- package/dist/lib/internal/task-event.js +4 -37
- package/dist/lib/internal/task-finalization.js +48 -1
- package/dist/lib/internal/task-ledger.js +14 -44
- package/dist/lib/internal/task-lifecycle.js +1 -1
- package/dist/lib/internal/task-operation-registry.js +2 -4
- package/dist/lib/internal/task-review.js +5 -37
- package/dist/lib/internal/task-verify.js +3 -47
- package/dist/lib/internal/task-warning.js +4 -40
- package/dist/lib/platform/completion-backfill.js +63 -17
- package/dist/lib/platform/pr-summary.js +4 -23
- package/dist/lib/platform/verification-sync.js +12 -49
- package/dist/lib/sandbox/control/client.js +4 -1
- package/dist/lib/sandbox/control/executor.js +12 -4
- package/dist/lib/sandbox/control/protocol.js +2 -1
- package/dist/lib/sandbox/control/server.js +26 -143
- package/dist/lib/sandbox/removal.js +15 -8
- package/dist/lib/sandbox/task-cleanup.js +13 -20
- package/dist/lib/task/activity-intent.js +1 -2
- package/dist/lib/task/artifact-command.js +11 -4
- package/dist/lib/task/artifact-lifecycle.js +217 -85
- package/dist/lib/task/artifact-operations.js +37 -28
- package/dist/lib/task/artifact-receipts.js +4 -1
- package/dist/lib/task/artifact-schema.js +8 -7
- package/dist/lib/task/artifact-selection.js +25 -0
- package/dist/lib/task/capabilities.js +158 -39
- package/dist/lib/task/commands/status.js +9 -2
- package/dist/lib/task/control-authority.js +12 -168
- package/dist/lib/task/decision-intents.js +14 -4
- package/dist/lib/task/delivery.js +1 -43
- package/dist/lib/task/events.js +68 -73
- package/dist/lib/task/finalization-handoff.js +92 -0
- package/dist/lib/task/finalization.js +423 -154
- package/dist/lib/task/intermediate-cleanup.js +9 -148
- package/dist/lib/task/ledger-intents.js +159 -20
- package/dist/lib/task/lifecycle-path.js +75 -0
- package/dist/lib/task/lifecycle.js +60 -11
- package/dist/lib/task/local-artifact-finalization.js +13 -47
- package/dist/lib/task/orchestration.js +17 -7
- package/dist/lib/task/review-command.js +1 -2
- package/dist/lib/task/review-finalization.js +4 -18
- package/dist/lib/task/rework-intent.js +70 -4
- package/dist/lib/task/snapshot.js +6 -6
- package/dist/lib/task/verification-engine.js +25 -30
- package/dist/lib/task/verification.js +2 -13
- package/dist/lib/task/workflow-warning-intents.js +23 -10
- package/dist/lib/task/workspace-snapshot.js +7 -2
- package/dist/lib/task/write.js +1 -2
- package/dist/lifecycle-build-manifest.json +3 -3
- package/lib/decide.ts +5 -35
- package/lib/git/branch-worktree.ts +41 -0
- package/lib/internal/cli-route-inventory.ts +1 -3
- package/lib/internal/task-activity.ts +6 -34
- package/lib/internal/task-artifact.ts +1 -1
- package/lib/internal/task-event.ts +4 -37
- package/lib/internal/task-finalization.ts +47 -1
- package/lib/internal/task-ledger.ts +15 -41
- package/lib/internal/task-lifecycle.ts +2 -2
- package/lib/internal/task-operation-registry.ts +2 -4
- package/lib/internal/task-review.ts +5 -31
- package/lib/internal/task-verify.ts +3 -39
- package/lib/internal/task-warning.ts +3 -32
- package/lib/platform/completion-backfill.ts +78 -16
- package/lib/platform/pr-summary.ts +4 -25
- package/lib/platform/verification-sync.ts +13 -53
- package/lib/sandbox/control/client.ts +5 -1
- package/lib/sandbox/control/executor.ts +13 -4
- package/lib/sandbox/control/protocol.ts +3 -2
- package/lib/sandbox/control/server.ts +21 -146
- package/lib/sandbox/removal.ts +23 -7
- package/lib/sandbox/task-cleanup.ts +12 -20
- package/lib/task/activity-intent.ts +1 -2
- package/lib/task/artifact-command.ts +14 -4
- package/lib/task/artifact-lifecycle.ts +236 -85
- package/lib/task/artifact-operations.ts +59 -28
- package/lib/task/artifact-receipts.ts +4 -1
- package/lib/task/artifact-schema.ts +10 -7
- package/lib/task/artifact-selection.ts +53 -0
- package/lib/task/capabilities.ts +154 -40
- package/lib/task/commands/status.ts +11 -2
- package/lib/task/control-authority.ts +17 -189
- package/lib/task/decision-intents.ts +11 -4
- package/lib/task/delivery.ts +1 -40
- package/lib/task/events.ts +73 -74
- package/lib/task/finalization-handoff.ts +104 -0
- package/lib/task/finalization.ts +388 -122
- package/lib/task/intermediate-cleanup.ts +9 -125
- package/lib/task/ledger-intents.ts +157 -20
- package/lib/task/lifecycle-path.ts +98 -0
- package/lib/task/lifecycle.ts +58 -13
- package/lib/task/local-artifact-finalization.ts +14 -56
- package/lib/task/orchestration.ts +26 -8
- package/lib/task/review-command.ts +2 -5
- package/lib/task/review-finalization.ts +4 -20
- package/lib/task/rework-intent.ts +75 -5
- package/lib/task/snapshot.ts +6 -6
- package/lib/task/verification-engine.ts +29 -30
- package/lib/task/verification.ts +3 -16
- package/lib/task/workflow-warning-intents.ts +20 -10
- package/lib/task/workspace-snapshot.ts +3 -2
- package/lib/task/write.ts +1 -4
- package/package.json +1 -1
- package/templates/.agents/rules/review-handshake.en.md +4 -4
- package/templates/.agents/rules/review-handshake.zh-CN.md +4 -4
- package/templates/.agents/skills/analyze-task/SKILL.en.md +21 -5
- package/templates/.agents/skills/analyze-task/SKILL.zh-CN.md +21 -5
- package/templates/.agents/skills/code-task/SKILL.en.md +14 -8
- package/templates/.agents/skills/code-task/SKILL.zh-CN.md +18 -13
- package/templates/.agents/skills/code-task/reference/code-rules.en.md +2 -2
- package/templates/.agents/skills/code-task/reference/code-rules.zh-CN.md +2 -2
- package/templates/.agents/skills/code-task/reference/dual-mode.en.md +4 -4
- package/templates/.agents/skills/code-task/reference/dual-mode.zh-CN.md +4 -4
- package/templates/.agents/skills/code-task/reference/report-template.en.md +7 -7
- package/templates/.agents/skills/code-task/reference/report-template.zh-CN.md +7 -7
- package/templates/.agents/skills/complete-manual-validation/config/verify.en.json +2 -2
- package/templates/.agents/skills/complete-manual-validation/config/verify.zh-CN.json +2 -2
- package/templates/.agents/skills/complete-manual-validation/reference/report-template.en.md +1 -3
- package/templates/.agents/skills/complete-manual-validation/reference/report-template.zh-CN.md +1 -3
- package/templates/.agents/skills/complete-task/SKILL.en.md +2 -2
- package/templates/.agents/skills/complete-task/SKILL.zh-CN.md +2 -2
- package/templates/.agents/skills/complete-task/config/verify.en.json +2 -2
- package/templates/.agents/skills/complete-task/config/verify.zh-CN.json +2 -2
- package/templates/.agents/skills/plan-task/SKILL.en.md +13 -10
- package/templates/.agents/skills/plan-task/SKILL.zh-CN.md +13 -10
- package/templates/.agents/skills/review-analysis/SKILL.en.md +5 -1
- package/templates/.agents/skills/review-analysis/SKILL.zh-CN.md +5 -1
- package/templates/.agents/skills/review-analysis/reference/report-template.en.md +3 -3
- package/templates/.agents/skills/review-analysis/reference/report-template.zh-CN.md +3 -3
- package/templates/.agents/skills/review-code/SKILL.en.md +5 -1
- package/templates/.agents/skills/review-code/SKILL.zh-CN.md +5 -1
- package/templates/.agents/skills/review-code/reference/report-template.en.md +3 -3
- package/templates/.agents/skills/review-code/reference/report-template.zh-CN.md +3 -3
- package/templates/.agents/skills/review-plan/SKILL.en.md +5 -1
- package/templates/.agents/skills/review-plan/SKILL.zh-CN.md +5 -1
- package/templates/.agents/skills/review-plan/reference/report-template.en.md +3 -3
- package/templates/.agents/skills/review-plan/reference/report-template.zh-CN.md +3 -3
- package/templates/.agents/skills/review-pr/config/verify.en.json +3 -1
- package/templates/.agents/skills/review-pr/config/verify.zh-CN.json +3 -1
- package/templates/.agents/skills/review-pr/reference/report-template.en.md +3 -3
- package/templates/.agents/skills/review-pr/reference/report-template.zh-CN.md +3 -3
- package/templates/.agents/skills/run-manual-validation/config/verify.en.json +2 -2
- package/templates/.agents/skills/run-manual-validation/config/verify.zh-CN.json +2 -2
- package/templates/.agents/skills/run-manual-validation/reference/report-template.en.md +2 -2
- package/templates/.agents/skills/run-manual-validation/reference/report-template.zh-CN.md +2 -2
- package/templates/.agents/skills/update-agent-infra/scripts/sync-templates.js +18 -2
- package/templates/.agents/templates/task.en.md +2 -2
- package/templates/.agents/templates/task.zh-CN.md +2 -2
- package/templates/.agents/workflows/bug-fix.en.yaml +11 -6
- package/templates/.agents/workflows/bug-fix.zh-CN.yaml +11 -6
- package/templates/.agents/workflows/feature-development.en.yaml +11 -6
- package/templates/.agents/workflows/feature-development.zh-CN.yaml +11 -6
- package/templates/.agents/workflows/refactoring.en.yaml +11 -6
- package/templates/.agents/workflows/refactoring.zh-CN.yaml +11 -6
- package/dist/lib/internal/task-override.js +0 -138
- package/dist/lib/sandbox/control/finalization-response.js +0 -33
- package/dist/lib/task/artifact-recovery.js +0 -476
- package/dist/lib/task/artifact-repair-intent.js +0 -181
- package/dist/lib/task/guard-override.js +0 -31
- package/dist/lib/task/human-override.js +0 -1259
- package/lib/internal/task-override.ts +0 -144
- package/lib/sandbox/control/finalization-response.ts +0 -35
- package/lib/task/artifact-recovery.ts +0 -572
- package/lib/task/artifact-repair-intent.ts +0 -227
- package/lib/task/guard-override.ts +0 -50
- package/lib/task/human-override.ts +0 -1522
|
@@ -147,16 +147,16 @@
|
|
|
147
147
|
|
|
148
148
|
## 状态核对
|
|
149
149
|
|
|
150
|
-
>
|
|
150
|
+
> 记录状态核对命令、审查范围、关键结果和未覆盖部分。
|
|
151
151
|
> 按 `.agents/rules/evidence-reporting.md` 同时记录审查范围、关键结果和未覆盖部分;正常成功不粘贴完整 stdout。
|
|
152
152
|
|
|
153
153
|
## 证据原文
|
|
154
154
|
|
|
155
|
-
> 遵循 `.agents/rules/evidence-reporting.md
|
|
155
|
+
> 遵循 `.agents/rules/evidence-reporting.md`:每条断言配对可执行命令和相称结果摘要;Blocker、失败、阻塞或争议必须保留可复现命令、准确位置和决定性摘录;无法复现的判断须降级或移入「自我质疑」。
|
|
156
156
|
|
|
157
157
|
- 断言:{verified claim}
|
|
158
158
|
```text
|
|
159
|
-
|
|
159
|
+
{command}
|
|
160
160
|
{result summary or decisive excerpt}
|
|
161
161
|
```
|
|
162
162
|
|
|
@@ -15,6 +15,10 @@ Review the latest code round and produce `review-code.md` or `review-code-r{N}.m
|
|
|
15
15
|
|
|
16
16
|
## Boundary / Critical Rules
|
|
17
17
|
|
|
18
|
+
### Path and rework
|
|
19
|
+
|
|
20
|
+
This stage consumes only the canonical path fact parsed by core from the latest valid analysis artifact; a stage omitted by that path must not create an artifact. When another Changes Requested verdict follows one completed revision-review cycle in the same stage, classify the rework before the next executor artifact and bind it to the finding, source SHA, and stable task-fact digest. A round or filename change is not new evidence.
|
|
21
|
+
|
|
18
22
|
### Persisted Report Evidence
|
|
19
23
|
|
|
20
24
|
Before generating the review report, read `.agents/rules/evidence-reporting.md`. Normal inspection records the command, scope, structured result, actual conclusion, and uncovered parts; findings, blocking conditions, or disputes retain reproducible locations and decisive excerpts, while identity fields remain exact.
|
|
@@ -67,7 +71,7 @@ Require:
|
|
|
67
71
|
|
|
68
72
|
### 2. Resolve the Artifact Context
|
|
69
73
|
|
|
70
|
-
Run `agent-infra-internal task-artifact {task-id} inspect --family review-code`. Continue only for `ready
|
|
74
|
+
Run `agent-infra-internal task-artifact {task-id} inspect --family review-code`. Continue only for `ready`. When `selection.disposition` is `reuse`, reuse `selection.artifact`, do not run started/init or write a new artifact, and continue directly to completion verification and next-step guidance. Otherwise take the latest `{code-artifact}` from `inputs` and `{review-round}` / `{review-artifact}` from `next.round` / `next.name`. Do not scan rounds or construct names in the skill. Then run the started event and verify the returned identity.
|
|
71
75
|
|
|
72
76
|
### 3. Read Implementation and Refinement Context
|
|
73
77
|
|
|
@@ -15,6 +15,10 @@ description: >
|
|
|
15
15
|
|
|
16
16
|
## 行为边界 / 关键规则
|
|
17
17
|
|
|
18
|
+
### 路径与返工
|
|
19
|
+
|
|
20
|
+
本阶段只消费核心从最新有效分析产物解析出的规范路径事实;未被所选路径包含的阶段不得创建产物。同阶段完成一次修订—复审后再次收到 Changes Requested 时,必须在下一执行产物前提交绑定 finding、来源 SHA 和稳定任务事实摘要的返工分类;轮次或文件名变化不是新证据。
|
|
21
|
+
|
|
18
22
|
### 持久化报告证据
|
|
19
23
|
|
|
20
24
|
生成审查报告时,先读取 `.agents/rules/evidence-reporting.md`。正常检视记录命令、范围、结构化结果、实际结论和未覆盖部分;finding、阻塞或争议保留可复现位置与决定性摘录,身份字段必须精确保留。
|
|
@@ -66,7 +70,7 @@ agent-infra-internal task-snapshot {task-id} --format text
|
|
|
66
70
|
|
|
67
71
|
### 2. 解析审查上下文
|
|
68
72
|
|
|
69
|
-
运行 `agent-infra-internal task-artifact {task-id} inspect --family review-code`。仅当结果为 `ready`
|
|
73
|
+
运行 `agent-infra-internal task-artifact {task-id} inspect --family review-code`。仅当结果为 `ready` 时继续。若 `selection.disposition` 为 `reuse`,复用 `selection.artifact`,不得执行 started、init 或写入新产物,并直接进入完成校验与下一步提示。其他状态从 `inputs` 取得最新 `{code-artifact}`,从 `next.round` / `next.name` 取得 `{review-round}` / `{review-artifact}`;不得自行扫描轮次或拼装文件名。随后执行 started 事件并复核返回身份。
|
|
70
74
|
|
|
71
75
|
### 3. 阅读实现与修复上下文
|
|
72
76
|
|
|
@@ -153,16 +153,16 @@ Use this template when writing `review-code.md` or `review-code-r{N}.md`.
|
|
|
153
153
|
|
|
154
154
|
## State Check
|
|
155
155
|
|
|
156
|
-
> Record the state-check command, review scope, key result, and uncovered parts
|
|
156
|
+
> Record the state-check command, review scope, key result, and uncovered parts.
|
|
157
157
|
> Follow `.agents/rules/evidence-reporting.md`: record review scope, key result, and uncovered parts; do not paste complete successful stdout.
|
|
158
158
|
|
|
159
159
|
## Raw Evidence
|
|
160
160
|
|
|
161
|
-
> Follow `.agents/rules/evidence-reporting.md`: pair each claim with
|
|
161
|
+
> Follow `.agents/rules/evidence-reporting.md`: pair each claim with an executable command and proportionate result summary; Blockers, failures, blocking conditions, or disputes require reproducible evidence, exact location, and a decisive excerpt; a judgment that cannot be reproduced must be downgraded or moved to Self-Doubt.
|
|
162
162
|
|
|
163
163
|
- Claim: {verified claim}
|
|
164
164
|
```text
|
|
165
|
-
|
|
165
|
+
{command}
|
|
166
166
|
{result summary or decisive excerpt}
|
|
167
167
|
```
|
|
168
168
|
|
|
@@ -153,16 +153,16 @@
|
|
|
153
153
|
|
|
154
154
|
## 状态核对
|
|
155
155
|
|
|
156
|
-
>
|
|
156
|
+
> 记录状态核对命令、审查范围、关键结果和未覆盖部分。
|
|
157
157
|
> 按 `.agents/rules/evidence-reporting.md` 同时记录审查范围、关键结果和未覆盖部分;正常成功不粘贴完整 stdout。
|
|
158
158
|
|
|
159
159
|
## 证据原文
|
|
160
160
|
|
|
161
|
-
> 遵循 `.agents/rules/evidence-reporting.md
|
|
161
|
+
> 遵循 `.agents/rules/evidence-reporting.md`:每条断言配对可执行命令和相称结果摘要;Blocker、失败、阻塞或争议必须保留可复现证据、准确位置和决定性摘录;无法复现的判断须降级或移入「自我质疑」。
|
|
162
162
|
|
|
163
163
|
- 断言:{verified claim}
|
|
164
164
|
```text
|
|
165
|
-
|
|
165
|
+
{command}
|
|
166
166
|
{result summary or decisive excerpt}
|
|
167
167
|
```
|
|
168
168
|
|
|
@@ -15,6 +15,10 @@ Review the latest plan artifact and produce `review-plan.md` or `review-plan-r{N
|
|
|
15
15
|
|
|
16
16
|
## Boundary / Critical Rules
|
|
17
17
|
|
|
18
|
+
### Path and rework
|
|
19
|
+
|
|
20
|
+
This stage consumes only the canonical path fact parsed by core from the latest valid analysis artifact; a stage omitted by that path must not create an artifact. When another Changes Requested verdict follows one completed revision-review cycle in the same stage, classify the rework before the next executor artifact and bind it to the finding, source SHA, and stable task-fact digest. A round or filename change is not new evidence.
|
|
21
|
+
|
|
18
22
|
### Persisted Report Evidence
|
|
19
23
|
|
|
20
24
|
Before generating the review report, read `.agents/rules/evidence-reporting.md`. Normal inspection records the command, scope, structured result, actual conclusion, and uncovered parts; findings, blocking conditions, or disputes retain reproducible locations and decisive excerpts, while identity fields remain exact.
|
|
@@ -54,7 +58,7 @@ Require `task.md` and at least one plan artifact: `plan.md` or `plan-r{N}.md`.
|
|
|
54
58
|
|
|
55
59
|
### 2. Resolve the Artifact Context
|
|
56
60
|
|
|
57
|
-
Run `agent-infra-internal task-artifact {task-id} inspect --family review-plan`. Continue only for `ready
|
|
61
|
+
Run `agent-infra-internal task-artifact {task-id} inspect --family review-plan`. Continue only for `ready`. When `selection.disposition` is `reuse`, reuse `selection.artifact`, do not run started/init or write a new artifact, and continue directly to completion verification and next-step guidance. Otherwise take `{plan-artifact}` from `inputs` and `{review-round}` / `{review-artifact}` from `next.round` / `next.name`. Do not scan rounds or construct names in the skill. Then run the started event and verify the returned identity.
|
|
58
62
|
|
|
59
63
|
### 3. Read Plan Context
|
|
60
64
|
|
|
@@ -15,6 +15,10 @@ description: >
|
|
|
15
15
|
|
|
16
16
|
## 行为边界 / 关键规则
|
|
17
17
|
|
|
18
|
+
### 路径与返工
|
|
19
|
+
|
|
20
|
+
本阶段只消费核心从最新有效分析产物解析出的规范路径事实;未被所选路径包含的阶段不得创建产物。同阶段完成一次修订—复审后再次收到 Changes Requested 时,必须在下一执行产物前提交绑定 finding、来源 SHA 和稳定任务事实摘要的返工分类;轮次或文件名变化不是新证据。
|
|
21
|
+
|
|
18
22
|
### 持久化报告证据
|
|
19
23
|
|
|
20
24
|
生成审查报告时,先读取 `.agents/rules/evidence-reporting.md`。正常检视记录命令、范围、结构化结果、实际结论和未覆盖部分;finding、阻塞或争议保留可复现位置与决定性摘录,身份字段必须精确保留。
|
|
@@ -57,7 +61,7 @@ agent-infra-internal task-snapshot {task-id} --format text
|
|
|
57
61
|
|
|
58
62
|
### 2. 解析审查上下文
|
|
59
63
|
|
|
60
|
-
运行 `agent-infra-internal task-artifact {task-id} inspect --family review-plan`。仅当结果为 `ready`
|
|
64
|
+
运行 `agent-infra-internal task-artifact {task-id} inspect --family review-plan`。仅当结果为 `ready` 时继续。若 `selection.disposition` 为 `reuse`,复用 `selection.artifact`,不得执行 started、init 或写入新产物,并直接进入完成校验与下一步提示。其他状态从 `inputs` 取得 `{plan-artifact}`,从 `next.round` / `next.name` 取得 `{review-round}` / `{review-artifact}`;不得自行扫描轮次或拼装文件名。随后执行 started 事件并复核返回身份。
|
|
61
65
|
|
|
62
66
|
### 3. 阅读方案上下文
|
|
63
67
|
|
|
@@ -157,16 +157,16 @@ Use this template when writing `review-plan.md` or `review-plan-r{N}.md`.
|
|
|
157
157
|
|
|
158
158
|
## State Check
|
|
159
159
|
|
|
160
|
-
> Record the state-check command, review scope, key result, and uncovered parts
|
|
160
|
+
> Record the state-check command, review scope, key result, and uncovered parts.
|
|
161
161
|
> Follow `.agents/rules/evidence-reporting.md`: record review scope, key result, and uncovered parts; do not paste complete successful stdout.
|
|
162
162
|
|
|
163
163
|
## Raw Evidence
|
|
164
164
|
|
|
165
|
-
> Follow `.agents/rules/evidence-reporting.md`: pair each claim with
|
|
165
|
+
> Follow `.agents/rules/evidence-reporting.md`: pair each claim with an executable command and proportionate result summary; Blockers, failures, blocking conditions, or disputes require a reproducible command, exact location, and decisive excerpt; a judgment that cannot be reproduced must be downgraded or moved to Self-Doubt.
|
|
166
166
|
|
|
167
167
|
- Claim: {verified claim}
|
|
168
168
|
```text
|
|
169
|
-
|
|
169
|
+
{command}
|
|
170
170
|
{result summary or decisive excerpt}
|
|
171
171
|
```
|
|
172
172
|
|
|
@@ -157,16 +157,16 @@
|
|
|
157
157
|
|
|
158
158
|
## 状态核对
|
|
159
159
|
|
|
160
|
-
>
|
|
160
|
+
> 记录状态核对命令、审查范围、关键结果和未覆盖部分。
|
|
161
161
|
> 按 `.agents/rules/evidence-reporting.md` 同时记录审查范围、关键结果和未覆盖部分;正常成功不粘贴完整 stdout。
|
|
162
162
|
|
|
163
163
|
## 证据原文
|
|
164
164
|
|
|
165
|
-
> 遵循 `.agents/rules/evidence-reporting.md
|
|
165
|
+
> 遵循 `.agents/rules/evidence-reporting.md`:每条断言配对可执行命令和相称结果摘要;Blocker、失败、阻塞或争议必须保留可复现命令、准确位置和决定性摘录;无法复现的判断须降级或移入「自我质疑」。
|
|
166
166
|
|
|
167
167
|
- 断言:{verified claim}
|
|
168
168
|
```text
|
|
169
|
-
|
|
169
|
+
{command}
|
|
170
170
|
{result summary or decisive excerpt}
|
|
171
171
|
```
|
|
172
172
|
|
|
@@ -12,8 +12,10 @@
|
|
|
12
12
|
"State Check",
|
|
13
13
|
"Evidence"
|
|
14
14
|
],
|
|
15
|
+
"state_check_patterns": [
|
|
16
|
+
"agent-infra-internal[ \\t]+task-snapshot\\b"
|
|
17
|
+
],
|
|
15
18
|
"required_patterns": [
|
|
16
|
-
"^\\$ ",
|
|
17
19
|
"^- \\*\\*Reviewed Head SHA\\*\\*[::]\\s*[0-9a-f]{40}\\s*$",
|
|
18
20
|
"^- \\*\\*Review Mode\\*\\*[::]\\s*(?:verify|audit|reconstruct)\\s*$",
|
|
19
21
|
"^- \\*\\*Evidence Scenario\\*\\*[::]\\s*S[123]\\s*$",
|
|
@@ -12,8 +12,10 @@
|
|
|
12
12
|
"状态核对",
|
|
13
13
|
"证据原文"
|
|
14
14
|
],
|
|
15
|
+
"state_check_patterns": [
|
|
16
|
+
"agent-infra-internal[ \\t]+task-snapshot\\b"
|
|
17
|
+
],
|
|
15
18
|
"required_patterns": [
|
|
16
|
-
"^\\$ ",
|
|
17
19
|
"^- \\*\\*被审 head SHA\\*\\*[::]\\s*[0-9a-f]{40}\\s*$",
|
|
18
20
|
"^- \\*\\*审查模式\\*\\*[::]\\s*(?:verify|audit|reconstruct)\\s*$",
|
|
19
21
|
"^- \\*\\*证据场景\\*\\*[::]\\s*S[123]\\s*$",
|
|
@@ -11,7 +11,7 @@ Use the following structure when creating `pr-review.md` or `pr-review-r{N}.md`.
|
|
|
11
11
|
|
|
12
12
|
## State Check
|
|
13
13
|
|
|
14
|
-
> Record the state-check command, PR/head, review scope, key result, and uncovered parts
|
|
14
|
+
> Record the state-check command, PR/head, review scope, key result, and uncovered parts.
|
|
15
15
|
> Follow `.agents/rules/evidence-reporting.md`: record PR, head, review scope, key result, and uncovered parts; do not paste complete successful stdout.
|
|
16
16
|
|
|
17
17
|
## Identity
|
|
@@ -77,10 +77,10 @@ Land the following in order before the line-level findings, without impersonatin
|
|
|
77
77
|
|
|
78
78
|
## Evidence
|
|
79
79
|
|
|
80
|
-
> Follow `.agents/rules/evidence-reporting.md`: pair every assertion with
|
|
80
|
+
> Follow `.agents/rules/evidence-reporting.md`: pair every assertion with an executable command and proportionate result summary; formal Review, failures, blocking conditions, or disputes retain exact identity and decisive excerpts.
|
|
81
81
|
|
|
82
82
|
- Assertion: {verified claim}
|
|
83
83
|
```text
|
|
84
|
-
|
|
84
|
+
{command}
|
|
85
85
|
{result summary or decisive excerpt}
|
|
86
86
|
```
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
|
|
12
12
|
## 状态核对
|
|
13
13
|
|
|
14
|
-
> 记录状态核对命令、PR/head
|
|
14
|
+
> 记录状态核对命令、PR/head、审查范围、关键结果和未覆盖部分。
|
|
15
15
|
> 按 `.agents/rules/evidence-reporting.md` 同时记录 PR、head、审查范围、关键结果和未覆盖部分;正常成功不粘贴完整 stdout。
|
|
16
16
|
|
|
17
17
|
## 身份信息
|
|
@@ -77,10 +77,10 @@
|
|
|
77
77
|
|
|
78
78
|
## 证据原文
|
|
79
79
|
|
|
80
|
-
> 遵循 `.agents/rules/evidence-reporting.md
|
|
80
|
+
> 遵循 `.agents/rules/evidence-reporting.md`:每条断言配对可执行命令和相称结果摘要;正式 Review、失败、阻塞或争议保留准确身份和决定性摘录。
|
|
81
81
|
|
|
82
82
|
- 断言:{verified claim}
|
|
83
83
|
```text
|
|
84
|
-
|
|
84
|
+
{command}
|
|
85
85
|
{result summary or decisive excerpt}
|
|
86
86
|
```
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
## State Check
|
|
11
11
|
|
|
12
12
|
```text
|
|
13
|
-
|
|
13
|
+
agent-infra-internal task-snapshot {task-id} --format text
|
|
14
14
|
{command-summary-and-key-result}
|
|
15
15
|
```
|
|
16
16
|
> Follow `.agents/rules/evidence-reporting.md`: record command name, target scope, exit status, sanitized result, and coverage gap; do not paste complete argv or sensitive transcripts.
|
|
@@ -67,7 +67,7 @@ $ agent-infra-internal task-snapshot {task-id} --format text
|
|
|
67
67
|
## Raw Evidence
|
|
68
68
|
|
|
69
69
|
```text
|
|
70
|
-
|
|
70
|
+
agent-infra-internal task-validate {task-ref} --scope {scope} --format json -- {redacted-command}
|
|
71
71
|
{sanitized-result}
|
|
72
72
|
```
|
|
73
73
|
> Keep only the allowed public command and sanitized structured result; complete successful stdout is not default report content.
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
## 状态核对
|
|
11
11
|
|
|
12
12
|
```text
|
|
13
|
-
|
|
13
|
+
agent-infra-internal task-snapshot {task-id} --format text
|
|
14
14
|
{command-summary-and-key-result}
|
|
15
15
|
```
|
|
16
16
|
> 按 `.agents/rules/evidence-reporting.md` 记录命令名称、目标范围、退出状态、sanitized result 和覆盖缺口;不得粘贴完整 argv 或敏感 transcript。
|
|
@@ -67,7 +67,7 @@ $ agent-infra-internal task-snapshot {task-id} --format text
|
|
|
67
67
|
## 证据原文
|
|
68
68
|
|
|
69
69
|
```text
|
|
70
|
-
|
|
70
|
+
agent-infra-internal task-validate {task-ref} --scope {scope} --format json -- {redacted-command}
|
|
71
71
|
{sanitized-result}
|
|
72
72
|
```
|
|
73
73
|
> 仅保留允许公开的命令与脱敏结构化结果;完整成功 stdout 不属于默认报告内容。
|
|
@@ -363,6 +363,13 @@ function assetMatches(entry, target) {
|
|
|
363
363
|
: normalizedTarget === normalizedEntry;
|
|
364
364
|
}
|
|
365
365
|
|
|
366
|
+
function isOwnedByDisabledAgentClient(target, enabledSet) {
|
|
367
|
+
return AGENT_CLIENT_MANIFEST.some((adapter) =>
|
|
368
|
+
!enabledSet.has(adapter.id)
|
|
369
|
+
&& adapter.ownedPathPrefixes.some((prefix) => assetMatches(prefix, target))
|
|
370
|
+
);
|
|
371
|
+
}
|
|
372
|
+
|
|
366
373
|
function adapterAssets(adapters, category) {
|
|
367
374
|
return adapters.flatMap((adapter) => adapter[category]);
|
|
368
375
|
}
|
|
@@ -1914,6 +1921,15 @@ function syncTemplates(projectRoot, templateRootOverride) {
|
|
|
1914
1921
|
}
|
|
1915
1922
|
|
|
1916
1923
|
const mergedMap = new Map();
|
|
1924
|
+
const addMergedTarget = (target, source) => {
|
|
1925
|
+
if (
|
|
1926
|
+
isOwnedByDisabledAgentClient(target, enabledTUIs)
|
|
1927
|
+
&& !isCustomProtected(target, protectedCustomSkills, customCommandTargets)
|
|
1928
|
+
) {
|
|
1929
|
+
return;
|
|
1930
|
+
}
|
|
1931
|
+
if (!mergedMap.has(target)) mergedMap.set(target, source);
|
|
1932
|
+
};
|
|
1917
1933
|
for (const entry of merged) {
|
|
1918
1934
|
if (isPathOwnedByOtherPlatform(entry, platformType)) {
|
|
1919
1935
|
report.managed.skippedPlatform.push(entry);
|
|
@@ -1925,13 +1941,13 @@ function syncTemplates(projectRoot, templateRootOverride) {
|
|
|
1925
1941
|
return globMatch(entry, t);
|
|
1926
1942
|
});
|
|
1927
1943
|
for (const [t, s] of platformSelect(langSelect(hits, lang, allSet, project), platformType, project)) {
|
|
1928
|
-
|
|
1944
|
+
addMergedTarget(t, s);
|
|
1929
1945
|
}
|
|
1930
1946
|
} else {
|
|
1931
1947
|
const rels = entryVariantRels(entry, allSet, platformType);
|
|
1932
1948
|
const selected = platformSelect(langSelect(rels, lang, allSet, project), platformType, project);
|
|
1933
1949
|
for (const [t, s] of selected) {
|
|
1934
|
-
|
|
1950
|
+
addMergedTarget(t, s);
|
|
1935
1951
|
}
|
|
1936
1952
|
}
|
|
1937
1953
|
}
|
|
@@ -106,8 +106,8 @@ delivery_remote_head: # Most recent successfully delivered task branch
|
|
|
106
106
|
|
|
107
107
|
## Rework Intent
|
|
108
108
|
|
|
109
|
-
| intent_id | finding_id | source_artifact | source_sha256 | target | status | declared_at | consumed_at |
|
|
110
|
-
|
|
109
|
+
| intent_id | finding_id | source_artifact | source_sha256 | target | classification | evidence_digest | task_fact_digest | status | declared_at | consumed_at |
|
|
110
|
+
|-----------|------------|----------------|---------------|--------|----------------|-----------------|------------------|--------|-------------|-------------|
|
|
111
111
|
|
|
112
112
|
## Artifact Invalidation
|
|
113
113
|
|
|
@@ -106,8 +106,8 @@ delivery_remote_head: # 最近一次成功交付到 remote 的任务分
|
|
|
106
106
|
|
|
107
107
|
## 返工意图
|
|
108
108
|
|
|
109
|
-
| intent_id | finding_id | source_artifact | source_sha256 | target | status | declared_at | consumed_at |
|
|
110
|
-
|
|
109
|
+
| intent_id | finding_id | source_artifact | source_sha256 | target | classification | evidence_digest | task_fact_digest | status | declared_at | consumed_at |
|
|
110
|
+
|-----------|------------|----------------|---------------|--------|----------------|-----------------|------------------|--------|-------------|-------------|
|
|
111
111
|
|
|
112
112
|
## 产物失效记录
|
|
113
113
|
|
|
@@ -9,6 +9,11 @@
|
|
|
9
9
|
name: bug-fix
|
|
10
10
|
description: Workflow for diagnosing and fixing a defect.
|
|
11
11
|
|
|
12
|
+
lifecycle_paths:
|
|
13
|
+
streamlined: [analysis, code, code-review]
|
|
14
|
+
standard: [analysis, design, code, code-review]
|
|
15
|
+
full: [analysis, analysis-review, design, design-review, code, code-review]
|
|
16
|
+
|
|
12
17
|
steps:
|
|
13
18
|
- name: analysis
|
|
14
19
|
description: Reproduce the defect, identify the root cause, and define the fix scope.
|
|
@@ -29,7 +34,7 @@ steps:
|
|
|
29
34
|
outputs:
|
|
30
35
|
- name: analysis
|
|
31
36
|
pattern: "analysis.md | analysis-r{N}.md"
|
|
32
|
-
rule: "
|
|
37
|
+
rule: "Let the task-artifact selector decide: reuse a completed artifact when inputs and substantive results match; create the next round only for new inputs, rework evidence, or result changes"
|
|
33
38
|
outputs:
|
|
34
39
|
- Root-cause analysis
|
|
35
40
|
- Affected files list
|
|
@@ -56,7 +61,7 @@ steps:
|
|
|
56
61
|
outputs:
|
|
57
62
|
- name: review-analysis
|
|
58
63
|
pattern: "review-analysis.md | review-analysis-r{N}.md"
|
|
59
|
-
rule: "
|
|
64
|
+
rule: "Let the task-artifact selector decide: reuse a completed artifact when inputs and substantive results match; create the next round only for new inputs, rework evidence, or result changes"
|
|
60
65
|
outputs:
|
|
61
66
|
- Requirement analysis review report
|
|
62
67
|
- Findings to fix, if any
|
|
@@ -84,7 +89,7 @@ steps:
|
|
|
84
89
|
outputs:
|
|
85
90
|
- name: plan
|
|
86
91
|
pattern: "plan.md | plan-r{N}.md"
|
|
87
|
-
rule: "
|
|
92
|
+
rule: "Let the task-artifact selector decide: reuse a completed artifact when inputs and substantive results match; create the next round only for new inputs, rework evidence, or result changes"
|
|
88
93
|
outputs:
|
|
89
94
|
- Fix plan
|
|
90
95
|
- Regression test list
|
|
@@ -110,7 +115,7 @@ steps:
|
|
|
110
115
|
outputs:
|
|
111
116
|
- name: review-plan
|
|
112
117
|
pattern: "review-plan.md | review-plan-r{N}.md"
|
|
113
|
-
rule: "
|
|
118
|
+
rule: "Let the task-artifact selector decide: reuse a completed artifact when inputs and substantive results match; create the next round only for new inputs, rework evidence, or result changes"
|
|
114
119
|
outputs:
|
|
115
120
|
- Plan review report
|
|
116
121
|
- Findings to fix, if any
|
|
@@ -146,7 +151,7 @@ steps:
|
|
|
146
151
|
outputs:
|
|
147
152
|
- name: code
|
|
148
153
|
pattern: "code.md | code-r{N}.md"
|
|
149
|
-
rule: "
|
|
154
|
+
rule: "Let the task-artifact selector decide: reuse a completed artifact when inputs and substantive results match; create the next round only for new inputs, rework evidence, or result changes"
|
|
150
155
|
outputs:
|
|
151
156
|
- Bug-fix branch with implementation or fixes
|
|
152
157
|
- Regression test files
|
|
@@ -173,7 +178,7 @@ steps:
|
|
|
173
178
|
outputs:
|
|
174
179
|
- name: review-code
|
|
175
180
|
pattern: "review-code.md | review-code-r{N}.md"
|
|
176
|
-
rule: "
|
|
181
|
+
rule: "Let the task-artifact selector decide: reuse a completed artifact when inputs and substantive results match; create the next round only for new inputs, rework evidence, or result changes"
|
|
177
182
|
outputs:
|
|
178
183
|
- Code review report
|
|
179
184
|
- Findings list, if any
|
|
@@ -8,6 +8,11 @@
|
|
|
8
8
|
name: bug-fix
|
|
9
9
|
description: 诊断和修复缺陷的工作流。
|
|
10
10
|
|
|
11
|
+
lifecycle_paths:
|
|
12
|
+
streamlined: [analysis, code, code-review]
|
|
13
|
+
standard: [analysis, design, code, code-review]
|
|
14
|
+
full: [analysis, analysis-review, design, design-review, code, code-review]
|
|
15
|
+
|
|
11
16
|
steps:
|
|
12
17
|
- name: analysis
|
|
13
18
|
description: 复现缺陷,识别根本原因,确定修复范围。
|
|
@@ -28,7 +33,7 @@ steps:
|
|
|
28
33
|
outputs:
|
|
29
34
|
- name: analysis
|
|
30
35
|
pattern: "analysis.md | analysis-r{N}.md"
|
|
31
|
-
rule: "
|
|
36
|
+
rule: "由 task-artifact 选择器决定:输入与实质结果未变化时复用已完成产物;仅在新输入、新返工证据或结果变化时创建下一轮"
|
|
32
37
|
outputs:
|
|
33
38
|
- 根因分析
|
|
34
39
|
- 受影响文件列表
|
|
@@ -55,7 +60,7 @@ steps:
|
|
|
55
60
|
outputs:
|
|
56
61
|
- name: review-analysis
|
|
57
62
|
pattern: "review-analysis.md | review-analysis-r{N}.md"
|
|
58
|
-
rule: "
|
|
63
|
+
rule: "由 task-artifact 选择器决定:输入与实质结果未变化时复用已完成产物;仅在新输入、新返工证据或结果变化时创建下一轮"
|
|
59
64
|
outputs:
|
|
60
65
|
- 需求分析审查报告
|
|
61
66
|
- 待修正问题列表(如有)
|
|
@@ -83,7 +88,7 @@ steps:
|
|
|
83
88
|
outputs:
|
|
84
89
|
- name: plan
|
|
85
90
|
pattern: "plan.md | plan-r{N}.md"
|
|
86
|
-
rule: "
|
|
91
|
+
rule: "由 task-artifact 选择器决定:输入与实质结果未变化时复用已完成产物;仅在新输入、新返工证据或结果变化时创建下一轮"
|
|
87
92
|
outputs:
|
|
88
93
|
- 任务文件中记录的修复方案
|
|
89
94
|
- 待添加的测试用例列表
|
|
@@ -109,7 +114,7 @@ steps:
|
|
|
109
114
|
outputs:
|
|
110
115
|
- name: review-plan
|
|
111
116
|
pattern: "review-plan.md | review-plan-r{N}.md"
|
|
112
|
-
rule: "
|
|
117
|
+
rule: "由 task-artifact 选择器决定:输入与实质结果未变化时复用已完成产物;仅在新输入、新返工证据或结果变化时创建下一轮"
|
|
113
118
|
outputs:
|
|
114
119
|
- 技术方案审查报告
|
|
115
120
|
- 待修正问题列表(如有)
|
|
@@ -145,7 +150,7 @@ steps:
|
|
|
145
150
|
outputs:
|
|
146
151
|
- name: code
|
|
147
152
|
pattern: "code.md | code-r{N}.md"
|
|
148
|
-
rule: "
|
|
153
|
+
rule: "由 task-artifact 选择器决定:输入与实质结果未变化时复用已完成产物;仅在新输入、新返工证据或结果变化时创建下一轮"
|
|
149
154
|
outputs:
|
|
150
155
|
- 包含实现或修复的缺陷修复分支
|
|
151
156
|
- 回归测试文件
|
|
@@ -172,7 +177,7 @@ steps:
|
|
|
172
177
|
outputs:
|
|
173
178
|
- name: review-code
|
|
174
179
|
pattern: "review-code.md | review-code-r{N}.md"
|
|
175
|
-
rule: "
|
|
180
|
+
rule: "由 task-artifact 选择器决定:输入与实质结果未变化时复用已完成产物;仅在新输入、新返工证据或结果变化时创建下一轮"
|
|
176
181
|
outputs:
|
|
177
182
|
- 代码审查报告
|
|
178
183
|
- 问题列表(如有)
|
|
@@ -9,6 +9,11 @@
|
|
|
9
9
|
name: feature-development
|
|
10
10
|
description: End-to-end workflow for developing a new feature.
|
|
11
11
|
|
|
12
|
+
lifecycle_paths:
|
|
13
|
+
streamlined: [analysis, code, code-review]
|
|
14
|
+
standard: [analysis, design, code, code-review]
|
|
15
|
+
full: [analysis, analysis-review, design, design-review, code, code-review]
|
|
16
|
+
|
|
12
17
|
steps:
|
|
13
18
|
- name: analysis
|
|
14
19
|
description: Analyze feature requirements, explore the codebase, and identify affected areas.
|
|
@@ -27,7 +32,7 @@ steps:
|
|
|
27
32
|
outputs:
|
|
28
33
|
- name: analysis
|
|
29
34
|
pattern: "analysis.md | analysis-r{N}.md"
|
|
30
|
-
rule: "
|
|
35
|
+
rule: "Let the task-artifact selector decide: reuse a completed artifact when inputs and substantive results match; create the next round only for new inputs, rework evidence, or result changes"
|
|
31
36
|
outputs:
|
|
32
37
|
- Requirement analysis report
|
|
33
38
|
- Affected files list
|
|
@@ -54,7 +59,7 @@ steps:
|
|
|
54
59
|
outputs:
|
|
55
60
|
- name: review-analysis
|
|
56
61
|
pattern: "review-analysis.md | review-analysis-r{N}.md"
|
|
57
|
-
rule: "
|
|
62
|
+
rule: "Let the task-artifact selector decide: reuse a completed artifact when inputs and substantive results match; create the next round only for new inputs, rework evidence, or result changes"
|
|
58
63
|
outputs:
|
|
59
64
|
- Requirement analysis review report
|
|
60
65
|
- Findings to fix, if any
|
|
@@ -83,7 +88,7 @@ steps:
|
|
|
83
88
|
outputs:
|
|
84
89
|
- name: plan
|
|
85
90
|
pattern: "plan.md | plan-r{N}.md"
|
|
86
|
-
rule: "
|
|
91
|
+
rule: "Let the task-artifact selector decide: reuse a completed artifact when inputs and substantive results match; create the next round only for new inputs, rework evidence, or result changes"
|
|
87
92
|
outputs:
|
|
88
93
|
- Technical plan
|
|
89
94
|
- Interface definitions
|
|
@@ -110,7 +115,7 @@ steps:
|
|
|
110
115
|
outputs:
|
|
111
116
|
- name: review-plan
|
|
112
117
|
pattern: "review-plan.md | review-plan-r{N}.md"
|
|
113
|
-
rule: "
|
|
118
|
+
rule: "Let the task-artifact selector decide: reuse a completed artifact when inputs and substantive results match; create the next round only for new inputs, rework evidence, or result changes"
|
|
114
119
|
outputs:
|
|
115
120
|
- Plan review report
|
|
116
121
|
- Findings to fix, if any
|
|
@@ -146,7 +151,7 @@ steps:
|
|
|
146
151
|
outputs:
|
|
147
152
|
- name: code
|
|
148
153
|
pattern: "code.md | code-r{N}.md"
|
|
149
|
-
rule: "
|
|
154
|
+
rule: "Let the task-artifact selector decide: reuse a completed artifact when inputs and substantive results match; create the next round only for new inputs, rework evidence, or result changes"
|
|
150
155
|
outputs:
|
|
151
156
|
- Feature branch with implementation or fixes
|
|
152
157
|
- Test files
|
|
@@ -173,7 +178,7 @@ steps:
|
|
|
173
178
|
outputs:
|
|
174
179
|
- name: review-code
|
|
175
180
|
pattern: "review-code.md | review-code-r{N}.md"
|
|
176
|
-
rule: "
|
|
181
|
+
rule: "Let the task-artifact selector decide: reuse a completed artifact when inputs and substantive results match; create the next round only for new inputs, rework evidence, or result changes"
|
|
177
182
|
outputs:
|
|
178
183
|
- Code review report
|
|
179
184
|
- Findings to fix
|