@mininglamp-oss/octo-runtime 1.1.9 → 1.1.11

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 (225) hide show
  1. package/README.md +2 -2
  2. package/apps/cli/README.md +1 -1
  3. package/{node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/runtime-configuration.d.ts → apps/cli/dist/adapter-configuration.d.ts} +1 -0
  4. package/{node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/runtime-configuration.js → apps/cli/dist/adapter-configuration.js} +1 -0
  5. package/apps/cli/dist/adapter-configurations.d.ts +1 -1
  6. package/apps/cli/dist/adapter-configurations.js +1 -1
  7. package/apps/cli/dist/adapters.d.ts +7 -0
  8. package/apps/cli/dist/adapters.js +77 -0
  9. package/apps/cli/dist/build-info.json +2 -2
  10. package/apps/cli/dist/command-tree.js +2 -3
  11. package/apps/cli/dist/extras.js +11 -1
  12. package/apps/cli/dist/help.js +1 -1
  13. package/apps/cli/dist/index.js +18 -1
  14. package/apps/cli/dist/main.d.ts +2 -0
  15. package/apps/cli/dist/main.js +67 -34
  16. package/apps/cli/dist/manifest.json +0 -5
  17. package/apps/cli/dist/module-manifest.js +21 -3
  18. package/apps/cli/dist/output.d.ts +19 -1
  19. package/apps/cli/dist/output.js +180 -33
  20. package/apps/cli/dist/playboard-interrupt.d.ts +6 -0
  21. package/apps/cli/dist/playboard-interrupt.js +86 -0
  22. package/apps/cli/dist/playboard.d.ts +2 -0
  23. package/apps/cli/dist/playboard.js +10 -11
  24. package/apps/cli/dist/state.d.ts +5 -2
  25. package/apps/cli/dist/state.js +48 -13
  26. package/dist/public/codex.d.ts +1 -0
  27. package/dist/public/codex.js +1 -0
  28. package/dist/public/executor-kernel.d.ts +4 -1
  29. package/dist/public/executor-kernel.js +2 -1
  30. package/dist/public/extra.d.ts +1 -1
  31. package/dist/public/host.d.ts +5 -0
  32. package/dist/public/host.js +2 -0
  33. package/node_modules/@mininglamp-oss/octo-runtime-acp-client/package.json +3 -3
  34. package/node_modules/@mininglamp-oss/octo-runtime-adapter-acp/dist/index.js +20 -0
  35. package/node_modules/@mininglamp-oss/octo-runtime-adapter-acp/package.json +4 -4
  36. package/node_modules/@mininglamp-oss/octo-runtime-adapter-antigravity/package.json +3 -3
  37. package/node_modules/@mininglamp-oss/octo-runtime-adapter-claude-code/package.json +3 -3
  38. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codebuddy/package.json +4 -4
  39. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/app-server.d.ts +6 -6
  40. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/app-server.js +68 -253
  41. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/index.d.ts +11 -6
  42. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/index.js +198 -52
  43. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/service.d.ts +58 -0
  44. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/service.js +650 -0
  45. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/stdin-writer.d.ts +3 -0
  46. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/stdin-writer.js +15 -0
  47. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/package.json +3 -3
  48. package/node_modules/@mininglamp-oss/octo-runtime-adapter-dsh/package.json +3 -3
  49. package/node_modules/@mininglamp-oss/octo-runtime-adapter-grok-build/package.json +5 -5
  50. package/node_modules/@mininglamp-oss/octo-runtime-adapter-hermes/package.json +2 -2
  51. package/node_modules/@mininglamp-oss/octo-runtime-adapter-kimi-code/package.json +2 -2
  52. package/node_modules/@mininglamp-oss/octo-runtime-adapter-mcode/package.json +2 -2
  53. package/node_modules/@mininglamp-oss/octo-runtime-adapter-openclaw/package.json +3 -3
  54. package/node_modules/@mininglamp-oss/octo-runtime-adapter-opencode/dist/index.d.ts +2 -0
  55. package/node_modules/@mininglamp-oss/octo-runtime-adapter-opencode/package.json +4 -4
  56. package/node_modules/@mininglamp-oss/octo-runtime-adapter-qodercli/package.json +2 -2
  57. package/node_modules/@mininglamp-oss/octo-runtime-adapter-qoderclicn/package.json +2 -2
  58. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/activity.d.ts +5 -0
  59. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/execution-scope.d.ts +25 -0
  60. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/index.d.ts +3 -0
  61. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/reasoning.js +1 -2
  62. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/service-status.d.ts +1 -1
  63. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/service-status.js +12 -30
  64. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/package.json +2 -2
  65. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/adapter-configuration.d.ts +3 -0
  66. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/adapter-configuration.js +125 -0
  67. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/adapter-configurations.d.ts +1 -1
  68. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/adapter-configurations.js +1 -1
  69. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/adapters.d.ts +7 -0
  70. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/adapters.js +77 -0
  71. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/build-info.json +2 -2
  72. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/command-tree.js +2 -3
  73. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/extras.js +11 -1
  74. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/help.js +1 -1
  75. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/index.js +18 -1
  76. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/main.d.ts +2 -0
  77. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/main.js +67 -34
  78. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/manifest.json +0 -5
  79. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/module-manifest.js +21 -3
  80. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/output.d.ts +19 -1
  81. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/output.js +180 -33
  82. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/playboard-interrupt.d.ts +6 -0
  83. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/playboard-interrupt.js +86 -0
  84. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/playboard.d.ts +2 -0
  85. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/playboard.js +10 -11
  86. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/state.d.ts +5 -2
  87. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/state.js +48 -13
  88. package/node_modules/@mininglamp-oss/octo-runtime-cli/package.json +23 -24
  89. package/node_modules/@mininglamp-oss/octo-runtime-client/build-info.json +5 -0
  90. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/async-question-reply.d.ts +30 -0
  91. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/async-question-reply.js +199 -0
  92. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/browser.d.ts +1 -0
  93. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/browser.js +1 -0
  94. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/client.d.ts +10 -0
  95. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/client.js +465 -0
  96. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/index.d.ts +6 -0
  97. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/index.js +6 -0
  98. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/internal.d.ts +4 -0
  99. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/internal.js +5 -0
  100. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/invocation-lifecycle.d.ts +59 -0
  101. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/invocation-lifecycle.js +287 -0
  102. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/notification.d.ts +1 -0
  103. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/notification.js +1 -0
  104. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/protocol.d.ts +1 -0
  105. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/protocol.js +1 -0
  106. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/runtime-path.d.ts +21 -0
  107. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/runtime-path.js +138 -0
  108. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/startup-catalog.d.ts +8 -0
  109. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/startup-catalog.js +65 -0
  110. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/startup-diagnostics.d.ts +82 -0
  111. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/startup-diagnostics.js +371 -0
  112. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/submission-error.d.ts +10 -0
  113. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/submission-error.js +23 -0
  114. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/types.d.ts +72 -0
  115. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/types.js +10 -0
  116. package/node_modules/@mininglamp-oss/octo-runtime-client/package.json +54 -0
  117. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/context-configuration-fixtures.json +1219 -0
  118. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/context-fixtures.json +5988 -0
  119. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/kernel-client.behavior.json +56 -0
  120. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/kernel-ipc-fixtures.json +53 -0
  121. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/kernel-ipc.schema.json +538 -0
  122. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/native-invoke-fixtures.json +116 -0
  123. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/protocol.schema.json +4525 -0
  124. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/run-protocol-fixtures.json +761 -0
  125. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/runtime-selection-fixtures.json +663 -0
  126. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/session-name-fixtures.json +191 -0
  127. package/node_modules/@mininglamp-oss/octo-runtime-cross-service/package.json +1 -1
  128. package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/index.d.ts +29 -21
  129. package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/index.js +173 -14
  130. package/node_modules/@mininglamp-oss/octo-runtime-executor-core/package.json +3 -3
  131. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/async-question-reply.d.ts +1 -30
  132. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/async-question-reply.js +2 -199
  133. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/client.d.ts +1 -8
  134. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/client.js +2 -444
  135. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/endpoint.js +2 -0
  136. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/execution-source.d.ts +17 -0
  137. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/execution-source.js +21 -0
  138. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/host-run-service.d.ts +11 -9
  139. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/host-run-service.js +14 -3
  140. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/index.d.ts +5 -7
  141. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/index.js +6 -7
  142. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/invocation-lifecycle.d.ts +1 -53
  143. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/invocation-lifecycle.js +2 -280
  144. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/invocation-manifest.d.ts +14 -13
  145. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/invocation-manifest.js +84 -187
  146. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/lifecycle.d.ts +5 -10
  147. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/lifecycle.js +4 -1
  148. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/runtime-home.d.ts +20 -0
  149. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/runtime-home.js +180 -0
  150. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/server.d.ts +5 -8
  151. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/server.js +75 -45
  152. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/service.d.ts +9 -2
  153. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/service.js +60 -5
  154. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/startup-catalog.d.ts +1 -0
  155. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/startup-catalog.js +1 -0
  156. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/startup-diagnostics.d.ts +1 -0
  157. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/startup-diagnostics.js +1 -0
  158. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/startup-logging.d.ts +4 -0
  159. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/startup-logging.js +18 -0
  160. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/submission-error.d.ts +1 -10
  161. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/submission-error.js +2 -23
  162. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/types.d.ts +2 -72
  163. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/types.js +2 -10
  164. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/package.json +5 -12
  165. package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/extra.js +1 -1
  166. package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/dist/ports.d.ts +2 -2
  167. package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-gateway/package.json +6 -6
  168. package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/extra.js +1 -1
  169. package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/dist/ports.d.ts +2 -2
  170. package/node_modules/@mininglamp-oss/octo-runtime-extra-channel-wecom/package.json +5 -5
  171. package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/index.js +4 -4
  172. package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/web/assets/{index-BVxePruX.js → index-BLMf2Etg.js} +1 -3
  173. package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/dist/web/index.html +1 -1
  174. package/node_modules/@mininglamp-oss/octo-runtime-extra-webui/package.json +2 -2
  175. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/endpoint.d.ts +1 -1
  176. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/endpoint.js +12 -5
  177. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/errors.d.ts +5 -1
  178. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/errors.js +9 -0
  179. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/execution.d.ts +44 -0
  180. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/execution.js +207 -0
  181. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-config.js +23 -3
  182. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-service.d.ts +27 -4
  183. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extra-service.js +133 -25
  184. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extras.d.ts +10 -3
  185. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/extras.js +18 -4
  186. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/home.d.ts +5 -6
  187. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/home.js +33 -45
  188. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/identity.js +6 -0
  189. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/index.d.ts +4 -0
  190. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/dist/index.js +3 -0
  191. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/package.json +5 -4
  192. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/adapter-metadata.d.ts +7 -0
  193. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/generated/protocol-types.d.ts +19 -15
  194. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/index.d.ts +3 -1
  195. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/index.js +1 -0
  196. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/service-processes.d.ts +5 -0
  197. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/service-processes.js +65 -0
  198. package/node_modules/@mininglamp-oss/octo-runtime-protocol/package.json +1 -1
  199. package/package.json +33 -29
  200. package/packages/octo-runtime-protocol/schema/protocol.schema.json +42 -36
  201. package/apps/cli/dist/worker.js +0 -18
  202. package/node_modules/@mininglamp-oss/octo-runtime-adapter-zcode-gui/dist/app-server.d.ts +0 -63
  203. package/node_modules/@mininglamp-oss/octo-runtime-adapter-zcode-gui/dist/app-server.js +0 -846
  204. package/node_modules/@mininglamp-oss/octo-runtime-adapter-zcode-gui/dist/index.d.ts +0 -54
  205. package/node_modules/@mininglamp-oss/octo-runtime-adapter-zcode-gui/dist/index.js +0 -154
  206. package/node_modules/@mininglamp-oss/octo-runtime-adapter-zcode-gui/package.json +0 -15
  207. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/worker.js +0 -18
  208. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/heartbeat.d.ts +0 -16
  209. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/heartbeat.js +0 -59
  210. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/manifest-adapters.d.ts +0 -6
  211. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/manifest-adapters.js +0 -88
  212. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/module-specifier.d.ts +0 -1
  213. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/module-specifier.js +0 -2
  214. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/process.d.ts +0 -42
  215. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/process.js +0 -292
  216. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/rpc.d.ts +0 -64
  217. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/rpc.js +0 -674
  218. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/runner.d.ts +0 -2
  219. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/runner.js +0 -5
  220. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/serve.d.ts +0 -10
  221. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/serve.js +0 -96
  222. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/supervisor.d.ts +0 -15
  223. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/supervisor.js +0 -279
  224. /package/{apps/cli/dist/worker.d.ts → node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/execution-scope.js} +0 -0
  225. /package/node_modules/@mininglamp-oss/{octo-runtime-cli/dist/worker.d.ts → octo-runtime-protocol/dist/adapter-metadata.js} +0 -0
