feat: implement per-task atomic commits for better AI observability

- Each task commits immediately after completion (feat/fix/test/refactor)
- Plan completion commits metadata only (docs: SUMMARY + STATE + ROADMAP)
- Git history becomes primary context source for future Claude sessions
- Better bisect granularity, failure recovery, and revert capabilities

Changes:
- execute-phase.md: Added <task_commit> protocol and per-task commit flow
- execute-plan.md: Updated commit rules and success criteria
- git-integration.md: New task-completion format, strategy rationale
- tdd.md: Aligned TDD commits with standard task commit pattern
- summary.md: Added Task Commits section with commit hashes
- README.md: Rewrote git history section with atomic commit benefits
- scope-estimation.md: Clarified commit counts per plan
- principles.md: Added <atomic_commits> section explaining strategy

Each plan now produces 3-4 commits (2-3 task commits + 1 metadata commit)
instead of single monolithic commit. Optimizes observability for solo
developer + Claude Code workflow.
This commit is contained in:
Lex Christopherson
2026-01-05 16:09:14 -06:00
parent a6df00ab2a
commit 875ac900a2
8 changed files with 430 additions and 79 deletions

View File

@@ -80,7 +80,7 @@ Plan 1: "Auth Database Models" (2 tasks)
Plan 2: "Auth API Core" (3 tasks)
Plan 3: "Auth API Protection" (2 tasks)
Plan 4: "Auth UI Components" (2 tasks)
Each: 30-40% context, peak quality, focused commits
Each: 30-40% context, peak quality, atomic commits (2-3 task commits + 1 metadata commit)
```
</anti_patterns>
@@ -137,7 +137,7 @@ Each plan: fresh context, peak quality. More plans = more thoroughness, same qua
<summary>
**2-3 tasks, 50% context target:**
- All tasks: Peak quality
- Git: Atomic, surgical commits
- Git: Atomic per-task commits (each task = 1 commit, plan = 1 metadata commit)
- Autonomous plans: Subagent execution (fresh context)
**The principle:** Aggressive atomicity. More plans, smaller scope, consistent quality.
@@ -145,5 +145,7 @@ Each plan: fresh context, peak quality. More plans = more thoroughness, same qua
**The rule:** If in doubt, split. Quality over consolidation. Always.
**Depth rule:** Depth increases plan COUNT, never plan SIZE.
**Commit rule:** Each plan produces 3-4 commits total (2-3 task commits + 1 docs commit). More granular history = better observability for Claude.
</summary>
</scope_estimation>