Skip to content
32 changes: 32 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,45 @@ Format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).

## [Unreleased]

### Fixed
- **Statusline context bar** — corrected calculation to use Claude Code's actual 16.5% autocompact buffer instead of a hardcoded 80% ceiling, so the displayed percentage now reflects when compaction is truly imminent (#769)
- Color thresholds updated to intuitive levels: green < 50%, yellow < 65%, orange < 80%, red ≥ 80%
- Display now shows two decimal places (e.g. `42.37%`) so small context changes are visible
- **Hooks not tracked in file manifest** — `gsd-statusline.js`, `gsd-check-update.js`, and `gsd-context-monitor.js` are now included in `gsd-file-manifest.json` so local modifications are detected and backed up before `/gsd:update` (#769)

### Added
- **Adaptive model profile** — fourth model profile (`adaptive`) that auto-selects models per-plan based on complexity evaluation (#210)
- `evaluateComplexity()` scores plan metadata (files modified, task count, objective keywords, plan type, dependencies) on 0-10+ scale
- Three tiers: Simple (haiku/sonnet), Medium (sonnet/opus), Complex (opus/sonnet)
- `adaptive_settings` config: `min_model`/`max_model` clamping, `log_selections` usage logging
- `resolve-adaptive-model` CLI command with `--context` for per-plan resolution
- `init plan-phase` and `init quick` now return `model_profile` and `adaptive_settings` for workflow use
- Plan index includes `type` and `depends_on` for enriched complexity evaluation
- Verifier uses per-plan adaptive resolution when in adaptive mode
- Full backward compatibility — non-adaptive profiles unaffected
- `/gsd:report-bug` command for structured bug reporting with severity tracking, diagnostic log capture, and GitHub issue creation
- `gsd-tools bug list/update/resolve` CLI commands for bug management
- `gsd-tools init bugs` and `scaffold bugs` for workflow bootstrapping
- Severity inference from keywords (critical/high/medium/low)
- Automatic diagnostic capture (git state, log files, error output)
- Optional GitHub issue creation via `gh` CLI
- Bug lifecycle: reported → investigating → fixing → resolved

## [1.22.0] - 2026-02-27

### Added
- Codex multi-agent support: `request_user_input` mapping, multi-agent config, and agent role generation for Codex runtime
- Analysis paralysis guard in agents to prevent over-deliberation during planning
- Exhaustive cross-check and task-level TDD patterns in agent workflows
- Code-aware discuss phase with codebase scouting — `/gsd:discuss-phase` now analyzes relevant source files before asking questions
- Concurrent milestone execution: work on multiple milestones in parallel with isolated state (#291)
- Milestone-scoped directories under `.planning/milestones/<name>/`
- `ACTIVE_MILESTONE` pointer file for switching context
- `/gsd:switch-milestone` command with in-progress work warnings
- `--milestone` CLI flag for explicit milestone targeting
- Statusline shows active milestone in multi-milestone mode
- All 28 workflow files updated for milestone-aware paths
- Zero behavioral change for single-milestone projects (legacy mode)

### Fixed
- Update checker clears both cache paths to prevent stale version notifications
Expand Down
19 changes: 18 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -474,6 +474,7 @@ You're never locked in. The system adapts.
| `/gsd:audit-milestone` | Verify milestone achieved its definition of done |
| `/gsd:complete-milestone` | Archive milestone, tag release |
| `/gsd:new-milestone [name]` | Start next version: questions → research → requirements → roadmap |
| `/gsd:switch-milestone <name>` | Switch active milestone for concurrent work |

### Navigation

Expand Down Expand Up @@ -512,15 +513,31 @@ You're never locked in. The system adapts.
| Command | What it does |
|---------|--------------|
| `/gsd:settings` | Configure model profile and workflow agents |
| `/gsd:set-profile <profile>` | Switch model profile (quality/balanced/budget) |
| `/gsd:set-profile <profile>` | Switch model profile (quality/balanced/budget/adaptive) |
| `/gsd:report-bug [desc]` | Report bug with severity tracking and GitHub issue creation |
| `/gsd:add-todo [desc]` | Capture idea for later |
| `/gsd:check-todos` | List pending todos |
| `/gsd:debug [desc]` | Systematic debugging with persistent state |
| `/gsd:add-tests <N> [instructions]` | Generate unit and E2E tests for completed phase |
| `/gsd:quick [--full]` | Execute ad-hoc task with GSD guarantees (`--full` adds plan-checking and verification) |
| `/gsd:health [--repair]` | Validate `.planning/` directory integrity, auto-repair with `--repair` |

<sup>¹ Contributed by reddit user OracleGreyBeard</sup>

### Concurrent Milestones

Work on multiple milestones simultaneously — e.g., v2.0 features + v1.5.1 hotfix:

```
/gsd:new-milestone "v1.5.1 Hotfix" # Creates milestone-scoped directory
/gsd:switch-milestone v2.0-features # Switch back to feature work
/gsd:progress # See status of active milestone
```

Each milestone gets isolated state: `STATE.md`, `ROADMAP.md`, `REQUIREMENTS.md`, `phases/` — all scoped under `.planning/milestones/<name>/`. Switch freely without losing progress.

When no second milestone exists, everything stays in `.planning/` as usual (zero behavioral change).

---

## Configuration
Expand Down
10 changes: 10 additions & 0 deletions bin/install.js
Original file line number Diff line number Diff line change
Expand Up @@ -1743,6 +1743,16 @@ function writeManifest(configDir, runtime = 'claude') {
}
}
}
if (!isCodex) {
const hooksDir = path.join(configDir, 'hooks');
const gsdHooks = ['gsd-statusline.js', 'gsd-check-update.js', 'gsd-context-monitor.js'];
for (const hook of gsdHooks) {
const hookPath = path.join(hooksDir, hook);
if (fs.existsSync(hookPath)) {
manifest.files['hooks/' + hook] = fileHash(hookPath);
}
}
}

fs.writeFileSync(path.join(configDir, MANIFEST_NAME), JSON.stringify(manifest, null, 2));
return manifest;
Expand Down
52 changes: 52 additions & 0 deletions commands/gsd/report-bug.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
---
name: gsd:report-bug
description: Report a bug with structured format, severity tracking, and GitHub integration
argument-hint: [optional bug description]
allowed-tools:
- Read
- Write
- Bash
- Glob
- Grep
- AskUserQuestion
---

<objective>
Report and track a bug with structured format, automatic severity classification, diagnostic log capture, and optional GitHub issue creation.

Routes to the report-bug workflow which handles:
- Directory structure creation
- Content extraction from arguments or conversation
- Severity inference from keywords
- Area inference from file paths
- Diagnostic log capture (git state, error output, log files)
- Bug file creation with frontmatter
- Git commits
- GitHub issue creation (if gh available)
- Next-action routing (investigate, plan fix, continue)
</objective>

<execution_context>
@~/.claude/get-shit-done/workflows/report-bug.md
</execution_context>

<context>
Arguments: $ARGUMENTS (optional bug description)

State is resolved in-workflow via `init bugs` and targeted reads.
</context>

<process>
**Follow the report-bug workflow** from `@~/.claude/get-shit-done/workflows/report-bug.md`.

The workflow handles all logic including:
1. Directory ensuring
2. Bug detail gathering (title, actual/expected behavior, repro steps)
3. Diagnostic log capture
4. Severity inference and confirmation
5. Area inference from file paths
6. Bug file creation with slug generation
7. Git commits
8. GitHub issue creation
9. Next-action routing
</process>
4 changes: 2 additions & 2 deletions commands/gsd/set-profile.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gsd:set-profile
description: Switch model profile for GSD agents (quality/balanced/budget)
description: Switch model profile for GSD agents (quality/balanced/budget/adaptive)
argument-hint: <profile>
allowed-tools:
- Read
Expand All @@ -12,7 +12,7 @@ allowed-tools:
Switch the model profile used by GSD agents. Controls which Claude model each agent uses, balancing quality vs token spend.

Routes to the set-profile workflow which handles:
- Argument validation (quality/balanced/budget)
- Argument validation (quality/balanced/budget/adaptive)
- Config file creation if missing
- Profile update in config.json
- Confirmation with model table display
Expand Down
30 changes: 30 additions & 0 deletions commands/gsd/switch-milestone.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
---
type: prompt
name: gsd:switch-milestone
description: Switch active milestone for concurrent work
argument-hint: <milestone-name>
allowed-tools:
- Read
- Bash
---

<objective>
Switch the active milestone to work on a different one concurrently.

Reads available milestones, warns about in-progress work on the current milestone, and updates the ACTIVE_MILESTONE pointer.
</objective>

<execution_context>
**Load these files NOW (before proceeding):**

- @~/.claude/get-shit-done/workflows/switch-milestone.md (main workflow)
</execution_context>

<context>
**User input:**
- Target milestone: {{milestone-name}}
</context>

<process>
Follow switch-milestone.md workflow end-to-end.
</process>
92 changes: 73 additions & 19 deletions docs/USER-GUIDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,7 @@ rapid prototyping phases where test infrastructure isn't the focus.
| `/gsd:audit-milestone` | Verify milestone met its definition of done | Before completing milestone |
| `/gsd:complete-milestone` | Archive milestone, tag release | All phases verified |
| `/gsd:new-milestone [name]` | Start next version cycle | After completing a milestone |
| `/gsd:switch-milestone <name>` | Switch active milestone for concurrent work | When working on multiple milestones |

### Navigation

Expand Down Expand Up @@ -197,11 +198,13 @@ rapid prototyping phases where test infrastructure isn't the focus.
|---------|---------|-------------|
| `/gsd:map-codebase` | Analyze existing codebase | Before `/gsd:new-project` on existing code |
| `/gsd:quick` | Ad-hoc task with GSD guarantees | Bug fixes, small features, config changes |
| `/gsd:report-bug [desc]` | Report bug with severity tracking and GitHub issues | When you discover a bug |
| `/gsd:debug [desc]` | Systematic debugging with persistent state | When something breaks |
| `/gsd:add-todo [desc]` | Capture an idea for later | Think of something during a session |
| `/gsd:check-todos` | List pending todos | Review captured ideas |
| `/gsd:settings` | Configure workflow toggles and model profile | Change model, toggle agents |
| `/gsd:set-profile <profile>` | Quick profile switch | Change cost/quality tradeoff |
| `/gsd:add-tests <N> [instructions]` | Generate unit and E2E tests for completed phase | After execution, before milestone completion |
| `/gsd:reapply-patches` | Restore local modifications after update | After `/gsd:update` if you had local edits |

---
Expand Down Expand Up @@ -241,7 +244,7 @@ GSD stores project settings in `.planning/config.json`. Configure during `/gsd:n
|---------|---------|---------|------------------|
| `mode` | `interactive`, `yolo` | `interactive` | `yolo` auto-approves decisions; `interactive` confirms at each step |
| `depth` | `quick`, `standard`, `comprehensive` | `standard` | Planning thoroughness: 3-5, 5-8, or 8-12 phases |
| `model_profile` | `quality`, `balanced`, `budget` | `balanced` | Model tier for each agent (see table below) |
| `model_profile` | `quality`, `balanced`, `budget`, `adaptive` | `balanced` | Model tier for each agent (see table below). `adaptive` auto-selects per-plan based on complexity. |

### Planning Settings

Expand Down Expand Up @@ -283,24 +286,27 @@ Disable these to speed up phases in familiar domains or when conserving tokens.

### Model Profiles (Per-Agent Breakdown)

| Agent | `quality` | `balanced` | `budget` |
|-------|-----------|------------|----------|
| gsd-planner | Opus | Opus | Sonnet |
| gsd-roadmapper | Opus | Sonnet | Sonnet |
| gsd-executor | Opus | Sonnet | Sonnet |
| gsd-phase-researcher | Opus | Sonnet | Haiku |
| gsd-project-researcher | Opus | Sonnet | Haiku |
| gsd-research-synthesizer | Sonnet | Sonnet | Haiku |
| gsd-debugger | Opus | Sonnet | Sonnet |
| gsd-codebase-mapper | Sonnet | Haiku | Haiku |
| gsd-verifier | Sonnet | Sonnet | Haiku |
| gsd-plan-checker | Sonnet | Sonnet | Haiku |
| gsd-integration-checker | Sonnet | Sonnet | Haiku |
| Agent | `quality` | `balanced` | `budget` | `adaptive` |
|-------|-----------|------------|----------|------------|
| gsd-planner | Opus | Opus | Sonnet | Sonnet→Opus |
| gsd-roadmapper | Opus | Sonnet | Sonnet | Sonnet→Opus |
| gsd-executor | Opus | Sonnet | Sonnet | Haiku→Sonnet |
| gsd-phase-researcher | Opus | Sonnet | Haiku | Haiku→Opus |
| gsd-project-researcher | Opus | Sonnet | Haiku | Haiku→Opus |
| gsd-research-synthesizer | Sonnet | Sonnet | Haiku | Haiku→Sonnet |
| gsd-debugger | Opus | Sonnet | Sonnet | Sonnet→Opus |
| gsd-codebase-mapper | Sonnet | Haiku | Haiku | Haiku→Sonnet |
| gsd-verifier | Sonnet | Sonnet | Haiku | Haiku→Sonnet |
| gsd-plan-checker | Sonnet | Sonnet | Haiku | Haiku→Sonnet |
| gsd-integration-checker | Sonnet | Sonnet | Haiku | Haiku→Sonnet |

*Adaptive column: range from simple→complex tier. Actual model depends on per-plan complexity scoring.*

**Profile philosophy:**
- **quality** -- Opus for all decision-making agents, Sonnet for read-only verification. Use when quota is available and the work is critical.
- **balanced** -- Opus only for planning (where architecture decisions happen), Sonnet for everything else. The default for good reason.
- **budget** -- Sonnet for anything that writes code, Haiku for research and verification. Use for high-volume work or less critical phases.
- **adaptive** -- Auto-selects per-plan based on complexity scoring. Simple plans get Haiku/Sonnet, complex plans get Opus. Best cost-quality tradeoff for mixed-complexity milestones.

---

Expand Down Expand Up @@ -380,6 +386,38 @@ claude --dangerously-skip-permissions
/gsd:remove-phase 7 # Descope phase 7 and renumber
```

### Concurrent Milestones

Work on multiple milestones simultaneously (e.g., v2.0 features + v1.5.1 hotfix):

```
/gsd:new-milestone "v1.5.1 Hotfix" # Creates milestone-scoped directory
/gsd:switch-milestone v2.0-features # Switch back to feature work
/gsd:progress # See status of active milestone
```

Each milestone gets isolated state under `.planning/milestones/<name>/`:

```
.planning/
├── PROJECT.md # Global (shared)
├── MILESTONES.md # Global (shared)
├── ACTIVE_MILESTONE # Pointer: "v2.0"
├── milestones/
│ ├── v2.0/
│ │ ├── STATE.md
│ │ ├── ROADMAP.md
│ │ ├── REQUIREMENTS.md
│ │ ├── config.json
│ │ └── phases/
│ └── v1.5.1-hotfix/
│ ├── STATE.md
│ ├── ROADMAP.md
│ └── phases/
```

When no second milestone exists, everything stays in `.planning/` as usual.

---

## Troubleshooting
Expand Down Expand Up @@ -449,23 +487,39 @@ For reference, here is what GSD creates in your project:
```
.planning/
PROJECT.md # Project vision and context (always loaded)
REQUIREMENTS.md # Scoped v1/v2 requirements with IDs
ROADMAP.md # Phase breakdown with status tracking
STATE.md # Decisions, blockers, session memory
config.json # Workflow configuration
MILESTONES.md # Completed milestone archive
MILESTONES.md # Completed milestone archive (global, shared)
ACTIVE_MILESTONE # Active milestone pointer (multi-milestone mode only)
research/ # Domain research from /gsd:new-project
todos/
pending/ # Captured ideas awaiting work
done/ # Completed todos
debug/ # Active debug sessions
resolved/ # Archived debug sessions
codebase/ # Brownfield codebase mapping (from /gsd:map-codebase)

# Single-milestone layout (default):
REQUIREMENTS.md # Scoped v1/v2 requirements with IDs
ROADMAP.md # Phase breakdown with status tracking
STATE.md # Decisions, blockers, session memory
config.json # Workflow configuration
phases/
XX-phase-name/
XX-YY-PLAN.md # Atomic execution plans
XX-YY-SUMMARY.md # Execution outcomes and decisions
CONTEXT.md # Your implementation preferences
RESEARCH.md # Ecosystem research findings
VERIFICATION.md # Post-execution verification results

# Multi-milestone layout (when concurrent milestones exist):
milestones/
v2.0/
STATE.md
ROADMAP.md
REQUIREMENTS.md
config.json
phases/
v1.5.1-hotfix/
STATE.md
ROADMAP.md
phases/
```
Loading