@@ -1,3 +1,3 @@
1
- <!doctype html><html lang="zh-CN"><head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><title>Octo Runtime</title> <script type="module" crossorigin src="/assets/index-BVxePruX.js"></script>
1
+ <!doctype html><html lang="zh-CN"><head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><title>Octo Runtime</title> <script type="module" crossorigin src="/assets/index-BLMf2Etg.js"></script>
2
2
  <link rel="stylesheet" crossorigin href="/assets/index-CYTpqItx.css">
3
3
  </head><body><div id="root"></div></body></html>
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mininglamp-oss/octo-runtime-extra-webui",
3
- "version": "1.1.9",
3
+ "version": "1.1.11",
4
4
  "private": true,
5
5
  "type": "module",
6
6
  "description": "Local Runtime workbench with canonical SSE presentation",
@@ -23,6 +23,6 @@
23
23
  "porting-map.md"
24
24
  ],
25
25
  "dependencies": {
26
- "@mininglamp-oss/octo-runtime-protocol": "1.1.9"
26
+ "@mininglamp-oss/octo-runtime-protocol": "1.1.11"
27
27
  }
28
28
  }
@@ -1,6 +1,6 @@
1
1
  /** 按选定平台规范化 Home 字符串;Windows 忽略大小写,其他平台保留大小写,不访问文件系统。 */
