Skip to content

feat(cli): health --coach mode for first-week adoption walkthrough#576

Merged
NagyVikt merged 2 commits into
mainfrom
worktree-agent-ae0769b7eaa32332e
May 15, 2026
Merged

feat(cli): health --coach mode for first-week adoption walkthrough#576
NagyVikt merged 2 commits into
mainfrom
worktree-agent-ae0769b7eaa32332e

Conversation

@NagyVikt
Copy link
Copy Markdown
Collaborator

Summary

Adds `colony health --coach` — a first-week walkthrough that detects new vs returning repos and surfaces the NEXT habit to adopt. Step completion is event-observed, never user-clicked.

  • Stage detection: `fresh` / `installed_no_signal` / `early` / `mid_adoption`
  • 7-step ladder, each with `cmd:` and `tool:` strings:
    1. `install_runtime` — any IDE installed
    2. `first_task_post`
    3. `first_task_claim_file`
    4. `first_task_hand_off`
    5. `first_plan_claim` — closes the 0/47 gap
    6. `first_quota_release`
    7. `first_gain_review`
  • New `coach_progress` SQLite table (migration 014, schema_version 13 → 14)
  • New storage methods: `markCoachStep`, `listCoachSteps`, `firstObservationTs`, `countObservationsByKindSince`
  • Shared `installed-ides` helper between `status` and `health-coach`
  • `colony gain` emits a `coach_gain_review` observation so step 7 self-detects
  • `--coach` mutex with `--fix-plan` (stderr warning, `--coach` wins), respects `--json`

Closes `⏳ Adoption coach mode in colony health that walks a new repo through first-week setup` under README §v0.x "Adoption nudges".

OpenSpec

`openspec/changes/health-coach-mode-2026-05-16/CHANGE.md`

Test plan

  • `pnpm --filter colonyq typecheck` — clean
  • `pnpm --filter colonyq test` — 293/293 pass (9 new health-coach tests)
  • `pnpm --filter @colony/storage test` — 157/157 pass
  • biome check on touched files — clean
  • Manual smoke: fresh `COLONY_HOME`, `--json` payload, `--coach --fix-plan` mutex

Merge order

Touches `packages/storage/src/storage.ts`. Recommended last — both #575 (drift detector) and this PR extend `storage.ts` independently. Whichever lands second needs a trivial rebase.

🤖 Generated with Claude Code

NagyVikt and others added 2 commits May 16, 2026 01:22
- New colony health --coach flag; mutex with --fix-plan
- 7-step ladder (install_runtime through first_gain_review)
- Stage detection: fresh / installed_no_signal / early / mid_adoption
- New coach_progress SQLite table (migration 014, schema_version 14)
- markCoachStep / listCoachSteps / firstObservationTs storage methods
- Shared installed-ides helper between status and health-coach
- colony gain emits coach_gain_review observation for step 7 detection

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@NagyVikt NagyVikt merged commit 53836ff into main May 15, 2026
1 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant