@codemation/core 0.13.2 → 0.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (212) hide show
  1. package/CHANGELOG.md +167 -0
  2. package/dist/{CostCatalogContract-Dxq1BTyi.d.cts → CostCatalogContract-Dwo-ZamG.d.cts} +2 -2
  3. package/dist/EngineRuntimeRegistration.types-BiNasx3G.d.cts +54 -0
  4. package/dist/EngineRuntimeRegistration.types-Dq4ucrdo.d.ts +21 -0
  5. package/dist/{InMemoryRunDataFactory-Csy2evr_.d.cts → InMemoryRunDataFactory-D2U9azmZ.d.cts} +4 -20
  6. package/dist/{InMemoryRunEventBusRegistry-Sa86VxuV.cjs → InMemoryRunEventBusRegistry-DO0WM9Lw.cjs} +1 -1
  7. package/dist/{InMemoryRunEventBusRegistry-Sa86VxuV.cjs.map → InMemoryRunEventBusRegistry-DO0WM9Lw.cjs.map} +1 -1
  8. package/dist/{InMemoryRunEventBusRegistry-Bwunvt1T.js → InMemoryRunEventBusRegistry-Layt2xgm.js} +1 -1
  9. package/dist/{InMemoryRunEventBusRegistry-Bwunvt1T.js.map → InMemoryRunEventBusRegistry-Layt2xgm.js.map} +1 -1
  10. package/dist/{ItemsInputNormalizer-Bi8m-Ijs.d.cts → ItemsInputNormalizer-A5txcOWX.d.cts} +3 -98
  11. package/dist/{ItemsInputNormalizer-BbQTSEkZ.cjs → ItemsInputNormalizer-C1fv3sMW.cjs} +2 -2
  12. package/dist/ItemsInputNormalizer-C1fv3sMW.cjs.map +1 -0
  13. package/dist/{ItemsInputNormalizer-BYljnXU0.d.ts → ItemsInputNormalizer-D2vrMrX1.d.ts} +2 -62
  14. package/dist/{ItemsInputNormalizer-CSZGMgl3.js → ItemsInputNormalizer-fUYo4GLV.js} +2 -2
  15. package/dist/ItemsInputNormalizer-fUYo4GLV.js.map +1 -0
  16. package/dist/{RunIntentService-BitgkKaT.d.cts → RunIntentService-DKxuHTUz.d.cts} +2 -15
  17. package/dist/{RunIntentService-DYpqfu6D.d.ts → RunIntentService-DrpKli2k.d.ts} +2 -22
  18. package/dist/{agentMcpTypes-DGIwk6Ue.d.cts → agentMcpTypes-BHX4RQCC.d.cts} +25 -518
  19. package/dist/bootstrap/index.cjs +9 -5
  20. package/dist/bootstrap/index.d.cts +32 -106
  21. package/dist/bootstrap/index.d.ts +18 -17
  22. package/dist/bootstrap/index.js +6 -5
  23. package/dist/{bootstrap-DIv-vloi.cjs → bootstrap-CTB53rEF.cjs} +9 -60
  24. package/dist/bootstrap-CTB53rEF.cjs.map +1 -0
  25. package/dist/{bootstrap-Bkd-Nfbn.js → bootstrap-DmqKheCI.js} +6 -57
  26. package/dist/bootstrap-DmqKheCI.js.map +1 -0
  27. package/dist/browser.cjs +12 -11
  28. package/dist/browser.d.cts +4 -4
  29. package/dist/browser.d.ts +3 -3
  30. package/dist/browser.js +3 -2
  31. package/dist/contracts-7L1wJHdk.cjs +569 -0
  32. package/dist/contracts-7L1wJHdk.cjs.map +1 -0
  33. package/dist/contracts-CjJ5CZ7N.js +447 -0
  34. package/dist/contracts-CjJ5CZ7N.js.map +1 -0
  35. package/dist/contracts.cjs +9 -2
  36. package/dist/contracts.d.cts +5 -5
  37. package/dist/contracts.d.ts +2 -2
  38. package/dist/contracts.js +3 -2
  39. package/dist/{executionPersistenceContracts-CN9d7AnL.d.cts → deploymentManifestTypes-B8CDmZZK.d.cts} +65 -81
  40. package/dist/di-C6Ubf9o5.cjs +179 -0
  41. package/dist/di-C6Ubf9o5.cjs.map +1 -0
  42. package/dist/di-Cjiil7U-.js +114 -0
  43. package/dist/di-Cjiil7U-.js.map +1 -0
  44. package/dist/{index-rllWL4r-.d.ts → index-CRv3_pY3.d.ts} +112 -808
  45. package/dist/{index-BSQ2LoIh.d.ts → index-mnLS0iQl.d.ts} +39 -372
  46. package/dist/index.cjs +53 -111
  47. package/dist/index.cjs.map +1 -1
  48. package/dist/index.d.cts +50 -438
  49. package/dist/index.d.ts +5 -5
  50. package/dist/index.js +28 -94
  51. package/dist/index.js.map +1 -1
  52. package/dist/{params-DRUr0F5v.d.cts → params-CrK4iuG1.d.cts} +3 -13
  53. package/dist/{runtime-CWPdvJpC.js → runtime-CBFDpmiz.js} +112 -648
  54. package/dist/runtime-CBFDpmiz.js.map +1 -0
  55. package/dist/{runtime-_VdHwGkJ.cjs → runtime-Due-FOZ2.cjs} +137 -717
  56. package/dist/runtime-Due-FOZ2.cjs.map +1 -0
  57. package/dist/testing.cjs +8 -40
  58. package/dist/testing.cjs.map +1 -1
  59. package/dist/testing.d.cts +3 -32
  60. package/dist/testing.d.ts +3 -32
  61. package/dist/testing.js +6 -38
  62. package/dist/testing.js.map +1 -1
  63. package/dist/{di-LP2qSHkY.cjs → workflowTypes-BW6Hhee7.cjs} +4 -230
  64. package/dist/workflowTypes-BW6Hhee7.cjs.map +1 -0
  65. package/dist/{di-tom0pM2h.js → workflowTypes-DZtBTmKf.js} +3 -163
  66. package/dist/workflowTypes-DZtBTmKf.js.map +1 -0
  67. package/package.json +1 -1
  68. package/src/ai/AgentConnectionNodeCollector.ts +0 -4
  69. package/src/ai/AgentMessageConfigNormalizerFactory.ts +0 -4
  70. package/src/ai/AiHost.ts +0 -38
  71. package/src/ai/CallableToolConfig.ts +0 -9
  72. package/src/ai/CallableToolKindToken.ts +0 -4
  73. package/src/authoring/callableTool.types.ts +0 -3
  74. package/src/authoring/defineCollection.types.ts +0 -11
  75. package/src/authoring/defineHumanApprovalNode.types.ts +0 -116
  76. package/src/authoring/defineNode.types.ts +18 -32
  77. package/src/authoring/definePollingTrigger.types.ts +36 -155
  78. package/src/authoring/definePollingTriggerInternals.ts +0 -4
  79. package/src/authoring/index.ts +1 -0
  80. package/src/authoring/nodeBaseOptions.types.ts +4 -0
  81. package/src/binaries/boundedReadBinary.types.ts +0 -16
  82. package/src/bootstrap/index.ts +8 -2
  83. package/src/bootstrap/runtime/EngineRuntimeRegistrar.ts +0 -5
  84. package/src/bootstrap/runtime/EngineRuntimeRegistration.types.ts +0 -23
  85. package/src/browser.ts +0 -3
  86. package/src/contracts/AgentBindError.ts +0 -5
  87. package/src/contracts/Clock.ts +0 -1
  88. package/src/contracts/CodemationTelemetryAttributeNames.ts +0 -10
  89. package/src/contracts/NoOpAgentMcpIntegration.ts +0 -6
  90. package/src/contracts/NoOpTelemetrySpanScope.ts +0 -7
  91. package/src/contracts/RetryPolicy.ts +0 -2
  92. package/src/contracts/agentMcpTypes.ts +0 -34
  93. package/src/contracts/assertionTypes.ts +0 -33
  94. package/src/contracts/baseTypes.ts +0 -6
  95. package/src/contracts/collectionTypes.ts +0 -25
  96. package/src/contracts/credentialTypes.ts +13 -60
  97. package/src/contracts/deploymentManifestTypes.ts +158 -0
  98. package/src/contracts/dispatchTypes.ts +29 -0
  99. package/src/contracts/executionPersistenceContracts.ts +0 -33
  100. package/src/contracts/hitlSeamTypes.ts +0 -14
  101. package/src/contracts/humanTaskStoreTypes.ts +0 -2
  102. package/src/contracts/inboxChannelTypes.ts +0 -9
  103. package/src/contracts/index.ts +3 -0
  104. package/src/contracts/itemExpr.ts +7 -21
  105. package/src/contracts/itemMeta.ts +0 -3
  106. package/src/contracts/mcpTypes.ts +0 -16
  107. package/src/contracts/retryPolicySpec.types.ts +0 -10
  108. package/src/contracts/runFinishedAtFactory.ts +0 -1
  109. package/src/contracts/runTypes.ts +0 -74
  110. package/src/contracts/runtimeTypes.ts +4 -131
  111. package/src/contracts/telemetryTypes.ts +0 -7
  112. package/src/contracts/testTriggerTypes.ts +0 -43
  113. package/src/contracts/triggerInvokerTypes.ts +6 -0
  114. package/src/contracts/webhookTypes.ts +0 -8
  115. package/src/contracts/workflowActivationPolicy.ts +0 -5
  116. package/src/contracts/workflowTypes.ts +5 -80
  117. package/src/contracts/workspaceFileTypes.ts +10 -42
  118. package/src/contracts.ts +18 -10
  119. package/src/credentials/CredentialMaterialProvider.types.ts +0 -28
  120. package/src/credentials/ManagedCredentialMaterialWriteError.ts +0 -6
  121. package/src/credentials/ManagedMaterialFetchError.ts +0 -6
  122. package/src/credentials/OAuthFlowExecutor.types.ts +0 -15
  123. package/src/di/CoreTokens.ts +2 -6
  124. package/src/events/ConnectionInvocationEventPublisher.ts +0 -7
  125. package/src/events/NodeEventPublisher.ts +0 -1
  126. package/src/events/runEvents.ts +0 -8
  127. package/src/execution/ActivationEnqueueService.ts +0 -10
  128. package/src/execution/ChildExecutionScopeFactory.ts +0 -13
  129. package/src/execution/FanInMergeByOriginMerger.ts +0 -11
  130. package/src/execution/InProcessRetryRunner.ts +0 -1
  131. package/src/execution/ItemExprResolver.ts +0 -3
  132. package/src/execution/NodeActivationRequestComposer.ts +0 -3
  133. package/src/execution/NodeActivationRequestInputPreparer.ts +0 -5
  134. package/src/execution/NodeExecutionSnapshotFactory.ts +0 -1
  135. package/src/execution/NodeExecutor.ts +1 -17
  136. package/src/execution/NodeOutputNormalizer.ts +8 -1
  137. package/src/execution/NodeSuspensionHandler.ts +1 -39
  138. package/src/execution/PersistedRunStateTerminalBuilder.ts +0 -5
  139. package/src/execution/RunSuspendedError.ts +0 -10
  140. package/src/execution/RunnableOutputBehaviorResolver.ts +12 -0
  141. package/src/execution/WorkflowRunExecutionContextFactory.ts +0 -3
  142. package/src/index.ts +10 -2
  143. package/src/orchestration/AbortControllerFactory.ts +0 -4
  144. package/src/orchestration/Engine.ts +0 -9
  145. package/src/orchestration/NodeExecutionRequestHandlerService.ts +3 -4
  146. package/src/orchestration/RunContinuationService.ts +7 -39
  147. package/src/orchestration/RunStartService.ts +0 -7
  148. package/src/orchestration/TestSuiteOrchestrator.ts +0 -18
  149. package/src/orchestration/TestSuiteRunIdFactory.ts +0 -4
  150. package/src/orchestration/TriggerRuntimeService.ts +3 -2
  151. package/src/planning/CurrentStateFrontierPlanner.ts +0 -1
  152. package/src/planning/RunQueuePlanner.ts +0 -6
  153. package/src/policies/executionLimits/EngineExecutionLimitsPolicy.ts +0 -8
  154. package/src/policies/executionLimits/EngineExecutionLimitsPolicyFactory.ts +0 -3
  155. package/src/runStorage/RunSummaryMapper.ts +0 -1
  156. package/src/runtime/EngineFactory.ts +6 -11
  157. package/src/runtime/RunIntentService.ts +0 -4
  158. package/src/runtime/WorkflowRepositoryWebhookTriggerMatcher.ts +0 -4
  159. package/src/runtime-types/InjectableRuntimeDecoratorComposerRegistry.ts +0 -4
  160. package/src/runtime-types/PersistedRuntimeTypeMetadataStoreRegistry.ts +0 -4
  161. package/src/runtime-types/PersistedRuntimeTypeNameResolver.ts +0 -1
  162. package/src/runtime-types/persistedRuntimeTypeModelRegistry.ts +0 -4
  163. package/src/runtime-types/runtimeTypeDecorators.types.ts +0 -12
  164. package/src/scheduler/ConfigDrivenOffloadPolicy.ts +0 -1
  165. package/src/scheduler/DefaultDrivingScheduler.ts +0 -6
  166. package/src/scheduler/InlineDrivingScheduler.ts +0 -13
  167. package/src/serialization/ItemsInputNormalizer.ts +0 -5
  168. package/src/testing/CapturingScheduler.ts +0 -3
  169. package/src/testing/EngineTestKitRunIdFactory.ts +0 -3
  170. package/src/testing/ItemHarnessNode.ts +0 -3
  171. package/src/testing/ItemHarnessNodeConfig.ts +0 -4
  172. package/src/testing/PrefixedSequentialIdGenerator.ts +0 -3
  173. package/src/testing/RegistrarEngineTestKit.types.ts +0 -2
  174. package/src/testing/RejectingCredentialSessionService.ts +0 -4
  175. package/src/testing/SubWorkflowRunnerTestNode.ts +0 -3
  176. package/src/testing/WorkflowTestHarnessManualTrigger.ts +0 -3
  177. package/src/testing/WorkflowTestKitBuilder.ts +0 -4
  178. package/src/testing/WorkflowTestKitRunNodeWorkflowFactory.ts +0 -3
  179. package/src/testing.ts +0 -3
  180. package/src/triggers/polling/PollingTriggerDedupWindow.ts +0 -4
  181. package/src/triggers/polling/PollingTriggerLogger.ts +0 -5
  182. package/src/triggers/polling/PollingTriggerRuntime.ts +0 -5
  183. package/src/types/index.ts +0 -6
  184. package/src/validation/WorkflowEdgePortValidator.ts +0 -5
  185. package/src/workflow/definition/ConnectionInvocationIdFactory.ts +0 -7
  186. package/src/workflow/definition/ConnectionNodeIdFactory.ts +0 -6
  187. package/src/workflow/definition/NodeIterationIdFactory.ts +0 -13
  188. package/src/workflow/definition/WorkflowExecutableNodeClassifier.ts +0 -6
  189. package/src/workflow/dsl/ChainCursorResolver.ts +8 -15
  190. package/src/workflow/dsl/NodeIdSlugifier.ts +0 -9
  191. package/src/workflow/dsl/WhenBuilder.ts +49 -2
  192. package/src/workflow/dsl/WorkflowDefinitionError.ts +0 -9
  193. package/src/workflow/dsl/workflowBuilderTypes.ts +5 -0
  194. package/src/workflowSnapshots/MissingRuntimeParityGuard.ts +24 -0
  195. package/src/workflowSnapshots/PersistedWorkflowTokenRegistry.ts +0 -6
  196. package/src/workflowSnapshots/WorkflowParityMismatchError.ts +18 -0
  197. package/src/workflowSnapshots/WorkflowSnapshotCodec.ts +1 -5
  198. package/src/workflowSnapshots/index.ts +3 -0
  199. package/dist/EngineRuntimeRegistration.types-CqcTWexS.d.cts +0 -81
  200. package/dist/EngineRuntimeRegistration.types-Cr75cSfL.d.ts +0 -44
  201. package/dist/ItemsInputNormalizer-BbQTSEkZ.cjs.map +0 -1
  202. package/dist/ItemsInputNormalizer-CSZGMgl3.js.map +0 -1
  203. package/dist/bootstrap-Bkd-Nfbn.js.map +0 -1
  204. package/dist/bootstrap-DIv-vloi.cjs.map +0 -1
  205. package/dist/contracts-CK0x6w_G.cjs +0 -74
  206. package/dist/contracts-CK0x6w_G.cjs.map +0 -1
  207. package/dist/contracts-DXdfTdpW.js +0 -50
  208. package/dist/contracts-DXdfTdpW.js.map +0 -1
  209. package/dist/di-LP2qSHkY.cjs.map +0 -1
  210. package/dist/di-tom0pM2h.js.map +0 -1
  211. package/dist/runtime-CWPdvJpC.js.map +0 -1
  212. package/dist/runtime-_VdHwGkJ.cjs.map +0 -1
