@agimon-ai/po-runner 0.0.0-alpha.1 → 0.0.0-alpha.100

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 (363) hide show
  1. package/LICENSE +149 -21
  2. package/README.md +68 -27
  3. package/dist/ansiScrub.mjs +1 -2
  4. package/dist/apiContracts.cjs +45 -2
  5. package/dist/apiContracts.cjs.map +1 -1
  6. package/dist/apiContracts.d.mts.map +1 -1
  7. package/dist/apiContracts.mjs +45 -2
  8. package/dist/apiContracts.mjs.map +1 -1
  9. package/dist/{bashResult-DNgtahGR.cjs → bashResult-B1w7qkQW.cjs} +13 -12
  10. package/dist/bashResult-B1w7qkQW.cjs.map +1 -0
  11. package/dist/{bashResult-DcrRaBLv.d.mts → bashResult-CfOPpOHN.d.mts} +2 -2
  12. package/dist/{bashResult-DcrRaBLv.d.mts.map → bashResult-CfOPpOHN.d.mts.map} +1 -1
  13. package/dist/{bashResult-bIVSzoj-.mjs → bashResult-ntL4Umz3.mjs} +13 -12
  14. package/dist/bashResult-ntL4Umz3.mjs.map +1 -0
  15. package/dist/{bashRunService-CJ02XaAq.mjs → bashRunService-CqIzJ5F6.mjs} +36 -24
  16. package/dist/bashRunService-CqIzJ5F6.mjs.map +1 -0
  17. package/dist/{bashRunService-Ci0cGdYO.d.mts → bashRunService-D95EJ5P5.d.mts} +18 -1
  18. package/dist/bashRunService-D95EJ5P5.d.mts.map +1 -0
  19. package/dist/{bashRunService-DyqxOSlx.cjs → bashRunService-pdXCVU1H.cjs} +36 -24
  20. package/dist/bashRunService-pdXCVU1H.cjs.map +1 -0
  21. package/dist/bashRunService.cjs +1 -1
  22. package/dist/bashRunService.d.mts +6 -6
  23. package/dist/bashRunService.d.mts.map +1 -1
  24. package/dist/bashRunService.mjs +1 -2
  25. package/dist/bashSchema.cjs +1 -1
  26. package/dist/bashSchema.d.mts +1 -1
  27. package/dist/bashSchema.mjs +1 -2
  28. package/dist/bashTool-CfNNdq62.cjs +43 -0
  29. package/dist/bashTool-CfNNdq62.cjs.map +1 -0
  30. package/dist/bashTool-DRW3lseL.mjs +26 -0
  31. package/dist/bashTool-DRW3lseL.mjs.map +1 -0
  32. package/dist/{bashTool-B1EwZLo_.d.mts → bashTool-Dc1ld2E3.d.mts} +3 -9
  33. package/dist/bashTool-Dc1ld2E3.d.mts.map +1 -0
  34. package/dist/bashTool.cjs +3 -3
  35. package/dist/bashTool.cjs.map +1 -1
  36. package/dist/bashTool.d.mts +4 -4
  37. package/dist/bashTool.d.mts.map +1 -1
  38. package/dist/bashTool.mjs +3 -3
  39. package/dist/bashTool.mjs.map +1 -1
  40. package/dist/bin/cli.cjs +23 -11
  41. package/dist/bin/cli.cjs.map +1 -1
  42. package/dist/bin/cli.d.mts.map +1 -1
  43. package/dist/bin/cli.mjs +23 -11
  44. package/dist/bin/cli.mjs.map +1 -1
  45. package/dist/bin/logSink.cjs +48 -34
  46. package/dist/bin/logSink.cjs.map +1 -1
  47. package/dist/bin/logSink.d.mts.map +1 -1
  48. package/dist/bin/logSink.mjs +46 -32
  49. package/dist/bin/logSink.mjs.map +1 -1
  50. package/dist/bin/runnerHost.cjs +123 -52
  51. package/dist/bin/runnerHost.cjs.map +1 -1
  52. package/dist/bin/runnerHost.d.mts.map +1 -1
  53. package/dist/bin/runnerHost.mjs +122 -51
  54. package/dist/bin/runnerHost.mjs.map +1 -1
  55. package/dist/{cliApp-Dj9nwaOv.cjs → cliApp-BYfgP44s.cjs} +94 -31
  56. package/dist/cliApp-BYfgP44s.cjs.map +1 -0
  57. package/dist/{cliApp-v8Z3rMCi.mjs → cliApp-DPbA8LkI.mjs} +91 -34
  58. package/dist/cliApp-DPbA8LkI.mjs.map +1 -0
  59. package/dist/cliApp.cjs +2 -1
  60. package/dist/cliApp.d.mts +7 -4
  61. package/dist/cliApp.d.mts.map +1 -1
  62. package/dist/cliApp.mjs +1 -2
  63. package/dist/clock.mjs +1 -2
  64. package/dist/{compaction-4QSUsBxq.cjs → compaction-Cduebib_.cjs} +3 -3
  65. package/dist/compaction-Cduebib_.cjs.map +1 -0
  66. package/dist/{compaction-DCw80VZj.mjs → compaction-nNlE6e5I.mjs} +3 -3
  67. package/dist/compaction-nNlE6e5I.mjs.map +1 -0
  68. package/dist/compaction.cjs +1 -1
  69. package/dist/compaction.d.mts +1 -1
  70. package/dist/compaction.mjs +1 -2
  71. package/dist/config.cjs +1 -1
  72. package/dist/config.d.mts +1 -1
  73. package/dist/config.mjs +1 -2
  74. package/dist/extensions/mcp-ui.mjs.map +1 -1
  75. package/dist/extensions/mcp.cjs +30 -18
  76. package/dist/extensions/mcp.cjs.map +1 -1
  77. package/dist/extensions/mcp.d.mts +1 -1
  78. package/dist/extensions/mcp.mjs +30 -18
  79. package/dist/extensions/mcp.mjs.map +1 -1
  80. package/dist/extensions/native.mjs +1707 -0
  81. package/dist/extensions/native.mjs.map +1 -0
  82. package/dist/extensions/server.cjs +1055 -223
  83. package/dist/extensions/server.cjs.map +1 -1
  84. package/dist/extensions/server.d.mts +2 -2
  85. package/dist/extensions/server.d.mts.map +1 -1
  86. package/dist/extensions/server.mjs +1051 -219
  87. package/dist/extensions/server.mjs.map +1 -1
  88. package/dist/extensions/web.mjs +656 -599
  89. package/dist/extensions/web.mjs.map +1 -1
  90. package/dist/{headless-BGYfIlNk.mjs → headless-CG2i0vqB.mjs} +54 -32
  91. package/dist/headless-CG2i0vqB.mjs.map +1 -0
  92. package/dist/{headless-CHUsBGhg.cjs → headless-DPj9mk2G.cjs} +54 -32
  93. package/dist/headless-DPj9mk2G.cjs.map +1 -0
  94. package/dist/{index-BZL7keVW.d.mts → index-BCCF1sGD.d.mts} +2 -2
  95. package/dist/index-BCCF1sGD.d.mts.map +1 -0
  96. package/dist/{index-D9-IXax4.d.mts → index-BKor0Jn_.d.mts} +6 -6
  97. package/dist/index-BKor0Jn_.d.mts.map +1 -0
  98. package/dist/{index-Dhi8asLH.d.mts → index-Bhh0LCcN.d.mts} +10 -4
  99. package/dist/index-Bhh0LCcN.d.mts.map +1 -0
  100. package/dist/{index-DM7yJpMs.d.mts → index-BxQmpB5q.d.mts} +6 -6
  101. package/dist/index-BxQmpB5q.d.mts.map +1 -0
  102. package/dist/{index-DBz0DxnL.d.mts → index-CH-z0BX3.d.mts} +11 -5
  103. package/dist/index-CH-z0BX3.d.mts.map +1 -0
  104. package/dist/index-DFORykA2.d.mts +57 -0
  105. package/dist/index-DFORykA2.d.mts.map +1 -0
  106. package/dist/index-EMbmq9gu.d.mts +45 -0
  107. package/dist/index-EMbmq9gu.d.mts.map +1 -0
  108. package/dist/index-qSi4-EJW.d.mts +49 -0
  109. package/dist/index-qSi4-EJW.d.mts.map +1 -0
  110. package/dist/index.cjs +5 -5
  111. package/dist/index.d.mts +6 -6
  112. package/dist/index.mjs +5 -5
  113. package/dist/launch.cjs +4 -0
  114. package/dist/launch.d.mts +55 -0
  115. package/dist/launch.d.mts.map +1 -0
  116. package/dist/launch.mjs +1 -0
  117. package/dist/{launcher-BG5t9nvG.d.mts → launcher-CDDBTvZq.d.mts} +4 -3
  118. package/dist/launcher-CDDBTvZq.d.mts.map +1 -0
  119. package/dist/{launcher-BDm6-DiQ.mjs → launcher-CwVJ55MC.mjs} +46 -32
  120. package/dist/launcher-CwVJ55MC.mjs.map +1 -0
  121. package/dist/{launcher-SlyE8R3b.cjs → launcher-ksyHY-iG.cjs} +53 -33
  122. package/dist/launcher-ksyHY-iG.cjs.map +1 -0
  123. package/dist/launcher.cjs +1 -1
  124. package/dist/launcher.d.mts +5 -5
  125. package/dist/launcher.d.mts.map +1 -1
  126. package/dist/launcher.mjs +1 -2
  127. package/dist/lifeline-26IaW5w7.d.mts +34 -0
  128. package/dist/lifeline-26IaW5w7.d.mts.map +1 -0
  129. package/dist/lifeline-B4cjtrBe.cjs +27 -0
  130. package/dist/lifeline-B4cjtrBe.cjs.map +1 -0
  131. package/dist/lifeline-CbxvM4uJ.cjs +229 -0
  132. package/dist/lifeline-CbxvM4uJ.cjs.map +1 -0
  133. package/dist/lifeline-doL4-_14.mjs +214 -0
  134. package/dist/lifeline-doL4-_14.mjs.map +1 -0
  135. package/dist/lifeline-nPh3cx5A.mjs +10 -0
  136. package/dist/lifeline-nPh3cx5A.mjs.map +1 -0
  137. package/dist/lifeline.cjs +4 -1
  138. package/dist/lifeline.d.mts +4 -21
  139. package/dist/lifeline.mjs +3 -3
  140. package/dist/logFile-B9FSwmE0.cjs +44 -0
  141. package/dist/logFile-B9FSwmE0.cjs.map +1 -0
  142. package/dist/{logFile-C7oQ_v-g.d.mts → logFile-BirfZtS1.d.mts} +4 -4
  143. package/dist/logFile-BirfZtS1.d.mts.map +1 -0
  144. package/dist/logFile-D1EOKqmL.mjs +39 -0
  145. package/dist/logFile-D1EOKqmL.mjs.map +1 -0
  146. package/dist/logFile.cjs +1 -1
  147. package/dist/logFile.d.mts +3 -3
  148. package/dist/logFile.d.mts.map +1 -1
  149. package/dist/logFile.mjs +1 -2
  150. package/dist/{logReader-MdW9ffvV.d.mts → logReader-Bn3WEdjg.d.mts} +4 -2
  151. package/dist/{logReader-MdW9ffvV.d.mts.map → logReader-Bn3WEdjg.d.mts.map} +1 -1
  152. package/dist/{logReader-B6J7L7Ua.cjs → logReader-ChLjLcLF.cjs} +103 -56
  153. package/dist/logReader-ChLjLcLF.cjs.map +1 -0
  154. package/dist/{logReader-UfbDbwQl.mjs → logReader-jp7aSOZ7.mjs} +101 -54
  155. package/dist/logReader-jp7aSOZ7.mjs.map +1 -0
  156. package/dist/logReader.cjs +1 -1
  157. package/dist/logReader.d.mts +2 -2
  158. package/dist/logReader.mjs +1 -2
  159. package/dist/processControl.mjs +1 -2
  160. package/dist/{ptyHost-MI2Z6WTG.cjs → ptyHost-C-oWV455.cjs} +21 -15
  161. package/dist/ptyHost-C-oWV455.cjs.map +1 -0
  162. package/dist/{ptyHost-DlQtTB8F.mjs → ptyHost-C2zu-ZfO.mjs} +20 -14
  163. package/dist/ptyHost-C2zu-ZfO.mjs.map +1 -0
  164. package/dist/{ptyHost-DWWtRrGn.d.mts → ptyHost-C_6x2xuJ.d.mts} +2 -2
  165. package/dist/{ptyHost-DWWtRrGn.d.mts.map → ptyHost-C_6x2xuJ.d.mts.map} +1 -1
  166. package/dist/ptyHost.cjs +1 -1
  167. package/dist/ptyHost.d.mts +2 -2
  168. package/dist/ptyHost.d.mts.map +1 -1
  169. package/dist/ptyHost.mjs +1 -2
  170. package/dist/{ptySpawner-DEi1KOnd.mjs → ptySpawner-C375NJnj.mjs} +2 -2
  171. package/dist/ptySpawner-C375NJnj.mjs.map +1 -0
  172. package/dist/{ptySpawner-ijw0g5_T.cjs → ptySpawner-C39IzbRo.cjs} +2 -2
  173. package/dist/ptySpawner-C39IzbRo.cjs.map +1 -0
  174. package/dist/ptySpawner.cjs +1 -1
  175. package/dist/ptySpawner.d.mts +1 -1
  176. package/dist/ptySpawner.mjs +1 -2
  177. package/dist/{reconcile-BugwYFbV.cjs → reconcile-DUaX_vKZ.mjs} +3 -63
  178. package/dist/reconcile-DUaX_vKZ.mjs.map +1 -0
  179. package/dist/{reconcile-DMeNSxwn.mjs → reconcile-DjF9T1hN.cjs} +13 -43
  180. package/dist/reconcile-DjF9T1hN.cjs.map +1 -0
  181. package/dist/reconcile.cjs +1 -2
  182. package/dist/reconcile.d.mts +4 -11
  183. package/dist/reconcile.d.mts.map +1 -1
  184. package/dist/reconcile.mjs +1 -2
  185. package/dist/responseEnvelope.cjs +2 -2
  186. package/dist/responseEnvelope.d.mts +7 -7
  187. package/dist/responseEnvelope.d.mts.map +1 -1
  188. package/dist/responseEnvelope.mjs +2 -2
  189. package/dist/{rmuxBackend-DfyQwJrc.mjs → rmuxBackend-BCfO297l.mjs} +62 -44
  190. package/dist/rmuxBackend-BCfO297l.mjs.map +1 -0
  191. package/dist/{rmuxBackend-DlxgqRZ1.cjs → rmuxBackend-BooQvfXt.cjs} +64 -46
  192. package/dist/rmuxBackend-BooQvfXt.cjs.map +1 -0
  193. package/dist/{rmuxBackend-CaEWooWn.d.mts → rmuxBackend-xFzlANM9.d.mts} +4 -4
  194. package/dist/rmuxBackend-xFzlANM9.d.mts.map +1 -0
  195. package/dist/rmuxBackend.cjs +1 -1
  196. package/dist/rmuxBackend.d.mts +2 -2
  197. package/dist/rmuxBackend.mjs +1 -2
  198. package/dist/rolldown-runtime-8H4AJuhK.mjs +14 -0
  199. package/dist/{rolldown-runtime-VH7oDXx4.cjs → rolldown-runtime-C0BPl7ul.cjs} +15 -0
  200. package/dist/{rtkProcessor-B9KPdyzr.mjs → rtkProcessor-DOXcp51z.mjs} +8 -7
  201. package/dist/rtkProcessor-DOXcp51z.mjs.map +1 -0
  202. package/dist/{rtkProcessor-Bc4L4o_8.cjs → rtkProcessor-J2gLQvM4.cjs} +10 -8
  203. package/dist/rtkProcessor-J2gLQvM4.cjs.map +1 -0
  204. package/dist/rtkProcessor.cjs +1 -1
  205. package/dist/rtkProcessor.d.mts +1 -1
  206. package/dist/rtkProcessor.mjs +1 -1
  207. package/dist/{runnerConfig-D2tGq5ZM.cjs → runnerConfig-BoLMinlx.cjs} +11 -11
  208. package/dist/runnerConfig-BoLMinlx.cjs.map +1 -0
  209. package/dist/{runnerConfig-BjtulXBI.d.mts → runnerConfig-DuWL6TJx.d.mts} +10 -10
  210. package/dist/{runnerConfig-BjtulXBI.d.mts.map → runnerConfig-DuWL6TJx.d.mts.map} +1 -1
  211. package/dist/{runnerConfig-BQBlVAXn.mjs → runnerConfig-XXMq4VQA.mjs} +11 -11
  212. package/dist/runnerConfig-XXMq4VQA.mjs.map +1 -0
  213. package/dist/{runnerDependencies-DruByBGS.mjs → runnerDependencies-0SbEl19h.mjs} +83 -64
  214. package/dist/runnerDependencies-0SbEl19h.mjs.map +1 -0
  215. package/dist/{runnerDependencies-KMZigIxB.cjs → runnerDependencies-DNxVf_Sg.cjs} +85 -66
  216. package/dist/runnerDependencies-DNxVf_Sg.cjs.map +1 -0
  217. package/dist/runnerDependencies.cjs +1 -1
  218. package/dist/runnerDependencies.d.mts +1 -1
  219. package/dist/runnerDependencies.mjs +1 -2
  220. package/dist/runnerHost-BvNYPMeh.mjs +165 -0
  221. package/dist/runnerHost-BvNYPMeh.mjs.map +1 -0
  222. package/dist/runnerHost-C2F5oxzn.cjs +184 -0
  223. package/dist/runnerHost-C2F5oxzn.cjs.map +1 -0
  224. package/dist/runnerLaunch-BAf7hXMr.cjs +192 -0
  225. package/dist/runnerLaunch-BAf7hXMr.cjs.map +1 -0
  226. package/dist/runnerLaunch-Bimgdh4h.mjs +175 -0
  227. package/dist/runnerLaunch-Bimgdh4h.mjs.map +1 -0
  228. package/dist/runnerNamer.d.mts +1 -1
  229. package/dist/runnerNamer.mjs +1 -2
  230. package/dist/{runnerPaths-BTEuzxw0.cjs → runnerPaths-CSkswyjR.cjs} +102 -202
  231. package/dist/runnerPaths-CSkswyjR.cjs.map +1 -0
  232. package/dist/{runnerPaths-B_dAAeco.mjs → runnerPaths-D3P7_EhW.mjs} +95 -201
  233. package/dist/runnerPaths-D3P7_EhW.mjs.map +1 -0
  234. package/dist/runnerPaths.cjs +1 -1
  235. package/dist/runnerPaths.d.mts +10 -14
  236. package/dist/runnerPaths.d.mts.map +1 -1
  237. package/dist/runnerPaths.mjs +1 -2
  238. package/dist/{runnerRegistry-BmkZTJHi.cjs → runnerRegistry-B8K1L3lq.cjs} +82 -46
  239. package/dist/runnerRegistry-B8K1L3lq.cjs.map +1 -0
  240. package/dist/{runnerRegistry-CtJiD02R.d.mts → runnerRegistry-BlZhS9yL.d.mts} +2 -4
  241. package/dist/{runnerRegistry-CtJiD02R.d.mts.map → runnerRegistry-BlZhS9yL.d.mts.map} +1 -1
  242. package/dist/{runnerRegistry-CeOHEjBv.mjs → runnerRegistry-Dqca6SD3.mjs} +61 -36
  243. package/dist/runnerRegistry-Dqca6SD3.mjs.map +1 -0
  244. package/dist/runnerRegistry-NW6oAJ71.cjs +60 -0
  245. package/dist/runnerRegistry-NW6oAJ71.cjs.map +1 -0
  246. package/dist/runnerRegistry-l0C_55oO.mjs +13 -0
  247. package/dist/runnerRegistry-l0C_55oO.mjs.map +1 -0
  248. package/dist/runnerRegistry.cjs +1 -1
  249. package/dist/runnerRegistry.d.mts +2 -2
  250. package/dist/runnerRegistry.mjs +1 -2
  251. package/dist/runnerSequence-ZTYgZ_2W.cjs +32 -0
  252. package/dist/runnerSequence-ZTYgZ_2W.cjs.map +1 -0
  253. package/dist/runnerSequence-k-_Fd77y.mjs +9 -0
  254. package/dist/runnerSequence-k-_Fd77y.mjs.map +1 -0
  255. package/dist/runnerSequenceStore-CaY7S_Sd.mjs +76 -0
  256. package/dist/runnerSequenceStore-CaY7S_Sd.mjs.map +1 -0
  257. package/dist/runnerSequenceStore-Ck6M-8r_.cjs +89 -0
  258. package/dist/runnerSequenceStore-Ck6M-8r_.cjs.map +1 -0
  259. package/dist/services/lifeline/client.cjs +89 -5
  260. package/dist/services/lifeline/client.cjs.map +1 -1
  261. package/dist/services/lifeline/client.d.mts +17 -1
  262. package/dist/services/lifeline/client.d.mts.map +1 -1
  263. package/dist/services/lifeline/client.mjs +85 -4
  264. package/dist/services/lifeline/client.mjs.map +1 -1
  265. package/dist/services/runnerSupervisor/index.cjs +36 -22
  266. package/dist/services/runnerSupervisor/index.cjs.map +1 -1
  267. package/dist/services/runnerSupervisor/index.d.mts +5 -5
  268. package/dist/services/runnerSupervisor/index.d.mts.map +1 -1
  269. package/dist/services/runnerSupervisor/index.mjs +35 -21
  270. package/dist/services/runnerSupervisor/index.mjs.map +1 -1
  271. package/dist/session-CdVeSD7F.mjs +8 -0
  272. package/dist/session-CdVeSD7F.mjs.map +1 -0
  273. package/dist/session-DnUj8Q71.cjs +25 -0
  274. package/dist/session-DnUj8Q71.cjs.map +1 -0
  275. package/dist/session-ISEGK4z9.mjs +26 -0
  276. package/dist/session-ISEGK4z9.mjs.map +1 -0
  277. package/dist/session-PQd3azWf.cjs +43 -0
  278. package/dist/session-PQd3azWf.cjs.map +1 -0
  279. package/dist/session.cjs +4 -3
  280. package/dist/session.d.mts +3 -1
  281. package/dist/session.d.mts.map +1 -1
  282. package/dist/session.mjs +3 -3
  283. package/dist/spawner.mjs +1 -2
  284. package/dist/{type-BXM03qSw.d.mts → type-BWY9vvSq.d.mts} +12 -10
  285. package/dist/type-BWY9vvSq.d.mts.map +1 -0
  286. package/dist/{type-C31e1gla.d.mts → type-BZAFiQjC.d.mts} +11 -11
  287. package/dist/{type-C31e1gla.d.mts.map → type-BZAFiQjC.d.mts.map} +1 -1
  288. package/dist/types.d.mts +1 -1
  289. package/llms.txt +2 -1
  290. package/package.json +62 -33
  291. package/skills/po-runner/SKILL.md +96 -0
  292. package/src/prompts/codemode-how-to-runner/SKILL.md +71 -0
  293. package/src/prompts/help-how-to-runner/SKILL.md +51 -0
  294. package/dist/bashResult-DNgtahGR.cjs.map +0 -1
  295. package/dist/bashResult-bIVSzoj-.mjs.map +0 -1
  296. package/dist/bashRunService-CJ02XaAq.mjs.map +0 -1
  297. package/dist/bashRunService-Ci0cGdYO.d.mts.map +0 -1
  298. package/dist/bashRunService-DyqxOSlx.cjs.map +0 -1
  299. package/dist/bashTool-B1EwZLo_.d.mts.map +0 -1
  300. package/dist/bashTool-C-k7fmyh.mjs +0 -24
  301. package/dist/bashTool-C-k7fmyh.mjs.map +0 -1
  302. package/dist/bashTool-CdgtqVFD.cjs +0 -41
  303. package/dist/bashTool-CdgtqVFD.cjs.map +0 -1
  304. package/dist/cliApp-Dj9nwaOv.cjs.map +0 -1
  305. package/dist/cliApp-v8Z3rMCi.mjs.map +0 -1
  306. package/dist/compaction-4QSUsBxq.cjs.map +0 -1
  307. package/dist/compaction-DCw80VZj.mjs.map +0 -1
  308. package/dist/headless-BGYfIlNk.mjs.map +0 -1
  309. package/dist/headless-CHUsBGhg.cjs.map +0 -1
  310. package/dist/index-BZL7keVW.d.mts.map +0 -1
  311. package/dist/index-BwB_jTI9.d.mts +0 -12
  312. package/dist/index-BwB_jTI9.d.mts.map +0 -1
  313. package/dist/index-D9-IXax4.d.mts.map +0 -1
  314. package/dist/index-DBz0DxnL.d.mts.map +0 -1
  315. package/dist/index-DM7yJpMs.d.mts.map +0 -1
  316. package/dist/index-Dhi8asLH.d.mts.map +0 -1
  317. package/dist/launcher-BDm6-DiQ.mjs.map +0 -1
  318. package/dist/launcher-BG5t9nvG.d.mts.map +0 -1
  319. package/dist/launcher-SlyE8R3b.cjs.map +0 -1
  320. package/dist/lifeline-BZaQA0rm.mjs +0 -88
  321. package/dist/lifeline-BZaQA0rm.mjs.map +0 -1
  322. package/dist/lifeline-BuV_erib.cjs +0 -98
  323. package/dist/lifeline-BuV_erib.cjs.map +0 -1
  324. package/dist/lifeline-eJdZV0nN.d.mts +0 -19
  325. package/dist/lifeline-eJdZV0nN.d.mts.map +0 -1
  326. package/dist/lifeline.d.mts.map +0 -1
  327. package/dist/logFile-C7oQ_v-g.d.mts.map +0 -1
  328. package/dist/logFile-CNvepZh0.cjs +0 -67
  329. package/dist/logFile-CNvepZh0.cjs.map +0 -1
  330. package/dist/logFile-KKPbkC-a.mjs +0 -60
  331. package/dist/logFile-KKPbkC-a.mjs.map +0 -1
  332. package/dist/logReader-B6J7L7Ua.cjs.map +0 -1
  333. package/dist/logReader-UfbDbwQl.mjs.map +0 -1
  334. package/dist/ptyHost-DlQtTB8F.mjs.map +0 -1
  335. package/dist/ptyHost-MI2Z6WTG.cjs.map +0 -1
  336. package/dist/ptySpawner-DEi1KOnd.mjs.map +0 -1
  337. package/dist/ptySpawner-ijw0g5_T.cjs.map +0 -1
  338. package/dist/reconcile-BugwYFbV.cjs.map +0 -1
  339. package/dist/reconcile-DMeNSxwn.mjs.map +0 -1
  340. package/dist/rmuxBackend-CaEWooWn.d.mts.map +0 -1
  341. package/dist/rmuxBackend-DfyQwJrc.mjs.map +0 -1
  342. package/dist/rmuxBackend-DlxgqRZ1.cjs.map +0 -1
  343. package/dist/rtkProcessor-B9KPdyzr.mjs.map +0 -1
  344. package/dist/rtkProcessor-Bc4L4o_8.cjs.map +0 -1
  345. package/dist/runnerConfig-BQBlVAXn.mjs.map +0 -1
  346. package/dist/runnerConfig-D2tGq5ZM.cjs.map +0 -1
  347. package/dist/runnerDependencies-DruByBGS.mjs.map +0 -1
  348. package/dist/runnerDependencies-KMZigIxB.cjs.map +0 -1
  349. package/dist/runnerPaths-BTEuzxw0.cjs.map +0 -1
  350. package/dist/runnerPaths-B_dAAeco.mjs.map +0 -1
  351. package/dist/runnerRegistry-BmkZTJHi.cjs.map +0 -1
  352. package/dist/runnerRegistry-CeOHEjBv.mjs.map +0 -1
  353. package/dist/session-BC43uEyG.cjs +0 -29
  354. package/dist/session-BC43uEyG.cjs.map +0 -1
  355. package/dist/session-Chsb_Nh2.mjs +0 -18
  356. package/dist/session-Chsb_Nh2.mjs.map +0 -1
  357. package/dist/session-DE2Acesp.mjs +0 -6
  358. package/dist/session-DE2Acesp.mjs.map +0 -1
  359. package/dist/session-SfIPtdZO.cjs +0 -11
  360. package/dist/session-SfIPtdZO.cjs.map +0 -1
  361. package/dist/type-BXM03qSw.d.mts.map +0 -1
  362. package/skills/doom-runner/SKILL.md +0 -78
  363. package/src/prompts/po-use-runner/SKILL.md +0 -47
