Fleet enhancer role + two-agent floor (closes#614)
Implements Jason's north-star (docs/fleet/north-star.md, #613): every fleet has a two-agent floor — orchestrator + enhancer minimum. Builds directly on my #612 init-R5 work.
Changes
Presets (general, coding, research, hybrid): add enhancer — claude, class: enhancer, persistent_persona: true — as a core always-on agent alongside the orchestrator. minimal/local-canary unchanged.
fleet.ts:
countEnhancers helper.
init guarantee extended: non-minimal profiles must yield exactly 1 orchestrator AND ≥1 enhancer (hard-fail otherwise — a corrupted preset can't write a malformed fleet).
removeAgentFromRoster refuses to drop the sole enhancer (symmetric with the existing sole-orchestrator guard), so the floor holds at runtime, not just at init.
framework/fleet/roles/enhancer.md — the enhancer mandate: monitor → analyze → plan remediation → upgrade tools/skills/harness with the orchestrator → file Mosaic Stack bug reports. Boundaries: does NOT code or review.
This is stacked on #612 (feat/fleet-polish-bundle) — its init code is #612's. The branch currently carries #612's commit too. Merge order: #612 → this. After #612 merges (squash), I'll rebase this onto main (the dup #612 work drops) so the final diff is enhancer-only. Ping me to rebase, or retarget on merge.
## Fleet enhancer role + two-agent floor (closes #614)
Implements Jason's north-star (`docs/fleet/north-star.md`, #613): every fleet has a **two-agent floor** — orchestrator + **enhancer** minimum. Builds directly on my #612 init-R5 work.
### Changes
- **Presets** (general, coding, research, hybrid): add `enhancer` — claude, `class: enhancer`, `persistent_persona: true` — as a **core always-on** agent alongside the orchestrator. `minimal`/`local-canary` unchanged.
- **`fleet.ts`**:
- `countEnhancers` helper.
- **init guarantee extended**: non-minimal profiles must yield **exactly 1 orchestrator AND ≥1 enhancer** (hard-fail otherwise — a corrupted preset can't write a malformed fleet).
- **`removeAgentFromRoster` refuses to drop the sole enhancer** (symmetric with the existing sole-orchestrator guard), so the floor holds at runtime, not just at init.
- **`framework/fleet/roles/enhancer.md`** — the enhancer mandate: monitor → analyze → plan remediation → upgrade tools/skills/harness **with the orchestrator** → file Mosaic Stack bug reports. Boundaries: **does NOT code or review**.
### Verification
- **155 fleet tests** green. New: `countEnhancers`; sole-enhancer remove guard; remove-allows-when-another; init two-agent-floor; every-non-minimal-preset-has-enhancer; updated preset-roster assertions. tsc/eslint/prettier/**sanitize** clean. TDD on the init guarantee + remove protection.
### Stacking (for the batch)
This is **stacked on #612** (`feat/fleet-polish-bundle`) — its init code is #612's. The branch currently carries #612's commit too. **Merge order: #612 → this.** After #612 merges (squash), I'll rebase this onto `main` (the dup #612 work drops) so the final diff is enhancer-only. Ping me to rebase, or retarget on merge.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Codex symmetry-gap finding. Three fixes completing add/remove boot-survival
symmetry:
1. disable-on-remove (BUG, TDD): fleet remove stopped + deleted roster/env/
heartbeat but never disabled the systemd unit, so a removed-but-enabled
[email protected] could resurrect on reboot pointing at deleted
config. Add buildSystemdDisableCommand + disable in remove (best-effort,
gated on !--keep-files).
2. add-enable: fleet add now enables the new agent's unit for boot-survival
(best-effort, independent of --start).
3. init-R5 guarantee: fleet init --write now fails hard when a non-minimal
profile lacks exactly one orchestrator (was a soft warning); the sanctioned
no-orchestrator 'minimal' preset is still allowed.
Verified: 4 new tests (disable builder; remove-invokes-disable; add-invokes-
enable; init general → exactly 1 orchestrator) + 147 existing fleet tests green
(151 total); tsc/eslint/prettier clean.
Refs #611
Co-Authored-By: Claude Opus 4.8 <[email protected]>
Claude-Session: https://claude.ai/code/session_01EsgTQzV5YUGk1JtCLP4B83
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Fleet enhancer role + two-agent floor (closes #614)
Implements Jason's north-star (
docs/fleet/north-star.md, #613): every fleet has a two-agent floor — orchestrator + enhancer minimum. Builds directly on my #612 init-R5 work.Changes
enhancer— claude,class: enhancer,persistent_persona: true— as a core always-on agent alongside the orchestrator.minimal/local-canaryunchanged.fleet.ts:countEnhancershelper.removeAgentFromRosterrefuses to drop the sole enhancer (symmetric with the existing sole-orchestrator guard), so the floor holds at runtime, not just at init.framework/fleet/roles/enhancer.md— the enhancer mandate: monitor → analyze → plan remediation → upgrade tools/skills/harness with the orchestrator → file Mosaic Stack bug reports. Boundaries: does NOT code or review.Verification
countEnhancers; sole-enhancer remove guard; remove-allows-when-another; init two-agent-floor; every-non-minimal-preset-has-enhancer; updated preset-roster assertions. tsc/eslint/prettier/sanitize clean. TDD on the init guarantee + remove protection.Stacking (for the batch)
This is stacked on #612 (
feat/fleet-polish-bundle) — its init code is #612's. The branch currently carries #612's commit too. Merge order: #612 → this. After #612 merges (squash), I'll rebase this ontomain(the dup #612 work drops) so the final diff is enhancer-only. Ping me to rebase, or retarget on merge.🤖 Generated with Claude Code
f27371be7ato5e73481f0a