@@ -1,48 +1,28 @@
1
- import { $t as RunnableNodeConfig, At as JsonValue, Ct as Item, Ki as NodeConnectionName, Nt as NodeConfigBase, Qr as TelemetrySpanScope, Tt as Items, Ut as NodeOutputs, Y as TypeToken, a as ConnectionInvocationId, b as PersistedRunState, en as RunnableNodeInputJson, ji as CredentialRequirement, qi as NodeId, rr as NodeExecutionContext } from "./agentMcpTypes-DGIwk6Ue.cjs";
2
- import { t as Expr } from "./params-DRUr0F5v.cjs";
1
+ import { Et as Items, Ii as CredentialRequirement, Pt as NodeConfigBase, Qi as NodeId, Wt as NodeOutputs, Y as TypeToken, Zi as NodeConnectionName, a as ConnectionInvocationId, ar as NodeExecutionContext, b as PersistedRunState, jt as JsonValue, nn as RunnableNodeInputJson, ti as TelemetrySpanScope, tn as RunnableNodeConfig, wt as Item } from "./agentMcpTypes-BHX4RQCC.cjs";
2
+ import { t as Expr } from "./params-CrK4iuG1.cjs";
3
3
  import { ZodType, input, output } from "zod";
4
4
 
5
5
  //#region src/contracts/mcpTypes.d.ts
