diff --git a/.planning/ROADMAP.md b/.planning/ROADMAP.md index 5b5d4f3..a6aa606 100644 --- a/.planning/ROADMAP.md +++ b/.planning/ROADMAP.md @@ -8,55 +8,48 @@ Multi-agent orchestration system built in six phases: foundation infrastructure, None +## Milestones + +- ✅ **v1.0 Core System** - Phases 1-6 (shipped 2026-01-30) +- 🚧 **v1.1 Test Infrastructure** - Phases 7-9 (in progress) + ## Phases **Phase Numbering:** - Integer phases (1, 2, 3): Planned milestone work - Decimal phases (2.1, 2.2): Urgent insertions (marked with INSERTED) -- [x] **Phase 1: Core Infrastructure** - CLI binary, server mode, process lifecycle, graceful shutdown -- [x] **Phase 1.1: Hexagonal Architecture** (INSERTED) - Tests, events, ports/adapters, tRPC -- [x] **Phase 2: Data Layer** - SQLite database with task hierarchy schema -- [x] **Phase 3: Git Integration** - Worktree isolation per agent with proper lifecycle -- [x] **Phase 4: Agent Lifecycle** - Spawn, stop, list agents with session persistence -- [x] **Phase 5: Task Dispatch** - Task visibility, dependency dispatch, work queue -- [x] **Phase 6: Coordination** - Merge agent outputs, handle conflicts - -## Phase Details +
+✅ v1.0 Core System (Phases 1-6) - SHIPPED 2026-01-30 ### Phase 1: Core Infrastructure **Goal**: CLI binary (`cw`) with server mode, process management, graceful shutdown, and logging **Depends on**: Nothing (first phase) **Requirements**: INFRA-01, INFRA-02, INFRA-03, INFRA-04, INFRA-05 **Research**: Unlikely (Node.js process patterns well-documented) -**Plans**: 5 plans in 3 waves +**Plans**: 5 plans Plans: -- [x] 01-01: Project Foundation (Wave 1) -- [x] 01-02: CLI Entry Point (Wave 2) -- [x] 01-03: Process Management (Wave 2) -- [x] 01-04: Logging Infrastructure (Wave 2) -- [x] 01-05: Coordination Server & Shutdown (Wave 3) +- [x] 01-01: Project Foundation +- [x] 01-02: CLI Entry Point +- [x] 01-03: Process Management +- [x] 01-04: Logging Infrastructure +- [x] 01-05: Coordination Server & Shutdown ### Phase 1.1: Hexagonal Architecture (INSERTED) **Goal**: Retrofit Phase 1 with hexagonal architecture, event-based inter-module communication, unit/integration tests, and tRPC for client communication **Depends on**: Phase 1 **Requirements**: None (architectural refactor) **Research**: Unlikely (patterns well-documented) -**Plans**: 6 plans in 3 waves +**Plans**: 6 plans Plans: -- [x] 01.1-01: Event Bus Foundation (Wave 1) -- [x] 01.1-02: tRPC Foundation (Wave 1) -- [x] 01.1-03: Process Module Tests + Events (Wave 2) -- [x] 01.1-04: Logging Module Tests + Events (Wave 2) -- [x] 01.1-05: Server Module Tests + Events (Wave 2) -- [x] 01.1-06: CLI tRPC Integration (Wave 3) - -**Scope:** -- Unit + integration tests for existing Phase 1 code -- Event bus for inter-module communication (extensible, swappable for external systems) -- tRPC router for server-to-client communication (CLI, future WebUI) +- [x] 01.1-01: Event Bus Foundation +- [x] 01.1-02: tRPC Foundation +- [x] 01.1-03: Process Module Tests + Events +- [x] 01.1-04: Logging Module Tests + Events +- [x] 01.1-05: Server Module Tests + Events +- [x] 01.1-06: CLI tRPC Integration ### Phase 2: Data Layer **Goal**: SQLite database with Drizzle ORM, task hierarchy schema (initiative → phase → plan → task) @@ -66,19 +59,19 @@ Plans: **Plans**: 2 plans Plans: -- [x] 02-01: SQLite Database Setup (Wave 1) -- [x] 02-02: Repository Layer (Wave 2) +- [x] 02-01: SQLite Database Setup +- [x] 02-02: Repository Layer ### Phase 3: Git Integration **Goal**: Git worktree management — create isolated worktrees per agent, preview diffs, integrate changes, cleanup **Depends on**: Phase 2 **Requirements**: GIT-01, GIT-02, GIT-03, GIT-04 **Research**: Unlikely (Git worktree well-documented) -**Plans**: TBD +**Plans**: 2 plans Plans: -- [x] 03-01: Git Events & WorktreeManager Port (Wave 1) -- [x] 03-02: WorktreeManager Adapter (Wave 2) +- [x] 03-01: Git Events & WorktreeManager Port +- [x] 03-02: WorktreeManager Adapter ### Phase 4: Agent Lifecycle **Goal**: Spawn, stop, list Claude Code agents with session persistence and background mode @@ -86,55 +79,95 @@ Plans: **Requirements**: AGENT-01, AGENT-02, AGENT-03, AGENT-04, AGENT-05, AGENT-07 **Research**: Likely (MCP protocol / Claude Code CLI integration needs validation) **Research topics**: Claude Code CLI -p flag behavior, JSON output schema, STDIO MCP transport, process tree management with execa -**Plans**: TBD +**Plans**: 4 plans Plans: -- [x] 04-01: Agent Schema & Repository (Wave 1) -- [x] 04-02: AgentManager Port & Events (Wave 1) -- [x] 04-03: AgentManager Adapter (Wave 2) -- [x] 04-04: tRPC Integration & CLI Commands (Wave 3) +- [x] 04-01: Agent Schema & Repository +- [x] 04-02: AgentManager Port & Events +- [x] 04-03: AgentManager Adapter +- [x] 04-04: tRPC Integration & CLI Commands ### Phase 5: Task Dispatch **Goal**: Task status visibility, dependency-ordered dispatch, work queue, agent message queue **Depends on**: Phase 4 **Requirements**: AGENT-06, TASK-01, TASK-04, TASK-05 **Research**: Unlikely (standard queue patterns) -**Plans**: 5 plans in 3 waves +**Plans**: 5 plans Plans: -- [x] 05-01: Message Schema & Repository (Wave 1) -- [x] 05-02: Task tRPC & CLI (Wave 1) -- [x] 05-03: Dispatch Port & Events (Wave 1) -- [x] 05-04: Dispatch Adapter (Wave 2) -- [x] 05-05: Message & Dispatch CLI (Wave 3) +- [x] 05-01: Message Schema & Repository +- [x] 05-02: Task tRPC & CLI +- [x] 05-03: Dispatch Port & Events +- [x] 05-04: Dispatch Adapter +- [x] 05-05: Message & Dispatch CLI ### Phase 6: Coordination **Goal**: Merge agent outputs into integration branch in dependency order, bounce conflicts back to agents **Depends on**: Phase 5 **Requirements**: COORD-01, COORD-02 -**Research**: Unlikely (programmatic coordination - gastown reference shows merge orchestration is code, not agent loop) -**Plans**: 3 plans in 3 waves +**Research**: Unlikely (programmatic coordination) +**Plans**: 3 plans Plans: -- [x] 06-01: Coordination Events & Port (Wave 1) -- [x] 06-02: CoordinationManager Adapter (Wave 2) -- [x] 06-03: tRPC & CLI Integration (Wave 3) +- [x] 06-01: Coordination Events & Port +- [x] 06-02: CoordinationManager Adapter +- [x] 06-03: tRPC & CLI Integration + +
+ +### 🚧 v1.1 Test Infrastructure (In Progress) + +**Milestone Goal:** E2E test coverage with mocked agents proving all dispatch/coordination scenarios work end-to-end + +#### Phase 7: Mock Agent & Test Harness + +**Goal**: Mock agent adapter with configurable scenarios + test harness foundation with DB-seeded fixtures +**Depends on**: v1.0 complete +**Research**: Unlikely (internal test patterns, vitest already in codebase) +**Plans**: TBD + +Plans: +- [ ] 07-01: TBD (run /gsd:plan-phase 7 to break down) + +#### Phase 8: E2E Scenario Tests + +**Goal**: Happy path tests (basic flow, dependencies, merging) + edge case tests (conflicts, interrupts, token limits) +**Depends on**: Phase 7 +**Research**: Unlikely (testing existing functionality) +**Plans**: TBD + +Plans: +- [ ] 08-01: TBD (run /gsd:plan-phase 8 to break down) + +#### Phase 9: Extended Scenarios & CI + +**Goal**: Additional scenario coverage + CI pipeline integration for automated test runs +**Depends on**: Phase 8 +**Research**: Unlikely (standard CI patterns) +**Plans**: TBD + +Plans: +- [ ] 09-01: TBD (run /gsd:plan-phase 9 to break down) ## Progress **Execution Order:** -Phases execute in numeric order: 1 → 1.1 → 2 → 3 → 4 → 5 → 6 +Phases execute in numeric order: 1 → 1.1 → 2 → 3 → 4 → 5 → 6 → 7 → 8 → 9 -| Phase | Plans Complete | Status | Completed | -|-------|----------------|--------|-----------| -| 1. Core Infrastructure | 5/5 | Complete | 2026-01-30 | -| 1.1. Hexagonal Architecture | 6/6 | Complete | 2026-01-30 | -| 2. Data Layer | 2/2 | Complete | 2026-01-30 | -| 3. Git Integration | 2/2 | Complete | 2026-01-30 | -| 4. Agent Lifecycle | 4/4 | Complete | 2026-01-30 | -| 5. Task Dispatch | 5/5 | Complete | 2026-01-30 | -| 6. Coordination | 3/3 | Complete | 2026-01-30 | +| Phase | Milestone | Plans Complete | Status | Completed | +|-------|-----------|----------------|--------|-----------| +| 1. Core Infrastructure | v1.0 | 5/5 | Complete | 2026-01-30 | +| 1.1. Hexagonal Architecture | v1.0 | 6/6 | Complete | 2026-01-30 | +| 2. Data Layer | v1.0 | 2/2 | Complete | 2026-01-30 | +| 3. Git Integration | v1.0 | 2/2 | Complete | 2026-01-30 | +| 4. Agent Lifecycle | v1.0 | 4/4 | Complete | 2026-01-30 | +| 5. Task Dispatch | v1.0 | 5/5 | Complete | 2026-01-30 | +| 6. Coordination | v1.0 | 3/3 | Complete | 2026-01-30 | +| 7. Mock Agent & Test Harness | v1.1 | 0/? | Not started | - | +| 8. E2E Scenario Tests | v1.1 | 0/? | Not started | - | +| 9. Extended Scenarios & CI | v1.1 | 0/? | Not started | - | --- *Roadmap created: 2026-01-30* -*v1 requirements: 23 mapped across 6 phases* +*v1.0 shipped: 2026-01-30 (27 plans, 6 phases)* +*v1.1 started: 2026-01-30* diff --git a/.planning/STATE.md b/.planning/STATE.md index d18c52b..4a66139 100644 --- a/.planning/STATE.md +++ b/.planning/STATE.md @@ -5,16 +5,16 @@ See: .planning/PROJECT.md (updated 2026-01-30) **Core value:** Coordinate multiple Claude Code agents without losing track or stepping on each other. -**Current focus:** v1 Complete — All phases finished +**Current focus:** v1.1 Test Infrastructure — E2E test coverage with mocked agents ## Current Position -Phase: 6 of 6 (Coordination) -Plan: 3 of 3 in current phase -Status: Milestone complete -Last activity: 2026-01-30 — Completed 06-03-PLAN.md +Phase: 7 of 9 (Mock Agent & Test Harness) +Plan: Not started +Status: Ready to plan +Last activity: 2026-01-30 — Milestone v1.1 created -Progress: ██████████ 100% +Progress: ░░░░░░░░░░ 0% ## Performance Metrics @@ -23,7 +23,7 @@ Progress: ██████████ 100% - Average duration: 3 min - Total execution time: 84 min -**By Phase:** +**By Phase (v1.0):** | Phase | Plans | Total | Avg/Plan | |-------|-------|-------|----------| @@ -108,6 +108,7 @@ None yet. - Phase 1.1 inserted after Phase 1: Hexagonal architecture with events, tests, and tRPC (URGENT) - Retrofits Phase 1 code before continuing to Phase 2 - Establishes architectural foundation for rest of project +- Milestone v1.1 created: Test infrastructure, 3 phases (Phase 7-9) ### Blockers/Concerns @@ -116,5 +117,5 @@ None yet. ## Session Continuity Last session: 2026-01-30 -Stopped at: v1 milestone complete — All 27 plans executed +Stopped at: Milestone v1.1 initialization Resume file: None