@timurproko/a1 0.2.7-dev.1245 → 0.2.7-dev.1252

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (342) hide show
  1. package/README.md +11 -36
  2. package/bin/cli.js +2 -17
  3. package/bin/ui.js +7 -48
  4. package/dist/app/session-shell/exit-notice.d.ts +2 -2
  5. package/dist/app/session-shell/exit-notice.js +10 -10
  6. package/dist/app/session-shell/prompt-submission.d.ts +2 -4
  7. package/dist/app/session-shell/prompt-submission.js +3 -23
  8. package/dist/app/session-shell/response-copy-transport.js +1 -2
  9. package/dist/app/session-shell/session-lifecycle.d.ts +1 -2
  10. package/dist/app/session-shell/session-lifecycle.js +2 -4
  11. package/dist/app/session-shell/session-shell-root.d.ts +0 -31
  12. package/dist/app/session-shell/session-shell-root.js +3 -4
  13. package/dist/app/session-shell/session-shell.js +6 -47
  14. package/dist/app/session-shell/session-viewport-controller.js +3 -6
  15. package/dist/app/session-shell/shell-host.js +2 -18
  16. package/dist/app/session-shell/transcript-document.d.ts +1 -2
  17. package/dist/app/session-shell/transcript-document.js +3 -28
  18. package/dist/app/session-shell/workflow-output.js +1 -1
  19. package/dist/app/session-shell/workflow-router.d.ts +1 -3
  20. package/dist/app/session-shell/workflow-router.js +1 -4
  21. package/dist/cli/dispatch.d.ts +1 -11
  22. package/dist/cli/dispatch.js +5 -92
  23. package/dist/cli/session-context.js +5 -7
  24. package/dist/cli/uninstall.d.ts +1 -5
  25. package/dist/cli/uninstall.js +6 -35
  26. package/dist/cli/version-stats.js +4 -7
  27. package/dist/composition/owned-settings.d.ts +0 -1
  28. package/dist/composition/owned-settings.js +0 -1
  29. package/dist/composition/owned-ui.d.ts +2 -24
  30. package/dist/composition/owned-ui.js +11 -87
  31. package/dist/composition/release-update-observation.d.ts +4 -4
  32. package/dist/composition/release-update-observation.js +17 -47
  33. package/dist/composition/session-backend.d.ts +0 -1
  34. package/dist/composition/session-runtime-registry.d.ts +3 -3
  35. package/dist/composition/settings-route-host.d.ts +0 -7
  36. package/dist/composition/settings-route-host.js +4 -10
  37. package/dist/composition/startup-route.d.ts +0 -1
  38. package/dist/composition/startup-route.js +0 -1
  39. package/dist/contracts/owned-ui/index.d.ts +1 -1
  40. package/dist/contracts/owned-ui/model.d.ts +0 -3
  41. package/dist/contracts/owned-ui/session-workflows.d.ts +1 -4
  42. package/dist/features/launch/development-launch.js +0 -1
  43. package/dist/features/launch/index.d.ts +1 -1
  44. package/dist/features/launch/intent.d.ts +1 -3
  45. package/dist/features/launch/intent.js +2 -4
  46. package/dist/features/launch/session-context.d.ts +2 -2
  47. package/dist/features/owned-ui/reference-screen-app.d.ts +0 -2
  48. package/dist/features/owned-ui/reference-screen-app.js +2 -9
  49. package/dist/features/owned-ui/settings-app.d.ts +0 -6
  50. package/dist/features/owned-ui/settings-app.js +5 -36
  51. package/dist/foundation/launch-context/index.d.ts +0 -12
  52. package/dist/foundation/launch-context/index.js +0 -26
  53. package/dist/foundation/lifecycle/claim-gate.d.ts +8 -0
  54. package/dist/foundation/lifecycle/claim-gate.js +37 -0
  55. package/dist/foundation/lifecycle/index.d.ts +5 -9
  56. package/dist/foundation/lifecycle/index.js +3 -4
  57. package/dist/foundation/lifecycle/model.d.ts +2 -59
  58. package/dist/foundation/lifecycle/model.js +0 -35
  59. package/dist/foundation/lifecycle/paths.d.ts +0 -24
  60. package/dist/foundation/lifecycle/paths.js +0 -40
  61. package/dist/foundation/lifecycle/process-liveness.d.ts +8 -0
  62. package/dist/foundation/lifecycle/process-liveness.js +18 -0
  63. package/dist/foundation/lifecycle/session-claim-lock.d.ts +1 -1
  64. package/dist/foundation/lifecycle/session-claim-lock.js +2 -2
  65. package/dist/foundation/lifecycle/session-repository-context.d.ts +6 -6
  66. package/dist/foundation/lifecycle/session-repository-context.js +2 -3
  67. package/dist/foundation/release/automatic-update.d.ts +1 -3
  68. package/dist/foundation/release/automatic-update.js +9 -30
  69. package/dist/foundation/release/bootstrap.d.ts +2 -25
  70. package/dist/foundation/release/bootstrap.js +33 -344
  71. package/dist/foundation/release/cohort-state.d.ts +21 -46
  72. package/dist/foundation/release/cohort-state.js +30 -62
  73. package/dist/foundation/release/dependency-certification.d.ts +1 -1
  74. package/dist/foundation/release/index.d.ts +10 -17
  75. package/dist/foundation/release/index.js +7 -11
  76. package/dist/foundation/release/latest-release.d.ts +1 -2
  77. package/dist/foundation/release/latest-release.js +1 -2
  78. package/dist/foundation/release/process-liveness.d.ts +2 -0
  79. package/dist/foundation/release/process-liveness.js +12 -0
  80. package/dist/foundation/release/release-gc.d.ts +12 -9
  81. package/dist/foundation/release/release-gc.js +34 -98
  82. package/dist/foundation/release/release-store.d.ts +2 -2
  83. package/dist/foundation/release/release-store.js +2 -2
  84. package/dist/foundation/release/restart-certification.js +1 -1
  85. package/dist/foundation/release/update-activation.d.ts +2 -9
  86. package/dist/foundation/release/update-activation.js +28 -43
  87. package/dist/foundation/release/update-execution-lease.js +1 -1
  88. package/dist/foundation/release/update-launch.d.ts +0 -2
  89. package/dist/foundation/release/update-launch.js +0 -7
  90. package/dist/foundation/release/update-recovery.js +1 -1
  91. package/dist/foundation/release/update-transaction.d.ts +1 -1
  92. package/dist/foundation/release/update-transaction.js +5 -2
  93. package/dist/foundation/release/update.d.ts +2 -10
  94. package/dist/foundation/release/update.js +23 -200
  95. package/dist/foundation/session-writer-lock/index.d.ts +14 -6
  96. package/dist/foundation/session-writer-lock/index.js +48 -103
  97. package/dist/foundation/startup/startup-runtime.d.ts +1 -1
  98. package/dist/foundation/terminal-cleanup/exit-notice.d.ts +6 -0
  99. package/dist/foundation/terminal-cleanup/exit-notice.js +36 -0
  100. package/dist/foundation/terminal-cleanup/index.d.ts +2 -1
  101. package/dist/foundation/terminal-cleanup/index.js +2 -1
  102. package/dist/foundation/terminal-cleanup/terminal-reset.d.ts +0 -5
  103. package/dist/foundation/terminal-cleanup/terminal-reset.js +0 -5
  104. package/dist/integrations/pi/components/index.d.ts +1 -1
  105. package/dist/integrations/pi/components/index.js +1 -1
  106. package/dist/integrations/pi/components/shell-editor-autocomplete.js +1 -4
  107. package/dist/integrations/pi/components/shell-footer-status.d.ts +1 -1
  108. package/dist/integrations/pi/components/shell-footer-status.js +2 -2
  109. package/dist/integrations/pi/components/shell-hotkey-sections.js +1 -1
  110. package/dist/integrations/pi/components/shell-presenters-info.d.ts +2 -5
  111. package/dist/integrations/pi/components/shell-presenters-info.js +4 -18
  112. package/dist/integrations/pi/components/shell-presenters-transcript.d.ts +1 -1
  113. package/dist/integrations/pi/components/shell-presenters-transcript.js +1 -1
  114. package/dist/integrations/pi/components/shell-shared-facade.d.ts +0 -2
  115. package/dist/integrations/pi/components/submitted-prompt-adapter.d.ts +2 -5
  116. package/dist/integrations/pi/components/submitted-prompt-adapter.js +2 -16
  117. package/dist/integrations/pi/components/upstream/components/session-footer.d.ts +1 -2
  118. package/dist/integrations/pi/components/upstream/components/session-footer.js +6 -8
  119. package/dist/integrations/pi/engine/adapter.d.ts +0 -1
  120. package/dist/integrations/pi/engine/adapter.js +1 -16
  121. package/dist/integrations/pi/engine/compaction-progress.js +13 -5
  122. package/dist/integrations/pi/engine/diagnostics-state.d.ts +0 -1
  123. package/dist/integrations/pi/engine/diagnostics-state.js +0 -14
  124. package/dist/integrations/pi/engine/prompt-suggestions.d.ts +0 -1
  125. package/dist/integrations/pi/engine/prompt-suggestions.js +0 -40
  126. package/dist/integrations/pi/engine/session-runtime.js +0 -2
  127. package/dist/integrations/pi/engine/workflow-runner.js +1 -1
  128. package/dist/integrations/pi/tui-runtime/adapter.d.ts +2 -2
  129. package/dist/integrations/pi/tui-runtime/adapter.js +2 -2
  130. package/dist/product-identity.d.ts +4 -6
  131. package/dist/product-identity.js +6 -11
  132. package/dist/product-identity.json +1 -40
  133. package/dist/runtime-payload-inventory.json +0 -3
  134. package/dist/ui/components/index.d.ts +2 -2
  135. package/dist/ui/components/index.js +1 -1
  136. package/dist/ui/components/submitted-prompt.d.ts +3 -13
  137. package/dist/ui/components/submitted-prompt.js +8 -41
  138. package/dist/ui/components/transcript-viewport.d.ts +1 -3
  139. package/dist/ui/components/transcript-viewport.js +1 -4
  140. package/dist/ui/settings/declarations.d.ts +3 -97
  141. package/dist/ui/settings/declarations.js +3 -78
  142. package/dist/ui/settings/migrations.js +18 -2
  143. package/docs/architecture/boundaries.md +22 -39
  144. package/docs/architecture/code-documentation.md +2 -2
  145. package/docs/architecture/internal-naming.md +9 -17
  146. package/docs/architecture/project-structure.md +30 -29
  147. package/docs/architecture/resource-and-data-policy.md +16 -31
  148. package/docs/architecture/toolchain.md +14 -19
  149. package/docs/architecture/ui-reference-provenance.md +2 -2
  150. package/docs/ci-release-runbook.md +6 -4
  151. package/docs/features/launch-profiles.md +11 -17
  152. package/docs/features/prompt-history.md +10 -11
  153. package/docs/local-worktree-cleanup.md +32 -1
  154. package/docs/manual-owned-ui-checkpoint.md +0 -1
  155. package/docs/openspec-archive-automation.md +11 -3
  156. package/docs/validation.md +5 -9
  157. package/docs/worktree-link-recovery.md +6 -6
  158. package/package.json +7 -19
  159. package/bin/guardian.js +0 -42
  160. package/bin/supervisor.js +0 -7
  161. package/bin/tab-launch-context.d.ts +0 -27
  162. package/bin/tab-launch-context.js +0 -94
  163. package/dist/app/session-shell/resident-tab-coordinator.d.ts +0 -38
  164. package/dist/app/session-shell/resident-tab-coordinator.js +0 -77
  165. package/dist/cli/tabs-request.d.ts +0 -7
  166. package/dist/cli/tabs-request.js +0 -1
  167. package/dist/cli/tabs.d.ts +0 -14
  168. package/dist/cli/tabs.js +0 -151
  169. package/dist/composition/resident-tab-bridge.d.ts +0 -41
  170. package/dist/composition/resident-tab-bridge.js +0 -209
  171. package/dist/composition/utility-tab.d.ts +0 -28
  172. package/dist/composition/utility-tab.js +0 -244
  173. package/dist/features/owned-ui/plus-menu-dialog.d.ts +0 -28
  174. package/dist/features/owned-ui/plus-menu-dialog.js +0 -89
  175. package/dist/features/resident-tab/auto-name.d.ts +0 -11
  176. package/dist/features/resident-tab/auto-name.js +0 -44
  177. package/dist/features/resident-tab/index.d.ts +0 -5
  178. package/dist/features/resident-tab/index.js +0 -7
  179. package/dist/features/resident-tab/shortcut-bindings-file.d.ts +0 -8
  180. package/dist/features/resident-tab/shortcut-bindings-file.js +0 -40
  181. package/dist/features/resident-tab/shortcut-declarations.d.ts +0 -13
  182. package/dist/features/resident-tab/shortcut-declarations.js +0 -26
  183. package/dist/features/resident-tab/shortcut-projection.d.ts +0 -29
  184. package/dist/features/resident-tab/shortcut-projection.js +0 -64
  185. package/dist/features/resident-tab/status-deriver.d.ts +0 -10
  186. package/dist/features/resident-tab/status-deriver.js +0 -12
  187. package/dist/foundation/launch-guardian/exit-watcher.d.ts +0 -14
  188. package/dist/foundation/launch-guardian/exit-watcher.js +0 -103
  189. package/dist/foundation/launch-guardian/index.d.ts +0 -2
  190. package/dist/foundation/launch-guardian/index.js +0 -1
  191. package/dist/foundation/launch-guardian/main.d.ts +0 -39
  192. package/dist/foundation/launch-guardian/main.js +0 -232
  193. package/dist/foundation/lifecycle/commands.d.ts +0 -40
  194. package/dist/foundation/lifecycle/commands.js +0 -1
  195. package/dist/foundation/lifecycle/launch-instance.d.ts +0 -46
  196. package/dist/foundation/lifecycle/launch-instance.js +0 -134
  197. package/dist/foundation/lifecycle/native-claim-gate.d.ts +0 -5
  198. package/dist/foundation/lifecycle/native-claim-gate.js +0 -41
  199. package/dist/foundation/lifecycle/supervisor-startup.d.ts +0 -30
  200. package/dist/foundation/lifecycle/supervisor-startup.js +0 -106
  201. package/dist/foundation/process-containment/addon-containment.d.ts +0 -20
  202. package/dist/foundation/process-containment/addon-containment.js +0 -139
  203. package/dist/foundation/process-containment/addon-process-inspector.d.ts +0 -11
  204. package/dist/foundation/process-containment/addon-process-inspector.js +0 -36
  205. package/dist/foundation/process-containment/addon.d.ts +0 -47
  206. package/dist/foundation/process-containment/addon.js +0 -57
  207. package/dist/foundation/process-containment/artifact.d.ts +0 -1
  208. package/dist/foundation/process-containment/artifact.js +0 -35
  209. package/dist/foundation/process-containment/contracts.d.ts +0 -33
  210. package/dist/foundation/process-containment/contracts.js +0 -35
  211. package/dist/foundation/process-containment/index.d.ts +0 -9
  212. package/dist/foundation/process-containment/index.js +0 -7
  213. package/dist/foundation/process-containment/linux-process-inspector.d.ts +0 -7
  214. package/dist/foundation/process-containment/linux-process-inspector.js +0 -27
  215. package/dist/foundation/process-containment/native-process-inspector.d.ts +0 -4
  216. package/dist/foundation/process-containment/native-process-inspector.js +0 -21
  217. package/dist/foundation/protocol/client.d.ts +0 -18
  218. package/dist/foundation/protocol/client.js +0 -130
  219. package/dist/foundation/protocol/index.d.ts +0 -3
  220. package/dist/foundation/protocol/index.js +0 -2
  221. package/dist/foundation/protocol/messages.d.ts +0 -90
  222. package/dist/foundation/protocol/messages.js +0 -100
  223. package/dist/foundation/release/cohort-selection.d.ts +0 -33
  224. package/dist/foundation/release/cohort-selection.js +0 -67
  225. package/dist/foundation/release/endpoint-lock.d.ts +0 -2
  226. package/dist/foundation/release/endpoint-lock.js +0 -37
  227. package/dist/foundation/release/endpoint-recovery.d.ts +0 -10
  228. package/dist/foundation/release/endpoint-recovery.js +0 -45
  229. package/dist/foundation/release/endpoints.d.ts +0 -32
  230. package/dist/foundation/release/endpoints.js +0 -152
  231. package/dist/foundation/release/prepared-update-activation.d.ts +0 -3
  232. package/dist/foundation/release/prepared-update-activation.js +0 -27
  233. package/dist/foundation/release/process-cleanup.d.ts +0 -14
  234. package/dist/foundation/release/process-cleanup.js +0 -76
  235. package/dist/foundation/release/supervisor-identity.d.ts +0 -15
  236. package/dist/foundation/release/supervisor-identity.js +0 -63
  237. package/dist/foundation/resident-tabs/boot-identity.d.ts +0 -6
  238. package/dist/foundation/resident-tabs/boot-identity.js +0 -16
  239. package/dist/foundation/resident-tabs/bounded-host-command.d.ts +0 -20
  240. package/dist/foundation/resident-tabs/bounded-host-command.js +0 -62
  241. package/dist/foundation/resident-tabs/bridge-client.d.ts +0 -73
  242. package/dist/foundation/resident-tabs/bridge-client.js +0 -327
  243. package/dist/foundation/resident-tabs/continuity.d.ts +0 -12
  244. package/dist/foundation/resident-tabs/continuity.js +0 -63
  245. package/dist/foundation/resident-tabs/doctor.d.ts +0 -28
  246. package/dist/foundation/resident-tabs/doctor.js +0 -166
  247. package/dist/foundation/resident-tabs/draft-checkpoint.d.ts +0 -27
  248. package/dist/foundation/resident-tabs/draft-checkpoint.js +0 -145
  249. package/dist/foundation/resident-tabs/ensure-terminal-host.d.ts +0 -36
  250. package/dist/foundation/resident-tabs/ensure-terminal-host.js +0 -151
  251. package/dist/foundation/resident-tabs/fault-injection.d.ts +0 -8
  252. package/dist/foundation/resident-tabs/fault-injection.js +0 -26
  253. package/dist/foundation/resident-tabs/fixture-control.d.ts +0 -7
  254. package/dist/foundation/resident-tabs/fixture-control.js +0 -35
  255. package/dist/foundation/resident-tabs/host-entry.d.ts +0 -1
  256. package/dist/foundation/resident-tabs/host-entry.js +0 -17
  257. package/dist/foundation/resident-tabs/index.d.ts +0 -15
  258. package/dist/foundation/resident-tabs/index.js +0 -10
  259. package/dist/foundation/resident-tabs/maintenance.d.ts +0 -39
  260. package/dist/foundation/resident-tabs/maintenance.js +0 -75
  261. package/dist/foundation/resident-tabs/progress-observation-schema.d.ts +0 -34
  262. package/dist/foundation/resident-tabs/progress-observation-schema.js +0 -1
  263. package/dist/foundation/resident-tabs/progress-observation.d.ts +0 -4
  264. package/dist/foundation/resident-tabs/progress-observation.js +0 -150
  265. package/dist/foundation/resident-tabs/prompt-journal.d.ts +0 -63
  266. package/dist/foundation/resident-tabs/prompt-journal.js +0 -213
  267. package/dist/foundation/resident-tabs/protocol.d.ts +0 -12
  268. package/dist/foundation/resident-tabs/protocol.js +0 -195
  269. package/dist/foundation/resident-tabs/recovery.d.ts +0 -26
  270. package/dist/foundation/resident-tabs/recovery.js +0 -205
  271. package/dist/foundation/resident-tabs/release-holds.d.ts +0 -28
  272. package/dist/foundation/resident-tabs/release-holds.js +0 -78
  273. package/dist/foundation/resident-tabs/routes.d.ts +0 -5
  274. package/dist/foundation/resident-tabs/routes.js +0 -5
  275. package/dist/foundation/resident-tabs/routing.d.ts +0 -11
  276. package/dist/foundation/resident-tabs/routing.js +0 -10
  277. package/dist/foundation/resident-tabs/runtime-control.d.ts +0 -38
  278. package/dist/foundation/resident-tabs/runtime-control.js +0 -74
  279. package/dist/foundation/resident-tabs/session-sync.d.ts +0 -14
  280. package/dist/foundation/resident-tabs/session-sync.js +0 -37
  281. package/dist/foundation/resident-tabs/settings.d.ts +0 -16
  282. package/dist/foundation/resident-tabs/settings.js +0 -60
  283. package/dist/foundation/resident-tabs/terminal-host-artifact.d.ts +0 -14
  284. package/dist/foundation/resident-tabs/terminal-host-artifact.js +0 -78
  285. package/dist/foundation/resident-tabs/zip-archive.d.ts +0 -9
  286. package/dist/foundation/resident-tabs/zip-archive.js +0 -56
  287. package/dist/foundation/storage/control-store.d.ts +0 -20
  288. package/dist/foundation/storage/control-store.js +0 -331
  289. package/dist/foundation/storage/index.d.ts +0 -1
  290. package/dist/foundation/storage/index.js +0 -1
  291. package/dist/foundation/supervision/index.d.ts +0 -3
  292. package/dist/foundation/supervision/index.js +0 -3
  293. package/dist/foundation/supervision/main.d.ts +0 -1
  294. package/dist/foundation/supervision/main.js +0 -86
  295. package/dist/foundation/supervision/paths.d.ts +0 -1
  296. package/dist/foundation/supervision/paths.js +0 -1
  297. package/dist/foundation/supervision/server.d.ts +0 -46
  298. package/dist/foundation/supervision/server.js +0 -606
  299. package/dist/integrations/pi/engine/offline-settings-port.d.ts +0 -23
  300. package/dist/integrations/pi/engine/offline-settings-port.js +0 -54
  301. package/dist/native/darwin-arm64/manifest.json +0 -23
  302. package/dist/native/darwin-arm64/process-guardian.node +0 -0
  303. package/dist/native/darwin-arm64/terminal-host-THIRD-PARTY-NOTICES.txt +0 -10500
  304. package/dist/native/darwin-arm64/terminal-host.manifest.json +0 -46
  305. package/dist/native/darwin-arm64/terminal-host.node +0 -0
  306. package/dist/native/darwin-x64/manifest.json +0 -23
  307. package/dist/native/darwin-x64/process-guardian.node +0 -0
  308. package/dist/native/darwin-x64/terminal-host-THIRD-PARTY-NOTICES.txt +0 -10737
  309. package/dist/native/darwin-x64/terminal-host.manifest.json +0 -46
  310. package/dist/native/darwin-x64/terminal-host.node +0 -0
  311. package/dist/native/linux-x64/manifest.json +0 -23
  312. package/dist/native/linux-x64/process-guardian.node +0 -0
  313. package/dist/native/linux-x64/terminal-host-THIRD-PARTY-NOTICES.txt +0 -11226
  314. package/dist/native/linux-x64/terminal-host.manifest.json +0 -46
  315. package/dist/native/linux-x64/terminal-host.node +0 -0
  316. package/dist/native/win32-x64/manifest.json +0 -23
  317. package/dist/native/win32-x64/process-guardian.node +0 -0
  318. package/dist/native/win32-x64/terminal-host-THIRD-PARTY-NOTICES.txt +0 -10757
  319. package/dist/native/win32-x64/terminal-host.manifest.json +0 -46
  320. package/dist/native/win32-x64/terminal-host.node +0 -0
  321. package/docs/architecture/evidence/resident-tabs/linux-x64.md +0 -37
  322. package/docs/architecture/evidence/resident-tabs/macos-arm64.md +0 -36
  323. package/docs/architecture/evidence/resident-tabs/macos-x64.md +0 -35
  324. package/docs/architecture/evidence/resident-tabs/windows-x64.md +0 -36
  325. package/docs/architecture/evidence/terminal-host-spike/manual-one-pane-terminal-host.md +0 -70
  326. package/docs/architecture/evidence/terminal-host-spike/manual-two-by-two-basic-terminal-host.md +0 -32
  327. package/docs/architecture/evidence/terminal-host-spike/milestone-baseline.json +0 -115
  328. package/docs/architecture/evidence/terminal-host-spike/owned-ui-foundation-prerequisite.json +0 -48
  329. package/docs/architecture/evidence/terminal-host-spike/terminal-host-provenance.json +0 -125
  330. package/docs/architecture/evidence/terminal-host-spike/terminal-host-task-5-1.json +0 -56
  331. package/docs/architecture/evidence/terminal-host-spike/terminal-host-task-5-3.json +0 -174
  332. package/docs/architecture/evidence/terminal-host-spike/terminal-spike-acceptance-record.json +0 -18
  333. package/docs/architecture/native-fixture-isolation.md +0 -23
  334. package/docs/architecture/process-guardian-provenance.md +0 -36
  335. package/docs/architecture/resident-tabs-requirements.md +0 -18
  336. package/docs/architecture/resident-tabs.md +0 -668
  337. package/docs/architecture/terminal-host-proof-gate.md +0 -34
  338. package/docs/architecture/terminal-host-provenance.md +0 -81
  339. package/docs/architecture/terminal-host-spike-evidence.md +0 -39
  340. package/docs/launch-recovery.md +0 -23
  341. package/docs/manual-launch-instance-acceptance.md +0 -43
  342. package/docs/manual-resident-tabs-acceptance.md +0 -51
