@smithers-orchestrator/engine 0.19.0 → 0.20.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smithers-orchestrator/engine",
3
- "version": "0.19.0",
3
+ "version": "0.20.0",
4
4
  "description": "Concrete Smithers workflow execution engine",
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -33,20 +33,20 @@
33
33
  "react": "^19.2.5",
34
34
  "react-dom": "^19.2.5",
35
35
  "zod": "^4.3.6",
36
- "@smithers-orchestrator/components": "0.19.0",
37
- "@smithers-orchestrator/agents": "0.19.0",
38
- "@smithers-orchestrator/db": "0.19.0",
39
- "@smithers-orchestrator/errors": "0.19.0",
40
- "@smithers-orchestrator/driver": "0.19.0",
41
- "@smithers-orchestrator/graph": "0.19.0",
42
- "@smithers-orchestrator/memory": "0.19.0",
43
- "@smithers-orchestrator/observability": "0.19.0",
44
- "@smithers-orchestrator/react-reconciler": "0.19.0",
45
- "@smithers-orchestrator/sandbox": "0.19.0",
46
- "@smithers-orchestrator/scheduler": "0.19.0",
47
- "@smithers-orchestrator/scorers": "0.19.0",
48
- "@smithers-orchestrator/time-travel": "0.19.0",
49
- "@smithers-orchestrator/vcs": "0.19.0"
36
+ "@smithers-orchestrator/agents": "0.20.0",
37
+ "@smithers-orchestrator/driver": "0.20.0",
38
+ "@smithers-orchestrator/components": "0.20.0",
39
+ "@smithers-orchestrator/db": "0.20.0",
40
+ "@smithers-orchestrator/graph": "0.20.0",
41
+ "@smithers-orchestrator/memory": "0.20.0",
42
+ "@smithers-orchestrator/errors": "0.20.0",
43
+ "@smithers-orchestrator/observability": "0.20.0",
44
+ "@smithers-orchestrator/react-reconciler": "0.20.0",
45
+ "@smithers-orchestrator/sandbox": "0.20.0",
46
+ "@smithers-orchestrator/scheduler": "0.20.0",
47
+ "@smithers-orchestrator/scorers": "0.20.0",
48
+ "@smithers-orchestrator/vcs": "0.20.0",
49
+ "@smithers-orchestrator/time-travel": "0.20.0"
50
50
  },
51
51
  "devDependencies": {
52
52
  "@types/bun": "latest",
@@ -789,25 +789,262 @@ function normalizeExecutionError(result) {
789
789
  }
790
790
  return new SmithersError("WORKFLOW_EXECUTION_FAILED", `Workflow execution ended with status "${result.status}"`, { status: result.status });
791
791
  }