package/LICENSE CHANGED
@@ -1,21 +1,149 @@
1
- MIT License
2
-
3
- Copyright (c) 2026 Vuong Ngo
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
1
+ License text copyright © 2017 MariaDB Corporation Ab, All Rights Reserved.
2
+ "Business Source License" is a trademark of MariaDB Corporation Ab.
3
+
4
+ Parameters
5
+
6
+ Licensor: Agimon Pty Ltd
7
+ Licensed Work: Po, the software in the Po source repository and the
8
+ packages released from it, in each version released by
9
+ the Licensor.
10
+ The Licensed Work is (c) 2026 Agimon Pty Ltd.
11
+ Material identified as third-party in the "Third-party
12
+ components" section at the end of this file or in a
13
+ NOTICE file, and any package or directory whose own
14
+ license file grants a different license, is not part of
15
+ the Licensed Work and remains under its own license.
16
+ Additional Use Grant: You may make production use of the Licensed Work if
17
+ your use is Eligible Use. "Eligible Use" is production use that falls
18
+ within at least one of the following:
19
+
20
+ (a) Personal Use. Use by an individual for their own personal purposes,
21
+ and not on behalf of, or for the benefit of, an employer, client, or
22
+ other Organization. Use by an individual in the course of employment
23
+ or engagement by an Organization is use by that Organization.
24
+
25
+ (b) Small Organization Use. Use by or on behalf of an Organization whose
26
+ Annual Revenue is less than USD 1,000,000.
27
+
28
+ (c) Non-profit, Education and Research Use. Use, regardless of Annual
29
+ Revenue, by (i) an Organization registered or recognized as a
30
+ non-profit or charitable organization under the laws of its
31
+ jurisdiction, for its non-profit purposes; (ii) an accredited school,
32
+ college, or university, for teaching, learning, or academic research;
33
+ or (iii) a publicly funded research institution, for its research.
34
+
35
+ (d) Service Provider Use. Use by a consultant, contractor, agency, or other
36
+ service provider, regardless of its own Annual Revenue, solely to
37
+ build, deploy, host, operate, or support the Licensed Work for a client
38
+ whose own use would be Eligible Use under (a), (b), or (c). A service
39
+ provider's use for its own purposes is Eligible Use only if the service
40
+ provider itself qualifies under (b) or (c).
41
+
42
+
43
+ Hosted services. Offering the Licensed Work to third parties as a hosted
44
+ or managed service whose primary value is the Licensed Work is Eligible
45
+ Use only if each such third party's own use would be Eligible Use.
46
+
47
+ Definitions. "Organization" means any company, partnership, sole
48
+ proprietorship, trust, association, government body, or other entity, and
49
+ includes an individual acting in a business or professional capacity.
50
+ "Affiliate" means any entity that directly or indirectly controls, is
51
+ controlled by, or is under common control with an Organization, where
52
+ "control" means ownership of more than 50% of the voting interests of an
53
+ entity or the power to direct its management and policies by contract or
54
+ otherwise. "Annual Revenue" means the total gross revenue of an
55
+ Organization and all of its Affiliates combined, from all sources and
56
+ whether or not related to the Licensed Work, for its most recently
57
+ completed fiscal year, or, if it has not completed a fiscal year, for the
58
+ twelve months before the use (or since its formation, if shorter),
59
+ converted into US dollars at the average exchange rate for that period.
60
+ Proceeds of equity or debt financing are not revenue.
61
+
62
+ Threshold. If an Organization stops qualifying under (b), its existing
63
+ production use remains Eligible Use for 90 days after it stops
64
+ qualifying, after which it must obtain a commercial license or stop
65
+ production use. Use that was Eligible Use when it occurred never requires
66
+ a commercial license after the fact.
67
+ Change Date: Four years from the date a version of the Licensed Work
68
+ is first publicly released by the Licensor.
69
+ Change License: Apache License, Version 2.0
70
+
71
+ For information about alternative licensing arrangements for the Licensed
72
+ Work, please visit: https://agimon.ai/licensing
73
+
74
+ Notice
75
+
76
+ The Business Source License (this document, or the "License") is not an Open
77
+ Source license. However, the Licensed Work will eventually be made available
78
+ under an Open Source License, as stated in this License.
79
+
80
+ -----------------------------------------------------------------------------
81
+
82
+ Business Source License 1.1
83
+
84
+ Terms
85
+
86
+ The Licensor hereby grants you the right to copy, modify, create derivative
87
+ works, redistribute, and make non-production use of the Licensed Work. The
88
+ Licensor may make an Additional Use Grant, above, permitting limited
89
+ production use.
90
+
91
+ Effective on the Change Date, or the fourth anniversary of the first publicly
92
+ available distribution of a specific version of the Licensed Work under this
93
+ License, whichever comes first, the Licensor hereby grants you rights under
94
+ the terms of the Change License, and the rights granted in the paragraph
95
+ above terminate.
96
+
97
+ If your use of the Licensed Work does not comply with the requirements
98
+ currently in effect as described in this License, you must purchase a
99
+ commercial license from the Licensor, its affiliated entities, or authorized
100
+ resellers, or you must refrain from using the Licensed Work.
101
+
102
+ All copies of the original and modified Licensed Work, and derivative works
103
+ of the Licensed Work, are subject to this License. This License applies
104
+ separately for each version of the Licensed Work and the Change Date may vary
105
+ for each version of the Licensed Work released by Licensor.
106
+
107
+ You must conspicuously display this License on each original or modified copy
108
+ of the Licensed Work. If you receive the Licensed Work in original or
109
+ modified form from a third party, the terms and conditions set forth in this
110
+ License apply to your use of that work.
111
+
112
+ Any use of the Licensed Work in violation of this License will automatically
113
+ terminate your rights under this License for the current and all other
114
+ versions of the Licensed Work.
115
+
116
+ This License does not grant you any right in any trademark or logo of
117
+ Licensor or its affiliates (provided that you may use a trademark or logo of
118
+ Licensor as expressly required by this License).
119
+
120
+ TO THE EXTENT PERMITTED BY APPLICABLE LAW, THE LICENSED WORK IS PROVIDED ON
121
+ AN “AS IS” BASIS. LICENSOR HEREBY DISCLAIMS ALL WARRANTIES AND CONDITIONS,
122
+ EXPRESS OR IMPLIED, INCLUDING (WITHOUT LIMITATION) WARRANTIES OF
123
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, NON-INFRINGEMENT, AND
124
+ TITLE.
125
+
126
+ MariaDB hereby grants you permission to use this License’s text to license
127
+ your works, and to refer to it using the trademark “Business Source License”,
128
+ as long as you comply with the Covenants of Licensor below.
129
+
130
+ Covenants of Licensor
131
+
132
+ In consideration of the right to use this License’s text and the “Business
133
+ Source License” name and trademark, Licensor covenants to MariaDB, and to all
134
+ other recipients of the licensed work to be provided by Licensor:
135
+
136
+ 1. To specify as the Change License the GPL Version 2.0 or any later version,
137
+ or a license that is compatible with GPL Version 2.0 or a later version,
138
+ where “compatible” means that software provided under the Change License can
139
+ be included in a program with software provided under GPL Version 2.0 or a
140
+ later version. Licensor may specify additional Change Licenses without
141
+ limitation.
142
+
143
+ 2. To either: (a) specify an additional grant of rights to use that does not
144
+ impose any additional restriction on the right granted in this License, as
145
+ the Additional Use Grant; or (b) insert the text “None”.
146
+
147
+ 3. To specify a Change Date.
148
+
149
+ 4. Not to modify this License in any other way.
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @agimon-ai/po-runner
2
2
 