6
6
  type McpServerTransport = "http";
7
7
  interface McpServerDeclaration {
8
- /** Globally unique slug, e.g. "gmail". Workflow authors reference this. */
9
8
  id: string;
10
9
  displayName: string;
11
10
  description: string;
12
11
  transport: McpServerTransport;
13
12
  url: string;
14
- /**
15
- * Credential types accepted by this MCP server, matching CredentialRequirement.acceptedTypes.
16
- * Absent or empty means no credential is required.
17
- */
18
13
  acceptedCredentialTypes?: ReadonlyArray<string>;
19
- /**
20
- * Documentation only in MVP. The bind-time validator checks
21
- * requiredScopes ⊆ CredentialInstance.scopesGranted.
22
- */
23
14
  requiredScopes?: string[];
24
- /** Non-secret static headers merged onto every MCP request. */
25
15
  staticHeaders?: Record<string, string>;
26
- /**
27
- * Overrides for tool descriptions advertised by the MCP server.
28
- * Applied by the connection pool after tools/list.
29
- * Key: exact tool name as returned by the server.
30
- */
31
16
  toolDescriptionOverrides?: Record<string, string>;
32
17
  }
33
18
  //#endregion
34
19
  //#region src/contracts/runFinishedAtFactory.d.ts
35
20
  type RunFinishedAtSource = Pick<PersistedRunState, "status" | "nodeSnapshotsByNodeId" | "finishedAt">;
36
- /** Derives workflow end time from persisted run root or node snapshots for run listings. */
37
21
  declare class RunFinishedAtFactory {
38
22
  static resolveIso(state: RunFinishedAtSource): string | undefined;
39
23
  }
40
24
  //#endregion
41
25
  //#region src/workflow/definition/ConnectionNodeIdFactory.d.ts
42
- /**
43
- * Deterministic ids for workflow connection-owned child nodes (LLM slot, tools, etc.).
44
- * These are stable across loads.
45
- */
46
26
  declare class ConnectionNodeIdFactory {
47
27
  static readonly connectionSegment: "__conn__";
48
28
  static languageModelConnectionNodeId(parentNodeId: NodeId): NodeId;
@@ -62,29 +42,14 @@ declare class ConnectionNodeIdFactory {
62
42
  parentNodeId: NodeId;
63
43
  normalizedToolName: string;
64
44
  }> | undefined;
65
- /** True when `nodeId` is a connection-owned child of `parentNodeId` (LLM or tool slot). */
66
45
  static isConnectionOwnedDescendantOf(parentNodeId: NodeId, nodeId: NodeId): boolean;
67
- /** Normalizes a tool display name to a stable id segment. */
68
46
  static normalizeToolName(toolName: string): string;
69
47
  }
70
48
  //#endregion
71
49
  //#region src/workflow/definition/NodeIterationIdFactory.d.ts
72
- /**
73
- * Unique ids for one per-item iteration of a runnable node's execute loop.
74
- *
75
- * Activations are per-batch (one scheduled execution of a node, possibly with N items).
76
- * Iterations refine that to one identifier per item-index inside the batch loop, so per-item
77
- * connection invocations and telemetry can be grouped without time-window heuristics.
78
- *
79
- * Uses Web Crypto's `randomUUID` (Node 19+ and all modern browsers) so this module is safe
80
- * to include in the browser entry. Importing `node:crypto` here previously leaked into the
81
- * canvas client bundle through `browser.ts` and OOM'd consumers' Turbopack builds.
82
- */
83
50
  declare class NodeIterationIdFactory {
84
51
  static create(): string;
85
- /** Deterministic id for tests when a stable sequence is needed. */
86
52
  static createForTest(seed: string, sequence: number): string;
87
- /** Deterministic id derived from a connection node id (for sub-agent / tool-call scopes). */
88
53
  static createForConnection(connectionNodeId: NodeId, sequence: number): string;
89
54
  }
90
55
  //#endregion
@@ -119,15 +84,9 @@ type CallableToolConfigOptions<TInputSchema extends ZodSchemaAny, TOutputSchema
119
84
  presentation?: AgentCanvasPresentation;
120
85
  inputSchema: TInputSchema;
121
86
  outputSchema: TOutputSchema;
122
- /**
123
- * Optional credential slots for this tool (same contract as other {@link ToolConfig} shapes).
124
- */
125
87
  credentialRequirements?: ReadonlyArray<CredentialRequirement>;
126
88
  execute: CallableToolExecuteHandler<TInputSchema, TOutputSchema>;
127
89
  }>;
