Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions docs/adr/0009-apple-platform-consolidation.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,5 +60,5 @@ Implementation status as of 2026-06:
capability tables, and any watchOS unsupported sentinel. watchOS remains out of scope for the current
consolidation.

This ADR owns the architectural decision; implementation progress for the remaining platform-plugin work lives
in `plans/phase3-platform-plugin-progress.md`.
This ADR owns the architectural decision; implementation progress for the remaining platform-plugin work is
tracked in GitHub issues under the Phase 3 umbrella (#972).
6 changes: 3 additions & 3 deletions plans/perfect-shape.md
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ but "add a platform" still touches the `device.ts` union line.
already builds `ios|macos|tvos` and ~85% of `platforms/ios` is already the OS-agnostic Apple engine, so this is
mostly relocate-and-rename for iOS/iPadOS/tvOS/macOS; visionOS is scoped net-new work and watchOS is an
explicit unsupported sentinel (XCUITest can't drive it). ADR 0009 owns the AppleOS decision; remaining
implementation state is tracked in [phase3-platform-plugin-progress.md](./phase3-platform-plugin-progress.md).
implementation state is tracked in the [Phase 3 tracking issue #972](https://github.com/callstack/agent-device/issues/972).

### 5.2 `CommandDescriptor` (the command axis) — *facet composition*, honoring ADR 0003

Expand Down Expand Up @@ -398,7 +398,7 @@ a step can't ship alone, the plan has failed.
| **0 · confidence builders** (behaviorless) | **(b) ✅ shipped** — exhaustive capability platform selection; **(c) ✅ shipped** — generic `RecordingBackend<P>` (5 casts deleted); (a) parse-at-boundary on MCP/HTTP edge; (d) collapse the 3 platform allow-lists + 5-layer batch validation | low | correctness/security; builds muscle memory; touches no identity table |
| **1 · command spine** | (a) **invert the import graph** — `commandRegistry` becomes root, `command-catalog`/`capabilities`/`daemon-registry`/`batch-policy` derive (parity-tested, no deletion yet); (b) promote each family's facet → `CommandDescriptor` additively; (c) replace the 24-arm switch with the total map, arm-by-arm | **med** (the import-cycle inversion is the real first-week blocker: `command-catalog` has ~95 importers and the facet imports `AgentDeviceClient` today) | finishes a proven seam; add-command → ~2 files; enables everything below |
| **2 · typed results** (the parity oracle) | (a) `CommandResultMap` with `Record` default, migrate per-command from real runner payloads; (b) graft `TypedError`; fold the disowned 'generic' family into `handlers/` **last**; (c) kill the `client-types.ts` mirror (~550 LOC) | med (must be per-command, never a big-bang retype of 203 files) | the safety net the platform unwind needs; biggest single LOC win |
| **3 · platform plugin** (now safe) | (a) define `PlatformPlugin`, **lazy** factories (cold-start benchmark guards latency); (b) move capability columns onto plugin grants, **porting every `supports()` closure verbatim**, pinned by the table-equivalence test before deletion; (c) ✅ unwind macOS and the OS-agnostic Apple engine out of `platforms/ios`; (d) finish Apple plugin facets, tvOS leaf, final `Platform` collapse, and watchOS sentinel last. The **Apple plugin is the first instance** and owns the `AppleOS` leaves — see ADR 0009 and [phase3-platform-plugin-progress.md](./phase3-platform-plugin-progress.md) | **high** (touches shared platform routing and the XCTest runner) | add-platform wiring → ~3 files; kills the 231-branch smear |
| **3 · platform plugin** (now safe) | (a) define `PlatformPlugin`, **lazy** factories (cold-start benchmark guards latency); (b) move capability columns onto plugin grants, **porting every `supports()` closure verbatim**, pinned by the table-equivalence test before deletion; (c) ✅ unwind macOS and the OS-agnostic Apple engine out of `platforms/ios`; (d) finish Apple plugin facets, tvOS leaf, final `Platform` collapse, and watchOS sentinel last. The **Apple plugin is the first instance** and owns the `AppleOS` leaves — see ADR 0009 and the [Phase 3 tracking issue #972](https://github.com/callstack/agent-device/issues/972) | **high** (touches shared platform routing and the XCTest runner) | add-platform wiring → ~3 files; kills the 231-branch smear |
| **4 · agent-cost** (opt-in) | (a) `ResponseView.toView` with `default`==today; `responseLevel` knob defaulting to `default`; (b) typed `BatchStepResult` → intermediate steps digest; per-command MCP `outputSchema`; generalize zero-load fast-paths | med (wire-shape risk vs Maestro — strictly opt-in) | the north-star-#2 token/latency wins |
| **5 · layering + legacy** (quiet windows) | intent-folder moves + utils extraction as pure path codemods; at next major drop the ~175 LOC of legacy aliases/barrels | low-per-step, high-diff | scoped ownership + import lint; merge-pain risk → land fast, small |

Expand Down Expand Up @@ -433,7 +433,7 @@ grants; bundling the folder reorg with the registry work (maximizes diff-noise a
## 8. Before / after — the command axis

(The platform-axis decision lives in ADR 0009; current implementation status lives in
[phase3-platform-plugin-progress.md](./phase3-platform-plugin-progress.md).)
the [Phase 3 tracking issue #972](https://github.com/callstack/agent-device/issues/972).)

```
BEFORE — a command's identity is RESTATED in ~10 hand-synced tables, aligned "by convention"
Expand Down
152 changes: 0 additions & 152 deletions plans/phase3-platform-plugin-progress.md

This file was deleted.

2 changes: 1 addition & 1 deletion src/core/platform-plugin/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import type { CapabilityBucket } from '../platform-descriptor/types.ts';
* (`providers` / `recording` / `appLog` / `perf`) are NOT declared here — they
* arrive in step (b), typed against PLATFORM-NEUTRAL, daemon-owned wrappers
* (not the iOS-simulator-shaped provider seam). See
* plans/phase3-platform-plugin-progress.md.
* docs/adr/0009-apple-platform-consolidation.md (tracked in issue #974).
*/
export type PlatformPlugin = {
/** Plugin/family id; also the capability-matrix bucket key for its platforms. */
Expand Down
Loading