@mininglamp-oss/octo-runtime 1.1.12 → 1.1.13

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 (172) hide show
  1. package/README.md +1 -1
  2. package/apps/cli/dist/adapters.d.ts +19 -1
  3. package/apps/cli/dist/adapters.js +153 -23
  4. package/apps/cli/dist/build-info.json +2 -2
  5. package/apps/cli/dist/codex.d.ts +5 -0
  6. package/apps/cli/dist/codex.js +36 -0
  7. package/apps/cli/dist/kernel.d.ts +4 -0
  8. package/apps/cli/dist/kernel.js +84 -0
  9. package/apps/cli/dist/main.js +8 -7
  10. package/apps/cli/dist/manifest.json +33 -22
  11. package/apps/cli/dist/output.d.ts +1 -0
  12. package/apps/cli/dist/output.js +8 -4
  13. package/apps/cli/dist/playboard.js +21 -12
  14. package/apps/cli/dist/provider-launch.d.ts +28 -0
  15. package/apps/cli/dist/provider-launch.js +52 -0
  16. package/apps/cli/dist/providers.d.ts +182 -0
  17. package/apps/cli/dist/providers.js +34 -0
  18. package/dist/public/adapter-sdk.d.ts +2 -0
  19. package/dist/public/adapter-sdk.js +2 -0
  20. package/dist/public/protocol.d.ts +1 -1
  21. package/dist/public/protocol.js +1 -1
  22. package/node_modules/@mininglamp-oss/octo-runtime-acp-client/dist/index.js +4 -4
  23. package/node_modules/@mininglamp-oss/octo-runtime-acp-client/package.json +3 -3
  24. package/node_modules/@mininglamp-oss/octo-runtime-adapter-acp/dist/index.d.ts +15 -14
  25. package/node_modules/@mininglamp-oss/octo-runtime-adapter-acp/dist/index.js +24 -28
  26. package/node_modules/@mininglamp-oss/octo-runtime-adapter-acp/package.json +4 -4
  27. package/node_modules/@mininglamp-oss/octo-runtime-adapter-antigravity/dist/index.d.ts +10 -35
  28. package/node_modules/@mininglamp-oss/octo-runtime-adapter-antigravity/dist/index.js +22 -29
  29. package/node_modules/@mininglamp-oss/octo-runtime-adapter-antigravity/package.json +3 -3
  30. package/node_modules/@mininglamp-oss/octo-runtime-adapter-claude-code/dist/index.d.ts +14 -68
  31. package/node_modules/@mininglamp-oss/octo-runtime-adapter-claude-code/dist/index.js +60 -43
  32. package/node_modules/@mininglamp-oss/octo-runtime-adapter-claude-code/package.json +3 -3
  33. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codebuddy/dist/index.d.ts +19 -31
  34. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codebuddy/dist/index.js +29 -18
  35. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codebuddy/package.json +4 -4
  36. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/app-server.d.ts +6 -5
  37. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/app-server.js +32 -26
  38. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/engine.d.ts +54 -0
  39. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/engine.js +147 -0
  40. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/environment.js +4 -8
  41. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/index.d.ts +20 -92
  42. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/index.js +104 -216
  43. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/mcp.d.ts +2 -2
  44. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/mcp.js +4 -11
  45. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/service.d.ts +9 -5
  46. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/dist/service.js +77 -81
  47. package/node_modules/@mininglamp-oss/octo-runtime-adapter-codex/package.json +3 -3
  48. package/node_modules/@mininglamp-oss/octo-runtime-adapter-dsh/dist/index.d.ts +4 -2
  49. package/node_modules/@mininglamp-oss/octo-runtime-adapter-dsh/dist/index.js +12 -14
  50. package/node_modules/@mininglamp-oss/octo-runtime-adapter-dsh/package.json +3 -3
  51. package/node_modules/@mininglamp-oss/octo-runtime-adapter-grok-build/dist/adapter.d.ts +14 -14
  52. package/node_modules/@mininglamp-oss/octo-runtime-adapter-grok-build/dist/adapter.js +23 -30
  53. package/node_modules/@mininglamp-oss/octo-runtime-adapter-grok-build/dist/client.js +4 -7
  54. package/node_modules/@mininglamp-oss/octo-runtime-adapter-grok-build/dist/index.d.ts +13 -21
  55. package/node_modules/@mininglamp-oss/octo-runtime-adapter-grok-build/dist/index.js +48 -26
  56. package/node_modules/@mininglamp-oss/octo-runtime-adapter-grok-build/package.json +5 -5
  57. package/node_modules/@mininglamp-oss/octo-runtime-adapter-hermes/dist/index.d.ts +16 -14
  58. package/node_modules/@mininglamp-oss/octo-runtime-adapter-hermes/dist/index.js +15 -7
  59. package/node_modules/@mininglamp-oss/octo-runtime-adapter-hermes/package.json +2 -2
  60. package/node_modules/@mininglamp-oss/octo-runtime-adapter-kimi-code/dist/index.d.ts +16 -14
  61. package/node_modules/@mininglamp-oss/octo-runtime-adapter-kimi-code/dist/index.js +14 -6
  62. package/node_modules/@mininglamp-oss/octo-runtime-adapter-kimi-code/package.json +2 -2
  63. package/node_modules/@mininglamp-oss/octo-runtime-adapter-mcode/dist/index.d.ts +16 -14
  64. package/node_modules/@mininglamp-oss/octo-runtime-adapter-mcode/dist/index.js +15 -7
  65. package/node_modules/@mininglamp-oss/octo-runtime-adapter-mcode/package.json +2 -2
  66. package/node_modules/@mininglamp-oss/octo-runtime-adapter-openclaw/dist/index.d.ts +7 -3
  67. package/node_modules/@mininglamp-oss/octo-runtime-adapter-openclaw/dist/index.js +27 -29
  68. package/node_modules/@mininglamp-oss/octo-runtime-adapter-openclaw/package.json +3 -3
  69. package/node_modules/@mininglamp-oss/octo-runtime-adapter-opencode/dist/index.d.ts +16 -25
  70. package/node_modules/@mininglamp-oss/octo-runtime-adapter-opencode/dist/index.js +109 -178
  71. package/node_modules/@mininglamp-oss/octo-runtime-adapter-opencode/package.json +4 -4
  72. package/node_modules/@mininglamp-oss/octo-runtime-adapter-qodercli/dist/index.d.ts +16 -14
  73. package/node_modules/@mininglamp-oss/octo-runtime-adapter-qodercli/dist/index.js +15 -6
  74. package/node_modules/@mininglamp-oss/octo-runtime-adapter-qodercli/package.json +3 -2
  75. package/node_modules/@mininglamp-oss/octo-runtime-adapter-qoderclicn/dist/index.d.ts +16 -14
  76. package/node_modules/@mininglamp-oss/octo-runtime-adapter-qoderclicn/dist/index.js +15 -6
  77. package/node_modules/@mininglamp-oss/octo-runtime-adapter-qoderclicn/package.json +3 -2
  78. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/activity.d.ts +5 -1
  79. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/agent-env.d.ts +49 -0
  80. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/agent-env.js +256 -0
  81. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/approval.js +7 -2
  82. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/environment.js +1 -1
  83. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/execution-scope.d.ts +5 -1
  84. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/index.d.ts +25 -12
  85. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/index.js +116 -58
  86. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/mcp.js +1 -1
  87. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/process-launch.d.ts +11 -1
  88. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/process-launch.js +89 -8
  89. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/provider-launch.d.ts +10 -0
  90. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/provider-launch.js +25 -0
  91. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/dist/public-display.js +10 -3
  92. package/node_modules/@mininglamp-oss/octo-runtime-adapter-sdk/package.json +2 -2
  93. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/adapters.d.ts +19 -1
  94. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/adapters.js +153 -23
  95. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/build-info.json +2 -2
  96. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/codex.d.ts +5 -0
  97. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/codex.js +36 -0
  98. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/kernel.d.ts +4 -0
  99. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/kernel.js +84 -0
  100. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/main.js +8 -7
  101. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/manifest.json +33 -22
  102. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/output.d.ts +1 -0
  103. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/output.js +8 -4
  104. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/playboard.js +21 -12
  105. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/provider-launch.d.ts +28 -0
  106. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/provider-launch.js +52 -0
  107. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/providers.d.ts +182 -0
  108. package/node_modules/@mininglamp-oss/octo-runtime-cli/dist/providers.js +34 -0
  109. package/node_modules/@mininglamp-oss/octo-runtime-cli/package.json +20 -20
  110. package/node_modules/@mininglamp-oss/octo-runtime-client/build-info.json +2 -2
  111. package/node_modules/@mininglamp-oss/octo-runtime-client/dist/client.js +2 -2
  112. package/node_modules/@mininglamp-oss/octo-runtime-client/package.json +5 -5
  113. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/kernel-ipc.schema.json +3 -104
  114. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/protocol.schema.json +173 -1295
  115. package/node_modules/@mininglamp-oss/octo-runtime-cross-service/package.json +1 -1
  116. package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/index.d.ts +0 -2
  117. package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/index.js +26 -54
  118. package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/invoke-input.d.ts +2 -2
  119. package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/invoke-input.js +13 -85
  120. package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/watchdog.d.ts +3 -1
  121. package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/watchdog.js +5 -0
  122. package/node_modules/@mininglamp-oss/octo-runtime-executor-core/package.json +3 -3
  123. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/index.d.ts +1 -1
  124. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/index.js +1 -1
  125. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/server.d.ts +5 -0
  126. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/dist/server.js +17 -20
  127. package/node_modules/@mininglamp-oss/octo-runtime-executor-kernel/package.json +5 -5
  128. package/node_modules/@mininglamp-oss/octo-runtime-host-sdk/package.json +4 -4
  129. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/browser.d.ts +0 -2
  130. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/browser.js +0 -2
  131. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/context-catalog.d.ts +0 -1
  132. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/context-catalog.js +3 -5
  133. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/context-configuration.js +1 -8
  134. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/context.d.ts +1 -2
  135. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/context.js +3 -267
  136. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/failure.d.ts +2 -0
  137. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/failure.js +17 -3
  138. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/generated/protocol-types.d.ts +102 -396
  139. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/generated/protocol-types.js +32 -1
  140. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/index.d.ts +6 -15
  141. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/index.js +33 -178
  142. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/invoke-input.d.ts +11 -22
  143. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/invoke-input.js +38 -78
  144. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/multimodal.js +6 -0
  145. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/run-protocol.d.ts +2 -1
  146. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/run-protocol.js +5 -28
  147. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/service-processes.js +2 -1
  148. package/node_modules/@mininglamp-oss/octo-runtime-protocol/package.json +1 -1
  149. package/package.json +34 -37
  150. package/packages/octo-runtime-protocol/schema/kernel-ipc.schema.json +3 -104
  151. package/packages/octo-runtime-protocol/schema/protocol.schema.json +173 -1295
  152. package/dist/public/codex.d.ts +0 -1
  153. package/dist/public/codex.js +0 -1
  154. package/dist/public/dsh.d.ts +0 -2
  155. package/dist/public/dsh.js +0 -1
  156. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/context-configuration-fixtures.json +0 -1219
  157. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/context-fixtures.json +0 -5988
  158. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/kernel-client.behavior.json +0 -56
  159. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/native-invoke-fixtures.json +0 -116
  160. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/run-protocol-fixtures.json +0 -761
  161. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/runtime-selection-fixtures.json +0 -663
  162. package/node_modules/@mininglamp-oss/octo-runtime-client/schema/session-name-fixtures.json +0 -191
  163. package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/context.d.ts +0 -12
  164. package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/context.js +0 -89
  165. package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/execution-preparation.d.ts +0 -33
  166. package/node_modules/@mininglamp-oss/octo-runtime-executor-core/dist/execution-preparation.js +0 -93
  167. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/execution-plan.d.ts +0 -3
  168. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/execution-plan.js +0 -80
  169. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/model-context.d.ts +0 -3
  170. package/node_modules/@mininglamp-oss/octo-runtime-protocol/dist/model-context.js +0 -9
  171. /package/node_modules/@mininglamp-oss/octo-runtime-client/{schema → fixtures}/kernel-ipc-fixtures.json +0 -0
  172. /package/packages/octo-runtime-protocol/{schema → test/fixtures}/kernel-ipc-fixtures.json +0 -0
