Commit Graph

40 Commits

Author SHA1 Message Date
Lex Christopherson
70cfd76c21 fix(execute-phase): include VERIFICATION.md in phase completion commit
Phase completion commit now stages VERIFICATION.md alongside ROADMAP.md,
STATE.md, and REQUIREMENTS.md so verification results are tracked.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-15 11:35:53 -06:00
Lex Christopherson
8e6ad96af1 feat(verification): add verify → plan → execute loop for gap closure
- Add verify_phase_goal step to execute-phase workflow
- Verifier outputs structured gaps: YAML for planner consumption
- Add --gaps flag to plan-phase for gap closure mode
- Route by verification status: passed, gaps_found, human_needed
- Gap closure creates sequential plans (04, 05...) from verification gaps
- User stays in control at each decision point

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-15 10:34:38 -06:00
Lex Christopherson
f3f6707cbe feat: add gsd-verifier subagent for phase goal verification
- gsd-verifier.md: dedicated verification subagent with all logic baked in
- Goal-backward verification: checks codebase, not SUMMARY claims
- Creates VERIFICATION.md, returns status to orchestrator
- execute-phase spawns gsd-verifier instead of general-purpose

Co-Authored-By: Claude <noreply@anthropic.com>
2026-01-15 09:51:14 -06:00
Lex Christopherson
e95186b2a7 refactor: update execute commands to spawn gsd-executor subagent
- execute-plan.md: spawn gsd-executor instead of general-purpose with template
- execute-phase.md: spawn gsd-executor for wave-based parallel execution
- Remove template filling, subagent has all logic baked in

