@openrig/cli 0.1.12 → 0.3.0

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 (856) hide show
  1. package/daemon/assets/openrig-activity-hook-relay.cjs +104 -0
  2. package/daemon/dist/adapters/claude-code-adapter.d.ts +24 -6
  3. package/daemon/dist/adapters/claude-code-adapter.d.ts.map +1 -1
  4. package/daemon/dist/adapters/claude-code-adapter.js +221 -65
  5. package/daemon/dist/adapters/claude-code-adapter.js.map +1 -1
  6. package/daemon/dist/adapters/claude-resume.d.ts +5 -0
  7. package/daemon/dist/adapters/claude-resume.d.ts.map +1 -1
  8. package/daemon/dist/adapters/claude-resume.js +13 -0
  9. package/daemon/dist/adapters/claude-resume.js.map +1 -1
  10. package/daemon/dist/adapters/codex-resume.d.ts +8 -1
  11. package/daemon/dist/adapters/codex-resume.d.ts.map +1 -1
  12. package/daemon/dist/adapters/codex-resume.js +74 -5
  13. package/daemon/dist/adapters/codex-resume.js.map +1 -1
  14. package/daemon/dist/adapters/codex-runtime-adapter.d.ts +9 -5
  15. package/daemon/dist/adapters/codex-runtime-adapter.d.ts.map +1 -1
  16. package/daemon/dist/adapters/codex-runtime-adapter.js +255 -28
  17. package/daemon/dist/adapters/codex-runtime-adapter.js.map +1 -1
  18. package/daemon/dist/adapters/terminal-adapter.d.ts +2 -1
  19. package/daemon/dist/adapters/terminal-adapter.d.ts.map +1 -1
  20. package/daemon/dist/adapters/terminal-adapter.js +7 -1
  21. package/daemon/dist/adapters/terminal-adapter.js.map +1 -1
  22. package/daemon/dist/adapters/tmux.d.ts.map +1 -1
  23. package/daemon/dist/adapters/tmux.js +53 -5
  24. package/daemon/dist/adapters/tmux.js.map +1 -1
  25. package/daemon/dist/builtins/workflow-specs/basic-loop.yaml +76 -0
  26. package/daemon/dist/builtins/workflow-specs/conveyor.yaml +80 -0
  27. package/daemon/dist/db/migrations/021_seat_handover_observability.d.ts +3 -0
  28. package/daemon/dist/db/migrations/021_seat_handover_observability.d.ts.map +1 -0
  29. package/daemon/dist/db/migrations/021_seat_handover_observability.js +11 -0
  30. package/daemon/dist/db/migrations/021_seat_handover_observability.js.map +1 -0
  31. package/daemon/dist/db/migrations/022_node_codex_config_profile.d.ts +3 -0
  32. package/daemon/dist/db/migrations/022_node_codex_config_profile.d.ts.map +1 -0
  33. package/daemon/dist/db/migrations/022_node_codex_config_profile.js +7 -0
  34. package/daemon/dist/db/migrations/022_node_codex_config_profile.js.map +1 -0
  35. package/daemon/dist/db/migrations/023_stream_items.d.ts +16 -0
  36. package/daemon/dist/db/migrations/023_stream_items.d.ts.map +1 -0
  37. package/daemon/dist/db/migrations/023_stream_items.js +37 -0
  38. package/daemon/dist/db/migrations/023_stream_items.js.map +1 -0
  39. package/daemon/dist/db/migrations/024_queue_items.d.ts +19 -0
  40. package/daemon/dist/db/migrations/024_queue_items.d.ts.map +1 -0
  41. package/daemon/dist/db/migrations/024_queue_items.js +52 -0
  42. package/daemon/dist/db/migrations/024_queue_items.js.map +1 -0
  43. package/daemon/dist/db/migrations/025_queue_transitions.d.ts +13 -0
  44. package/daemon/dist/db/migrations/025_queue_transitions.d.ts.map +1 -0
  45. package/daemon/dist/db/migrations/025_queue_transitions.js +28 -0
  46. package/daemon/dist/db/migrations/025_queue_transitions.js.map +1 -0
  47. package/daemon/dist/db/migrations/026_inbox_entries.d.ts +14 -0
  48. package/daemon/dist/db/migrations/026_inbox_entries.d.ts.map +1 -0
  49. package/daemon/dist/db/migrations/026_inbox_entries.js +35 -0
  50. package/daemon/dist/db/migrations/026_inbox_entries.js.map +1 -0
  51. package/daemon/dist/db/migrations/027_outbox_entries.d.ts +12 -0
  52. package/daemon/dist/db/migrations/027_outbox_entries.d.ts.map +1 -0
  53. package/daemon/dist/db/migrations/027_outbox_entries.js +30 -0
  54. package/daemon/dist/db/migrations/027_outbox_entries.js.map +1 -0
  55. package/daemon/dist/db/migrations/028_project_classifications.d.ts +26 -0
  56. package/daemon/dist/db/migrations/028_project_classifications.d.ts.map +1 -0
  57. package/daemon/dist/db/migrations/028_project_classifications.js +44 -0
  58. package/daemon/dist/db/migrations/028_project_classifications.js.map +1 -0
  59. package/daemon/dist/db/migrations/029_classifier_leases.d.ts +22 -0
  60. package/daemon/dist/db/migrations/029_classifier_leases.d.ts.map +1 -0
  61. package/daemon/dist/db/migrations/029_classifier_leases.js +41 -0
  62. package/daemon/dist/db/migrations/029_classifier_leases.js.map +1 -0
  63. package/daemon/dist/db/migrations/030_views_custom.d.ts +15 -0
  64. package/daemon/dist/db/migrations/030_views_custom.d.ts.map +1 -0
  65. package/daemon/dist/db/migrations/030_views_custom.js +27 -0
  66. package/daemon/dist/db/migrations/030_views_custom.js.map +1 -0
  67. package/daemon/dist/db/migrations/031_watchdog_jobs.d.ts +34 -0
  68. package/daemon/dist/db/migrations/031_watchdog_jobs.d.ts.map +1 -0
  69. package/daemon/dist/db/migrations/031_watchdog_jobs.js +59 -0
  70. package/daemon/dist/db/migrations/031_watchdog_jobs.js.map +1 -0
  71. package/daemon/dist/db/migrations/032_watchdog_history.d.ts +28 -0
  72. package/daemon/dist/db/migrations/032_watchdog_history.d.ts.map +1 -0
  73. package/daemon/dist/db/migrations/032_watchdog_history.js +46 -0
  74. package/daemon/dist/db/migrations/032_watchdog_history.js.map +1 -0
  75. package/daemon/dist/db/migrations/033_workflow_specs.d.ts +30 -0
  76. package/daemon/dist/db/migrations/033_workflow_specs.d.ts.map +1 -0
  77. package/daemon/dist/db/migrations/033_workflow_specs.js +50 -0
  78. package/daemon/dist/db/migrations/033_workflow_specs.js.map +1 -0
  79. package/daemon/dist/db/migrations/034_workflow_instances.d.ts +42 -0
  80. package/daemon/dist/db/migrations/034_workflow_instances.d.ts.map +1 -0
  81. package/daemon/dist/db/migrations/034_workflow_instances.js +63 -0
  82. package/daemon/dist/db/migrations/034_workflow_instances.js.map +1 -0
  83. package/daemon/dist/db/migrations/035_workflow_step_trails.d.ts +29 -0
  84. package/daemon/dist/db/migrations/035_workflow_step_trails.d.ts.map +1 -0
  85. package/daemon/dist/db/migrations/035_workflow_step_trails.js +48 -0
  86. package/daemon/dist/db/migrations/035_workflow_step_trails.js.map +1 -0
  87. package/daemon/dist/db/migrations/036_watchdog_policy_enum_extension.d.ts +35 -0
  88. package/daemon/dist/db/migrations/036_watchdog_policy_enum_extension.d.ts.map +1 -0
  89. package/daemon/dist/db/migrations/036_watchdog_policy_enum_extension.js +43 -0
  90. package/daemon/dist/db/migrations/036_watchdog_policy_enum_extension.js.map +1 -0
  91. package/daemon/dist/db/migrations/037_mission_control_actions.d.ts +51 -0
  92. package/daemon/dist/db/migrations/037_mission_control_actions.d.ts.map +1 -0
  93. package/daemon/dist/db/migrations/037_mission_control_actions.js +74 -0
  94. package/daemon/dist/db/migrations/037_mission_control_actions.js.map +1 -0
  95. package/daemon/dist/db/migrations/038_workspace_primitive.d.ts +16 -0
  96. package/daemon/dist/db/migrations/038_workspace_primitive.d.ts.map +1 -0
  97. package/daemon/dist/db/migrations/038_workspace_primitive.js +20 -0
  98. package/daemon/dist/db/migrations/038_workspace_primitive.js.map +1 -0
  99. package/daemon/dist/db/migrations/039_queue_target_repo.d.ts +16 -0
  100. package/daemon/dist/db/migrations/039_queue_target_repo.d.ts.map +1 -0
  101. package/daemon/dist/db/migrations/039_queue_target_repo.js +21 -0
  102. package/daemon/dist/db/migrations/039_queue_target_repo.js.map +1 -0
  103. package/daemon/dist/domain/active-lens-store.d.ts +23 -0
  104. package/daemon/dist/domain/active-lens-store.d.ts.map +1 -0
  105. package/daemon/dist/domain/active-lens-store.js +87 -0
  106. package/daemon/dist/domain/active-lens-store.js.map +1 -0
  107. package/daemon/dist/domain/agent-activity-store.d.ts +42 -0
  108. package/daemon/dist/domain/agent-activity-store.d.ts.map +1 -0
  109. package/daemon/dist/domain/agent-activity-store.js +177 -0
  110. package/daemon/dist/domain/agent-activity-store.js.map +1 -0
  111. package/daemon/dist/domain/agent-images/agent-image-library-service.d.ts +68 -0
  112. package/daemon/dist/domain/agent-images/agent-image-library-service.d.ts.map +1 -0
  113. package/daemon/dist/domain/agent-images/agent-image-library-service.js +339 -0
  114. package/daemon/dist/domain/agent-images/agent-image-library-service.js.map +1 -0
  115. package/daemon/dist/domain/agent-images/agent-image-types.d.ts +113 -0
  116. package/daemon/dist/domain/agent-images/agent-image-types.d.ts.map +1 -0
  117. package/daemon/dist/domain/agent-images/agent-image-types.js +24 -0
  118. package/daemon/dist/domain/agent-images/agent-image-types.js.map +1 -0
  119. package/daemon/dist/domain/agent-images/evidence-guard.d.ts +26 -0
  120. package/daemon/dist/domain/agent-images/evidence-guard.d.ts.map +1 -0
  121. package/daemon/dist/domain/agent-images/evidence-guard.js +185 -0
  122. package/daemon/dist/domain/agent-images/evidence-guard.js.map +1 -0
  123. package/daemon/dist/domain/agent-images/manifest-parser.d.ts +3 -0
  124. package/daemon/dist/domain/agent-images/manifest-parser.d.ts.map +1 -0
  125. package/daemon/dist/domain/agent-images/manifest-parser.js +114 -0
  126. package/daemon/dist/domain/agent-images/manifest-parser.js.map +1 -0
  127. package/daemon/dist/domain/agent-images/resume-token-discovery.d.ts +28 -0
  128. package/daemon/dist/domain/agent-images/resume-token-discovery.d.ts.map +1 -0
  129. package/daemon/dist/domain/agent-images/resume-token-discovery.js +83 -0
  130. package/daemon/dist/domain/agent-images/resume-token-discovery.js.map +1 -0
  131. package/daemon/dist/domain/agent-images/snapshot-capturer.d.ts +36 -0
  132. package/daemon/dist/domain/agent-images/snapshot-capturer.d.ts.map +1 -0
  133. package/daemon/dist/domain/agent-images/snapshot-capturer.js +58 -0
  134. package/daemon/dist/domain/agent-images/snapshot-capturer.js.map +1 -0
  135. package/daemon/dist/domain/agent-manifest.d.ts.map +1 -1
  136. package/daemon/dist/domain/agent-manifest.js +3 -0
  137. package/daemon/dist/domain/agent-manifest.js.map +1 -1
  138. package/daemon/dist/domain/agent-starter-resolver.d.ts +94 -0
  139. package/daemon/dist/domain/agent-starter-resolver.d.ts.map +1 -0
  140. package/daemon/dist/domain/agent-starter-resolver.js +198 -0
  141. package/daemon/dist/domain/agent-starter-resolver.js.map +1 -0
  142. package/daemon/dist/domain/classifier-lease-manager.d.ts +130 -0
  143. package/daemon/dist/domain/classifier-lease-manager.d.ts.map +1 -0
  144. package/daemon/dist/domain/classifier-lease-manager.js +285 -0
  145. package/daemon/dist/domain/classifier-lease-manager.js.map +1 -0
  146. package/daemon/dist/domain/conflict-detector.d.ts.map +1 -1
  147. package/daemon/dist/domain/conflict-detector.js +6 -3
  148. package/daemon/dist/domain/conflict-detector.js.map +1 -1
  149. package/daemon/dist/domain/context-monitor.d.ts +5 -4
  150. package/daemon/dist/domain/context-monitor.d.ts.map +1 -1
  151. package/daemon/dist/domain/context-monitor.js +26 -11
  152. package/daemon/dist/domain/context-monitor.js.map +1 -1
  153. package/daemon/dist/domain/context-packs/bundle-assembler.d.ts +49 -0
  154. package/daemon/dist/domain/context-packs/bundle-assembler.d.ts.map +1 -0
  155. package/daemon/dist/domain/context-packs/bundle-assembler.js +81 -0
  156. package/daemon/dist/domain/context-packs/bundle-assembler.js.map +1 -0
  157. package/daemon/dist/domain/context-packs/context-pack-library-service.d.ts +41 -0
  158. package/daemon/dist/domain/context-packs/context-pack-library-service.d.ts.map +1 -0
  159. package/daemon/dist/domain/context-packs/context-pack-library-service.js +148 -0
  160. package/daemon/dist/domain/context-packs/context-pack-library-service.js.map +1 -0
  161. package/daemon/dist/domain/context-packs/context-pack-types.d.ts +64 -0
  162. package/daemon/dist/domain/context-packs/context-pack-types.d.ts.map +1 -0
  163. package/daemon/dist/domain/context-packs/context-pack-types.js +22 -0
  164. package/daemon/dist/domain/context-packs/context-pack-types.js.map +1 -0
  165. package/daemon/dist/domain/context-packs/manifest-parser.d.ts +3 -0
  166. package/daemon/dist/domain/context-packs/manifest-parser.d.ts.map +1 -0
  167. package/daemon/dist/domain/context-packs/manifest-parser.js +74 -0
  168. package/daemon/dist/domain/context-packs/manifest-parser.js.map +1 -0
  169. package/daemon/dist/domain/context-usage-store.d.ts +15 -2
  170. package/daemon/dist/domain/context-usage-store.d.ts.map +1 -1
  171. package/daemon/dist/domain/context-usage-store.js +157 -2
  172. package/daemon/dist/domain/context-usage-store.js.map +1 -1
  173. package/daemon/dist/domain/files/file-write-service.d.ts +61 -0
  174. package/daemon/dist/domain/files/file-write-service.d.ts.map +1 -0
  175. package/daemon/dist/domain/files/file-write-service.js +180 -0
  176. package/daemon/dist/domain/files/file-write-service.js.map +1 -0
  177. package/daemon/dist/domain/files/path-safety.d.ts +47 -0
  178. package/daemon/dist/domain/files/path-safety.d.ts.map +1 -0
  179. package/daemon/dist/domain/files/path-safety.js +176 -0
  180. package/daemon/dist/domain/files/path-safety.js.map +1 -0
  181. package/daemon/dist/domain/graph-projection.d.ts +14 -1
  182. package/daemon/dist/domain/graph-projection.d.ts.map +1 -1
  183. package/daemon/dist/domain/graph-projection.js +8 -0
  184. package/daemon/dist/domain/graph-projection.js.map +1 -1
  185. package/daemon/dist/domain/hot-potato-enforcer.d.ts +45 -0
  186. package/daemon/dist/domain/hot-potato-enforcer.d.ts.map +1 -0
  187. package/daemon/dist/domain/hot-potato-enforcer.js +94 -0
  188. package/daemon/dist/domain/hot-potato-enforcer.js.map +1 -0
  189. package/daemon/dist/domain/inbox-handler.d.ts +68 -0
  190. package/daemon/dist/domain/inbox-handler.d.ts.map +1 -0
  191. package/daemon/dist/domain/inbox-handler.js +177 -0
  192. package/daemon/dist/domain/inbox-handler.js.map +1 -0
  193. package/daemon/dist/domain/install-engine.d.ts.map +1 -1
  194. package/daemon/dist/domain/install-engine.js +22 -6
  195. package/daemon/dist/domain/install-engine.js.map +1 -1
  196. package/daemon/dist/domain/install-verifier.d.ts.map +1 -1
  197. package/daemon/dist/domain/install-verifier.js +10 -5
  198. package/daemon/dist/domain/install-verifier.js.map +1 -1
  199. package/daemon/dist/domain/managed-blocks.d.ts.map +1 -1
  200. package/daemon/dist/domain/managed-blocks.js +22 -3
  201. package/daemon/dist/domain/managed-blocks.js.map +1 -1
  202. package/daemon/dist/domain/mission-control/audit-browse.d.ts +26 -0
  203. package/daemon/dist/domain/mission-control/audit-browse.d.ts.map +1 -0
  204. package/daemon/dist/domain/mission-control/audit-browse.js +101 -0
  205. package/daemon/dist/domain/mission-control/audit-browse.js.map +1 -0
  206. package/daemon/dist/domain/mission-control/mission-control-action-log.d.ts +51 -0
  207. package/daemon/dist/domain/mission-control/mission-control-action-log.d.ts.map +1 -0
  208. package/daemon/dist/domain/mission-control/mission-control-action-log.js +124 -0
  209. package/daemon/dist/domain/mission-control/mission-control-action-log.js.map +1 -0
  210. package/daemon/dist/domain/mission-control/mission-control-fleet-cli-capability.d.ts +131 -0
  211. package/daemon/dist/domain/mission-control/mission-control-fleet-cli-capability.d.ts.map +1 -0
  212. package/daemon/dist/domain/mission-control/mission-control-fleet-cli-capability.js +232 -0
  213. package/daemon/dist/domain/mission-control/mission-control-fleet-cli-capability.js.map +1 -0
  214. package/daemon/dist/domain/mission-control/mission-control-read-layer.d.ts +85 -0
  215. package/daemon/dist/domain/mission-control/mission-control-read-layer.d.ts.map +1 -0
  216. package/daemon/dist/domain/mission-control/mission-control-read-layer.js +265 -0
  217. package/daemon/dist/domain/mission-control/mission-control-read-layer.js.map +1 -0
  218. package/daemon/dist/domain/mission-control/mission-control-write-contract.d.ts +69 -0
  219. package/daemon/dist/domain/mission-control/mission-control-write-contract.d.ts.map +1 -0
  220. package/daemon/dist/domain/mission-control/mission-control-write-contract.js +300 -0
  221. package/daemon/dist/domain/mission-control/mission-control-write-contract.js.map +1 -0
  222. package/daemon/dist/domain/mission-control/notification-adapter-ntfy.d.ts +18 -0
  223. package/daemon/dist/domain/mission-control/notification-adapter-ntfy.d.ts.map +1 -0
  224. package/daemon/dist/domain/mission-control/notification-adapter-ntfy.js +48 -0
  225. package/daemon/dist/domain/mission-control/notification-adapter-ntfy.js.map +1 -0
  226. package/daemon/dist/domain/mission-control/notification-adapter-types.d.ts +25 -0
  227. package/daemon/dist/domain/mission-control/notification-adapter-types.d.ts.map +1 -0
  228. package/daemon/dist/domain/mission-control/notification-adapter-types.js +7 -0
  229. package/daemon/dist/domain/mission-control/notification-adapter-types.js.map +1 -0
  230. package/daemon/dist/domain/mission-control/notification-adapter-webhook.d.ts +27 -0
  231. package/daemon/dist/domain/mission-control/notification-adapter-webhook.d.ts.map +1 -0
  232. package/daemon/dist/domain/mission-control/notification-adapter-webhook.js +47 -0
  233. package/daemon/dist/domain/mission-control/notification-adapter-webhook.js.map +1 -0
  234. package/daemon/dist/domain/mission-control/notification-dispatcher.d.ts +53 -0
  235. package/daemon/dist/domain/mission-control/notification-dispatcher.d.ts.map +1 -0
  236. package/daemon/dist/domain/mission-control/notification-dispatcher.js +181 -0
  237. package/daemon/dist/domain/mission-control/notification-dispatcher.js.map +1 -0
  238. package/daemon/dist/domain/native-resume-probe.d.ts +1 -1
  239. package/daemon/dist/domain/native-resume-probe.d.ts.map +1 -1
  240. package/daemon/dist/domain/native-resume-probe.js +67 -0
  241. package/daemon/dist/domain/native-resume-probe.js.map +1 -1
  242. package/daemon/dist/domain/node-inventory.d.ts +29 -1
  243. package/daemon/dist/domain/node-inventory.d.ts.map +1 -1
  244. package/daemon/dist/domain/node-inventory.js +184 -38
  245. package/daemon/dist/domain/node-inventory.js.map +1 -1
  246. package/daemon/dist/domain/node-launcher.d.ts +2 -0
  247. package/daemon/dist/domain/node-launcher.d.ts.map +1 -1
  248. package/daemon/dist/domain/node-launcher.js +21 -7
  249. package/daemon/dist/domain/node-launcher.js.map +1 -1
  250. package/daemon/dist/domain/outbox-handler.d.ts +48 -0
  251. package/daemon/dist/domain/outbox-handler.d.ts.map +1 -0
  252. package/daemon/dist/domain/outbox-handler.js +106 -0
  253. package/daemon/dist/domain/outbox-handler.js.map +1 -0
  254. package/daemon/dist/domain/policies/artifact-pool-helpers.d.ts +64 -0
  255. package/daemon/dist/domain/policies/artifact-pool-helpers.d.ts.map +1 -0
  256. package/daemon/dist/domain/policies/artifact-pool-helpers.js +226 -0
  257. package/daemon/dist/domain/policies/artifact-pool-helpers.js.map +1 -0
  258. package/daemon/dist/domain/policies/artifact-pool-ready.d.ts +3 -0
  259. package/daemon/dist/domain/policies/artifact-pool-ready.d.ts.map +1 -0
  260. package/daemon/dist/domain/policies/artifact-pool-ready.js +41 -0
  261. package/daemon/dist/domain/policies/artifact-pool-ready.js.map +1 -0
  262. package/daemon/dist/domain/policies/edge-artifact-required.d.ts +3 -0
  263. package/daemon/dist/domain/policies/edge-artifact-required.d.ts.map +1 -0
  264. package/daemon/dist/domain/policies/edge-artifact-required.js +90 -0
  265. package/daemon/dist/domain/policies/edge-artifact-required.js.map +1 -0
  266. package/daemon/dist/domain/policies/periodic-reminder.d.ts +3 -0
  267. package/daemon/dist/domain/policies/periodic-reminder.d.ts.map +1 -0
  268. package/daemon/dist/domain/policies/periodic-reminder.js +30 -0
  269. package/daemon/dist/domain/policies/periodic-reminder.js.map +1 -0
  270. package/daemon/dist/domain/policies/types.d.ts +51 -0
  271. package/daemon/dist/domain/policies/types.d.ts.map +1 -0
  272. package/daemon/dist/domain/policies/types.js +9 -0
  273. package/daemon/dist/domain/policies/types.js.map +1 -0
  274. package/daemon/dist/domain/policies/workflow-keepalive.d.ts +7 -0
  275. package/daemon/dist/domain/policies/workflow-keepalive.d.ts.map +1 -0
  276. package/daemon/dist/domain/policies/workflow-keepalive.js +123 -0
  277. package/daemon/dist/domain/policies/workflow-keepalive.js.map +1 -0
  278. package/daemon/dist/domain/preview/preview-rate-limiter.d.ts +20 -0
  279. package/daemon/dist/domain/preview/preview-rate-limiter.d.ts.map +1 -0
  280. package/daemon/dist/domain/preview/preview-rate-limiter.js +46 -0
  281. package/daemon/dist/domain/preview/preview-rate-limiter.js.map +1 -0
  282. package/daemon/dist/domain/profile-resolver.d.ts +5 -0
  283. package/daemon/dist/domain/profile-resolver.d.ts.map +1 -1
  284. package/daemon/dist/domain/profile-resolver.js +62 -8
  285. package/daemon/dist/domain/profile-resolver.js.map +1 -1
  286. package/daemon/dist/domain/progress/progress-indexer.d.ts +73 -0
  287. package/daemon/dist/domain/progress/progress-indexer.d.ts.map +1 -0
  288. package/daemon/dist/domain/progress/progress-indexer.js +210 -0
  289. package/daemon/dist/domain/progress/progress-indexer.js.map +1 -0
  290. package/daemon/dist/domain/project-classifier.d.ts +75 -0
  291. package/daemon/dist/domain/project-classifier.d.ts.map +1 -0
  292. package/daemon/dist/domain/project-classifier.js +132 -0
  293. package/daemon/dist/domain/project-classifier.js.map +1 -0
  294. package/daemon/dist/domain/projection-planner.d.ts +1 -0
  295. package/daemon/dist/domain/projection-planner.d.ts.map +1 -1
  296. package/daemon/dist/domain/projection-planner.js +3 -0
  297. package/daemon/dist/domain/projection-planner.js.map +1 -1
  298. package/daemon/dist/domain/ps-projection.d.ts +31 -0
  299. package/daemon/dist/domain/ps-projection.d.ts.map +1 -1
  300. package/daemon/dist/domain/ps-projection.js +38 -0
  301. package/daemon/dist/domain/ps-projection.js.map +1 -1
  302. package/daemon/dist/domain/queue-repository.d.ts +340 -0
  303. package/daemon/dist/domain/queue-repository.d.ts.map +1 -0
  304. package/daemon/dist/domain/queue-repository.js +744 -0
  305. package/daemon/dist/domain/queue-repository.js.map +1 -0
  306. package/daemon/dist/domain/queue-transition-log.d.ts +38 -0
  307. package/daemon/dist/domain/queue-transition-log.d.ts.map +1 -0
  308. package/daemon/dist/domain/queue-transition-log.js +52 -0
  309. package/daemon/dist/domain/queue-transition-log.js.map +1 -0
  310. package/daemon/dist/domain/rehydrate-eligibility.d.ts +16 -0
  311. package/daemon/dist/domain/rehydrate-eligibility.d.ts.map +1 -0
  312. package/daemon/dist/domain/rehydrate-eligibility.js +43 -0
  313. package/daemon/dist/domain/rehydrate-eligibility.js.map +1 -0
  314. package/daemon/dist/domain/restore-check-service.d.ts +203 -0
  315. package/daemon/dist/domain/restore-check-service.d.ts.map +1 -0
  316. package/daemon/dist/domain/restore-check-service.js +1060 -0
  317. package/daemon/dist/domain/restore-check-service.js.map +1 -0
  318. package/daemon/dist/domain/restore-orchestrator.d.ts +49 -3
  319. package/daemon/dist/domain/restore-orchestrator.d.ts.map +1 -1
  320. package/daemon/dist/domain/restore-orchestrator.js +464 -64
  321. package/daemon/dist/domain/restore-orchestrator.js.map +1 -1
  322. package/daemon/dist/domain/rig-expansion-service.d.ts.map +1 -1
  323. package/daemon/dist/domain/rig-expansion-service.js +13 -0
  324. package/daemon/dist/domain/rig-expansion-service.js.map +1 -1
  325. package/daemon/dist/domain/rig-repository.d.ts +31 -1
  326. package/daemon/dist/domain/rig-repository.d.ts.map +1 -1
  327. package/daemon/dist/domain/rig-repository.js +104 -5
  328. package/daemon/dist/domain/rig-repository.js.map +1 -1
  329. package/daemon/dist/domain/rig-teardown.d.ts.map +1 -1
  330. package/daemon/dist/domain/rig-teardown.js +5 -0
  331. package/daemon/dist/domain/rig-teardown.js.map +1 -1
  332. package/daemon/dist/domain/rigspec-codec.d.ts.map +1 -1
  333. package/daemon/dist/domain/rigspec-codec.js +28 -0
  334. package/daemon/dist/domain/rigspec-codec.js.map +1 -1
  335. package/daemon/dist/domain/rigspec-exporter.d.ts.map +1 -1
  336. package/daemon/dist/domain/rigspec-exporter.js +2 -0
  337. package/daemon/dist/domain/rigspec-exporter.js.map +1 -1
  338. package/daemon/dist/domain/rigspec-instantiator.d.ts +29 -0
  339. package/daemon/dist/domain/rigspec-instantiator.d.ts.map +1 -1
  340. package/daemon/dist/domain/rigspec-instantiator.js +194 -2
  341. package/daemon/dist/domain/rigspec-instantiator.js.map +1 -1
  342. package/daemon/dist/domain/rigspec-schema.d.ts.map +1 -1
  343. package/daemon/dist/domain/rigspec-schema.js +349 -0
  344. package/daemon/dist/domain/rigspec-schema.js.map +1 -1
  345. package/daemon/dist/domain/runtime-adapter.d.ts +38 -2
  346. package/daemon/dist/domain/runtime-adapter.d.ts.map +1 -1
  347. package/daemon/dist/domain/runtime-adapter.js +5 -0
  348. package/daemon/dist/domain/runtime-adapter.js.map +1 -1
  349. package/daemon/dist/domain/seat-handover-planner.d.ts +84 -0
  350. package/daemon/dist/domain/seat-handover-planner.d.ts.map +1 -0
  351. package/daemon/dist/domain/seat-handover-planner.js +188 -0
  352. package/daemon/dist/domain/seat-handover-planner.js.map +1 -0
  353. package/daemon/dist/domain/seat-handover-service.d.ts +104 -0
  354. package/daemon/dist/domain/seat-handover-service.d.ts.map +1 -0
  355. package/daemon/dist/domain/seat-handover-service.js +343 -0
  356. package/daemon/dist/domain/seat-handover-service.js.map +1 -0
  357. package/daemon/dist/domain/seat-status-service.d.ts +50 -0
  358. package/daemon/dist/domain/seat-status-service.d.ts.map +1 -0
  359. package/daemon/dist/domain/seat-status-service.js +66 -0
  360. package/daemon/dist/domain/seat-status-service.js.map +1 -0
  361. package/daemon/dist/domain/session-source-rebuild-resolver.d.ts +53 -0
  362. package/daemon/dist/domain/session-source-rebuild-resolver.d.ts.map +1 -0
  363. package/daemon/dist/domain/session-source-rebuild-resolver.js +59 -0
  364. package/daemon/dist/domain/session-source-rebuild-resolver.js.map +1 -0
  365. package/daemon/dist/domain/session-transport.d.ts +30 -0
  366. package/daemon/dist/domain/session-transport.d.ts.map +1 -1
  367. package/daemon/dist/domain/session-transport.js +322 -12
  368. package/daemon/dist/domain/session-transport.js.map +1 -1
  369. package/daemon/dist/domain/skill-discovery.d.ts +51 -0
  370. package/daemon/dist/domain/skill-discovery.d.ts.map +1 -0
  371. package/daemon/dist/domain/skill-discovery.js +144 -0
  372. package/daemon/dist/domain/skill-discovery.js.map +1 -0
  373. package/daemon/dist/domain/slices/slice-detail-projector.d.ts +182 -0
  374. package/daemon/dist/domain/slices/slice-detail-projector.d.ts.map +1 -0
  375. package/daemon/dist/domain/slices/slice-detail-projector.js +508 -0
  376. package/daemon/dist/domain/slices/slice-detail-projector.js.map +1 -0
  377. package/daemon/dist/domain/slices/slice-indexer.d.ts +118 -0
  378. package/daemon/dist/domain/slices/slice-indexer.d.ts.map +1 -0
  379. package/daemon/dist/domain/slices/slice-indexer.js +503 -0
  380. package/daemon/dist/domain/slices/slice-indexer.js.map +1 -0
  381. package/daemon/dist/domain/snapshot-repository.d.ts +18 -0
  382. package/daemon/dist/domain/snapshot-repository.d.ts.map +1 -1
  383. package/daemon/dist/domain/snapshot-repository.js +77 -0
  384. package/daemon/dist/domain/snapshot-repository.js.map +1 -1
  385. package/daemon/dist/domain/spec-library-service.d.ts +17 -2
  386. package/daemon/dist/domain/spec-library-service.d.ts.map +1 -1
  387. package/daemon/dist/domain/spec-library-service.js +31 -1
  388. package/daemon/dist/domain/spec-library-service.js.map +1 -1
  389. package/daemon/dist/domain/spec-library-workflow-scanner.d.ts +81 -0
  390. package/daemon/dist/domain/spec-library-workflow-scanner.d.ts.map +1 -0
  391. package/daemon/dist/domain/spec-library-workflow-scanner.js +171 -0
  392. package/daemon/dist/domain/spec-library-workflow-scanner.js.map +1 -0
  393. package/daemon/dist/domain/startup-orchestrator.d.ts +22 -3
  394. package/daemon/dist/domain/startup-orchestrator.d.ts.map +1 -1
  395. package/daemon/dist/domain/startup-orchestrator.js +31 -5
  396. package/daemon/dist/domain/startup-orchestrator.js.map +1 -1
  397. package/daemon/dist/domain/startup-validation.d.ts.map +1 -1
  398. package/daemon/dist/domain/startup-validation.js +57 -11
  399. package/daemon/dist/domain/startup-validation.js.map +1 -1
  400. package/daemon/dist/domain/steering/health-summary.d.ts +39 -0
  401. package/daemon/dist/domain/steering/health-summary.d.ts.map +1 -0
  402. package/daemon/dist/domain/steering/health-summary.js +100 -0
  403. package/daemon/dist/domain/steering/health-summary.js.map +1 -0
  404. package/daemon/dist/domain/steering/steering-composer.d.ts +102 -0
  405. package/daemon/dist/domain/steering/steering-composer.d.ts.map +1 -0
  406. package/daemon/dist/domain/steering/steering-composer.js +263 -0
  407. package/daemon/dist/domain/steering/steering-composer.js.map +1 -0
  408. package/daemon/dist/domain/stream-store.d.ts +56 -0
  409. package/daemon/dist/domain/stream-store.d.ts.map +1 -0
  410. package/daemon/dist/domain/stream-store.js +108 -0
  411. package/daemon/dist/domain/stream-store.js.map +1 -0
  412. package/daemon/dist/domain/transcript-capture.d.ts.map +1 -1
  413. package/daemon/dist/domain/transcript-capture.js +7 -4
  414. package/daemon/dist/domain/transcript-capture.js.map +1 -1
  415. package/daemon/dist/domain/transcript-redaction.d.ts +13 -0
  416. package/daemon/dist/domain/transcript-redaction.d.ts.map +1 -0
  417. package/daemon/dist/domain/transcript-redaction.js +34 -0
  418. package/daemon/dist/domain/transcript-redaction.js.map +1 -0
  419. package/daemon/dist/domain/transcript-rotation.d.ts +29 -0
  420. package/daemon/dist/domain/transcript-rotation.d.ts.map +1 -0
  421. package/daemon/dist/domain/transcript-rotation.js +109 -0
  422. package/daemon/dist/domain/transcript-rotation.js.map +1 -0
  423. package/daemon/dist/domain/transcript-store.d.ts +15 -0
  424. package/daemon/dist/domain/transcript-store.d.ts.map +1 -1
  425. package/daemon/dist/domain/transcript-store.js +64 -2
  426. package/daemon/dist/domain/transcript-store.js.map +1 -1
  427. package/daemon/dist/domain/types.d.ts +416 -4
  428. package/daemon/dist/domain/types.d.ts.map +1 -1
  429. package/daemon/dist/domain/types.js +8 -1
  430. package/daemon/dist/domain/types.js.map +1 -1
  431. package/daemon/dist/domain/user-settings/settings-store.d.ts +42 -0
  432. package/daemon/dist/domain/user-settings/settings-store.d.ts.map +1 -0
  433. package/daemon/dist/domain/user-settings/settings-store.js +364 -0
  434. package/daemon/dist/domain/user-settings/settings-store.js.map +1 -0
  435. package/daemon/dist/domain/view-event-bridge.d.ts +12 -0
  436. package/daemon/dist/domain/view-event-bridge.d.ts.map +1 -0
  437. package/daemon/dist/domain/view-event-bridge.js +91 -0
  438. package/daemon/dist/domain/view-event-bridge.js.map +1 -0
  439. package/daemon/dist/domain/view-projector.d.ts +83 -0
  440. package/daemon/dist/domain/view-projector.d.ts.map +1 -0
  441. package/daemon/dist/domain/view-projector.js +296 -0
  442. package/daemon/dist/domain/view-projector.js.map +1 -0
  443. package/daemon/dist/domain/watchdog-history-log.d.ts +49 -0
  444. package/daemon/dist/domain/watchdog-history-log.d.ts.map +1 -0
  445. package/daemon/dist/domain/watchdog-history-log.js +67 -0
  446. package/daemon/dist/domain/watchdog-history-log.js.map +1 -0
  447. package/daemon/dist/domain/watchdog-jobs-repository.d.ts +81 -0
  448. package/daemon/dist/domain/watchdog-jobs-repository.d.ts.map +1 -0
  449. package/daemon/dist/domain/watchdog-jobs-repository.js +164 -0
  450. package/daemon/dist/domain/watchdog-jobs-repository.js.map +1 -0
  451. package/daemon/dist/domain/watchdog-policy-engine.d.ts +92 -0
  452. package/daemon/dist/domain/watchdog-policy-engine.d.ts.map +1 -0
  453. package/daemon/dist/domain/watchdog-policy-engine.js +442 -0
  454. package/daemon/dist/domain/watchdog-policy-engine.js.map +1 -0
  455. package/daemon/dist/domain/watchdog-scheduler.d.ts +76 -0
  456. package/daemon/dist/domain/watchdog-scheduler.d.ts.map +1 -0
  457. package/daemon/dist/domain/watchdog-scheduler.js +112 -0
  458. package/daemon/dist/domain/watchdog-scheduler.js.map +1 -0
  459. package/daemon/dist/domain/whoami-service.d.ts +29 -0
  460. package/daemon/dist/domain/whoami-service.d.ts.map +1 -1
  461. package/daemon/dist/domain/whoami-service.js +68 -0
  462. package/daemon/dist/domain/whoami-service.js.map +1 -1
  463. package/daemon/dist/domain/workflow/slice-workflow-binding.d.ts +21 -0
  464. package/daemon/dist/domain/workflow/slice-workflow-binding.d.ts.map +1 -0
  465. package/daemon/dist/domain/workflow/slice-workflow-binding.js +103 -0
  466. package/daemon/dist/domain/workflow/slice-workflow-binding.js.map +1 -0
  467. package/daemon/dist/domain/workflow/slice-workflow-projection.d.ts +81 -0
  468. package/daemon/dist/domain/workflow/slice-workflow-projection.d.ts.map +1 -0
  469. package/daemon/dist/domain/workflow/slice-workflow-projection.js +127 -0
  470. package/daemon/dist/domain/workflow/slice-workflow-projection.js.map +1 -0
  471. package/daemon/dist/domain/workflow/starter-spec-loader.d.ts +51 -0
  472. package/daemon/dist/domain/workflow/starter-spec-loader.d.ts.map +1 -0
  473. package/daemon/dist/domain/workflow/starter-spec-loader.js +140 -0
  474. package/daemon/dist/domain/workflow/starter-spec-loader.js.map +1 -0
  475. package/daemon/dist/domain/workflow-instance-store.d.ts +46 -0
  476. package/daemon/dist/domain/workflow-instance-store.d.ts.map +1 -0
  477. package/daemon/dist/domain/workflow-instance-store.js +116 -0
  478. package/daemon/dist/domain/workflow-instance-store.js.map +1 -0
  479. package/daemon/dist/domain/workflow-projector.d.ts +64 -0
  480. package/daemon/dist/domain/workflow-projector.d.ts.map +1 -0
  481. package/daemon/dist/domain/workflow-projector.js +432 -0
  482. package/daemon/dist/domain/workflow-projector.js.map +1 -0
  483. package/daemon/dist/domain/workflow-runtime.d.ts +63 -0
  484. package/daemon/dist/domain/workflow-runtime.d.ts.map +1 -0
  485. package/daemon/dist/domain/workflow-runtime.js +150 -0
  486. package/daemon/dist/domain/workflow-runtime.js.map +1 -0
  487. package/daemon/dist/domain/workflow-spec-cache.d.ts +42 -0
  488. package/daemon/dist/domain/workflow-spec-cache.d.ts.map +1 -0
  489. package/daemon/dist/domain/workflow-spec-cache.js +218 -0
  490. package/daemon/dist/domain/workflow-spec-cache.js.map +1 -0
  491. package/daemon/dist/domain/workflow-step-trail-log.d.ts +27 -0
  492. package/daemon/dist/domain/workflow-step-trail-log.d.ts.map +1 -0
  493. package/daemon/dist/domain/workflow-step-trail-log.js +73 -0
  494. package/daemon/dist/domain/workflow-step-trail-log.js.map +1 -0
  495. package/daemon/dist/domain/workflow-types.d.ts +108 -0
  496. package/daemon/dist/domain/workflow-types.d.ts.map +1 -0
  497. package/daemon/dist/domain/workflow-types.js +11 -0
  498. package/daemon/dist/domain/workflow-types.js.map +1 -0
  499. package/daemon/dist/domain/workflow-validator.d.ts +31 -0
  500. package/daemon/dist/domain/workflow-validator.d.ts.map +1 -0
  501. package/daemon/dist/domain/workflow-validator.js +115 -0
  502. package/daemon/dist/domain/workflow-validator.js.map +1 -0
  503. package/daemon/dist/domain/workspace/default-workspace-scaffold.d.ts +6 -0
  504. package/daemon/dist/domain/workspace/default-workspace-scaffold.d.ts.map +1 -0
  505. package/daemon/dist/domain/workspace/default-workspace-scaffold.js +207 -0
  506. package/daemon/dist/domain/workspace/default-workspace-scaffold.js.map +1 -0
  507. package/daemon/dist/domain/workspace/frontmatter-validator.d.ts +40 -0
  508. package/daemon/dist/domain/workspace/frontmatter-validator.d.ts.map +1 -0
  509. package/daemon/dist/domain/workspace/frontmatter-validator.js +185 -0
  510. package/daemon/dist/domain/workspace/frontmatter-validator.js.map +1 -0
  511. package/daemon/dist/domain/workspace/workspace-resolver.d.ts +25 -0
  512. package/daemon/dist/domain/workspace/workspace-resolver.d.ts.map +1 -0
  513. package/daemon/dist/domain/workspace/workspace-resolver.js +86 -0
  514. package/daemon/dist/domain/workspace/workspace-resolver.js.map +1 -0
  515. package/daemon/dist/index.d.ts.map +1 -1
  516. package/daemon/dist/index.js +30 -2
  517. package/daemon/dist/index.js.map +1 -1
  518. package/daemon/dist/middleware/auth-bearer-token.d.ts +49 -0
  519. package/daemon/dist/middleware/auth-bearer-token.d.ts.map +1 -0
  520. package/daemon/dist/middleware/auth-bearer-token.js +135 -0
  521. package/daemon/dist/middleware/auth-bearer-token.js.map +1 -0
  522. package/daemon/dist/openrig-compat.d.ts +1 -1
  523. package/daemon/dist/openrig-compat.d.ts.map +1 -1
  524. package/daemon/dist/openrig-compat.js +6 -4
  525. package/daemon/dist/openrig-compat.js.map +1 -1
  526. package/daemon/dist/routes/activity.d.ts +3 -0
  527. package/daemon/dist/routes/activity.d.ts.map +1 -0
  528. package/daemon/dist/routes/activity.js +47 -0
  529. package/daemon/dist/routes/activity.js.map +1 -0
  530. package/daemon/dist/routes/agent-images.d.ts +8 -0
  531. package/daemon/dist/routes/agent-images.d.ts.map +1 -0
  532. package/daemon/dist/routes/agent-images.js +253 -0
  533. package/daemon/dist/routes/agent-images.js.map +1 -0
  534. package/daemon/dist/routes/config.d.ts +3 -0
  535. package/daemon/dist/routes/config.d.ts.map +1 -0
  536. package/daemon/dist/routes/config.js +109 -0
  537. package/daemon/dist/routes/config.js.map +1 -0
  538. package/daemon/dist/routes/context-packs.d.ts +3 -0
  539. package/daemon/dist/routes/context-packs.d.ts.map +1 -0
  540. package/daemon/dist/routes/context-packs.js +129 -0
  541. package/daemon/dist/routes/context-packs.js.map +1 -0
  542. package/daemon/dist/routes/files.d.ts +17 -0
  543. package/daemon/dist/routes/files.d.ts.map +1 -0
  544. package/daemon/dist/routes/files.js +262 -0
  545. package/daemon/dist/routes/files.js.map +1 -0
  546. package/daemon/dist/routes/health-summary.d.ts +9 -0
  547. package/daemon/dist/routes/health-summary.d.ts.map +1 -0
  548. package/daemon/dist/routes/health-summary.js +33 -0
  549. package/daemon/dist/routes/health-summary.js.map +1 -0
  550. package/daemon/dist/routes/mission-control.d.ts +37 -0
  551. package/daemon/dist/routes/mission-control.d.ts.map +1 -0
  552. package/daemon/dist/routes/mission-control.js +283 -0
  553. package/daemon/dist/routes/mission-control.js.map +1 -0
  554. package/daemon/dist/routes/progress.d.ts +7 -0
  555. package/daemon/dist/routes/progress.d.ts.map +1 -0
  556. package/daemon/dist/routes/progress.js +33 -0
  557. package/daemon/dist/routes/progress.js.map +1 -0
  558. package/daemon/dist/routes/projects.d.ts +12 -0
  559. package/daemon/dist/routes/projects.d.ts.map +1 -0
  560. package/daemon/dist/routes/projects.js +178 -0
  561. package/daemon/dist/routes/projects.js.map +1 -0
  562. package/daemon/dist/routes/queue.d.ts +10 -0
  563. package/daemon/dist/routes/queue.d.ts.map +1 -0
  564. package/daemon/dist/routes/queue.js +425 -0
  565. package/daemon/dist/routes/queue.js.map +1 -0
  566. package/daemon/dist/routes/restore-check.d.ts +3 -0
  567. package/daemon/dist/routes/restore-check.d.ts.map +1 -0
  568. package/daemon/dist/routes/restore-check.js +200 -0
  569. package/daemon/dist/routes/restore-check.js.map +1 -0
  570. package/daemon/dist/routes/rigs.d.ts +3 -0
  571. package/daemon/dist/routes/rigs.d.ts.map +1 -1
  572. package/daemon/dist/routes/rigs.js +131 -9
  573. package/daemon/dist/routes/rigs.js.map +1 -1
  574. package/daemon/dist/routes/rigspec.js +6 -3
  575. package/daemon/dist/routes/rigspec.js.map +1 -1
  576. package/daemon/dist/routes/seat.d.ts +3 -0
  577. package/daemon/dist/routes/seat.d.ts.map +1 -0
  578. package/daemon/dist/routes/seat.js +69 -0
  579. package/daemon/dist/routes/seat.js.map +1 -0
  580. package/daemon/dist/routes/sessions.d.ts.map +1 -1
  581. package/daemon/dist/routes/sessions.js +144 -4
  582. package/daemon/dist/routes/sessions.js.map +1 -1
  583. package/daemon/dist/routes/slices.d.ts +9 -0
  584. package/daemon/dist/routes/slices.d.ts.map +1 -0
  585. package/daemon/dist/routes/slices.js +192 -0
  586. package/daemon/dist/routes/slices.js.map +1 -0
  587. package/daemon/dist/routes/snapshots.js +66 -29
  588. package/daemon/dist/routes/snapshots.js.map +1 -1
  589. package/daemon/dist/routes/spec-library.d.ts.map +1 -1
  590. package/daemon/dist/routes/spec-library.js +72 -5
  591. package/daemon/dist/routes/spec-library.js.map +1 -1
  592. package/daemon/dist/routes/steering.d.ts +7 -0
  593. package/daemon/dist/routes/steering.d.ts.map +1 -0
  594. package/daemon/dist/routes/steering.js +27 -0
  595. package/daemon/dist/routes/steering.js.map +1 -0
  596. package/daemon/dist/routes/stream.d.ts +9 -0
  597. package/daemon/dist/routes/stream.d.ts.map +1 -0
  598. package/daemon/dist/routes/stream.js +119 -0
  599. package/daemon/dist/routes/stream.js.map +1 -0
  600. package/daemon/dist/routes/transcripts.d.ts.map +1 -1
  601. package/daemon/dist/routes/transcripts.js +38 -0
  602. package/daemon/dist/routes/transcripts.js.map +1 -1
  603. package/daemon/dist/routes/transport.d.ts.map +1 -1
  604. package/daemon/dist/routes/transport.js +21 -0
  605. package/daemon/dist/routes/transport.js.map +1 -1
  606. package/daemon/dist/routes/up.d.ts.map +1 -1
  607. package/daemon/dist/routes/up.js +43 -4
  608. package/daemon/dist/routes/up.js.map +1 -1
  609. package/daemon/dist/routes/views.d.ts +13 -0
  610. package/daemon/dist/routes/views.d.ts.map +1 -0
  611. package/daemon/dist/routes/views.js +120 -0
  612. package/daemon/dist/routes/views.js.map +1 -0
  613. package/daemon/dist/routes/watchdog.d.ts +18 -0
  614. package/daemon/dist/routes/watchdog.d.ts.map +1 -0
  615. package/daemon/dist/routes/watchdog.js +148 -0
  616. package/daemon/dist/routes/watchdog.js.map +1 -0
  617. package/daemon/dist/routes/whoami.d.ts.map +1 -1
  618. package/daemon/dist/routes/whoami.js +6 -1
  619. package/daemon/dist/routes/whoami.js.map +1 -1
  620. package/daemon/dist/routes/workflow.d.ts +20 -0
  621. package/daemon/dist/routes/workflow.d.ts.map +1 -0
  622. package/daemon/dist/routes/workflow.js +227 -0
  623. package/daemon/dist/routes/workflow.js.map +1 -0
  624. package/daemon/dist/routes/workspace.d.ts +3 -0
  625. package/daemon/dist/routes/workspace.d.ts.map +1 -0
  626. package/daemon/dist/routes/workspace.js +53 -0
  627. package/daemon/dist/routes/workspace.js.map +1 -0
  628. package/daemon/dist/server.d.ts +81 -0
  629. package/daemon/dist/server.d.ts.map +1 -1
  630. package/daemon/dist/server.js +85 -1
  631. package/daemon/dist/server.js.map +1 -1
  632. package/daemon/dist/startup.d.ts +9 -0
  633. package/daemon/dist/startup.d.ts.map +1 -1
  634. package/daemon/dist/startup.js +585 -8
  635. package/daemon/dist/startup.js.map +1 -1
  636. package/daemon/docs/reference/agent-spec.md +19 -12
  637. package/daemon/docs/reference/agent-startup-guide.md +11 -11
  638. package/daemon/docs/reference/project-workspace.md +102 -0
  639. package/daemon/specs/agents/apps/vault-specialist/agent.yaml +2 -2
  640. package/daemon/specs/agents/apps/vault-specialist/guidance/role.md +0 -1
  641. package/daemon/specs/agents/conveyor/builder/agent.yaml +35 -0
  642. package/daemon/specs/agents/conveyor/builder/guidance/role.md +31 -0
  643. package/daemon/specs/agents/conveyor/builder/startup/context.md +9 -0
  644. package/daemon/specs/agents/conveyor/lead/agent.yaml +35 -0
  645. package/daemon/specs/agents/conveyor/lead/guidance/role.md +34 -0
  646. package/daemon/specs/agents/conveyor/lead/startup/context.md +15 -0
  647. package/daemon/specs/agents/conveyor/planner/agent.yaml +35 -0
  648. package/daemon/specs/agents/conveyor/planner/guidance/role.md +29 -0
  649. package/daemon/specs/agents/conveyor/planner/startup/context.md +12 -0
  650. package/daemon/specs/agents/conveyor/reviewer/agent.yaml +35 -0
  651. package/daemon/specs/agents/conveyor/reviewer/guidance/role.md +29 -0
  652. package/daemon/specs/agents/conveyor/reviewer/startup/context.md +10 -0
  653. package/daemon/specs/agents/design/product-designer/agent.yaml +1 -1
  654. package/daemon/specs/agents/development/implementer/agent.yaml +2 -2
  655. package/daemon/specs/agents/development/implementer/guidance/role.md +0 -1
  656. package/daemon/specs/agents/development/qa/agent.yaml +1 -1
  657. package/daemon/specs/agents/orchestration/orchestrator/agent.yaml +2 -2
  658. package/daemon/specs/agents/orchestration/orchestrator/guidance/role.md +2 -3
  659. package/daemon/specs/agents/product-management/pm/agent.yaml +4 -0
  660. package/daemon/specs/agents/research/analyst/agent.yaml +1 -1
  661. package/daemon/specs/agents/research/synthesizer/agent.yaml +1 -1
  662. package/daemon/specs/agents/review/independent-reviewer/agent.yaml +1 -1
  663. package/daemon/specs/agents/shared/agent.yaml +17 -2
  664. package/daemon/specs/agents/shared/runtime/claude-mcp.fragment.json +12 -0
  665. package/daemon/specs/agents/shared/runtime/claude-settings.fragment.json +16 -0
  666. package/daemon/specs/agents/shared/runtime/codex-config.fragment.toml +5 -0
  667. package/daemon/specs/agents/shared/skills/claude-compact-in-place/SKILL.md +100 -0
  668. package/daemon/specs/agents/shared/skills/core/openrig-operator/SKILL.md +110 -0
  669. package/daemon/specs/agents/shared/skills/core/openrig-user/SKILL.md +69 -1
  670. package/daemon/specs/agents/shared/skills/core/openrig-user-settings/SKILL.md +153 -0
  671. package/daemon/specs/agents/shared/skills/pods/orchestration-team/SKILL.md +3 -0
  672. package/daemon/specs/agents/shared/skills/rig-architect/SKILL.md +11 -1
  673. package/daemon/specs/rigs/launch/conveyor/CULTURE.md +34 -0
  674. package/daemon/specs/rigs/launch/conveyor/README.md +33 -0
  675. package/daemon/specs/rigs/launch/conveyor/rig.yaml +72 -0
  676. package/daemon/specs/rigs/preview/product-team/CULTURE.md +2 -2
  677. package/daemon/specs/rigs/preview/product-team/rig.yaml +3 -4
  678. package/dist/bin-wrapper.js +0 -0
  679. package/dist/commands/agent-image.d.ts +4 -0
  680. package/dist/commands/agent-image.d.ts.map +1 -0
  681. package/dist/commands/agent-image.js +352 -0
  682. package/dist/commands/agent-image.js.map +1 -0
  683. package/dist/commands/capture.d.ts +7 -1
  684. package/dist/commands/capture.d.ts.map +1 -1
  685. package/dist/commands/capture.js +59 -1
  686. package/dist/commands/capture.js.map +1 -1
  687. package/dist/commands/compact-plan.d.ts +9 -0
  688. package/dist/commands/compact-plan.d.ts.map +1 -0
  689. package/dist/commands/compact-plan.js +354 -0
  690. package/dist/commands/compact-plan.js.map +1 -0
  691. package/dist/commands/config-init-workspace.d.ts +35 -0
  692. package/dist/commands/config-init-workspace.d.ts.map +1 -0
  693. package/dist/commands/config-init-workspace.js +300 -0
  694. package/dist/commands/config-init-workspace.js.map +1 -0
  695. package/dist/commands/config.d.ts.map +1 -1
  696. package/dist/commands/config.js +78 -18
  697. package/dist/commands/config.js.map +1 -1
  698. package/dist/commands/context-pack.d.ts +4 -0
  699. package/dist/commands/context-pack.d.ts.map +1 -0
  700. package/dist/commands/context-pack.js +357 -0
  701. package/dist/commands/context-pack.js.map +1 -0
  702. package/dist/commands/context.d.ts +9 -0
  703. package/dist/commands/context.d.ts.map +1 -0
  704. package/dist/commands/context.js +220 -0
  705. package/dist/commands/context.js.map +1 -0
  706. package/dist/commands/daemon.d.ts.map +1 -1
  707. package/dist/commands/daemon.js +8 -0
  708. package/dist/commands/daemon.js.map +1 -1
  709. package/dist/commands/expand.d.ts.map +1 -1
  710. package/dist/commands/expand.js +15 -4
  711. package/dist/commands/expand.js.map +1 -1
  712. package/dist/commands/heartbeat.d.ts +99 -0
  713. package/dist/commands/heartbeat.d.ts.map +1 -0
  714. package/dist/commands/heartbeat.js +393 -0
  715. package/dist/commands/heartbeat.js.map +1 -0
  716. package/dist/commands/import.d.ts.map +1 -1
  717. package/dist/commands/import.js +7 -2
  718. package/dist/commands/import.js.map +1 -1
  719. package/dist/commands/project.d.ts +14 -0
  720. package/dist/commands/project.d.ts.map +1 -0
  721. package/dist/commands/project.js +157 -0
  722. package/dist/commands/project.js.map +1 -0
  723. package/dist/commands/ps.d.ts +20 -3
  724. package/dist/commands/ps.d.ts.map +1 -1
  725. package/dist/commands/ps.js +614 -33
  726. package/dist/commands/ps.js.map +1 -1
  727. package/dist/commands/queue.d.ts +16 -0
  728. package/dist/commands/queue.d.ts.map +1 -0
  729. package/dist/commands/queue.js +410 -0
  730. package/dist/commands/queue.js.map +1 -0
  731. package/dist/commands/restore-check.d.ts +9 -0
  732. package/dist/commands/restore-check.d.ts.map +1 -0
  733. package/dist/commands/restore-check.js +234 -0
  734. package/dist/commands/restore-check.js.map +1 -0
  735. package/dist/commands/restore-packet.d.ts +9 -0
  736. package/dist/commands/restore-packet.d.ts.map +1 -0
  737. package/dist/commands/restore-packet.js +383 -0
  738. package/dist/commands/restore-packet.js.map +1 -0
  739. package/dist/commands/restore.d.ts.map +1 -1
  740. package/dist/commands/restore.js +44 -1
  741. package/dist/commands/restore.js.map +1 -1
  742. package/dist/commands/seat.d.ts +5 -0
  743. package/dist/commands/seat.d.ts.map +1 -0
  744. package/dist/commands/seat.js +170 -0
  745. package/dist/commands/seat.js.map +1 -0
  746. package/dist/commands/send.d.ts +19 -1
  747. package/dist/commands/send.d.ts.map +1 -1
  748. package/dist/commands/send.js +116 -5
  749. package/dist/commands/send.js.map +1 -1
  750. package/dist/commands/setup.js +3 -3
  751. package/dist/commands/setup.js.map +1 -1
  752. package/dist/commands/specs.d.ts +4 -2
  753. package/dist/commands/specs.d.ts.map +1 -1
  754. package/dist/commands/specs.js +111 -24
  755. package/dist/commands/specs.js.map +1 -1
  756. package/dist/commands/stream.d.ts +12 -0
  757. package/dist/commands/stream.d.ts.map +1 -0
  758. package/dist/commands/stream.js +111 -0
  759. package/dist/commands/stream.js.map +1 -0
  760. package/dist/commands/up.d.ts.map +1 -1
  761. package/dist/commands/up.js +79 -5
  762. package/dist/commands/up.js.map +1 -1
  763. package/dist/commands/view.d.ts +12 -0
  764. package/dist/commands/view.d.ts.map +1 -0
  765. package/dist/commands/view.js +82 -0
  766. package/dist/commands/view.js.map +1 -0
  767. package/dist/commands/watchdog.d.ts +15 -0
  768. package/dist/commands/watchdog.d.ts.map +1 -0
  769. package/dist/commands/watchdog.js +120 -0
  770. package/dist/commands/watchdog.js.map +1 -0
  771. package/dist/commands/whoami.d.ts +8 -1
  772. package/dist/commands/whoami.d.ts.map +1 -1
  773. package/dist/commands/whoami.js +69 -5
  774. package/dist/commands/whoami.js.map +1 -1
  775. package/dist/commands/workflow.d.ts +17 -0
  776. package/dist/commands/workflow.d.ts.map +1 -0
  777. package/dist/commands/workflow.js +175 -0
  778. package/dist/commands/workflow.js.map +1 -0
  779. package/dist/commands/workspace.d.ts +6 -0
  780. package/dist/commands/workspace.d.ts.map +1 -0
  781. package/dist/commands/workspace.js +83 -0
  782. package/dist/commands/workspace.js.map +1 -0
  783. package/dist/config-store.d.ts +73 -1
  784. package/dist/config-store.d.ts.map +1 -1
  785. package/dist/config-store.js +314 -42
  786. package/dist/config-store.js.map +1 -1
  787. package/dist/cross-host-cli-helpers.d.ts +12 -0
  788. package/dist/cross-host-cli-helpers.d.ts.map +1 -0
  789. package/dist/cross-host-cli-helpers.js +48 -0
  790. package/dist/cross-host-cli-helpers.js.map +1 -0
  791. package/dist/cross-host-executor.d.ts +84 -0
  792. package/dist/cross-host-executor.d.ts.map +1 -0
  793. package/dist/cross-host-executor.js +138 -0
  794. package/dist/cross-host-executor.js.map +1 -0
  795. package/dist/daemon-lifecycle.d.ts +22 -0
  796. package/dist/daemon-lifecycle.d.ts.map +1 -1
  797. package/dist/daemon-lifecycle.js +41 -0
  798. package/dist/daemon-lifecycle.js.map +1 -1
  799. package/dist/host-registry.d.ts +50 -0
  800. package/dist/host-registry.d.ts.map +1 -0
  801. package/dist/host-registry.js +116 -0
  802. package/dist/host-registry.js.map +1 -0
  803. package/dist/index.d.ts +24 -0
  804. package/dist/index.d.ts.map +1 -1
  805. package/dist/index.js +30 -0
  806. package/dist/index.js.map +1 -1
  807. package/dist/mcp-server.d.ts.map +1 -1
  808. package/dist/mcp-server.js +22 -2
  809. package/dist/mcp-server.js.map +1 -1
  810. package/dist/openrig-compat.d.ts +1 -1
  811. package/dist/openrig-compat.d.ts.map +1 -1
  812. package/dist/openrig-compat.js +6 -4
  813. package/dist/openrig-compat.js.map +1 -1
  814. package/dist/restore-packet/claude-transcript-parser.d.ts +12 -0
  815. package/dist/restore-packet/claude-transcript-parser.d.ts.map +1 -0
  816. package/dist/restore-packet/claude-transcript-parser.js +221 -0
  817. package/dist/restore-packet/claude-transcript-parser.js.map +1 -0
  818. package/dist/restore-packet/codex-jsonl-parser.d.ts +11 -0
  819. package/dist/restore-packet/codex-jsonl-parser.d.ts.map +1 -0
  820. package/dist/restore-packet/codex-jsonl-parser.js +159 -0
  821. package/dist/restore-packet/codex-jsonl-parser.js.map +1 -0
  822. package/dist/restore-packet/omitted-records.d.ts +60 -0
  823. package/dist/restore-packet/omitted-records.d.ts.map +1 -0
  824. package/dist/restore-packet/omitted-records.js +116 -0
  825. package/dist/restore-packet/omitted-records.js.map +1 -0
  826. package/dist/restore-packet/packet-writer.d.ts +59 -0
  827. package/dist/restore-packet/packet-writer.d.ts.map +1 -0
  828. package/dist/restore-packet/packet-writer.js +224 -0
  829. package/dist/restore-packet/packet-writer.js.map +1 -0
  830. package/dist/restore-packet/redaction.d.ts +30 -0
  831. package/dist/restore-packet/redaction.d.ts.map +1 -0
  832. package/dist/restore-packet/redaction.js +71 -0
  833. package/dist/restore-packet/redaction.js.map +1 -0
  834. package/dist/restore-packet/runtime-detect.d.ts +19 -0
  835. package/dist/restore-packet/runtime-detect.d.ts.map +1 -0
  836. package/dist/restore-packet/runtime-detect.js +81 -0
  837. package/dist/restore-packet/runtime-detect.js.map +1 -0
  838. package/dist/restore-packet/schema-validator.d.ts +13 -0
  839. package/dist/restore-packet/schema-validator.d.ts.map +1 -0
  840. package/dist/restore-packet/schema-validator.js +245 -0
  841. package/dist/restore-packet/schema-validator.js.map +1 -0
  842. package/dist/restore-packet/types.d.ts +76 -0
  843. package/dist/restore-packet/types.d.ts.map +1 -0
  844. package/dist/restore-packet/types.js +15 -0
  845. package/dist/restore-packet/types.js.map +1 -0
  846. package/dist/schemas/restore-summary.schema.json +98 -0
  847. package/package.json +10 -3
  848. package/scripts/check-abi.mjs +123 -0
  849. package/ui/dist/assets/index-BDHU1JUK.js +412 -0
  850. package/ui/dist/assets/index-DXTyJSqu.css +1 -0
  851. package/ui/dist/graphics/operator-climber-monochrome.png +0 -0
  852. package/ui/dist/index.html +3 -2
  853. package/daemon/specs/agents/shared/skills/mental-model-ha/SKILL.md +0 -953
  854. package/ui/dist/assets/index-B09doO8H.js +0 -139
  855. package/ui/dist/assets/index-Ccd-jwRN.js +0 -225
  856. package/ui/dist/assets/index-DlMH-REm.css +0 -1