@@ -67,7 +67,7 @@ export type HostControl = {
67
67
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
68
68
  * via the `definition` "RunProtocolErrorCode".
69
69
  */
70
- export type RunProtocolErrorCode = "PROTOCOL_MODE_INVALID" | "PROTOCOL_MODE_UNSUPPORTED" | "EXECUTION_PROTOCOL_MISMATCH" | "EXECUTION_IDENTITY_CONFLICT" | "NATIVE_METHOD_UNSUPPORTED" | "NATIVE_RESPONSE_INVALID" | "INTERACTION_NOT_ACTIVE" | "INVALID_QUESTION_RESPONSE" | "ASYNC_ANSWER_REJECTED" | "OPERATION_OUTCOME_UNKNOWN" | "HOST_EXECUTION_FAILED" | "HOST_ENDED_WITHOUT_TERMINAL" | "PROVIDER_MESSAGE_TOO_LARGE" | "HOST_FRAME_TOO_LARGE" | "STREAM_QUEUE_ITEM_TOO_LARGE" | "STREAM_QUEUE_BYTES_EXCEEDED" | "STREAM_QUEUE_ITEMS_EXCEEDED" | "STREAM_GAP" | "STREAM_EXPIRED" | "REMOTE_NATIVE_UNSUPPORTED" | "HOST_FRAME_INVALID" | "HOST_CONTROL_INVALID" | "HOST_RECEIPT_INVALID" | "PROTOCOL_SUPPORT_INVALID";
70
+ export type RunProtocolErrorCode = "PROTOCOL_MODE_INVALID" | "PROTOCOL_MODE_UNSUPPORTED" | "EXECUTION_PROTOCOL_MISMATCH" | "EXECUTION_IDENTITY_CONFLICT" | "NATIVE_METHOD_UNSUPPORTED" | "NATIVE_RESPONSE_INVALID" | "INTERACTION_NOT_ACTIVE" | "INVALID_QUESTION_RESPONSE" | "ASYNC_ANSWER_REJECTED" | "OPERATION_OUTCOME_UNKNOWN" | "HOST_EXECUTION_FAILED" | "HOST_ENDED_WITHOUT_TERMINAL" | "WORKDIR_REQUIRED" | "WORKDIR_INVALID" | "WORKDIR_NOT_FOUND" | "WORKDIR_NOT_DIRECTORY" | "WORKDIR_UNAVAILABLE" | "PROVIDER_MESSAGE_TOO_LARGE" | "HOST_FRAME_TOO_LARGE" | "STREAM_QUEUE_ITEM_TOO_LARGE" | "STREAM_QUEUE_BYTES_EXCEEDED" | "STREAM_QUEUE_ITEMS_EXCEEDED" | "STREAM_GAP" | "STREAM_EXPIRED" | "REMOTE_NATIVE_UNSUPPORTED" | "HOST_FRAME_INVALID" | "HOST_CONTROL_INVALID" | "HOST_RECEIPT_INVALID" | "PROTOCOL_SUPPORT_INVALID";
71
71
  export type ProtocolMode1 = "native" | "canonical";
72
72
  /**
73
73
  * Public, channel-neutral project notification. No runtime context, reasoning, credentials, or tool payloads belong in this envelope.
@@ -82,7 +82,7 @@ export type NotificationMessage = NotificationMessage1;
82
82
  */
83
83
  export type ApprovalMode = "ask" | "assisted" | "full_access";
84
84
  /**
85
- * Open Context item. Built-in types retain their payload contracts; unknown optional types are preserved and ignored by unsupported consumers.
85
+ * Opaque ordered item. The envelope validates structure; consuming Adapters validate shared settings and their privately agreed payloads. Private items require no public registration.
86
86
  *
87
87
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
88
88
  * via the `definition` "ContextItem".
@@ -95,10 +95,13 @@ export type ContextItem = {
95
95
  payload: Record<string, unknown>;
96
96
  };
97
97
  /**
98
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
99
- * via the `definition` "PersistentContextEnvelope".
98
+ * In addition to draft-07 validation, every consumer must enforce the x-octo semantic keywords: unique ordered namespace/name tuples, compact UTF-8 JSON byte budget, JSON nesting depth with the envelope at depth zero, and Unicode scalar strings in every nested value and object key. Canonical hashing uses ECMAScript JSON number serialization, including -0 becoming 0 and normalized exponent notation; object keys are sorted by UTF-16 code units before ECMAScript integer-index enumeration. U+2028/U+2029 and non-ASCII scalar values are not escaped or Unicode-normalized.
100
99
  */
101
100
  export type PersistentContextEnvelope = ContextEnvelope;
101
+ /**
102
+ * In addition to draft-07 validation, every consumer must enforce the x-octo semantic keywords: unique ordered namespace/name tuples, compact UTF-8 JSON byte budget, JSON nesting depth with the envelope at depth zero, and Unicode scalar strings in every nested value and object key. Canonical hashing uses ECMAScript JSON number serialization, including -0 becoming 0 and normalized exponent notation; object keys are sorted by UTF-16 code units before ECMAScript integer-index enumeration. U+2028/U+2029 and non-ASCII scalar values are not escaped or Unicode-normalized.
103
+ */
104
+ export type PersistentContextEnvelope1 = ContextEnvelope;
102
105
  /**
103
106
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
104
107
  * via the `definition` "PublicObjectMaterial".
@@ -121,6 +124,13 @@ export type PublicObjectMaterial = {
121
124
  end?: number;
122
125
  };
123
126
  };
127
+ /**
128
+ * In addition to draft-07 validation, every consumer must enforce the x-octo semantic keywords: unique ordered namespace/name tuples, compact UTF-8 JSON byte budget, JSON nesting depth with the envelope at depth zero, and Unicode scalar strings in every nested value and object key. Canonical hashing uses ECMAScript JSON number serialization, including -0 becoming 0 and normalized exponent notation; object keys are sorted by UTF-16 code units before ECMAScript integer-index enumeration. U+2028/U+2029 and non-ASCII scalar values are not escaped or Unicode-normalized.
129
+ *
130
+ * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
131
+ * via the `definition` "PersistentContextEnvelope".
132
+ */
133
+ export type PersistentContextEnvelope2 = ContextEnvelope;
124
134
  /**
125
135
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
126
136
  * via the `definition` "ContextModelSelectionPayload".
@@ -143,63 +153,11 @@ export type ContextReasoningPayload = {
143
153
  export type ContextReasoningPayload1 = {
144
154
  [k: string]: unknown;
145
155
  };
146
- /**
147
- * fixed uses the supplied path; random creates a workspace on the AgentSession's first run and reuses it for subsequent runs; none delegates workspace ownership to a preset Agent.
148
- *
149
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
150
- * via the `definition` "ContextWorkspacePayload".
151
- */
152
- export type ContextWorkspacePayload = {
153
- mode: "fixed";
154
- path: string;
155
- } | {
156
- mode: "random";
157
- } | {
158
- mode: "none";
159
- };
160
- /**
161
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
162
- * via the `definition` "ContextRuntimeSelectionPayload".
163
- */
164
156
  export type ContextRuntimeSelectionPayload = {
165
- mode: "candidates" | "explicit";
166
- runtime_id?: string;
167
- /**
168
- * @minItems 1
169
- * @maxItems 64
170
- */
171
- runtime_ids?: [string, ...string[]];
172
- strategy?: "preferred_failover";
173
- offline_behavior?: "wait" | "fail";
174
- failover?: "candidates" | "none";
175
- } & ContextRuntimeSelectionPayload1;
176
- export type ContextRuntimeSelectionPayload1 = {
177
157
  mode?: "candidates";
178
158
  } | {
179
159
  mode?: "explicit";
180
160
  };
181
- /**
182
- * A channel continuity descriptor. The x-octo-matching-trigger-fields keyword requires trigger_fact.message_id == trigger_message_id and matching presence/value of trigger_fact.message_seq and trigger_seq.
183
- *
184
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
185
- * via the `definition` "ContextContinuityPayload".
186
- */
187
- export type ContextContinuityPayload = ChannelContextDescriptor & {
188
- session_generation?: {
189
- [k: string]: unknown;
190
- };
191
- trigger_seq?: {
192
- [k: string]: unknown;
193
- };
194
- trigger_fact?: {
195
- message_seq?: {
196
- [k: string]: unknown;
197
- };
198
- occurred_at_ms?: {
199
- [k: string]: unknown;
200
- };
201
- };
202
- };
203
161
  /**
204
162
  * Worker-frozen Context runtime candidates. Explicit selection cannot fail over.
205
163
  *
@@ -207,23 +165,6 @@ export type ContextContinuityPayload = ChannelContextDescriptor & {
207
165
  * via the `definition` "ResolvedRuntimeSelection".
208
166
  */
209
167
  export type ResolvedRuntimeSelection = ResolvedRuntimeSelection1;
210
- /**
211
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
212
- * via the `definition` "ResolvedExecutionPlan".
213
- */
214
- export type ResolvedExecutionPlan = ResolvedExecutionPlan1;
215
- /**
216
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
217
- * via the `definition` "AgentSource".
218
- */
219
- export type AgentSource = "preset" | "provisioned";
220
- /**
221
- * Dynamic server-name map. No business-specific names are enumerated. Each value must match one closed transport variant.
222
- *
223
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
224
- * via the `definition` "McpServers".
225
- */
226
- export type McpServers = Record<string, McpServer>;
227
168
  /**
228
169
  * Provider-neutral interaction. Omitted delivery retains synchronous blocking semantics; async questions allow continued work. Only Adapter-owned automatic approvals may omit external responses; this does not imply completion.
229
170
  *
@@ -239,19 +180,19 @@ export type InteractionRequestedPayload = InteractionRequestedPayload1;
239
180
  */
240
181
  export type ApprovalDisplayDetails = Record<string, unknown>;
241
182
  /**
242
- * Bounded history result. complete means only that the requested window was returned, not that the local journal is authoritative.
183
+ * Provider-neutral per-invocation MCP server definition.
243
184
  *
244
185
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
245
- * via the `definition` "ContextSyncResult".
186
+ * via the `definition` "McpServer".
246
187
  */
247
- export type ContextSyncResult = ContextSyncResult1;
188
+ export type McpServer = McpStdioServer | McpStreamableHttpServer;
248
189
  /**
249
- * Provider-neutral per-invocation MCP server definition.
190
+ * Dynamic server-name map. No business-specific names are enumerated. Each value must match one closed transport variant.
250
191
  *
251
192
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
252
- * via the `definition` "McpServer".
193
+ * via the `definition` "McpServers".
253
194
  */
254
- export type McpServer = McpStdioServer | McpStreamableHttpServer;
195
+ export type McpServers = Record<string, McpServer>;
255
196
  /**
256
197
  * Ordered provider-native user input. Image bytes are materialized only for the invocation, never used as a text fallback.
257
198
  *
@@ -270,6 +211,13 @@ export type ModelInputPart = {
270
211
  byteSize: number;
271
212
  sha256: string;
272
213
  };
214
+ /**
215
+ * Serializable execution request sent from Core to Adapter Host. AbortSignal is added in src/index.ts because it cannot cross a process boundary.
216
+ *
217
+ * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
218
+ * via the `definition` "InvokeRequestWire".
219
+ */
220
+ export type InvokeRequestWire = InvokeRequestWire1;
273
221
  /**
274
222
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
275
223
  * via the `definition` "ActivitySubject".
@@ -286,6 +234,11 @@ export type ActivitySubject = {
286
234
  type: "interaction";
287
235
  id: string;
288
236
  };
237
+ /**
238
+ * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
239
+ * via the `definition` "AgentSource".
240
+ */
241
+ export type AgentSource = "preset" | "provisioned";
289
242
  /**
290
243
  * Declarative MCP resource operation. Only deployed scoped operations may execute; schema validation does not authorize access.
291
244
  *
@@ -313,37 +266,6 @@ export type ContextReferenceEntry = {
313
266
  * via the `definition` "ModelInputParts".
314
267
  */
315
268
  export type ModelInputParts = [ModelInputPart, ...ModelInputPart[]];
316
- /**
317
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
318
- * via the `definition` "AgentEnv".
319
- */
320
- export type AgentEnv = {
321
- agentConfig?: {
322
- timeoutSeconds?: {
323
- [k: string]: unknown;
324
- };
325
- };
326
- } & {
327
- schema: "octo.context-envelope/v3";
328
- /**
329
- * @maxItems 32
330
- */
331
- items: (ContextItem & ({
332
- namespace?: "octo.execution";
333
- } | {
334
- namespace?: "octo.security";
335
- name?: "approval_policy";
336
- } | {
337
- namespace?: "octo.control";
338
- name?: "instructions";
339
- }))[];
340
- agentSource?: AgentSource;
341
- workdir?: string;
342
- controlInstructions?: string;
343
- approvalMode?: ApprovalMode;
344
- agentConfig?: AgentConfig;
345
- runtimeLimits?: RuntimeLimits;
346
- };
347
269
  /**
348
270
  * Serializable data shapes for the Octo Runtime NDJSON protocol. Runtime behavior remains hand-written in src/index.ts, and this schema is the source of truth for generated TypeScript types. The x-octo-unicode-scalar-strings semantic keyword requires every JSON string value and object member name to contain Unicode scalar values only: unpaired UTF-16 surrogates are rejected, not repaired or normalized. Consumers must enforce this protocol-wide rule even when validating a definition directly.
349
271
  */
@@ -2028,14 +1950,14 @@ export interface ContextEnvelope {
2028
1950
  items: ContextItem[];
2029
1951
  }
2030
1952
  /**
2031
- * Agent defaults and mandatory constraints, stored under one external configuration version. Authorized configuration writers may persist system instructions in mandatory with text-only entries. Ephemeral business content and default-layer instructions are forbidden; callers cannot submit trusted control instructions.
1953
+ * Agent defaults and mandatory execution constraints stored under one external configuration version. Application prompts belong to caller-provided ordinary inputs, not execution settings.
2032
1954
  *
2033
1955
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2034
1956
  * via the `definition` "ContextConfiguration".
2035
1957
  */
2036
1958
  export interface ContextConfiguration {
2037
- defaults: ContextEnvelope;
2038
- mandatory: PersistentContextEnvelope;
1959
+ defaults: PersistentContextEnvelope;
1960
+ mandatory: PersistentContextEnvelope1;
2039
1961
  }
2040
1962
  /**
2041
1963
  * Public Context facts. Preparation is distinct from Adapter application or invocation. This projection excludes resource files, trusted instruction text, credentials and Runtime paths.
@@ -2063,11 +1985,10 @@ export interface RunContextProjection {
2063
1985
  model?: string;
2064
1986
  effort?: string;
2065
1987
  approval_mode: "ask" | "assisted" | "full_access";
2066
- workspace_mode: "fixed" | "random" | "none";
2067
1988
  };
2068
1989
  }
2069
1990
  /**
2070
- * Workspace preparation for the current Run lease and frozen execution Context; it does not prove Provider use of model context.
1991
+ * Preparation facts for the current Run lease and caller-owned workspace path; they do not prove Provider use of model context or transfer directory ownership to Runtime.
2071
1992
  *
2072
1993
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2073
1994
  * via the `definition` "ContextPreparationReceipt".
@@ -2077,7 +1998,6 @@ export interface ContextPreparationReceipt {
2077
1998
  run_id: string;
2078
1999
  lease_id: string;
2079
2000
  fencing_token: number;
2080
- workspace_mode: "fixed" | "random" | "none";
2081
2001
  workspace_path: string;
2082
2002
  provider_state_dir: string;
2083
2003
  /**
@@ -2091,7 +2011,6 @@ export interface ContextPreparationReceipt {
2091
2011
  */
2092
2012
  export interface ContextAdapterPayload {
2093
2013
  type: string;
2094
- provider_agent_id?: string;
2095
2014
  }
2096
2015
  /**
2097
2016
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
@@ -2108,6 +2027,15 @@ export interface ContextModelPayload {
2108
2027
  selection?: ContextModelSelectionPayload;
2109
2028
  reasoning?: ContextReasoningPayload;
2110
2029
  }
2030
+ /**
2031
+ * Caller-owned, already prepared directory. Runtime validates the concrete local execution path and never allocates or recreates an application workspace.
2032
+ *
2033
+ * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2034
+ * via the `definition` "ContextWorkspacePayload".
2035
+ */
2036
+ export interface ContextWorkspacePayload {
2037
+ path: string;
2038
+ }
2111
2039
  /**
2112
2040
  * Snake-case frozen watchdog limits, with the same bounds as RuntimeLimits. Legacy enforcement=observe cannot be combined with v2 settings.
2113
2041
  *
@@ -2125,6 +2053,18 @@ export interface ContextLimitsPayload {
2125
2053
  cancel_grace_ms?: number;
2126
2054
  enforcement?: "enforce" | "observe";
2127
2055
  }
2056
+ export interface ContextRuntimeSelectionPayload1 {
2057
+ mode: "candidates" | "explicit";
2058
+ runtime_id?: string;
2059
+ /**
2060
+ * @minItems 1
2061
+ * @maxItems 64
2062
+ */
2063
+ runtime_ids?: [string, ...string[]];
2064
+ strategy?: "preferred_failover";
2065
+ offline_behavior?: "wait" | "fail";
2066
+ failover?: "candidates" | "none";
2067
+ }
2128
2068
  /**
2129
2069
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2130
2070
  * via the `definition` "ContextApprovalPolicyPayload".
@@ -2132,20 +2072,6 @@ export interface ContextLimitsPayload {
2132
2072
  export interface ContextApprovalPolicyPayload {
2133
2073
  mode: ApprovalMode;
2134
2074
  }
2135
- /**
2136
- * Untrusted inline selection text with optional resource reference, source metadata and summary. Source metadata is not an authorization claim.
2137
- *
2138
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2139
- * via the `definition` "ContextSelectionEntry".
2140
- */
2141
- export interface ContextSelectionEntry {
2142
- text: string;
2143
- resource_ref?: string;
2144
- source?: {
2145
- [k: string]: unknown;
2146
- } | string;
2147
- summary?: string;
2148
- }
2149
2075
  /**
2150
2076
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2151
2077
  * via the `definition` "ContextMcpLocator".
@@ -2154,111 +2080,6 @@ export interface ContextMcpLocator {
2154
2080
  server_ref: string;
2155
2081
  tool: string;
2156
2082
  }
2157
- export interface ContextResourceEntry {
2158
- resource_ref: string;
2159
- resolver: "mcp";
2160
- locator: {};
2161
- /**
2162
- * Frozen non-secret JSON parameters supplied by the authenticated resolver plan, not model-generated commands.
2163
- */
2164
- params?: Record<string, unknown>;
2165
- authorization_ref?: string;
2166
- revision?: string;
2167
- }
2168
- /**
2169
- * Control instruction containing only non-empty text. Authorization belongs to the authenticated upstream boundary, not to a caller-supplied source label.
2170
- *
2171
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2172
- * via the `definition` "ContextInstructionEntry".
2173
- */
2174
- export interface ContextInstructionEntry {
2175
- text: string;
2176
- }
2177
- /**
2178
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2179
- * via the `definition` "ContextInstructionsPayload".
2180
- */
2181
- export interface ContextInstructionsPayload {
2182
- entries: ContextInstructionEntry[];
2183
- }
2184
- /**
2185
- * Snapshot selection descriptor in ExecutionEnvelope. Scope, consumer_key, and session_generation isolate the consumption cursor.
2186
- *
2187
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2188
- * via the `definition` "ChannelContextDescriptor".
2189
- */
2190
- export interface ChannelContextDescriptor {
2191
- scope: ChannelScope;
2192
- consumer_key: string;
2193
- session_generation: number;
2194
- trigger_message_id: string;
2195
- trigger_seq?: number;
2196
- trigger_fact: ChannelMessageFact;
2197
- }
2198
- /**
2199
- * Platform-neutral channel isolation key. account_id may be null but remains explicit; an absent thread_id selects the conversation root.
2200
- *
2201
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2202
- * via the `definition` "ChannelScope".
2203
- */
2204
- export interface ChannelScope {
2205
- tenant_id: string;
2206
- endpoint_id: string;
2207
- channel: string;
2208
- account_id: string | null;
2209
- bot_id: string;
2210
- conversation_id: string;
2211
- thread_id?: string | null;
2212
- }
2213
- /**
2214
- * A platform-neutral message fact in the rebuildable channel journal. Message content is always untrusted external input.
2215
- *
2216
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2217
- * via the `definition` "ChannelMessageFact".
2218
- */
2219
- export interface ChannelMessageFact {
2220
- message_id: string;
2221
- message_seq?: number;
2222
- sender: ChannelMessageSender;
2223
- occurred_at_ms: number;
2224
- /**
2225
- * @minItems 1
2226
- */
2227
- parts: [ChannelMessagePart, ...ChannelMessagePart[]];
2228
- flags?: ChannelMessageFlags;
2229
- }
2230
- /**
2231
- * Normalized sender fact without platform credentials.
2232
- *
2233
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2234
- * via the `definition` "ChannelMessageSender".
2235
- */
2236
- export interface ChannelMessageSender {
2237
- id: string;
2238
- label?: string;
2239
- kind: string;
2240
- }
2241
- /**
2242
- * Normalized platform message part. type and text are common fields; connector extensions remain untrusted external data.
2243
- *
2244
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2245
- * via the `definition` "ChannelMessagePart".
2246
- */
2247
- export interface ChannelMessagePart {
2248
- type: string;
2249
- text?: string;
2250
- [k: string]: unknown;
2251
- }
2252
- /**
2253
- * Common message flags that affect context projection. Self and control messages are excluded from provider-visible context.
2254
- *
2255
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2256
- * via the `definition` "ChannelMessageFlags".
2257
- */
2258
- export interface ChannelMessageFlags {
2259
- self?: boolean;
2260
- control?: boolean;
2261
- }
2262
2083
  export interface ResolvedRuntimeSelection1 {
2263
2084
  schema: "octo.runtime-selection/v2";
2264
2085
  selection_mode: "explicit" | "candidates";
@@ -2284,44 +2105,6 @@ export interface ResolvedRuntimeSelection1 {
2284
2105
  offline_behavior: "wait" | "fail";
2285
2106
  failover: "candidates" | "none";
2286
2107
  }
2287
- export interface ResolvedExecutionPlan1 {
2288
- actmode?: "default" | "plan";
2289
- adapter_type: string;
2290
- workdir: string;
2291
- workspace?: ContextWorkspacePayload;
2292
- model?: string;
2293
- effort?: string;
2294
- approval_mode: ApprovalMode;
2295
- runtime_limits?: ContextLimitsPayload;
2296
- provider_agent_id?: string;
2297
- agent_source: AgentSource;
2298
- envs?: ContextEnvsPayload;
2299
- mcp?: ContextMcpPayload;
2300
- }
2301
- /**
2302
- * Run 级环境变量列表;以 key 标识变量,按 key 合并,不进入模型输入。
2303
- *
2304
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2305
- * via the `definition` "ContextEnvsPayload".
2306
- */
2307
- export interface ContextEnvsPayload {
2308
- /**
2309
- * @maxItems 128
2310
- */
2311
- env_variables: {
2312
- key: string;
2313
- value: string;
2314
- }[];
2315
- }
2316
- /**
2317
- * Run-scoped MCP connection templates. Server names are dynamic keys; values are validated by transport. Variables resolve only in the execution environment, never in the model context.
2318
- *
2319
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2320
- * via the `definition` "ContextMcpPayload".
2321
- */
2322
- export interface ContextMcpPayload {
2323
- mcpServers: McpServers;
2324
- }
2325
2108
  /**
2326
2109
  * Runtime-owned phase-aware invocation watchdog budgets.
2327
2110
  *
@@ -2339,51 +2122,6 @@ export interface RuntimeLimits {
2339
2122
  cancelGraceMs?: number;
2340
2123
  enforcement?: "observe" | "enforce";
2341
2124
  }
2342
- /**
2343
- * Adapter-internal configuration derived from the resolved execution plan, not a public source of run model or approval choices. Legacy permission and thinking fields are forbidden.
2344
- *
2345
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2346
- * via the `definition` "AgentConfig".
2347
- */
2348
- export interface AgentConfig {
2349
- /**
2350
- * Default provider CLI working directory. It is a cwd, not a filesystem security boundary.
2351
- */
2352
- workdir?: string;
2353
- /**
2354
- * Model identifier.
2355
- */
2356
- model?: string;
2357
- /**
2358
- * Provider sandbox mode identifier.
2359
- */
2360
- sandbox?: string;
2361
- /**
2362
- * Provider-side agent identifier.
2363
- */
2364
- providerAgentId?: string;
2365
- /**
2366
- * Optional provider reasoning effort identifier. Provider adapters may define an explicit default.
2367
- */
2368
- effort?: string;
2369
- /**
2370
- * Invocation timeout in seconds.
2371
- */
2372
- timeoutSeconds?: number;
2373
- /**
2374
- * OpenClaw configuration path.
2375
- */
2376
- openclawConfigPath?: string;
2377
- /**
2378
- * OpenClaw state directory.
2379
- */
2380
- openclawStateDir?: string;
2381
- /**
2382
- * Provider-specific extension options passed through unchanged by Core.
2383
- */
2384
- providerOptions?: Record<string, unknown>;
2385
- [k: string]: unknown;
2386
- }
2387
2125
  /**
2388
2126
  * Non-blocking question batch. IDs are positions scoped to this interaction, not provider-native question IDs.
2389
2127
  *
@@ -2647,58 +2385,6 @@ export interface RunIdentity {
2647
2385
  */
2648
2386
  agentSessionId: string;
2649
2387
  }
