tangweijie a26f65a3d8 docs: 收口 REV-004 一期正式文档与交付闭环
统一 REV-004 一期范围、接口口径、数据库承接口径与追溯关系,
并补齐执行手册、quickstart、tasks 及治理台账,完成可执行交付闭环。
2026-03-13 15:02:29 +08:00

14 KiB
Raw Blame History

Tasks: REV-004 账务处理一期

Input: Design documents from /specs/001-rev004-accounting/ Prerequisites: plan.md (required), spec.md (required), research.md, data-model.md, contracts/

Validation: Validation tasks are NOT optional in this repository. Every document change task set MUST include the applicable validation and ledger-sync tasks.

Organization: Tasks are grouped by user story so each document-maintenance slice can be completed, reviewed, and validated independently.

Format: [ID] [P?] [Story] Description

  • [P]: Can run in parallel (different files, no dependencies)
  • [Story]: Which user story this task belongs to (e.g., US1, US2, US3)
  • Include exact file paths in descriptions

Path Conventions

  • Main documents: docs/design/01_Overview/, docs/design/02_Detailed_Design/, docs/design/03_Technical_Design/
  • Governance documents: docs/design/00_Management/
  • Archive references: docs/design/04_Appendix/Archive/
  • Runtime guidance: README.md, AGENTS.md, .specify/templates/

Phase 1: Setup (Shared Foundation)

Purpose: Confirm the source-of-truth set, target files, and planning artifacts before editing formal documents.

  • T001 Read prerequisite governance documents docs/design/00_Management/01_Project_Progress.md, docs/design/00_Management/02_Delivery_Standards.md, and docs/design/00_Management/03_Task_Checklist.md before formal document edits
  • T002 Confirm target chapters and intended updates in specs/001-rev004-accounting/spec.md, specs/001-rev004-accounting/plan.md, docs/design/02_Detailed_Design/12_REV_Detailed.md, docs/design/03_Technical_Design/03_Interface_Design.md, and docs/design/03_Technical_Design/01_Database_Design.md
  • T003 [P] Confirm source-of-truth and allowed references using .specify/memory/constitution.md, docs/design/01_Overview/03_Summary_Design.md, docs/design/02_Detailed_Design/12_REV_Detailed.md, docs/design/03_Technical_Design/03_Interface_Design.md, and docs/design/03_Technical_Design/01_Database_Design.md
  • T004 [P] Confirm scope boundary, exclusions, traceability anchors, and impacted files in specs/001-rev004-accounting/research.md, specs/001-rev004-accounting/contracts/rev004-scenario-matrix.md, specs/001-rev004-accounting/contracts/rev004-traceability-matrix.md, and docs/guides/REV004_ACCOUNTING_EXECUTION_PLAYBOOK.md

Phase 2: Foundational Alignment (Blocking Prerequisites)

Purpose: Prepare the common wording, structure, and traceability baseline that all user stories depend on.

  • T005 Normalize common terminology, scenario names, and approval boundary wording in specs/001-rev004-accounting/data-model.md, specs/001-rev004-accounting/contracts/if-rev-007-accounting-request.md, and specs/001-rev004-accounting/contracts/rev004-scenario-matrix.md
  • T006 [P] Map shared entities and result fields from specs/001-rev004-accounting/data-model.md into target update notes for docs/design/02_Detailed_Design/12_REV_Detailed.md and docs/design/03_Technical_Design/03_Interface_Design.md
  • T007 [P] Map shared physical carriers from specs/001-rev004-accounting/contracts/rev004-traceability-matrix.md into target update notes for docs/design/03_Technical_Design/01_Database_Design.md
  • T008 Establish a single update checklist for validation and ledger-sync using specs/001-rev004-accounting/quickstart.md, docs/design/00_Management/01_Project_Progress.md, and docs/design/00_Management/03_Task_Checklist.md

Phase 3: User Story 1 - 收敛一期范围 (Priority: P1) 🎯 MVP

Goal: 在正式详细设计与执行手册中明确 REV-004 一期纳入范围、排除项、共性能力优先顺序与审批边界。

Independent Test: 审阅者仅通过 docs/design/02_Detailed_Design/12_REV_Detailed.mddocs/guides/REV004_ACCOUNTING_EXECUTION_PLAYBOOK.md,即可确认一期纳入场景、排除项、审批边界和“共性能力先统一、场景能力再分批”的组织方式一致。