@@ -0,0 +1 @@
1
+ {"version":3,"file":"notification-dispatcher.d.ts","sourceRoot":"","sources":["../../../src/domain/mission-control/notification-dispatcher.ts"],"names":[],"mappings":"AAkBA,OAAO,KAAK,QAAQ,MAAM,gBAAgB,CAAC;AAC3C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAEhD,OAAO,KAAK,EACV,mBAAmB,EAEpB,MAAM,iCAAiC,CAAC;AAEzC,MAAM,WAAW,0BAA0B;IACzC,EAAE,EAAE,QAAQ,CAAC,QAAQ,CAAC;IACtB,QAAQ,EAAE,QAAQ,CAAC;IACnB,OAAO,EAAE,mBAAmB,CAAC;IAC7B;;;;OAIG;IACH,qBAAqB,CAAC,EAAE,OAAO,CAAC;IAChC,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAC/B,GAAG,CAAC,EAAE,MAAM,IAAI,CAAC;CAClB;AAUD,qBAAa,oCAAoC;IAC/C,OAAO,CAAC,QAAQ,CAAC,EAAE,CAAoB;IACvC,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAW;IACpC,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAsB;IAC9C,OAAO,CAAC,QAAQ,CAAC,qBAAqB,CAAU;IAChD,OAAO,CAAC,QAAQ,CAAC,qBAAqB,CAAgB;IACtD,OAAO,CAAC,QAAQ,CAAC,GAAG,CAAa;IACjC,OAAO,CAAC,WAAW,CAA6B;IAChD,mEAAmE;IACnE,OAAO,CAAC,QAAQ,CAAC,cAAc,CAAqB;gBAExC,IAAI,EAAE,0BAA0B;IAS5C,yDAAyD;IACzD,KAAK,IAAI,IAAI;IAOb,iDAAiD;IACjD,IAAI,IAAI,IAAI;IAQZ;;;;OAIG;IACG,QAAQ,IAAI,OAAO,CAAC;QACxB,SAAS,EAAE,MAAM,CAAC;QAClB,MAAM,EAAE,MAAM,CAAC;QACf,EAAE,EAAE,OAAO,CAAC;QACZ,GAAG,CAAC,EAAE,MAAM,CAAC;QACb,KAAK,CAAC,EAAE,MAAM,CAAC;KAChB,CAAC;YAqBY,WAAW;YA4BX,QAAQ;IA0BtB,OAAO,CAAC,QAAQ;IAUhB,OAAO,CAAC,UAAU;IAWlB,OAAO,CAAC,WAAW;IAUnB,OAAO,CAAC,QAAQ;IAShB,0DAA0D;IAC1D,iBAAiB,IAAI,IAAI;CAG1B"}
@@ -0,0 +1,181 @@
1
+ // PL-005 Phase B: Mission Control notification dispatcher.
2
+ //
3
+ // Subscribes to relevant events on the EventBus and POSTs through the
4
+ // configured notification adapter (ntfy default; webhook alternate).
5
+ // Best-effort delivery; failure does NOT interrupt the underlying
6
+ // action being notified about (PRD invariant). Emits `mission_control
7
+ // .notification_sent` / `_failed` for the audit trail.
8
+ //
9
+ // Triggers (Phase B v0):
10
+ // - Mandatory: human-gate qitem arrival. Detected via the
11
+ // `queue.created` event (Phase A coordination event) where the
12
+ // created qitem's tier == "human-gate".
13
+ // - Optional: verb completion. When opts.includeVerbCompletion is
14
+ // true, `mission_control.action_executed` events also dispatch.
15
+ //
16
+ // Single notification target (the operator's phone). MVP context:
17
+ // no multi-user routing, no per-user opt-in matrix.
18
+ export class MissionControlNotificationDispatcher {
19
+ db;
20
+ eventBus;
21
+ adapter;
22
+ includeVerbCompletion;
23
+ missionControlBaseUrl;
24
+ now;
25
+ unsubscribe = null;
26
+ /** Per-(qitem_id, mechanism) drop set for once-per-qitem dedup. */
27
+ dispatchedKeys = new Set();
28
+ constructor(deps) {
29
+ this.db = deps.db;
30
+ this.eventBus = deps.eventBus;
31
+ this.adapter = deps.adapter;
32
+ this.includeVerbCompletion = Boolean(deps.includeVerbCompletion);
33
+ this.missionControlBaseUrl = normalizeBaseUrl(deps.missionControlBaseUrl);
34
+ this.now = deps.now ?? (() => new Date());
35
+ }
36
+ /** Subscribe to relevant EventBus events. Idempotent. */
37
+ start() {
38
+ if (this.unsubscribe)
39
+ return;
40
+ this.unsubscribe = this.eventBus.subscribe((event) => {
41
+ void this.handleEvent(event);
42
+ });
43
+ }
44
+ /** Unsubscribe + clear dedup set. Idempotent. */
45
+ stop() {
46
+ if (this.unsubscribe) {
47
+ this.unsubscribe();
48
+ this.unsubscribe = null;
49
+ }
50
+ this.dispatchedKeys.clear();
51
+ }
52
+ /**
53
+ * Send a synthetic notification through the configured adapter so
54
+ * the operator can verify their setup. Used by the
55
+ * `POST /api/mission-control/notifications/test` route.
56
+ */
57
+ async sendTest() {
58
+ const payload = {
59
+ title: "Mission Control test notification",
60
+ body: `Synthetic test from OpenRig daemon at ${this.now().toISOString()}`,
61
+ tags: ["openrig", "mission-control", "test"],
62
+ };
63
+ const result = await this.adapter.send(payload);
64
+ if (result.ok) {
65
+ this.emitSent(null, "test");
66
+ }
67
+ else {
68
+ this.emitFailed(null, result.error ?? "unknown");
69
+ }
70
+ return {
71
+ mechanism: this.adapter.mechanism,
72
+ target: this.adapter.target,
73
+ ok: result.ok,
74
+ ack: result.ack,
75
+ error: result.error,
76
+ };
77
+ }
78
+ async handleEvent(event) {
79
+ if (event.type === "queue.created") {
80
+ const qitem = this.lookupQitem(event.qitemId);
81
+ if (!qitem || qitem.tier !== "human-gate")
82
+ return;
83
+ // Mandatory trigger: human-gate qitem arrival.
84
+ await this.dispatch({
85
+ triggerKind: "human-gate-arrival",
86
+ qitemId: qitem.qitem_id,
87
+ title: "human-gate qitem arrived",
88
+ body: `New human-gate qitem ${qitem.qitem_id} from ${qitem.source_session} → ${qitem.destination_session}\n\n` +
89
+ truncateBody(qitem.body, 280),
90
+ tags: ["openrig", "mission-control", "human-gate"],
91
+ });
92
+ return;
93
+ }
94
+ if (event.type === "mission_control.action_executed" && this.includeVerbCompletion) {
95
+ await this.dispatch({
96
+ triggerKind: "verb-completion",
97
+ qitemId: event.qitemId,
98
+ title: `verb completed: ${event.actionVerb}`,
99
+ body: `Mission Control verb ${event.actionVerb} on qitem ${event.qitemId ?? "(none)"} by ${event.actorSession}`,
100
+ tags: ["openrig", "mission-control", "verb-complete"],
101
+ });
102
+ return;
103
+ }
104
+ }
105
+ async dispatch(input) {
106
+ const dedupKey = `${input.qitemId ?? "no-qitem"}::${input.triggerKind}::${this.adapter.mechanism}`;
107
+ if (this.dispatchedKeys.has(dedupKey))
108
+ return;
109
+ this.dispatchedKeys.add(dedupKey);
110
+ const result = await this.adapter.send({
111
+ title: input.title,
112
+ body: input.body,
113
+ qitemRef: this.qitemRef(input.qitemId),
114
+ tags: input.tags,
115
+ });
116
+ if (result.ok) {
117
+ this.emitSent(input.qitemId, result.ack ?? "ok");
118
+ }
119
+ else {
120
+ this.emitFailed(input.qitemId, result.error ?? "unknown");
121
+ }
122
+ }
123
+ emitSent(qitemId, _ack) {
124
+ this.eventBus.emit({
125
+ type: "mission_control.notification_sent",
126
+ mechanism: this.adapter.mechanism,
127
+ target: this.adapter.target,
128
+ qitemId,
129
+ sentAt: this.now().toISOString(),
130
+ });
131
+ }
132
+ emitFailed(qitemId, error) {
133
+ this.eventBus.emit({
134
+ type: "mission_control.notification_failed",
135
+ mechanism: this.adapter.mechanism,
136
+ target: this.adapter.target,
137
+ qitemId,
138
+ error,
139
+ failedAt: this.now().toISOString(),
140
+ });
141
+ }
142
+ lookupQitem(qitemId) {
143
+ const row = this.db
144
+ .prepare(`SELECT qitem_id, source_session, destination_session, tier, body
145
+ FROM queue_items WHERE qitem_id = ? LIMIT 1`)
146
+ .get(qitemId);
147
+ return row ?? null;
148
+ }
149
+ qitemRef(qitemId) {
150
+ if (!qitemId)
151
+ return undefined;
152
+ if (!this.missionControlBaseUrl)
153
+ return qitemId;
154
+ const url = new URL("/mission-control", this.missionControlBaseUrl);
155
+ url.searchParams.set("view", "human-gate");
156
+ url.searchParams.set("qitem", qitemId);
157
+ return url.toString();
158
+ }
159
+ /** Test/observability: clear once-per-qitem dedup set. */
160
+ resetDedupForTest() {
161
+ this.dispatchedKeys.clear();
162
+ }
163
+ }
164
+ function truncateBody(s, max) {
165
+ if (s.length <= max)
166
+ return s;
167
+ return s.slice(0, max - 1) + "…";
168
+ }
169
+ function normalizeBaseUrl(raw) {
170
+ const trimmed = raw?.trim();
171
+ if (!trimmed)
172
+ return null;
173
+ try {
174
+ const url = new URL(trimmed);
175
+ return url.toString();
176
+ }
177
+ catch {
178
+ return null;
179
+ }
180
+ }
181
+ //# sourceMappingURL=notification-dispatcher.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"notification-dispatcher.js","sourceRoot":"","sources":["../../../src/domain/mission-control/notification-dispatcher.ts"],"names":[],"mappings":"AAAA,2DAA2D;AAC3D,EAAE;AACF,sEAAsE;AACtE,qEAAqE;AACrE,kEAAkE;AAClE,sEAAsE;AACtE,uDAAuD;AACvD,EAAE;AACF,yBAAyB;AACzB,4DAA4D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AAI,CAAC,qBAAqB;YAAE,OAAO,OAAO,CAAC;QAChD,MAAM,GAAG,GAAG,IAAI,GAAG,CAAC,kBAAkB,EAAE,IAAI,CAAC,qBAAqB,CAAC,CAAC;QACpE,GAAG,CAAC,YAAY,CAAC,GAAG,CAAC,MAAM,EAAE,YAAY,CAAC,CAAC;QAC3C,GAAG,CAAC,YAAY,CAAC,GAAG,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;QACvC,OAAO,GAAG,CAAC,QAAQ,EAAE,CAAC;IACxB,CAAC;IAED,0DAA0D;IAC1D,iBAAiB;QACf,IAAI,CAAC,cAAc,CAAC,KAAK,EAAE,CAAC;IAC9B,CAAC;CACF;AAED,SAAS,YAAY,CAAC,CAAS,EAAE,GAAW;IAC1C,IAAI,CAAC,CAAC,MAAM,IAAI,GAAG;QAAE,OAAO,CAAC,CAAC;IAC9B,OAAO,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,GAAG,GAAG,CAAC,CAAC,GAAG,GAAG,CAAC;AACnC,CAAC;AAED,SAAS,gBAAgB,CAAC,GAAuB;IAC/C,MAAM,OAAO,GAAG,GAAG,EAAE,IAAI,EAAE,CAAC;IAC5B,IAAI,CAAC,OAAO;QAAE,OAAO,IAAI,CAAC;IAC1B,IAAI,CAAC;QACH,MAAM,GAAG,GAAG,IAAI,GAAG,CAAC,OAAO,CAAC,CAAC;QAC7B,OAAO,GAAG,CAAC,QAAQ,EAAE,CAAC;IACxB,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,IAAI,CAAC;IACd,CAAC;AACH,CAAC"}
@@ -1,4 +1,4 @@
1
- export type NativeResumeProbeStatus = "resumed" | "failed" | "inconclusive";
1
+ export type NativeResumeProbeStatus = "resumed" | "failed" | "inconclusive" | "attention_required";
2
2
  export interface NativeResumeProbeInput {
3
3
  runtime: string | null;
4
4
  paneCommand: string | null;
@@ -1 +1 @@
1
- {"version":3,"file":"native-resume-probe.d.ts","sourceRoot":"","sources":["../../src/domain/native-resume-probe.ts"],"names":[],"mappings":"AAEA,MAAM,MAAM,uBAAuB,GAAG,SAAS,GAAG,QAAQ,GAAG,cAAc,CAAC;AAE5E,MAAM,WAAW,sBAAsB;IACrC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;CAC5B;AAED,MAAM,WAAW,uBAAuB;IACtC,MAAM,EAAE,uBAAuB,CAAC;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,oBAAoB;IACnC,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;CAC5B;AAID,wBAAgB,wBAAwB,CACtC,OAAO,EAAE,MAAM,GAAG,IAAI,EACtB,WAAW,EAAE,MAAM,GAAG,IAAI,EAC1B,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,GAC1B,MAAM,GAAG,IAAI,CAUf;AAED,wBAAgB,uBAAuB,CACrC,KAAK,EAAE,sBAAsB,GAC5B,uBAAuB,CAqHzB;AAED,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,oBAAoB,GAAG,OAAO,CAItE"}
1
+ {"version":3,"file":"native-resume-probe.d.ts","sourceRoot":"","sources":["../../src/domain/native-resume-probe.ts"],"names":[],"mappings":"AAKA,MAAM,MAAM,uBAAuB,GAAG,SAAS,GAAG,QAAQ,GAAG,cAAc,GAAG,oBAAoB,CAAC;AAEnG,MAAM,WAAW,sBAAsB;IACrC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;CAC5B;AAED,MAAM,WAAW,uBAAuB;IACtC,MAAM,EAAE,uBAAuB,CAAC;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,oBAAoB;IACnC,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;CAC5B;AAID,wBAAgB,wBAAwB,CACtC,OAAO,EAAE,MAAM,GAAG,IAAI,EACtB,WAAW,EAAE,MAAM,GAAG,IAAI,EAC1B,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,GAC1B,MAAM,GAAG,IAAI,CAUf;AAED,wBAAgB,uBAAuB,CACrC,KAAK,EAAE,sBAAsB,GAC5B,uBAAuB,CA0IzB;AAED,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,oBAAoB,GAAG,OAAO,CAItE"}
@@ -24,6 +24,13 @@ export function assessNativeResumeProbe(input) {
24
24
  detail: "Claude reported that the requested session no longer exists.",
25
25
  };
26
26
  }