2
2
  export declare function normalizedHome(home: string, platform?: NodeJS.Platform): string;
3
3
  export declare function homeHash(home: string, platform?: NodeJS.Platform): string;
4
- /** 按 Home 和组件派生本地 IPC 地址;平台路径差异在内部处理,无需调用方转换路径。 */
4
+ /** 纯计算 Home 对应地址并检查传输预算;不准备目录,真实存在/权限由服务 initialize 再校验。 */
5
5
  export declare function componentEndpoint(home: string, component?: string, platform?: NodeJS.Platform): string;
6
6
  export declare function componentServiceId(home: string, component: string, platform?: NodeJS.Platform): string;
@@ -1,19 +1,26 @@
1
1
  import { createHash } from "node:crypto";
2
- import { posix, win32 } from "node:path";
2
+ import { posix } from "node:path";
3
+ import { normalizeRuntimeHome, assertIpcEndpoint, assertRuntimePath } from "@mininglamp-oss/octo-runtime-executor-kernel";
3
4
  /** 按选定平台规范化 Home 字符串;Windows 忽略大小写,其他平台保留大小写,不访问文件系统。 */
4
5
  export function normalizedHome(home, platform = process.platform) {
5
- return platform === "win32" ? win32.resolve(home).toLowerCase() : posix.resolve(home);
6
+ const absolute = normalizeRuntimeHome(home, platform);
7
+ return platform === "win32" ? absolute.toLowerCase() : absolute;
6
8
  }