@@ -103,6 +103,8 @@ The real three-release `update-predecessor` scenario is exhaustive because its f
103
103
 
104
104
  Development outcomes report each owner/scope invocation separately while sharing authenticated build/package preparation. The aggregate reports setup, scope, job, aggregate-processing, total runner, and runner-critical-path durations. The acceptance targets are at most eight minutes of runner critical path and five minutes for one PR-required scope; an over-target result remains unmet without retries, timeout increases, workload reduction, or mutable installation caches. Hosted queue time is reported separately when available and is not counted as test execution.
105
105
 
106
+ Candidate-packing Development lanes build the pure-JavaScript product once per lane with `npm run build` and record the build receipt; there is no native artifact to build, cache, restore, or certify.
107
+
106
108
  Inspect local committed and worktree impact without running tests:
107
109
 
108
110
  ```sh
@@ -125,7 +127,7 @@ Rendering evidence captures each selected producer/mode/workload matrix once and
125
127
 
126
128
  ## Resource-sensitive fast validation
127
129
 
128
- The authoritative fast-tier declaration identifies tests that repeatedly create temporary repositories, launch child processes, mutate storage, or coordinate release cohorts. The planner removes those files from the parallel remainder and runs them exactly once in one serial `vitest-fast-resource-sensitive` process with file parallelism disabled, on an isolated runner that no other partition shares. One process instead of one per file removes about twenty cold starts from the partition; each file still gets a fresh module context. Pull-request, development-package, and complete release plans use the same partition on every platform.
130
+ The authoritative fast-tier declaration identifies tests that repeatedly create temporary repositories, launch child processes, or mutate release and update state. The planner removes those files from the parallel remainder and runs them exactly once in one serial `vitest-fast-resource-sensitive` process with file parallelism disabled, on an isolated runner that no other partition shares. One process instead of one per file removes about twenty cold starts from the partition; each file still gets a fresh module context. Pull-request, development-package, and complete release plans use the same partition on every platform.
129
131
 
130
132
  The partition runs under an explicit `--testTimeout=30000`, the same hang bound the other explicit fast-tier invocations use. That bound is a hang detector, not a performance gate: shared Windows runners vary by a factor of two or more for identical work, and a fixed five-second wall-clock limit failed passing suites on runner noise. Per-test durations remain in the reporter evidence; `scripts/release/report-resource-sensitive-validation.mjs` records repeated executions and lists every test body above five seconds under `slowTests` so a real slowdown is visible without failing the pull request. A failure is still not retried or converted to success, and the bound is not raised to create margin.
131
133
 
@@ -152,7 +154,7 @@ For applicable code changes, it requires the dedicated Defender-enabled exact-pa
152
154
  | Windows Node 22 | Required for applicable changes | Not scheduled | Retained | Retained |
153
155
  | Windows Node 24 | Not scheduled | Retained | Retained | Retained |
154
156
 
155
- Each selected startup lane runs the package-install scenarios once: a failed budget remains failed and is never retried to obtain a warmed result. The budgets are the ones the `a1-shell` capability declares (2 seconds after an update and on a warm launch, 2.5 seconds with no live supervisor); development validation, development previews, nightly publication, and Full regression record an overrun as a warning and are judged by the three-run persistent-overrun verdict, while stable candidate validation fails on it (see `STARTUP_BUDGET_ENFORCEMENT` in [validation](validation.md)). The publication lane set comes from `scripts/release/publication-validation-matrix.mjs`: a numbered preview validates on the Windows, Linux, and macOS Node 24 lanes, and nightly covers the same head on Windows Node 22 within a day. Node 24 runtime support, other PR jobs, Defender, and publication gates are unchanged. Full validation retains every deferred startup, image, and history test through its existing suite owners.
157
+ Each selected startup lane runs the package-install scenarios once: a failed budget remains failed and is never retried to obtain a warmed result. The budgets are the ones the `a1-shell` capability declares (2 seconds after an update and on a warm launch, 2.5 seconds on a restart-equivalent launch); development validation, development previews, nightly publication, and Full regression record an overrun as a warning and are judged by the three-run persistent-overrun verdict, while stable candidate validation fails on it (see `STARTUP_BUDGET_ENFORCEMENT` in [validation](validation.md)). The publication lane set comes from `scripts/release/publication-validation-matrix.mjs`: a numbered preview validates on the Windows, Linux, and macOS Node 24 lanes, and nightly covers the same head on Windows Node 22 within a day. Node 24 runtime support, other PR jobs, Defender, and publication gates are unchanged. Full validation retains every deferred startup, image, and history test through its existing suite owners.
156
158
 
157
159
  The trade-off is delayed detection: a Node-24-specific regression can reach `develop` before nightly catches it, and the same is true for a real published-predecessor regression. A green bounded PR check does not certify Node 24 or real historical predecessor execution, and nightly failure still blocks its publication. For an unselected candidate or diagnosis, explicitly request the non-publishing standalone Full regression workflow for the desired branch or tag:
158
160
 
@@ -331,10 +333,10 @@ extra-path, wrong-body, or ambiguous work is refused. An existing reopening bran
331
333
  without that exact PR is preserved rather than overwritten. The local preparation
332
334
  checkout is never committed, reset, or used to publish package bytes.
333
335
 
334
- Candidate validation builds the process guardian on all supported platforms, stamps
336
+ Candidate validation builds the product, stamps
335
337
  the version, packs each package once, runs the complete stable suite against those
336
338
  bytes on Windows, Linux, and macOS, and retains the pair for 30 days as
337
- `release-package-<version>`. Stable publication skips the guardian builds and
339
+ `release-package-<version>`. Stable publication skips the build and
338
340
  validation lanes, adopts that retained pair, publishes both to npm `latest` with
339
341
  provenance from the `npm-publish` environment, and exercises the exact published
340
342
  installer/application pair in isolated prefixes on every release lane. Only after
@@ -4,17 +4,13 @@
4
4
 
5
5
  | Command | Purpose | Pi user profile |
6
6
  |---|---|---|
7
- | `a1` | A1 | `~/.a1/agent` |
7
+ | `a1` | A1, one agent in this terminal | `~/.a1/agent` |
8
8
  | `a1 --session <path\|id>` | Resume a persisted A1 session | `~/.a1/agent` (or explicitly selected storage) |
9
- | `a1 solo` | Fresh A1 direct single-agent mode | `~/.a1/agent` |
10
- | `a1 solo --session <path\|id>` | Resume a persisted A1 session in direct single-agent mode | `~/.a1/agent` (or explicitly selected storage) |
11
9
  | `a1 pi` | Pi-compatible direct comparison surface using the ordinary Pi profile | ordinary `~/.pi/agent` |
12
10
 
13
- `a1 solo` is available in release and prerelease builds. Without arguments it starts a fresh single-agent session; with `--session` and optional `--session-dir` it resumes a saved session. Both forms omit the tab strip and the Tabs settings section.
14
-
15
11
  `a1 pi` is a development instrument for comparing A1 against pinned Pi. Prerelease builds — what `a1 update --develop` or `a1 update --develop <number>` installs — expose it. A release build does not recognize the launch form. Repository development can run the comparison directly with `npm start:pi`.
16
12
 
17
- There is no `a1 agent` command. The former `a1 ui` subcommand is removed. Unsupported commands return quietly without selecting another runtime. Bare `a1` is the normal A1 product surface.
13
+ There is no `a1 agent` command. The former `a1 ui` subcommand, the `a1 solo` launch word, and the `a1 tabs …` maintenance commands are removed; like any other unsupported command they return quietly without selecting another runtime. Bare `a1` is the normal A1 product surface.
18
14
 
19
15
  ## First launch
20
16
 
@@ -37,20 +33,18 @@ Run Pi’s normal `/login` independently in each profile that needs stored authe
37
33
 
38
34
  ## Resume a session
39
35
 
40
- After a conversation has been persisted, exit A1 and run the command it prints from the original project directory. Exited solo sessions print the solo form; tabbed A1 sessions keep the tabbed form:
36
+ After a conversation has been persisted, exit A1 and run the command it prints from the original project directory:
41
37
 
42
38
  ```sh