Implementation for User Story 1

  • T009 [US1] Update REV-004 一期范围、排除项、共性能力顺序和审批边界 in docs/design/02_Detailed_Design/12_REV_Detailed.md
  • T010 [US1] Sync REV-004 执行范围、验收入口和后续实施组织方式 in docs/guides/REV004_ACCOUNTING_EXECUTION_PLAYBOOK.md
  • T011 [P] [US1] Sync REV-004 一期范围摘要 and cross-references in docs/design/01_Overview/03_Summary_Design.md
  • T012 [US1] Update traceability note for scoped scenarios in specs/001-rev004-accounting/contracts/rev004-traceability-matrix.md
  • T013 [US1] Run make validate-file FILE=docs/design/02_Detailed_Design/12_REV_Detailed.md and capture result for docs/design/02_Detailed_Design/12_REV_Detailed.md
  • T014 [US1] Run make validate-file FILE=docs/guides/REV004_ACCOUNTING_EXECUTION_PLAYBOOK.md and capture result for docs/guides/REV004_ACCOUNTING_EXECUTION_PLAYBOOK.md
  • T015 [US1] Run make check-links and capture cross-document link result for US1 file changes
  • T016 [US1] Update important progress note in docs/design/00_Management/01_Project_Progress.md if US1 produces an important formal document change after validation passes
  • T017 [US1] Update REV-004 scope task status in docs/design/00_Management/03_Task_Checklist.md if US1 completes a tracked task or materially changes its closure condition

Checkpoint: User Story 1 is reviewable, validated, and ledger-synced independently.


Phase 4: User Story 2 - 对齐接口与数据口径 (Priority: P2)

Goal: 在详细设计、接口设计与数据库设计中统一 IF-REV-007、账单承接对象、原交易校验对象、结果表达和留痕对象。

Independent Test: 审阅者仅通过对照 docs/design/02_Detailed_Design/12_REV_Detailed.mddocs/design/03_Technical_Design/03_Interface_Design.mddocs/design/03_Technical_Design/01_Database_Design.md,即可确认 REV-004 的核心场景、请求/响应字段、物理承接口径和追溯关系一致。

Implementation for User Story 2

  • T018 [US2] Update REV-004 scenario rules, result fields, and log requirements in docs/design/02_Detailed_Design/12_REV_Detailed.md
  • T019 [US2] Update IF-REV-007 request/response, approval boundary, and acceptance notes in docs/design/03_Technical_Design/03_Interface_Design.md
  • T020 [US2] Update REV-004 physical carrier wording for biz_charge*, bk_transaction*, and biz_operat_log* in docs/design/03_Technical_Design/01_Database_Design.md
  • T021 [P] [US2] Sync shared entity and field mapping notes in specs/001-rev004-accounting/data-model.md
  • T022 [P] [US2] Sync contract details and scenario matrix notes in specs/001-rev004-accounting/contracts/if-rev-007-accounting-request.md and specs/001-rev004-accounting/contracts/rev004-scenario-matrix.md
  • T023 [US2] Update traceability rows for interface/database alignment in specs/001-rev004-accounting/contracts/rev004-traceability-matrix.md
  • T024 [US2] Run make validate-file FILE=docs/design/02_Detailed_Design/12_REV_Detailed.md and capture result for US2 detailed design changes
  • T025 [US2] Run make validate-file FILE=docs/design/03_Technical_Design/03_Interface_Design.md and capture result for interface design changes
  • T026 [US2] Run make validate-file FILE=docs/design/03_Technical_Design/01_Database_Design.md and capture result for database design changes
  • T027 [US2] Run make check-links and capture cross-document link result for US2 file changes
  • T028 [US2] Update important progress note in docs/design/00_Management/01_Project_Progress.md if US2 produces an important formal document change after validation passes
  • T029 [US2] Update REV-004 interface/database alignment task status in docs/design/00_Management/03_Task_Checklist.md if US2 completes a tracked task or materially changes its closure condition

Checkpoint: User Story 2 is reviewable and validated independently.


Phase 5: User Story 3 - 形成可执行交付闭环 (Priority: P3)

Goal: 在执行手册与管理台账中固化 REV-004 的后续实施顺序、验收入口、最小校验动作与台账更新触发条件。

Independent Test: 审阅者仅通过 docs/guides/REV004_ACCOUNTING_EXECUTION_PLAYBOOK.mddocs/design/00_Management/01_Project_Progress.mddocs/design/00_Management/03_Task_Checklist.md,即可确认 REV-004 后续 tasks 的拆解依据、验收入口、最小校验动作和台账同步方式已经明确。