7
9
  export function homeHash(home, platform = process.platform) {
8
10
  return createHash("sha256").update(normalizedHome(home, platform)).digest("hex").slice(0, 16);
9
11
  }
10
- /** 按 Home 和组件派生本地 IPC 地址;平台路径差异在内部处理,无需调用方转换路径。 */
12
+ /** 纯计算 Home 对应地址并检查传输预算;不准备目录,真实存在/权限由服务 initialize 再校验。 */
11
13
  export function componentEndpoint(home, component = "executor-kernel", platform = process.platform) {
12
14
  if (!/^[a-z][a-z0-9-]{0,69}$/.test(component))
13
15
  throw new Error("COMPONENT_INVALID");
14
- return platform === "win32"
16
+ assertRuntimePath(normalizedHome(home, platform), "home", platform);
17
+ const endpoint = platform === "win32"
15
18
  ? `\\\\.\\pipe\\octo-runtime-${component === "executor-kernel" ? "kernel" : component}-${homeHash(home, platform)}`
16
- : posix.join(normalizedHome(home, platform), "sockets", `octo-runtime-${component}.sock`);
19
+ : component === "executor-kernel"
20
+ ? posix.join(normalizedHome(home, platform), "executor-kernel.sock")
21
+ : posix.join(normalizedHome(home, platform), "sockets", `octo-runtime-${component}.sock`);
22
+ assertIpcEndpoint(endpoint, platform);
23
+ return endpoint;
17
24
  }