43
39
  a1 --session <id>
44
40
  a1 --session-dir '/path/to/session store' --session <id>
45
- a1 solo --session <id>
46
- a1 solo --session-dir '/path/to/session store' --session <id>
47
41
  ```
48
42
 
49
43
  `--session` also accepts a `.jsonl` file path; `--session-dir` may come before or after it. Explicit storage overrides `PI_CODING_AGENT_SESSION_DIR`, which overrides default storage. IDs are searched in the current project before other projects within the A1 store. A cross-project ID match asks before creating a fork with a new identity; an explicit file resumes directly using its stored working directory. Missing or invalid targets fail rather than create an empty replacement.
50
44
 
51
- Resume uses the shipped Pi's public restoration behavior, including the compaction format it writes. It sends no model prompt by itself and does not recover, convert, or modify an unrelated conversation. A tabbed selection opens in a new A1 tab or focuses the tab already holding it; a solo selection opens in the direct strip-free UI without starting the resident host. A live session remains protected by its single-writer lease. Pi picker/continue CLI aliases and `a1 pi --session` are not supported; in-UI `/resume` is unchanged.
45
+ Resume uses the shipped Pi's public restoration behavior, including the compaction format it writes. It sends no model prompt by itself and does not recover, convert, or modify an unrelated conversation. A session already open in another A1 process stays protected by the session writer guard, so A1 offers a fork instead of attaching to it. Pi picker/continue CLI aliases and `a1 pi --session` are not supported; in-UI `/resume` is unchanged.
52
46
 
53
- Regression evidence creates disposable sessions through Pi 0.84.2, then executes the emitted command through the packed public entry, bootstrap, guardian, and owned UI. Default/custom storage, Windows Git Bash quoting, supervisor restart, failure cleanup, and simultaneous distinct selections are covered in `test/foundation/release/session-resume.integration.test.ts`. CI runs it in the resource-sensitive `package-smoke` scope, not the fast remainder. Unsupported synthetic retained-tail certification is separate deferred work.
47
+ Regression evidence creates disposable sessions through the pinned Pi, then executes the emitted command through the packed public entry, bootstrap, and owned UI. Default/custom storage, Windows Git Bash quoting, an occupied session, failure cleanup, and simultaneous distinct selections are covered in `test/foundation/release/session-resume.integration.test.ts`. CI runs it in the resource-sensitive `package-smoke` scope, not the fast remainder. Unsupported synthetic retained-tail certification is separate deferred work.
54
48
 
55
49
  ## Pi comparison profile
56
50
 
@@ -58,14 +52,14 @@ Regression evidence creates disposable sessions through Pi 0.84.2, then executes
58
52
 
59
53
  ## Terminal behavior
60
54
 
61
- All interactive launch forms run the A1-owned full-viewport TUI over pinned Pi engine, component, and terminal APIs. Bare `a1` attaches to the native resident host; each tab runs the owned UI in a holder-owned pseudoterminal, while Node never relays or renders terminal bytes. `a1 solo` uses the direct owned path without resident infrastructure. `a1 pi` uses that same direct pipeline with A1-specific screens withheld.
55
+ All interactive launch forms run the A1-owned full-viewport TUI over pinned Pi engine, component, and terminal APIs. The installed `a1` command selects the approved active release and runs its UI as one directly attached child process with the terminal inherited; nothing relays or renders terminal bytes in between. `a1 pi` uses that same pipeline with A1-specific screens withheld.
62
56
 
63
- ## Concurrent instance lifecycle
57
+ ## Concurrent launches
64
58
 
65
- Each `a1 solo` or `a1 pi` invocation receives a unique non-detachable launch instance. Normal A1 clients instead attach to the profile's tab set, which can be viewed from concurrent terminals with explicit input-controller transfer. Profile files remain shared according to the selected profile root.
59
+ Every `a1` or `a1 pi` invocation is an independent process. Any number can run at once in different terminals; profile files remain shared according to the selected profile root, and the session writer guard keeps each session file to one writer.
66
60
 
67
- Normal exit or terminal closure tears down a solo/comparison launch instance within bounded graceful and forced deadlines. Closing or detaching a normal A1 client leaves its tabs running; a tab and its process tree stop only when the user explicitly closes that tab.
61
+ Quitting with `/quit` or `Ctrl+C` twice ends the agent and returns to the shell. Closing the terminal ends the agent too, as it does for upstream Pi. If the UI exits uncleanly, the launcher restores the terminal and prints the resume command.
68
62
 
69
- ## Recovery and comparison
63
+ ## Comparison and reporting
70
64
 
71
- If A1's normal mode cannot start, bare `a1` falls back to the direct path with one notice. To start single agent mode explicitly, run `a1 solo` from the same working directory. To compare against the pinned Pi profile, run `a1 pi`; its profile data is intentionally separate, so authentication or settings may need independent configuration. Use `a1 --version` to record the installed A1 release before reporting a difference.
65
+ To compare against the pinned Pi profile, run `a1 pi`; its profile data is intentionally separate, so authentication or settings may need independent configuration. Use `a1 --version` to record the installed A1 release before reporting a difference.
@@ -44,11 +44,11 @@ imported automatically.
44
44
  The default uses A1's effective profile home: `A1_PROFILE_HOME` when set, otherwise
45
45
  the operating-system home. A custom agent-profile directory changes the history
46
46
  identity, not this default root. `A1_DATA_DIR` takes precedence for storage;
47
- `XDG_DATA_HOME` does not redirect default history. Control metadata, settings,
47
+ `XDG_DATA_HOME` does not redirect default history. Release state, settings,
48
48
  agent resources, releases, logs, runtime files, and caches keep their existing
49
49
  locations. For repository-local `./scripts/dev` launches, history uses a stable
50
- checkout-wide data root so two independent solo instances share the selected
51
- Shared database, while control and runtime data remain isolated per launch.
50
+ checkout-wide data root so two independent instances share the selected
51
+ Shared database, while release and runtime data remain isolated per launch.
52
52
  The development-only `A1_DEV_HISTORY_DATA_DIR` selects that root; an explicit
53
53
  `A1_DATA_DIR` still overrides its launcher default. Existing histories in old
54
54
  per-instance development roots are not moved or combined.
@@ -62,14 +62,14 @@ Old and new releases using different roots do not synchronize history.
62
62
  In Shared mode the filename is the original `a1-` SHA-256 profile identity,
63
63
  independent of project, session, checkout, and release. In Unique mode (the
64
64
  default), a domain-separated digest also includes the stable conversation session
65
- ID; two solo launches or resident tabs therefore use different databases and
65
+ ID; two concurrent launches therefore use different databases and
66
66
  image sidecars. Resuming the same session reuses its store; starting or forking a
67
67
  session selects a different one. Windows ordinary case and separator variants
68
68
  normalize together. Moving a profile, unresolved symlink aliases, or selecting a
69
69
  different data root can select a different history; A1 never silently merges or
70
70
  imports it.
71
71
 
72
- The database is separate from `control.sqlite3`, agent resources, and disposable
72
+ The database is separate from release state, agent resources, and disposable
73
73
  caches. Upgrades, ordinary npm uninstall/reinstall, release rollback, cache cleanup,
74
74
  and conversation deletion do not clear it. Reusing saved history requires the
75
75
  same profile and history root; explicitly deleting user data still removes it.
@@ -91,9 +91,9 @@ The History section in `/settings` provides:
91
91
  storage and durable recall for subsequent launches, not current-session
92
92
  recovery. Existing enabled instances keep running until closed.
93
93
  - **History scope:** Unique (default) keeps each agent session's durable prompts
94
- separate across solo launches and resident tabs. Shared restores the former
95
- profile-wide store. Switching applies to running agents, including other solo
96
- processes and resident tabs, when their shared settings update arrives. New
94
+ separate across concurrent launches. Shared restores the former
95
+ profile-wide store. Switching applies to running agents, including other A1
96
+ processes, when their shared settings update arrives. New
97
97
  prompts use the newly selected store; already-submitted writes finish in their
98
98
  original store. Switching never transfers or deletes records, and it preserves
99
99
  unsent drafts. Existing profiles without this setting default to Unique, so
@@ -145,9 +145,8 @@ Build the checkout, then launch it through `./scripts/dev`. Use an isolated
145
145
  `A1_DATA_DIR` for disposable history checks; keep that same directory on each
146
146
  restart and in both concurrent terminals. The development launcher always sets
147
147
  an isolated `A1_DATA_DIR`; to try the home-based location in that launcher,
148
- explicitly select `A1_DATA_DIR=<effective-home>/.a1/data` and keep
149
- `A1_DATABASE_PATH` in a separate disposable directory so control metadata is not
150
- placed beside history. For a history-only review, `NODE_DISABLE_COMPILE_CACHE=1`
148
+ explicitly select `A1_DATA_DIR=<effective-home>/.a1/data` in a disposable
149
+ profile home. For a history-only review, `NODE_DISABLE_COMPILE_CACHE=1`
151
150
  also avoids creating compile-cache files under that explicitly overridden root.
152
151
  The focused path/composition tests cover normal no-override selection. Test:
153
152
 
@@ -99,6 +99,32 @@ node scripts/governance/local-worktree-cleanup.mjs discard \
99
99
 
100
100
  An open, merged, reopened, forked, protected, reserved, advanced, dirty, active, linked, nested, replaced, current, or unverifiable candidate remains blocking. Remote deletion followed by a Windows lock or later local blocker is reported as `partial`; the journal preserves the remaining worktree/local ref for the same exact confirmed command to inspect and resume. The command never scans by age or name, adopts another session's checkout, enables queue/watch, or turns PR close events into automatic discard authority.
101
101
 
102
+ ### Closed-unmerged branch without a checkout
103
+
104
+ Use the same explicitly confirmed `discard` operation with `--branch` instead of `--path` when the checkout is already gone and no live cleanup registration owns the ref. The selectors are mutually exclusive:
105
+
106
+ ```bash
107
+ cd /d/Git/a1 && node scripts/governance/local-worktree-cleanup.mjs discard --repo D:/Git/a1 --branch feature/rejected-example --change rejected-example --pr 123 --confirm-closed-unmerged
108
+ ```
109
+
110
+ Branch mode verifies the named same-repository PR is still closed-unmerged into `develop`, its implementation association matches the requested change, no other open PR uses the branch, no Git worktree has it checked out, and no nonterminal registration owns the ref. Protected/reserved refs, advanced local or remote tips, malformed evidence, conflicting journals, and scoped lock contention block. It never creates a checkout, invents a filesystem identity, deletes a directory, or adopts a worktree.
111
+
112
+ A branch-scoped `branch-discard-<ref-digest>.json` journal beside the ordinary cleanup state pins the repository, exact ref, change, PR, expected head, and deletion step without changing existing worktree records. After local preflight, the command journals intent, revalidates live evidence, expected-head deletes only the remote ref, verifies remote absence, and compare-and-deletes the unchanged local ref. Absent refs support resumption. Repeated completed requests report `already-discarded` only while both refs remain absent; a recreated ref is retained as `discard-ref-recreated`. Command reports, not the worktree-only registration list, describe this branch-scoped state. Sweep and queue never invoke branch-only discard.
113
+
114
+ ## Explicit disposable-link remediation
115
+
116
+ Ordinary completion and sweep still refuse external descendant links. For one released, eligible merged candidate, a separately confirmed `unlink-disposable-link` operation can remove one explicitly named ignored descendant link beneath a central disposable root without admitting its external target into purge:
117
+
118
+ ```bash
119
+ cd /d/Git/a1 && node scripts/governance/local-worktree-cleanup.mjs unlink-disposable-link --repo D:/Git/a1 --path D:/Git/a1/.worktrees/example-task --change example-task --pr 123 --link .artifacts/agent/shared-node-modules --confirm-link-only
120
+ ```
121
+
122
+ The command requires the existing released registration, exact candidate/change/PR, accepted HEAD ancestry, eligible merged/archive evidence, absent remote topic ref, and clean local content except for that one named link. Invoke it from primary, with no known conflicting editor, using integrated repository policy. Owned, current, replaced, dirty, ineligible, unregistered, or resource-busy candidates remain blocked. Other unsafe links remain blockers; no wildcard or bulk-link option exists.
123
+
124
+ Only a relative slash-separated path strictly below a central disposable root is accepted. The path must be ignored and untracked, its parents must be real non-link directories inside the canonical worktree, and its final entry must be a resolvable symlink or junction with a target outside that worktree. Internally targeted links remain on the ordinary generated-content path and are rejected by this no-target-enumeration operation. Escapes, root substitutions, ordinary files/directories, cycles, Git-metadata targets, identity/target/parent drift, and locked links block. The command revalidates candidate authority, full local content, ancestor identities, link fingerprint, and target before every bounded non-recursive unlink attempt, including Windows junction fallback. It never enumerates, traverses, modifies, or removes the target.
125
+
126
+ An `unlinked` report records the candidate and removed link identity without target contents. The worktree and its released registration remain intact; a later ordinary `complete` or sweep must independently repeat every normal gate. The operation enables nothing, deletes no ref, does not grant ongoing link-removal authority, and cannot repair locked leftover directories. A missing selected link reports a named blocker rather than fabricating prior success.
127
+
102
128
  ## Explicit redundant no-PR retirement
103
129
 
104
130
  A non-empty unregistered checkout is never adopted by sweep, preview, queue/watch, branch pruning, age, or ancestry. After the maintainer explicitly authorizes one exact redundant checkout, use the repository-owned operation from the primary checkout:
@@ -170,7 +196,7 @@ Registration binds the repository, exact directory/filesystem identity, candidat
170
196
 
171
197
  A CI/base/older-ancestor checkout does not qualify automatically. Version 3 has no local acceptance/archive checkout to register. No local archive checkout is required when a legacy archive was generated entirely on GitHub. Legacy version-1/version-2 linkage remains supported, but individually reviewing and registering a legacy checkout is explicit adoption, not a bulk sweep.
172
198
 
173
- Low-level `register` keeps an explicit disposable allowlist for legacy and diagnostic use. The standard `complete` command supplies the central repository policy automatically; agents do not choose flags for normal completed-delivery cleanup. Neither route permits discarding tracked, staged, unstaged, untracked, unknown ignored, unapproved linked, special, or actual nested repository/submodule content. The sole link exception is the guarded exact-root or contained descendant behavior above. Declaring or centrally recognizing a generated directory does not bypass ignored-path, identity, type, or traversal checks.
199
+ Low-level `register` keeps an explicit disposable allowlist for legacy and diagnostic use. The standard `complete` command supplies the central repository policy automatically; agents do not choose flags for normal completed-delivery cleanup. Neither route permits discarding tracked, staged, unstaged, untracked, unknown ignored, unapproved linked, special, or actual nested repository/submodule content. Automatic purge admits only the guarded exact-root or contained descendant behavior above. Separately confirmed named-link remediation removes only its exact link entry and never widens purge authority. Declaring or centrally recognizing a generated directory does not bypass ignored-path, identity, type, or traversal checks.
174
200
 
175
201
  Before handing a completed checkout to cleanup, stop its development processes, leave its directory, and release it using the returned ID and current generation:
176
202
 
@@ -184,6 +210,10 @@ After a low-level release, request a pass from the stable checkout if queue clea
184
210
 
185
211
  ## Resume or recover ownership
186
212
 
213
+ This protocol works for external agents without an A1 installation, runtime, or session link. First verify the exact delivery branch, change, and PR plus continuing editing ownership or explicit handoff under the [worktree protocol](architecture/project-structure.md#development-worktrees). Inspect Git locks and this tool's `status` from the primary checkout. A familiar path, clean status, or missing A1 runtime is not evidence of another editor's absence. Known live editing claims, foreign cleanup ownership, Git locks, and unverifiable handoffs block reuse.
214
+
215
+ For a worktree with no cleanup registration, this tool supplies no ownership claim: a fresh checkout created by this session or verified continuing ownership/explicit handoff establishes editing provenance. Do not register with fabricated PR identities or create a cleanup claim solely to simulate an A1 link. For a released registration, the atomic claim below is mandatory before editing; an already-owned registration requires matching owner authority. A failed claim never authorizes recovery or takeover. A successful cleanup claim prevents cleanup but does not prove exclusive editing ownership, and an A1 runtime link does not claim the cleanup journal. Both remain cooperative, independent safeguards.
216
+
187
217
  Before resuming a released worktree, acquire it:
188
218
 
189
219
  ```bash
