@swirls/looms 0.12.2 → 0.12.3
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/CHANGELOG.md +6 -0
- package/dist/agent/effects.d.ts +266 -266
- package/dist/agent/module.d.ts +650 -650
- package/dist/core/module.d.ts +5 -2
- package/dist/core/module.js +3 -0
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @swirls/looms
|
|
2
2
|
|
|
3
|
+
## 0.12.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 04d546e: `onEffect` and `onAdmit` accept an effect definition that requires host services. Wrapping `callLlmEffect` in middleware, as in `onEffect(callLlmEffect, handler)`, was a type error because the definition's service requirements did not match the parameter's default. The functions now infer those requirements from the definition.
|
|
8
|
+
|
|
3
9
|
## 0.12.2
|
|
4
10
|
|
|
5
11
|
### Patch Changes
|
package/dist/agent/effects.d.ts
CHANGED
|
@@ -23,6 +23,252 @@ export declare const callLlmEffect: NoInfer<import("@swirls/looms/core").LocalEf
|
|
|
23
23
|
readonly alreadyCompacted?: boolean | undefined;
|
|
24
24
|
readonly consumedSteerMessageIds?: readonly string[] | undefined;
|
|
25
25
|
}, AgentDefinitionsTag | LlmTag, (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
26
|
+
readonly type: "runtime.child.close.requested";
|
|
27
|
+
readonly payload: {
|
|
28
|
+
readonly policy: "terminate" | "wait";
|
|
29
|
+
};
|
|
30
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
31
|
+
readonly type: "runtime.child.settled";
|
|
32
|
+
readonly payload: {
|
|
33
|
+
readonly runId: string;
|
|
34
|
+
readonly status: "cancelled" | "completed" | "failed";
|
|
35
|
+
readonly output: Schema.Json;
|
|
36
|
+
readonly error: string | null;
|
|
37
|
+
};
|
|
38
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
39
|
+
readonly type: "runtime.effect.ambiguous";
|
|
40
|
+
readonly payload: {
|
|
41
|
+
readonly effectId: string;
|
|
42
|
+
readonly attempt: number;
|
|
43
|
+
readonly error: string;
|
|
44
|
+
};
|
|
45
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
46
|
+
readonly type: "runtime.effect.attempt.started";
|
|
47
|
+
readonly payload: {
|
|
48
|
+
readonly effectId: string;
|
|
49
|
+
readonly attempt: number;
|
|
50
|
+
};
|
|
51
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
52
|
+
readonly type: "runtime.effect.cancel.requested";
|
|
53
|
+
readonly payload: {
|
|
54
|
+
readonly effectId: string;
|
|
55
|
+
readonly attempt: number;
|
|
56
|
+
readonly deadlineAt: number | null;
|
|
57
|
+
};
|
|
58
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
59
|
+
readonly type: "runtime.effect.cancelled";
|
|
60
|
+
readonly payload: {
|
|
61
|
+
readonly effectId: string;
|
|
62
|
+
readonly attempt: number;
|
|
63
|
+
};
|
|
64
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
65
|
+
readonly type: "runtime.effect.completed";
|
|
66
|
+
readonly payload: {
|
|
67
|
+
readonly effectId: string;
|
|
68
|
+
readonly attempt: number;
|
|
69
|
+
};
|
|
70
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
71
|
+
readonly type: "runtime.effect.dispatch.deferred";
|
|
72
|
+
readonly payload: {
|
|
73
|
+
readonly effectId: string;
|
|
74
|
+
readonly attempt: number;
|
|
75
|
+
readonly retryAt: number;
|
|
76
|
+
readonly error: string;
|
|
77
|
+
readonly try: number;
|
|
78
|
+
};
|
|
79
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
80
|
+
readonly type: "runtime.effect.dispatched";
|
|
81
|
+
readonly payload: {
|
|
82
|
+
readonly effectId: string;
|
|
83
|
+
readonly attempt: number;
|
|
84
|
+
readonly deadlineAt: number | null;
|
|
85
|
+
};
|
|
86
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
87
|
+
readonly type: "runtime.effect.failed";
|
|
88
|
+
readonly payload: {
|
|
89
|
+
readonly effectId: string;
|
|
90
|
+
readonly error: string;
|
|
91
|
+
readonly nonRetryable?: boolean | undefined;
|
|
92
|
+
readonly retryAfterMs?: number | undefined;
|
|
93
|
+
};
|
|
94
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
95
|
+
readonly type: "runtime.effect.heartbeat";
|
|
96
|
+
readonly payload: {
|
|
97
|
+
readonly effectId: string;
|
|
98
|
+
readonly attempt: number;
|
|
99
|
+
readonly heartbeatAt: number;
|
|
100
|
+
readonly deadlineAt: number | null;
|
|
101
|
+
readonly details?: Schema.Json | undefined;
|
|
102
|
+
};
|
|
103
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
104
|
+
readonly type: "runtime.effect.queued";
|
|
105
|
+
readonly payload: {
|
|
106
|
+
readonly effectId: string;
|
|
107
|
+
readonly attempt: number;
|
|
108
|
+
readonly deadlineAt: number | null;
|
|
109
|
+
};
|
|
110
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
111
|
+
readonly type: "runtime.effect.retry.scheduled";
|
|
112
|
+
readonly payload: {
|
|
113
|
+
readonly effectId: string;
|
|
114
|
+
readonly attempt: number;
|
|
115
|
+
readonly nextAttemptAt: number;
|
|
116
|
+
readonly error: string;
|
|
117
|
+
};
|
|
118
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
119
|
+
readonly type: "runtime.effect.timed_out";
|
|
120
|
+
readonly payload: {
|
|
121
|
+
readonly effectId: string;
|
|
122
|
+
readonly attempt: number;
|
|
123
|
+
readonly timeout: string;
|
|
124
|
+
};
|
|
125
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
126
|
+
readonly type: "runtime.effect.worker.started";
|
|
127
|
+
readonly payload: {
|
|
128
|
+
readonly effectId: string;
|
|
129
|
+
readonly attempt: number;
|
|
130
|
+
readonly deadlineAt: number | null;
|
|
131
|
+
};
|
|
132
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
133
|
+
readonly type: "runtime.fork.elided";
|
|
134
|
+
readonly payload: {
|
|
135
|
+
readonly type: string;
|
|
136
|
+
};
|
|
137
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
138
|
+
readonly type: "runtime.run.cancelled";
|
|
139
|
+
readonly payload: {
|
|
140
|
+
readonly reason?: string | undefined;
|
|
141
|
+
};
|
|
142
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
143
|
+
readonly type: "runtime.run.completed";
|
|
144
|
+
readonly payload: {
|
|
145
|
+
readonly output: Schema.Json;
|
|
146
|
+
readonly error: string | null;
|
|
147
|
+
};
|
|
148
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
149
|
+
readonly type: "runtime.run.forked";
|
|
150
|
+
readonly payload: {
|
|
151
|
+
readonly sourceRunId: string;
|
|
152
|
+
readonly sourceSeq: number;
|
|
153
|
+
};
|
|
154
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
155
|
+
readonly type: "runtime.run.launched";
|
|
156
|
+
readonly payload: {
|
|
157
|
+
readonly runId: string;
|
|
158
|
+
readonly kind: string;
|
|
159
|
+
readonly definitionName: string;
|
|
160
|
+
readonly definitionVersion: string;
|
|
161
|
+
readonly effectId: string;
|
|
162
|
+
readonly close: "terminate" | "wait";
|
|
163
|
+
};
|
|
164
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
165
|
+
readonly type: "runtime.run.started";
|
|
166
|
+
readonly payload: {
|
|
167
|
+
readonly rootThreadId?: string | undefined;
|
|
168
|
+
readonly kind: string;
|
|
169
|
+
readonly definitionName: string;
|
|
170
|
+
readonly definitionVersion: string;
|
|
171
|
+
readonly input: Schema.Json;
|
|
172
|
+
readonly requestedThreadId?: string | null | undefined;
|
|
173
|
+
readonly launchedBy?: {
|
|
174
|
+
readonly runId: string;
|
|
175
|
+
readonly threadId: string;
|
|
176
|
+
readonly effectId: string;
|
|
177
|
+
readonly causationId: string;
|
|
178
|
+
readonly causationSeq: number;
|
|
179
|
+
} | undefined;
|
|
180
|
+
readonly attributes?: {
|
|
181
|
+
readonly [x: string]: string;
|
|
182
|
+
} | undefined;
|
|
183
|
+
readonly trace?: {
|
|
184
|
+
readonly traceparent: string;
|
|
185
|
+
readonly tracestate?: string | undefined;
|
|
186
|
+
} | undefined;
|
|
187
|
+
};
|
|
188
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
189
|
+
readonly type: "runtime.signal.received";
|
|
190
|
+
readonly payload: {
|
|
191
|
+
readonly signalType: string;
|
|
192
|
+
};
|
|
193
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
194
|
+
readonly type: "runtime.snapshot.taken";
|
|
195
|
+
readonly payload: {
|
|
196
|
+
readonly seq: number;
|
|
197
|
+
readonly stateHash: string;
|
|
198
|
+
readonly state?: Schema.Json | undefined;
|
|
199
|
+
};
|
|
200
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
201
|
+
readonly type: "runtime.thread.cancel.requested";
|
|
202
|
+
readonly payload: {
|
|
203
|
+
readonly threadId: string;
|
|
204
|
+
};
|
|
205
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
206
|
+
readonly type: "runtime.thread.cancelled";
|
|
207
|
+
readonly payload: {
|
|
208
|
+
readonly threadId: string;
|
|
209
|
+
readonly reason?: string | undefined;
|
|
210
|
+
readonly resumeSeq?: number | undefined;
|
|
211
|
+
};
|
|
212
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
213
|
+
readonly type: "runtime.thread.completed";
|
|
214
|
+
readonly payload: {
|
|
215
|
+
readonly threadId: string;
|
|
216
|
+
readonly output: Schema.Json;
|
|
217
|
+
};
|
|
218
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
219
|
+
readonly type: "runtime.thread.failed";
|
|
220
|
+
readonly payload: {
|
|
221
|
+
readonly threadId: string;
|
|
222
|
+
readonly error: string;
|
|
223
|
+
};
|
|
224
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
225
|
+
readonly type: "runtime.thread.started";
|
|
226
|
+
readonly payload: {
|
|
227
|
+
readonly threadId: string;
|
|
228
|
+
readonly kind: string;
|
|
229
|
+
readonly definitionName: string;
|
|
230
|
+
readonly definitionVersion: string;
|
|
231
|
+
readonly input: Schema.Json;
|
|
232
|
+
readonly parentThreadId: string | null;
|
|
233
|
+
};
|
|
234
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
235
|
+
readonly type: "runtime.timer.fired";
|
|
236
|
+
readonly payload: {
|
|
237
|
+
readonly timerId: string;
|
|
238
|
+
readonly waitId: string;
|
|
239
|
+
};
|
|
240
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
241
|
+
readonly type: "runtime.timer.set";
|
|
242
|
+
readonly payload: {
|
|
243
|
+
readonly timerId: string;
|
|
244
|
+
readonly waitId: string;
|
|
245
|
+
readonly wakeAt: number;
|
|
246
|
+
};
|
|
247
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
248
|
+
readonly type: "runtime.wait.registered";
|
|
249
|
+
readonly payload: {
|
|
250
|
+
readonly waitId: string;
|
|
251
|
+
readonly threadId?: string | undefined;
|
|
252
|
+
readonly on: {
|
|
253
|
+
readonly type: string | readonly string[];
|
|
254
|
+
readonly match?: Schema.Json | undefined;
|
|
255
|
+
} | {
|
|
256
|
+
readonly timerAt: number;
|
|
257
|
+
};
|
|
258
|
+
readonly tag?: Schema.Json | undefined;
|
|
259
|
+
};
|
|
260
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
261
|
+
readonly type: "runtime.wait.satisfied";
|
|
262
|
+
readonly payload: {
|
|
263
|
+
readonly waitId: string;
|
|
264
|
+
readonly tag?: Schema.Json | undefined;
|
|
265
|
+
readonly event: {
|
|
266
|
+
readonly id: string;
|
|
267
|
+
readonly type: string;
|
|
268
|
+
readonly payload: Schema.Json;
|
|
269
|
+
};
|
|
270
|
+
};
|
|
271
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
26
272
|
readonly type: "agent.context.compacted";
|
|
27
273
|
readonly payload: {
|
|
28
274
|
readonly turn: number;
|
|
@@ -270,7 +516,19 @@ export declare const callLlmEffect: NoInfer<import("@swirls/looms/core").LocalEf
|
|
|
270
516
|
readonly input: number;
|
|
271
517
|
readonly output: number;
|
|
272
518
|
};
|
|
273
|
-
})
|
|
519
|
+
})>>;
|
|
520
|
+
export declare const executeToolEffect: NoInfer<import("@swirls/looms/core").LocalEffectDefinition<{
|
|
521
|
+
readonly turn: number;
|
|
522
|
+
readonly definitionName?: string | undefined;
|
|
523
|
+
readonly definitionVersion: string;
|
|
524
|
+
readonly toolCall: {
|
|
525
|
+
readonly id: string;
|
|
526
|
+
readonly name: string;
|
|
527
|
+
readonly arguments: Schema.Json;
|
|
528
|
+
};
|
|
529
|
+
readonly input?: Schema.Json | undefined;
|
|
530
|
+
readonly depth?: number | undefined;
|
|
531
|
+
}, AgentDefinitionsTag, (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
274
532
|
readonly type: "runtime.child.close.requested";
|
|
275
533
|
readonly payload: {
|
|
276
534
|
readonly policy: "terminate" | "wait";
|
|
@@ -509,26 +767,14 @@ export declare const callLlmEffect: NoInfer<import("@swirls/looms/core").LocalEf
|
|
|
509
767
|
readonly type: "runtime.wait.satisfied";
|
|
510
768
|
readonly payload: {
|
|
511
769
|
readonly waitId: string;
|
|
512
|
-
readonly tag?: Schema.Json | undefined;
|
|
513
|
-
readonly event: {
|
|
514
|
-
readonly id: string;
|
|
515
|
-
readonly type: string;
|
|
516
|
-
readonly payload: Schema.Json;
|
|
517
|
-
};
|
|
518
|
-
};
|
|
519
|
-
})>>;
|
|
520
|
-
export declare const executeToolEffect: NoInfer<import("@swirls/looms/core").LocalEffectDefinition<{
|
|
521
|
-
readonly turn: number;
|
|
522
|
-
readonly definitionName?: string | undefined;
|
|
523
|
-
readonly definitionVersion: string;
|
|
524
|
-
readonly toolCall: {
|
|
525
|
-
readonly id: string;
|
|
526
|
-
readonly name: string;
|
|
527
|
-
readonly arguments: Schema.Json;
|
|
770
|
+
readonly tag?: Schema.Json | undefined;
|
|
771
|
+
readonly event: {
|
|
772
|
+
readonly id: string;
|
|
773
|
+
readonly type: string;
|
|
774
|
+
readonly payload: Schema.Json;
|
|
775
|
+
};
|
|
528
776
|
};
|
|
529
|
-
|
|
530
|
-
readonly depth?: number | undefined;
|
|
531
|
-
}, AgentDefinitionsTag, (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
777
|
+
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
532
778
|
readonly type: "agent.context.compacted";
|
|
533
779
|
readonly payload: {
|
|
534
780
|
readonly turn: number;
|
|
@@ -776,251 +1022,5 @@ export declare const executeToolEffect: NoInfer<import("@swirls/looms/core").Loc
|
|
|
776
1022
|
readonly input: number;
|
|
777
1023
|
readonly output: number;
|
|
778
1024
|
};
|
|
779
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
780
|
-
readonly type: "runtime.child.close.requested";
|
|
781
|
-
readonly payload: {
|
|
782
|
-
readonly policy: "terminate" | "wait";
|
|
783
|
-
};
|
|
784
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
785
|
-
readonly type: "runtime.child.settled";
|
|
786
|
-
readonly payload: {
|
|
787
|
-
readonly runId: string;
|
|
788
|
-
readonly status: "cancelled" | "completed" | "failed";
|
|
789
|
-
readonly output: Schema.Json;
|
|
790
|
-
readonly error: string | null;
|
|
791
|
-
};
|
|
792
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
793
|
-
readonly type: "runtime.effect.ambiguous";
|
|
794
|
-
readonly payload: {
|
|
795
|
-
readonly effectId: string;
|
|
796
|
-
readonly attempt: number;
|
|
797
|
-
readonly error: string;
|
|
798
|
-
};
|
|
799
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
800
|
-
readonly type: "runtime.effect.attempt.started";
|
|
801
|
-
readonly payload: {
|
|
802
|
-
readonly effectId: string;
|
|
803
|
-
readonly attempt: number;
|
|
804
|
-
};
|
|
805
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
806
|
-
readonly type: "runtime.effect.cancel.requested";
|
|
807
|
-
readonly payload: {
|
|
808
|
-
readonly effectId: string;
|
|
809
|
-
readonly attempt: number;
|
|
810
|
-
readonly deadlineAt: number | null;
|
|
811
|
-
};
|
|
812
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
813
|
-
readonly type: "runtime.effect.cancelled";
|
|
814
|
-
readonly payload: {
|
|
815
|
-
readonly effectId: string;
|
|
816
|
-
readonly attempt: number;
|
|
817
|
-
};
|
|
818
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
819
|
-
readonly type: "runtime.effect.completed";
|
|
820
|
-
readonly payload: {
|
|
821
|
-
readonly effectId: string;
|
|
822
|
-
readonly attempt: number;
|
|
823
|
-
};
|
|
824
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
825
|
-
readonly type: "runtime.effect.dispatch.deferred";
|
|
826
|
-
readonly payload: {
|
|
827
|
-
readonly effectId: string;
|
|
828
|
-
readonly attempt: number;
|
|
829
|
-
readonly retryAt: number;
|
|
830
|
-
readonly error: string;
|
|
831
|
-
readonly try: number;
|
|
832
|
-
};
|
|
833
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
834
|
-
readonly type: "runtime.effect.dispatched";
|
|
835
|
-
readonly payload: {
|
|
836
|
-
readonly effectId: string;
|
|
837
|
-
readonly attempt: number;
|
|
838
|
-
readonly deadlineAt: number | null;
|
|
839
|
-
};
|
|
840
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
841
|
-
readonly type: "runtime.effect.failed";
|
|
842
|
-
readonly payload: {
|
|
843
|
-
readonly effectId: string;
|
|
844
|
-
readonly error: string;
|
|
845
|
-
readonly nonRetryable?: boolean | undefined;
|
|
846
|
-
readonly retryAfterMs?: number | undefined;
|
|
847
|
-
};
|
|
848
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
849
|
-
readonly type: "runtime.effect.heartbeat";
|
|
850
|
-
readonly payload: {
|
|
851
|
-
readonly effectId: string;
|
|
852
|
-
readonly attempt: number;
|
|
853
|
-
readonly heartbeatAt: number;
|
|
854
|
-
readonly deadlineAt: number | null;
|
|
855
|
-
readonly details?: Schema.Json | undefined;
|
|
856
|
-
};
|
|
857
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
858
|
-
readonly type: "runtime.effect.queued";
|
|
859
|
-
readonly payload: {
|
|
860
|
-
readonly effectId: string;
|
|
861
|
-
readonly attempt: number;
|
|
862
|
-
readonly deadlineAt: number | null;
|
|
863
|
-
};
|
|
864
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
865
|
-
readonly type: "runtime.effect.retry.scheduled";
|
|
866
|
-
readonly payload: {
|
|
867
|
-
readonly effectId: string;
|
|
868
|
-
readonly attempt: number;
|
|
869
|
-
readonly nextAttemptAt: number;
|
|
870
|
-
readonly error: string;
|
|
871
|
-
};
|
|
872
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
873
|
-
readonly type: "runtime.effect.timed_out";
|
|
874
|
-
readonly payload: {
|
|
875
|
-
readonly effectId: string;
|
|
876
|
-
readonly attempt: number;
|
|
877
|
-
readonly timeout: string;
|
|
878
|
-
};
|
|
879
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
880
|
-
readonly type: "runtime.effect.worker.started";
|
|
881
|
-
readonly payload: {
|
|
882
|
-
readonly effectId: string;
|
|
883
|
-
readonly attempt: number;
|
|
884
|
-
readonly deadlineAt: number | null;
|
|
885
|
-
};
|
|
886
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
887
|
-
readonly type: "runtime.fork.elided";
|
|
888
|
-
readonly payload: {
|
|
889
|
-
readonly type: string;
|
|
890
|
-
};
|
|
891
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
892
|
-
readonly type: "runtime.run.cancelled";
|
|
893
|
-
readonly payload: {
|
|
894
|
-
readonly reason?: string | undefined;
|
|
895
|
-
};
|
|
896
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
897
|
-
readonly type: "runtime.run.completed";
|
|
898
|
-
readonly payload: {
|
|
899
|
-
readonly output: Schema.Json;
|
|
900
|
-
readonly error: string | null;
|
|
901
|
-
};
|
|
902
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
903
|
-
readonly type: "runtime.run.forked";
|
|
904
|
-
readonly payload: {
|
|
905
|
-
readonly sourceRunId: string;
|
|
906
|
-
readonly sourceSeq: number;
|
|
907
|
-
};
|
|
908
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
909
|
-
readonly type: "runtime.run.launched";
|
|
910
|
-
readonly payload: {
|
|
911
|
-
readonly runId: string;
|
|
912
|
-
readonly kind: string;
|
|
913
|
-
readonly definitionName: string;
|
|
914
|
-
readonly definitionVersion: string;
|
|
915
|
-
readonly effectId: string;
|
|
916
|
-
readonly close: "terminate" | "wait";
|
|
917
|
-
};
|
|
918
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
919
|
-
readonly type: "runtime.run.started";
|
|
920
|
-
readonly payload: {
|
|
921
|
-
readonly rootThreadId?: string | undefined;
|
|
922
|
-
readonly kind: string;
|
|
923
|
-
readonly definitionName: string;
|
|
924
|
-
readonly definitionVersion: string;
|
|
925
|
-
readonly input: Schema.Json;
|
|
926
|
-
readonly requestedThreadId?: string | null | undefined;
|
|
927
|
-
readonly launchedBy?: {
|
|
928
|
-
readonly runId: string;
|
|
929
|
-
readonly threadId: string;
|
|
930
|
-
readonly effectId: string;
|
|
931
|
-
readonly causationId: string;
|
|
932
|
-
readonly causationSeq: number;
|
|
933
|
-
} | undefined;
|
|
934
|
-
readonly attributes?: {
|
|
935
|
-
readonly [x: string]: string;
|
|
936
|
-
} | undefined;
|
|
937
|
-
readonly trace?: {
|
|
938
|
-
readonly traceparent: string;
|
|
939
|
-
readonly tracestate?: string | undefined;
|
|
940
|
-
} | undefined;
|
|
941
|
-
};
|
|
942
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
943
|
-
readonly type: "runtime.signal.received";
|
|
944
|
-
readonly payload: {
|
|
945
|
-
readonly signalType: string;
|
|
946
|
-
};
|
|
947
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
948
|
-
readonly type: "runtime.snapshot.taken";
|
|
949
|
-
readonly payload: {
|
|
950
|
-
readonly seq: number;
|
|
951
|
-
readonly stateHash: string;
|
|
952
|
-
readonly state?: Schema.Json | undefined;
|
|
953
|
-
};
|
|
954
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
955
|
-
readonly type: "runtime.thread.cancel.requested";
|
|
956
|
-
readonly payload: {
|
|
957
|
-
readonly threadId: string;
|
|
958
|
-
};
|
|
959
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
960
|
-
readonly type: "runtime.thread.cancelled";
|
|
961
|
-
readonly payload: {
|
|
962
|
-
readonly threadId: string;
|
|
963
|
-
readonly reason?: string | undefined;
|
|
964
|
-
readonly resumeSeq?: number | undefined;
|
|
965
|
-
};
|
|
966
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
967
|
-
readonly type: "runtime.thread.completed";
|
|
968
|
-
readonly payload: {
|
|
969
|
-
readonly threadId: string;
|
|
970
|
-
readonly output: Schema.Json;
|
|
971
|
-
};
|
|
972
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
973
|
-
readonly type: "runtime.thread.failed";
|
|
974
|
-
readonly payload: {
|
|
975
|
-
readonly threadId: string;
|
|
976
|
-
readonly error: string;
|
|
977
|
-
};
|
|
978
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
979
|
-
readonly type: "runtime.thread.started";
|
|
980
|
-
readonly payload: {
|
|
981
|
-
readonly threadId: string;
|
|
982
|
-
readonly kind: string;
|
|
983
|
-
readonly definitionName: string;
|
|
984
|
-
readonly definitionVersion: string;
|
|
985
|
-
readonly input: Schema.Json;
|
|
986
|
-
readonly parentThreadId: string | null;
|
|
987
|
-
};
|
|
988
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
989
|
-
readonly type: "runtime.timer.fired";
|
|
990
|
-
readonly payload: {
|
|
991
|
-
readonly timerId: string;
|
|
992
|
-
readonly waitId: string;
|
|
993
|
-
};
|
|
994
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
995
|
-
readonly type: "runtime.timer.set";
|
|
996
|
-
readonly payload: {
|
|
997
|
-
readonly timerId: string;
|
|
998
|
-
readonly waitId: string;
|
|
999
|
-
readonly wakeAt: number;
|
|
1000
|
-
};
|
|
1001
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
1002
|
-
readonly type: "runtime.wait.registered";
|
|
1003
|
-
readonly payload: {
|
|
1004
|
-
readonly waitId: string;
|
|
1005
|
-
readonly threadId?: string | undefined;
|
|
1006
|
-
readonly on: {
|
|
1007
|
-
readonly type: string | readonly string[];
|
|
1008
|
-
readonly match?: Schema.Json | undefined;
|
|
1009
|
-
} | {
|
|
1010
|
-
readonly timerAt: number;
|
|
1011
|
-
};
|
|
1012
|
-
readonly tag?: Schema.Json | undefined;
|
|
1013
|
-
};
|
|
1014
|
-
}) | (Omit<import("@swirls/looms/core").EventInput, "payload" | "type"> & {
|
|
1015
|
-
readonly type: "runtime.wait.satisfied";
|
|
1016
|
-
readonly payload: {
|
|
1017
|
-
readonly waitId: string;
|
|
1018
|
-
readonly tag?: Schema.Json | undefined;
|
|
1019
|
-
readonly event: {
|
|
1020
|
-
readonly id: string;
|
|
1021
|
-
readonly type: string;
|
|
1022
|
-
readonly payload: Schema.Json;
|
|
1023
|
-
};
|
|
1024
|
-
};
|
|
1025
1025
|
})>>;
|
|
1026
1026
|
export declare function readToolCall(value: JsonValue): ToolCall | null;
|