18
25
  export function componentServiceId(home, component, platform = process.platform) {
19
26
  if (!/^[a-z][a-z0-9-]{0,69}$/.test(component))
@@ -1,6 +1,10 @@
1
+ import { type StartupContext, type StartupDiagnostic } from "@mininglamp-oss/octo-runtime-executor-kernel";
1
2
  export declare class HostRuntimeError extends Error {
2
3
  readonly code: string;
3
4
  readonly scope: string;
4
5
  readonly retryable: boolean;
5
- constructor(code: string, scope: string, retryable: boolean, message: string, options?: ErrorOptions);
6
+ readonly diagnostic?: StartupDiagnostic;
7
+ constructor(code: string, scope: string, retryable: boolean, message: string, options?: ErrorOptions & {
8
+ context?: StartupContext;
9
+ });
6
10
  }
@@ -1,12 +1,21 @@
1
+ import { describeStartupError } from "@mininglamp-oss/octo-runtime-executor-kernel";
1
2
  export class HostRuntimeError extends Error {
2
3
  code;
3
4
  scope;
4
5
  retryable;
6
+ diagnostic;
5
7
  constructor(code, scope, retryable, message, options) {
6
8
  super(message, options);
7
9
  this.code = code;
8
10
  this.scope = scope;
9
11
  this.retryable = retryable;
10
12
  this.name = "HostRuntimeError";
13
+ // Host 的执行/身份错误仍属于原 scope;只有启动相关 Home 错误附加启动投影。
14
+ if (/^HOME_|^(LOCAL_STATE_INVALID|WRITE_FAILED)$/.test(code))
15
+ this.diagnostic = describeStartupError(this, {
16
+ component: "host",
17
+ phase: "created",
18
+ context: options?.context
19
+ });
11
20
  }
12
21
  }
@@ -0,0 +1,44 @@
1
+ import type { AgentExecutor, HostedAdapterMetadata } from "@mininglamp-oss/octo-runtime-executor-core";
2
+ import { type KernelClient } from "@mininglamp-oss/octo-runtime-executor-kernel";
3
+ import { type InputInvoke, type InteractionResponse, type NativeInteractionResponse } from "@mininglamp-oss/octo-runtime-protocol";
4
+ /** 宿主显式选择执行位置;direct 始终借用同一 Core,ipc 只连接已有服务。 */
5
+ export type ExtraExecution = {
6
+ kind: "direct";
7
+ executor: AgentExecutor;
8
+ endpoint?: never;
9
+ } | {
10
+ kind: "ipc";
11
+ endpoint: string;
12
+ executor?: never;
13
+ };
14
+ /** Extra 只控制本 scope 的调用;不暴露执行器 shutdown 或 Kernel 的低层恢复原语。 */
15
+ export interface ExtraExecutionContext {
16
+ readonly kind: "direct" | "ipc";
17
+ readonly invoke: InputInvoke;
18
+ cancelInvocation(id: string, reason?: string): Promise<{
19
+ accepted: boolean;
20
+ }>;
21
+ respondInteraction(id: string, response: InteractionResponse): Promise<void>;
22
+ respondNativeInteraction(id: string, response: NativeInteractionResponse): Promise<void>;
23
+ list(): Promise<HostedAdapterMetadata[]>;
24
+ }
25
+ export interface ExtraExecutionScope {
26
+ context: ExtraExecutionContext;
27
+ available(): Promise<boolean>;
28
+ stopAdmission(): void;
29
+ drain(options: {
30
+ deadline: number;
31
+ reason: string;
32
+ }): Promise<{
33
+ complete: boolean;
34
+ }>;
35
+ release(): Promise<void>;
36
+ }
37
+ /** 复用同一 IPC client 的登记、取消重试及恢复逻辑,不复制协议实现。 */
38
+ export declare function ipcExecutionContext(client: KernelClient): ExtraExecutionContext;
39
+ export declare function createIpcExecutionScope(client: KernelClient): ExtraExecutionScope;
40
+ /**
41
+ * 将 Core 的执行 iterator 留在共享有界源中独立驱动;插件只有观察视图。
42
+ * 完整接纳凭据到达前只操作自己的 signal,绝不凭调用方传入的 id 取消共享 Core。
43
+ */
44
+ export declare function createDirectExecutionScope(executor: AgentExecutor): ExtraExecutionScope;
@@ -0,0 +1,207 @@
1
+ import { setTimeout as delay } from "node:timers/promises";
2
+ import { HostRunService, KernelError, admissionClosedError } from "@mininglamp-oss/octo-runtime-executor-kernel";
3
+ import { createInputInvoke, identifyInvokeInput, assertInvokeRequestSize, isHostTerminal } from "@mininglamp-oss/octo-runtime-protocol";
4
+ /** 复用同一 IPC client 的登记、取消重试及恢复逻辑,不复制协议实现。 */
5
+ export function ipcExecutionContext(client) {
6
+ return Object.freeze({
7
+ kind: "ipc",
8
+ invoke: client.invoke,
9
+ cancelInvocation: (id, reason) => client.cancelInvocation(id, reason),
10
+ respondInteraction: (id, response) => client.respondInteraction(id, response),
11
+ respondNativeInteraction: (id, response) => client.respondNativeInteraction(id, response),
12
+ list: () => client.list()
13
+ });
14
+ }
15
+ export function createIpcExecutionScope(client) {
16
+ return {
17
+ context: ipcExecutionContext(client),
18
+ available: () => client.status().then((status) => status.execution_ready, () => false),
19
+ stopAdmission: () => client.invocations.stopAdmission(),
20
+ drain: (options) => client.invocations.drain(options),
21
+ release() {
22
+ client.close();
23
+ return Promise.resolve();
24
+ }
25
+ };
26
+ }
27
+ // 只协调显式共享同一对象的 scope;缓冲总额不随 Extra 数量倍增,不创建全局执行器。
28
+ const coordinators = new WeakMap();
29
+ /**
30
+ * 将 Core 的执行 iterator 留在共享有界源中独立驱动;插件只有观察视图。
31
+ * 完整接纳凭据到达前只操作自己的 signal,绝不凭调用方传入的 id 取消共享 Core。
32
+ */
33
+ export function createDirectExecutionScope(executor) {
34
+ let coordinator = coordinators.get(executor);
35
+ if (!coordinator) {
36
+ coordinator = {
37
+ users: 0,
38
+ source: new HostRunService({
39
+ invoke: executor.invoke,
40
+ invokeFrames: (input, environment) => executor.invokeFrames(input, environment),
41
+ list: (configurations) => executor.describe(configurations),
42
+ probe: (type, options) => Promise.resolve(executor.probe(type, options)),
43
+ cancel: (id, reason) => Promise.resolve({ cancelled: executor.cancel(id, reason) }),
44
+ respondInteraction: (id, response) => executor.respondInteraction(id, response),
45
+ respondNative: (id, response) => executor.respondNative(id, response)
46
+ })
47
+ };
48
+ coordinators.set(executor, coordinator);
49
+ }
50
+ const shared = coordinator;
51
+ shared.users++;
52
+ const records = new Map();
53
+ const queries = new Set();
54
+ let stopped = false;
55
+ let released = false;
56
+ let draining;
57
+ const assertOpen = () => {
58
+ if (stopped)
59
+ throw admissionClosedError();
60
+ if (!executor.status().available)
61
+ throw new Error("EXECUTOR_CLOSED");
62
+ };
63
+ const owned = (id) => {
64
+ const record = records.get(id);
65
+ if (!record)
66
+ throw new KernelError("INVOCATION_NOT_TRACKED");
67
+ return record;
68
+ };
69
+ const accepted = (id) => {
70
+ const record = owned(id);
71
+ if (!record.receipt)
72
+ throw new KernelError("INVOCATION_NOT_ACCEPTED");
73
+ if (record.failed)
74
+ throw new KernelError("RUN_OUTCOME_UNKNOWN");
75
+ return record.receipt;
76
+ };
77
+ const trackQuery = (pending) => {
78
+ queries.add(pending);
79
+ void pending.then(() => queries.delete(pending), () => queries.delete(pending));
80
+ };
81
+ const cancel = async (id, reason = "caller_cancelled") => {
82
+ const record = owned(id);
83
+ if (!record.receipt) {
84
+ record.controller.abort(reason);
85
+ // 明确拒绝接纳不会取得他人的控制权;已接纳则由此 signal 定向通知同一次调用。
86
+ await record.admitted;
87
+ return { accepted: true };
88
+ }
89
+ const receipt = accepted(id);
90
+ if (shared.source.get(receipt.run_id).terminal)
91
+ return { accepted: false };
92
+ return { accepted: executor.cancel(receipt.invocation_id, reason) };
93
+ };
94
+ async function* observe(input, environment = {}) {
95
+ assertOpen();
96
+ environment.signal?.throwIfAborted();
97
+ assertInvokeRequestSize(input, environment);
98
+ const identified = identifyInvokeInput(structuredClone(input));
99
+ if (records.has(identified.invocationId))
100
+ throw new KernelError("EXECUTION_IDENTITY_CONFLICT");
101
+ if (records.size >= 128)
102
+ throw new KernelError("CLIENT_INVOCATION_CAPACITY_EXHAUSTED");
103
+ const controller = new AbortController();
104
+ const abort = () => controller.abort(environment.signal?.reason);
105
+ environment.signal?.addEventListener("abort", abort, { once: true });
106
+ const admitted = shared.source.submit(identified, {
107
+ ...environment,
108
+ ...(environment.executionEnvOverrides
109
+ ? { executionEnvOverrides: structuredClone(environment.executionEnvOverrides) }
110
+ : {}),
111
+ signal: controller.signal
112
+ });
113
+ const record = {
114
+ controller,
115
+ admitted,
116
+ settled: Promise.resolve(),
117
+ failed: false
118
+ };
119
+ records.set(identified.invocationId, record);
120
+ record.settled = admitted
121
+ .then(async (receipt) => {
122
+ record.receipt = receipt;
123
+ await shared.source.settled(receipt);
124
+ const cleanup = await executor.waitForInvocationCleanup(receipt);
125
+ if (cleanup !== "complete")
126
+ throw new Error("EXTRA_RUN_CLEANUP_INCOMPLETE");
127
+ records.delete(identified.invocationId);
128
+ })
129
+ .catch(() => {
130
+ // submit 明确拒绝时未创建 Core owner;已接纳的失败必须保留容量和关闭失败事实。
131
+ if (!record.receipt)
132
+ records.delete(identified.invocationId);
133
+ else
134
+ record.failed = true;
135
+ })
136
+ .finally(() => environment.signal?.removeEventListener("abort", abort));
137
+ const receipt = await admitted;
138
+ let after = 0;
139
+ while (true) {
140
+ const window = shared.source.read(receipt.run_id, receipt.stream_id, after);
141
+ for (const item of window.events) {
142
+ after = item.seq;
143
+ yield item.event;
144
+ if (isHostTerminal(item.event)) {
145
+ if (item.event.kind === "control" &&
146
+ item.event.control.type === "state" &&
147
+ item.event.control.state === "lost")
148
+ throw new KernelError("RUN_OUTCOME_UNKNOWN");
149
+ return;
150
+ }
151
+ }
152
+ // 每次只读取中央窗口的一小批;观察退出不关闭 source,也不撤销已接纳调用。
153
+ await delay(10);
154
+ }
155
+ }
156
+ const context = Object.freeze({
157
+ kind: "direct",
158
+ invoke: createInputInvoke(observe),
159
+ cancelInvocation: cancel,
160
+ respondInteraction: async (id, response) => {
161
+ const receipt = accepted(id);
162
+ await shared.source.respond(receipt.run_id, response);
163
+ },
164
+ respondNativeInteraction: async (id, response) => {
165
+ const receipt = accepted(id);
166
+ await shared.source.respondNativeRun(receipt.run_id, response);
167
+ },
168
+ list: async () => {
169
+ assertOpen();
170
+ if (queries.size >= 128)
171
+ throw new Error("EXTRA_QUERY_CAPACITY_EXHAUSTED");
172
+ const query = executor.describe({}, { onProbe: trackQuery });
173
+ trackQuery(query);
174
+ return query;
175
+ }
176
+ });
177
+ return {
178
+ context,
179
+ available: () => Promise.resolve(!stopped && executor.status().available),
180
+ stopAdmission() {
181
+ stopped = true;
182
+ },
183
+ drain({ deadline, reason }) {
184
+ stopped = true;
185
+ return (draining ??= (async () => {
186
+ for (const [id] of records)
187
+ void cancel(id, reason).catch(() => undefined);
188
+ while ([...records.values()].some((record) => !record.failed) || queries.size) {
189
+ if (Date.now() >= deadline)
190
+ return { complete: false };
191
+ await delay(Math.min(10, Math.max(1, deadline - Date.now())));
192
+ }
193
+ return { complete: records.size === 0 };
194
+ })());
195
+ },
196
+ async release() {
197
+ stopped = true;
198
+ if (released || records.size || queries.size)
199
+ return;
200
+ released = true;
201
+ if (--shared.users === 0) {
202
+ coordinators.delete(executor);
203
+ await shared.source.close();
204
+ }
205
+ }
206
+ };
207
+ }
@@ -2,6 +2,7 @@ import { constants } from "node:fs";
2
2
  import { lstat, open, readdir } from "node:fs/promises";
3
3
  import { isAbsolute, join } from "node:path";
4
4
  import { pathToFileURL } from "node:url";
5
+ import { withStartupContext } from "@mininglamp-oss/octo-runtime-executor-kernel";
5
6
  import { assertExtraName } from "./extras.js";
6
7
  export function assertStoredExtra(value) {
7
8
  if (!value || typeof value !== "object" || Array.isArray(value))
@@ -44,7 +45,13 @@ export function extraRegistration(descriptor) {
44
45
  module,
45
46
  config: stored.config,
46
47
  enabled: stored.enabled,
47
- load: () => import(isAbsolute(module) ? pathToFileURL(module).href : module)
48
+ load: () => import(isAbsolute(module) ? pathToFileURL(module).href : module).catch((error) => {
49
+ throw withStartupContext(error, {
50
+ component: name,
51
+ phase: "created",
52
+ context: { module, resource: "extra-module", operation: "import", configKey: "module" }
53
+ });
54
+ })
48
55
  };
49
56
  }
50
57
  /** Called only by a host that explicitly selects this directory as its source. */
@@ -76,7 +83,7 @@ export async function readExtraDirectory(directory) {
76
83
  registrations.push({
77
84
  name: entry.name,
78
85
  config: {},
79
- load: () => Promise.reject(new Error(code))
86
+ load: () => Promise.reject(new Error(code, { cause: error }))
80
87
  });
81
88
  }
82
89
  }