@@ -210,6 +240,7 @@ State, journals, stop controls, and execution reports live in `<git-common-dir>/
210
240
  - `blocked`: ownership, content, path, provenance, authentication, or identity needs attention.
211
241
  - `unmanaged`: no local registration; no automatic adoption. Reason `empty-directory-recent` marks an all-empty folder still inside its ten-minute grace, and in preview `empty-directory` marks one an execution pass would remove.
212
242
  - `removed`: worktree and eligible local-ref operations were verified.
243
+ - `unlinked`: only the explicitly named disposable link entry was removed; its target, worktree, and released registration were preserved.
213
244
  - `already-absent`: a completed journal's path/ref are still absent.
214
245
  - `retired`: either evidence was unverifiable but nothing remained to delete and the merged PR registration completed with `retired-nothing-left`, or an exact confirmed `retire-redundant` operation safely removed its no-PR checkout and local ref.
215
246
  - `forgotten`: the maintainer explicitly closed an all-absent entry with `forget`.
@@ -22,7 +22,6 @@ $manualRoot = (Resolve-Path ".artifacts/manual-owned-ui").Path
22
22
  $env:A1_CONFIG_DIR = "$manualRoot\state\config"
23
23
  $env:A1_DATA_DIR = "$manualRoot\state\data"
24
24
  $env:A1_RUNTIME_DIR = "$manualRoot\state\runtime"
25
- $env:A1_DATABASE_PATH = "$manualRoot\state\data\control.sqlite3"
26
25
  ```