128
- /**
129
- * Inline callable agent tool: DSL sugar over {@link ToolConfig} without a separate {@link NodeResolver}-registered {@link Tool} class.
130
- */
131
90
  declare class CallableToolConfig<TInputSchema extends ZodSchemaAny, TOutputSchema extends ZodSchemaAny> implements ToolConfig {
132
91
  readonly name: string;
133
92
  readonly type: TypeToken<unknown>;
@@ -142,9 +101,6 @@ declare class CallableToolConfig<TInputSchema extends ZodSchemaAny, TOutputSchem
142
101
  getCredentialRequirements(): ReadonlyArray<CredentialRequirement>;
143
102
  getInputSchema(): TInputSchema;
144
103
  getOutputSchema(): TOutputSchema;
145
- /**
146
- * Parses tool input and output with the configured Zod schemas.
147
- */
148
104
  executeTool(args: ToolExecuteArgs<CallableToolConfig<TInputSchema, TOutputSchema>, input<TInputSchema>>): Promise<output<TOutputSchema>>;
149
105
  private parseInput;
150
106
  private parseOutput;
@@ -158,10 +114,6 @@ declare class CallableToolFactoryImpl {
158
114
  declare const CallableToolFactory: CallableToolFactoryImpl;
159
115
  //#endregion
160
116
  //#region src/ai/CallableToolKindToken.d.ts
161
- /**
162
- * Shared {@link import("../di").TypeToken} marker for {@link CallableToolConfig}.
163
- * Callable tools are not registered in {@link NodeResolver}; this class only satisfies {@link ToolConfig#type}.
164
- */
165
117
  declare class CallableToolKindToken {}
166
118
  //#endregion
167
119
  //#region src/ai/AgentToolFactory.d.ts
@@ -177,10 +129,6 @@ declare const AgentToolFactory: AgentToolFactoryImpl;
177
129
  //#endregion
178
130
  //#region src/ai/AgentMessageConfigNormalizerFactory.d.ts
179
131
  declare class AgentMessageConfigNormalizer {
180
- /**
181
- * Prefer {@code input.messages} when present (ItemNode / engine-mapped payloads); otherwise resolve from
182
- * {@link AgentNodeConfig.messages} templates.
183
- */
184
132
  static resolveFromInputOrConfig<TInputJson, TOutputJson>(input: unknown, config: AgentNodeConfig<TInputJson, TOutputJson>, args: AgentMessageBuildArgs<TInputJson>): ReadonlyArray<AgentMessageDto>;
185
133
  static normalize<TInputJson, TOutputJson>(config: AgentNodeConfig<TInputJson, TOutputJson>, args: AgentMessageBuildArgs<TInputJson>): ReadonlyArray<AgentMessageDto>;
186
134
  private static tryMessagesFromStructuredInput;
@@ -214,11 +162,6 @@ type ToolExecuteArgs<TConfig extends ToolConfig = ToolConfig, TInput = unknown>
214
162
  item: Item;
215
163
  itemIndex: number;
216
164
  items: Items;
217
- /**
218
- * Optional sub-agent boundary hooks: when present, the live `agent.tool.call` span and the
219
- * planned tool-call invocationId are forwarded so node-backed runtimes can re-root their child
220
- * execution scope. Plain function tools may safely ignore these hooks.
221
- */
222
165
  hooks?: Readonly<{
223
166
  parentSpan?: TelemetrySpanScope;
224
167
  parentInvocationId?: ConnectionInvocationId;
@@ -249,12 +192,7 @@ interface AgentMessageTemplate<TInputJson = unknown> {
249
192
  readonly role: AgentMessageRole;
250
193
  readonly content: AgentMessageTemplateContent<TInputJson>;
251
194
  }
252
- /** A single prompt line: fixed DTO or template with optional function `content`. */
253
195
  type AgentMessageLine<TInputJson = unknown> = AgentMessageDto | AgentMessageTemplate<TInputJson>;
254
- /**
255
- * Message list for an agent. Prefer a **plain array** of `{ role, content }` (optionally with function `content` for templates).
256
- * Use the object form only when you need `buildMessages` to append messages after optional `prompt` lines.
257
- */
258
196
  type AgentMessageConfig<TInputJson = unknown> = Expr<ReadonlyArray<AgentMessageLine<TInputJson>>, TInputJson> | ReadonlyArray<AgentMessageLine<TInputJson>> | {
259
197
  readonly prompt?: ReadonlyArray<AgentMessageLine<TInputJson>>;
260
198
  readonly buildMessages?: (args: AgentMessageBuildArgs<TInputJson>) => ReadonlyArray<AgentMessageDto>;
@@ -269,7 +207,6 @@ interface AgentGuardrailConfig {
269
207
  readonly onTurnLimitReached?: AgentTurnLimitBehavior;
270
208
  readonly modelInvocationOptions?: AgentModelInvocationOptions;
271
209
  }
272
- /** Defaults aligned with common tool-agent iteration limits (many products use ~10 max rounds). */
273
210
  declare const AgentGuardrailDefaults: {
274
211
  readonly maxTurns: 10;
275
212
  readonly onTurnLimitReached: AgentTurnLimitBehavior;
@@ -293,25 +230,10 @@ interface ChatModelConfig {
293
230
  readonly presentation?: AgentCanvasPresentation;
294
231
  getCredentialRequirements?(): ReadonlyArray<CredentialRequirement>;
295
232
  }
296
- /**
297
- * Provider-neutral chat language model wrapper returned by a {@link ChatModelFactory}.
298
- *
299
- * Thin adapter around an AI SDK `LanguageModelV2` (from `@ai-sdk/provider`) plus the call-site
300
- * defaults Codemation needs at every generate/stream: the provider label, the model name used for
301
- * pricing / telemetry, and the default invocation options (max output tokens, temperature,
302
- * provider-specific overrides).
303
- *
304
- * The consumer (AIAgentNode / AgentStructuredOutputRunner) passes `languageModel` directly into
305
- * `generateText({ model, ... })` from the `ai` package.
306
- */
307
233
  interface ChatLanguageModel {
308
- /** AI SDK `LanguageModelV2` instance (kept `unknown` to avoid leaking the SDK type into `@codemation/core`). */
309
234
  readonly languageModel: unknown;
310
- /** Stable pricing/telemetry key — e.g. `"gpt-4.1-nano"`. */
311
235
  readonly modelName: string;
312
- /** Provider label — e.g. `"openai"`. Used for cost tracking. */
313
236
  readonly provider?: string;
314
- /** Defaults merged into every call. Consumers may override per-invocation. */
315
237
  readonly defaultCallOptions?: ChatLanguageModelCallOptions;
316
238
  }
317
239
  interface ChatLanguageModelCallOptions {
@@ -319,14 +241,8 @@ interface ChatLanguageModelCallOptions {
319
241
  readonly temperature?: number;
320
242
  readonly providerOptions?: Readonly<Record<string, Readonly<Record<string, JsonValue>>>>;
321
243
  }
322
- /**
323
- * Options for a structured-output generate call. Mirrors
324
- * `generateText({ output: Output.object(...) })` from the `ai` package.
325
- */
326
244
  interface StructuredOutputOptions {
327
- /** Optional schema name — used by some providers as the JSON schema name attribute. */
328
245
  readonly schemaName?: string;
329
- /** When `true`, the consumer should pass a strict-mode-compatible JSON Schema record. */
330
246
  readonly strict?: boolean;
331
247
  }
332
248
  interface ChatModelFactory<TConfig extends ChatModelConfig = ChatModelConfig> {
@@ -361,12 +277,6 @@ type NodeBackedToolConfigOptions<TNodeConfig extends RunnableNodeConfig<any, any
361
277
  outputSchema: TOutputSchema;
362
278
  mapInput?: NodeBackedToolInputMapper<TNodeConfig, input<TInputSchema>>;
363
279
  mapOutput?: NodeBackedToolOutputMapper<TNodeConfig, input<TInputSchema>, output<TOutputSchema>>;
364
- /**
365
- * Marks THIS tool binding as human-in-the-loop and sets the behavior when a human rejects the
366
- * approval: `"return"` feeds the rejection back to the agent as a tool result, `"halt"` stops the
367
- * run. Set per binding, so two tools backed by the same node can reject differently. When set, it
368
- * takes precedence over any `humanApprovalToolBehavior` marker carried by the backing node.
369
- */
370
280
  onRejected?: "halt" | "return";
371
281
  }>;
372
282
  interface AgentNodeConfig<TInputJson = unknown, TOutputJson = unknown> extends RunnableNodeConfig<TInputJson, TOutputJson> {
@@ -400,11 +310,6 @@ type AgentConnectionNodeCollectorApi = Readonly<{
400
310
  declare const AgentConnectionNodeCollector: AgentConnectionNodeCollectorApi;
401
311
  //#endregion
402
312
  //#region src/serialization/ItemsInputNormalizer.d.ts
403
- /**
404
- * Normalizes external inputs into the engine's canonical `Items` shape.
405
- * Used at host and builder boundaries where callers may provide either a raw value,
406
- * a single item-like object, or an array of item-like values.
407
- */
408
313
  declare class ItemsInputNormalizer {
409
314
  normalize(raw: unknown): Items;
410
315
  private normalizeItem;
@@ -412,4 +317,4 @@ declare class ItemsInputNormalizer {
412
317
  }
413
318
  //#endregion
414
319
  export { McpServerDeclaration as $, ChatModelFactory as A, ZodSchemaAny as B, AgentToolDefinition as C, ChatLanguageModel as D, AgentTurnLimitBehavior as E, NodeBackedToolOutputMapperArgs as F, CallableToolFactory as G, AgentMessageConfigNormalizer as H, StructuredOutputOptions as I, CallableToolExecuteHandler as J, CallableToolConfig as K, Tool as L, NodeBackedToolInputMapper as M, NodeBackedToolInputMapperArgs as N, ChatLanguageModelCallOptions as O, NodeBackedToolOutputMapper as P, RunFinishedAtFactory as Q, ToolConfig as R, AgentToolCallPlanner as S, AgentToolToken as T, AgentToolFactory as U, AgentConfigInspector as V, CallableToolKindToken as W, NodeIterationIdFactory as X, NodeBackedToolConfig as Y, ConnectionNodeIdFactory as Z, AgentMessageTemplateContent as _, AgentConnectionNodeRole as a, AgentTool as b, AgentCanvasPresentation as c, AgentMessageBuildArgs as d, McpServerTransport as et, AgentMessageConfig as f, AgentMessageTemplate as g, AgentMessageRole as h, AgentConnectionNodeDescriptor as i, NodeBackedToolConfigOptions as j, ChatModelConfig as k, AgentGuardrailConfig as l, AgentMessageLine as m, AgentConnectionCredentialSource as n, McpServerResolver as o, AgentMessageDto as p, CallableToolConfigOptions as q, AgentConnectionNodeCollector as r, AgentAttachmentRole as s, ItemsInputNormalizer as t, AgentGuardrailDefaults as u, AgentModelInvocationOptions as v, AgentToolExecuteArgs as w, AgentToolCall as x, AgentNodeConfig as y, ToolExecuteArgs as z };
415
- //# sourceMappingURL=ItemsInputNormalizer-Bi8m-Ijs.d.cts.map
320
+ //# sourceMappingURL=ItemsInputNormalizer-A5txcOWX.d.cts.map
@@ -1,4 +1,4 @@
1
- const require_di = require('./di-LP2qSHkY.cjs');
1
+ const require_di = require('./di-C6Ubf9o5.cjs');
2
2
  let tsyringe = require("tsyringe");
3
3
  tsyringe = require_di.__toESM(tsyringe);
4
4
 
@@ -40,4 +40,4 @@ Object.defineProperty(exports, 'ItemsInputNormalizer', {
40
40
  return ItemsInputNormalizer;
41
41
  }
42
42
  });
43
- //# sourceMappingURL=ItemsInputNormalizer-BbQTSEkZ.cjs.map
43
+ //# sourceMappingURL=ItemsInputNormalizer-C1fv3sMW.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ItemsInputNormalizer-C1fv3sMW.cjs","names":["ItemsInputNormalizer"],"sources":["../src/serialization/ItemsInputNormalizer.ts"],"sourcesContent":["import type { Item, Items } from \"../contracts/workflowTypes\";\nimport { injectable } from \"../di\";\n\n@injectable()\nexport class ItemsInputNormalizer {\n normalize(raw: unknown): Items {\n if (raw === undefined || raw === null) {\n return [];\n }\n if (Array.isArray(raw)) {\n return raw.map((value) => this.normalizeItem(value));\n }\n return [this.normalizeItem(raw)];\n }\n\n private normalizeItem(raw: unknown): Item {\n if (!this.isItem(raw)) {\n return { json: raw };\n }\n return {\n json: raw.json,\n ...(raw.binary === undefined ? {} : { binary: raw.binary }),\n ...(raw.meta === undefined ? {} : { meta: raw.meta }),\n ...(raw.paired === undefined ? {} : { paired: raw.paired }),\n };\n }\n\n private isItem(raw: unknown): raw is Item {\n return typeof raw === \"object\" && raw !== null && Object.prototype.hasOwnProperty.call(raw, \"json\");\n }\n}\n"],"mappings":";;;;;;;;;;;;;;AAIO,iCAAMA,uBAAqB;CAChC,UAAU,KAAqB;AAC7B,MAAI,QAAQ,UAAa,QAAQ,KAC/B,QAAO,EAAE;AAEX,MAAI,MAAM,QAAQ,IAAI,CACpB,QAAO,IAAI,KAAK,UAAU,KAAK,cAAc,MAAM,CAAC;AAEtD,SAAO,CAAC,KAAK,cAAc,IAAI,CAAC;;CAGlC,AAAQ,cAAc,KAAoB;AACxC,MAAI,CAAC,KAAK,OAAO,IAAI,CACnB,QAAO,EAAE,MAAM,KAAK;AAEtB,SAAO;GACL,MAAM,IAAI;GACV,GAAI,IAAI,WAAW,SAAY,EAAE,GAAG,EAAE,QAAQ,IAAI,QAAQ;GAC1D,GAAI,IAAI,SAAS,SAAY,EAAE,GAAG,EAAE,MAAM,IAAI,MAAM;GACpD,GAAI,IAAI,WAAW,SAAY,EAAE,GAAG,EAAE,QAAQ,IAAI,QAAQ;GAC3D;;CAGH,AAAQ,OAAO,KAA2B;AACxC,SAAO,OAAO,QAAQ,YAAY,QAAQ,QAAQ,OAAO,UAAU,eAAe,KAAK,KAAK,OAAO;;;6DAzB1F"}
@@ -1,4 +1,4 @@
1
- import { Eo as NodeId, Ii as NodeExecutionContext, Mr as RunnableNodeConfig, Nr as RunnableNodeInputJson, On as TypeToken, Rt as ConnectionInvocationId, Sr as NodeOutputs, To as NodeConnectionName, fr as NodeConfigBase, gt as Expr, ir as Items, ja as TelemetrySpanScope, lr as JsonValue, nr as Item, q as McpServerDeclaration, uo as CredentialRequirement } from "./index-rllWL4r-.js";
1
+ import { $i as NodeExecutionContext, $t as ConnectionInvocationId, Ao as CredentialRequirement, Et as Expr, Go as NodeConnectionName, Ko as NodeId, Or as NodeConfigBase, Rr as NodeOutputs, Tr as JsonValue, Un as TypeToken, Xr as RunnableNodeInputJson, Y as McpServerDeclaration, Ya as TelemetrySpanScope, Yr as RunnableNodeConfig, br as Items, vr as Item } from "./index-CRv3_pY3.js";
2
2
  import { ZodType, input, output } from "zod";
3
3
 
4
4
  //#region src/ai/NodeBackedToolConfig.d.ts
@@ -33,15 +33,9 @@ type CallableToolConfigOptions<TInputSchema extends ZodSchemaAny, TOutputSchema
33
33
  presentation?: AgentCanvasPresentation;
34
34
  inputSchema: TInputSchema;
35
35
  outputSchema: TOutputSchema;
36
- /**
37
- * Optional credential slots for this tool (same contract as other {@link ToolConfig} shapes).
38
- */
39
36
  credentialRequirements?: ReadonlyArray<CredentialRequirement>;
40
37
  execute: CallableToolExecuteHandler<TInputSchema, TOutputSchema>;
41
38
  }>;
42
- /**
43
- * Inline callable agent tool: DSL sugar over {@link ToolConfig} without a separate {@link NodeResolver}-registered {@link Tool} class.
44
- */
45
39
  declare class CallableToolConfig<TInputSchema extends ZodSchemaAny, TOutputSchema extends ZodSchemaAny> implements ToolConfig {
46
40
  readonly name: string;
47
41
  readonly type: TypeToken<unknown>;
@@ -56,9 +50,6 @@ declare class CallableToolConfig<TInputSchema extends ZodSchemaAny, TOutputSchem
56
50
  getCredentialRequirements(): ReadonlyArray<CredentialRequirement>;
57
51
  getInputSchema(): TInputSchema;
58
52
  getOutputSchema(): TOutputSchema;
59
- /**
60
- * Parses tool input and output with the configured Zod schemas.
61
- */
62
53
  executeTool(args: ToolExecuteArgs<CallableToolConfig<TInputSchema, TOutputSchema>, input<TInputSchema>>): Promise<output<TOutputSchema>>;
63
54
  private parseInput;
64
55
  private parseOutput;
@@ -72,10 +63,6 @@ declare class CallableToolFactoryImpl {
72
63
  declare const CallableToolFactory: CallableToolFactoryImpl;
73
64
  //#endregion
74
65
  //#region src/ai/CallableToolKindToken.d.ts
75
- /**
76
- * Shared {@link import("../di").TypeToken} marker for {@link CallableToolConfig}.
77
- * Callable tools are not registered in {@link NodeResolver}; this class only satisfies {@link ToolConfig#type}.
78
- */
79
66
  declare class CallableToolKindToken {}
80
67
  //#endregion
81
68
  //#region src/ai/AgentToolFactory.d.ts
@@ -91,10 +78,6 @@ declare const AgentToolFactory: AgentToolFactoryImpl;
91
78
  //#endregion
92
79
  //#region src/ai/AgentMessageConfigNormalizerFactory.d.ts
93
80
  declare class AgentMessageConfigNormalizer {
94
- /**
95
- * Prefer {@code input.messages} when present (ItemNode / engine-mapped payloads); otherwise resolve from
96
- * {@link AgentNodeConfig.messages} templates.
97
- */
98
81
  static resolveFromInputOrConfig<TInputJson, TOutputJson>(input: unknown, config: AgentNodeConfig<TInputJson, TOutputJson>, args: AgentMessageBuildArgs<TInputJson>): ReadonlyArray<AgentMessageDto>;
99
82
  static normalize<TInputJson, TOutputJson>(config: AgentNodeConfig<TInputJson, TOutputJson>, args: AgentMessageBuildArgs<TInputJson>): ReadonlyArray<AgentMessageDto>;
100
83
  private static tryMessagesFromStructuredInput;
@@ -128,11 +111,6 @@ type ToolExecuteArgs<TConfig extends ToolConfig = ToolConfig, TInput = unknown>
128
111
  item: Item;
129
112
  itemIndex: number;
130
113
  items: Items;
131
- /**
132
- * Optional sub-agent boundary hooks: when present, the live `agent.tool.call` span and the
133
- * planned tool-call invocationId are forwarded so node-backed runtimes can re-root their child
134
- * execution scope. Plain function tools may safely ignore these hooks.
135
- */
136
114
  hooks?: Readonly<{
137
115
  parentSpan?: TelemetrySpanScope;
138
116
  parentInvocationId?: ConnectionInvocationId;
@@ -163,12 +141,7 @@ interface AgentMessageTemplate<TInputJson = unknown> {
163
141
  readonly role: AgentMessageRole;
164
142
  readonly content: AgentMessageTemplateContent<TInputJson>;
165
143
  }
166
- /** A single prompt line: fixed DTO or template with optional function `content`. */
167
144
  type AgentMessageLine<TInputJson = unknown> = AgentMessageDto | AgentMessageTemplate<TInputJson>;
168
- /**
169
- * Message list for an agent. Prefer a **plain array** of `{ role, content }` (optionally with function `content` for templates).
170
- * Use the object form only when you need `buildMessages` to append messages after optional `prompt` lines.
171
- */
172
145
  type AgentMessageConfig<TInputJson = unknown> = Expr<ReadonlyArray<AgentMessageLine<TInputJson>>, TInputJson> | ReadonlyArray<AgentMessageLine<TInputJson>> | {
173
146
  readonly prompt?: ReadonlyArray<AgentMessageLine<TInputJson>>;
174
147
  readonly buildMessages?: (args: AgentMessageBuildArgs<TInputJson>) => ReadonlyArray<AgentMessageDto>;
@@ -183,7 +156,6 @@ interface AgentGuardrailConfig {
183
156
  readonly onTurnLimitReached?: AgentTurnLimitBehavior;
184
157
  readonly modelInvocationOptions?: AgentModelInvocationOptions;
185
158
  }
186
- /** Defaults aligned with common tool-agent iteration limits (many products use ~10 max rounds). */
187
159
  declare const AgentGuardrailDefaults: {
188
160
  readonly maxTurns: 10;
189
161
  readonly onTurnLimitReached: AgentTurnLimitBehavior;
@@ -207,25 +179,10 @@ interface ChatModelConfig {
207
179
  readonly presentation?: AgentCanvasPresentation;
208
180
  getCredentialRequirements?(): ReadonlyArray<CredentialRequirement>;
209
181
  }
210
- /**
211
- * Provider-neutral chat language model wrapper returned by a {@link ChatModelFactory}.
212
- *
213
- * Thin adapter around an AI SDK `LanguageModelV2` (from `@ai-sdk/provider`) plus the call-site
214
- * defaults Codemation needs at every generate/stream: the provider label, the model name used for
215
- * pricing / telemetry, and the default invocation options (max output tokens, temperature,
216
- * provider-specific overrides).
217
- *
218
- * The consumer (AIAgentNode / AgentStructuredOutputRunner) passes `languageModel` directly into
219
- * `generateText({ model, ... })` from the `ai` package.
220
- */
221
182
  interface ChatLanguageModel {
222
- /** AI SDK `LanguageModelV2` instance (kept `unknown` to avoid leaking the SDK type into `@codemation/core`). */
223
183
  readonly languageModel: unknown;
224
- /** Stable pricing/telemetry key — e.g. `"gpt-4.1-nano"`. */
225
184
  readonly modelName: string;
226
- /** Provider label — e.g. `"openai"`. Used for cost tracking. */
227
185
  readonly provider?: string;
228
- /** Defaults merged into every call. Consumers may override per-invocation. */
229
186
  readonly defaultCallOptions?: ChatLanguageModelCallOptions;
230
187
  }
231
188
  interface ChatLanguageModelCallOptions {
@@ -233,14 +190,8 @@ interface ChatLanguageModelCallOptions {
233
190
  readonly temperature?: number;
234
191
  readonly providerOptions?: Readonly<Record<string, Readonly<Record<string, JsonValue>>>>;
235
192
  }
236
- /**
237
- * Options for a structured-output generate call. Mirrors
238
- * `generateText({ output: Output.object(...) })` from the `ai` package.
239
- */
240
193
  interface StructuredOutputOptions {
241
- /** Optional schema name — used by some providers as the JSON schema name attribute. */
242
194
  readonly schemaName?: string;
243
- /** When `true`, the consumer should pass a strict-mode-compatible JSON Schema record. */
244
195
  readonly strict?: boolean;
245
196
  }
246
197
  interface ChatModelFactory<TConfig extends ChatModelConfig = ChatModelConfig> {
@@ -275,12 +226,6 @@ type NodeBackedToolConfigOptions<TNodeConfig extends RunnableNodeConfig<any, any
275
226
  outputSchema: TOutputSchema;
276
227
  mapInput?: NodeBackedToolInputMapper<TNodeConfig, input<TInputSchema>>;
277
228
  mapOutput?: NodeBackedToolOutputMapper<TNodeConfig, input<TInputSchema>, output<TOutputSchema>>;
278
- /**
279
- * Marks THIS tool binding as human-in-the-loop and sets the behavior when a human rejects the
280
- * approval: `"return"` feeds the rejection back to the agent as a tool result, `"halt"` stops the
281
- * run. Set per binding, so two tools backed by the same node can reject differently. When set, it
282
- * takes precedence over any `humanApprovalToolBehavior` marker carried by the backing node.
283
- */
284
229
  onRejected?: "halt" | "return";
285
230
  }>;
286
231
  interface AgentNodeConfig<TInputJson = unknown, TOutputJson = unknown> extends RunnableNodeConfig<TInputJson, TOutputJson> {
@@ -314,11 +259,6 @@ type AgentConnectionNodeCollectorApi = Readonly<{
314
259
  declare const AgentConnectionNodeCollector: AgentConnectionNodeCollectorApi;
315
260
  //#endregion
316
261
  //#region src/serialization/ItemsInputNormalizer.d.ts
317
- /**
318
- * Normalizes external inputs into the engine's canonical `Items` shape.
319
- * Used at host and builder boundaries where callers may provide either a raw value,
320
- * a single item-like object, or an array of item-like values.
321
- */
322
262
  declare class ItemsInputNormalizer {
323
263
  normalize(raw: unknown): Items;
324
264
  private normalizeItem;
@@ -326,4 +266,4 @@ declare class ItemsInputNormalizer {
326
266
  }
327
267
  //#endregion
328
268
  export { ChatModelFactory as A, ZodSchemaAny as B, AgentToolDefinition as C, ChatLanguageModel as D, AgentTurnLimitBehavior as E, NodeBackedToolOutputMapperArgs as F, CallableToolFactory as G, AgentMessageConfigNormalizer as H, StructuredOutputOptions as I, CallableToolExecuteHandler as J, CallableToolConfig as K, Tool as L, NodeBackedToolInputMapper as M, NodeBackedToolInputMapperArgs as N, ChatLanguageModelCallOptions as O, NodeBackedToolOutputMapper as P, ToolConfig as R, AgentToolCallPlanner as S, AgentToolToken as T, AgentToolFactory as U, AgentConfigInspector as V, CallableToolKindToken as W, NodeBackedToolConfig as Y, AgentMessageTemplateContent as _, AgentConnectionNodeRole as a, AgentTool as b, AgentCanvasPresentation as c, AgentMessageBuildArgs as d, AgentMessageConfig as f, AgentMessageTemplate as g, AgentMessageRole as h, AgentConnectionNodeDescriptor as i, NodeBackedToolConfigOptions as j, ChatModelConfig as k, AgentGuardrailConfig as l, AgentMessageLine as m, AgentConnectionCredentialSource as n, McpServerResolver as o, AgentMessageDto as p, CallableToolConfigOptions as q, AgentConnectionNodeCollector as r, AgentAttachmentRole as s, ItemsInputNormalizer as t, AgentGuardrailDefaults as u, AgentModelInvocationOptions as v, AgentToolExecuteArgs as w, AgentToolCall as x, AgentNodeConfig as y, ToolExecuteArgs as z };
329
- //# sourceMappingURL=ItemsInputNormalizer-BYljnXU0.d.ts.map
269
+ //# sourceMappingURL=ItemsInputNormalizer-D2vrMrX1.d.ts.map
@@ -1,4 +1,4 @@
1
- import { a as injectable } from "./di-tom0pM2h.js";
1
+ import { a as injectable } from "./di-Cjiil7U-.js";
2
2
 
3
3
  //#region \0@oxc-project+runtime@0.95.0/helpers/decorate.js
4
4
  function __decorate(decorators, target, key, desc) {
@@ -33,4 +33,4 @@ ItemsInputNormalizer = __decorate([injectable()], ItemsInputNormalizer);
33
33
 
34
34
  //#endregion
35
35
  export { ItemsInputNormalizer as t };
36
- //# sourceMappingURL=ItemsInputNormalizer-CSZGMgl3.js.map
36
+ //# sourceMappingURL=ItemsInputNormalizer-fUYo4GLV.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ItemsInputNormalizer-fUYo4GLV.js","names":["ItemsInputNormalizer"],"sources":["../src/serialization/ItemsInputNormalizer.ts"],"sourcesContent":["import type { Item, Items } from \"../contracts/workflowTypes\";\nimport { injectable } from \"../di\";\n\n@injectable()\nexport class ItemsInputNormalizer {\n normalize(raw: unknown): Items {\n if (raw === undefined || raw === null) {\n return [];\n }\n if (Array.isArray(raw)) {\n return raw.map((value) => this.normalizeItem(value));\n }\n return [this.normalizeItem(raw)];\n }\n\n private normalizeItem(raw: unknown): Item {\n if (!this.isItem(raw)) {\n return { json: raw };\n }\n return {\n json: raw.json,\n ...(raw.binary === undefined ? {} : { binary: raw.binary }),\n ...(raw.meta === undefined ? {} : { meta: raw.meta }),\n ...(raw.paired === undefined ? {} : { paired: raw.paired }),\n };\n }\n\n private isItem(raw: unknown): raw is Item {\n return typeof raw === \"object\" && raw !== null && Object.prototype.hasOwnProperty.call(raw, \"json\");\n }\n}\n"],"mappings":";;;;;;;;;;;;AAIO,iCAAMA,uBAAqB;CAChC,UAAU,KAAqB;AAC7B,MAAI,QAAQ,UAAa,QAAQ,KAC/B,QAAO,EAAE;AAEX,MAAI,MAAM,QAAQ,IAAI,CACpB,QAAO,IAAI,KAAK,UAAU,KAAK,cAAc,MAAM,CAAC;AAEtD,SAAO,CAAC,KAAK,cAAc,IAAI,CAAC;;CAGlC,AAAQ,cAAc,KAAoB;AACxC,MAAI,CAAC,KAAK,OAAO,IAAI,CACnB,QAAO,EAAE,MAAM,KAAK;AAEtB,SAAO;GACL,MAAM,IAAI;GACV,GAAI,IAAI,WAAW,SAAY,EAAE,GAAG,EAAE,QAAQ,IAAI,QAAQ;GAC1D,GAAI,IAAI,SAAS,SAAY,EAAE,GAAG,EAAE,MAAM,IAAI,MAAM;GACpD,GAAI,IAAI,WAAW,SAAY,EAAE,GAAG,EAAE,QAAQ,IAAI,QAAQ;GAC3D;;CAGH,AAAQ,OAAO,KAA2B;AACxC,SAAO,OAAO,QAAQ,YAAY,QAAQ,QAAQ,OAAO,UAAU,eAAe,KAAK,KAAK,OAAO;;;mCAzBtG,YAAY"}
@@ -1,4 +1,4 @@
1
- import { Ar as WorkflowSnapshotResolver, D as RunCurrentState, Er as WorkflowRepository, Fr as WebhookTriggerMatcher, H as WorkflowExecutionRepository, I as RunStopCondition, Ir as WebhookTriggerResolution, Mt as NodeActivationId, N as RunResult, Pr as WebhookInvocationMatch, Tt as Items, Ut as NodeOutputs, Xi as WorkflowId, Yn as LiveWorkflowRepository, Zn as NodeActivationContinuation, Zt as RunId, ar as NodeExecutionRequestHandler, ir as NodeExecutionRequest, jr as HttpMethod, k as RunExecutionOptions, on as WorkflowDefinition, p as NodeInputsByPort, pr as ResumeContext, qi as NodeId, qt as ParentExecutionRef, s as CurrentStateExecutionRequest, w as PersistedWorkflowTokenRegistryLike, z as WebhookRunResult } from "./agentMcpTypes-DGIwk6Ue.cjs";
1
+ import { $n as NodeActivationContinuation, $t as RunId, D as RunCurrentState, Et as Items, H as WorkflowExecutionRepository, I as RunStopCondition, Jt as ParentExecutionRef, Lr as WebhookInvocationMatch, N as RunResult, Nr as WorkflowSnapshotResolver, Nt as NodeActivationId, Pr as HttpMethod, Qi as NodeId, Rr as WebhookTriggerMatcher, Wt as NodeOutputs, Zn as LiveWorkflowRepository, cn as WorkflowDefinition, hr as ResumeContext, k as RunExecutionOptions, kr as WorkflowRepository, or as NodeExecutionRequest, p as NodeInputsByPort, s as CurrentStateExecutionRequest, sr as NodeExecutionRequestHandler, ta as WorkflowId, w as PersistedWorkflowTokenRegistryLike, z as WebhookRunResult, zr as WebhookTriggerResolution } from "./agentMcpTypes-BHX4RQCC.cjs";
2
2
 
3
3
  //#region src/orchestration/Engine.d.ts
4
4
  interface EngineTriggerRuntime {
@@ -71,11 +71,6 @@ interface EngineFacadeDeps {
71
71
  runContinuationService: EngineRunContinuationService;
72
72
  nodeExecutionRequestHandler: EngineNodeExecutionRequestHandler;
73
73
  }
74
- /**
75
- * Runtime facade for orchestration, continuation, triggers, and webhook routing.
76
- * Prefer {@link import("../intents/RunIntentService").RunIntentService} for host/HTTP invocation boundaries.
77
- * The class token is exported from `@codemation/core/bootstrap` (not the main `@codemation/core` barrel).
78
- */
79
74
  declare class Engine implements NodeActivationContinuation, NodeExecutionRequestHandler {
80
75
  private readonly deps;
81
76
  constructor(deps: EngineFacadeDeps);
@@ -136,10 +131,6 @@ declare class Engine implements NodeActivationContinuation, NodeExecutionRequest
136
131
  status: "completed" | "failed" | "halted";
137
132
  }>>;
138
133
  waitForWebhookResponse(runId: RunId): Promise<WebhookRunResult>;
139
- /**
140
- * Re-activate a suspended run item with a human decision (HITL).
141
- * The HTTP resume endpoint calls this; this method exposes the engine primitive.
142
- */
143
134
  resumeRun(args: {
144
135
  runId: RunId;
145
136
  taskId: string;
@@ -209,12 +200,8 @@ declare class RunIntentService {
209
200
  }): WebhookTriggerResolution;
210
201
  runMatchedWebhook(args: MatchedWebhookRunIntent): Promise<WebhookRunResult>;
211
202
  runWebhookMatch(args: WebhookMatchRunIntent): Promise<WebhookRunResult>;
212
- /**
213
- * Webhook-triggered runs always force inline execution first.
214
- * This is the highest-precedence scheduler override: it wins over node hints and container defaults.
215
- */
216
203
  private createWebhookExecutionOptions;
217
204
  }
218
205
  //#endregion
219
206
  export { InMemoryLiveWorkflowRepository as n, Engine as r, RunIntentService as t };
220
- //# sourceMappingURL=RunIntentService-BitgkKaT.d.cts.map
207
+ //# sourceMappingURL=RunIntentService-DKxuHTUz.d.cts.map
@@ -1,4 +1,4 @@
1
- import { $t as PersistedRunState, Ai as NodeActivationContinuation, Ar as RunId, Bt as CurrentStateExecutionRequest, Dr as PersistedRunPolicySnapshot, Eo as NodeId, Er as ParentExecutionRef, Hi as NodeResolver, Hn as EngineExecutionLimitsPolicyConfig, Hr as WorkflowErrorHandlerSpec, Jr as WorkflowStoragePolicyDecisionArgs, Ki as ResumeContext, Kr as WorkflowPolicyRuntimeDefaults, Kt as NodeInputsByPort, Li as NodeExecutionRequest, Oi as LiveWorkflowRepository, Ri as NodeExecutionRequestHandler, Sr as NodeOutputs, Vn as EngineExecutionLimitsPolicy, Vr as WorkflowErrorHandler, aa as WorkflowRepository, cn as RunExecutionOptions, dr as NodeActivationId, fn as RunResult, fr as NodeConfigBase, gr as NodeErrorHandlerSpec, ha as WebhookTriggerResolution, hn as RunStopCondition, ir as Items, ko as WorkflowId, la as WorkflowSnapshotResolver, ma as WebhookTriggerMatcher, mr as NodeErrorHandler, nn as PersistedWorkflowSnapshotNode, on as RunCurrentState, pa as WebhookInvocationMatch, rn as PersistedWorkflowTokenRegistryLike, tn as PersistedWorkflowSnapshot, ua as HttpMethod, vn as WebhookRunResult, xn as WorkflowExecutionRepository, zr as WorkflowDefinition } from "./index-rllWL4r-.js";
1
+ import { An as RunStopCondition, Ar as NodeErrorHandler, Ca as WorkflowRepository, Cn as RunExecutionOptions, Da as WorkflowSnapshotResolver, Dn as RunResult, Dr as NodeActivationId, Gi as LiveWorkflowRepository, Hr as ParentExecutionRef, In as WorkflowExecutionRepository, Ko as NodeId, Ma as WebhookTriggerMatcher, Mr as NodeErrorHandlerSpec, Na as WebhookTriggerResolution, Nn as WebhookRunResult, Oa as HttpMethod, Or as NodeConfigBase, Rr as NodeOutputs, Ur as PersistedRunPolicySnapshot, Yo as WorkflowId, _n as PersistedWorkflowSnapshotNode, aa as NodeResolver, ai as WorkflowErrorHandlerSpec, br as Items, di as WorkflowStoragePolicyDecisionArgs, ea as NodeExecutionRequest, gn as PersistedWorkflowSnapshot, ii as WorkflowErrorHandler, ir as EngineExecutionLimitsPolicyConfig, ja as WebhookInvocationMatch, la as ResumeContext, li as WorkflowPolicyRuntimeDefaults, mn as PersistedRunState, ni as WorkflowDefinition, qi as NodeActivationContinuation, qr as RunId, rr as EngineExecutionLimitsPolicy, sn as NodeInputsByPort, ta as NodeExecutionRequestHandler, tn as CurrentStateExecutionRequest, vn as PersistedWorkflowTokenRegistryLike, xn as RunCurrentState } from "./index-CRv3_pY3.js";
2
2
 
3
3
  //#region src/orchestration/Engine.d.ts
4
4
  interface EngineTriggerRuntime {
@@ -71,11 +71,6 @@ interface EngineFacadeDeps {
71
71
  runContinuationService: EngineRunContinuationService;
72
72
  nodeExecutionRequestHandler: EngineNodeExecutionRequestHandler;
73
73
  }
74
- /**
75
- * Runtime facade for orchestration, continuation, triggers, and webhook routing.
76
- * Prefer {@link import("../intents/RunIntentService").RunIntentService} for host/HTTP invocation boundaries.
77
- * The class token is exported from `@codemation/core/bootstrap` (not the main `@codemation/core` barrel).
78
- */
79
74
  declare class Engine implements NodeActivationContinuation, NodeExecutionRequestHandler {
80
75
  private readonly deps;
81
76
  constructor(deps: EngineFacadeDeps);
@@ -136,10 +131,6 @@ declare class Engine implements NodeActivationContinuation, NodeExecutionRequest
136
131
  status: "completed" | "failed" | "halted";
137
132
  }>>;
138
133
  waitForWebhookResponse(runId: RunId): Promise<WebhookRunResult>;
139
- /**
140
- * Re-activate a suspended run item with a human decision (HITL).
141
- * The HTTP resume endpoint calls this; this method exposes the engine primitive.
142
- */
143
134
  resumeRun(args: {
144
135
  runId: RunId;
145
136
  taskId: string;
@@ -178,9 +169,6 @@ declare class WorkflowPolicyErrorServices {
178
169
  }
179
170
  //#endregion
180
171
  //#region src/policies/executionLimits/EngineExecutionLimitsPolicyFactory.d.ts
181
- /**
182
- * Builds {@link EngineExecutionLimitsPolicy} by merging {@link ENGINE_EXECUTION_LIMITS_DEFAULTS} with optional `overrides` (e.g. host `runtime.engineExecutionLimits`).
183
- */
184
172
  declare class EngineExecutionLimitsPolicyFactory {
185
173
  create(overrides?: Partial<EngineExecutionLimitsPolicyConfig>): EngineExecutionLimitsPolicy;
186
174
  }
@@ -197,10 +185,6 @@ declare class WorkflowSnapshotCodec {
197
185
  create(workflow: WorkflowDefinition): PersistedWorkflowSnapshot;
198
186
  hydrate(snapshotNode: PersistedWorkflowSnapshotNode, liveConfig: NodeConfigBase): NodeConfigBase;
199
187
  private serializeConfig;
200
- /**
201
- * Safely call `config.inspectorSummary()` and return a plain JSON-safe array, or undefined.
202
- * Returns undefined if the method is absent, throws, or produces no valid rows.
203
- */
204
188
  private safeInspectorSummary;
205
189
  private injectTokenIds;
206
190
  private mergeValue;
@@ -288,12 +272,8 @@ declare class RunIntentService {
288
272
  }): WebhookTriggerResolution;
289
273
  runMatchedWebhook(args: MatchedWebhookRunIntent): Promise<WebhookRunResult>;
290
274
  runWebhookMatch(args: WebhookMatchRunIntent): Promise<WebhookRunResult>;
291
- /**
292
- * Webhook-triggered runs always force inline execution first.
293
- * This is the highest-precedence scheduler override: it wins over node hints and container defaults.
294
- */
295
275
  private createWebhookExecutionOptions;
296
276
  }
297
277
  //#endregion
298
278
  export { RunPolicySnapshotFactory as a, RunTerminalPersistenceCoordinator as c, WorkflowSnapshotCodec as i, WorkflowStoragePolicyEvaluator as l, InMemoryLiveWorkflowRepository as n, EngineExecutionLimitsPolicyFactory as o, EngineWorkflowRunnerService as r, WorkflowPolicyErrorServices as s, RunIntentService as t, Engine as u };
299
- //# sourceMappingURL=RunIntentService-DYpqfu6D.d.ts.map
279
+ //# sourceMappingURL=RunIntentService-DrpKli2k.d.ts.map