agent-project-sdlc 0.1.22 → 0.1.24
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 +13 -5
- package/assets/agents/AGENTS_CORE.md +7 -1
- package/assets/docs/README.md +14 -6
- package/assets/policies/phase_contracts.yaml +136 -12
- package/assets/skills/pjsdlc_architect_design/SKILL.md +7 -1
- package/assets/skills/pjsdlc_dev_sprint/SKILL.md +10 -6
- package/assets/skills/pjsdlc_implementation_doc/SKILL.md +5 -4
- package/assets/skills/pjsdlc_manager/SKILL.md +9 -6
- package/assets/skills/pjsdlc_reviewer/SKILL.md +2 -2
- package/assets/skills/pjsdlc_rfc_recalibrate/SKILL.md +3 -3
- package/assets/skills/pjsdlc_tester/SKILL.md +8 -5
- package/assets/templates/EVIDENCE_INDEX_TEMPLATE.md +2 -1
- package/assets/templates/EXPLORATION_APPENDIX_TEMPLATE.md +2 -0
- package/assets/templates/IMPLEMENTATION_DOC_TEMPLATE.md +27 -6
- package/assets/templates/PLAN_TEMPLATE.yaml +31 -1
- package/assets/templates/RUNBOOK_TEMPLATE.md +10 -5
- package/assets/templates/TEST_REPORT_TEMPLATE.md +1 -0
- package/assets/tools/harness_utils.py +388 -18
- package/assets/tools/transition.py +24 -31
- package/assets/tools/validate_design.py +5 -0
- package/assets/tools/validate_harness.py +14 -1
- package/assets/tools/validate_prompt_language.py +1 -1
- package/assets/tools/validate_rfc.py +5 -0
- package/dist/lib/init.js +1 -1
- package/dist/lib/validators.js +567 -6
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -83,15 +83,23 @@ Release docs are current-state facts, not a version ledger. New release work sho
|
|
|
83
83
|
|
|
84
84
|
The generic rule is that any workflow promoting a draft task into a formal `TASK-*` in `plan.yaml` must remove the source draft from its draft queue in the same state update. The formal task is then recovered only from `plan.yaml`; completed history lives in implementation docs, git, PR and CI records. The built-in Harness draft queue is currently `plan.draft.yaml.tasks[]`, which means unadopted development drafts only. `/devloop` treats the development queue as exhausted only when both `plan.yaml.tasks[]` and `plan.draft.yaml.tasks[]` have no executable task.
|
|
85
85
|
|
|
86
|
-
|
|
86
|
+
Phase routing is expressed as a lightweight explicit directed graph in `<harnessRoot>/pjsdlc_managed/policies/phase_contracts.yaml`: `phases` stores stable phase contracts, while `transitions` stores legal edges and small runtime effects such as setting or clearing `suspended_phase`. This makes normal advance, pre-development return, TESTING bugfix return, RFC interrupt/resume and BLOCKED resume rules consumable by both the transition helper and validators. It is intentionally not a heavy graph engine: no history graph, traversal framework, node/edge classes or visualizer are introduced; the goal is to reduce missed rules and drift.
|
|
87
87
|
|
|
88
|
-
|
|
88
|
+
Migration cost is low for projects that use managed assets: run `npx sdlc-harness upgrade` to sync the new `phase_contracts.yaml` and `tools/transition.py`, or run `npx sdlc-harness sync` if only managed files need refreshing. `lifecycle.yaml` and `plan.yaml` do not need manual migration; old `allowed_next_phases` values are regenerated from the graph on the next transition. Projects with custom phase policies should convert node-local `next` / `returns` to top-level `transitions`, and add the `TESTING -> ARCHITECTING` / `TESTING -> SPRINTING` bugfix return edges when they want the new routing. If the new `validate-harness` reports missing `transitions`, run `upgrade` or `sync` before validating again.
|
|
89
89
|
|
|
90
|
-
|
|
90
|
+
Before development starts, `ARCHITECTING` can return to `REQUIREMENT_GATHERING` for PRD edits. The manager uses `python3 tools/transition.py --to REQUIREMENT_GATHERING`, the PM workflow updates the PRD through one `TASK-*`, then `validate-pm` and `python3 tools/transition.py --to ARCHITECTING` return the project to design. Requirement, acceptance or product-boundary changes after `SPRINTING` use RFC recalibration; `SPRINTING`, `REVIEWING`, `TESTING` and `RELEASING` can enter the controlled interrupt with `python3 tools/transition.py --to RFC_RECALIBRATION`, then return to `SPRINTING` after `validate-rfc`.
|
|
91
91
|
|
|
92
|
-
|
|
92
|
+
When TESTING finds a bug, first record `Bugfix Route` in `.docs/07_test/TEST_REPORT.md`, then let the manager choose the lightweight return. `bugfix_replan` uses `python3 tools/transition.py --to ARCHITECTING` when the technical plan, interface contract, task breakdown, Development Self-Test Contract or Module Key Test Graph must change. `bugfix_implementation_gap` uses `python3 tools/transition.py --to SPRINTING` only when the technical plan is still correct and implementation deviated from it. Requirement, acceptance or product-boundary changes still use RFC recalibration.
|
|
93
93
|
|
|
94
|
-
`
|
|
94
|
+
`validate-design` treats semantic slicing as a hard gate. Generated `overview.md` files do not count as deliverables, development draft tasks in `plan.draft.yaml` must reference existing tech plan slices through `docs.tech_plan`, multiple development draft tasks need distinct primary tech plan slices, and explicit AI provider/copilot, external-system, or compliance/permission/audit themes require dedicated architecture slices. Draft tasks with runnable boundaries must also include `self_test_contract`, backed by a `Development Self-Test Contract` section in the tech plan; the contract must include `module_key_test_path` from local start or invocation to all self-test scenarios completion, covering every runnable entry promised by the current task/module and its internal key paths. Complex or high-risk paths may set `graph_required: true` and provide `module_key_test_graph` to express entries, checkpoints, scenarios, exits and evidence refs as a lightweight DAG.
|
|
95
|
+
|
|
96
|
+
SPRINTING Definition of Done includes module-level runnable delivery boundaries. API, CLI, server route, service, agent, runtime, adapter, worker, provider, config-contract and fixture/live boundaries promised by a technical plan or task must be implemented or marked `BLOCKED` during development. Runtime/app/provider/live tasks must declare `evidence_level.required`, `target_runtime_environment` and `self_test_contract` in `plan.yaml`; every gate in `self_test_contract.required_gates` must also appear in task `required_gates`, and `self_test_contract.module_key_test_path` must describe the path from local start or invocation to all self-test scenarios completion, covering every runnable entry promised by the current task/module and its internal key paths. Complex task `module_key_test_graph` is the canonical handoff path detail: it is a DAG instead of a tree because scenarios can share setup and converge on the same observable exit; it is not a heavy test execution graph and must not store traces, debug logs, operator logs, runbook bodies or evidence bodies. `deployed_runtime` cannot be closed by `unit`, `local_runtime`, `external_provider_live`, provider smoke, fake adapters or localhost smoke alone, and `business_handoff_ready` requires a Testing Handoff Contract. The current task implementation doc must include `Development Evidence` and a completed `Development Self-Test Report` with `Report Status: PASS | BLOCKED | IN_PROGRESS | STALE`, contract source, Module Application Entry, scenario results, executed gates, Module Key Test Path, Module Key Test Graph when required, Observable Exit, Current Blocker, Testing Handoff Readiness and Evidence Index Refs; only `Report Status: PASS` with every scenario `PASS` can close a development task. The report proves module entry, core path, exit and minimal evidence pointers; it is not a debug log, operator log, runbook, evidence dump or exploration history. Fallback/diagnostic detail belongs in `.docs/09_runbooks/**` evidence indexes, appendices or git history. The report must not use an `Actual Evidence` body field, should stay under 80 lines for ordinary tasks and under 120 lines for high-risk runtime tasks. Module Key Test Path records actual entries, internal key paths, boundaries, checkpoints and observable completion evidence. Provider smoke, fixture smoke, fake adapters and one-shot smoke prove only local links; they do not by themselves prove application readiness. REVIEWING treats missing entry/exit, initialization, config contract, target runtime, evidence level or development evidence as blocking, and TESTING only exercises entrypoints that Review has confirmed as `PASS`; complex paths are consumed through Module Key Test Graph, and TESTING must not add product runtime, bootstrap, provider adapter, deploy code or package runtime scripts.
|
|
97
|
+
|
|
98
|
+
High-risk runtime/live/remote-operator tasks are resume-first. When the current SPRINTING task requires `external_provider_live`, `deployed_runtime` or `business_handoff_ready`, or its target runtime is `cloud_vm`, `managed_service`, `browser` or `worker`, `plan.yaml` must include top-level `resume_capsule` with the current state, canonical path, next step, blocker, last passed gate, do-not-retry list and recovery refs. Any judgment that changes the next action must be promoted to `resume_capsule.do_not_retry`, the runbook top-level `Hard Constraints`, or the short `Current Operator Path`; it cannot live only in evidence, notes, an appendix, or a long implementation doc. The validator scans `working_notes`, implementation docs and runbooks for session / QR / canonical path / do-not-retry judgments and fails when they are not promoted. Open task `working_notes` stays short, with a 5-8 item target and an 8 item validator limit. Long-term implementation facts stay in the implementation doc; operator paths, credential references and remote entrypoints live in `.docs/09_runbooks/**`; the implementation doc only keeps a short `Current Operator Path` with canonical operator path, runbook link, credential reference name, command/UI channel, hard constraints and do-not-retry summary. Evidence bodies live in an evidence index or external system and must not move into implementation-doc mainline sections such as `Evidence Dump`, `Operator Log`, `Failed Attempts`, or `Screenshot Index`; failed exploration stays in an exploration appendix. The Development Self-Test Report for these tasks must include a Gate Breakdown that separates local gate, cloud/service gate, executor/operator readiness and live smoke or handoff evidence.
|
|
99
|
+
|
|
100
|
+
`make validate-dev` and `npx sdlc-harness validate-dev` are in-development SPRINTING gates. They allow the current `current_task_id` open task to remain in `plan.yaml` while checking that it is a valid `phase: "SPRINTING"` task with `docs`, `allowed_paths`, `required_gates`, `acceptance_criteria`, `implementation_doc`, scoped dirty files, an empty `plan.draft.yaml` queue, runtime evidence task contract, `self_test_contract`, linked runnable-entry implementation docs, structured development evidence and a completed Development Self-Test Report. The report must include legal `Report Status` and Module Key Test Path so later agents can reuse the debug path from local entry to all self-test scenarios completion; that path is scoped to entries and internal key paths promised by the current task/module, not the whole system. When `graph_required: true` or `module_key_test_graph` exists, validators check that the graph is a single-entry DAG, node and edge refs are valid, every scenario is reachable from the entry and can reach an observable exit, and `evidence_ref` is only a short pointer. `validate-dev` only passes completion-oriented dev evidence when `Report Status: PASS` and every scenario is `PASS`; `BLOCKED`, `IN_PROGRESS` and `STALE` reports may exist as recovery facts but cannot close the current development task. Page tasks need a dev server or page URL plus browser/Playwright/screenshot/equivalent interaction evidence; API/CLI/worker/service/agent/runtime tasks need a startup or invocation command, endpoint/health/status, and observable response/output/side effect. `validate-dev` checks content consistency and completeness between the report and current `self_test_contract`; it does not prove commands really executed in the current run. Agents must execute the current task `required_gates` before filling the report, and writing `PASS` without running those gates is an Agent execution violation. `make validate-current` and `/advance` are phase-exit gates; before moving to REVIEWING, the implementation commit and completion ledger must be done and no open task may remain.
|
|
101
|
+
|
|
102
|
+
Migration cost for the lightweight DAG test path graph is zero to low. Existing projects, tasks and implementation docs that only use `module_key_test_path` remain valid; missing graphs are not retroactively rejected. Managed consumers can run `npx sdlc-harness upgrade`, or `npx sdlc-harness sync` when only managed files need refreshing. New high-risk or multi-scenario tasks will be prompted to generate `graph_required: true` and a graph skeleton. Existing high-risk tasks can be manually improved by splitting their current Module Key Test Path into a DAG. No automatic text-to-graph migration is provided because branches, checkpoints and observable exits require human or Agent judgment, and automatic conversion can invent false structure.
|
|
95
103
|
|
|
96
104
|
`validate-test` keeps its command name as the TESTING phase gate. `.docs/07_test/TEST_STRATEGY.md` describes scope, environment, priority and execution strategy; `.docs/07_test/TEST_CASES.md` describes cases bound to real runnable entry/exit; `.docs/07_test/TEST_REPORT.md` only records executed TESTING evidence, test matrix, regression evidence, runnable entry/exit coverage, coverage gaps and final decision. `validate-test` only accepts `TEST_REPORT.md`; it no longer treats `TEST_PLAN.md` as a report fallback.
|
|
97
105
|
|
|
@@ -144,7 +144,7 @@ Strong success criteria 可以让你 independent loop。Weak criteria,例如
|
|
|
144
144
|
6. 不要在当前 open task 的 `required_gates` 通过前把任务标记为 `done`。
|
|
145
145
|
7. 代码 gate 通过后,更新相关 implementation doc 和 `.docs/INDEX.md`。
|
|
146
146
|
8. `reviewer` 角色只读,不直接修改源码。
|
|
147
|
-
9. 进入 `SPRINTING` 后的需求变更必须进入 RFC 工作流;`ARCHITECTING` 阶段发现 PRD 需要修改时,可以先回到 `REQUIREMENT_GATHERING`。
|
|
147
|
+
9. 进入 `SPRINTING` 后的需求变更必须进入 RFC 工作流;`ARCHITECTING` 阶段发现 PRD 需要修改时,可以先回到 `REQUIREMENT_GATHERING`;`TESTING` 阶段发现 bug 时,先在 `TEST_REPORT.md` 判定 `Bugfix Route`,再轻量回到 `ARCHITECTING` 或 `SPRINTING`。
|
|
148
148
|
10. task/release 历史动作记录使用 git commit、tag 或外部 release 系统,不维护 `<harnessRoot>/archive/` 常规归档。
|
|
149
149
|
11. 在 `SPRINTING` 阶段,task 完成闭环必须先创建 task implementation commit,再提交移除该 task 后的 task completion ledger commit;如果没有 remote/upstream、权限或凭证导致无法 push,不要开始下一个 task,先报告 blocker。
|
|
150
150
|
12. 文档 slice 发生变化后,运行 `make docs-overview` 刷新对应 `overview.md`。
|
|
@@ -168,6 +168,7 @@ Strong success criteria 可以让你 independent loop。Weak criteria,例如
|
|
|
168
168
|
- “开始开发 / 做当前任务 / 做下一个任务” → 等价 `/dev`。
|
|
169
169
|
- “开始循环:写任务,执行任务 / 把开发循环跑完” → 等价 `/devloop`。
|
|
170
170
|
- “跑测试 / 验证一下” → 运行当前 task 或阶段对应 gate。
|
|
171
|
+
- “测试发现 bug / 回去修 / 修测试问题” → 如果当前是 `TESTING`,先读取 `TEST_REPORT.md#Bugfix Route`;`bugfix_replan` 回 `ARCHITECTING` 修改技术方案后再开发,`bugfix_implementation_gap` 回 `SPRINTING` 补实现任务,需求或验收变化走 RFC。
|
|
171
172
|
- 每个阶段任务开始时,默认先做 parallel eligibility check;适合安全拆分时,主 Agent 创建或使用 `parallel_execution.trigger: "workflow_default"` 并调度 Codex native subagents。用户说“并行 / 多 agent / 多 worktree / parallel” → 使用 `trigger: "user_requested"` 强化该意图。
|
|
172
173
|
- “准备 review / 帮我 review” → 进入只读 Review workflow。
|
|
173
174
|
- “刷新文档总览 / 同步 overview” → 等价 `/overview`。
|
|
@@ -200,3 +201,8 @@ python3 tools/transition.py --to <PHASE>
|
|
|
200
201
|
|
|
201
202
|
流转前先运行阶段 gate,通常使用 `make validate-current`,或使用
|
|
202
203
|
`.codex/pjsdlc_managed/policies/phase_contracts.yaml` 中列出的具体 `make validate-*` 目标。
|
|
204
|
+
|
|
205
|
+
`TESTING` 中发现 bug 时不要直接重试或改 runtime。先让测试报告记录 `Bugfix Route`:`bugfix_replan`
|
|
206
|
+
表示回 `ARCHITECTING` 修 tech plan / task breakdown / handoff graph;`bugfix_implementation_gap`
|
|
207
|
+
表示技术方案仍正确、只回 `SPRINTING` 补实现偏差;需求、验收标准或产品边界变化仍走
|
|
208
|
+
`RFC_RECALIBRATION`。
|
package/assets/docs/README.md
CHANGED
|
@@ -102,15 +102,23 @@ Agent 会读取 `<harnessRoot>/state/lifecycle.yaml` 和 `<harnessRoot>/state/pl
|
|
|
102
102
|
|
|
103
103
|
技术方案阶段需要产出 `plan.draft.yaml`,是为了解决跨阶段交接和当前执行队列纯净性的冲突。`ARCHITECTING` 必须在进入开发前证明方案可以拆成具体、可验证的开发单元,包括修改范围、gate、implementation doc 和执行顺序;但这些未来开发 task 如果直接进入 `plan.yaml`,会和当前架构阶段 task 混在一起,让阶段 gate 无法区分“架构任务未完成”和“下一阶段任务已预拆”。因此开发任务先作为 draft 暂存,进入 `SPRINTING` 后再逐个 promote 成正式 `TASK-*`。其它阶段默认根据上一阶段已经稳定的事实源即时创建当前阶段 task,只有当某个阶段也需要提前为后续阶段生成具体执行任务时,才应引入同类 draft queue。
|
|
104
104
|
|
|
105
|
-
|
|
105
|
+
阶段关系由 `<harnessRoot>/pjsdlc_managed/policies/phase_contracts.yaml` 中的轻量显式有向图表达:`phases` 保存稳定阶段 contract,`transitions` 保存合法流转边和少量效果,例如设置或清理 `suspended_phase`。这样做是为了让正常推进、开发前返回、TESTING bugfix return、RFC interrupt/resume 和 BLOCKED resume 都被 transition helper 与 validator 读取,避免规则埋在长文档或工具硬编码里。它不是重型图引擎,不保存历史、不做复杂遍历、不引入 node/edge class 或可视化;目标只是降低遗漏和漂移。
|
|
106
106
|
|
|
107
|
-
|
|
107
|
+
迁移成本较低:对使用 managed assets 的项目,运行 `npx sdlc-harness upgrade` 即可同步新的 `phase_contracts.yaml` 和 `tools/transition.py`;也可以运行 `npx sdlc-harness sync` 只刷新 managed 文件。`lifecycle.yaml` 和 `plan.yaml` 不需要手动迁移,旧的 `allowed_next_phases` 会在下一次 `transition.py` 执行后按图重新生成。只有维护了自定义 phase policy 的项目需要把阶段内的 `next` / `returns` 转成 top-level `transitions`,并按需加入 `TESTING -> ARCHITECTING` / `TESTING -> SPRINTING` bugfix return edges;如果升级前直接运行新版 `validate-harness` 看到缺少 `transitions`,先执行 `upgrade` / `sync`。
|
|
108
108
|
|
|
109
|
-
|
|
109
|
+
在尚未进入开发前,`ARCHITECTING` 可以回到 `REQUIREMENT_GATHERING` 修改 PRD:Manager 使用 `python3 tools/transition.py --to REQUIREMENT_GATHERING` 切回 PM/PRD 工作流,完成 PRD task 和 `validate-pm` 后,再用 `python3 tools/transition.py --to ARCHITECTING` 回到设计阶段。进入 `SPRINTING` 后的需求、验收标准或产品边界变化走 RFC workflow;`SPRINTING`、`REVIEWING`、`TESTING` 和 `RELEASING` 都可以通过 `python3 tools/transition.py --to RFC_RECALIBRATION` 进入受控 RFC 中断,RFC 完成后回到 `SPRINTING` 重新完成开发自测和 handoff。
|
|
110
110
|
|
|
111
|
-
|
|
111
|
+
TESTING 阶段发现 bug 时,先在 `.docs/07_test/TEST_REPORT.md` 记录 `Bugfix Route`,再由 Manager 选择轻量 return:`bugfix_replan` 走 `python3 tools/transition.py --to ARCHITECTING`,用于技术方案、接口契约、任务拆分、Development Self-Test Contract 或 Module Key Test Graph 需要改;`bugfix_implementation_gap` 走 `python3 tools/transition.py --to SPRINTING`,只用于技术方案正确但实现偏离的修复。后者是保留口子,不是预期常态;需求、验收标准或产品边界变化仍走 RFC。
|
|
112
112
|
|
|
113
|
-
`
|
|
113
|
+
`validate-design` 会把架构阶段的语义切片作为硬 gate:`overview.md` 不计入 deliverables,`plan.draft.yaml` 中每个开发 draft task 必须通过 `docs.tech_plan` 指向存在的 tech plan slice;多个开发 draft task 默认需要不同 primary tech plan slice。PRD、tech plan 或 draft task 明确出现 AI provider / copilot、外部系统边界、合规 / 权限 / 审计等横切主题时,也需要对应的专门 architecture slice。可运行边界类 draft task 还必须带 `self_test_contract`,并在 tech plan 中有 `Development Self-Test Contract`;合同必须记录 `module_key_test_path`,说明从本地启动或调用入口开始,到完成全部自测 scenario 的模块关键测试路径,并覆盖本 task / 本模块承诺的所有可运行入口和内部关键路径。复杂或 high-risk 路径可设置 `graph_required: true` 并提供 `module_key_test_graph`,把入口、checkpoint、scenario、出口和 evidence refs 表达成轻量 DAG。
|
|
114
|
+
|
|
115
|
+
SPRINTING 的 Definition of Done 包含模块级可运行交付边界:技术方案或 task 承诺的 API、CLI、server route、service、agent、runtime、adapter、worker、provider、配置契约和 fixture/live 边界必须在开发阶段实现或明确 `BLOCKED`。runtime/app/provider/live 类 task 必须在 `plan.yaml` 声明 `evidence_level.required`、`target_runtime_environment` 和 `self_test_contract`;`self_test_contract.required_gates` 必须同步出现在 task `required_gates`,`self_test_contract.module_key_test_path` 必须描述从本地启动或调用入口开始,到完成全部自测 scenario 的模块关键测试路径,并覆盖本 task / 本模块承诺的所有可运行入口和内部关键路径。复杂 task 的 `module_key_test_graph` 是 handoff path 的 canonical detail:它是 DAG 而不是树,因为多个 scenario 可能共享 setup、分支后汇合到同一 observable exit;它不是重型测试执行图,不保存 trace、debug log、operator log、runbook 正文或证据正文。`deployed_runtime` 不能用 `unit`、`local_runtime`、`external_provider_live`、provider smoke、fake adapter 或 localhost smoke 单独关闭,`business_handoff_ready` 还必须有 Testing Handoff Contract。当前 task 的 implementation doc 还必须写入 `Development Evidence` 和 `Development Self-Test Report`,其中自测报告记录 `Report Status: PASS | BLOCKED | IN_PROGRESS | STALE`、contract source、Module Application Entry、scenario results、executed gates、Module Key Test Path、必要时的 Module Key Test Graph、Observable Exit、Current Blocker、Testing Handoff Readiness 和 Evidence Index Refs;只有 `Report Status: PASS` 且所有 scenario 为 `PASS` 才能关闭 development task。`Development Self-Test Report` 只证明模块入口、核心路径、出口和最小证据指针,不承担 debug log、operator log、runbook、evidence dump 或探索流水职责;fallback / diagnostic 最多一句总结,详细内容进入 `.docs/09_runbooks/**` evidence index / appendix 或 git history;主报告不得使用 `Actual Evidence` 正文字段,普通报告目标不超过 80 行,high-risk 报告目标不超过 120 行。`Module Key Test Path` 必须记录实际入口、内部关键路径、关键边界、观察点和可观测完成证据。provider smoke、fixture smoke、fake adapter 或 one-shot smoke 只能证明局部链路,不能单独证明 application readiness。REVIEWING 会把缺少入口/出口、初始化、配置契约、目标运行环境、证据等级或开发自测证据作为阻断项;TESTING 只调用 Review 已确认 `PASS` 的既有入口做输入输出验证,复杂路径按 Module Key Test Graph 消费,不能新增 product runtime、bootstrap、provider adapter、deploy 或 package runtime script。
|
|
116
|
+
|
|
117
|
+
复杂 runtime/live/remote-operator 任务采用 resume-first 分层:当当前 SPRINTING task 要求 `external_provider_live`、`deployed_runtime`、`business_handoff_ready`,或目标环境是 `cloud_vm`、`managed_service`、`browser`、`worker` 时,`plan.yaml` 顶层必须维护 `resume_capsule`,只保留当前状态、canonical path、下一步、blocker、last passed gate、do-not-retry 和 recovery refs;凡会改变下一步动作的判断,必须 promoted 到 `resume_capsule.do_not_retry`、runbook 顶部 `Hard Constraints` 或短 `Current Operator Path`,不能只埋在 evidence、notes、appendix 或长 implementation doc 中。validator 会扫描 `working_notes`、implementation doc 和 runbook 中的 session / QR / canonical path / do-not-retry 类关键判断,未 promoted 时 fail。open task 的 `working_notes` 只保留恢复短备注,目标 5-8 条且 validator 上限 8 条。长期实现事实写 implementation doc;操作路径、凭证引用、远端入口写 `.docs/09_runbooks/**` runbook;implementation doc 只放短的 `Current Operator Path`,记录 canonical operator path、runbook link、credential reference name、command/UI channel、hard constraints 和 do-not-retry summary;证据正文只进入 evidence index 或外部证据系统,不得转移成 implementation doc 主线的 `Evidence Dump`、`Operator Log`、`Failed Attempts` 或 `Screenshot Index` 等章节;失败探索隔离到 exploration appendix。高风险 task 的 `Development Self-Test Report` 还必须有 `Gate Breakdown`,把 local gate、cloud/service gate、executor/operator readiness 和 live smoke / handoff 分开记录,不能只用一个 `validate-dev PASS` 覆盖全部进度。
|
|
118
|
+
|
|
119
|
+
`make validate-dev` / `npx sdlc-harness validate-dev` 是 SPRINTING 开发中 gate:当前 `current_task_id` 指向的 open task 可以继续留在 `plan.yaml`,validator 会检查它是否是合法 `phase: "SPRINTING"` task、是否具备 `docs`、`allowed_paths`、`required_gates`、`acceptance_criteria`、`implementation_doc`,并校验 dirty files、`plan.draft.yaml`、runtime evidence task contract、`self_test_contract`、implementation doc、结构化 `Development Evidence` 和 `Development Self-Test Report`。自测报告必须记录合法 `Report Status` 和 `Module Key Test Path`,便于后续 Agent 复用从本地入口到全部自测用例完成的 debug 路径;该路径只要求覆盖本 task / 本模块承诺范围内的可运行入口和内部关键路径,不要求覆盖全系统所有模块。若 `graph_required: true` 或存在 `module_key_test_graph`,validator 会校验它是单入口 DAG、节点和边引用有效、每个 scenario 可从 entry 到达并能走到 observable exit,且 `evidence_ref` 只是短指针。`validate-dev` 只接受 `Report Status: PASS` 且所有 scenario 为 `PASS` 的完成态;`BLOCKED`、`IN_PROGRESS`、`STALE` 可以记录恢复事实,但不能关闭当前 development task。页面类证据需要 dev server/page URL 与 browser check;API/CLI/worker/service/agent/runtime 类证据需要 startup/invocation command、endpoint/health/status 与 response/output/side effect。`validate-dev` 只校验自测报告内容与当前 `self_test_contract` 的一致性和完整性,不证明命令在本轮真实执行;Agent 必须先实际运行 current task `required_gates` 后再填写 `Development Self-Test Report`,未执行 required gates 却写 `PASS` 属于 Agent execution violation。`make validate-current` / `/advance` 是阶段出口 gate;进入 REVIEWING 前仍必须先完成 implementation commit 和 completion ledger,把 open task 从 `plan.yaml` 移除。
|
|
120
|
+
|
|
121
|
+
轻量 DAG 测试路径图的迁移成本为零到低:旧项目、旧 task 和旧 implementation doc 只写 `module_key_test_path` 仍然有效;缺少 graph 不会被 retroactive fail。升级 managed consumers 时运行 `npx sdlc-harness upgrade`,只刷新 managed files 时运行 `npx sdlc-harness sync`。新 high-risk / multi-scenario task 会由更新后的 prompts 倾向生成 `graph_required: true` 和 `module_key_test_graph` skeleton。旧 high-risk task 如需提升交接质量,可手动把现有 `Module Key Test Path` 拆成 DAG;不提供自动 text-to-graph migration,因为分支、checkpoint 和 observable exit 需要人工或 Agent 判断,自动转换容易制造虚假结构。
|
|
114
122
|
|
|
115
123
|
`validate-test` 仍然是 TESTING 阶段 gate 名称。`.docs/07_test/TEST_STRATEGY.md` 描述测试范围、环境、优先级和执行策略;`.docs/07_test/TEST_CASES.md` 描述绑定真实 runnable entry/exit 的测试用例;`.docs/07_test/TEST_REPORT.md` 只记录 TESTING 阶段实际执行后的 test matrix、regression evidence、runnable entry/exit coverage、coverage gaps 和 final decision。`validate-test` 只接受 `TEST_REPORT.md`,不会把 `TEST_PLAN.md` 当作 report fallback。
|
|
116
124
|
|
|
@@ -128,7 +136,7 @@ SPRINTING 的 Definition of Done 包含模块级可运行交付边界:技术
|
|
|
128
136
|
|
|
129
137
|
`<harnessRoot>/skills/<name>/SKILL.md` 是 Harness 的 workflow skill 事实源,也是稳定的 hard file index。它有两种使用方式:
|
|
130
138
|
|
|
131
|
-
- Harness soft index:`AGENTS.md` 要求 Agent 先读 lifecycle/plan,再按 `active_skill` 和 `phase_contracts.yaml` 读取对应 skill
|
|
139
|
+
- Harness soft index:`AGENTS.md` 要求 Agent 先读 lifecycle/plan,再按 `active_skill` 和 `phase_contracts.yaml` 的 phase graph 读取对应 skill 与合法下一步。
|
|
132
140
|
- Native skill adapter:如果某个 Agent 支持 native skill registry,可以把这些 workflow skills 同步或安装到该 Agent 的原生 skill root,让“产品方案”“技术方案”“开发循环”等自然语言在首轮就有机会命中。
|
|
133
141
|
|
|
134
142
|
只在 `AGENTS.md` 里声明 `<harnessRoot>/skills` 不等于 native skill 注册;它保证的是 Harness soft index。Native skill 是否首轮水合,取决于具体 Agent 客户端是否扫描这个目录,或是否使用了额外 adapter。
|
|
@@ -8,7 +8,6 @@ phases:
|
|
|
8
8
|
outputs:
|
|
9
9
|
- "<harnessRoot>/state/lifecycle.yaml"
|
|
10
10
|
gates: []
|
|
11
|
-
next: "REQUIREMENT_GATHERING"
|
|
12
11
|
|
|
13
12
|
REQUIREMENT_GATHERING:
|
|
14
13
|
goal: "收集需求并形成产品方案"
|
|
@@ -23,7 +22,6 @@ phases:
|
|
|
23
22
|
- ".docs/INDEX.md"
|
|
24
23
|
gates:
|
|
25
24
|
- "make validate-pm"
|
|
26
|
-
next: "ARCHITECTING"
|
|
27
25
|
|
|
28
26
|
ARCHITECTING:
|
|
29
27
|
goal: "根据产品方案生成架构设计、技术方案和任务草案"
|
|
@@ -40,9 +38,6 @@ phases:
|
|
|
40
38
|
- "<harnessRoot>/state/plan.draft.yaml"
|
|
41
39
|
gates:
|
|
42
40
|
- "make validate-design"
|
|
43
|
-
next: "SPRINTING"
|
|
44
|
-
returns:
|
|
45
|
-
- "REQUIREMENT_GATHERING"
|
|
46
41
|
|
|
47
42
|
SPRINTING:
|
|
48
43
|
goal: "按任务状态执行开发、消费已采用草案、开发验证、Development Evidence 和实现文档沉淀"
|
|
@@ -62,7 +57,6 @@ phases:
|
|
|
62
57
|
- "<harnessRoot>/state/plan.draft.yaml"
|
|
63
58
|
gates:
|
|
64
59
|
- "make validate-dev"
|
|
65
|
-
next: "REVIEWING"
|
|
66
60
|
|
|
67
61
|
REVIEWING:
|
|
68
62
|
goal: "只读审查实现质量、需求一致性和架构风险"
|
|
@@ -79,7 +73,6 @@ phases:
|
|
|
79
73
|
- ".docs/06_review/REVIEW_REPORT.md"
|
|
80
74
|
gates:
|
|
81
75
|
- "make validate-review"
|
|
82
|
-
next: "TESTING"
|
|
83
76
|
|
|
84
77
|
TESTING:
|
|
85
78
|
goal: "基于已交付 entry/exit 形成测试策略、测试用例、执行报告、回归证据和覆盖缺口结论"
|
|
@@ -100,7 +93,6 @@ phases:
|
|
|
100
93
|
- "tests/"
|
|
101
94
|
gates:
|
|
102
95
|
- "make validate-test"
|
|
103
|
-
next: "RELEASING"
|
|
104
96
|
|
|
105
97
|
RELEASING:
|
|
106
98
|
goal: "当前发布状态、发布检查和回滚方案"
|
|
@@ -115,7 +107,6 @@ phases:
|
|
|
115
107
|
- ".docs/08_release/CURRENT_RELEASE.md"
|
|
116
108
|
gates:
|
|
117
109
|
- "make validate-release"
|
|
118
|
-
next: "COMPLETED"
|
|
119
110
|
|
|
120
111
|
COMPLETED:
|
|
121
112
|
goal: "当前里程碑已完成"
|
|
@@ -126,7 +117,6 @@ phases:
|
|
|
126
117
|
outputs:
|
|
127
118
|
- "<harnessRoot>/state/lifecycle.yaml"
|
|
128
119
|
gates: []
|
|
129
|
-
next: "IDLE"
|
|
130
120
|
|
|
131
121
|
RFC_RECALIBRATION:
|
|
132
122
|
goal: "处理需求变更、影响分析、测试事实源清理、局部补丁和任务回退"
|
|
@@ -145,7 +135,6 @@ phases:
|
|
|
145
135
|
- ".docs/INDEX.md"
|
|
146
136
|
gates:
|
|
147
137
|
- "make validate-rfc"
|
|
148
|
-
next: "SPRINTING"
|
|
149
138
|
|
|
150
139
|
BLOCKED:
|
|
151
140
|
goal: "等待人工补充信息、授权或基础设施处理"
|
|
@@ -156,4 +145,139 @@ phases:
|
|
|
156
145
|
outputs:
|
|
157
146
|
- "<harnessRoot>/state/lifecycle.yaml"
|
|
158
147
|
gates: []
|
|
159
|
-
|
|
148
|
+
|
|
149
|
+
transitions:
|
|
150
|
+
- from: "IDLE"
|
|
151
|
+
to: "REQUIREMENT_GATHERING"
|
|
152
|
+
trigger: "advance"
|
|
153
|
+
kind: "normal"
|
|
154
|
+
- from: "REQUIREMENT_GATHERING"
|
|
155
|
+
to: "ARCHITECTING"
|
|
156
|
+
trigger: "advance"
|
|
157
|
+
kind: "normal"
|
|
158
|
+
- from: "ARCHITECTING"
|
|
159
|
+
to: "SPRINTING"
|
|
160
|
+
trigger: "advance"
|
|
161
|
+
kind: "normal"
|
|
162
|
+
- from: "SPRINTING"
|
|
163
|
+
to: "REVIEWING"
|
|
164
|
+
trigger: "advance"
|
|
165
|
+
kind: "normal"
|
|
166
|
+
- from: "REVIEWING"
|
|
167
|
+
to: "TESTING"
|
|
168
|
+
trigger: "advance"
|
|
169
|
+
kind: "normal"
|
|
170
|
+
- from: "TESTING"
|
|
171
|
+
to: "RELEASING"
|
|
172
|
+
trigger: "advance"
|
|
173
|
+
kind: "normal"
|
|
174
|
+
- from: "TESTING"
|
|
175
|
+
to: "ARCHITECTING"
|
|
176
|
+
trigger: "bugfix_replan"
|
|
177
|
+
kind: "return"
|
|
178
|
+
- from: "TESTING"
|
|
179
|
+
to: "SPRINTING"
|
|
180
|
+
trigger: "bugfix_implementation_gap"
|
|
181
|
+
kind: "return"
|
|
182
|
+
- from: "RELEASING"
|
|
183
|
+
to: "COMPLETED"
|
|
184
|
+
trigger: "advance"
|
|
185
|
+
kind: "normal"
|
|
186
|
+
- from: "COMPLETED"
|
|
187
|
+
to: "IDLE"
|
|
188
|
+
trigger: "advance"
|
|
189
|
+
kind: "normal"
|
|
190
|
+
- from: "ARCHITECTING"
|
|
191
|
+
to: "REQUIREMENT_GATHERING"
|
|
192
|
+
trigger: "return_to_prd"
|
|
193
|
+
kind: "return"
|
|
194
|
+
- from: "SPRINTING"
|
|
195
|
+
to: "RFC_RECALIBRATION"
|
|
196
|
+
trigger: "requirement_change"
|
|
197
|
+
kind: "interrupt"
|
|
198
|
+
effects:
|
|
199
|
+
set_suspended_phase: true
|
|
200
|
+
- from: "REVIEWING"
|
|
201
|
+
to: "RFC_RECALIBRATION"
|
|
202
|
+
trigger: "requirement_change"
|
|
203
|
+
kind: "interrupt"
|
|
204
|
+
effects:
|
|
205
|
+
set_suspended_phase: true
|
|
206
|
+
- from: "TESTING"
|
|
207
|
+
to: "RFC_RECALIBRATION"
|
|
208
|
+
trigger: "requirement_change"
|
|
209
|
+
kind: "interrupt"
|
|
210
|
+
effects:
|
|
211
|
+
set_suspended_phase: true
|
|
212
|
+
- from: "RELEASING"
|
|
213
|
+
to: "RFC_RECALIBRATION"
|
|
214
|
+
trigger: "requirement_change"
|
|
215
|
+
kind: "interrupt"
|
|
216
|
+
effects:
|
|
217
|
+
set_suspended_phase: true
|
|
218
|
+
- from: "RFC_RECALIBRATION"
|
|
219
|
+
to: "SPRINTING"
|
|
220
|
+
trigger: "rfc_complete"
|
|
221
|
+
kind: "resume"
|
|
222
|
+
effects:
|
|
223
|
+
clear_suspended_phase: true
|
|
224
|
+
- from: "IDLE"
|
|
225
|
+
to: "BLOCKED"
|
|
226
|
+
trigger: "blocked"
|
|
227
|
+
kind: "interrupt"
|
|
228
|
+
effects:
|
|
229
|
+
set_suspended_phase: true
|
|
230
|
+
- from: "REQUIREMENT_GATHERING"
|
|
231
|
+
to: "BLOCKED"
|
|
232
|
+
trigger: "blocked"
|
|
233
|
+
kind: "interrupt"
|
|
234
|
+
effects:
|
|
235
|
+
set_suspended_phase: true
|
|
236
|
+
- from: "ARCHITECTING"
|
|
237
|
+
to: "BLOCKED"
|
|
238
|
+
trigger: "blocked"
|
|
239
|
+
kind: "interrupt"
|
|
240
|
+
effects:
|
|
241
|
+
set_suspended_phase: true
|
|
242
|
+
- from: "SPRINTING"
|
|
243
|
+
to: "BLOCKED"
|
|
244
|
+
trigger: "blocked"
|
|
245
|
+
kind: "interrupt"
|
|
246
|
+
effects:
|
|
247
|
+
set_suspended_phase: true
|
|
248
|
+
- from: "REVIEWING"
|
|
249
|
+
to: "BLOCKED"
|
|
250
|
+
trigger: "blocked"
|
|
251
|
+
kind: "interrupt"
|
|
252
|
+
effects:
|
|
253
|
+
set_suspended_phase: true
|
|
254
|
+
- from: "TESTING"
|
|
255
|
+
to: "BLOCKED"
|
|
256
|
+
trigger: "blocked"
|
|
257
|
+
kind: "interrupt"
|
|
258
|
+
effects:
|
|
259
|
+
set_suspended_phase: true
|
|
260
|
+
- from: "RELEASING"
|
|
261
|
+
to: "BLOCKED"
|
|
262
|
+
trigger: "blocked"
|
|
263
|
+
kind: "interrupt"
|
|
264
|
+
effects:
|
|
265
|
+
set_suspended_phase: true
|
|
266
|
+
- from: "COMPLETED"
|
|
267
|
+
to: "BLOCKED"
|
|
268
|
+
trigger: "blocked"
|
|
269
|
+
kind: "interrupt"
|
|
270
|
+
effects:
|
|
271
|
+
set_suspended_phase: true
|
|
272
|
+
- from: "RFC_RECALIBRATION"
|
|
273
|
+
to: "BLOCKED"
|
|
274
|
+
trigger: "blocked"
|
|
275
|
+
kind: "interrupt"
|
|
276
|
+
effects:
|
|
277
|
+
set_suspended_phase: true
|
|
278
|
+
- from: "BLOCKED"
|
|
279
|
+
to: "<suspended_phase>"
|
|
280
|
+
trigger: "resume"
|
|
281
|
+
kind: "resume"
|
|
282
|
+
effects:
|
|
283
|
+
clear_suspended_phase: true
|
|
@@ -23,6 +23,8 @@ ADR 用来解决“后来的人只看到结果,看不到当年取舍”的问
|
|
|
23
23
|
|
|
24
24
|
如果在 `ARCHITECTING` 中发现 PRD 缺失、验收标准不清或产品边界需要调整,且项目尚未进入 `SPRINTING`,不要用架构文档替代产品事实。先收尾或移除当前 open design task,再请 Manager 使用 `python3 tools/transition.py --to REQUIREMENT_GATHERING` 回到 PM/PRD 工作流修改 `.docs/01_product/**`。进入 `SPRINTING` 后的需求变化走 RFC workflow。
|
|
25
25
|
|
|
26
|
+
如果是从 `TESTING` 通过 `bugfix_replan` 回到 `ARCHITECTING`,默认只修正测试报告证明有问题的 tech plan、interface contract、task breakdown、Development Self-Test Contract 或 Module Key Test Graph,并引用 `.docs/07_test/TEST_REPORT.md` 中的失败 scenario。不要把这条路径扩成全量重设计;如果 bugfix 需要修改 PRD、acceptance criteria 或产品边界,转入 `RFC_RECALIBRATION`。
|
|
27
|
+
|
|
26
28
|
架构阶段默认先评估是否适合并行调研或方案拆解。适合时,主 Agent 使用 `parallel_execution.trigger: "workflow_default"` 和 `runtime.provider: "codex_native_subagents"` 调度 worker 分别做架构草稿、接口分析、风险清单或方案对比;用户明确要求并行时使用 `trigger: "user_requested"`。worker 不直接写最终 architecture、tech plan、ADR 或 `plan.draft.yaml`,最终事实源和任务草案由主 Agent 合成;不适合拆分时保持串行并记录原因。
|
|
27
29
|
|
|
28
30
|
## 输入
|
|
@@ -57,7 +59,8 @@ ADR 用来解决“后来的人只看到结果,看不到当年取舍”的问
|
|
|
57
59
|
- 如果实现计划改变了已有模块边界,应更新相关 architecture slice,而不是只在 task 描述里补一句。
|
|
58
60
|
- 只要技术方案或 draft task 出现 service、agent、runtime、worker、frontend app、provider/live integration 或外部可运行边界,task breakdown 必须包含最后一公里 runtime 初始化和 testing handoff 交付:目标运行环境、启动/部署或预览方式、health/readiness、smoke 输入输出、日志/错误证据、测试可调用入口和出口。
|
|
59
61
|
- 这类开发 draft task 必须写入 `evidence_level.required`、`target_runtime_environment` 和 `self_test_contract`。`evidence_level.required` 只能使用 `unit`、`local_runtime`、`external_provider_live`、`deployed_runtime`、`business_handoff_ready`;`target_runtime_environment.kind` 只能使用 `local`、`ci`、`staging`、`cloud_vm`、`managed_service`、`browser`、`worker`、`not_applicable`。`self_test_contract` 的 `source` 必须引用当前 tech plan slice,`required_gates` 必须同步到 task `required_gates`,`scenarios[]` 至少覆盖一个可运行入口和可观测出口,`module_key_test_path` 必须描述从本地启动或调用入口开始,到完成所有自测 scenario 的模块关键测试路径,并覆盖本 task / 本模块承诺的所有可运行入口和内部关键路径。
|
|
60
|
-
-
|
|
62
|
+
- 复杂或高风险自测路径要同时生成轻量 DAG skeleton:当 scenario >= 3、多分支、多入口、runtime/live/provider/browser/worker,或 Review/Testing 需要明确消费 checkpoint / exit / evidence refs 时,在 `self_test_contract` 设置 `graph_required: true` 并填写 `module_key_test_graph`。图只保存 handoff path 的 `entry`、`checkpoint`、`branch`、`scenario`、`observable_exit` 节点和边,以及短 `evidence_ref` 指针;不要把命令输出、截图过程、operator log、debug log、runbook 正文、失败探索或历史流水塞进图。普通单入口 / 少量 scenario task 保留短 `module_key_test_path` 即可。
|
|
63
|
+
- 如果 draft task 属于 high-risk runtime/live/remote-operator 工作(`external_provider_live`、`deployed_runtime`、`business_handoff_ready`,或目标环境为 `cloud_vm`、`managed_service`、`browser`、`worker`),还必须预留恢复分层:`docs.runbook` 指向 `.docs/09_runbooks/**` 下的 runbook / evidence index / exploration appendix,`allowed_paths` 覆盖这些文件,acceptance criteria 要求 promote 后维护 `plan.yaml#resume_capsule`,并把会改变下一步动作的判断 promoted 到 `resume_capsule.do_not_retry` 或 runbook 顶部 `Hard Constraints`。runbook 写 canonical operator path 和 hard constraints,evidence index 只写证据指针,exploration appendix 隔离失败尝试;不要把这些内容塞进 implementation doc 主线。
|
|
61
64
|
- 如果用户明确要求把既有完整技术方案文件切成多个 `.docs/03_tech_plan/` slices,先确认 replacement slices 覆盖原文件中仍有效的接口契约、数据模型、模块方案、任务组和 gate;切片完成并更新 `plan.draft.yaml` 引用、`.docs/INDEX.md`、刷新 `overview.md` 后,删除被替代的完整 tech plan file,避免同一事实由完整文件和 slices 双重保留。
|
|
62
65
|
- 每次新增、拆分、合并或废弃 slice 后,都要更新 `.docs/INDEX.md`。
|
|
63
66
|
|
|
@@ -83,6 +86,7 @@ ADR 用来解决“后来的人只看到结果,看不到当年取舍”的问
|
|
|
83
86
|
5. 风险或不清晰的问题按 `<harnessRoot>/pjsdlc_managed/policies/risk_matrix.yaml` 标记。
|
|
84
87
|
6. 任务边界应足够小,能在一次设计执行内闭环;`result_docs` 应指向将被更新或新增的 architecture、tech plan、ADR 或 `plan.draft.yaml` 文件。
|
|
85
88
|
7. `make validate-design` 是阶段出口 gate;如果还有 open `TASK-*` design task,不要请求进入 `SPRINTING`。
|
|
89
|
+
8. 从 TESTING bugfix 回流的设计任务必须引用 `TEST_REPORT.md` 的 `Bugfix Route: bugfix_replan` 和失败 scenario,只补受影响的 tech plan / draft task,不修改产品事实。
|
|
86
90
|
|
|
87
91
|
## 完成检查
|
|
88
92
|
|
|
@@ -94,6 +98,8 @@ ADR 用来解决“后来的人只看到结果,看不到当年取舍”的问
|
|
|
94
98
|
- [ ] `plan.draft.yaml` 中每个开发 draft task 已通过 `docs.tech_plan` 绑定到对应 tech plan slice。
|
|
95
99
|
- [ ] 如果用户要求把完整技术方案切成 tech plan slices,已删除被替代的完整 tech plan file,并同步 `plan.draft.yaml` 引用。
|
|
96
100
|
- [ ] task draft 字段完整且范围清晰;runtime/app/provider/live 类 task 已声明 `evidence_level`、`target_runtime_environment` 和 `self_test_contract`。
|
|
101
|
+
- [ ] 复杂或 high-risk 自测路径已判断是否需要 `graph_required: true`;需要时已在 tech plan 和 draft task 中生成 `module_key_test_graph` skeleton。
|
|
102
|
+
- [ ] 如果来自 TESTING bugfix 回流,已只修正 `bugfix_replan` 指向的技术方案或任务边界,并保留 `TEST_REPORT.md` 失败 scenario 引用。
|
|
97
103
|
- [ ] `.docs/INDEX.md` 已链接新增产物。
|
|
98
104
|
- [ ] 已运行 `make docs-overview` 刷新 `.docs/<stage>/overview.md`。
|
|
99
105
|
- [ ] `make validate-design` 准备通过。
|
|
@@ -17,16 +17,18 @@ description: Use during SPRINTING to execute one task from plan.yaml, respecting
|
|
|
17
17
|
|
|
18
18
|
开发阶段的 Definition of Done 包含可运行的系统入口/出口。凡技术方案或 task 承诺 API、CLI、server route、service、agent、runtime、adapter、worker、provider、外部发送/写入执行器、配置契约或 live/fixture 双模式边界,当前实现必须提供对应入口、调用方式、初始化方式、输出/副作用边界和验证方式;如果真实入口/出口尚不可运行,不能把 task 当作完成,也不能把缺口留给 TESTING 补 runtime。runtime/app/provider/live 类 task 必须在 `plan.yaml` 声明 `evidence_level.required`、`target_runtime_environment` 和 `self_test_contract`,并按合同交付:`deployed_runtime` 不能用 `unit`、`local_runtime`、`external_provider_live`、provider smoke、fake adapter 或 localhost smoke 单独关闭;`business_handoff_ready` 必须提供 Testing Handoff Contract。Implementation doc 必须写明 `Runnable Entry/Exit`,并在 `Development Evidence` 中记录 `Evidence Level`、`Target Runtime Environment`、`Runnable Entry`、`Observable Exit`、`Client / Server Initialization`、`Config Contract`、`Testing Handoff Readiness`、`Known Missing Runtime Boundaries` 和 `Basic Self-test Evidence`;其中 `Basic Self-test Evidence` 应指向已执行的 `Development Self-Test Report`。确实不适用时也要显式写 `Not applicable` 和具体原因。provider smoke、fixture smoke、fake adapter 或 one-shot smoke 只能证明局部链路,不能单独证明 `Application readiness`。此时应保留或创建 `BLOCKED`/后续 dev task,或通过 RFC/ARCHITECTING 处理边界变更。
|
|
19
19
|
|
|
20
|
-
`self_test_contract` 是开发阶段自测合同,由 ARCHITECTING 或 RFC_RECALIBRATION 先定义,SPRINTING 负责执行并在 implementation doc 填写 `Development Self-Test Report`。开发者不得在开发结束后用现有实现反推自测合同;如果合同缺失、入口不匹配、required gates 未同步或场景无法执行,要先回到 ARCHITECTING/RFC 或把 task 保持为 `BLOCKED`。自测报告不是 TESTING 阶段产物,也不是 debug log、operator log、runbook 或历史流水;它只证明当前模块级可运行交付边界已经能被 Review/Testing 消费。报告必须写 `Report Status: PASS | BLOCKED | IN_PROGRESS | STALE`,只有 `PASS` 且所有 scenario 都是 `PASS` 才能关闭当前 development task;`BLOCKED`、`IN_PROGRESS`、`STALE` 可以作为恢复事实存在,但不能作为交接通过。报告还必须记录 `Module Key Test Path`:从本地启动或调用入口开始,执行并完成 `self_test_contract` 中全部自测用例的模块关键测试路径。该路径应覆盖本 task / 本模块承诺的所有可运行入口,以及自测用例实际经过的内部关键路径、关键边界、观察点和可观测完成证据,供后续 Agent 复用和 debug
|
|
20
|
+
`self_test_contract` 是开发阶段自测合同,由 ARCHITECTING 或 RFC_RECALIBRATION 先定义,SPRINTING 负责执行并在 implementation doc 填写 `Development Self-Test Report`。开发者不得在开发结束后用现有实现反推自测合同;如果合同缺失、入口不匹配、required gates 未同步或场景无法执行,要先回到 ARCHITECTING/RFC 或把 task 保持为 `BLOCKED`。自测报告不是 TESTING 阶段产物,也不是 debug log、operator log、runbook 或历史流水;它只证明当前模块级可运行交付边界已经能被 Review/Testing 消费。报告必须写 `Report Status: PASS | BLOCKED | IN_PROGRESS | STALE`,只有 `PASS` 且所有 scenario 都是 `PASS` 才能关闭当前 development task;`BLOCKED`、`IN_PROGRESS`、`STALE` 可以作为恢复事实存在,但不能作为交接通过。报告还必须记录 `Module Key Test Path`:从本地启动或调用入口开始,执行并完成 `self_test_contract` 中全部自测用例的模块关键测试路径。该路径应覆盖本 task / 本模块承诺的所有可运行入口,以及自测用例实际经过的内部关键路径、关键边界、观察点和可观测完成证据,供后续 Agent 复用和 debug。如果合同包含 `graph_required: true` 或 `module_key_test_graph`,开发者还必须沿该 DAG 执行并在报告中写入实际 `Module Key Test Graph`:节点只记录 entry、checkpoint、branch、scenario、observable_exit 和 evidence pointer,边只记录路径流向;不要把图扩成 runtime 搭建、执行 trace、debug log 或证据正文。
|
|
21
21
|
|
|
22
|
-
开发阶段交付包含两类产物:实现产物(代码、配置、脚本、测试等)和开发自测产物。`Development Self-Test Report` 是开发阶段产物,不是计划、模板或历史记录。若当前 task 或关联技术方案声明 `self_test_contract.status: "required"`,必须先逐条执行 `self_test_contract.scenarios[]` 和 `self_test_contract.required_gates`,再填写或更新 `Development Self-Test Report`。没有本轮执行过的 runnable entry、内部关键路径、observable exit / artifact / screenshot / response / log 等证据时,不得写 `PASS`,不得完成 task
|
|
22
|
+
开发阶段交付包含两类产物:实现产物(代码、配置、脚本、测试等)和开发自测产物。`Development Self-Test Report` 是开发阶段产物,不是计划、模板或历史记录。若当前 task 或关联技术方案声明 `self_test_contract.status: "required"`,必须先逐条执行 `self_test_contract.scenarios[]` 和 `self_test_contract.required_gates`,再填写或更新 `Development Self-Test Report`。没有本轮执行过的 runnable entry、内部关键路径、observable exit / artifact / screenshot / response / log 等证据时,不得写 `PASS`,不得完成 task。自测报告只保留交接卡字段:`Report Status`、`Contract Source`、`Module Application Entry`、`Module Key Test Path`、`Scenario Results`、`Executed Gates`、`Observable Exit`、`Current Blocker`、`Testing Handoff Readiness` 和 `Evidence Index Refs`;证据正文、长命令输出、截图过程和 UI 操作细节进入 evidence index、外部 artifact 或 `.docs/09_runbooks/**` exploration appendix。主报告目标几十行,fallback / diagnostic 最多一句总结,不写 `Actual Evidence` 正文字段。
|
|
23
23
|
|
|
24
|
-
高风险 runtime/live/remote-operator task 必须维护恢复优先级。若 `evidence_level.required` 是 `external_provider_live`、`deployed_runtime`、`business_handoff_ready`,或 `target_runtime_environment.kind` 是 `cloud_vm`、`managed_service`、`browser`、`worker`,`plan.yaml` 顶层必须有 `resume_capsule`,并在路径选择结论变化时立即更新:`state`、`canonical_path`、`next_step`、`blocker`、`last_passed_gate`、`do_not_retry` 和 `recovery_refs
|
|
24
|
+
高风险 runtime/live/remote-operator task 必须维护恢复优先级。若 `evidence_level.required` 是 `external_provider_live`、`deployed_runtime`、`business_handoff_ready`,或 `target_runtime_environment.kind` 是 `cloud_vm`、`managed_service`、`browser`、`worker`,`plan.yaml` 顶层必须有 `resume_capsule`,并在路径选择结论变化时立即更新:`state`、`canonical_path`、`next_step`、`blocker`、`last_passed_gate`、`do_not_retry` 和 `recovery_refs`。凡会改变下一步动作的判断,必须 promoted 到 `resume_capsule.do_not_retry`、runbook 顶部 `Hard Constraints` 或 implementation doc 的短 `Current Operator Path`,不能只埋在 evidence、notes、exploration appendix 或长 implementation doc 中。例如 PC 微信已确认登录后再次出现 QR 时,先判定 `rule_assumption_gap` vs `operator_induced_logout_or_session_reset`,不得直接进入重新扫码流程。validator 会扫描 `working_notes`、implementation doc 和 runbook 中的 session / QR / canonical path / do-not-retry 类关键判断;只在 notes/evidence 中出现而未 promoted 会 fail。`working_notes` 只保留短恢复备注,目标 5-8 条且不得超过 8 条;canonical operator path 写入 `.docs/09_runbooks/**` runbook,并在 implementation doc 写一个短的 `Current Operator Path` 链接 runbook、credential reference name、command/UI channel、hard constraints 和 do-not-retry summary。证据正文只在 evidence index 或外部系统,失败探索写入 exploration appendix。不要把 A/B/C 路径探索流水混进 implementation doc 主线或 scenario evidence。
|
|
25
25
|
|
|
26
26
|
页面类任务在开发阶段必须启动 dev server 或等价预览入口,并用浏览器、Playwright、截图或等价方式验证页面可加载、主入口可访问、核心按钮/表单/跳转可用、没有明显报错或空白页。API/CLI/worker/RPA/service/agent/runtime 类任务必须记录实际启动或调用命令、endpoint、worker command、dry-run/live preflight、health/status 或 server action,以及可观察的 response、队列 item、审计日志、文件产物、发送结果、错误码或 PASS/BLOCKED 结果。
|
|
27
27
|
|
|
28
28
|
`/dev` 和 `/devloop` 是开发阶段的两个入口。`/dev` 创建或选择下一个最小 `TASK-*` development task,设置 `phase: "SPRINTING"`,并只完成一个 task 闭环后停止。通用规则是从任何 draft queue promote 正式 `TASK-*` 时都必须同次消费源 draft;当前开发阶段的内置 draft queue 是 `plan.draft.yaml.tasks[]`,因此如果这个 task 来自 `plan.draft.yaml.tasks[]`,promote 时必须同次删除源 draft,避免已采用草案继续显示为 `pending`。`/devloop` 连续运行 `/dev`,直到 `plan.yaml.tasks[]` 和 `plan.draft.yaml.tasks[]` 都没有明确可创建/执行的任务,或遇到需求、架构、allowed_paths、gate、commit/push blocker。
|
|
29
29
|
|
|
30
|
+
如果是从 `TESTING` 通过 `bugfix_implementation_gap` 直接回到 `SPRINTING`,先创建或选择一个最小 bugfix `TASK-*`,引用 `.docs/07_test/TEST_REPORT.md` 的 failing scenario、既有 tech plan slice 和相关 implementation doc。该路径只用于“技术方案正确但实现偏离”的修复;如果测试证明技术方案、接口契约、任务拆分或 handoff graph 需要修改,应回 `ARCHITECTING`;如果需求或验收标准变化,应走 RFC。
|
|
31
|
+
|
|
30
32
|
实现时遵循小步闭环:先检查 `git status`,确认工作区没有未归属到当前 task 的脏变更;再定位相关代码和测试,做必要修改,运行 gate,修复失败,写入或更新相关 implementation doc 并刷新文档派生视图。直接运行 `make validate-dev` 或 `npx sdlc-harness validate-dev` 是开发中 gate,允许当前 `SPRINTING` task 仍然 open,并校验 `current_task_id`、task 合同、dirty files、draft queue 和 implementation doc。此时先不要从 `plan.yaml` 移除当前 task,要在当前 task 仍位于 `plan.yaml` 时创建 task implementation commit;随后再移除 task,创建 task completion ledger commit,并 push 两个 commit。`make validate-current` / `/advance` 是阶段出口 gate,必须在 open task 已移除后才通过。不要顺手重构、重排格式或处理无关问题;如果发现无关风险,只记录或报告。
|
|
31
33
|
|
|
32
34
|
开发阶段默认先评估当前 task 是否能安全并行。适合时,主 Agent 创建 `parallel_execution.trigger: "workflow_default"` 合同,默认使用 `runtime_managed` + `runtime.provider: "codex_native_subagents"` 调度 worker;用户明确要求并行、多 agent 或多 worktree 时使用 `trigger: "user_requested"`。主 Agent 声明每个 worker 的 `owned_paths`、`forbidden_paths`、`expected_output` 和 `required_gates`;非 native fallback 写仓库时还要声明 `branch` 和 `worktree`。worker 可以在各自非空、互不重叠且属于当前 task `allowed_paths` 的 owned paths 内实现,但不得直接修改 `plan.yaml`、`lifecycle.yaml`、`.docs/INDEX.md`、overview 或最终 implementation doc。主 Agent 负责 review、merge/cherry-pick、运行总 gate、更新事实源和完成两段提交。不适合拆分时继续串行 `/dev` 或 `/devloop` 并记录原因。
|
|
@@ -62,7 +64,7 @@ description: Use during SPRINTING to execute one task from plan.yaml, respecting
|
|
|
62
64
|
- task implementation commit 必须发生在 task 移除之前,避免实现变更和计划短期化混在同一个提交里。
|
|
63
65
|
- task completion ledger commit 发生在 implementation commit 之后,只负责将该 task 从当前 `plan.yaml` 移除。
|
|
64
66
|
- 一个开发 task 默认对应一个主要 implementation commit 和一个轻量 completion ledger commit。implementation commit message 应包含 task id,例如 `TASK-003: implement login rate limit`;push 成功前,不进入下一个 task。
|
|
65
|
-
- 本 Skill 不直接重切 PRD 或 tech plan;如果发现上游语义边界错误,进入 `BLOCKED`、创建 RFC,或请求回到 `ARCHITECTING
|
|
67
|
+
- 本 Skill 不直接重切 PRD 或 tech plan;如果发现上游语义边界错误,进入 `BLOCKED`、创建 RFC,或请求回到 `ARCHITECTING`。从 TESTING bugfix 回流的 `bugfix_implementation_gap` task 也不得重切技术方案;它必须引用 `TEST_REPORT.md` 的失败 scenario 和既有 tech plan,并只修实现偏差。
|
|
66
68
|
- gate 通过后调用 `pjsdlc_implementation_doc`,由该 Skill 按真实实现更新或新增 `.docs/04_implementation/` 模块级 slice。
|
|
67
69
|
- direct dev gate 与 phase-exit gate 语义不同:`validate-dev` 支持当前 open `SPRINTING` task;`validate-current` 在 `SPRINTING` 下仍会拒绝 open task,提示先完成 implementation commit 和 completion ledger。
|
|
68
70
|
- 如果一个任务实际变成多个独立实现边界,应停止扩大范围,拆分后续任务或回到任务规划。
|
|
@@ -75,7 +77,7 @@ description: Use during SPRINTING to execute one task from plan.yaml, respecting
|
|
|
75
77
|
每个 open task 都必须在 `plan.yaml` 中包含完整执行合同:
|
|
76
78
|
|
|
77
79
|
1. `current_task_id` 指向正在执行的 open task。
|
|
78
|
-
2. open task 直接声明 `phase: "SPRINTING"`、`docs`、`allowed_paths`、`required_gates`、`acceptance_criteria` 和 `implementation_doc`;runtime/app/provider/live 类 task 还必须声明 `evidence_level`、`target_runtime_environment` 和 `self_test_contract`。`self_test_contract.required_gates` 必须同步出现在 task `required_gates`,`self_test_contract.module_key_test_path` 必须描述从本地启动或调用入口开始,到完成所有自测 scenario 的模块关键测试路径,并覆盖本 task /
|
|
80
|
+
2. open task 直接声明 `phase: "SPRINTING"`、`docs`、`allowed_paths`、`required_gates`、`acceptance_criteria` 和 `implementation_doc`;runtime/app/provider/live 类 task 还必须声明 `evidence_level`、`target_runtime_environment` 和 `self_test_contract`。`self_test_contract.required_gates` 必须同步出现在 task `required_gates`,`self_test_contract.module_key_test_path` 必须描述从本地启动或调用入口开始,到完成所有自测 scenario 的模块关键测试路径,并覆盖本 task / 本模块承诺的所有可运行入口和内部关键路径;若 `graph_required: true`,`module_key_test_graph` 是复杂路径的 canonical detail,不能用长文字路径替代。
|
|
79
81
|
3. 如果 open task 是由 `plan.draft.yaml.tasks[]` promote 而来,创建正式 `TASK-*` 和删除源 draft 必须发生在同一次状态更新中;正式 task 的恢复现场只保存在 `plan.yaml`。
|
|
80
82
|
4. 任务执行中只保留恢复所需的简短 `working_notes`,目标 5-8 条且不得超过 8 条;high-risk runtime/live task 用 `resume_capsule` 保存恢复卡片,并链接 runbook / evidence index / exploration appendix。
|
|
81
83
|
5. gate、implementation doc、`.docs/INDEX.md` 和 `overview.md` 完成后,在当前 task 仍位于 `plan.yaml` 时创建 task implementation commit。
|
|
@@ -113,10 +115,12 @@ done task 的执行流水不在当前 `plan.yaml` 长期保留,也不是默认
|
|
|
113
115
|
- [ ] 当前任务仍然是单一清晰的执行单元。
|
|
114
116
|
- [ ] 技术方案或 task 承诺的 API/CLI/adapter/worker/provider、配置契约、输出/副作用和 fixture/live 边界已可运行并写入 implementation doc,或已明确 `BLOCKED`/后续 dev task。
|
|
115
117
|
- [ ] implementation doc `Development Evidence` 已记录 `Evidence Level`、`Target Runtime Environment`、`Runnable Entry`、`Observable Exit`、`Client / Server Initialization`、`Config Contract`、`Testing Handoff Readiness`、`Known Missing Runtime Boundaries`、`Basic Self-test Evidence`,或写明带原因的 `Not applicable`。
|
|
116
|
-
- [ ] 如果当前 task 有 `self_test_contract.status: "required"`,已逐条执行当前 `self_test_contract.scenarios[]` 和 `self_test_contract.required_gates`,并在 implementation doc `Development Self-Test Report` 写入 `Report Status`、本轮 contract source、scenario results、executed gates、
|
|
118
|
+
- [ ] 如果当前 task 有 `self_test_contract.status: "required"`,已逐条执行当前 `self_test_contract.scenarios[]` 和 `self_test_contract.required_gates`,并在 implementation doc `Development Self-Test Report` 写入 `Report Status`、本轮 contract source、Module Application Entry、scenario results、executed gates、Module Key Test Path、Observable Exit、Current Blocker、Testing Handoff Readiness 和 Evidence Index Refs,且 `Report Status: PASS`、所有 scenario 都是 `PASS`。
|
|
119
|
+
- [ ] 如果 `self_test_contract.graph_required: true` 或存在 `module_key_test_graph`,已在 `Development Self-Test Report` 写入实际 `Module Key Test Graph`,且 graph 覆盖入口、scenario、observable exit 和 evidence refs。
|
|
117
120
|
- [ ] 如果当前 task 是 high-risk runtime/live/remote-operator 工作,`resume_capsule` 已更新为 5-8 条恢复事实,`recovery_refs` 链接 implementation doc 和 `.docs/09_runbooks/**` runbook/evidence,implementation doc 已填写短的 `Current Operator Path` 和分层 `Gate Breakdown`。
|
|
118
121
|
- [ ] 如果 task 要求 `business_handoff_ready`,implementation doc 已写入 Testing Handoff Contract,包含入口、配置、初始化/health、输入样例、预期出口、清理方式和证据等级。
|
|
119
122
|
- [ ] 如果当前 task 来自 `plan.draft.yaml.tasks[]`,源 draft 已在 promote 时从 draft 列表删除。
|
|
123
|
+
- [ ] 如果当前 task 来自 TESTING bugfix 回流,已确认它是 `bugfix_implementation_gap`,并引用 `TEST_REPORT.md`、既有 tech plan 和 implementation doc。
|
|
120
124
|
- [ ] implementation doc 已生成或更新,并反映相关模块的真实代码。
|
|
121
125
|
- [ ] 如果启用了 `parallel_execution`,worker owned paths、forbidden paths、required gates 和主 Agent 集成结果已记录。
|
|
122
126
|
- [ ] gate 结果已写入 implementation doc `Verification`,必要时当前 task `working_notes` 也记录了恢复现场所需的 gate evidence。
|
|
@@ -21,7 +21,7 @@ implementation doc 只写长期实现事实,不写完整操作日记。对于
|
|
|
21
21
|
|
|
22
22
|
如果模块包含或承诺可运行系统边界,implementation doc 必须记录 runnable entry/exit:API/CLI/server route/service/agent/runtime/adapter/worker/provider 的调用方式、初始化方式、配置契约、输入来源、输出或副作用、fixture/live 模式边界,以及哪些真实外部执行器尚未实现。还必须在 `Development Evidence` 中记录开发阶段实际验证过的 `Evidence Level`、`Target Runtime Environment`、`Runnable Entry`、`Observable Exit`、`Client / Server Initialization`、`Config Contract`、`Testing Handoff Readiness`、`Known Missing Runtime Boundaries` 和 `Basic Self-test Evidence`;`Basic Self-test Evidence` 应指向已执行的 `Development Self-Test Report`。确实没有应用入口时,`Not applicable` 必须写清原因。不能把未来才会实现的入口写成当前事实,不能把 provider smoke、fixture smoke、fake adapter 或 one-shot smoke 单独写成 application readiness。如果 task 要求 `business_handoff_ready`,还必须写 Testing Handoff Contract,包含入口、配置、初始化/health、输入样例、预期出口、清理/reset/幂等说明和证据等级。
|
|
23
23
|
|
|
24
|
-
如果当前 task 有 `self_test_contract.status: "required"`,implementation doc 必须填写 `Development Self-Test Report`,把设计/RFC 阶段定义的自测合同执行完成:记录 `Report Status: PASS | BLOCKED | IN_PROGRESS | STALE`、contract source
|
|
24
|
+
如果当前 task 有 `self_test_contract.status: "required"`,implementation doc 必须填写 `Development Self-Test Report`,把设计/RFC 阶段定义的自测合同执行完成:记录 `Report Status: PASS | BLOCKED | IN_PROGRESS | STALE`、contract source、`Module Application Entry`、每个 scenario 的结果、executed gates、`Module Key Test Path`、`Observable Exit`、`Current Blocker`、`Testing Handoff Readiness` 和 `Evidence Index Refs`。`Development Self-Test Report` 是几十行交接卡,不是 debug log、operator log、runbook、evidence dump 或历史流水;不要写 `Actual Evidence` 正文字段。fallback / diagnostic 在主报告最多一句总结,详细命令、截图过程、UI 操作细节和失败路径进入 evidence index、exploration appendix 或 git history。High-risk runtime/live task 还必须写 `Current Operator Path` 和 `Gate Breakdown`,把 canonical operator path、runbook link、credential reference name、command/UI channel、hard constraints、do-not-retry summary 以及 local gate、cloud/service gate、executor/operator readiness、live smoke / handoff 分层记录,不能只写一个大 `validate-dev PASS`。凡会改变下一步动作的判断,必须 promoted 到 `plan.yaml#resume_capsule.do_not_retry` 或 runbook 顶部 `Hard Constraints`,不能只留在 evidence 或 appendix。`Development Self-Test Report` 只能记录当前 task 本轮实际执行后的结果;不得用历史报告、模板字段、代码阅读或无关通用 gate 替代本轮 self-test scenario 执行。`Module Key Test Path` 必须说明从本地启动或调用入口开始,执行并完成 `self_test_contract` 中全部自测用例的模块关键测试路径。该路径应覆盖本 task / 本模块承诺的所有可运行入口,以及自测用例实际经过的内部关键路径、关键边界、观察点和可观测完成证据,供后续 Agent 复用和 debug。如果 task contract 设置 `graph_required: true` 或包含 `module_key_test_graph`,还必须记录实际 `Module Key Test Graph`,用轻量 DAG 展示 entry、checkpoint、branch、scenario、observable_exit 与 evidence refs;图只放路径骨架和证据指针,不放执行 trace、命令输出、截图过程、operator log、debug log、runbook 正文或失败探索。任何 scenario 非 `PASS`,或 `Report Status` 为 `BLOCKED`、`IN_PROGRESS`、`STALE` 时,不得把开发 task 写成完成。
|
|
25
25
|
|
|
26
26
|
## 输入
|
|
27
27
|
|
|
@@ -53,7 +53,7 @@ implementation doc 只写长期实现事实,不写完整操作日记。对于
|
|
|
53
53
|
3. 与技术方案的偏移必须明确记录,即便该偏移是合理的。
|
|
54
54
|
4. runnable entry/exit、配置契约和 fixture/live 边界必须记录当前事实;缺失项写入 `未覆盖(Not covered)` 或方案偏移。
|
|
55
55
|
5. `Development Evidence` 必须包含 task 合同要求的证据等级、目标运行环境、实际可调用入口、可观察出口、初始化方式、配置契约、测试交接状态、缺失 runtime 边界和开发自测证据;页面类任务记录 dev server/page URL 与 browser check,API/CLI/worker/RPA/service/agent/runtime 类任务记录 startup/invocation command、endpoint/health/status 与 response/output/side effect。
|
|
56
|
-
6. `Development Self-Test Report` 必须记录 `Report Status`、当前 task 本轮执行 `self_test_contract` 中全部 scenario 和 required gates 后的结果,并记录从本地启动或调用入口开始,到完成所有自测用例的 `Module Key Test Path`;路径必须覆盖本 task / 本模块承诺的所有可运行入口、内部关键路径、关键边界、观察点和完成证据,不能只补一句 smoke 结果,也不能复用历史 PASS、模板字段、代码阅读或无关通用 gate
|
|
56
|
+
6. `Development Self-Test Report` 必须记录 `Report Status`、当前 task 本轮执行 `self_test_contract` 中全部 scenario 和 required gates 后的结果,并记录从本地启动或调用入口开始,到完成所有自测用例的 `Module Key Test Path`;路径必须覆盖本 task / 本模块承诺的所有可运行入口、内部关键路径、关键边界、观察点和完成证据,不能只补一句 smoke 结果,也不能复用历史 PASS、模板字段、代码阅读或无关通用 gate 作为本轮证据。若 contract 包含 `module_key_test_graph` 或 `graph_required: true`,报告还必须记录实际 `Module Key Test Graph`。
|
|
57
57
|
7. 测试覆盖必须列出具体测试,或明确记录覆盖缺口。
|
|
58
58
|
8. 文档粒度保持在模块、子系统或核心数据流级别;不要默认按 task 建文档,也不要写成跨全项目的巨型百科。
|
|
59
59
|
|
|
@@ -65,8 +65,9 @@ implementation doc 只写长期实现事实,不写完整操作日记。对于
|
|
|
65
65
|
- [ ] 核心数据流已说明。
|
|
66
66
|
- [ ] runnable entry/exit、配置契约和 fixture/live 边界已记录,或缺失项已明确标注。
|
|
67
67
|
- [ ] `Development Evidence` 已记录 `Evidence Level`、`Target Runtime Environment`、`Runnable Entry`、`Observable Exit`、`Client / Server Initialization`、`Config Contract`、`Testing Handoff Readiness`、`Known Missing Runtime Boundaries`、`Basic Self-test Evidence`,或带原因的 `Not applicable`。
|
|
68
|
-
- [ ] 如果当前 task 有 `self_test_contract.status: "required"`,`Development Self-Test Report` 已记录 `Report Status`、contract source、scenario results、executed gates、Module Key Test Path、
|
|
69
|
-
- [ ]
|
|
68
|
+
- [ ] 如果当前 task 有 `self_test_contract.status: "required"`,`Development Self-Test Report` 已记录 `Report Status`、contract source、Module Application Entry、scenario results、executed gates、Module Key Test Path、Observable Exit、Current Blocker、Testing Handoff Readiness 和 Evidence Index Refs。
|
|
69
|
+
- [ ] 如果 contract 包含 `module_key_test_graph` 或 `graph_required: true`,`Development Self-Test Report` 已记录实际 `Module Key Test Graph`,且图内只有路径骨架和 evidence pointer。
|
|
70
|
+
- [ ] 如果当前 task 是 high-risk runtime/live/remote-operator 工作,implementation doc 主线只保留实现事实、短 `Current Operator Path`、hard constraints 和恢复链接,`Gate Breakdown` 已分层记录,本轮失败探索已隔离到 exploration appendix。
|
|
70
71
|
- [ ] `business_handoff_ready` task 已记录 Testing Handoff Contract。
|
|
71
72
|
- [ ] 已判断 implementation doc 的语义切片边界。
|
|
72
73
|
- [ ] 方案偏移和测试覆盖已记录。
|