792
+ /**
793
+ * @typedef {{ _tag: "WorkflowGraph"; expr: unknown; pipe: (...fns: Array<(g: any) => any>) => any }} WorkflowGraph
794
+ */
795
+
796
+ /**
797
+ * @param {unknown} value
798
+ * @returns {value is WorkflowGraph}
799
+ */
800
+ function isWorkflowGraph(value) {
801
+ return Boolean(value) && typeof value === "object" && /** @type {any} */ (value)._tag === "WorkflowGraph";
802
+ }
803
+
804
+ /**
805
+ * @param {unknown} expr
806
+ * @returns {WorkflowGraph}
807
+ */
808
+ function makeGraph(expr) {
809
+ /** @type {WorkflowGraph} */
810
+ const graph = /** @type {any} */ ({ _tag: "WorkflowGraph", expr });
811
+ graph.pipe = function pipe(...fns) {
812
+ return fns.reduce((acc, fn) => fn(acc), graph);
813
+ };
814
+ return graph;
815
+ }
816
+
817
+ /**
818
+ * Build the graph constructors shared by Smithers.workflow and Smithers.fragment.
819
+ */
820
+ function makeFactory() {
821
+ return {
822
+ /**
823
+ * @param {string} id
824
+ * @param {StepOptions} options
825
+ */
826
+ step: (id, options) => makeGraph({ _tag: "Step", id, options }),
827
+ /**
828
+ * @param {string} id
829
+ * @param {ApprovalOptions} options
830
+ */
831
+ approval: (id, options) => makeGraph({ _tag: "Approval", id, options }),
832
+ /**
833
+ * @param {WorkflowGraph[]} children
834
+ */
835
+ sequence: (...children) => makeGraph({ _tag: "Sequence", children }),
836
+ parallel: (...args) => {
837
+ let maxConcurrency;
838
+ const items = [...args];
839
+ const last = items[items.length - 1];
840
+ if (last &&
841
+ typeof last === "object" &&
842
+ !Array.isArray(last) &&
843
+ !isWorkflowGraph(last) &&
844
+ "maxConcurrency" in last) {
845
+ maxConcurrency = Number(last.maxConcurrency);
846
+ items.pop();
847
+ }
848
+ return makeGraph({ _tag: "Parallel", children: items, maxConcurrency });
849
+ },
850
+ match: (source, options) => makeGraph({
851
+ _tag: "Match",
852
+ source,
853
+ when: options.when,
854
+ then: options.then,
855
+ else: options.else,
856
+ }),
857
+ branch: (options) => makeGraph({
858
+ _tag: "Branch",
859
+ condition: options.condition,
860
+ needs: options.needs,
861
+ then: options.then,
862
+ else: options.else,
863
+ }),
864
+ loop: (options) => makeGraph({
865
+ _tag: "Loop",
866
+ id: options.id,
867
+ child: options.children,
868
+ until: options.until,
869
+ maxIterations: options.maxIterations,
870
+ onMaxReached: options.onMaxReached,
871
+ }),
872
+ worktree: (options) => makeGraph({
873
+ _tag: "Worktree",
874
+ id: options.id,
875
+ path: options.path,
876
+ branch: options.branch,
877
+ skipIf: options.skipIf,
878
+ needs: options.needs,
879
+ child: options.children,
880
+ }),
881
+ scope: (instanceId, child) => makeGraph({
882
+ _tag: "Scope",
883
+ instanceId,
884
+ child,
885
+ }),
886
+ };
887
+ }
888
+
889
+ /**
890
+ * @param {string} prefix
891
+ * @param {string | undefined} id
892
+ */
893
+ function applyPrefixId(prefix, id) {
894
+ if (!id) return id;
895
+ return prefix ? `${prefix}.${id}` : id;
896
+ }
897
+
898
+ /**
899
+ * @param {Record<string, WorkflowGraph> | undefined} needs
900
+ * @param {string} prefix
901
+ * @param {Map<string, Map<WorkflowGraph, BuilderNode>>} memo
902
+ */
903
+ function compileNeeds(needs, prefix, memo) {
904
+ if (!needs) return undefined;
905
+ const out = {};
906
+ for (const [key, dep] of Object.entries(needs)) {
907
+ out[key] = compileGraph(dep, prefix, memo);
908
+ }
909
+ return out;
910
+ }
911
+
912
+ /**
913
+ * Walk a graph expression tree and produce a BuilderNode tree at the active prefix.
914
+ * Memoizes per (prefix, graph) so a value referenced as both a child and a needs source
915
+ * compiles to a single handle, while reuse under different scopes produces distinct handles.
916
+ *
917
+ * @param {WorkflowGraph} graph
918
+ * @param {string} [prefix]
919
+ * @param {Map<string, Map<WorkflowGraph, BuilderNode>>} [memo]
920
+ * @returns {BuilderNode}
921
+ */
922
+ function compileGraph(graph, prefix = "", memo = new Map()) {
923
+ let perPrefix = memo.get(prefix);
924
+ if (!perPrefix) {
925
+ perPrefix = new Map();
926
+ memo.set(prefix, perPrefix);
927
+ }
928
+ const cached = perPrefix.get(graph);
929
+ if (cached) return cached;
930
+
931
+ const builder = createBuilder(prefix);
932
+ const expr = /** @type {any} */ (graph.expr);
933
+ let node;
934
+
935
+ switch (expr._tag) {
936
+ case "Step": {
937
+ const compiledOptions = {
938
+ ...expr.options,
939
+ needs: compileNeeds(expr.options.needs, prefix, memo) ?? {},
940
+ };
941
+ node = builder.step(expr.id, compiledOptions);
942
+ break;
943
+ }
944
+ case "Approval": {
945
+ const compiledOptions = {
946
+ ...expr.options,
947
+ needs: compileNeeds(expr.options.needs, prefix, memo) ?? {},
948
+ };
949
+ node = builder.approval(expr.id, compiledOptions);
950
+ break;
951
+ }
952
+ case "Sequence": {
953
+ node = {
954
+ kind: "sequence",
955
+ children: expr.children.map((c) => compileGraph(c, prefix, memo)),
956
+ };
957
+ break;
958
+ }
959
+ case "Parallel": {
960
+ node = {
961
+ kind: "parallel",
962
+ children: expr.children.map((c) => compileGraph(c, prefix, memo)),
963
+ maxConcurrency: expr.maxConcurrency,
964
+ };
965
+ break;
966
+ }
967
+ case "Match": {
968
+ node = {
969
+ kind: "match",
970
+ source: compileGraph(expr.source, prefix, memo),
971
+ when: expr.when,
972
+ then: compileGraph(expr.then, prefix, memo),
973
+ else: expr.else ? compileGraph(expr.else, prefix, memo) : undefined,
974
+ };
975
+ break;
976
+ }
977
+ case "Branch": {
978
+ node = {
979
+ kind: "branch",
980
+ condition: expr.condition,
981
+ needs: compileNeeds(expr.needs, prefix, memo),
982
+ then: compileGraph(expr.then, prefix, memo),
983
+ else: expr.else ? compileGraph(expr.else, prefix, memo) : undefined,
984
+ };
985
+ break;
986
+ }
987
+ case "Loop": {
988
+ node = {
989
+ kind: "loop",
990
+ id: applyPrefixId(prefix, expr.id),
991
+ children: compileGraph(expr.child, prefix, memo),
992
+ until: expr.until,
993
+ maxIterations: expr.maxIterations,
994
+ onMaxReached: expr.onMaxReached,
995
+ };
996
+ break;
997
+ }
998
+ case "Worktree": {
999
+ node = {
1000
+ kind: "worktree",
1001
+ id: applyPrefixId(prefix, expr.id),
1002
+ path: expr.path,
1003
+ branch: expr.branch,
1004
+ skipIf: expr.skipIf,
1005
+ needs: compileNeeds(expr.needs, prefix, memo),
1006
+ children: compileGraph(expr.child, prefix, memo),
1007
+ };
1008
+ break;
1009
+ }
1010
+ case "Scope": {
1011
+ const nextPrefix = prefix ? `${prefix}.${expr.instanceId}` : expr.instanceId;
1012
+ node = compileGraph(expr.child, nextPrefix, memo);
1013
+ break;
1014
+ }
1015
+ default:
1016
+ throw new SmithersError("UNKNOWN_GRAPH_EXPR", `Unknown graph expression _tag: "${expr._tag}"`);
1017
+ }
1018
+
1019
+ perPrefix.set(graph, node);
1020
+ return node;
1021
+ }
1022
+
792
1023
  /**
793
1024
  * @param {{ name: string; input: AnySchema }} options
794
1025
  */