@@ -86,7 +93,13 @@ export async function readExtraDirectory(directory) {
86
93
  export async function readStoredExtra(directory, name) {
87
94
  assertExtraName(name);
88
95
  const file = join(directory, name, "config.json");
89
- const handle = await open(file, constants.O_RDONLY | (constants.O_NOFOLLOW ?? 0) | (constants.O_NONBLOCK ?? 0));
96
+ const handle = await open(file, constants.O_RDONLY | (constants.O_NOFOLLOW ?? 0) | (constants.O_NONBLOCK ?? 0)).catch((error) => {
97
+ throw withStartupContext(error, {
98
+ component: name,
99
+ phase: "created",
100
+ context: { path: file, resource: "extra-config", operation: "open", configKey: "config" }
101
+ });
102
+ });
90
103
  try {
91
104
  // 权限、大小和读取绑定同一个文件,不允许检查后换成链接或其他目标。
92
105
  const info = await handle.stat();
@@ -114,6 +127,13 @@ export async function readStoredExtra(directory, name) {
114
127
  assertStoredExtra(stored);
115
128
  return stored;
116
129
  }
130
+ catch (error) {
131
+ throw withStartupContext(error, {
132
+ component: name,
133
+ phase: "created",
134
+ context: { path: file, resource: "extra-config", operation: "read", configKey: "config" }
135
+ });
136
+ }
117
137
  finally {
118
138
  await handle.close();
119
139
  }
@@ -1,8 +1,8 @@
1
1
  import { type RuntimeLoggingOptions } from "@mininglamp-oss/octo-runtime-adapter-sdk";
2
2
  import { type ServiceLifecycle, type ServicePhase } from "@mininglamp-oss/octo-runtime-executor-kernel";
3
3
  import { type ExtraPluginModule, type JsonObject } from "./extras.js";
4
- export interface ExtraServiceOptions<D extends object = Record<string, never>> {
5
- endpoint: string;
4
+ import { type ExtraExecution } from "./execution.js";
5
+ interface ExtraServiceCommonOptions<D extends object> {
6
6
  module: ExtraPluginModule<D>;
7
7
  config: JsonObject;
8
8
  dependencies: Readonly<D>;
@@ -10,13 +10,36 @@ export interface ExtraServiceOptions<D extends object = Record<string, never>> {
10
10
  controlEndpoint?: string;
11
11
  logging?: RuntimeLoggingOptions;
12
12
  }
13
+ /** IPC/legacy 继续校验宿主 Home;direct 可以完全不配置 Home 和控制端点。 */
14
+ export type ExtraServiceOptions<D extends object = Record<string, never>> = ExtraServiceCommonOptions<D> & ({
15
+ execution: Extract<ExtraExecution, {
16
+ kind: "direct";
17
+ }>;
18
+ endpoint?: never;
19
+ home?: string;
20
+ } | {
21
+ execution: Extract<ExtraExecution, {
22
+ kind: "ipc";
23
+ }>;
24
+ endpoint?: never;
25
+ home: string;
26
+ } | {
27
+ execution?: never;
28
+ endpoint: string;
29
+ home: string;
30
+ });
13
31
  export interface ExtraServiceStatus {
14
32
  phase: ServicePhase;
15
33
  name: string;
16
34
  pid: number;
17
- kernel_available: boolean;
35
+ execution: {
36
+ kind: "direct" | "ipc";
37
+ available: boolean;
38
+ };
39
+ kernel_available?: boolean;
18
40
  plugin: JsonObject;
19
41
  }
20
42
  export type ExtraService = ServiceLifecycle<ExtraServiceStatus>;
21
- /** 装配插件和同进程业务函数;只借用指定 Kernel,不启动或关闭它。 */
43
+ /** 装配插件与独立调用 scope;只借用宿主的 Core 或既有 Kernel,关闭不接管执行服务。 */
22
44
  export declare function createExtraService<D extends object>(options: ExtraServiceOptions<D>): ExtraService;
45
+ export {};