docs: migrate project memory governance

This commit is contained in:
inman committed 2026-08-30 15:31:12 +08:00
1 parent 7b5d855b09
commit e7aa58a203
37 files changed
+942 -34

No files matched your search

@@ -0,0 +1,69 @@
# Task: Migrate project docs governance
## Identity
- Task ID: 20260828-migrate-project-docs-6f1a9c2d
- Mode: Integration
- Branch: main
- Worktree: /Users/inmanx/Documents/lwltAPI
- Base commit: 7b5d855b093af39bf834fab4f41f41b37be1170d
- Owner: codex
- Status: Ready for Integration
## Scope
- Initialize and adopt `.project-docs/` as the repository's durable project-memory system.
- Migrate known current state, architecture, domain boundaries, evidence pointers, commitments, and maintenance rules from the legacy root planning files and active project documentation.
- Archive and retire root `task_plan.md`, `findings.md`, and `progress.md` so the repository has one active documentation system.
- Update `AGENTS.md`, `README.md`, and repository hygiene tests to enforce the new entry and ownership workflow.
## Intent And Constraints
- Preserve all legacy content in date-scoped history before removing root files.
- Do not fabricate unknown project facts; keep unknowns and authorization-dependent validation explicit.
- Do not change business behavior, source contracts, release artifacts, ERP state, services, deployment, or external systems.
- Keep this migration exclusively owned under the integration lock; no sub-agents or concurrent task scopes are involved.
- Use the bundled `maintain-project-docs` scripts for initialization, ownership, validation, drift checking, and task completion.
## Plan
1. Scan active references and inspect governance/test files that depend on the legacy root planning files.
2. Freeze exact legacy files into `archive/project-history/2026-08-28/` and update its index.
3. Populate the canonical `.project-docs` brief, current state, decisions, architecture, domain, evidence, reflection, commitments, and maintenance records from verified local sources.
4. Update project entry documents and repository hygiene checks, then remove the legacy root files.
5. Run document checks, drift checks, the repository's five required gates, size/hash/link/diff checks, and complete the task context.
## Outcome
- Initialized the complete `.project-docs/` concurrency and canonical-memory tree with the bundled non-overwriting initializer.
- Claimed the known dirty `main` worktree in exclusive Integration mode and acquired the repository integration lock.
- Populated project positioning, success criteria, integrated state/history, decisions, architecture, domain rules, glossary, evidence, reflection, commitments, stale-state guidance, and project authority pointers from verified local sources.
- Updated `AGENTS.md`, `README.md`, and repository hygiene tests so future repository tasks use `maintain-project-docs` and the Concurrent Task Gate.
- Preserved the final legacy `task_plan.md`, `findings.md`, and `progress.md` byte-for-byte in `archive/project-history/2026-08-28/`, indexed their hashes, and removed the root copies to prevent dual project-memory systems.
- No business code, contracts, release artifacts, ERP state, service process, deployment, or external system was changed.
## Verification
- 2026-08-30 completion recheck: the user explicitly authorized finishing, committing, and releasing the known governance migration changes.
- `check_project_docs.py`: passed.
- `task_context.py doctor`: registry consistent.
- `check_doc_drift.py --task-id 20260828-migrate-project-docs-6f1a9c2d`: passed after resolving the initializer placeholder issue recorded below.
- Repository governance: 9/9 passed, including root boundaries, `.project-docs` authority, Markdown links, archive indexes, release hashes, and package/source equality.
- TypeScript check: passed.
- Control-plane tests: 127/127 passed.
- Legacy/platform/tools tests: 248/248 passed.
- Build: passed.
- Two macOS-generated `.DS_Store` files were moved out of the repository before the final verification; they contained no project source or task state.
- Final legacy archive SHA-256 and byte comparisons: all three passed.
## Gate Notes
- The first drift check correctly blocked six initializer-created `.gitkeep` files inside task-owned supporting directories because they had no task ID owner. The empty placeholders were removed; task records create their parent directory automatically, and future optional supporting directories are created only when a valid task-prefixed record is needed. No project information was deleted.
## Follow-ups
- Authorization-dependent ERP and AgentBus follow-ups were integrated into `.project-docs/80-commitments/commitments.md`; this documentation migration creates no additional operational follow-up.
## Promotion Candidates
- None. This task ran in Integration mode and applied the user-approved project-memory migration directly to canonical documentation.