27
26
 
28
27
  Run each installed launch form yourself:
@@ -6,6 +6,14 @@ Unrelated standalone documentation remains separate: a non-draft unassociated PR
6
6
 
7
7
  Version-1 and version-2 deliveries and their existing comments, acceptance PRs, archive PRs, receipts, retries, and bounded catch-up remain supported under [Legacy delivery](#legacy-delivery). Do not silently convert an in-flight legacy delivery.
8
8
 
9
+ ## Worktree context across agent environments
10
+
11
+ External agents use ordinary Git worktrees without an A1 installation, runtime, or session link. Follow the [development worktree protocol](architecture/project-structure.md#development-worktrees): keep primary on `develop`, run the cleanup sweep, inspect Git inventory, and verify the exact task root, common repository, branch, and state before edits. A fresh worktree created by the session establishes its provenance. An existing delivery needs continuing ownership or explicit handoff plus the exact branch, change, and PR; inventory and a clean checkout alone grant nothing.
12
+
13
+ Use A1 inventory/linking only inside an active A1 shell-tool session, and Claude Code's established worktree hooks in that environment. Missing A1 integration alone does not block an external agent. A known live owner, Git lock, conflicting cleanup owner, or unverifiable handoff still blocks reuse. Claim any released cleanup registration through the [cleanup ownership protocol](local-worktree-cleanup.md#resume-or-recover-ownership) before editing. Neither a runtime link nor a cleanup claim proves the absence of arbitrary external editors; coordination remains cooperative.
14
+
15
+ Repeat context and ownership verification on resume or stream changes, preserve the delivery's branch/history/PR, and keep every command explicitly scoped to its worktree. Handoffs name the absolute worktree path, branch, change, PR, and whether editing ownership is being handed over. An editing handoff does not register, release, or authorize cleanup and grants no integration authority. The lifecycle below applies equally to all agent environments.
16
+
9
17
  ## Version-3 lifecycle
10
18
 
11
19
  1. **Draft plan:** create one normally named branch/PR such as `feature/...`, `fix/...`, or `chore/...`. Start the body with `## Proposal`, use it for one or two sentences of intent, and follow it with one or more unchecked, outcome-sized task items under `## Implementation`, with no fixed maximum. Each item names a delivered code outcome. Omit generic process tasks; run, verify, validate, evidence, or manual-test items; quoted phase lines; and routine validation command lists, and keep machine linkage under final collapsed `Automation`. Keep it draft and include only planning artifacts until the maintainer approves the plan and explicitly requests implementation.
@@ -94,11 +102,11 @@ Keep acceptance absent during proposal review so unfinished intent is not mistak
94
102
 
95
103
  ## Agent scratch files
96
104
 
97
- When an agent chooses a path for a transient repository-delivery file—such as a PR/comment body, command payload, captured output, temporary patch/diff, or ad hoc log—it must use a purpose-specific descendant of the exact `.artifacts/` root in the worktree that owns the operation. A linked delivery uses its linked task worktree, not the primary checkout, another worktree, the operating-system temporary directory, home/desktop, or a sibling path. Address the worktree path explicitly because session linking does not change tool cwd.
105
+ When an agent chooses a path for a transient repository-delivery file—such as a PR/comment body, command payload, captured output, temporary patch/diff, or ad hoc log—it must use a purpose-specific descendant of the exact `.artifacts/` root in the worktree that owns the operation. Use the verified task worktree, not the primary checkout, another worktree, the operating-system temporary directory, home/desktop, or a sibling path. Address the worktree path explicitly; context verification and optional runtime association do not change tool cwd.
98
106
 
99
107
  Keep these files ignored, unstaged, uncommitted, disposable, non-authoritative, and free of credentials or other prohibited sensitive data. Required durable evidence belongs in its declared tracked OpenSpec location. This rule governs paths selected by the agent; it does not relocate temporary storage internally selected by Git, GitHub CLI, OpenSpec, language/package tooling, product runtime code, test frameworks, or hermetic fixtures.
100
108
 
101
- For example, create `.artifacts/agent/pr-body.md` in the linked worktree before passing it to `gh pr create --body-file` or `gh pr edit --body-file`. The exact `.artifacts/` root remains subject to the existing guarded generated-content cleanup policy; this guidance does not authorize deletion outside that root or through unsafe filesystem boundaries.
109
+ For example, create `.artifacts/agent/pr-body.md` in the verified task worktree before passing it to `gh pr create --body-file` or `gh pr edit --body-file`. The exact `.artifacts/` root remains subject to the existing guarded generated-content cleanup policy; this guidance does not authorize deletion outside that root or through unsafe filesystem boundaries.
102
110
 
103
111
  ## Version-3 implementation metadata
104
112
 
@@ -190,7 +198,7 @@ If an unassociated implementation has already integrated, do not edit its merged
190
198
 
191
199
  ## Finalization command
192
200
 
193
- The local command remains available for inspection or when a developer prefers to finalize before the automatic ready transition; the workflow then verifies the head and pushes nothing. It has inspection mode by default and an explicit `--write` mode. It never commits, pushes, edits GitHub, marks a PR ready, or merges. Run from the linked worktree and use an ignored artifact body file so the operation can update exact version-3 paths without mutating remote PR state:
201
+ The local command remains available for inspection or when a developer prefers to finalize before the automatic ready transition; the workflow then verifies the head and pushes nothing. It has inspection mode by default and an explicit `--write` mode. It never commits, pushes, edits GitHub, marks a PR ready, or merges. Run from the verified task worktree and use an ignored artifact body file so the operation can update exact version-3 paths without mutating remote PR state:
194
202
 
195
203
  ```bash
196
204
  git fetch origin develop
@@ -6,7 +6,7 @@ Development validation computes one exact base/head selection with:
6
6
  npm run select:validation-impact -- --base <full-base-sha> --head <full-head-sha> --output .artifacts/validation/impact.json
7
7
  ```
8
8
 
9
- The versioned `config/validation-ownership.json` registry maps stable product and test path groups to a mandatory PR core, an explicit critical floor per owner, changed and bounded transitive consumers, resource-sensitive tests, and integration owners. The coarse owners are UI/rendering, launch/startup, release/package/update, Pi, native containment, image/history, governance, and shared product inputs. Each integration owner in `config/integration-owners.json` declares `pull-request`, `direct-impact`, or `exhaustive` cadence. A changed pull-request test selects its owner; a changed exhaustive test selects focused deterministic contracts and records the exhaustive owner as cadence-deferred. Shared support selects every declared PR consumer and records affected exhaustive consumers; copies, renames, and deletions inspect both identities. Reasons and changed paths are recorded in `impact.json`.
9
+ The versioned `config/validation-ownership.json` registry maps stable product and test path groups to a mandatory PR core, an explicit critical floor per owner, changed and bounded transitive consumers, resource-sensitive tests, and integration owners. The coarse owners are UI/rendering, launch/startup, release/package/update, Pi, image/history, governance, and shared product inputs. Each integration owner in `config/integration-owners.json` declares `pull-request`, `direct-impact`, or `exhaustive` cadence. A changed pull-request test selects its owner; a changed exhaustive test selects focused deterministic contracts and records the exhaustive owner as cadence-deferred. Shared support selects every declared PR consumer and records affected exhaustive consumers; copies, renames, and deletions inspect both identities. Reasons and changed paths are recorded in `impact.json`.
10
10
 
11
11
  Reviewed `refinements` can narrow a coarse owner's tests and integration links for known subareas: scrollbar/settings, clipboard/editor/repository commands, documentation/cleanup/delivery governance, and development-environment tooling. Each rule keeps an explicit minimum test set; a bounded relative-import graph across `test/`, `src/`, `scripts/`, and `bin/` adds at most 24 sorted transitive consumers per changed path, including consumers outside the coarse owner, and integration owners of those retained consumers. The graph is supplemental, not sole coverage authority. Unreviewed or absent source identities and an unavailable graph retain the coarse owner. Changed tests, shared support, and mixed source/support changes retain their coarse contracts; rename and deletion classification still includes both identities. Some UI changes deliberately select more tests than before because the graph exposes formerly missed shell consumers.
12
12
 
@@ -40,7 +40,7 @@ Do not run preflight, `test:fast`, `test:full`, `test:release`, or directory-wid
40
40
  npm run preflight # pull-request validation's fast gates on the committed head
41
41
  ```
42
42
 
43
- Preflight selects the committed merge-base diff with `origin/develop` exactly as validation does (uncommitted paths are reported, not checked), writes it to `.artifacts/validation/local-impact.json`, and stops at the first failure. It runs the core job's install build and receipt, `typecheck`, `check:architecture`, changed-file code documentation, release documentation, changed-file naming, docs governance, strict OpenSpec validation with the workflow's pinned validator, the delivery-guidance test, and the core job's `pr-core-tests` and `pr-selected-tests` scopes. Each step invokes the script and arguments its workflow job runs, so a failure reports the same rule identifier and path. It never builds the native host, does not run resource-sensitive or integration owners, and CI remains the authority.
43
+ Preflight selects the committed merge-base diff with `origin/develop` exactly as validation does (uncommitted paths are reported, not checked), writes it to `.artifacts/validation/local-impact.json`, and stops at the first failure. It runs the core job's install build and receipt, `typecheck`, `check:architecture`, changed-file code documentation, release documentation, changed-file naming, docs governance, strict OpenSpec validation with the workflow's pinned validator, the delivery-guidance test, and the core job's `pr-core-tests` and `pr-selected-tests` scopes. Each step invokes the script and arguments its workflow job runs, so a failure reports the same rule identifier and path. It does not run resource-sensitive or integration owners, and CI remains the authority.
44
44
 
45
45
  `test:pr-core` is not a replacement for `test:fast`: CI combines it with directly changed and coarse-owner tests from the exact impact selection. Selected resource-sensitive tests run independently on an isolated Windows runner. Selected package, startup, rendering, Pi, compatibility, and platform owners also run independently after their actual prerequisites.
46
46
 
@@ -50,11 +50,7 @@ Conservative Development retains every critical owner floor and the small set of
50
50
  node scripts/release/generate-validation-ownership-ledger.mjs --output .artifacts/validation/ownership-ledger.json
51
51
  ```
52
52
 
53
- Containment-selected modular jobs build and test the debug `process-guardian.node` addon for their exact platform, export `A1_PROCESS_GUARDIAN_PATH` to that file, and run the launch-owner integration fixtures as Node processes. The tests exercise the real addon-held Windows job or Unix process group, addon-backed identity and terminal operations, and the Node exit watcher; no fixture invokes a process-guardian executable. The Windows startup lane keeps Defender real-time protection enabled while packaged startup loads the release addon.
54
-
55
- The `terminal-host` owner is CI-only. A change under `native/terminal-host/` or to its run scripts selects, per platform (Windows x64, Linux x64, macOS arm64), one **Native terminal host** job and three **Native terminal host tests** partition jobs. The partition jobs each build the test profile and run one third of the serialized `role_integration` suite (`run-terminal-host-probe.mjs --partition <i>/3`, partitioned by sorted test name read from the suite's source); the feature-gated `role-host` binary stands in only for the fixed role grammar inside Rust integration tests and is never packaged. The build-and-probe job runs `npm run test:terminal-host` with the role suite skipped (`TERMINAL_HOST_PARTITION=none`), building `terminal-host.node` with Rust, Node-API 9, and Zig 0.15.2 for the lane's exact target and baseline CPU model. It loads the addon for its version and non-interactive probes, verifies the shared session-writer lock export, and uploads the debug addon and frozen protocol manifest; Linux also runs bounded decoder fuzzing.
56
-
57
- The protected aggregate requires every partition of every selected platform, keyed by `partition` in the outcome authority and job envelope. Because the role suite no longer warms the resident launch paths in the build-and-probe job, its certification step runs one unmeasured `measure-resident-tabs.mjs` pass before the measured pass whose budgets are unchanged. Fidelity, latency, chaos, and certification start roles as `process.execPath dist/foundation/resident-tabs/host-entry.js` with `A1_TERMINAL_HOST_PATH` naming the addon. Windows cleanup identifies those Node-hosted residents by command line; it never kills every `node.exe` by image name. Locally, `npm run test:terminal-host` without a partition is unchanged and runs everything in one process. Local Windows builds fail in `build.rs` unless `TERMINAL_HOST_LOCAL_BUILD=1` is set, because Zig's package fetch unpacks test data that workstation antivirus quarantines. Native lanes also publish the terminal library they linked; a local build can link it instead of running Zig (see Local native iteration in [`architecture/resident-tabs.md`](architecture/resident-tabs.md)), which is development evidence only and never replaces selected CI. `TERMINAL_HOST_CONTRACTS_ONLY=1` is a library-only diagnostic and cannot substitute for selected CI. See [`native/terminal-host/README.md`](../native/terminal-host/README.md).
53
+ The repository has no native code, so no validation lane builds, caches, or certifies a native artifact; every lane builds the TypeScript product with `npm run build` and tests it as JavaScript. The Windows startup lane keeps Defender real-time protection enabled while it measures packaged startup.
58
54
 
59
55
  ## Coverage-preserving efficiency
60
56
 
@@ -94,7 +90,7 @@ For GitHub's explicit **re-run failed jobs** action, a successful job that GitHu
94
90
 
95
91
  Checkout-bound type, architecture, governance, unit, and smoke outcomes bind head/run/selection/scope authority without inventing package identity. Build and package receipts remain mandatory wherever validation consumes emitted or packed bytes: package, startup, update, compatibility, preview, release, and publication boundaries.
96
92
 
97
- A build receipt binds checkout head, complete build inputs, toolchain, emitted files, and native artifacts. A package receipt additionally binds exact tarball bytes, packed entries, manifest/bin identity, producer, and verified build/source authority. `VALIDATION_BUILD_READY` and `VALIDATION_CANDIDATE_TARBALL` only locate prerequisites; stale or tampered receipts cause fresh preparation or failure.
93
+ A build receipt binds checkout head, complete build inputs, toolchain, and emitted files. A package receipt additionally binds exact tarball bytes, packed entries, manifest/bin identity, producer, and verified build/source authority. `VALIDATION_BUILD_READY` and `VALIDATION_CANDIDATE_TARBALL` only locate prerequisites; stale or tampered receipts cause fresh preparation or failure.
98
94
 
99
95
  Npm download bytes may be reused with integrity checks and `--prefer-offline`, with normal network fallback. Every installation prefix remains fresh. Installed package trees, dependency certification, startup/profile state, mutable fixture repositories, passing outcomes, and publication evidence are never restored from caches.
100
96
 
@@ -141,7 +137,7 @@ Download these artifacts from the exact workflow run:
141
137
  - `development-validation-impact`: base/head, global selection identity, PR-core tests, selected pull-request owners, cadence-deferred exhaustive owners, exclusions, and bounded reasons.
142
138
  - `development-validation-outcome-<job>-<platform>-node<node>-attempt-<attempt>`: attempt-qualified outcome, content-free envelope, per-scope authority and duration, and applicable exact-artifact evidence.
143
139
  - `development-validation-aggregate-<head>-<run>-<attempt>`: selected/deferred owners, accepted/reused attempts, evidence count, runner critical path, total runner time, aggregate processing, setup/gate/scope time, cache state, and invocation count.
144
- - `pr-full-regression-selection-<run>-<attempt>` plus `complete-regression-aggregate-<run>-<attempt>`: current PR/head/base/metadata selection identity and all four exact-run native lane envelopes. Missing, mismatched, stale, failed, cancelled, or unexpected skip evidence blocks the protected aggregate. It reports the eight-minute critical-path and five-minute individual-scope targets as met or unmet; hosted queue delay is not test execution and remains separate.
140
+ - `pr-full-regression-selection-<run>-<attempt>` plus `complete-regression-aggregate-<run>-<attempt>`: current PR/head/base/metadata selection identity and all four exact-run platform lane envelopes. Missing, mismatched, stale, failed, cancelled, or unexpected skip evidence blocks the protected aggregate. It reports the eight-minute critical-path and five-minute individual-scope targets as met or unmet; hosted queue delay is not test execution and remains separate.
145
141
  - startup/resume phase JSONL and performance JSON: first-attempt launch evidence and retained failed setup/readiness records.
146
142
 
147
143
  For selected implementation candidates, record focused and pre-finalization full observations before finalization. Keep final head/run/selection identity in Actions and handoff rather than adding a post-success commit that invalidates that evidence. A successful selected PR run replaces an additional mandatory dispatch; standalone runs remain diagnostic, and numbered-package nightly recovery remains independent.
@@ -4,9 +4,9 @@ A1 coordinates worktree-claim mutations separately from the editing claims thems
4
4
 
5
5
  ## Automatic recovery
6
6
 
7
- Updated A1 holds an OS lock on the persistent `session-worktree-claims/mutation.authority` file. The OS releases it when the process exits, including a crash. `mutation.lock` is now a persistent directory that blocks older file-lock writers; its `owner.json` is only diagnostic metadata.
7
+ Updated A1 holds a `proper-lockfile` gate, the `mutation.authority.gate` lock directory beside the persistent `session-worktree-claims/mutation.authority` file, for each mutation. The holder refreshes it while working; a gate left by a crashed or stalled process becomes stale after 10 seconds and the next mutation reclaims it. `mutation.lock` is a persistent directory that blocks older file-lock writers; its `owner.json` is only diagnostic metadata.
8
8
 
9
- The next mutation safely recovers abandoned owner/pending metadata after taking native authority. Empty, truncated, NUL-filled, or otherwise malformed metadata does not prevent this recovery. One bounded `recovery.json` records the recovery reason/time, not the original bytes or session contents. A live native holder remains protected. Acquisition waits at most two seconds by default and honors cancellation.
9
+ The next mutation safely recovers abandoned owner/pending metadata after taking the gate. Empty, truncated, NUL-filled, or otherwise malformed metadata does not prevent this recovery. One bounded `recovery.json` records the recovery reason/time, not the original bytes or session contents. A live gate holder remains protected. Acquisition waits at most two seconds by default and honors cancellation.
10
10
 
11
11
  If startup registration fails temporarily, the running session retries on its 30-second refresh interval. Slow attempts are coalesced rather than queued indefinitely. Once registration succeeds, retry the explicit worktree link in the same session. Switching an agent's session replaces its publication identity, and disposal drains publication before releasing claims.
12
12
 
@@ -18,19 +18,19 @@ An existing regular-file `mutation.lock` belongs to the old protocol. Updated A1
18
18
 
19
19
  For this one-time legacy case, stop all older A1 processes normally, move only that exact regular lock file to a backup while they are stopped, then start updated A1. Keep sessions, runtime records, associations, editing claims, Git locks, and worktrees. Reinstalling/downgrading alone does not clear persisted legacy state. Never move the new directory or delete `mutation.authority` while A1 is running.
20
20
 
21
- When the old gate is absent, updated A1 initializes its compatibility barrier automatically. Older versions cannot mutate worktree claims after this point: all participating sessions must use the updated version. This intentionally prevents two incompatible mutation protocols from running concurrently. The installed native addon must support the new gate; there is no unsafe PID-file fallback if the addon is missing or outdated.
21
+ When the old gate is absent, updated A1 initializes its compatibility barrier automatically. Older versions cannot mutate worktree claims after this point: all participating sessions must use the updated version. This intentionally prevents two incompatible mutation protocols from running concurrently.
22
22
 
23
23
  ## Diagnostics
24
24
 
25
25
  | Code | Meaning / next step |
26
26
  | --- | --- |
27
- | `worktree-claim-busy` | A mutation still holds native authority. Retry the link shortly; runtime registration retries automatically. |
27
+ | `worktree-claim-busy` | A mutation still holds the gate. Retry the link shortly; runtime registration retries automatically. |
28
28
  | `worktree-legacy-recovery-required` | Retained old-format gate. Use the stopped-process legacy procedure above. |
29
- | `worktree-coordination-unavailable` | Missing or outdated native support. Repair/update the A1 installation. |
29
+ | `worktree-coordination-unavailable` | The installation cannot coordinate worktree claims. Repair/update the A1 installation. |
30
30
  | `worktree-coordination-io` | Gate/metadata filesystem access failed. Check permissions and storage availability. |
31
31
  | `worktree-coordination-boundary` | Unexpected file type, link, or entry. Retain it for inspection; do not clear the store. |
32
32
  | `session-runtime-unavailable` | Runtime registration has not succeeded. Retry after the next refresh and address any specific coordination failure. |
33
- | `process-inspection-unavailable` / `session-runtime-unverifiable` | Exact process identity cannot be checked. Repair inspection support; no ownership takeover is authorized. |
33
+ | `session-runtime-unverifiable` | The runtime's recorded process cannot be checked. Retry; no ownership takeover is authorized. |
34
34
  | `worktree-active-in-another-session` | Another live agent owns the target. Use a different worktree or have that owner release it. |
35
35
  | `worktree-owner-unverifiable` | The editing claim itself is uncertain. Gate recovery cannot make that claim available. |
36
36
 
package/package.json CHANGED
@@ -1,16 +1,12 @@
1
1
  {
2
2
  "name": "@timurproko/a1",
3
- "version": "0.2.7-dev.1245",
4
- "description": "Standalone terminal workspace for supervised native and managed agents",
3
+ "version": "0.2.7-dev.1252",
4
+ "description": "Standalone single-agent terminal UI on pinned Pi",
5
5
  "type": "module",
6
6
  "privateLaunchContract": "neutral-launch-v1",
7
7
  "updateActivationContracts": [
8
8
  "activate-v1"
9
9
  ],
10
- "residentControlContracts": [
11
- "resident-control-v1",
12
- "resident-workspace-v1"
13
- ],
14
10
  "updateCommandContracts": [
15
11
  "update-release-v1"
16
12
  ],
@@ -32,12 +28,10 @@
32
28
  "clean": "node scripts/clean.mjs",
33
29
  "build": "node scripts/development/run-build.mjs",
34
30
  "build:core": "node scripts/development/run-build.mjs --core",
35
- "build:managed": "npm run clean && tsc -p tsconfig.build.json && node scripts/release/generate-release-notes-resource.mjs && node scripts/pi/build-pi-settings-metadata.mjs && node scripts/pi/build-startup-public.mjs && node scripts/development/build-process-guardian.mjs",
36
- "build:process-guardian": "node scripts/development/build-process-guardian.mjs",
37
- "build:terminal-host": "node scripts/development/build-terminal-host.mjs",
31
+ "build:managed": "npm run clean && tsc -p tsconfig.build.json && node scripts/release/generate-release-notes-resource.mjs && node scripts/pi/build-pi-settings-metadata.mjs && node scripts/pi/build-startup-public.mjs",
38
32
  "typecheck": "tsgo -p tsconfig.json --noEmit && tsgo -p tsconfig.bin.json",
39
- "check:local": "npm run typecheck && npm run check:architecture && npm run check:names && vitest run test/repository-governance/native-ci-workflows.test.ts",
40
- "check:architecture": "node scripts/governance/check-architecture.mjs && node scripts/governance/check-session-writer-guard.mjs && node scripts/governance/check-product-identity-boundaries.mjs && node scripts/governance/check-package-identity.mjs && node scripts/governance/check-pinned-pi-source-ledger.mjs && node scripts/governance/check-terminal-host-provenance.mjs",
33
+ "check:local": "npm run typecheck && npm run check:architecture && npm run check:names",
34
+ "check:architecture": "node scripts/governance/check-architecture.mjs && node scripts/governance/check-session-writer-guard.mjs && node scripts/governance/check-product-identity-boundaries.mjs && node scripts/governance/check-package-identity.mjs && node scripts/governance/check-pinned-pi-source-ledger.mjs",
41
35
  "preflight": "node scripts/development/run-preflight.mjs",
42
36
  "check:names": "node scripts/governance/product-identifier-policy.mjs --check",
43
37
  "check:names:changed": "node scripts/governance/product-identifier-policy.mjs --check --selection .artifacts/validation/impact.json",
@@ -60,9 +54,6 @@
60
54
  "test:scope": "node scripts/release/run-validation-tier.mjs",
61
55
  "test:full": "node scripts/release/run-validation-tier.mjs full-release",
62
56
  "test:release": "node scripts/release/run-release-gates.mjs",
63
- "test:terminal-host": "node scripts/development/run-terminal-host-probe.mjs",
64
- "test:resident-parallel-progress": "node scripts/development/verify-resident-parallel-progress.mjs",
65
- "test:resident-chaos": "node scripts/development/run-resident-chaos.mjs --build",
66
57
  "test:pi-engine-conformance": "vitest run test/integrations/pi/engine/conformance.test.ts test/integrations/pi/engine/runtime-integration.test.ts test/integrations/pi/engine/session-integration.test.ts",
67
58
  "report:pi-engine-conformance": "npm run build --silent && node scripts/pi/run-pi-engine-conformance.mjs",
68
59
  "report:rendering-stability": "tsx scripts/pi/report-rendering-stability.ts",
@@ -70,8 +61,6 @@
70
61
  "sync:pi-ui": "npm run update:pi-component-parity && npm run update:pi-event-frame-parity",
71
62
  "update:pi-component-parity": "tsx scripts/pi/update-pi-component-parity.ts",
72
63
  "update:pi-event-frame-parity": "tsx scripts/pi/update-pi-event-frame-parity.ts",
73
- "proof:terminal-host": "node scripts/development/run-terminal-host.mjs",
74
- "proof:terminal-host:ci": "node scripts/development/certify-ci-terminal-host.mjs",
75
64
  "start": "npm run build && node scripts/development/dev-launch.mjs",
76
65
  "start:pi": "npm run build && node scripts/development/dev-launch.mjs pi",
77
66
  "prepack": "node scripts/release/validate-packaged-release-note.mjs && node scripts/release/prepack-gate.mjs",
@@ -110,7 +99,6 @@
110
99
  "cli",
111
100
  "tui",
112
101
  "terminal",
113
- "multiplexer",
114
102
  "agents"
115
103
  ],
116
104
  "author": "Timur Prokopiev",
@@ -126,7 +114,7 @@
126
114
  "@mariozechner/clipboard": "^0.3.9"
127
115
  },
128
116
  "publication": {
129
- "source": "fc4a2588e22b6d90034465d80d7923c8fede91d8",
130
- "pullRequest": 870
117
+ "source": "9f0307c00ea0b83cfd4aea196543ddb7738fc6ee",
118
+ "pullRequest": 878
131
119
  }
132
120
  }
package/bin/guardian.js DELETED
@@ -1,42 +0,0 @@
1
- #!/usr/bin/env node
2
-
3
- const startup = await import("../dist/foundation/startup/startup-runtime.js");
4
- startup.enableEnvironmentCompileCache(process.env);
5
- await startup.markStartupPhase(process.env, "guardian-start");
6
- const { resolve } = await import("node:path");
7
- const { parseSessionSelection } = await import("../dist/foundation/lifecycle/session-selection.js");
8
- const { runLaunchGuardian } = await import("../dist/foundation/launch-guardian/main.js");
9
-
10
- const { readLaunchContext } = await import("../dist/foundation/launch-context/index.js");
11
- const launchContext = readLaunchContext(process.env, "release");
12
- const releaseRoot = launchContext.releaseRoot;
13
- const profileId = readLaunchContext(process.env, "profile").launchProfile;
14
- // Invariant: the "release" and "profile" requirements above already refused an environment without
15
- // these values; the checks give the type checker the same certainty.
16
- if (releaseRoot === undefined || profileId === undefined) throw new Error("A1 launch context is incomplete");
17
-
18
- const sessionSelection = parseSessionSelection(process.argv.slice(2));
19
- const rootCommand = launchContext.residentRootExecutable === undefined ? undefined : {
20
- executable: launchContext.residentRootExecutable,
21
- arguments: JSON.parse(launchContext.residentRootArguments ?? "[]"),
22
- };
23
- Promise.resolve().then(() => runLaunchGuardian({
24
- ...(sessionSelection === undefined ? {} : { sessionSelection }),
25
- ...(rootCommand === undefined ? {} : { rootCommand }),
26
- profileId,
27
- releaseRoot,
28
- uiEntry: resolve(releaseRoot, "bin", "ui.js"),
29
- environment: process.env,
30
- cwd: process.cwd(),
31
- })).then(
32
- code => { process.exitCode = code; },
33
- error => {
34
- if (error instanceof Error && "code" in error && error.code === "release-superseded" && typeof process.send === "function") {
35
- process.send({ type: "a1-release-reselection" });
36
- process.exitCode = 1;
37
- return;
38
- }
39
- console.error(error instanceof Error ? error.message : String(error));
40
- process.exitCode = 1;
41
- },
42
- );
package/bin/supervisor.js DELETED
@@ -1,7 +0,0 @@
1
- #!/usr/bin/env node
2
- import { runSupervisor } from "../dist/foundation/supervision/index.js";
3
-
4
- runSupervisor(process.argv.slice(2)).catch(error => {
5
- console.error(error instanceof Error ? error.stack ?? error.message : String(error));
6
- process.exitCode = 1;
7
- });
@@ -1,27 +0,0 @@
1
- export interface TabLaunchCredentials {
2
- readonly tabId: string;
3
- readonly token: string;
4
- readonly endpoint: string;
5
- readonly releaseId?: string;
6
- }
7
-
8
- export function formatResidentFallbackNotice(reason: string): string;
9
-
10
- export function assignFreshSessionRuntimeId(
11
- environment: Record<string, string | undefined>,
12
- name: string,
13
- createId: () => string,
14
- ): string;
15
-
16
- export function waitForStandbyPromotion(input: NodeJS.ReadStream, promotionFile?: string): Promise<void>;
17
-
18
- export function consumeTabLaunchContext(
19
- arguments_: readonly string[],
20
- environment: Record<string, string | undefined>,
21
- ): {
22
- readonly uiArguments: string[];
23
- readonly tabCredentials: TabLaunchCredentials | undefined;
24
- readonly tabDataDir?: string;
25
- readonly tabIncarnation?: number;
26
- readonly tabStandby: boolean;
27
- };