@fitlab-ai/agent-infra 0.3.2 → 0.4.1
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 +18 -35
- package/README.zh-CN.md +18 -35
- package/lib/defaults.json +5 -12
- package/lib/init.js +9 -25
- package/lib/paths.js +3 -42
- package/lib/update.js +43 -32
- package/package.json +2 -1
- package/templates/.agents/QUICKSTART.md +17 -7
- package/templates/.agents/QUICKSTART.zh-CN.md +17 -7
- package/templates/.agents/README.md +21 -14
- package/templates/.agents/README.zh-CN.md +21 -14
- package/templates/.agents/skills/analyze-task/SKILL.md +7 -10
- package/templates/.agents/skills/analyze-task/SKILL.zh-CN.md +7 -9
- package/templates/.agents/skills/block-task/SKILL.md +9 -13
- package/templates/.agents/skills/block-task/SKILL.zh-CN.md +9 -12
- package/templates/.agents/skills/check-task/SKILL.md +4 -8
- package/templates/.agents/skills/check-task/SKILL.zh-CN.md +4 -6
- package/templates/.agents/skills/close-codescan/SKILL.md +1 -4
- package/templates/.agents/skills/close-codescan/SKILL.zh-CN.md +1 -3
- package/templates/.agents/skills/close-dependabot/SKILL.md +1 -4
- package/templates/.agents/skills/close-dependabot/SKILL.zh-CN.md +1 -3
- package/templates/.agents/skills/commit/SKILL.md +26 -198
- package/templates/.agents/skills/commit/SKILL.zh-CN.md +26 -197
- package/templates/.agents/skills/commit/reference/commit-message.md +60 -0
- package/templates/.agents/skills/commit/reference/commit-message.zh-CN.md +60 -0
- package/templates/.agents/skills/commit/reference/copyright-check.md +39 -0
- package/templates/.agents/skills/commit/reference/copyright-check.zh-CN.md +39 -0
- package/templates/.agents/skills/commit/reference/task-status-update.md +88 -0
- package/templates/.agents/skills/commit/reference/task-status-update.zh-CN.md +88 -0
- package/templates/.agents/skills/complete-task/SKILL.md +8 -13
- package/templates/.agents/skills/complete-task/SKILL.zh-CN.md +8 -11
- package/templates/.agents/skills/create-issue/SKILL.md +32 -251
- package/templates/.agents/skills/create-issue/SKILL.zh-CN.md +33 -252
- package/templates/.agents/skills/create-issue/reference/label-and-type.md +77 -0
- package/templates/.agents/skills/create-issue/reference/label-and-type.zh-CN.md +77 -0
- package/templates/.agents/skills/create-issue/reference/template-matching.md +45 -0
- package/templates/.agents/skills/create-issue/reference/template-matching.zh-CN.md +45 -0
- package/templates/.agents/skills/create-pr/SKILL.md +33 -224
- package/templates/.agents/skills/create-pr/SKILL.zh-CN.md +32 -222
- package/templates/.agents/skills/create-pr/reference/branch-strategy.md +29 -0
- package/templates/.agents/skills/create-pr/reference/branch-strategy.zh-CN.md +29 -0
- package/templates/.agents/skills/create-pr/reference/pr-body-template.md +86 -0
- package/templates/.agents/skills/create-pr/reference/pr-body-template.zh-CN.md +86 -0
- package/templates/.agents/skills/create-release-note/SKILL.md +10 -13
- package/templates/.agents/skills/create-release-note/SKILL.zh-CN.md +10 -12
- package/templates/.agents/skills/create-task/SKILL.md +5 -8
- package/templates/.agents/skills/create-task/SKILL.zh-CN.md +5 -7
- package/templates/.agents/skills/implement-task/SKILL.md +48 -178
- package/templates/.agents/skills/implement-task/SKILL.zh-CN.md +44 -172
- package/templates/.agents/skills/implement-task/reference/implementation-rules.md +58 -0
- package/templates/.agents/skills/implement-task/reference/implementation-rules.zh-CN.md +58 -0
- package/templates/.agents/skills/implement-task/reference/report-template.md +63 -0
- package/templates/.agents/skills/implement-task/reference/report-template.zh-CN.md +63 -0
- package/templates/.agents/skills/import-codescan/SKILL.md +2 -5
- package/templates/.agents/skills/import-codescan/SKILL.zh-CN.md +2 -4
- package/templates/.agents/skills/import-dependabot/SKILL.md +4 -7
- package/templates/.agents/skills/import-dependabot/SKILL.zh-CN.md +4 -6
- package/templates/.agents/skills/import-issue/SKILL.md +6 -8
- package/templates/.agents/skills/import-issue/SKILL.zh-CN.md +6 -8
- package/templates/.agents/skills/init-labels/SKILL.md +1 -4
- package/templates/.agents/skills/init-labels/SKILL.zh-CN.md +1 -4
- package/templates/.agents/skills/init-milestones/SKILL.md +1 -3
- package/templates/.agents/skills/init-milestones/SKILL.zh-CN.md +1 -3
- package/templates/.agents/skills/plan-task/SKILL.md +7 -11
- package/templates/.agents/skills/plan-task/SKILL.zh-CN.md +7 -9
- package/templates/.agents/skills/refine-task/SKILL.md +38 -162
- package/templates/.agents/skills/refine-task/SKILL.zh-CN.md +36 -158
- package/templates/.agents/skills/refine-task/reference/fix-workflow.md +76 -0
- package/templates/.agents/skills/refine-task/reference/fix-workflow.zh-CN.md +76 -0
- package/templates/.agents/skills/refine-task/reference/report-template.md +38 -0
- package/templates/.agents/skills/refine-task/reference/report-template.zh-CN.md +38 -0
- package/templates/.agents/skills/refine-title/SKILL.md +1 -4
- package/templates/.agents/skills/refine-title/SKILL.zh-CN.md +1 -3
- package/templates/.agents/skills/release/SKILL.md +58 -19
- package/templates/.agents/skills/release/SKILL.zh-CN.md +58 -18
- package/templates/.agents/skills/review-task/SKILL.md +37 -239
- package/templates/.agents/skills/review-task/SKILL.zh-CN.md +37 -238
- package/templates/.agents/skills/review-task/reference/output-templates.md +72 -0
- package/templates/.agents/skills/review-task/reference/output-templates.zh-CN.md +72 -0
- package/templates/.agents/skills/review-task/reference/report-template.md +63 -0
- package/templates/.agents/skills/review-task/reference/report-template.zh-CN.md +63 -0
- package/templates/.agents/skills/review-task/reference/review-criteria.md +24 -0
- package/templates/.agents/skills/review-task/reference/review-criteria.zh-CN.md +24 -0
- package/templates/.agents/skills/sync-issue/SKILL.md +32 -490
- package/templates/.agents/skills/sync-issue/SKILL.zh-CN.md +33 -490
- package/templates/.agents/skills/sync-issue/reference/comment-publish.md +88 -0
- package/templates/.agents/skills/sync-issue/reference/comment-publish.zh-CN.md +88 -0
- package/templates/.agents/skills/sync-issue/reference/delivery-detection.md +42 -0
- package/templates/.agents/skills/sync-issue/reference/delivery-detection.zh-CN.md +42 -0
- package/templates/.agents/skills/sync-issue/reference/label-sync.md +63 -0
- package/templates/.agents/skills/sync-issue/reference/label-sync.zh-CN.md +63 -0
- package/templates/.agents/skills/sync-issue/reference/milestone-sync.md +37 -0
- package/templates/.agents/skills/sync-issue/reference/milestone-sync.zh-CN.md +37 -0
- package/templates/.agents/skills/sync-pr/SKILL.md +25 -287
- package/templates/.agents/skills/sync-pr/SKILL.zh-CN.md +29 -291
- package/templates/.agents/skills/sync-pr/reference/comment-publish.md +82 -0
- package/templates/.agents/skills/sync-pr/reference/comment-publish.zh-CN.md +82 -0
- package/templates/.agents/skills/sync-pr/reference/delivery-detection.md +54 -0
- package/templates/.agents/skills/sync-pr/reference/delivery-detection.zh-CN.md +54 -0
- package/templates/.agents/skills/test/SKILL.md +1 -3
- package/templates/.agents/skills/test/SKILL.zh-CN.md +1 -3
- package/templates/.agents/skills/test-integration/SKILL.md +1 -4
- package/templates/.agents/skills/test-integration/SKILL.zh-CN.md +1 -3
- package/templates/.agents/skills/update-agent-infra/SKILL.md +7 -11
- package/templates/.agents/skills/update-agent-infra/SKILL.zh-CN.md +7 -9
- package/templates/.agents/skills/update-agent-infra/scripts/sync-templates.js +59 -118
- package/templates/.agents/skills/upgrade-dependency/SKILL.md +1 -4
- package/templates/.agents/skills/upgrade-dependency/SKILL.zh-CN.md +1 -3
- package/templates/.agents/templates/handoff.md +1 -1
- package/templates/.agents/templates/handoff.zh-CN.md +1 -1
- package/templates/.agents/workflows/bug-fix.yaml +71 -71
- package/templates/.agents/workflows/bug-fix.zh-CN.yaml +1 -1
- package/templates/.agents/workflows/feature-development.yaml +71 -71
- package/templates/.agents/workflows/feature-development.zh-CN.yaml +1 -1
- package/templates/.agents/workflows/refactoring.yaml +76 -76
- package/templates/.agents/workflows/refactoring.zh-CN.yaml +1 -1
- package/templates/{.agent-workspace → .agents/workspace}/README.md +1 -1
- package/templates/{.agent-workspace → .agents/workspace}/README.zh-CN.md +1 -1
- package/templates/.claude/CLAUDE.md +14 -52
- package/templates/.claude/CLAUDE.zh-CN.md +14 -52
- package/templates/.claude/commands/analyze-task.md +1 -1
- package/templates/.claude/commands/analyze-task.zh-CN.md +1 -1
- package/templates/.claude/commands/block-task.md +2 -1
- package/templates/.claude/commands/block-task.zh-CN.md +2 -1
- package/templates/.claude/commands/check-task.md +2 -1
- package/templates/.claude/commands/check-task.zh-CN.md +2 -1
- package/templates/.claude/commands/close-codescan.md +2 -1
- package/templates/.claude/commands/close-codescan.zh-CN.md +2 -1
- package/templates/.claude/commands/close-dependabot.md +2 -1
- package/templates/.claude/commands/close-dependabot.zh-CN.md +2 -1
- package/templates/.claude/commands/commit.md +1 -1
- package/templates/.claude/commands/commit.zh-CN.md +1 -1
- package/templates/.claude/commands/complete-task.md +1 -1
- package/templates/.claude/commands/complete-task.zh-CN.md +1 -1
- package/templates/.claude/commands/create-issue.md +1 -1
- package/templates/.claude/commands/create-issue.zh-CN.md +1 -1
- package/templates/.claude/commands/create-pr.md +1 -1
- package/templates/.claude/commands/create-pr.zh-CN.md +1 -1
- package/templates/.claude/commands/create-release-note.md +2 -1
- package/templates/.claude/commands/create-release-note.zh-CN.md +2 -1
- package/templates/.claude/commands/create-task.md +1 -1
- package/templates/.claude/commands/create-task.zh-CN.md +1 -1
- package/templates/.claude/commands/implement-task.md +1 -1
- package/templates/.claude/commands/implement-task.zh-CN.md +1 -1
- package/templates/.claude/commands/import-codescan.md +1 -0
- package/templates/.claude/commands/import-codescan.zh-CN.md +2 -1
- package/templates/.claude/commands/import-dependabot.md +1 -0
- package/templates/.claude/commands/import-dependabot.zh-CN.md +2 -1
- package/templates/.claude/commands/import-issue.md +1 -1
- package/templates/.claude/commands/import-issue.zh-CN.md +1 -1
- package/templates/.claude/commands/init-labels.md +1 -0
- package/templates/.claude/commands/init-labels.zh-CN.md +2 -1
- package/templates/.claude/commands/init-milestones.md +2 -1
- package/templates/.claude/commands/init-milestones.zh-CN.md +2 -1
- package/templates/.claude/commands/plan-task.md +1 -1
- package/templates/.claude/commands/plan-task.zh-CN.md +1 -1
- package/templates/.claude/commands/refine-task.zh-CN.md +1 -1
- package/templates/.claude/commands/refine-title.md +2 -1
- package/templates/.claude/commands/refine-title.zh-CN.md +2 -1
- package/templates/.claude/commands/release.md +2 -1
- package/templates/.claude/commands/release.zh-CN.md +2 -1
- package/templates/.claude/commands/review-task.md +1 -1
- package/templates/.claude/commands/review-task.zh-CN.md +1 -1
- package/templates/.claude/commands/sync-issue.md +1 -1
- package/templates/.claude/commands/sync-issue.zh-CN.md +1 -1
- package/templates/.claude/commands/sync-pr.md +1 -1
- package/templates/.claude/commands/sync-pr.zh-CN.md +1 -1
- package/templates/.claude/commands/test-integration.md +2 -1
- package/templates/.claude/commands/test-integration.zh-CN.md +2 -1
- package/templates/.claude/commands/test.md +1 -1
- package/templates/.claude/commands/test.zh-CN.md +1 -1
- package/templates/.claude/commands/update-agent-infra.md +2 -1
- package/templates/.claude/commands/update-agent-infra.zh-CN.md +2 -1
- package/templates/.claude/commands/upgrade-dependency.md +2 -1
- package/templates/.claude/commands/upgrade-dependency.zh-CN.md +2 -1
- package/templates/.claude/hooks/check-version-format.sh +44 -0
- package/templates/.claude/settings.json +14 -0
- package/templates/.gemini/commands/_project_/analyze-task.toml +1 -1
- package/templates/.gemini/commands/_project_/analyze-task.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/block-task.toml +1 -1
- package/templates/.gemini/commands/_project_/block-task.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/check-task.toml +1 -1
- package/templates/.gemini/commands/_project_/check-task.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/close-codescan.toml +1 -1
- package/templates/.gemini/commands/_project_/close-codescan.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/close-dependabot.toml +1 -1
- package/templates/.gemini/commands/_project_/close-dependabot.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/commit.toml +1 -1
- package/templates/.gemini/commands/_project_/commit.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/complete-task.toml +1 -1
- package/templates/.gemini/commands/_project_/complete-task.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/create-issue.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/create-pr.toml +1 -1
- package/templates/.gemini/commands/_project_/create-pr.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/create-release-note.toml +1 -1
- package/templates/.gemini/commands/_project_/create-release-note.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/create-task.toml +1 -1
- package/templates/.gemini/commands/_project_/create-task.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/implement-task.toml +1 -1
- package/templates/.gemini/commands/_project_/implement-task.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/import-codescan.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/import-dependabot.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/import-issue.toml +1 -1
- package/templates/.gemini/commands/_project_/import-issue.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/init-labels.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/init-milestones.toml +1 -1
- package/templates/.gemini/commands/_project_/init-milestones.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/plan-task.toml +1 -1
- package/templates/.gemini/commands/_project_/plan-task.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/refine-task.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/refine-title.toml +1 -1
- package/templates/.gemini/commands/_project_/refine-title.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/release.toml +1 -1
- package/templates/.gemini/commands/_project_/release.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/review-task.toml +1 -1
- package/templates/.gemini/commands/_project_/review-task.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/sync-issue.toml +1 -1
- package/templates/.gemini/commands/_project_/sync-issue.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/sync-pr.toml +1 -1
- package/templates/.gemini/commands/_project_/sync-pr.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/test-integration.toml +1 -1
- package/templates/.gemini/commands/_project_/test-integration.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/test.toml +1 -1
- package/templates/.gemini/commands/_project_/test.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/update-agent-infra.toml +1 -1
- package/templates/.gemini/commands/_project_/update-agent-infra.zh-CN.toml +1 -1
- package/templates/.gemini/commands/_project_/upgrade-dependency.toml +1 -1
- package/templates/.gemini/commands/_project_/upgrade-dependency.zh-CN.toml +1 -1
- package/templates/.github/hooks/check-version-format.sh +29 -0
- package/templates/.github/hooks/pre-commit +8 -0
- package/templates/.opencode/COMMAND_STYLE_GUIDE.md +6 -6
- package/templates/.opencode/COMMAND_STYLE_GUIDE.zh-CN.md +6 -6
- package/templates/.opencode/commands/analyze-task.md +1 -1
- package/templates/.opencode/commands/analyze-task.zh-CN.md +1 -1
- package/templates/.opencode/commands/block-task.md +1 -1
- package/templates/.opencode/commands/block-task.zh-CN.md +1 -1
- package/templates/.opencode/commands/check-task.md +1 -1
- package/templates/.opencode/commands/check-task.zh-CN.md +1 -1
- package/templates/.opencode/commands/close-codescan.md +1 -1
- package/templates/.opencode/commands/close-codescan.zh-CN.md +1 -1
- package/templates/.opencode/commands/close-dependabot.md +1 -1
- package/templates/.opencode/commands/close-dependabot.zh-CN.md +1 -1
- package/templates/.opencode/commands/commit.md +1 -1
- package/templates/.opencode/commands/commit.zh-CN.md +1 -1
- package/templates/.opencode/commands/complete-task.md +1 -1
- package/templates/.opencode/commands/complete-task.zh-CN.md +1 -1
- package/templates/.opencode/commands/create-issue.zh-CN.md +1 -1
- package/templates/.opencode/commands/create-pr.md +1 -1
- package/templates/.opencode/commands/create-pr.zh-CN.md +1 -1
- package/templates/.opencode/commands/create-release-note.md +1 -1
- package/templates/.opencode/commands/create-release-note.zh-CN.md +1 -1
- package/templates/.opencode/commands/create-task.md +1 -1
- package/templates/.opencode/commands/create-task.zh-CN.md +1 -1
- package/templates/.opencode/commands/implement-task.md +1 -1
- package/templates/.opencode/commands/implement-task.zh-CN.md +1 -1
- package/templates/.opencode/commands/import-codescan.zh-CN.md +1 -1
- package/templates/.opencode/commands/import-dependabot.zh-CN.md +1 -1
- package/templates/.opencode/commands/import-issue.md +1 -1
- package/templates/.opencode/commands/import-issue.zh-CN.md +1 -1
- package/templates/.opencode/commands/init-labels.zh-CN.md +1 -1
- package/templates/.opencode/commands/init-milestones.md +1 -1
- package/templates/.opencode/commands/init-milestones.zh-CN.md +1 -1
- package/templates/.opencode/commands/plan-task.md +1 -1
- package/templates/.opencode/commands/plan-task.zh-CN.md +1 -1
- package/templates/.opencode/commands/refine-task.zh-CN.md +1 -1
- package/templates/.opencode/commands/refine-title.md +1 -1
- package/templates/.opencode/commands/refine-title.zh-CN.md +1 -1
- package/templates/.opencode/commands/release.md +1 -1
- package/templates/.opencode/commands/release.zh-CN.md +1 -1
- package/templates/.opencode/commands/review-task.md +1 -1
- package/templates/.opencode/commands/review-task.zh-CN.md +1 -1
- package/templates/.opencode/commands/sync-issue.md +1 -1
- package/templates/.opencode/commands/sync-issue.zh-CN.md +1 -1
- package/templates/.opencode/commands/sync-pr.md +1 -1
- package/templates/.opencode/commands/sync-pr.zh-CN.md +1 -1
- package/templates/.opencode/commands/test-integration.md +1 -1
- package/templates/.opencode/commands/test-integration.zh-CN.md +1 -1
- package/templates/.opencode/commands/test.md +1 -1
- package/templates/.opencode/commands/test.zh-CN.md +1 -1
- package/templates/.opencode/commands/update-agent-infra.md +1 -1
- package/templates/.opencode/commands/update-agent-infra.zh-CN.md +1 -1
- package/templates/.opencode/commands/upgrade-dependency.md +1 -1
- package/templates/.opencode/commands/upgrade-dependency.zh-CN.md +1 -1
- package/templates/AGENTS.md +11 -3
- package/templates/AGENTS.zh-CN.md +11 -3
- package/templates/.editorconfig +0 -15
- package/templates/.github/ISSUE_TEMPLATE/01_bug_report.yml +0 -149
- package/templates/.github/ISSUE_TEMPLATE/02_question.yml +0 -101
- package/templates/.github/ISSUE_TEMPLATE/03_feature_request.yml +0 -131
- package/templates/.github/ISSUE_TEMPLATE/04_documentation.yml +0 -165
- package/templates/.github/ISSUE_TEMPLATE/05_other.yml +0 -147
- package/templates/.github/ISSUE_TEMPLATE/config.yml +0 -11
- package/templates/.github/PULL_REQUEST_TEMPLATE.md +0 -123
- package/templates/.github/dependabot.yml +0 -17
- package/templates/.github/hooks/check-utf8-encoding.sh +0 -25
- package/templates/.github/release.yml +0 -27
- package/templates/.github/workflows/pr-title-check.yml +0 -42
- package/templates/.mailmap +0 -4
- package/templates/CONTRIBUTING.md +0 -126
- package/templates/CONTRIBUTING.zh-CN.md +0 -124
- package/templates/SECURITY.md +0 -131
- package/templates/SECURITY.zh-CN.md +0 -131
|
@@ -1,102 +1,63 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: implement-task
|
|
3
|
-
description:
|
|
4
|
-
根据技术方案实施任务,编写代码和测试,输出实现报告。当用户在技术方案审查通过后要求实施任务或编码时触发。
|
|
5
|
-
参数:task-id。
|
|
3
|
+
description: "根据技术方案实施任务并输出报告"
|
|
6
4
|
---
|
|
7
5
|
|
|
8
6
|
# 实施任务
|
|
9
7
|
|
|
8
|
+
根据已批准的技术方案实施任务,并产出 `implementation.md` 或 `implementation-r{N}.md`。
|
|
9
|
+
|
|
10
10
|
## 行为边界 / 关键规则
|
|
11
11
|
|
|
12
|
-
-
|
|
13
|
-
-
|
|
14
|
-
-
|
|
15
|
-
- 执行本技能后,你**必须**立即更新 task.md
|
|
12
|
+
- 严格遵循最新方案产物:`plan.md` 或 `plan-r{N}.md`
|
|
13
|
+
- 绝不自动执行 `git add` 或 `git commit`
|
|
14
|
+
- 每轮实现都创建新的实现产物,不覆盖旧文件
|
|
15
|
+
- 执行本技能后,你**必须**立即更新 task.md
|
|
16
16
|
|
|
17
17
|
## 执行步骤
|
|
18
18
|
|
|
19
19
|
### 1. 验证前置条件
|
|
20
20
|
|
|
21
|
-
|
|
22
|
-
- `.
|
|
21
|
+
先检查:
|
|
22
|
+
- `.agents/workspace/active/{task-id}/task.md`
|
|
23
23
|
- 至少一个技术方案产物:`plan.md` 或 `plan-r{N}.md`
|
|
24
24
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
如果任一文件缺失,提示用户先完成前置步骤。
|
|
25
|
+
如果缺少任一文件,立即停止并提示用户先完成前置步骤。
|
|
28
26
|
|
|
29
27
|
### 2. 确定输入方案与实现轮次
|
|
30
28
|
|
|
31
|
-
扫描 `.
|
|
32
|
-
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
- 如果不存在 `implementation.md` 且不存在 `implementation-r*.md` → 本轮为第 1 轮,产出 `implementation.md`
|
|
36
|
-
- 如果存在 `implementation.md` 且不存在 `implementation-r*.md` → 本轮为第 2 轮,产出 `implementation-r2.md`
|
|
37
|
-
- 如果存在 `implementation-r{N}.md` → 本轮为第 N+1 轮,产出 `implementation-r{N+1}.md`
|
|
29
|
+
扫描 `.agents/workspace/active/{task-id}/` 并记录:
|
|
30
|
+
- 最高轮次的方案文件为 `{plan-artifact}`
|
|
31
|
+
- 本轮实现产物为 `implementation.md` 或 `implementation-r{N}.md`
|
|
32
|
+
- `{implementation-round}` 与 `{implementation-artifact}`
|
|
38
33
|
|
|
39
|
-
|
|
40
|
-
- `{plan-artifact}`:本次实现遵循的技术方案文件
|
|
41
|
-
- `{implementation-round}`:本轮实现轮次
|
|
42
|
-
- `{implementation-artifact}`:本轮实现报告文件名
|
|
43
|
-
|
|
44
|
-
注意:仅在审查结论为“拒绝”后重新执行时才会进入多轮。正常首次实现始终产出 `implementation.md`。
|
|
34
|
+
如果存在 `plan-r{N}.md`,读取最高轮次的方案文件;否则读取 `plan.md`。
|
|
45
35
|
|
|
46
36
|
### 3. 阅读技术方案
|
|
47
37
|
|
|
48
|
-
仔细阅读 `{plan-artifact}
|
|
49
|
-
-
|
|
50
|
-
-
|
|
51
|
-
- 需要创建/修改的文件
|
|
38
|
+
仔细阅读 `{plan-artifact}`,提取:
|
|
39
|
+
- 实施步骤
|
|
40
|
+
- 需要创建或修改的文件
|
|
52
41
|
- 测试策略
|
|
53
|
-
-
|
|
42
|
+
- 约束、风险与已批准的取舍
|
|
54
43
|
|
|
55
44
|
### 4. 执行代码实现
|
|
56
45
|
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
**必要任务**:
|
|
60
|
-
- [ ] 按照计划实现功能代码
|
|
61
|
-
- [ ] 编写全面的单元测试
|
|
62
|
-
- [ ] 在本地运行测试以验证功能
|
|
63
|
-
- [ ] 更新相关文档和注释
|
|
64
|
-
- [ ] 遵循项目编码规范(参见项目指南)
|
|
46
|
+
按照 `.agents/workflows/feature-development.yaml` 和方案顺序实施。
|
|
65
47
|
|
|
66
|
-
|
|
67
|
-
1. **严格遵循计划**:不偏离技术方案
|
|
68
|
-
2. **逐步执行**:按顺序执行计划步骤
|
|
69
|
-
3. **持续测试**:每完成一个步骤后运行测试
|
|
70
|
-
4. **保持简单**:不过度设计,不添加计划外的功能
|
|
48
|
+
> 详细实现规则、测试纪律和偏离处理见 `reference/implementation-rules.md`。执行此步骤前,先读取 `reference/implementation-rules.md`。
|
|
71
49
|
|
|
72
50
|
### 5. 运行测试验证
|
|
73
51
|
|
|
74
|
-
|
|
52
|
+
使用 `test` 技能中的项目测试命令,直到所有必需测试通过。
|
|
75
53
|
|
|
76
|
-
|
|
77
|
-
# 查看 .agents/skills/test/SKILL.md 获取项目测试命令
|
|
78
|
-
# 常见模式:
|
|
79
|
-
# npm test (Node.js)
|
|
80
|
-
# mvn test (Maven)
|
|
81
|
-
# pytest (Python)
|
|
82
|
-
# go test ./... (Go)
|
|
83
|
-
```
|
|
84
|
-
|
|
85
|
-
如果测试失败:
|
|
86
|
-
- 先分析失败原因,优先修复由本次实现引入的问题,以及为匹配已批准方案而需要同步调整的测试或文档
|
|
87
|
-
- 修复后重新运行测试,直到测试通过,或明确确认存在超出当前任务范围的外部阻塞
|
|
88
|
-
- 仅当问题属于外部阻塞、环境缺失或需求不明确且无法在当前任务内解决时,才向用户报告阻塞并停止;此时不要创建实现报告,不要更新 task.md 为实现完成,也不要输出步骤 8 的完成模板
|
|
54
|
+
如果测试失败,先尝试修复并重新运行测试。只有在确认存在外部阻塞、环境缺失或需求不明确且超出任务范围时,才可以停止。
|
|
89
55
|
|
|
90
|
-
|
|
56
|
+
### 6. 编写实现报告
|
|
91
57
|
|
|
92
|
-
|
|
58
|
+
创建 `.agents/workspace/active/{task-id}/{implementation-artifact}`。
|
|
93
59
|
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
要求:
|
|
97
|
-
- 不要覆盖已有的实现报告
|
|
98
|
-
- 在报告中明确记录本轮轮次编号和实际产物文件名
|
|
99
|
-
- 如果本轮是重实现,说明其触发原因(例如上一轮审查结论为 Rejected)
|
|
60
|
+
> 报告结构、必填章节和完整模板见 `reference/report-template.md`。写报告前先读取 `reference/report-template.md`。
|
|
100
61
|
|
|
101
62
|
### 7. 更新任务状态
|
|
102
63
|
|
|
@@ -106,127 +67,38 @@ description: >
|
|
|
106
67
|
date "+%Y-%m-%d %H:%M:%S"
|
|
107
68
|
```
|
|
108
69
|
|
|
109
|
-
更新 `.
|
|
70
|
+
更新 `.agents/workspace/active/{task-id}/task.md`:
|
|
110
71
|
- `current_step`:implementation
|
|
111
|
-
- `assigned_to`:{
|
|
72
|
+
- `assigned_to`:{当前代理}
|
|
112
73
|
- `updated_at`:{当前时间}
|
|
113
|
-
-
|
|
114
|
-
-
|
|
115
|
-
-
|
|
116
|
-
```
|
|
117
|
-
- {yyyy-MM-dd HH:mm:ss} — **Implementation (Round {N})** by {agent} — Code implemented, {n} files modified, {n} tests passed → {artifact-filename}
|
|
118
|
-
```
|
|
74
|
+
- 记录 Round `{implementation-round}` 的 `{implementation-artifact}`
|
|
75
|
+
- 追加:
|
|
76
|
+
`- {yyyy-MM-dd HH:mm:ss} — **Implementation (Round {N})** by {agent} — Code implemented, {n} files modified, {n} tests passed → {implementation-artifact}`
|
|
119
77
|
|
|
120
78
|
### 8. 告知用户
|
|
121
79
|
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
输出格式:
|
|
125
|
-
```
|
|
126
|
-
任务 {task-id} 实现完成。
|
|
127
|
-
|
|
128
|
-
摘要:
|
|
129
|
-
- 修改文件:{数量}
|
|
130
|
-
- 新建文件:{数量}
|
|
131
|
-
- 测试通过:{数量}/{总数}
|
|
132
|
-
|
|
133
|
-
产出文件:
|
|
134
|
-
- 实现报告:.agent-workspace/active/{task-id}/{implementation-artifact}(Round {implementation-round})
|
|
135
|
-
|
|
136
|
-
下一步 - 代码审查:
|
|
137
|
-
- Claude Code / OpenCode:/review-task {task-id}
|
|
138
|
-
- Gemini CLI:/{{project}}:review-task {task-id}
|
|
139
|
-
- Codex CLI:$review-task {task-id}
|
|
140
|
-
```
|
|
141
|
-
|
|
142
|
-
## 输出模板
|
|
143
|
-
|
|
144
|
-
```markdown
|
|
145
|
-
# 实现报告
|
|
146
|
-
|
|
147
|
-
- **实现轮次**:Round {implementation-round}
|
|
148
|
-
- **产物文件**:`{implementation-artifact}`
|
|
149
|
-
|
|
150
|
-
## 修改文件
|
|
151
|
-
|
|
152
|
-
### 新建文件
|
|
153
|
-
- `{file-path}` - {描述}
|
|
154
|
-
|
|
155
|
-
### 修改文件
|
|
156
|
-
- `{file-path}` - {变更摘要}
|
|
157
|
-
|
|
158
|
-
## 关键代码说明
|
|
159
|
-
|
|
160
|
-
### {模块/功能名称}
|
|
161
|
-
**文件**:`{file-path}:{line-number}`
|
|
162
|
-
|
|
163
|
-
**实现逻辑**:
|
|
164
|
-
{重要逻辑的说明}
|
|
165
|
-
|
|
166
|
-
**关键代码**:
|
|
167
|
-
```{language}
|
|
168
|
-
{关键代码片段}
|
|
169
|
-
```
|
|
170
|
-
|
|
171
|
-
## 测试结果
|
|
172
|
-
|
|
173
|
-
### 单元测试
|
|
174
|
-
- 测试文件:`{test-file-path}`
|
|
175
|
-
- 测试用例数:{数量}
|
|
176
|
-
- 通过率:{百分比}
|
|
177
|
-
|
|
178
|
-
**测试输出**:
|
|
179
|
-
```
|
|
180
|
-
{测试运行结果}
|
|
181
|
-
```
|
|
182
|
-
|
|
183
|
-
## 与计划的差异
|
|
184
|
-
|
|
185
|
-
{如果实现与计划有差异,说明原因}
|
|
186
|
-
|
|
187
|
-
## 审查关注点
|
|
188
|
-
|
|
189
|
-
**需要审查者注意的要点**:
|
|
190
|
-
- {关注点 1}
|
|
191
|
-
- {关注点 2}
|
|
192
|
-
|
|
193
|
-
## 已知问题
|
|
194
|
-
|
|
195
|
-
{实现过程中发现的问题或后续需要优化的事项}
|
|
196
|
-
|
|
197
|
-
## 后续步骤
|
|
198
|
-
|
|
199
|
-
{代码审查或后续工作的建议}
|
|
200
|
-
```
|
|
80
|
+
输出实现摘要,并完整展示下一步代码审查的所有 TUI 命令格式。
|
|
201
81
|
|
|
202
82
|
## 完成检查清单
|
|
203
83
|
|
|
204
|
-
- [ ]
|
|
205
|
-
- [ ]
|
|
206
|
-
- [ ]
|
|
207
|
-
- [ ]
|
|
208
|
-
- [ ]
|
|
209
|
-
- [ ] 更新了 task.md 中的 `assigned_to`
|
|
210
|
-
- [ ] 追加了 Activity Log 条目到 task.md
|
|
211
|
-
- [ ] 在工作流进度中标记了 implementation 为已完成
|
|
212
|
-
- [ ] 告知了用户下一步(必须展示所有 TUI 的命令格式,不要筛选)
|
|
84
|
+
- [ ] 已完成批准范围内的代码实现
|
|
85
|
+
- [ ] 已创建 `{implementation-artifact}`
|
|
86
|
+
- [ ] 所有必需测试通过
|
|
87
|
+
- [ ] 已更新 task.md 并追加 Activity Log
|
|
88
|
+
- [ ] 已向用户展示所有 TUI 格式的下一步命令
|
|
213
89
|
|
|
214
90
|
## 停止
|
|
215
91
|
|
|
216
|
-
|
|
92
|
+
完成检查清单后立即停止。不要自动提交。
|
|
217
93
|
|
|
218
94
|
## 注意事项
|
|
219
95
|
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
4. **代码质量**:遵循项目编码规范
|
|
224
|
-
5. **计划偏离**:如果需要偏离计划,在实现报告中记录原因
|
|
225
|
-
6. **版本化规则**:首轮实现使用 `implementation.md`;后续重实现使用 `implementation-r{N}.md`
|
|
96
|
+
- 首轮实现使用 `implementation.md`,后续轮次使用 `implementation-r{N}.md`
|
|
97
|
+
- 如偏离 `{plan-artifact}`,必须在报告中记录原因
|
|
98
|
+
- 新测试必须验证有意义的业务行为,而不是机械透传
|
|
226
99
|
|
|
227
100
|
## 错误处理
|
|
228
101
|
|
|
229
|
-
-
|
|
230
|
-
-
|
|
231
|
-
-
|
|
232
|
-
- 构建失败:输出构建错误,停止实现
|
|
102
|
+
- 任务未找到:`Task {task-id} not found`
|
|
103
|
+
- 缺少方案:`Technical plan not found, please run the plan-task skill first`
|
|
104
|
+
- 本地修复后仍无法通过测试:说明外部阻塞并停止,且不要创建实现产物
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# Implementation Rules
|
|
2
|
+
|
|
3
|
+
Read this file before coding or interpreting test failures.
|
|
4
|
+
|
|
5
|
+
## Execute Code Implementation
|
|
6
|
+
|
|
7
|
+
Follow the `implementation` step in `.agents/workflows/feature-development.yaml`.
|
|
8
|
+
|
|
9
|
+
**Required tasks**:
|
|
10
|
+
- [ ] implement the feature code according to the plan
|
|
11
|
+
- [ ] write comprehensive unit tests
|
|
12
|
+
- [ ] run tests locally to validate the feature
|
|
13
|
+
- [ ] update related documentation and comments
|
|
14
|
+
- [ ] follow project coding standards
|
|
15
|
+
|
|
16
|
+
**Implementation principles**:
|
|
17
|
+
1. **Follow the plan strictly**: do not deviate from the technical plan
|
|
18
|
+
2. **Work step by step**: execute the planned sequence
|
|
19
|
+
3. **Keep testing continuously**: re-run tests as work progresses
|
|
20
|
+
4. **Keep it simple**: do not add unplanned features
|
|
21
|
+
|
|
22
|
+
## Run Test Verification
|
|
23
|
+
|
|
24
|
+
Run the project test command. Refer to the `test` skill for project-specific commands.
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
# See .agents/skills/test/SKILL.md for the project's test command
|
|
28
|
+
# Common patterns:
|
|
29
|
+
# npm test (Node.js)
|
|
30
|
+
# mvn test (Maven)
|
|
31
|
+
# pytest (Python)
|
|
32
|
+
# go test ./... (Go)
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
If tests fail:
|
|
36
|
+
- analyze the failure first and prioritize fixing issues introduced by this implementation
|
|
37
|
+
- re-run tests after each fix until they pass, or confirm that the problem is an external blocker
|
|
38
|
+
- only stop without producing the implementation artifact when the failure is caused by an external blocker, missing environment, or unclear requirement that cannot be resolved inside the task
|
|
39
|
+
|
|
40
|
+
Two-way failure handling:
|
|
41
|
+
1. implementation-caused failures:
|
|
42
|
+
- fix the code, tests, docs, or fixtures introduced by this implementation
|
|
43
|
+
- re-run the test command after each fix
|
|
44
|
+
- continue until all required tests pass
|
|
45
|
+
2. external blockers:
|
|
46
|
+
- confirm the failure comes from missing environment, unrelated upstream breakage, or unclear requirements outside this task
|
|
47
|
+
- stop without creating `implementation.md` / `implementation-r{N}.md`
|
|
48
|
+
- do not mark implementation complete in `task.md`
|
|
49
|
+
- do not output the normal success/next-step template
|
|
50
|
+
|
|
51
|
+
## Notes
|
|
52
|
+
|
|
53
|
+
1. **Prerequisite**: the approved technical plan must exist (`plan.md` or `plan-r{N}.md`)
|
|
54
|
+
2. **No auto-commit**: do not run `git commit` or `git add`
|
|
55
|
+
3. **Test quality**: new tests must validate meaningful business logic
|
|
56
|
+
4. **Code quality**: follow project coding conventions
|
|
57
|
+
5. **Plan deviation**: record any deviation in the implementation report
|
|
58
|
+
6. **Versioning**: Round 1 uses `implementation.md`; later rounds use `implementation-r{N}.md`
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# 实现规则
|
|
2
|
+
|
|
3
|
+
在编写代码或判断测试失败原因之前先读取本文件。
|
|
4
|
+
|
|
5
|
+
## 执行代码实现
|
|
6
|
+
|
|
7
|
+
遵循 `.agents/workflows/feature-development.yaml` 中的 `implementation` 步骤。
|
|
8
|
+
|
|
9
|
+
**必做任务**:
|
|
10
|
+
- [ ] 按计划实现功能代码
|
|
11
|
+
- [ ] 编写完整的单元测试
|
|
12
|
+
- [ ] 在本地运行测试验证功能
|
|
13
|
+
- [ ] 更新相关文档和注释
|
|
14
|
+
- [ ] 遵守项目编码规范
|
|
15
|
+
|
|
16
|
+
**实现原则**:
|
|
17
|
+
1. **严格遵循方案**:不要偏离技术方案
|
|
18
|
+
2. **按步骤推进**:按计划顺序执行
|
|
19
|
+
3. **持续测试**:实现过程中持续重新运行测试
|
|
20
|
+
4. **保持简单**:不要加入未计划的功能
|
|
21
|
+
|
|
22
|
+
## 运行测试验证
|
|
23
|
+
|
|
24
|
+
运行项目测试命令。项目特定命令请参考 `test` skill。
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
# 参考 .agents/skills/test/SKILL.md 中的项目测试命令
|
|
28
|
+
# 常见模式:
|
|
29
|
+
# npm test (Node.js)
|
|
30
|
+
# mvn test (Maven)
|
|
31
|
+
# pytest (Python)
|
|
32
|
+
# go test ./... (Go)
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
如果测试失败:
|
|
36
|
+
- 先分析失败原因,并优先修复由本次实现引入的问题
|
|
37
|
+
- 每次修复后重新运行测试,直到通过,或者确认问题属于外部阻塞
|
|
38
|
+
- 只有当失败由外部阻塞、环境缺失或当前任务内无法澄清的需求问题导致时,才允许在不生成实现产物的情况下停止
|
|
39
|
+
|
|
40
|
+
双分支失败处理:
|
|
41
|
+
1. 本次实现引入的失败:
|
|
42
|
+
- 修复由本次实现引入的代码、测试、文档或 fixture 问题
|
|
43
|
+
- 每次修复后重新运行测试命令
|
|
44
|
+
- 持续处理直到所有必需测试通过
|
|
45
|
+
2. 外部阻塞:
|
|
46
|
+
- 确认失败来自缺失环境、无关的上游损坏,或任务范围外的需求不明确
|
|
47
|
+
- 停止,并且不要创建 `implementation.md` / `implementation-r{N}.md`
|
|
48
|
+
- 不要在 `task.md` 中把实现标记为完成
|
|
49
|
+
- 不要输出正常的成功/下一步模板
|
|
50
|
+
|
|
51
|
+
## 注意事项
|
|
52
|
+
|
|
53
|
+
1. **前置条件**:必须存在已批准的技术方案(`plan.md` 或 `plan-r{N}.md`)
|
|
54
|
+
2. **禁止自动提交**:不要执行 `git commit` 或 `git add`
|
|
55
|
+
3. **测试质量**:新增测试必须验证有意义的业务逻辑
|
|
56
|
+
4. **代码质量**:遵循项目编码规范
|
|
57
|
+
5. **方案偏离**:任何偏离都要记录到实现报告中
|
|
58
|
+
6. **版本命名**:Round 1 使用 `implementation.md`,后续轮次使用 `implementation-r{N}.md`
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
# Implementation Report Template
|
|
2
|
+
|
|
3
|
+
Use this structure when creating `implementation.md` or `implementation-r{N}.md`.
|
|
4
|
+
|
|
5
|
+
## Output Template
|
|
6
|
+
|
|
7
|
+
```markdown
|
|
8
|
+
# Implementation Report
|
|
9
|
+
|
|
10
|
+
- **Implementation Round**: Round {implementation-round}
|
|
11
|
+
- **Artifact File**: `{implementation-artifact}`
|
|
12
|
+
|
|
13
|
+
## Modified Files
|
|
14
|
+
|
|
15
|
+
### New Files
|
|
16
|
+
- `{file-path}` - {description}
|
|
17
|
+
|
|
18
|
+
### Modified Files
|
|
19
|
+
- `{file-path}` - {change summary}
|
|
20
|
+
|
|
21
|
+
## Key Code Explanation
|
|
22
|
+
|
|
23
|
+
### {Module/Feature Name}
|
|
24
|
+
**File**: `{file-path}:{line-number}`
|
|
25
|
+
|
|
26
|
+
**Implementation Logic**:
|
|
27
|
+
{important logic summary}
|
|
28
|
+
|
|
29
|
+
**Key Code**:
|
|
30
|
+
```{language}
|
|
31
|
+
{key-code-snippet}
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## Test Results
|
|
35
|
+
|
|
36
|
+
### Unit Tests
|
|
37
|
+
- Test file: `{test-file-path}`
|
|
38
|
+
- Test case count: {count}
|
|
39
|
+
- Pass rate: {percentage}
|
|
40
|
+
|
|
41
|
+
**Test Output**:
|
|
42
|
+
```
|
|
43
|
+
{test-run-output}
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
## Differences from Plan
|
|
47
|
+
|
|
48
|
+
{describe any deviation from the approved plan}
|
|
49
|
+
|
|
50
|
+
## Items for Review
|
|
51
|
+
|
|
52
|
+
**Focus areas for reviewers**:
|
|
53
|
+
- {item 1}
|
|
54
|
+
- {item 2}
|
|
55
|
+
|
|
56
|
+
## Known Issues
|
|
57
|
+
|
|
58
|
+
{known issues or follow-up ideas}
|
|
59
|
+
|
|
60
|
+
## Next Steps
|
|
61
|
+
|
|
62
|
+
{recommended follow-up}
|
|
63
|
+
```
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
# 实现报告模板
|
|
2
|
+
|
|
3
|
+
创建 `implementation.md` 或 `implementation-r{N}.md` 时,使用以下结构。
|
|
4
|
+
|
|
5
|
+
## 输出模板
|
|
6
|
+
|
|
7
|
+
```markdown
|
|
8
|
+
# 实现报告
|
|
9
|
+
|
|
10
|
+
- **实现轮次**: Round {implementation-round}
|
|
11
|
+
- **产物文件**: `{implementation-artifact}`
|
|
12
|
+
|
|
13
|
+
## 变更文件
|
|
14
|
+
|
|
15
|
+
### 新建文件
|
|
16
|
+
- `{file-path}` - {description}
|
|
17
|
+
|
|
18
|
+
### 修改文件
|
|
19
|
+
- `{file-path}` - {change summary}
|
|
20
|
+
|
|
21
|
+
## 关键代码说明
|
|
22
|
+
|
|
23
|
+
### {模块/功能名称}
|
|
24
|
+
**文件**: `{file-path}:{line-number}`
|
|
25
|
+
|
|
26
|
+
**实现逻辑**:
|
|
27
|
+
{important logic summary}
|
|
28
|
+
|
|
29
|
+
**关键代码**:
|
|
30
|
+
```{language}
|
|
31
|
+
{key-code-snippet}
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## 测试结果
|
|
35
|
+
|
|
36
|
+
### 单元测试
|
|
37
|
+
- 测试文件: `{test-file-path}`
|
|
38
|
+
- 测试用例数: {count}
|
|
39
|
+
- 通过率: {percentage}
|
|
40
|
+
|
|
41
|
+
**测试输出**:
|
|
42
|
+
```
|
|
43
|
+
{test-run-output}
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
## 与方案的差异
|
|
47
|
+
|
|
48
|
+
{describe any deviation from the approved plan}
|
|
49
|
+
|
|
50
|
+
## 供审查关注的内容
|
|
51
|
+
|
|
52
|
+
**建议审查者重点关注**:
|
|
53
|
+
- {item 1}
|
|
54
|
+
- {item 2}
|
|
55
|
+
|
|
56
|
+
## 已知问题
|
|
57
|
+
|
|
58
|
+
{known issues or follow-up ideas}
|
|
59
|
+
|
|
60
|
+
## 下一步
|
|
61
|
+
|
|
62
|
+
{recommended follow-up}
|
|
63
|
+
```
|
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: import-codescan
|
|
3
|
-
description:
|
|
4
|
-
Import a Code Scanning (CodeQL) alert and create a remediation task.
|
|
5
|
-
Triggered when the user asks to import a Code Scanning alert.
|
|
6
|
-
Argument: alert number.
|
|
3
|
+
description: "Import a Code Scanning alert and create a remediation task"
|
|
7
4
|
---
|
|
8
5
|
|
|
9
6
|
# Import Code Scanning Alert
|
|
@@ -36,7 +33,7 @@ Extract key information:
|
|
|
36
33
|
|
|
37
34
|
Check whether a task for this alert already exists. If not, create one:
|
|
38
35
|
|
|
39
|
-
Directory: `.
|
|
36
|
+
Directory: `.agents/workspace/active/TASK-{yyyyMMdd-HHmmss}/`
|
|
40
37
|
|
|
41
38
|
Task metadata:
|
|
42
39
|
```yaml
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: import-codescan
|
|
3
|
-
description:
|
|
4
|
-
导入 Code Scanning(CodeQL)告警并创建修复任务。
|
|
5
|
-
当用户要求导入 Code Scanning 告警时触发。参数:告警编号。
|
|
3
|
+
description: "导入 Code Scanning 告警并创建修复任务"
|
|
6
4
|
---
|
|
7
5
|
|
|
8
6
|
# 导入 Code Scanning 告警
|
|
@@ -35,7 +33,7 @@ gh api repos/{owner}/{repo}/code-scanning/alerts/<alert-number>
|
|
|
35
33
|
|
|
36
34
|
检查是否已存在该告警的任务。如果不存在,创建:
|
|
37
35
|
|
|
38
|
-
目录:`.
|
|
36
|
+
目录:`.agents/workspace/active/TASK-{yyyyMMdd-HHmmss}/`
|
|
39
37
|
|
|
40
38
|
任务元数据:
|
|
41
39
|
```yaml
|
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: import-dependabot
|
|
3
|
-
description:
|
|
4
|
-
Import a Dependabot security alert and create a remediation task.
|
|
5
|
-
Triggered when the user asks to import a Dependabot alert.
|
|
6
|
-
Argument: alert number.
|
|
3
|
+
description: "Import a Dependabot alert and create a remediation task"
|
|
7
4
|
---
|
|
8
5
|
|
|
9
6
|
# Import Dependabot Security Alert
|
|
@@ -33,11 +30,11 @@ Extract key information:
|
|
|
33
30
|
|
|
34
31
|
### 2. Create the Task Directory and File
|
|
35
32
|
|
|
36
|
-
Check whether `.
|
|
33
|
+
Check whether `.agents/workspace/active/` already has a task for this alert.
|
|
37
34
|
- If found, ask the user whether to re-import
|
|
38
35
|
- If not found, create a new task
|
|
39
36
|
|
|
40
|
-
Create directory: `.
|
|
37
|
+
Create directory: `.agents/workspace/active/TASK-{yyyyMMdd-HHmmss}/`
|
|
41
38
|
|
|
42
39
|
Task metadata must include:
|
|
43
40
|
```yaml
|
|
@@ -78,7 +75,7 @@ Task information:
|
|
|
78
75
|
- Task ID: {task-id}
|
|
79
76
|
|
|
80
77
|
Output file:
|
|
81
|
-
- Task file: .
|
|
78
|
+
- Task file: .agents/workspace/active/{task-id}/task.md
|
|
82
79
|
|
|
83
80
|
Next step:
|
|
84
81
|
- Claude Code / OpenCode: /analyze-task {task-id}
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: import-dependabot
|
|
3
|
-
description:
|
|
4
|
-
导入 Dependabot 安全告警并创建修复任务。
|
|
5
|
-
当用户要求导入 Dependabot 告警时触发。参数:告警编号。
|
|
3
|
+
description: "导入 Dependabot 安全告警并创建修复任务"
|
|
6
4
|
---
|
|
7
5
|
|
|
8
6
|
# 导入 Dependabot 安全告警
|
|
@@ -32,11 +30,11 @@ gh api repos/{owner}/{repo}/dependabot/alerts/<alert-number>
|
|
|
32
30
|
|
|
33
31
|
### 2. 创建任务目录和文件
|
|
34
32
|
|
|
35
|
-
检查 `.
|
|
33
|
+
检查 `.agents/workspace/active/` 中是否已存在该告警的任务。
|
|
36
34
|
- 如果找到,询问用户是否重新导入
|
|
37
35
|
- 如果未找到,创建新任务
|
|
38
36
|
|
|
39
|
-
创建目录:`.
|
|
37
|
+
创建目录:`.agents/workspace/active/TASK-{yyyyMMdd-HHmmss}/`
|
|
40
38
|
|
|
41
39
|
任务元数据需包含:
|
|
42
40
|
```yaml
|
|
@@ -77,7 +75,7 @@ date "+%Y-%m-%d %H:%M:%S"
|
|
|
77
75
|
- 任务 ID:{task-id}
|
|
78
76
|
|
|
79
77
|
产出文件:
|
|
80
|
-
- 任务文件:.
|
|
78
|
+
- 任务文件:.agents/workspace/active/{task-id}/task.md
|
|
81
79
|
|
|
82
80
|
下一步:
|
|
83
81
|
- Claude Code / OpenCode:/analyze-task {task-id}
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: import-issue
|
|
3
|
-
description:
|
|
4
|
-
Import from a GitHub Issue and create a task file.
|
|
5
|
-
Triggered when the user asks to import an Issue. Argument: issue number.
|
|
3
|
+
description: "Import a GitHub Issue and create a task"
|
|
6
4
|
---
|
|
7
5
|
|
|
8
6
|
# Import Issue
|
|
@@ -27,7 +25,7 @@ Extract: issue number, title, description, and labels.
|
|
|
27
25
|
|
|
28
26
|
### 2. Check for an Existing Task
|
|
29
27
|
|
|
30
|
-
Search `.
|
|
28
|
+
Search `.agents/workspace/active/` for an existing task linked to this Issue.
|
|
31
29
|
- If found, ask the user whether to re-import or continue with the existing task
|
|
32
30
|
- If not found, create a new task
|
|
33
31
|
|
|
@@ -37,7 +35,7 @@ Search `.agent-workspace/active/` for an existing task linked to this Issue.
|
|
|
37
35
|
date +%Y%m%d-%H%M%S
|
|
38
36
|
```
|
|
39
37
|
|
|
40
|
-
- Create the directory: `.
|
|
38
|
+
- Create the directory: `.agents/workspace/active/TASK-{yyyyMMdd-HHmmss}/`
|
|
41
39
|
- Use the `.agents/templates/task.md` template to create `task.md`
|
|
42
40
|
|
|
43
41
|
Task metadata:
|
|
@@ -62,7 +60,7 @@ Get the current time:
|
|
|
62
60
|
date "+%Y-%m-%d %H:%M:%S"
|
|
63
61
|
```
|
|
64
62
|
|
|
65
|
-
Update `.
|
|
63
|
+
Update `.agents/workspace/active/{task-id}/task.md`:
|
|
66
64
|
- `current_step`: requirement-analysis
|
|
67
65
|
- `assigned_to`: {current AI agent}
|
|
68
66
|
- `updated_at`: {current time}
|
|
@@ -84,7 +82,7 @@ Task information:
|
|
|
84
82
|
- Workflow: {workflow}
|
|
85
83
|
|
|
86
84
|
Output file:
|
|
87
|
-
- Task file: .
|
|
85
|
+
- Task file: .agents/workspace/active/{task-id}/task.md
|
|
88
86
|
|
|
89
87
|
Next step - run requirements analysis:
|
|
90
88
|
- Claude Code / OpenCode: /analyze-task {task-id}
|
|
@@ -94,7 +92,7 @@ Next step - run requirements analysis:
|
|
|
94
92
|
|
|
95
93
|
## Completion Checklist
|
|
96
94
|
|
|
97
|
-
- [ ] Created the task file `.
|
|
95
|
+
- [ ] Created the task file `.agents/workspace/active/{task-id}/task.md`
|
|
98
96
|
- [ ] Recorded `issue_number` in task.md
|
|
99
97
|
- [ ] Updated `current_step` to requirement-analysis
|
|
100
98
|
- [ ] Updated `updated_at` to the current time
|