2650
- /**
2651
- * Idempotent context-only batch appended by agent-worker to its bound daemon.
2652
- *
2653
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2654
- * via the `definition` "ChannelContextAppend".
2655
- */
2656
- export interface ChannelContextAppend {
2657
- agent_id: string;
2658
- scope: ChannelScope;
2659
- /**
2660
- * @minItems 1
2661
- * @maxItems 100
2662
- */
2663
- facts: [ChannelMessageFact, ...ChannelMessageFact[]];
2664
- gap_after_seq?: number;
2665
- }
2666
- /**
2667
- * Bounded backfill requested by the daemon after cold start or gap detection. It never carries platform tokens.
2668
- *
2669
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2670
- * via the `definition` "ContextSyncRequest".
2671
- */
2672
- export interface ContextSyncRequest {
2673
- request_id: string;
2674
- run_id: string;
2675
- scope: ChannelScope;
2676
- trigger_message_id: string;
2677
- trigger_seq?: number;
2678
- after_seq?: number;
2679
- limit: number;
2680
- }
2681
- export interface ContextSyncResult1 {
2682
- request_id: string;
2683
- scope: ChannelScope;
2684
- /**
2685
- * @maxItems 100
2686
- */
2687
- facts: ChannelMessageFact[];
2688
- completeness: "complete" | "partial" | "unavailable";
2689
- through_seq?: number;
2690
- }
2691
- /**
2692
- * Result of advancing the consumer cursor with version CAS after terminal durability.
2693
- *
2694
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2695
- * via the `definition` "ContextCommitResult".
2696
- */
2697
- export interface ContextCommitResult {
2698
- snapshot_id: string;
2699
- committed: boolean;
2700
- reason?: "already_committed" | "snapshot_not_found" | "snapshot_not_submitted" | "consumer_advanced" | "snapshot_failed";
2701
- }
2702
2388
  /**
2703
2389
  * A per-invocation MCP server launched as a child process by the provider.
2704
2390
  *
@@ -2735,14 +2421,8 @@ export interface McpStreamableHttpServer {
2735
2421
  startupTimeoutMs?: number;
2736
2422
  toolTimeoutMs?: number;
2737
2423
  }
2738
- /**
2739
- * Serializable execution request sent from Core to Adapter Host. AbortSignal is added in src/index.ts because it cannot cross a process boundary.
2740
- *
2741
- * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2742
- * via the `definition` "InvokeRequestWire".
2743
- */
2744
- export interface InvokeRequestWire {
2745
- executionEnvOverrides?: ContextEnvsPayload1;
2424
+ export interface InvokeRequestWire1 {
2425
+ executionEnvOverrides?: ContextEnvsPayload;
2746
2426
  /**
2747
2427
  * Active Adapter Host invocation identifier and cancellation target.
2748
2428
  */
@@ -2797,27 +2477,15 @@ export interface InvokeRequestWire {
2797
2477
  * Frozen alternate user turn for the first turn of a fresh provider session after resume fails.
2798
2478
  */
2799
2479
  freshFallbackModelInput?: string;
2800
- /**
2801
- * Provider process cwd. Sandboxing, containers, or host permissions provide the actual access boundary.
2802
- */
2803
- workdir: string;
2804
- /**
2805
- * Trusted session instructions. Adapters inject them only when starting a provider session; resuming an existing session must not inject or clear them.
2806
- */
2807
- controlInstructions: string;
2808
- context: ContextEnvelope;
2809
2480
  runMetadata?: Record<string, unknown>;
2810
- approvalMode: ApprovalMode;
2811
2481
  providerSession?: ProviderSession;
2812
- runtimeLimits?: RuntimeLimits;
2813
- agentConfig: AgentConfig;
2814
2482
  protocolVersion: 2;
2815
- agentSource: AgentSource;
2483
+ agentEnv: AgentEnv;
2816
2484
  }
2817
2485
  /**
2818
- * Run 级环境变量列表;以 key 标识变量,按 key 合并,不进入模型输入。
2486
+ * Trusted ingress execution environment, independent of business Context; never render or persist in business snapshots.
2819
2487
  */
2820
- export interface ContextEnvsPayload1 {
2488
+ export interface ContextEnvsPayload {
2821
2489
  /**
2822
2490
  * @maxItems 128
2823
2491
  */
@@ -2826,6 +2494,19 @@ export interface ContextEnvsPayload1 {
2826
2494
  value: string;
2827
2495
  }[];
2828
2496
  }
2497
+ /**
2498
+ * Execution envelope forwarded unchanged to the Adapter. Only shared bean types belong to the public protocol; Harness-specific payloads are private agreements between the caller and its Adapter.
2499
+ *
2500
+ * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2501
+ * via the `definition` "AgentEnv".
2502
+ */
2503
+ export interface AgentEnv {
2504
+ schema: "octo.context-envelope/v3";
2505
+ /**
2506
+ * @maxItems 32
2507
+ */
2508
+ items: ContextItem[];
2509
+ }
2829
2510
  /**
2830
2511
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2831
2512
  * via the `definition` "ActivityInfo".
@@ -2986,6 +2667,30 @@ export interface IssuedToolAuthorization {
2986
2667
  namespace: string;
2987
2668
  expires_at: string;
2988
2669
  }
2670
+ /**
2671
+ * Run 级环境变量列表;以 key 标识变量,按 key 合并,不进入模型输入。
2672
+ *
2673
+ * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2674
+ * via the `definition` "ContextEnvsPayload".
2675
+ */
2676
+ export interface ContextEnvsPayload1 {
2677
+ /**
2678
+ * @maxItems 128
2679
+ */
2680
+ env_variables: {
2681
+ key: string;
2682
+ value: string;
2683
+ }[];
2684
+ }
2685
+ /**
2686
+ * Run-scoped MCP connection templates. Server names are dynamic keys; values are validated by transport. Variables resolve only in the execution environment, never in the model context.
2687
+ *
2688
+ * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
2689
+ * via the `definition` "ContextMcpPayload".
2690
+ */
2691
+ export interface ContextMcpPayload {
2692
+ mcpServers: McpServers;
2693
+ }
2989
2694
  export interface InvokeInputWire {
2990
2695
  /**
2991
2696
  * Optional caller-owned nonblank display name of 1-256 Unicode code points, without C0/DEL/C1 controls; Core supplies a random UUID default without business naming policy.
@@ -3009,14 +2714,13 @@ export interface InvokeInputWire {
3009
2714
  freshFallbackModelInputParts?: ModelInputParts;
3010
2715
  freshFallbackImagesUnavailable?: boolean;
3011
2716
  agentEnv: AgentEnv;
3012
- [k: string]: unknown;
3013
2717
  }
3014
2718
  /**
3015
2719
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
3016
2720
  * via the `definition` "KernelInvokeEnvironmentWire".
3017
2721
  */
3018
2722
  export interface KernelInvokeEnvironmentWire {
3019
- executionEnvOverrides?: ContextEnvsPayload;
2723
+ executionEnvOverrides?: ContextEnvsPayload1;
3020
2724
  }
3021
2725
  /**
3022
2726
  * This interface was referenced by `OctoRuntimeProtocolSchema`'s JSON-Schema
@@ -3045,3 +2749,5 @@ export interface HostedAdapterMetadataWire {
3045
2749
  unavailableReason?: string | null;
3046
2750
  [k: string]: unknown;
3047
2751
  }
2752
+ export declare const KERNEL_IPC_VERSION: 2;
2753
+ export declare const RUN_PROTOCOL_ERRORS: readonly ["PROTOCOL_MODE_INVALID", "PROTOCOL_MODE_UNSUPPORTED", "EXECUTION_PROTOCOL_MISMATCH", "EXECUTION_IDENTITY_CONFLICT", "NATIVE_METHOD_UNSUPPORTED", "NATIVE_RESPONSE_INVALID", "INTERACTION_NOT_ACTIVE", "INVALID_QUESTION_RESPONSE", "ASYNC_ANSWER_REJECTED", "OPERATION_OUTCOME_UNKNOWN", "HOST_EXECUTION_FAILED", "HOST_ENDED_WITHOUT_TERMINAL", "WORKDIR_REQUIRED", "WORKDIR_INVALID", "WORKDIR_NOT_FOUND", "WORKDIR_NOT_DIRECTORY", "WORKDIR_UNAVAILABLE", "PROVIDER_MESSAGE_TOO_LARGE", "HOST_FRAME_TOO_LARGE", "STREAM_QUEUE_ITEM_TOO_LARGE", "STREAM_QUEUE_BYTES_EXCEEDED", "STREAM_QUEUE_ITEMS_EXCEEDED", "STREAM_GAP", "STREAM_EXPIRED", "REMOTE_NATIVE_UNSUPPORTED", "HOST_FRAME_INVALID", "HOST_CONTROL_INVALID", "HOST_RECEIPT_INVALID", "PROTOCOL_SUPPORT_INVALID"];