w05-task-closure

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

任务收尾规范

Task Closure Specification

适用于主要交付完成后的收尾阶段,确保日志、优化分析完整落地。

Applicable to the closure phase after major deliverables are completed, ensuring logs and optimization analysis are fully implemented.

⚠️ 核心强制要求

⚠️ Core Mandatory Requirements

触发条件

Trigger Conditions

  • 主要功能或文档交付已完成
  • 用户明确指示"进入收尾/后置流程"
  • Agent 交付总结后询问并获得同意
  • Major functions or document deliverables have been completed
  • User explicitly instructs "Enter closure/post-process"
  • Consent is obtained after the Agent delivers the summary and asks for confirmation

必须执行的流程

Mandatory Processes

  1. W00 同步检查:确认已通过
    w00-workflow-checkpoint
    完成最终 issue 同步(含最终 checkpoint 摘要与下一步信息)。
  2. 结构检查(再收尾):本任务涉及的所有代码文件 ≤300 行(
    file-size-limit
    )、职责清晰且无循环依赖(
    single-responsibility
    )。若超限或职责不清:先拆分/重构再继续收尾;若用户选择暂不处理,在日志中记录「遗留:结构问题」及建议。
  3. 生成任务日志:使用
    scripts/generate_task_log.py
  4. 六维度优化分析:代码质量/架构设计/性能/测试/可维护性/技术债务
若未绑定 Issue,需在收尾说明中明确记录原因与补建计划,并补充项目级任务视图的替代追踪方式。

  1. W00 Synchronization Check: Confirm that the final issue synchronization (including the final checkpoint summary and next-step information) has been completed via
    w00-workflow-checkpoint
    .
  2. Structure Check (Final Closure): All code files involved in this task must be ≤300 lines (
    file-size-limit
    ), with clear responsibilities and no circular dependencies (
    single-responsibility
    ). If exceeding the limit or with unclear responsibilities: split/refactor first before proceeding with closure; if the user chooses to postpone handling, record "Outstanding: Structural Issues" and suggestions in the log.
  3. Generate Task Log: Use
    scripts/generate_task_log.py
  4. Six-Dimension Optimization Analysis: Code Quality/Architecture Design/Performance/Testability/Maintainability/Technical Debt
If no Issue is bound, clearly record the reason and plan for supplementing the Issue in the closure description, and supplement an alternative tracking method for the project-level task view.

AI Agent 行为要求

AI Agent Behavioral Requirements

主动询问

Proactive Inquiry

完成主要交付后,主动询问:
主要交付已完成。是否进入收尾流程?
After completing major deliverables, proactively ask:
Major deliverables have been completed. Would you like to proceed to the closure process?

完成汇报

Completion Report

收尾完成后汇报日志位置和分析要点。
After completing the closure, report the log location and key analysis points.

与 W00 协同(自动 + 手动)

Collaboration with W00 (Automatic + Manual)

  • 收尾前检查是否存在绑定的
    Issue #
  • 若存在:由
    w05-task-closure
    直接执行任务关闭;必要时仅调用
    w00-workflow-checkpoint
    补最后一次 checkpoint 存档。

  • Before closure, check if there is a bound
    Issue #
    .
  • If exists: Directly execute task closure via
    w05-task-closure
    ; if necessary, only call
    w00-workflow-checkpoint
    to supplement the final checkpoint archive.

禁止事项

Prohibited Items

  • ❌ 跳过收尾流程或伪造执行结果
  • ❌ 漏写日志核心字段、六维分析
  • ❌ 未说明未执行项的原因与计划

  • ❌ Skip the closure process or falsify execution results
  • ❌ Omit core log fields or six-dimension analysis
  • ❌ Fail to explain the reasons and plans for unexecuted items

工具脚本

Tool Scripts

脚本
scripts/generate_task_log.py
功能:生成符合规范的任务日志,包含六维度优化分析

Script:
scripts/generate_task_log.py
Function: Generate standardized task logs, including six-dimension optimization analysis

参考资料

Reference Materials

  • references/closure-workflow.md
    - 收尾工作流详细说明(触发条件、结构检查、日志规范、六维度分析)
  • ../w00-workflow-checkpoint/SKILL.md
    - Workflow GitHub Issues 基础存档能力(自动 + 手动)
  • refactor-and-decompose/SKILL.md
    - 收尾前结构检查约束
  • references/closure-workflow.md
    - Detailed description of the closure workflow (trigger conditions, structure check, log specification, six-dimension analysis)
  • ../w00-workflow-checkpoint/SKILL.md
    - Workflow GitHub Issues basic archiving capability (Automatic + Manual)
  • refactor-and-decompose/SKILL.md
    - Structure check constraints before closure