3
- Supervised shell execution, background process control, durable logs.
3
+ Supervised shell execution, sequential checks, background process control, complete session-temp logs.
4
4
 
5
5
  Part of the [Po distribution](https://www.npmjs.com/package/@agimon-ai/po).
6
6
 
@@ -29,18 +29,18 @@ Panes come from the first backend that answers: bundled RMUX, then `rmux` on PAT
29
29
  PATH. Only when none is available does a non-interactive command fall back to a supervised
30
30
  subprocess, and interactive commands need one of them. A tmux-backed run is supervised by the same
31
31
  host process as an RMUX one, so exit metadata and logs behave the same; its session names carry a
32
- `doom-tmux-` prefix rather than `doom-runner-`.
32
+ `po-tmux-` prefix rather than `po-runner-`.
33
33
 
34
34
  ## Install
35
35
 
36
- `po init` and `dpi init` include Runner in `default.packages` in `.po/modes.yaml`. Move
36
+ `po init` include Runner in `default.packages` in `.po/modes.yaml`. Move
37
37
  it to a named layer to enable it only in selected major modes.
38
38
 
39
39
  ## Use the `bash` tool
40
40
 
41
41
  ```json
42
42
  {
43
- "command": "pnpm test",
43
+ "command": ["pnpm test"],
44
44
  "timeout": 60
45
45
  }
46
46
  ```
@@ -49,8 +49,26 @@ Commands crossing the promotion threshold move to a supervised runner. The defau
49
49
  seconds. Set `background: true` to detach immediately, or `interactive: true` only when a command
50
50
  needs terminal input.
51
51
 
52
- Runner requires `PI_SESSION_ID` for session ownership. Processes, controls, and logs remain
53
- addressable after transcript compaction because their identity is outside model context.
52
+ Always pass `command` as an array, including for one command. Dependent commands run in separate fresh shells, sequentially and fail-fast:
53
+
54
+ ```json
55
+ {
56
+ "command": ["pnpm build", "pnpm typecheck", "pnpm lint", "pnpm test"],
57
+ "name": "verification",
58
+ "timeout": 120
59
+ }
60
+ ```
61
+
62
+ With `interactive: true`, only the last command gets a pseudo terminal. Runner returns control when
63
+ that stage starts; inspect its stage runner ID and logs, then use that ID for input, not the sequence ID.
64
+ Each command gets its own timeout and complete log. The result lists all attempted log paths and only
65
+ the last executed command's trimmed output. Shell state such as `cd` and `export` does not carry
66
+ between entries. Keep repository mutations separate from verification.
67
+ A promoted array remains one supervised sequence, and its next command waits for the current process
68
+ to actually exit. Native sessions receive one aggregate completion; remote MCP callers poll.
69
+
70
+ Runner requires a session identity and host-admitted `PO_SESSION_TEMP_DIR`. Processes, controls, and
71
+ logs remain addressable after transcript compaction because identity is outside model context.
54
72
 
55
73
  ### RTK result processing
56
74
 
@@ -63,15 +81,30 @@ also returns bounded raw output with a warning and does not change the command e
63
81
 
64
82
  ## Inspect and control runs
65
83
 
66
- The `doom-runner` CLI supports:
84
+ When code mode is available, use its typed `runner` namespace rather than shelling out to the CLI:
85
+
86
+ ```ts
87
+ // discover({ namespace: 'runner' }) shows current signatures.
88
+ return await runner.list();
89
+ return await runner.status({ id: 'returned-id' });
90
+ return await runner.logs({ id: 'returned-id', lines: 100 });
91
+ return await runner.stop({ id: 'unused-id', reason: 'finished' });
92
+ ```
93
+
94
+ `runner.input` sends interactive input, and `runner.stopAll` stops this session's active work. Reads
95
+ return bounded snapshots, not live streams. Sequence IDs report ordered stages and the guarded final
96
+ result; stage IDs address the actual process logs. Check status before retrying, and distinguish a
97
+ requested cancellation from confirmed termination.
98
+
99
+ Without code mode, the `po-runner` CLI supports:
67
100
 
68
101
  ```bash
69
- doom-runner list
70
- doom-runner status <runner-id>
71
- doom-runner logs <runner-id>
72
- doom-runner input <runner-id> --text "y" --enter
73
- doom-runner stop <runner-id>
74
- doom-runner stop-all
102
+ po-runner list
103
+ po-runner status <runner-id>
104
+ po-runner logs <runner-id>
105
+ po-runner input <runner-id> --text "y" --enter
106
+ po-runner stop <runner-id>
107
+ po-runner stop-all
75
108
  ```
76
109
 
77
110
  The `input` command requires a running interactive process backed by RMUX or tmux.
@@ -80,15 +113,17 @@ Stop runs that are no longer required.
80
113
 
81
114
  ## Storage and limits
82
115
 
83
- By default, session-scoped logs and registry data live under:
116
+ All runner files live beneath the session's host-admitted temporary directory: command logs, process
117
+ metadata, sequence manifests, cancellation files, and supervision transport files. Runner does not
118
+ use the artifact folder or a durable agent-directory fallback for session-owned files.
84
119
 
85
- ```text
86
- ~/.po/agent/doom-runner/<session>/
87
- ```
120
+ Session removal, restart, or termination stops its runner processes and removes its runner subtree
121
+ and registry entries. An external observer handles owner hard-kill cleanup. Compaction and ordinary
122
+ activity changes do not remove evidence. Save important deliverables to the session artifact folder.
88
123
 
89
- Logs remain complete until TTL cleanup and are eligible for cleanup after seven days by default. The
90
- legacy log-size configuration exports remain available for compatibility but no longer rotate log
91
- content. Result limits, retention, and the promotion threshold remain environment-configurable.
124
+ Do not pipe or redirect command output to a file, `head`, or `tail`. Runner automatically saves full
125
+ logs and bounds returned output. Inspect saved logs when an excerpt is truncated instead of rerunning
126
+ the command. Result limits and the promotion threshold remain environment-configurable.
92
127
 
93
128
  ### Result excerpts
94
129
 
@@ -109,7 +144,7 @@ Compiling 1200 modules...
109
144
  compiled src/module-599.ts
110
145
  Build succeeded in 12.4s
111
146
  exit status 0
112
- Full log: /path/to/run.log (17.0 KB, 604 lines); inspect with doom-runner logs run-a
147
+ Full log: /path/to/run.log (17.0 KB, 604 lines); inspect with po-runner logs run-a
113
148
  ```
114
149
 
115
150
  Three ceilings apply and whichever binds first wins: bytes, lines, and tokens. Tokens are there
@@ -123,8 +158,8 @@ estimator models how BPE behaves, with punctuation forcing boundaries, natural w
123
158
  letter-digit runs expensive. Its worst error against `gpt-tokenizer` is a factor of about 1.46
124
159
  either way, which is why the byte ceiling stays behind it as the hard bound.
125
160
 
126
- `DOOM_RUNNER_RESULT_MAX_BYTES`, `DOOM_RUNNER_RESULT_MAX_TOKENS`, and their
127
- `DOOM_RUNNER_SUCCESS_*` counterparts move these for one invocation. A pragma overrides all of
161
+ `PO_RUNNER_RESULT_MAX_BYTES`, `PO_RUNNER_RESULT_MAX_TOKENS`, and their
162
+ `PO_RUNNER_SUCCESS_*` counterparts move these for one invocation. A pragma overrides all of
128
163
  them, which is how one noisy successful command can still ask for the wider result. Raising only
129
164
  `maxResultBytes` will not help when the token ceiling is the one binding.
130
165
 
@@ -151,7 +186,7 @@ One command that needs a wider result can say so on its first line. The pragma i
151
186
  so it stays harmless to the command itself:
152
187
 
153
188
  ```bash
154
- # @doom: {"maxResultBytes": 32768, "maxResultTokens": 8192, "maxResultLines": 300}
189
+ # @po: {"maxResultBytes": 32768, "maxResultTokens": 8192, "maxResultLines": 300}
155
190
  pnpm build
156
191
  ```
157
192
 
@@ -186,7 +221,7 @@ retention accordingly.
186
221
 
187
222
  The headless Po server shares one heavy-job queue across its sessions. Known
188
223
  noninteractive build, test, lint, and typecheck commands acquire a slot before
189
- launching. The default is two concurrent jobs; set `DOOM_RUNNER_MAX_HEAVY_JOBS`
224
+ launching. The default is two concurrent jobs; set `PO_RUNNER_MAX_HEAVY_JOBS`
190
225
  to a positive integer in the server's environment to change it. The waiting queue
191
226
  is bounded to 128 jobs. Cancellation removes queued work without launching it.
192
227
 
@@ -246,7 +281,7 @@ Maintained by [Agimon](https://agimon.ai/about).
246
281
 
247
282
  ## License
248
283
 
249
- MIT
284
+ Business Source License 1.1: free for personal use, organisations under USD 1M revenue, non-profits and education. See [LICENSE](LICENSE) and https://agimon.ai/licensing.
250
285
 
251
286
  ## Extension lifecycle and source layout
252
287
 
@@ -254,4 +289,10 @@ Public capabilities use flat kebab-case subpaths such as `runner-dependencies`,
254
289
 
255
290
  ### Native session ownership
256
291
 
257
- The Po server facet owns runner startup, history retention, background completion notifications, and successful-compaction recovery. The standalone `po-runner` command remains available. Runner project settings retain the existing headless bridge's trusted-project assumption, validation, and environment-over-project precedence. Optional runner activity toggles do not restart the retained supervisor.
292
+ The Po server plugin owns runner startup, history retention, background completion notifications, and successful-compaction recovery. The standalone `po-runner` command remains available. Runner project settings retain the existing headless bridge's trusted-project assumption, validation, and environment-over-project precedence. Optional runner activity toggles do not restart the retained supervisor.
293
+
294
+ ### Package launches and trusted owner routing
295
+
296
+ `readPoRunnerLaunch(context)` from `@agimon-ai/po-runner/launch` returns the `po/runner-launch` service, whose `start`, `get`, `list`, `stop`, `logs` and `onChange` always act on the calling session. Its optional `forOwner()` takes no argument and returns the same six operations against the session's trusted owner: the workflow run's `ownerSessionId` when the session was bootstrapped as a workflow step, otherwise the session itself. Callers cannot name an owner. Check `typeof launch.forOwner === 'function'` before use, because builds that predate it lack it.
297
+
298
+ Routed starts never wake the owner's agent (`wakeOnExit` is forced off) and register with the owner's supervision, so a runner survives its workflow child and stops with the owner. Releasing the child cancels only its own pending starts before handoff and its own subscriptions. A missing or other-build owner fails with `owner unavailable` before anything spawns. Closing owners also refuse launches, with a disposed or aborted error if still registered. There is no fallback to the calling session. The `bash` tool, the `runner` namespace and the top-level launch methods stay session-local.
@@ -1,2 +1 @@
1
- import { a as stripAnsiKeepingColour, i as stripAnsi, n as scrubTerminalOutput, r as scrubTerminalOutputToPlainText, t as collapseCarriageReturns } from "./ansiScrub-CsqTSaVT.mjs";
2
- export { collapseCarriageReturns, scrubTerminalOutput, scrubTerminalOutputToPlainText, stripAnsi, stripAnsiKeepingColour };
1
+ export { t as collapseCarriageReturns, n as scrubTerminalOutput, r as scrubTerminalOutputToPlainText, i as stripAnsi, a as stripAnsiKeepingColour } from "./ansiScrub-CsqTSaVT.mjs";
@@ -50,7 +50,14 @@ const Run = typebox.Type.Object({
50
50
  finishedAt: S
51
51
  }))
52
52
  });
53
- const RunnerPayloadSchema = typebox.Type.Object({ runs: typebox.Type.Array(Run) });
53
+ const RunnerPayloadSchema = typebox.Type.Object({
54
+ runs: typebox.Type.Array(Run),
55
+ sessionDirectory: O(S),
56
+ startFailure: O(typebox.Type.Object({
57
+ id: S,
58
+ message: S
59
+ }))
60
+ });
54
61
  const RunnerLogSchema = typebox.Type.Object({
55
62
  runId: S,
56
63
  running: B,
@@ -73,6 +80,18 @@ const RunnerScreenSchema = typebox.Type.Object({
73
80
  offset: O(N),
74
81
  ended: O(B)
75
82
  });
83
+ const RunnerOutputSchema = typebox.Type.Object({
84
+ chunk: typebox.Type.String({ contentEncoding: "base64" }),
85
+ offset: typebox.Type.Integer({
86
+ minimum: 0,
87
+ maximum: Number.MAX_SAFE_INTEGER
88
+ }),
89
+ reset: B,
90
+ generation: O(S),
91
+ exists: B,
92
+ hasMore: B,
93
+ ended: B
94
+ });
76
95
  const apiContracts = (0, _agimon_ai_po_core_apiContracts.defineApiContract)({
77
96
  version: 1,
78
97
  dynamic: [],
@@ -98,6 +117,30 @@ const apiContracts = (0, _agimon_ai_po_core_apiContracts.defineApiContract)({
98
117
  })),
99
118
  responses: (0, _agimon_ai_po_core_apiContracts.jsonApiResponses)(RunnerLogSchema)
100
119
  },
120
+ ...["log", "screen"].map((kind) => ({
121
+ id: `runner.${kind}.read`,
122
+ scope: "session",
123
+ basePath: "runner",
124
+ path: `/runners/{runId}/${kind}/read`,
125
+ method: "GET",
126
+ authentication: "owner",
127
+ description: `Read at most 64 KiB of session-owned runner ${kind} bytes as base64. A completed runner remains readable; screen reads require an owned interactive multiplexer pane.`,
128
+ parameters: [{
129
+ name: "from",
130
+ in: "query",
131
+ required: false,
132
+ schema: typebox.Type.Integer({
133
+ minimum: 0,
134
+ maximum: Number.MAX_SAFE_INTEGER
135
+ })
136
+ }, ...kind === "screen" ? [{
137
+ name: "generation",
138
+ in: "query",
139
+ required: false,
140
+ schema: S
141
+ }] : []],
142
+ responses: (0, _agimon_ai_po_core_apiContracts.jsonApiResponses)(RunnerOutputSchema)
143
+ })),
101
144
  ...["log", "screen"].map((kind) => ({
102
145
  id: `runner.${kind}.stream`,
103
146
  scope: "session",
@@ -147,7 +190,7 @@ const apiContracts = (0, _agimon_ai_po_core_apiContracts.defineApiContract)({
147
190
  sockets: ["global", "workspace"].map((scope) => ({
148
191
  id: "runner.channel",
149
192
  scope,
150
- service: "po.hub.v1",
193
+ service: "po.hub",
151
194
  member: "runner_runs",
152
195
  kind: "channel",
153
196
  direction: "server-to-client",
@@ -1 +1 @@
1
- {"version":3,"file":"apiContracts.cjs","names":["Type","defineApiContract","jsonApiResponses"],"sources":["../src/schemas/apiContracts.ts"],"sourcesContent":["import { defineApiContract, jsonApiResponses } from '@agimon-ai/po-core/apiContracts';\nimport { Type } from 'typebox';\n\nconst S = Type.String();\nconst N = Type.Number();\nconst B = Type.Boolean();\nconst O = Type.Optional;\nconst literals = <T extends string>(values: T[]) => Type.Union(values.map((value) => Type.Literal(value)));\nconst Run = Type.Object({\n id: S,\n name: S,\n pid: N,\n command: S,\n cwd: S,\n interactive: B,\n backend: literals(['rmux', 'tmux', 'native']),\n state: literals(['running', 'completed']),\n promoted: B,\n startedAt: S,\n logPath: S,\n exit: O(\n Type.Object({\n reason: literals(['completed', 'failed', 'signaled', 'stopped', 'timed_out', 'launcher_error', 'backend_lost']),\n code: Type.Union([N, Type.Null()]),\n signal: Type.Union([S, Type.Null()]),\n terminationReason: O(\n literals([\n 'timeout',\n 'user_stop',\n 'request_cancelled',\n 'parent_session_cleanup',\n 'owner_lost',\n 'external_signal',\n ]),\n ),\n stopReason: O(S),\n finishedAt: S,\n }),\n ),\n});\nexport const RunnerPayloadSchema = Type.Object({ runs: Type.Array(Run) });\nexport const RunnerLogSchema = Type.Object({\n runId: S,\n running: B,\n text: S,\n lineCount: N,\n totalLines: N,\n fileSize: N,\n completeBytes: N,\n path: S,\n exists: B,\n lineNumbers: O(Type.Array(N)),\n});\nexport const RunnerAppendSchema = Type.Object({ lines: Type.Array(S), offset: O(N), ended: O(B) });\nexport const RunnerScreenSchema = Type.Object({ chunk: S, offset: O(N), ended: O(B) });\nexport const apiContracts = defineApiContract({\n version: 1,\n dynamic: [],\n http: [\n {\n id: 'runner.log',\n scope: 'session',\n basePath: 'runner',\n path: '/runners/{runId}/log',\n method: 'GET',\n authentication: 'owner',\n description: 'Read a runner log tail or literal substring search.',\n parameters: ['lines', 'grep', 'ignoreCase', 'contextLines'].map((name) => ({\n name,\n in: 'query',\n required: false,\n schema: S,\n })),\n responses: jsonApiResponses(RunnerLogSchema),\n },\n ...(['log', 'screen'] as const).map((kind) => ({\n id: `runner.${kind}.stream`,\n scope: 'session' as const,\n basePath: 'runner',\n path: `/runners/{runId}/${kind}/stream`,\n method: 'GET' as const,\n authentication: 'owner' as const,\n description: `Follow runner ${kind}. SSE data is JSON; ping events carry empty data.`,\n parameters: [{ name: 'from', in: 'query' as const, required: false, schema: N }],\n responses: {\n '200': {\n description: 'Event stream.',\n contentType: 'text/event-stream',\n schema: S,\n events: {\n [kind === 'log' ? 'append' : 'screen']: kind === 'log' ? RunnerAppendSchema : RunnerScreenSchema,\n ping: Type.Literal(''),\n },\n },\n '404': { description: 'Runner unavailable.', schema: Type.Object({ error: S }) },\n },\n })),\n {\n id: 'runner.input',\n scope: 'session',\n basePath: 'runner',\n path: '/runners/{runId}/screen/input',\n method: 'POST',\n authentication: 'owner',\n description: 'Send text to an interactive runner.',\n body: {\n required: true,\n contentType: 'application/json',\n schema: Type.Object({ text: Type.String({ minLength: 1 }) }),\n },\n responses: jsonApiResponses(Type.Object({ delivered: Type.Literal(true) })),\n },\n ],\n sockets: (['global', 'workspace'] as const).map((scope) => ({\n id: 'runner.channel',\n scope,\n service: 'po.hub.v1',\n member: 'runner_runs',\n kind: 'channel',\n direction: 'server-to-client',\n description: 'Runner channel payload in the hub frame payload property.',\n input: RunnerPayloadSchema,\n })),\n});\nexport default apiContracts;\n"],"mappings":";;;;;;;AAGA,MAAM,IAAIA,QAAAA,KAAK,OAAO;AACtB,MAAM,IAAIA,QAAAA,KAAK,OAAO;AACtB,MAAM,IAAIA,QAAAA,KAAK,QAAQ;AACvB,MAAM,IAAIA,QAAAA,KAAK;AACf,MAAM,YAA8B,WAAgBA,QAAAA,KAAK,MAAM,OAAO,KAAK,UAAUA,QAAAA,KAAK,QAAQ,KAAK,CAAC,CAAC;AACzG,MAAM,M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WAAW;EAC1D,IAAI;EACJ;EACA,SAAS;EACT,QAAQ;EACR,MAAM;EACN,WAAW;EACX,aAAa;EACb,OAAO;CACT,EAAE;AACJ,CAAC"}
1
+ {"version":3,"file":"apiContracts.cjs","names":["Type","defineApiContract","jsonApiResponses"],"sources":["../src/schemas/apiContracts.ts"],"sourcesContent":["import { defineApiContract, jsonApiResponses } from '@agimon-ai/po-core/apiContracts';\nimport { Type } from 'typebox';\n\nconst S = Type.String();\nconst N = Type.Number();\nconst B = Type.Boolean();\nconst O = Type.Optional;\nconst literals = <T extends string>(values: T[]) => Type.Union(values.map((value) => Type.Literal(value)));\nconst Run = Type.Object({\n id: S,\n name: S,\n pid: N,\n command: S,\n cwd: S,\n interactive: B,\n backend: literals(['rmux', 'tmux', 'native']),\n state: literals(['running', 'completed']),\n promoted: B,\n startedAt: S,\n logPath: S,\n exit: O(\n Type.Object({\n reason: literals(['completed', 'failed', 'signaled', 'stopped', 'timed_out', 'launcher_error', 'backend_lost']),\n code: Type.Union([N, Type.Null()]),\n signal: Type.Union([S, Type.Null()]),\n terminationReason: O(\n literals([\n 'timeout',\n 'user_stop',\n 'request_cancelled',\n 'parent_session_cleanup',\n 'owner_lost',\n 'external_signal',\n ]),\n ),\n stopReason: O(S),\n finishedAt: S,\n }),\n ),\n});\nexport const RunnerPayloadSchema = Type.Object({\n runs: Type.Array(Run),\n sessionDirectory: O(S),\n startFailure: O(Type.Object({ id: S, message: S })),\n});\nexport const RunnerLogSchema = Type.Object({\n runId: S,\n running: B,\n text: S,\n lineCount: N,\n totalLines: N,\n fileSize: N,\n completeBytes: N,\n path: S,\n exists: B,\n lineNumbers: O(Type.Array(N)),\n});\nexport const RunnerAppendSchema = Type.Object({ lines: Type.Array(S), offset: O(N), ended: O(B) });\nexport const RunnerScreenSchema = Type.Object({ chunk: S, offset: O(N), ended: O(B) });\nexport const RunnerOutputSchema = Type.Object({\n chunk: Type.String({ contentEncoding: 'base64' }),\n offset: Type.Integer({ minimum: 0, maximum: Number.MAX_SAFE_INTEGER }),\n reset: B,\n generation: O(S),\n exists: B,\n hasMore: B,\n ended: B,\n});\nexport const apiContracts = defineApiContract({\n version: 1,\n dynamic: [],\n http: [\n {\n id: 'runner.log',\n scope: 'session',\n basePath: 'runner',\n path: '/runners/{runId}/log',\n method: 'GET',\n authentication: 'owner',\n description: 'Read a runner log tail or literal substring search.',\n parameters: ['lines', 'grep', 'ignoreCase', 'contextLines'].map((name) => ({\n name,\n in: 'query',\n required: false,\n schema: S,\n })),\n responses: jsonApiResponses(RunnerLogSchema),\n },\n ...(['log', 'screen'] as const).map((kind) => ({\n id: `runner.${kind}.read`,\n scope: 'session' as const,\n basePath: 'runner',\n path: `/runners/{runId}/${kind}/read`,\n method: 'GET' as const,\n authentication: 'owner' as const,\n description: `Read at most 64 KiB of session-owned runner ${kind} bytes as base64. A completed runner remains readable; screen reads require an owned interactive multiplexer pane.`,\n parameters: [\n {\n name: 'from',\n in: 'query' as const,\n required: false,\n schema: Type.Integer({ minimum: 0, maximum: Number.MAX_SAFE_INTEGER }),\n },\n ...(kind === 'screen' ? [{ name: 'generation', in: 'query' as const, required: false, schema: S }] : []),\n ],\n responses: jsonApiResponses(RunnerOutputSchema),\n })),\n ...(['log', 'screen'] as const).map((kind) => ({\n id: `runner.${kind}.stream`,\n scope: 'session' as const,\n basePath: 'runner',\n path: `/runners/{runId}/${kind}/stream`,\n method: 'GET' as const,\n authentication: 'owner' as const,\n description: `Follow runner ${kind}. SSE data is JSON; ping events carry empty data.`,\n parameters: [{ name: 'from', in: 'query' as const, required: false, schema: N }],\n responses: {\n '200': {\n description: 'Event stream.',\n contentType: 'text/event-stream',\n schema: S,\n events: {\n [kind === 'log' ? 'append' : 'screen']: kind === 'log' ? RunnerAppendSchema : RunnerScreenSchema,\n ping: Type.Literal(''),\n },\n },\n '404': { description: 'Runner unavailable.', schema: Type.Object({ error: S }) },\n },\n })),\n {\n id: 'runner.input',\n scope: 'session',\n basePath: 'runner',\n path: '/runners/{runId}/screen/input',\n method: 'POST',\n authentication: 'owner',\n description: 'Send text to an interactive runner.',\n body: {\n required: true,\n contentType: 'application/json',\n schema: Type.Object({ text: Type.String({ minLength: 1 }) }),\n },\n responses: jsonApiResponses(Type.Object({ delivered: Type.Literal(true) })),\n },\n ],\n sockets: (['global', 'workspace'] as const).map((scope) => ({\n id: 'runner.channel',\n scope,\n service: 'po.hub',\n member: 'runner_runs',\n kind: 'channel',\n direction: 'server-to-client',\n description: 'Runner channel payload in the hub frame payload property.',\n input: RunnerPayloadSchema,\n })),\n});\nexport default apiContracts;\n"],"mappings":";;;;;;;AAGA,MAAM,IAAIA,QAAAA,KAAK,OAAO;AACtB,MAAM,IAAIA,QAAAA,KAAK,OAAO;AACtB,MAAM,IAAIA,QAAAA,KAAK,QAAQ;AACvB,MAAM,IAAIA,QAAAA,KAAK;AACf,MAAM,YAA8B,WAAgBA,QAAAA,KAAK,MAAM,OAAO,KAAK,UAAUA,QAAAA,KAAK,QAAQ,KAAK,CAAC,CAAC;AACzG,MAAM,MAAMA,QAAAA,KAAK,OAAO;CACtB,IAAI;CACJ,MAAM;CACN,KAAK;CACL,SAAS;CACT,KAAK;CACL,aAAa;CACb,SAAS,SAAS;EAAC;EAAQ;EAAQ;CAAQ,CAAC;CAC5C,OAAO,SAAS,CAAC,WAAW,WAAW,CAAC;CACxC,UAAU;CACV,WAAW;CACX,SAAS;CACT,MAAM,EACJA,QAAAA,KAAK,OAAO;EACV,QAAQ,SAAS;GAAC;GAAa;GAAU;GAAY;GAAW;GAAa;GAAkB;EAAc,CAAC;EAC9G,MAAMA,QAAAA,KAAK,MAAM,CAAC,GAAGA,QAAAA,KAAK,KAAK,CAAC,CAAC;EACjC,QAAQA,QAAAA,KAAK,MAAM,CAAC,GAAGA,QAAAA,KAAK,KAAK,CAAC,CAAC;EACnC,mBAAmB,EACjB,SAAS;GACP;GACA;GACA;GACA;GACA;GACA;EACF,CAAC,CACH;EACA,YAAY,EAAE,CAAC;EACf,YAAY;CAC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O,EAAE,MAAMA,QAAAA,KAAK,OAAO,EAAE,WAAW,EAAE,CAAC,EAAE,CAAC;GAC7D;GACA,YAAA,GAAWE,gCAAAA,iBAAAA,CAAiBF,QAAAA,KAAK,OAAO,EAAE,WAAWA,QAAAA,KAAK,QAAQ,IAAI,EAAE,CAAC,CAAC;EAC5E;CACF;CACA,SAAU,CAAC,UAAU,WAAW,CAAC,CAAW,KAAK,WAAW;EAC1D,IAAI;EACJ;EACA,SAAS;EACT,QAAQ;EACR,MAAM;EACN,WAAW;EACX,aAAa;EACb,OAAO;CACT,EAAE;AACJ,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"apiContracts.d.mts","names":[],"sources":["../src/schemas/apiContracts.ts"],"mappings":";;qBAuDa"}
1
+ {"version":3,"file":"apiContracts.d.mts","names":[],"sources":["../src/schemas/apiContracts.ts"],"mappings":";;qBAoEa"}
@@ -46,7 +46,14 @@ const Run = Type.Object({
46
46
  finishedAt: S
47
47
  }))
48
48
  });
49
- const RunnerPayloadSchema = Type.Object({ runs: Type.Array(Run) });
49
+ const RunnerPayloadSchema = Type.Object({
50
+ runs: Type.Array(Run),
51
+ sessionDirectory: O(S),
52
+ startFailure: O(Type.Object({
53
+ id: S,
54
+ message: S
55
+ }))
56
+ });
50
57
  const RunnerLogSchema = Type.Object({
51
58
  runId: S,
52
59
  running: B,
@@ -69,6 +76,18 @@ const RunnerScreenSchema = Type.Object({
69
76
  offset: O(N),
70
77
  ended: O(B)
71
78
  });
79
+ const RunnerOutputSchema = Type.Object({
80
+ chunk: Type.String({ contentEncoding: "base64" }),
81
+ offset: Type.Integer({
82
+ minimum: 0,
83
+ maximum: Number.MAX_SAFE_INTEGER
84
+ }),
85
+ reset: B,
86
+ generation: O(S),
87
+ exists: B,
88
+ hasMore: B,
89
+ ended: B
90
+ });
72
91
  const apiContracts = defineApiContract({
73
92
  version: 1,
74
93
  dynamic: [],
@@ -94,6 +113,30 @@ const apiContracts = defineApiContract({
94
113
  })),
95
114
  responses: jsonApiResponses(RunnerLogSchema)
96
115
  },
116
+ ...["log", "screen"].map((kind) => ({
117
+ id: `runner.${kind}.read`,
118
+ scope: "session",
119
+ basePath: "runner",
120
+ path: `/runners/{runId}/${kind}/read`,
121
+ method: "GET",
122
+ authentication: "owner",
123
+ description: `Read at most 64 KiB of session-owned runner ${kind} bytes as base64. A completed runner remains readable; screen reads require an owned interactive multiplexer pane.`,
124
+ parameters: [{
125
+ name: "from",
126
+ in: "query",
127
+ required: false,
128
+ schema: Type.Integer({
129
+ minimum: 0,
130
+ maximum: Number.MAX_SAFE_INTEGER
131
+ })
132
+ }, ...kind === "screen" ? [{
133
+ name: "generation",
134
+ in: "query",
135
+ required: false,
136
+ schema: S
137
+ }] : []],
138
+ responses: jsonApiResponses(RunnerOutputSchema)
139
+ })),
97
140
  ...["log", "screen"].map((kind) => ({
98
141
  id: `runner.${kind}.stream`,
99
142
  scope: "session",
@@ -143,7 +186,7 @@ const apiContracts = defineApiContract({
143
186
  sockets: ["global", "workspace"].map((scope) => ({
144
187
  id: "runner.channel",
145
188
  scope,
146
- service: "po.hub.v1",
189
+ service: "po.hub",
147
190
  member: "runner_runs",
148
191
  kind: "channel",
149
192
  direction: "server-to-client",
@@ -1 +1 @@
1
- {"version":3,"file":"apiContracts.mjs","names":[],"sources":["../src/schemas/apiContracts.ts"],"sourcesContent":["import { defineApiContract, jsonApiResponses } from '@agimon-ai/po-core/apiContracts';\nimport { Type } from 'typebox';\n\nconst S = Type.String();\nconst N = Type.Number();\nconst B = Type.Boolean();\nconst O = Type.Optional;\nconst literals = <T extends string>(values: T[]) => Type.Union(values.map((value) => Type.Literal(value)));\nconst Run = Type.Object({\n id: S,\n name: S,\n pid: N,\n command: S,\n cwd: S,\n interactive: B,\n backend: literals(['rmux', 'tmux', 'native']),\n state: literals(['running', 'completed']),\n promoted: B,\n startedAt: S,\n logPath: S,\n exit: O(\n Type.Object({\n reason: literals(['completed', 'failed', 'signaled', 'stopped', 'timed_out', 'launcher_error', 'backend_lost']),\n code: Type.Union([N, Type.Null()]),\n signal: Type.Union([S, Type.Null()]),\n terminationReason: O(\n literals([\n 'timeout',\n 'user_stop',\n 'request_cancelled',\n 'parent_session_cleanup',\n 'owner_lost',\n 'external_signal',\n ]),\n ),\n stopReason: O(S),\n finishedAt: S,\n }),\n ),\n});\nexport const RunnerPayloadSchema = Type.Object({ runs: Type.Array(Run) });\nexport const RunnerLogSchema = Type.Object({\n runId: S,\n running: B,\n text: S,\n lineCount: N,\n totalLines: N,\n fileSize: N,\n completeBytes: N,\n path: S,\n exists: B,\n lineNumbers: O(Type.Array(N)),\n});\nexport const RunnerAppendSchema = Type.Object({ lines: Type.Array(S), offset: O(N), ended: O(B) });\nexport const RunnerScreenSchema = Type.Object({ chunk: S, offset: O(N), ended: O(B) });\nexport const apiContracts = defineApiContract({\n version: 1,\n dynamic: [],\n http: [\n {\n id: 'runner.log',\n scope: 'session',\n basePath: 'runner',\n path: '/runners/{runId}/log',\n method: 'GET',\n authentication: 'owner',\n description: 'Read a runner log tail or literal substring search.',\n parameters: ['lines', 'grep', 'ignoreCase', 'contextLines'].map((name) => ({\n name,\n in: 'query',\n required: false,\n schema: S,\n })),\n responses: jsonApiResponses(RunnerLogSchema),\n },\n ...(['log', 'screen'] as const).map((kind) => ({\n id: `runner.${kind}.stream`,\n scope: 'session' as const,\n basePath: 'runner',\n path: `/runners/{runId}/${kind}/stream`,\n method: 'GET' as const,\n authentication: 'owner' as const,\n description: `Follow runner ${kind}. SSE data is JSON; ping events carry empty data.`,\n parameters: [{ name: 'from', in: 'query' as const, required: false, schema: N }],\n responses: {\n '200': {\n description: 'Event stream.',\n contentType: 'text/event-stream',\n schema: S,\n events: {\n [kind === 'log' ? 'append' : 'screen']: kind === 'log' ? RunnerAppendSchema : RunnerScreenSchema,\n ping: Type.Literal(''),\n },\n },\n '404': { description: 'Runner unavailable.', schema: Type.Object({ error: S }) },\n },\n })),\n {\n id: 'runner.input',\n scope: 'session',\n basePath: 'runner',\n path: '/runners/{runId}/screen/input',\n method: 'POST',\n authentication: 'owner',\n description: 'Send text to an interactive runner.',\n body: {\n required: true,\n contentType: 'application/json',\n schema: Type.Object({ text: Type.String({ minLength: 1 }) }),\n },\n responses: jsonApiResponses(Type.Object({ delivered: Type.Literal(true) })),\n },\n ],\n sockets: (['global', 'workspace'] as const).map((scope) => ({\n id: 'runner.channel',\n scope,\n service: 'po.hub.v1',\n member: 'runner_runs',\n kind: 'channel',\n direction: 'server-to-client',\n description: 'Runner channel payload in the hub frame payload property.',\n input: RunnerPayloadSchema,\n })),\n});\nexport default apiContracts;\n"],"mappings":";;;AAGA,MAAM,IAAI,KAAK,OAAO;AACtB,MAAM,IAAI,KAAK,OAAO;AACtB,MAAM,IAAI,KAAK,QAAQ;AACvB,MAAM,IAAI,KAAK;AACf,MAAM,YAA8B,WAAgB,KAAK,MAAM,OAAO,KAAK,UAAU,KAAK,QAAQ,KAAK,CAAC,CAAC;AACzG,MAAM,MAAM,KAAK,OAAO;CACtB,IAAI;CACJ,MAAM;CACN,KAAK;CACL,SAAS;CACT,KAAK;CACL,aAAa;CACb,SAAS,SAAS;EAAC;EAAQ;EAAQ;CAAQ,CAAC;CAC5C,OAAO,SAAS,CAAC,WAAW,WAAW,CAAC;CACxC,UAAU;CACV,WAAW;CACX,SAAS;CACT,MAAM,EACJ,KAAK,OAAO;EACV,QAAQ,SAAS;GAAC;GAAa;GAAU;GAAY;GAAW;GAAa;GAAkB;EAAc,CAAC;EAC9G,MAAM,KAAK,MAAM,CAAC,GAAG,KAAK,KAAK,CAAC,CAAC;EACjC,QAAQ,KAAK,MAAM,CAAC,GAAG,KAAK,KAAK,CAAC,CAAC;EACnC,mBAAmB,EACjB,SAAS;GACP;GACA;GACA;GACA;GACA;GACA;EACF,CAAC,CACH;EACA,YAAY,EAAE,CAAC;EACf,YAAY;CACd,CAAC,CACH;AACF,CAAC;AACD,MAAa,sBAAsB,KAAK,OAAO,EAAE,MAAM,KAAK,MAAM,GAAG,EA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;IAAE;GACjF;EACF,EAAE;EACF;GACE,IAAI;GACJ,OAAO;GACP,UAAU;GACV,MAAM;GACN,QAAQ;GACR,gBAAgB;GAChB,aAAa;GACb,MAAM;IACJ,UAAU;IACV,aAAa;IACb,QAAQ,KAAK,OAAO,EAAE,MAAM,KAAK,OAAO,EAAE,WAAW,EAAE,CAAC,EAAE,CAAC;GAC7D;GACA,WAAW,iBAAiB,KAAK,OAAO,EAAE,WAAW,KAAK,QAAQ,IAAI,EAAE,CAAC,CAAC;EAC5E;CACF;CACA,SAAU,CAAC,UAAU,WAAW,CAAC,CAAW,KAAK,WAAW;EAC1D,IAAI;EACJ;EACA,SAAS;EACT,QAAQ;EACR,MAAM;EACN,WAAW;EACX,aAAa;EACb,OAAO;CACT,EAAE;AACJ,CAAC"}
1
+ {"version":3,"file":"apiContracts.mjs","names":[],"sources":["../src/schemas/apiContracts.ts"],"sourcesContent":["import { defineApiContract, jsonApiResponses } from '@agimon-ai/po-core/apiContracts';\nimport { Type } from 'typebox';\n\nconst S = Type.String();\nconst N = Type.Number();\nconst B = Type.Boolean();\nconst O = Type.Optional;\nconst literals = <T extends string>(values: T[]) => Type.Union(values.map((value) => Type.Literal(value)));\nconst Run = Type.Object({\n id: S,\n name: S,\n pid: N,\n command: S,\n cwd: S,\n interactive: B,\n backend: literals(['rmux', 'tmux', 'native']),\n state: literals(['running', 'completed']),\n promoted: B,\n startedAt: S,\n logPath: S,\n exit: O(\n Type.Object({\n reason: literals(['completed', 'failed', 'signaled', 'stopped', 'timed_out', 'launcher_error', 'backend_lost']),\n code: Type.Union([N, Type.Null()]),\n signal: Type.Union([S, Type.Null()]),\n terminationReason: O(\n literals([\n 'timeout',\n 'user_stop',\n 'request_cancelled',\n 'parent_session_cleanup',\n 'owner_lost',\n 'external_signal',\n ]),\n ),\n stopReason: O(S),\n finishedAt: S,\n }),\n ),\n});\nexport const RunnerPayloadSchema = Type.Object({\n runs: Type.Array(Run),\n sessionDirectory: O(S),\n startFailure: O(Type.Object({ id: S, message: S })),\n});\nexport const RunnerLogSchema = Type.Object({\n runId: S,\n running: B,\n text: S,\n lineCount: N,\n totalLines: N,\n fileSize: N,\n completeBytes: N,\n path: S,\n exists: B,\n lineNumbers: O(Type.Array(N)),\n});\nexport const RunnerAppendSchema = Type.Object({ lines: Type.Array(S), offset: O(N), ended: O(B) });\nexport const RunnerScreenSchema = Type.Object({ chunk: S, offset: O(N), ended: O(B) });\nexport const RunnerOutputSchema = Type.Object({\n chunk: Type.String({ contentEncoding: 'base64' }),\n offset: Type.Integer({ minimum: 0, maximum: Number.MAX_SAFE_INTEGER }),\n reset: B,\n generation: O(S),\n exists: B,\n hasMore: B,\n ended: B,\n});\nexport const apiContracts = defineApiContract({\n version: 1,\n dynamic: [],\n http: [\n {\n id: 'runner.log',\n scope: 'session',\n basePath: 'runner',\n path: '/runners/{runId}/log',\n method: 'GET',\n authentication: 'owner',\n description: 'Read a runner log tail or literal substring search.',\n parameters: ['lines', 'grep', 'ignoreCase', 'contextLines'].map((name) => ({\n name,\n in: 'query',\n required: false,\n schema: S,\n })),\n responses: jsonApiResponses(RunnerLogSchema),\n },\n ...(['log', 'screen'] as const).map((kind) => ({\n id: `runner.${kind}.read`,\n scope: 'session' as const,\n basePath: 'runner',\n path: `/runners/{runId}/${kind}/read`,\n method: 'GET' as const,\n authentication: 'owner' as const,\n description: `Read at most 64 KiB of session-owned runner ${kind} bytes as base64. A completed runner remains readable; screen reads require an owned interactive multiplexer pane.`,\n parameters: [\n {\n name: 'from',\n in: 'query' as const,\n required: false,\n schema: Type.Integer({ minimum: 0, maximum: Number.MAX_SAFE_INTEGER }),\n },\n ...(kind === 'screen' ? [{ name: 'generation', in: 'query' as const, required: false, schema: S }] : []),\n ],\n responses: jsonApiResponses(RunnerOutputSchema),\n })),\n ...(['log', 'screen'] as const).map((kind) => ({\n id: `runner.${kind}.stream`,\n scope: 'session' as const,\n basePath: 'runner',\n path: `/runners/{runId}/${kind}/stream`,\n method: 'GET' as const,\n authentication: 'owner' as const,\n description: `Follow runner ${kind}. SSE data is JSON; ping events carry empty data.`,\n parameters: [{ name: 'from', in: 'query' as const, required: false, schema: N }],\n responses: {\n '200': {\n description: 'Event stream.',\n contentType: 'text/event-stream',\n schema: S,\n events: {\n [kind === 'log' ? 'append' : 'screen']: kind === 'log' ? RunnerAppendSchema : RunnerScreenSchema,\n ping: Type.Literal(''),\n },\n },\n '404': { description: 'Runner unavailable.', schema: Type.Object({ error: S }) },\n },\n })),\n {\n id: 'runner.input',\n scope: 'session',\n basePath: 'runner',\n path: '/runners/{runId}/screen/input',\n method: 'POST',\n authentication: 'owner',\n description: 'Send text to an interactive runner.',\n body: {\n required: true,\n contentType: 'application/json',\n schema: Type.Object({ text: Type.String({ minLength: 1 }) }),\n },\n responses: jsonApiResponses(Type.Object({ delivered: Type.Literal(true) })),\n },\n ],\n sockets: (['global', 'workspace'] as const).map((scope) => ({\n id: 'runner.channel',\n scope,\n service: 'po.hub',\n member: 'runner_runs',\n kind: 'channel',\n direction: 'server-to-client',\n description: 'Runner channel payload in the hub frame payload property.',\n input: RunnerPayloadSchema,\n })),\n});\nexport default apiContracts;\n"],"mappings":";;;AAGA,MAAM,IAAI,KAAK,OAAO;AACtB,MAAM,IAAI,KAAK,OAAO;AACtB,MAAM,IAAI,KAAK,QAAQ;AACvB,MAAM,IAAI,KAAK;AACf,MAAM,YAA8B,WAAgB,KAAK,MAAM,OAAO,KAAK,UAAU,KAAK,QAAQ,KAAK,CAAC,CAAC;AACzG,MAAM,MAAM,KAAK,OAAO;CACtB,IAAI;CACJ,MAAM;CACN,KAAK;CACL,SAAS;CACT,KAAK;CACL,aAAa;CACb,SAAS,SAAS;EAAC;EAAQ;EAAQ;CAAQ,CAAC;CAC5C,OAAO,SAAS,CAAC,WAAW,WAAW,CAAC;CACxC,UAAU;CACV,WAAW;CACX,SAAS;CACT,MAAM,EACJ,KAAK,OAAO;EACV,QAAQ,SAAS;GAAC;GAAa;GAAU;GAAY;GAAW;GAAa;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