27
+ if (looksLikeClaudeResumeSelectionPrompt(paneContent)) {
28
+ return {
29
+ status: "attention_required",
30
+ code: "claude_resume_selection_prompt",
31
+ detail: "Claude is at a resume-selection prompt; an operator must choose the conversation to continue.",
32
+ };
33
+ }
27
34
  if (looksLikeClaudeTrustPrompt(paneContent)) {
28
35
  return {
29
36
  status: "inconclusive",
@@ -80,6 +87,13 @@ export function assessNativeResumeProbe(input) {
80
87
  detail: "Codex reported that the requested saved session does not exist.",
81
88
  };
82
89
  }
90
+ if (looksLikeCodexAuthRefusal(paneContent)) {
91
+ return {
92
+ status: "attention_required",
93
+ code: "codex_auth_refusal",
94
+ detail: "Codex could not refresh the stored access token; an operator must sign in again before the session can resume.",
95
+ };
96
+ }
83
97
  if (looksLikeCodexTrustPrompt(paneContent)) {
84
98
  return {
85
99
  status: "inconclusive",
@@ -87,6 +101,13 @@ export function assessNativeResumeProbe(input) {
87
101
  detail: "Codex is waiting for workspace trust approval before the session can become interactive.",
88
102
  };
89
103
  }
104
+ if (looksLikeCodexModelSelectionPrompt(paneContent)) {
105
+ return {
106
+ status: "inconclusive",
107
+ code: "model_selection_gate",
108
+ detail: "Codex is waiting for model selection before the session can become interactive.",
109
+ };
110
+ }
90
111
  if (looksLikeCodexTui(paneContent)) {
91
112
  return {
92
113
  status: "resumed",
@@ -143,6 +164,27 @@ function looksLikeClaudeTrustPrompt(paneContent) {
143
164
  return paneContent.includes("Accessing workspace:")
144
165
  && paneContent.includes("Yes, I trust this folder");
145
166
  }
167
+ // Claude's resume-selection prompt appears when `claude --resume` finds multiple
168
+ // candidate conversations (or after a reboot when the conversation index is
169
+ // rebuilt). The prompt lists numbered options and asks the operator to pick.
170
+ //
171
+ // L3 invariant: do NOT auto-answer. Surface as `attention_required` and let an
172
+ // operator choose; later reconciliation upgrades to `operator_recovered` only
173
+ // when the operator reaches a usable state.
174
+ function looksLikeClaudeResumeSelectionPrompt(paneContent) {
175
+ // Stable substring is the explicit "Choose ... conversation" verb plus the
176
+ // numbered/arrow option marker that Claude prints. Both must be present so
177
+ // we don't false-positive on similar TUI strings.
178
+ const hasChooseVerb = paneContent.includes("Choose a conversation")
179
+ || paneContent.includes("Choose the conversation")
180
+ || paneContent.includes("Select a conversation");
181
+ if (!hasChooseVerb)
182
+ return false;
183
+ // Look for the numbered/arrow option marker in recent lines.
184
+ const recentLines = paneContent.split("\n").slice(-30);
185
+ const numberedOption = recentLines.some((line) => /^\s*(?:›\s*)?\d+\.\s+\S/.test(line));
186
+ return numberedOption;
187
+ }
146
188
  function looksLikeClaudeLoginPrompt(paneContent) {
147
189
  return paneContent.includes("Not logged in")
148
190
  && paneContent.includes("Run /login");
@@ -161,8 +203,33 @@ function looksLikeCodexTui(paneContent) {
161
203
  const hasModelFooter = /(^|\n)\s{2,}gpt-[^\n]+ · [^\n]+(?:\n|$)/.test(recentLines);
162
204
  return hasPromptLine && hasModelFooter;
163
205
  }
206
+ // Codex prints these messages when its stored OAuth access token can no
207
+ // longer be refreshed — operator logged out elsewhere, account changed,
208
+ // device key revoked, etc. Operator recovers via `codex login`. Both
209
+ // anchors required: the access-token phrase distinguishes from generic
210
+ // errors; the operator-instruction phrase distinguishes from internal
211
+ // debug logs that may include the access-token phrase incidentally.
212
+ //
213
+ // Source verified at codex-cli 0.125.0 binary at
214
+ // /opt/homebrew/Caskroom/codex/0.125.0/codex-aarch64-apple-darwin:
215
+ // "Your access token could not be refreshed because you have since
216
+ // logged out or signed in to another account. Please sign in again."
217
+ // "Your access token could not be refreshed. Please log out and sign
218
+ // in again."
219
+ function looksLikeCodexAuthRefusal(paneContent) {
220
+ if (!paneContent.includes("access token could not be refreshed"))
221
+ return false;
222
+ return (paneContent.includes("Please sign in again")
223
+ || paneContent.includes("Please log out and sign in again"));
224
+ }
164
225
  function looksLikeCodexTrustPrompt(paneContent) {
165
226
  return paneContent.includes("Do you trust the contents of this directory?")
166
227
  && paneContent.includes("Yes, continue");
167
228
  }
229
+ function looksLikeCodexModelSelectionPrompt(paneContent) {
230
+ const recentLines = paneContent.split("\n").slice(-20);
231
+ const numberedModelOptions = recentLines.filter((line) => (/^\s*(?:›\s*)?\d+\.\s+/.test(line)
232
+ && /\bgpt-[\w.-]+\b/i.test(line)));
233
+ return numberedModelOptions.length >= 2;
234
+ }
168
235
  //# sourceMappingURL=native-resume-probe.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"native-resume-probe.js","sourceRoot":"","sources":["../../src/domain/native-resume-probe.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAqBxD,MAAM,cAAc,GAAG,IAAI,GAAG,CAAC,CAAC,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,CAAC,CAAC,CAAC;AAE5E,MAAM,UAAU,wBAAwB,CACtC,OAAsB,EACtB,WAA0B,EAC1B,WAA2B;IAE3B,IAAI,CAAC,WAAW;QAAE,OAAO,IAAI,CAAC;IAC9B,IAAI,OAAO,KAAK,aAAa,EAAE,CAAC;QAC9B,MAAM,UAAU,GAAG,WAAW,CAAC,CAAC,CAAC,WAAW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AG,yCAAyC,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;IAEnF,OAAO,aAAa,IAAI,cAAc,CAAC;AACzC,CAAC;AAED,wEAAwE;AACxE,wEAAwE;AACxE,qEAAqE;AACrE,uEAAuE;AACvE,sEAAsE;AACtE,oEAAoE;AACpE,EAAE;AACF,iDAAiD;AACjD,mEAAmE;AACnE,qEAAqE;AACrE,wEAAwE;AACxE,uEAAuE;AACvE,gBAAgB;AAChB,SAAS,yBAAyB,CAAC,WAAmB;IACpD,IAAI,CAAC,WAAW,CAAC,QAAQ,CAAC,qCAAqC,CAAC;QAAE,OAAO,KAAK,CAAC;IAC/E,OAAO,CACL,WAAW,CAAC,QAAQ,CAAC,sBAAsB,CAAC;WACzC,WAAW,CAAC,QAAQ,CAAC,kCAAkC,CAAC,CAC5D,CAAC;AACJ,CAAC;AAED,SAAS,yBAAyB,CAAC,WAAmB;IACpD,OAAO,WAAW,CAAC,QAAQ,CAAC,8CAA8C,CAAC;WACtE,WAAW,CAAC,QAAQ,CAAC,eAAe,CAAC,CAAC;AAC7C,CAAC;AAED,SAAS,kCAAkC,CAAC,WAAmB;IAC7D,MAAM,WAAW,GAAG,WAAW,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC;IACvD,MAAM,oBAAoB,GAAG,WAAW,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,CACxD,uBAAuB,CAAC,IAAI,CAAC,IAAI,CAAC;WAC/B,kBAAkB,CAAC,IAAI,CAAC,IAAI,CAAC,CACjC,CAAC,CAAC;IAEH,OAAO,oBAAoB,CAAC,MAAM,IAAI,CAAC,CAAC;AAC1C,CAAC"}
@@ -1,7 +1,30 @@
1
1
  import type Database from "better-sqlite3";
2
- import type { NodeInventoryEntry, NodeDetailEntry } from "./types.js";
2
+ import type { NodeInventoryEntry, NodeDetailEntry, NodeRestoreOutcome, NodeLifecycleState, Snapshot } from "./types.js";
3
3
  import type { RuntimeAdapter } from "./runtime-adapter.js";
4
4
  import type { ContextUsageStore } from "./context-usage-store.js";
5
+ import type { AgentActivityStore } from "./agent-activity-store.js";
6
+ import type { TmuxAdapter } from "../adapters/tmux.js";
7
+ /**
8
+ * Derives per-node lifecycle state from session/restore truth plus the rig's latest
9
+ * usable snapshot.
10
+ *
11
+ * Priorities (post-L2):
12
+ * attention_required — restoreOutcome=failed AND tmux session is alive
13
+ * (v0 proxy for the Claude resume-prompt case; revisited in L3).
14
+ * running — sessionStatus=running.
15
+ * recoverable — non-running session AND the latest usable snapshot has a
16
+ * non-null resume token for THIS node.
17
+ * detached — anything else (no session, exited, detached without resume token).
18
+ *
19
+ * Permission/IO failures upstream (L1 fail-closed) leave sessionStatus unchanged, so
20
+ * the projection stays honest without misclassifying ambiguous probe failures.
21
+ */
22
+ export declare function deriveNodeLifecycleState(input: {
23
+ sessionStatus: string | null;
24
+ restoreOutcome: NodeRestoreOutcome;
25
+ nodeId: string;
26
+ usableSnapshot: Snapshot | null;
27
+ }): NodeLifecycleState;
5
28
  /**
6
29
  * Get the canonical node inventory for a rig.
7
30
  * Single source of truth consumed by CLI, UI, and MCP.
@@ -30,4 +53,9 @@ export declare function getNodeInventoryWithContext(db: Database.Database, rigId
30
53
  * Context-aware wrapper: returns node detail with context usage attached.
31
54
  */
32
55
  export declare function getNodeDetailWithContext(db: Database.Database, rigId: string, logicalId: string, contextUsageStore: ContextUsageStore, opts?: Parameters<typeof getNodeDetail>[3]): NodeDetailEntry | null;
56
+ export declare function attachAgentActivity(entries: NodeInventoryEntry[], deps: {
57
+ tmuxAdapter: TmuxAdapter;
58
+ activityStore?: AgentActivityStore;
59
+ now?: Date;
60
+ }): Promise<NodeInventoryEntry[]>;
33
61
  //# sourceMappingURL=node-inventory.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"node-inventory.d.ts","sourceRoot":"","sources":["../../src/domain/node-inventory.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,QAAQ,MAAM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