Implementation for User Story 3

  • T030 [US3] Update REV-004 execution sequence, independent acceptance entry, and validation steps in docs/guides/REV004_ACCOUNTING_EXECUTION_PLAYBOOK.md
  • T031 [US3] Record REV-004 planning milestone and next-step entry in docs/design/00_Management/01_Project_Progress.md if US3 forms an important governance or formal delivery milestone
  • T032 [US3] Update REV-004 tracked checklist items and completion criteria in docs/design/00_Management/03_Task_Checklist.md if US3 completes or materially redefines a tracked task
  • T033 [P] [US3] Sync quick review and validation wording in specs/001-rev004-accounting/quickstart.md
  • T034 [P] [US3] Sync task-splitting and closure assumptions in specs/001-rev004-accounting/plan.md
  • T035 [US3] Run make validate-file FILE=docs/guides/REV004_ACCOUNTING_EXECUTION_PLAYBOOK.md and capture result for execution playbook changes
  • T036 [US3] Run make validate-file FILE=docs/design/00_Management/01_Project_Progress.md and capture result for project progress changes
  • T037 [US3] Run make validate-file FILE=docs/design/00_Management/03_Task_Checklist.md and capture result for task checklist changes
  • T038 [US3] Run make check-links and capture cross-document link result for US3 file changes

Checkpoint: All planned document updates are independently reviewable, validated, and ledger-synced.


Final Phase: Polish & Cross-Cutting Closure

Purpose: Ensure repository-wide consistency after all story slices are complete.

  • T039 [P] Re-check source-of-truth alignment across docs/design/02_Detailed_Design/12_REV_Detailed.md, docs/design/03_Technical_Design/03_Interface_Design.md, docs/design/03_Technical_Design/01_Database_Design.md, and docs/guides/REV004_ACCOUNTING_EXECUTION_PLAYBOOK.md
  • T040 [P] Re-check relative links, traceability rows, and Mermaid consistency across docs/design/01_Overview/03_Summary_Design.md, docs/design/00_Management/01_Project_Progress.md, docs/design/00_Management/03_Task_Checklist.md, and specs/001-rev004-accounting/contracts/rev004-traceability-matrix.md
  • T041 Prepare final change summary with modified files, validation results, remaining risks, and next-step suggestions in the final response for /specs/001-rev004-accounting/tasks.md

Dependencies & Execution Order

Phase Dependencies

  • Phase 1: Setup: No dependencies; MUST finish before document updates.
  • Phase 2: Foundational Alignment: Depends on Phase 1; MUST finish before story implementation.
  • US1 (P1): Starts after Phase 2; defines the MVP scope baseline.
  • US2 (P2): Starts after US1 scope wording is stable, because interface/database alignment depends on agreed scenario scope.
  • US3 (P3): Starts after US1 and US2, because ledger closure depends on settled scope and aligned formal documents.
  • Final Phase: Depends on all selected user stories being complete.

Within Each User Story

  • Update formal target documents before syncing contracts, quickstart, or traceability notes.
  • Complete content edits before running validation commands.
  • Complete validation before writing progress or checklist ledger entries.
  • Complete ledger sync before final cross-cutting closure.

User Story Completion Order

  • US1 → US2 → US3

Parallel Opportunities

  • T003 and T004 can run in parallel after T001 and T002.
  • T006 and T007 can run in parallel after T005.
  • In US1, T010 and T011 can run in parallel after T009.
  • In US2, T021 and T022 can run in parallel after T018 / T019 / T020 complete.
  • In US3, T033 and T034 can run in parallel after T030 / T031 / T032 are scoped.
  • In the final phase, T039 and T040 can run in parallel.

Parallel Execution Examples

User Story 1

# After T009 completes, run in parallel:
- T010 Update docs/guides/REV004_ACCOUNTING_EXECUTION_PLAYBOOK.md
- T011 Update docs/design/01_Overview/03_Summary_Design.md

User Story 2

# After T018/T019/T020 complete, run in parallel:
- T021 Sync specs/001-rev004-accounting/data-model.md
- T022 Sync specs/001-rev004-accounting/contracts/if-rev-007-accounting-request.md and rev004-scenario-matrix.md

User Story 3

# After core US3 updates are planned, run in parallel:
- T033 Sync specs/001-rev004-accounting/quickstart.md
- T034 Sync specs/001-rev004-accounting/plan.md

Implementation Strategy

MVP First (User Story 1 only)

先完成 US1把 REV-004 一期范围、排除项、审批边界和共性能力顺序稳定下来。只要 docs/design/02_Detailed_Design/12_REV_Detailed.mddocs/guides/REV004_ACCOUNTING_EXECUTION_PLAYBOOK.md 已可独立评审并完成最小校验,就可以形成第一版可评审增量。

Incremental Delivery

  1. 完成 US1锁定一期边界。
  2. 完成 US2打通详细设计、接口设计、数据库设计的一致口径。
  3. 完成 US3补齐执行手册与台账闭环。
  4. 完成 Final Phase做全局复核与结果汇总。

Notes

  • 每个任务都必须保持单一真源模型,不得把 Archive 直接当成正式输出。
  • 本 feature 未要求 TDD 或新增自动化测试,因此本任务列表不生成代码测试任务。
  • make check-links 在多个故事中重复出现,是因为每个故事都要求独立可验收。
  • 若后续正式文档未实际修改,可在执行时将对应台账更新任务标记为不适用,但必须先给出理由。