795
- export function createWorkflow(options) {
1026
+ export function workflow(options) {
1027
+ const factory = makeFactory();
796
1028
  return {
1029
+ ...factory,
797
1030
  /**
798
- * @param {($: BuilderApi) => BuilderNode} buildGraph
799
- * @returns {BuiltSmithersWorkflow}
800
- */
801
- build(buildGraph) {
802
- const root = buildGraph(createBuilder());
1031
+ * Finalize the workflow definition. Compiles the graph expression tree to a
1032
+ * BuilderNode tree, allocates step handles with active prefixes, and returns
1033
+ * a runnable workflow.
1034
+ *
1035
+ * @param {WorkflowGraph} graph
1036
+ */
1037
+ from(graph) {
1038
+ const root = compileGraph(graph);
803
1039
  annotateLoops(root);
804
1040
  const handles = collectHandles(root);
805
1041
  assertUniqueHandleIds(handles);
806
1042
  return {
1043
+ node: root,
807
1044
  /**
808
- * @param {unknown} input
809
- * @param {Omit<Parameters<typeof runWorkflow>[1], "input">} [opts]
810
- */
1045
+ * @param {unknown} input
1046
+ * @param {Omit<Parameters<typeof runWorkflow>[1], "input">} [opts]
1047
+ */
811
1048
  execute(input, opts) {
812
1049
  return Effect.gen(function* () {
813
1050
  const env = yield* Effect.context();
@@ -815,12 +1052,12 @@ export function createWorkflow(options) {
815
1052
  const decodedInput = decodeSchema(options.input, input);
816
1053
  const encodedInput = JSON.parse(JSON.stringify(encodeSchema(options.input, decodedInput) ?? {}));
817
1054
  return yield* Effect.acquireUseRelease(Effect.sync(() => createBuilderDb(sqliteConfig.filename, handles)), (runtime) => Effect.promise(async () => {
818
- const workflow = {
1055
+ const wf = {
819
1056
  db: runtime.db,
820
- build: (ctx) => React.createElement(Workflow, { name: options.name }, renderNode(ctx && root ? root : root, ctx, decodedInput, env)),
1057
+ build: (ctx) => React.createElement(Workflow, { name: options.name }, renderNode(root, ctx, decodedInput, env)),
821
1058
  opts: {},
822
1059
  };
823
- const result = await Effect.runPromise(runWorkflow(workflow, {
1060
+ const result = await Effect.runPromise(runWorkflow(wf, {
824
1061
  ...opts,
825
1062
  input: encodedInput,
826
1063
  }));
@@ -839,39 +1076,28 @@ export function createWorkflow(options) {
839
1076
  },
840
1077
  };
841
1078
  }
1079
+
842
1080
  /**
843
- * @param {{ name: string; params?: Record<string, unknown> }} options
1081
+ * Build a graph fragment whose steps live across workflows. Same constructors as
1082
+ * a workflow handle, minus `from` — fragments are values, not workflows. They compile
1083
+ * when mounted into a real workflow via `G.scope(instanceId, fragment)`.
1084
+ *
1085
+ * @param {AnySchema} _inputSchema
844
1086
  */
845
- export function createComponent(options) {
846
- return {
847
- /**
848
- * @param {($: BuilderApi, params: Record<string, unknown>) => BuilderNode} buildGraph
849
- * @returns {ComponentDefinition}
850
- */
851
- build(buildGraph) {
852
- return {
853
- kind: "component-definition",
854
- name: options.name,
855
- /**
856
- * @param {string} prefix
857
- * @param {Record<string, unknown>} params
858
- */
859
- buildWithPrefix(prefix, params) {
860
- return buildGraph(createBuilder(prefix), params);
861
- },
862
- };
863
- },
864
- };
1087
+ export function fragment(_inputSchema) {
1088
+ return makeFactory();
865
1089
  }
1090
+
866
1091
  /**
867
1092
  * @param {SmithersSqliteOptions} options
868
1093
  */
869
1094
  function sqlite(options) {
870
1095
  return Layer.succeed(SmithersSqlite, options);
871
1096
  }
872
- /** @type {{ sqlite: typeof sqlite; createWorkflow: typeof createWorkflow; createComponent: typeof createComponent }} */
1097
+
1098
+ /** @type {{ sqlite: typeof sqlite; workflow: typeof workflow; fragment: typeof fragment }} */
873
1099
  export const Smithers = {
874
1100
  sqlite,
875
- createWorkflow,
876
- createComponent,
1101
+ workflow,
1102
+ fragment,
877
1103
  };
package/src/index.d.ts CHANGED
@@ -1259,24 +1259,56 @@ type BuilderApi = {
1259
1259
  type BuiltSmithersWorkflow = {
1260
1260
  execute: (input: unknown, opts?: Omit<Parameters<typeof runWorkflow>[1], "input">) => Effect.Effect<unknown, unknown, unknown>;
1261
1261
  };
1262
- type WorkflowDefinitionBuilder = {
1263
- build: (buildGraph: ($: BuilderApi) => BuilderNode$1) => BuiltSmithersWorkflow;
1264
- };
1265
- type ComponentDefinitionBuilder = {
1266
- build: (buildGraph: ($: BuilderApi, params?: Record<string, unknown>) => BuilderNode$1) => ComponentDefinition;
1267
- };
1268
- declare function createWorkflow(options: {
1262
+ type WorkflowGraph<I = unknown, A = unknown> = {
1263
+ readonly _tag: "WorkflowGraph";
1264
+ readonly expr: unknown;
1265
+ pipe<B = A>(...fns: Array<(g: WorkflowGraph<I, any>) => WorkflowGraph<I, any>>): WorkflowGraph<I, B>;
1266
+ };
1267
+ type GraphFactory = {
1268
+ step: (id: string, options: StepOptions$1) => WorkflowGraph;
1269
+ approval: (id: string, options: ApprovalOptions$1) => WorkflowGraph;
1270
+ sequence: (...children: WorkflowGraph[]) => WorkflowGraph;
1271
+ parallel: (...nodesOrOptions: Array<WorkflowGraph | { maxConcurrency?: number }>) => WorkflowGraph;
1272
+ match: (source: WorkflowGraph, options: {
1273
+ when: (value: unknown) => boolean;
1274
+ then: WorkflowGraph;
1275
+ else?: WorkflowGraph;
1276
+ }) => WorkflowGraph;
1277
+ branch: (options: {
1278
+ condition: (ctx: Record<string, unknown>) => boolean;
1279
+ needs?: Record<string, WorkflowGraph>;
1280
+ then: WorkflowGraph;
1281
+ else?: WorkflowGraph;
1282
+ }) => WorkflowGraph;
1283
+ loop: (options: {
1284
+ id?: string;
1285
+ children: WorkflowGraph;
1286
+ until: (outputs: Record<string, unknown>) => boolean;
1287
+ maxIterations?: number;
1288
+ onMaxReached?: "fail" | "return-last";
1289
+ }) => WorkflowGraph;
1290
+ worktree: (options: {
1291
+ id?: string;
1292
+ path: string;
1293
+ branch?: string;
1294
+ skipIf?: (ctx: Record<string, unknown>) => boolean;
1295
+ needs?: Record<string, WorkflowGraph>;
1296
+ children: WorkflowGraph;
1297
+ }) => WorkflowGraph;
1298
+ scope: (instanceId: string, child: WorkflowGraph) => WorkflowGraph;
1299
+ };
1300
+ type WorkflowHandle = GraphFactory & {
1301
+ from(graph: WorkflowGraph): BuiltSmithersWorkflow & { node: BuilderNode$1 };
1302
+ };
1303
+ declare function workflow(options: {
1269
1304
  name: string;
1270
1305
  input: AnySchema$1;
1271
- }): WorkflowDefinitionBuilder;
1272
- declare function createComponent(options: {
1273
- name: string;
1274
- params?: Record<string, unknown>;
1275
- }): ComponentDefinitionBuilder;
1306
+ }): WorkflowHandle;
1307
+ declare function fragment(_inputSchema: AnySchema$1): GraphFactory;
1276
1308
  declare const Smithers: {
1277
1309
  sqlite: typeof sqlite;
1278
- createWorkflow: typeof createWorkflow;
1279
- createComponent: typeof createComponent;
1310
+ workflow: typeof workflow;
1311
+ fragment: typeof fragment;
1280
1312
  };
1281
1313
  type AnySchema = effect.Schema.Schema<unknown, unknown, never>;
1282
1314
  type ApprovalOptions = {
@@ -1289,10 +1321,7 @@ type ApprovalOptions = {
1289
1321
  };
1290
1322
  type BuiltSmithersWorkflow$1 = BuiltSmithersWorkflow;
1291
1323
  type BuilderApi$1 = BuilderApi;
1292
- type ComponentDefinition$1 = ComponentDefinition;
1293
- type ComponentDefinitionBuilder$1 = ComponentDefinitionBuilder;
1294
1324
  type StepOptions$1 = StepOptions;
1295
- type WorkflowDefinitionBuilder$1 = WorkflowDefinitionBuilder;
1296
1325
  type BuilderNode = BuilderNode$1;
1297
1326
  type BuilderStepContext = Record<string, unknown> & {
1298
1327
  input: unknown;
@@ -1653,4 +1682,4 @@ type SmithersWorkflow = any;
1653
1682
 
1654
1683
  type ChildWorkflowDefinition = ChildWorkflowDefinition$1;
1655
1684
 
1656
- export { type AlertHumanRequestOptions, AlertRuntime, type AlertRuntimeServices, type AnySchema, type ApprovalOptions, type ApprovalPayload, ApprovalPayloadSchema, type ApprovalResult, ApprovalResultSchema, type BridgeManagedTaskKind, type BuilderApi$1 as BuilderApi, type BuilderNode, type BuilderStepContext, type BuilderStepHandle, type BuiltSmithersWorkflow$1 as BuiltSmithersWorkflow, type CancelPayload, CancelPayloadSchema, type CancelResult, CancelResultSchema, type ChildWorkflowDefinition, type ChildWorkflowExecuteOptions, CodeplaneSandboxExecutorLive, type ComponentDefinition$1 as ComponentDefinition, type ComponentDefinitionBuilder$1 as ComponentDefinitionBuilder, type ComputeTaskBridgeToolConfig, type ContinuationRequest, type CorrelatedSmithersEvent, type CorrelationContext, type DiffBundle, DockerSandboxExecutorLive, EventBus, type ExecuteTaskActivityOptions, type FilePatch, type GetRunPayload, GetRunPayloadSchema, type GetRunResult, GetRunResultSchema, HUMAN_REQUEST_KINDS, HUMAN_REQUEST_STATUSES, type HijackState, type HotReloadEvent, HotWorkflowController, type HumanRequestKind, type HumanRequestSchemaValidation, type HumanRequestStatus, type JsonSchema, type LegacyExecuteTaskFn, type ListRunsPayload, ListRunsPayloadSchema, type OverlayOptions, type PlanNode, type RalphMeta, type RalphState, type RalphStateMap, type ReadonlyTaskStateMap, RetriableTaskFailure, type RetryPolicy, type RetryWaitMap, type RunResult$2 as RunResult, RunStatusSchema, type RunSummary, RunSummarySchema, type SQLiteTable, SandboxHttpRunner, type ScheduleResult, type ScheduleSnapshot, type SignalPayload, SignalPayloadSchema, type SignalResult, SignalResultSchema, type SignalRunOptions, Smithers, type SmithersAlertPolicy, type SmithersEvent, SmithersRpcGroup, type SmithersSqliteOptions, SqlMessageStorage, type StaticTaskBridgeToolConfig, type StepOptions$1 as StepOptions, type TaskActivityContext, type TaskActivityRetryOptions, type TaskBridgeToolConfig, type TaskRecord, TaskResult, type TaskState, type TaskStateMap, TaskWorkerEntity, WatchTree, type WatchTreeOptions, WorkerDispatchKind, WorkerTask$1 as WorkerTask, WorkerTaskKind, type WorkflowDefinitionBuilder$1 as WorkflowDefinitionBuilder, type WorkflowPatchDecisionRecord, type WorkflowPatchDecisions, type WorkflowVersioningRuntime, type WorkflowVersioningRuntimeOptions, type XmlNode, type _TaskActivityContext, applyDiffBundle, approve, approveNode, awaitApprovalDurableDeferred, awaitWaitForEventDurableDeferred, bridgeApprovalResolve, bridgeSignalResolve, bridgeWaitForEventResolve, buildHumanRequestId, buildOverlay, buildPlanTree, canExecuteBridgeManagedComputeTask, canExecuteBridgeManagedStaticTask, cancel, cancelPendingTimersBridge, cleanupGenerations, computeDiffBundle, computeDiffBundleBetweenRefs, createComponent, createSchedulerWakeQueue, createWorkflow, createWorkflowVersioningRuntime, denyNode, dispatchWorkerTask, ensureSqlMessageStorage, ensureSqlMessageStorageEffect, executeChildWorkflow, executeComputeTaskBridge, executeStaticTaskBridge, executeTaskActivity, executeTaskBridge, executeTaskBridgeEffect, getDefinedToolMetadata, getHumanTaskPrompt, getRun, getSqlMessageStorage, getWorkflowMakeBridgeRuntime, getWorkflowPatchDecisions, getWorkflowVersioningRuntime, isBridgeManagedTimerTask, isBridgeManagedWaitForEventTask, isHumanRequestPastTimeout, isHumanTaskMeta, isPidAlive, isRunHeartbeatFresh, isTaskResultFailure, jsonSchemaToZod, listRuns, makeAbortError, makeApprovalDurableDeferred, makeDurableDeferredBridgeExecutionId, makeTaskActivity, makeTaskBridgeKey, makeWaitForEventDurableDeferred, makeWorkerTask, parseAttemptMetaJson, parseRuntimeOwnerPid, renderFrame, resolveDeferredTaskStateBridge, resolveOverlayEntry, resolveSchema, runWorkflow, runWorkflowWithMakeBridge, scheduleTasks, signal, signalRun, subscribeTaskWorkerDispatches, usePatched, validateHumanRequestValue, wireAbortSignal, withWorkflowMakeBridgeRuntime, withWorkflowVersioningRuntime };
1685
+ export { type AlertHumanRequestOptions, AlertRuntime, type AlertRuntimeServices, type AnySchema, type ApprovalOptions, type ApprovalPayload, ApprovalPayloadSchema, type ApprovalResult, ApprovalResultSchema, type BridgeManagedTaskKind, type BuilderApi$1 as BuilderApi, type BuilderNode, type BuilderStepContext, type BuilderStepHandle, type BuiltSmithersWorkflow$1 as BuiltSmithersWorkflow, type CancelPayload, CancelPayloadSchema, type CancelResult, CancelResultSchema, type ChildWorkflowDefinition, type ChildWorkflowExecuteOptions, CodeplaneSandboxExecutorLive, type ComputeTaskBridgeToolConfig, type ContinuationRequest, type CorrelatedSmithersEvent, type CorrelationContext, type DiffBundle, DockerSandboxExecutorLive, EventBus, type ExecuteTaskActivityOptions, type FilePatch, type GetRunPayload, GetRunPayloadSchema, type GetRunResult, GetRunResultSchema, type GraphFactory, HUMAN_REQUEST_KINDS, HUMAN_REQUEST_STATUSES, type HijackState, type HotReloadEvent, HotWorkflowController, type HumanRequestKind, type HumanRequestSchemaValidation, type HumanRequestStatus, type JsonSchema, type LegacyExecuteTaskFn, type ListRunsPayload, ListRunsPayloadSchema, type OverlayOptions, type PlanNode, type RalphMeta, type RalphState, type RalphStateMap, type ReadonlyTaskStateMap, RetriableTaskFailure, type RetryPolicy, type RetryWaitMap, type RunResult$2 as RunResult, RunStatusSchema, type RunSummary, RunSummarySchema, type SQLiteTable, SandboxHttpRunner, type ScheduleResult, type ScheduleSnapshot, type SignalPayload, SignalPayloadSchema, type SignalResult, SignalResultSchema, type SignalRunOptions, Smithers, type SmithersAlertPolicy, type SmithersEvent, SmithersRpcGroup, type SmithersSqliteOptions, SqlMessageStorage, type StaticTaskBridgeToolConfig, type StepOptions$1 as StepOptions, type TaskActivityContext, type TaskActivityRetryOptions, type TaskBridgeToolConfig, type TaskRecord, TaskResult, type TaskState, type TaskStateMap, TaskWorkerEntity, WatchTree, type WatchTreeOptions, WorkerDispatchKind, WorkerTask$1 as WorkerTask, WorkerTaskKind, type WorkflowGraph, type WorkflowHandle, type WorkflowPatchDecisionRecord, type WorkflowPatchDecisions, type WorkflowVersioningRuntime, type WorkflowVersioningRuntimeOptions, type XmlNode, type _TaskActivityContext, applyDiffBundle, approve, approveNode, awaitApprovalDurableDeferred, awaitWaitForEventDurableDeferred, bridgeApprovalResolve, bridgeSignalResolve, bridgeWaitForEventResolve, buildHumanRequestId, buildOverlay, buildPlanTree, canExecuteBridgeManagedComputeTask, canExecuteBridgeManagedStaticTask, cancel, cancelPendingTimersBridge, cleanupGenerations, computeDiffBundle, computeDiffBundleBetweenRefs, createSchedulerWakeQueue, createWorkflowVersioningRuntime, denyNode, dispatchWorkerTask, ensureSqlMessageStorage, ensureSqlMessageStorageEffect, executeChildWorkflow, executeComputeTaskBridge, executeStaticTaskBridge, executeTaskActivity, executeTaskBridge, executeTaskBridgeEffect, fragment, getDefinedToolMetadata, getHumanTaskPrompt, getRun, getSqlMessageStorage, getWorkflowMakeBridgeRuntime, getWorkflowPatchDecisions, getWorkflowVersioningRuntime, isBridgeManagedTimerTask, isBridgeManagedWaitForEventTask, isHumanRequestPastTimeout, isHumanTaskMeta, isPidAlive, isRunHeartbeatFresh, isTaskResultFailure, jsonSchemaToZod, listRuns, makeAbortError, makeApprovalDurableDeferred, makeDurableDeferredBridgeExecutionId, makeTaskActivity, makeTaskBridgeKey, makeWaitForEventDurableDeferred, makeWorkerTask, parseAttemptMetaJson, parseRuntimeOwnerPid, renderFrame, resolveDeferredTaskStateBridge, resolveOverlayEntry, resolveSchema, runWorkflow, runWorkflowWithMakeBridge, scheduleTasks, signal, signalRun, subscribeTaskWorkerDispatches, usePatched, validateHumanRequestValue, wireAbortSignal, withWorkflowMakeBridgeRuntime, withWorkflowVersioningRuntime, workflow };