Co-Authored-By: Claude <noreply@anthropic.com>
2026-01-15 09:34:32 -06:00
Lex Christopherson
bd4bd9db53 refactor: remove dead code, improve execute-phase UX, fix requirements flow
- Remove phantom status.md command (background agent model abandoned)
- Remove agent-history.md template (unused)
- Remove _archive/ directory
- Add narration to execute-phase (describe what's being built before/after waves)
- Update new-project to offer define-requirements as fast path
- Make define-requirements work without research (gather through questioning)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-15 01:04:41 -06:00
Lex Christopherson
62f12794dd chore: remove dead ISSUES.md system
Remove the global ISSUES.md deferred enhancement tracking system.

- Delete /gsd:consider-issues command (never used)
- Delete issues.md template (never instantiated)
- Remove Rule 5 from deviation rules (never triggered)
- Remove all ISSUES.md, ISS-XXX, and "deferred issues" references
- Update STATE.md to track pending todos instead

The ISSUES.md system was designed to capture non-critical enhancements
during plan execution via "Rule 5", but it never fired in practice
across 100+ projects. The system added ~350 lines of dead code.

The /gsd:add-todo and /gsd:check-todos system serves the same purpose
and is actually used.

Note: UAT *-ISSUES.md files (per-plan, created by /gsd:verify-work)
are unaffected - those are a separate, active system.

Closes #56

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-14 12:33:18 -06:00
Lex Christopherson
d30893a834 feat: pre-compute wave numbers at plan time
Wave numbers now computed during plan-phase and stored in PLAN.md
frontmatter. Execute-phase reads wave directly instead of deriving
from depends_on at runtime.

- Add assign_waves step to plan-phase workflow
- Add wave field to frontmatter (plan-format, phase-prompt template)
- Simplify execute-phase: remove analyze_dependencies and group_into_waves
- Replace with group_by_wave that just reads frontmatter integers

Co-Authored-By: Claude <noreply@anthropic.com>
2026-01-13 18:10:20 -06:00
Lex Christopherson
69300f975f fix(checkpoints): replace resume with fresh continuation agents
Resume fails when subagents use parallel tool calls due to Claude Code
serialization bug (consecutive assistant entries with same message ID).

Solution: Subagents return structured checkpoint state, orchestrator
spawns fresh agent with continuation-prompt template instead of resuming.

New files:
- templates/checkpoint-return.md: Structured format with completed tasks table
- templates/continuation-prompt.md: Template for spawning continuation agent

Updated:
- templates/subagent-task-prompt.md: Reference checkpoint-return, remove resume language
- workflows/execute-phase.md: Replace Task(resume=id) with fresh agent spawn
- workflows/execute-plan.md: Update checkpoint_return_for_orchestrator step

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-13 17:44:43 -06:00
Lex Christopherson
d5c08e1685 feat(execute-phase): load project state before execution
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-13 17:03:06 -06:00
Lex Christopherson
e5d4ecc28c feat: parallel-first planning with dependency graphs and checkpoint-resume
- plan-phase.md: dependency-first planning, vertical slices default
- phase-prompt.md: autonomous field, wave structure, frontmatter table
- scope-estimation.md: parallel default, removed "parallel-aware" framing
- plan-format.md: frontmatter docs with depends_on, files_modified, autonomous
- execute-phase.md: checkpoint-resume flow using Task resume parameter

Plans now declare explicit dependencies via frontmatter. Wave assignment
is automatic based on depends_on + files_modified. Checkpoints pause
subagent, return to orchestrator, user responds, orchestrator resumes.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-13 16:32:03 -06:00
Lex Christopherson
e30e387c00 refactor(execute-phase): wave-based blocking execution
Replace background agents + polling with blocking Task calls.
Orchestrator stays lean (~15% context), subagents load full workflow.

- Archive old execute-phase command and workflow
- Add subagent-task-prompt.md template (orchestrator→subagent contract)
- Rewrite execute-phase with wave-based parallelization
- Dependency analysis groups plans into execution waves
- Parallel Task calls within waves, sequential across waves
- No TaskOutput polling - Task blocks until completion

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-13 16:06:17 -06:00
Lex Christopherson
755b28e644 refactor(10): simplify plan frontmatter for parallelization
Remove confusing `parallelizable` boolean field. It was redundant -
execute-phase already computes parallelizability from `depends_on`
and file conflicts.

Changes:
- Remove `parallelizable: true|false` from plan frontmatter
- Rename `files_exclusive` to `files_modified` (clearer intent)
- Simplify execute-phase dependency detection logic
- Update phase-prompt template and plan-phase workflow

Parallelization is now fully automatic based on:
- `depends_on: []` (empty = independent)
- `files_modified: [...]` (no overlap = can parallelize)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-12 14:55:40 -06:00
Lex Christopherson
b810d1ddca fix(execute-phase): add one-subagent-per-plan constraint
Context isolation is the primary goal, not parallelization.
Even sequential plans spawn separate subagents for fresh 200k context.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-12 14:34:37 -06:00
Lex Christopherson
5c8e5dffbf feat(11-03): use frontmatter for categorization and wave calculation
- Update categorization table to show frontmatter-aware criteria
- Add categorization priority documentation
- Update calculate_wave() to check frontmatter depends_on first
- Handle parallelizable: false as implicit Wave 2+ assignment
- Fall back to inferred requires only when no frontmatter
- Add [frontmatter] annotation in wave output for plans using new fields
2026-01-12 14:18:30 -06:00
Lex Christopherson
9fcc2a4409 feat(11-03): read parallelization frontmatter in execute-phase
- Add PLAN_PARALLELIZABLE, PLAN_DEPENDS_ON, PLAN_FILES_EXCLUSIVE arrays
- Check for parallelizable, depends_on, files_exclusive in plan frontmatter
- Use frontmatter values directly when present
- Fall back to inference logic for old plans without frontmatter
- Document dependency detection priority
2026-01-12 14:17:52 -06:00
Lex Christopherson
8e8fba2793 fix(10-02): load execute-plan.md context in execute-phase command
- Command now loads both workflows (execution + orchestration)
- Agents commit tasks normally (removed DON'T COMMIT instruction)
- Orchestrator only commits metadata after all agents complete
- No duplication - single source of truth for execution logic
2026-01-12 13:23:16 -06:00
Lex Christopherson
511def76a3 feat(10-02): implement parallel spawning and monitoring
- spawn_parallel_agents: Task tool with run_in_background, XML agent prompt,
  agent-history.json tracking with parallel_group, wave queuing
- monitor_parallel_completion: TaskOutput polling loop, completion report parsing,
  check_and_spawn_dependents, failure handling, progress display
- orchestrator_commit: merge conflict detection failsafe, per-plan staging,
  conflict resolution options
- Total: 956 lines (within 800-1200 target)
2026-01-12 13:07:10 -06:00
Lex Christopherson
caf28103e6 feat(10-02): implement dependency analysis step
- Bash implementation for extracting frontmatter requires
- File conflict detection with automatic dependency injection
- Topological sort wave calculation algorithm
- Checkpoint handling separation for foreground/parallel
- Example dependency graph table visualization
2026-01-12 12:57:50 -06:00
Lex Christopherson
af7720c9d7 feat(10-02): create execute-phase.md workflow structure
- 9 steps: load_project_state, identify_phase, analyze_plan_dependencies,
  parallelization_config, spawn_parallel_agents, monitor_parallel_completion,
  orchestrator_commit, create_phase_summary, offer_next
- Purpose, when_to_use, error_handling, success_criteria sections
- 543 lines total
2026-01-12 12:54:49 -06:00
Lex Christopherson
1690b53b31 refactor(10-01): rename execute-phase.md to execute-plan.md
- Preserves git history via git mv
- Prepares for separation of single-plan vs multi-plan execution
- execute-plan.md handles single PLAN.md execution
2026-01-12 12:38:43 -06:00
Lex Christopherson
6ba850712f feat: add subagent resume capability
Add ability to resume interrupted subagent executions using Task tool's
resume parameter. Tracks agent IDs during execution and enables seamless
continuation after session timeout, rate limits, or crashes.

- New /gsd:resume-task command for resuming interrupted agents
- Agent ID tracking in execute-phase workflow
- Dual storage: current-agent-id.txt (fast) + agent-history.json (audit)
- Auto-detection of interrupted agents in resume-project workflow
- File conflict warnings before resume

Closes #37

Co-Authored-By: davesienkowski <davesienkowski@users.noreply.github.com>
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-10 14:19:10 -06:00
Lex Christopherson
863f86e4be feat: surface verify-work option after plan execution
Add /gsd:verify-work to "Also available" sections in execute-phase workflow:
- Route A: After plan completion, before next plan
- Route B: After phase completion, before next phase
- Route C: After milestone completion, before archiving

Users can now easily run manual acceptance testing at any completion point.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-08 10:07:04 -06:00
Lex Christopherson
da884ea7f0 fix: enforce mandatory verification before phase/milestone completion routing
- Rewrite offer_next step in execute-phase.md as mandatory verification gate
- Rewrite offer_next_phase step in transition.md with explicit verification
- Rewrite route step in progress.md with numbered verification steps
- Replace broken regex [0-9] (only matched single digits) with ROADMAP.md reading
- Add decision tables mapping conditions to explicit routes (A, B, C, D)
- Require Claude to "State the counts" before any routing decision
- Add "Do NOT skip this verification" instruction to prevent premature completion claims

Fixes issue where Claude would declare "phase complete" or "milestone complete"
without verifying remaining plans actually exist.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-07 15:19:22 -06:00
Lex Christopherson
1b9c2f2455 fix: commit phase artifacts when created (#12)
Each phase workflow now commits its artifacts immediately:
- discuss-phase.md commits CONTEXT.md
- research-phase.md commits RESEARCH.md
- plan-phase.md commits PLAN.md (and DISCOVERY.md)
- execute-phase.md commits only execution artifacts (SUMMARY, STATE, ROADMAP)

Planning artifacts are inputs to execution and should be saved when created.
Execution artifacts are outputs and are committed after execution completes.

Closes #12
2026-01-06 12:12:21 -06:00
Lex Christopherson
85f0ea5c58 feat: TDD features use dedicated plans for full context quality
TDD requires 2-3 execution cycles (RED → GREEN → REFACTOR), each with
file reads, test runs, and potential debugging. This consumes 40-50%
of context for a single feature. Dedicated TDD plans ensure full
quality throughout the cycle.

- TDD plans use `type: tdd` frontmatter with `<feature>` element
- One feature per TDD plan (batching defeats the purpose)
- Target ~40% context usage for TDD plans
- Standard plans handle non-TDD work with 2-3 tasks

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-05 21:55:36 -06:00
Lex Christopherson
875ac900a2 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.
2026-01-05 16:09:14 -06:00
Lex Christopherson
3307c05f54 feat(06-01): YAML frontmatter schema with dependency graph metadata enabling automatic context assembly
- Added comprehensive YAML frontmatter schema to summary.md template
- Frontmatter includes dependency graph (requires/provides/affects), subsystem, tech tracking, key files
- Added frontmatter population guidance to execute-phase.md
- Enables intelligent summary selection via dependency graph scanning

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-05 09:43:02 -06:00
Lex Christopherson
5390b33bd2 feat(05-tdd): TDD integration with detection, annotation, and execution flow
- Add references/tdd.md with detection heuristics, red-green-refactor cycle
- Add tdd_annotation section to plan-format.md with task structure
- Expand plan-phase.md with TDD detection and annotation guidance
- Add tdd_execution section to execute-phase.md with commit patterns
- TDD-aware task routing in execute step

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-31 11:40:56 -06:00
Lex Christopherson
f24203dc91 fix: explicit plan count check in offer_next step
Adds bash logic to count PLAN vs SUMMARY files before deciding
whether to offer next plan or next phase. Fixes bug where GSD
would skip remaining plans in a phase.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-29 11:39:42 -06:00
Lex Christopherson
c11b744f27 fix: improve incremental codebase map updates
- Remove arbitrary ">3 files" threshold
- Add specific update actions per change type
- Add explicit skip conditions (bug fixes, content changes)
- Clarify update format: single targeted edits, not section rewrites
- Add "file renamed/moved" case to update paths

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-18 09:18:54 -06:00
Lex Christopherson
dccde98f64 fix: remove arbitrary 100-line limit from codebase mapping
The limit was causing loss of useful context, especially code examples
in TESTING.md and CONVENTIONS.md. Document quality > arbitrary brevity.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-17 15:11:30 -06:00
Lex Christopherson
c3273a50c1 fix: use inline code for Next Up commands (avoids nesting ambiguity) 2025-12-17 13:03:48 -06:00
Lex Christopherson
8d2f307451 feat(03-01): brownfield integration into GSD workflows
- new-project.md detects existing code, offers /gsd:map-codebase first
- plan-phase loads relevant codebase context based on phase type
- execute-phase updates codebase map incrementally after execution

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-17 10:37:57 -06:00
Lex Christopherson
733fc1440c feat: improved continuation UI with context and visual hierarchy
- Add continuation-format.md reference defining the standard format
- Replace "## To Continue" with "## ▶ Next Up"
- Show plan/phase name + description instead of just command paths
- Add `/clear` explanation: "fresh context window"
- Change "Other options" to "Also available"
- Add /gsd:research-phase to phase planning options
- Add visual separators and completion headers

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-17 09:00:18 -06:00
Lex Christopherson
d45fbd845d fix: replace inline command invocation with clear-then-paste pattern
End-of-command workflows now show explicit instructions to run /clear
and paste the next command, rather than offering numbered options that
invoke SlashCommand directly. This prevents users from accidentally
exhausting context by continuing work in the same session.

- Updated 16 files (commands and workflows)
- YOLO mode auto-continues preserved (user explicitly chose automation)
- In-workflow decisions like consider-issues preserved

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-16 09:33:51 -06:00
Lex Christopherson
a906e2ad35 refactor: use <if mode> tags for yolo/interactive branching
Cleaner conditional structure in execute-phase and transition workflows.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-16 08:20:15 -06:00
Lex Christopherson
b4de126ade fix: update stale CONTEXT.md references to new vision structure
plan-phase, execute-phase, resume-project now reference:
- <vision> instead of <phase_objectives>
- <essential> instead of <constraints>/<risks>
- <boundaries> instead of <success_indicators>

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-16 08:19:24 -06:00
Lex Christopherson
4e72b469a0 Include PLAN.md in phase completion commits
Preserve the execution plan alongside SUMMARY.md in git history.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-15 17:42:19 -06:00
Lex Christopherson
2e1b0b8d70 Add issue triage system to prevent deferred issue pile-up
- /gsd:consider-issues reviews issues with codebase context
- Phase completion now prompts for issue review
- Auto-categorizes: resolved, urgent, natural-fit, can-wait
- README: explain context exhaustion problem and subagent solution

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-15 08:25:51 -06:00
Lex Christopherson
1fe3fa427e Initial commit: Get Shit Done - meta-prompting system for Claude Code
- NPX install: npx get-shit-done-cc
- Slash commands for project management
- Context engineering templates and workflows

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-15 07:44:41 -06:00