|
1 | | -# add-cli-shell-product runtime progress |
| 1 | +# add-cli-shell-app runtime progress |
2 | 2 |
|
3 | 3 | ## Objective facts |
4 | 4 |
|
|
15 | 15 |
|
16 | 16 | ## Remaining platform gaps |
17 | 17 |
|
18 | | -- `cli-shell` does not yet consume product attention and product delegation APIs in product code. |
| 18 | +- `cli-shell` does not yet consume app attention and app delegation APIs in app code. |
19 | 19 | - Managed/takeover state is not yet projected from platform truth on reconnect. |
20 | | -- Managed/takeover enable/disable does not yet commit hosting attention or create/revoke product delegations. |
| 20 | +- Managed/takeover enable/disable does not yet commit hosting attention or create/revoke app delegations. |
21 | 21 | - Real daemon integration coverage for repeated attach / `@default` / `--session=2` is still missing. |
22 | 22 | - TUI group is not started yet. |
23 | 23 |
|
24 | 24 | ## Evidence and blockers |
25 | 25 |
|
26 | 26 | - Current targeted `cli-shell` and launcher tests are green. |
27 | | -- `openspec validate add-cli-shell-product --strict` is green. |
| 27 | +- `openspec validate add-cli-shell-app --strict` is green. |
28 | 28 | - Package-level `bunx tsc --noEmit -p packages/cli/tsconfig.json` is still blocked by pre-existing drift in `packages/tui/src/run-tui.tsx` (`ChatMessageRole` includes `system` while the local consumer expects only `user | assistant`). |
29 | 29 |
|
30 | 30 | ## Runtime tensions observed during managed/integration closure |
31 | 31 |
|
32 | 32 | - Real daemon room grants keep the bootstrap superadmin membership alongside the summoned Avatar grants. The durable contract for cli-shell is "selected Avatar grants are ensured", not "the room contains only cli-shell avatars". |
33 | 33 | - Global terminal and room catalog order is not a stable contract. Integration assertions should sort by durable keys (`terminalId`, `metadata.resourceKey`) instead of assuming creation order. |
34 | | -- The cli-shell package boundary stayed clean during managed-mode implementation: product code consumed `@agenter/client-sdk` and `@agenter/product-extension-runtime` only. The remaining cross-package typecheck blocker lives in pre-existing `packages/tui/src/run-tui.tsx`, which should not be misattributed to cli-shell runtime work. |
| 34 | +- The cli-shell package boundary stayed clean during managed-mode implementation: app code consumed `@agenter/client-sdk` and `@agenter/app-runtime` only. The remaining cross-package typecheck blocker lives in pre-existing `packages/tui/src/run-tui.tsx`, which should not be misattributed to cli-shell runtime work. |
35 | 35 |
|
36 | 36 | ## TUI substrate notes |
37 | 37 |
|
38 | | -- The collapsed shell-terminal TUI can stay product-orthogonal by reading only runtime-store projections: `focusedTerminalId`, `terminalSnapshots`, `heartbeatGroups`, and `unreadBySession`. No `@agenter/tui` dashboard/session-list reuse is needed. |
| 38 | +- The collapsed shell-terminal TUI can stay app-orthogonal by reading only runtime-store projections: `focusedTerminalId`, `terminalSnapshots`, `heartbeatGroups`, and `unreadBySession`. No `@agenter/tui` dashboard/session-list reuse is needed. |
39 | 39 | - This workspace needed an explicit `bun install` before `@opentui/core` and `@opentui/react` became resolvable in `packages/cli-shell`. The package declarations were correct, but the local install state was missing. |
40 | | -- `@opentui/react/test-utils` currently leaves a React `act(...)` warning on renderer teardown even though the collapsed TUI assertions pass. This is test-harness noise, not a product-contract failure, and should not be confused with a cli-shell runtime regression. |
| 40 | +- `@opentui/react/test-utils` currently leaves a React `act(...)` warning on renderer teardown even though the collapsed TUI assertions pass. This is test-harness noise, not a app-contract failure, and should not be confused with a cli-shell runtime regression. |
41 | 41 |
|
42 | 42 | ## Next steps |
43 | 43 |
|
44 | | -1. Add product-side managed runtime helpers around hosting attention and product delegation. |
| 44 | +1. Add app-side managed runtime helpers around hosting attention and app delegation. |
45 | 45 | 2. Add real daemon integration tests for repeated attach / avatar override / session isolation. |
46 | 46 | 3. Use those helpers as the substrate for the bottom-only TUI instead of inventing local managed state. |
47 | 47 |
|
48 | 48 | ## Interactive TUI closure facts |
49 | 49 |
|
50 | | -- The interactive TUI now routes product interaction through a controller layer instead of a renderer-heavy test harness. This was necessary because the Bun + OpenTUI test renderer teardown kept producing unstable behavior unrelated to cli-shell product contracts. |
| 50 | +- The interactive TUI now routes app interaction through a controller layer instead of a renderer-heavy test harness. This was necessary because the Bun + OpenTUI test renderer teardown kept producing unstable behavior unrelated to cli-shell app contracts. |
51 | 51 | - The cli-shell frame now renders as a styled cell grid, including gray user-message rows and gray focused input rows, while preserving deterministic column accounting for CJK and emoji glyphs. |
52 | 52 | - Focused TUI tests now cover: |
53 | 53 | - toolbar status / heartbeat summaries |
|
60 | 60 |
|
61 | 61 | ## Remaining gap after TUI closure |
62 | 62 |
|
63 | | -- Task 4.21 is intentionally still open. Cli-shell now creates and projects product delegations correctly, but the remaining acceptance requirement is stronger: confirm that autonomous terminal writes in managed execution use the Avatar actor identity and preserve delegation/lease provenance in the real write path, rather than only in cli-shell's own projection state. |
| 63 | +- Task 4.21 is intentionally still open. Cli-shell now creates and projects app delegations correctly, but the remaining acceptance requirement is stronger: confirm that autonomous terminal writes in managed execution use the Avatar actor identity and preserve delegation/lease provenance in the real write path, rather than only in cli-shell's own projection state. |
64 | 64 | - Real local walkthrough (`5.5`) and long-running real AI semantic validation (`5.7`-`5.11`) remain pending after the TUI task group. |
65 | 65 |
|
66 | 66 | ## 2026-05-08 real walkthrough closure facts for 5.5 |
|
162 | 162 | - model-response cache file observation |
163 | 163 |
|
164 | 164 | - The semantic suite input path was corrected to follow durable platform law. |
165 | | - - Earlier assumption: cli-shell product room could be used as the conversational wake source. |
166 | | - - Verified correction: self-evolution chat turns must use the session primary room path, not the product room metadata room. |
| 165 | + - Earlier assumption: cli-shell app room could be used as the conversational wake source. |
| 166 | + - Verified correction: self-evolution chat turns must use the session primary room path, not the app room metadata room. |
167 | 167 | - Real fixture change: |
168 | 168 | - attach the session primary room before chat sends |
169 | 169 | - read back assistant-visible replies from the attached primary room rather than from optimistic chat-only projections |
170 | 170 |
|
171 | 171 | - Deterministic verification for the semantic suite scaffolding is green: |
172 | 172 | - `bunx tsc --noEmit -p packages/cli-shell/tsconfig.json` |
173 | 173 | - `bun test packages/cli-shell/test/cli-shell.test.ts packages/cli-shell/test/cli-shell.integration.test.ts packages/cli-shell/test/cli-shell-tui.test.tsx packages/cli-shell/test/package-boundary.test.ts packages/cli-shell/test/real-cli-shell-semantic.integration.test.ts` |
174 | | - - `openspec validate add-cli-shell-product --strict` |
| 174 | + - `openspec validate add-cli-shell-app --strict` |
175 | 175 |
|
176 | 176 | - Real-provider acceptance remains objectively blocked on this machine as of 2026-05-08: |
177 | 177 | - `glm` (`https://api.z.ai/api/anthropic`) |
|
190 | 190 |
|
191 | 191 | - Because the long-running suite cannot complete a full real semantic pass with any currently available provider on this machine: |
192 | 192 | - `5.7` and `5.8` are supportable as implemented suite capability |
193 | | - - `5.9` and `5.11` remain blocked as real acceptance tasks, not as missing cli-shell product code |
| 193 | + - `5.9` and `5.11` remain blocked as real acceptance tasks, not as missing cli-shell app code |
194 | 194 |
|
195 | 195 | ## 2026-05-08 semantic acceptance reopen and closure for 5.9 / 5.11 |
196 | 196 |
|
|
200 | 200 | - `AGENTER_REAL_AI_MODEL=deepseek-chat` |
201 | 201 | - `AGENTER_REAL_AI_VENDOR=deepseek` |
202 | 202 |
|
203 | | -- Real acceptance failures after that switch were suite/fixture law mismatches, not missing cli-shell product behavior: |
| 203 | +- Real acceptance failures after that switch were suite/fixture law mismatches, not missing cli-shell app behavior: |
204 | 204 | - room-reply wait originally used chat timestamp ordering against primary-room durable messages; real runtime ordering is not guaranteed across those two surfaces |
205 | 205 | - assistant-room detection originally required `senderActorId` only; real primary-room snapshots are more stable when `from` is also accepted as Avatar identity evidence |
206 | 206 | - model-call wait originally used recent-array length, which is not durable because the debug list is a sliding window; stable `modelCall.id` is the correct anchor |
|
212 | 212 |
|
213 | 213 | - Closure evidence on the current suite revision: |
214 | 214 | - `bunx tsc --noEmit -p packages/cli-shell/tsconfig.json` |
215 | | - - `openspec validate add-cli-shell-product --strict` |
| 215 | + - `openspec validate add-cli-shell-app --strict` |
216 | 216 | - `bun test packages/cli-shell/test/real-cli-shell-semantic.integration.test.ts --test-name-pattern "senior-led"` |
217 | 217 | - pass in ~75s |
218 | 218 | - `bun test packages/cli-shell/test/real-cli-shell-semantic.integration.test.ts --test-name-pattern "requirement-led"` |
|
223 | 223 | - These three passing real-AI traces now support `5.9`: |
224 | 224 | - `senior-led`: result-first / terse preference learned from correction and reused after compact+reconnect |
225 | 225 | - `requirement-led`: strict `result:` / `next:` format learned from evidence instead of role archetype |
226 | | - - `playful`: relaxed companion-like tone learned without turning playfulness into a product mode or breaking engineering boundaries |
| 226 | + - `playful`: relaxed companion-like tone learned without turning playfulness into a app mode or breaking engineering boundaries |
227 | 227 |
|
228 | 228 | - The same suite now supports `5.11` because each passing scenario includes the required long-script behaviors: |
229 | 229 | - many-turn terminal-adjacent exchange |
|
240 | 240 |
|
241 | 241 | ## 2026-05-08 publish-surface closure facts |
242 | 242 |
|
243 | | -- The product implementation had already closed functionally; the remaining work was npm publish-surface hardening for `agenter` and `@agenter/cli-shell`. |
| 243 | +- The app implementation had already closed functionally; the remaining work was npm publish-surface hardening for `agenter` and `@agenter/cli-shell`. |
244 | 244 |
|
245 | 245 | - The `agenter` public wrapper now avoids loading daemon/runtime chunks for pure metadata flows: |
246 | 246 | - `packages/cli/src/run-cli.ts` moved daemon/auth-service startup imports behind dynamic boundaries |
247 | | - - descriptor-launched product metadata argv (`--help`, `--version`, `help`, `version`) now skip daemon bootstrap |
248 | | - - objective effect: `agenter shell --help` no longer triggers daemon/runtime side effects just to print product help |
| 247 | + - descriptor-launched app metadata argv (`--help`, `--version`, `help`, `version`) now skip daemon bootstrap |
| 248 | + - objective effect: `agenter shell --help` no longer triggers daemon/runtime side effects just to print app help |
249 | 249 |
|
250 | 250 | - The bundled prompt/i18n asset blocker was closed without adding ad-hoc package-root file copying: |
251 | 251 | - `packages/i18n-en/src/index.ts` and `packages/i18n-zh-Hans/src/index.ts` now use bundled JSON payloads as the non-workspace fallback while preserving live `prompts/` dir loading in the workspace |
|
256 | 256 | - `packages/terminal-system/src/xterm-bridge.ts` now uses that static module boundary instead of `createRequire("@xterm/headless")` |
257 | 257 | - objective effect: `agenter` dist now carries the already-validated headless terminal implementation inside the bundle, so installed tarballs can start the daemon without missing-module failure |
258 | 258 |
|
259 | | -- The `@agenter/cli-shell` help/runtime blocker was closed in product code: |
| 259 | +- The `@agenter/cli-shell` help/runtime blocker was closed in app code: |
260 | 260 | - `packages/cli-shell/src/run-cli-shell.ts` now short-circuits metadata-only argv and lazy-loads the TUI runner only for real TTY attach flows |
261 | 261 | - `packages/cli-shell/scripts/build.ts` now enables chunk splitting so the OpenTUI platform code stays out of help/non-TTY startup |
262 | 262 | - objective effect: `agenter-cli-shell --help` and `agenter shell --help` both exit cleanly without resolving OpenTUI platform modules early |
|
0 commit comments