@swirls/looms 0.4.0 → 0.5.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/CHANGELOG.md +55 -0
- package/dist/actor/cell.d.ts +21 -2
- package/dist/actor/cell.js +15 -3
- package/dist/actor/host.d.ts +10 -2
- package/dist/actor/host.js +27 -4
- package/dist/actor/index.d.ts +2 -1
- package/dist/actor/index.js +1 -1
- package/dist/actor/routing.d.ts +3 -0
- package/dist/actor/routing.js +13 -2
- package/dist/agent/definitions-store.d.ts +1 -1
- package/dist/agent/definitions-store.js +1 -1
- package/dist/agent/definitions.d.ts +48 -0
- package/dist/agent/definitions.js +44 -0
- package/dist/agent/effects.d.ts +184 -0
- package/dist/agent/effects.js +172 -40
- package/dist/agent/events.d.ts +89 -0
- package/dist/agent/events.js +25 -0
- package/dist/agent/module.d.ts +412 -0
- package/dist/agent/module.js +5 -1
- package/dist/agent/scope.d.ts +88 -0
- package/dist/agent/threads.js +39 -3
- package/dist/agent/types.d.ts +4 -0
- package/dist/approval/effects.d.ts +40 -0
- package/dist/approval/module.d.ts +80 -0
- package/dist/client/client.d.ts +468 -119
- package/dist/client/client.js +214 -21
- package/dist/client/index.d.ts +1 -1
- package/dist/client/sse.d.ts +1 -1
- package/dist/client/sse.js +2 -2
- package/dist/cloudflare/durable-object.d.ts +66 -2
- package/dist/cloudflare/durable-object.js +96 -1
- package/dist/cloudflare/event-store.d.ts +7 -3
- package/dist/cloudflare/event-store.js +16 -3
- package/dist/cloudflare/index.d.ts +7 -1
- package/dist/cloudflare/index.js +7 -1
- package/dist/cloudflare/memory-queue.d.ts +18 -0
- package/dist/cloudflare/memory-queue.js +53 -0
- package/dist/cloudflare/queue-consumer.d.ts +52 -0
- package/dist/cloudflare/queue-consumer.js +102 -0
- package/dist/cloudflare/queue-message.d.ts +31 -0
- package/dist/cloudflare/queue-message.js +33 -0
- package/dist/cloudflare/queue-pull.d.ts +62 -0
- package/dist/cloudflare/queue-pull.js +130 -0
- package/dist/cloudflare/queue-worker.d.ts +39 -0
- package/dist/cloudflare/queue-worker.js +62 -0
- package/dist/cloudflare/r2-blob-store.d.ts +33 -0
- package/dist/cloudflare/r2-blob-store.js +60 -0
- package/dist/cloudflare/router.d.ts +4 -1
- package/dist/cloudflare/router.js +8 -3
- package/dist/cloudflare/websocket.d.ts +27 -0
- package/dist/cloudflare/websocket.js +215 -0
- package/dist/core/blob-offload.d.ts +21 -0
- package/dist/core/blob-offload.js +143 -0
- package/dist/core/blob-store.d.ts +45 -0
- package/dist/core/blob-store.js +164 -0
- package/dist/core/blobs.d.ts +37 -0
- package/dist/core/blobs.js +160 -0
- package/dist/core/definition-resolver.d.ts +40 -0
- package/dist/core/definition-resolver.js +129 -0
- package/dist/core/definition-store.d.ts +6 -0
- package/dist/core/definition-store.js +37 -1
- package/dist/core/effects.d.ts +86 -3
- package/dist/core/effects.js +99 -3
- package/dist/core/envelope.d.ts +9 -0
- package/dist/core/envelope.js +4 -0
- package/dist/core/event-codec.js +3 -0
- package/dist/core/fold.js +83 -1
- package/dist/core/ids.d.ts +2 -0
- package/dist/core/ids.js +4 -0
- package/dist/core/index.d.ts +8 -0
- package/dist/core/index.js +8 -0
- package/dist/core/launcher.d.ts +97 -0
- package/dist/core/launcher.js +67 -0
- package/dist/core/module-scope.d.ts +7 -3
- package/dist/core/module-scope.js +3 -0
- package/dist/core/module.d.ts +10 -0
- package/dist/core/projection.js +4 -0
- package/dist/core/protocol.d.ts +36 -1
- package/dist/core/protocol.js +35 -0
- package/dist/core/published.d.ts +2 -0
- package/dist/core/published.js +4 -1
- package/dist/core/replay.d.ts +96 -0
- package/dist/core/run-context.d.ts +33 -0
- package/dist/core/run-context.js +23 -0
- package/dist/core/sqlite-store.js +57 -5
- package/dist/core/state.d.ts +60 -0
- package/dist/core/state.js +19 -0
- package/dist/core/store.d.ts +6 -0
- package/dist/core/store.js +7 -0
- package/dist/core/subscription.d.ts +97 -0
- package/dist/core/subscription.js +224 -0
- package/dist/core/thread.d.ts +7 -0
- package/dist/core/thread.js +1 -0
- package/dist/core/trace.d.ts +21 -0
- package/dist/core/trace.js +45 -0
- package/dist/core/worker-callback.d.ts +25 -1
- package/dist/debugger/app/assets/{index-CgDzWJg7.css → index-B7GdT1UA.css} +1 -1
- package/dist/debugger/app/assets/index-C31SnCuN.js +22 -0
- package/dist/debugger/app/assets/routes-DPA3O5AF.js +47 -0
- package/dist/debugger/app/index.html +2 -2
- package/dist/debugger/components/event-inspector.d.ts +3 -1
- package/dist/debugger/components/event-inspector.js +25 -4
- package/dist/debugger/components/event-stream.d.ts +4 -1
- package/dist/debugger/components/event-stream.js +2 -2
- package/dist/debugger/components/run-tree.d.ts +5 -2
- package/dist/debugger/components/run-tree.js +10 -4
- package/dist/debugger/context.d.ts +8 -1
- package/dist/debugger/context.js +15 -3
- package/dist/debugger/events/protocol-summarize.js +18 -3
- package/dist/debugger/index.d.ts +1 -1
- package/dist/debugger/index.js +1 -1
- package/dist/debugger/shell/debugger-shell.js +1 -1
- package/dist/debugger/shell/events-pane.js +4 -3
- package/dist/debugger/styles.css +1 -0
- package/dist/evaluator/definitions-store.d.ts +3 -4
- package/dist/evaluator/definitions-store.js +3 -3
- package/dist/evaluator/definitions.d.ts +4 -1
- package/dist/evaluator/definitions.js +5 -2
- package/dist/evaluator/effects.d.ts +74 -33
- package/dist/evaluator/effects.js +6 -2
- package/dist/evaluator/module.d.ts +150 -66
- package/dist/evaluator/module.js +7 -3
- package/dist/evaluator/threads.d.ts +2 -0
- package/dist/evaluator/threads.js +4 -0
- package/dist/projectors/event-log.d.ts +87 -0
- package/dist/projectors/event-log.js +396 -0
- package/dist/projectors/index-model.d.ts +12 -0
- package/dist/projectors/index-model.js +12 -3
- package/dist/projectors/memory.js +7 -0
- package/dist/projectors/postgres.d.ts +1 -0
- package/dist/projectors/postgres.js +32 -15
- package/dist/projectors/schema.d.ts +5 -0
- package/dist/projectors/schema.js +26 -1
- package/dist/projectors/sqlite.js +47 -19
- package/dist/projectors/with-projectors.d.ts +7 -1
- package/dist/projectors/with-projectors.js +13 -3
- package/dist/react/materialize.js +5 -1
- package/dist/react/react.d.ts +10 -2
- package/dist/react/react.js +43 -19
- package/dist/react/store.d.ts +11 -2
- package/dist/react/store.js +104 -12
- package/dist/react/tables.d.ts +4 -1
- package/dist/runtime/cancellation.d.ts +2 -1
- package/dist/runtime/cancellation.js +35 -2
- package/dist/runtime/child-run.d.ts +10 -0
- package/dist/runtime/child-run.js +58 -0
- package/dist/runtime/deadline-transition-planner.js +11 -2
- package/dist/runtime/dispatch-effect.d.ts +2 -2
- package/dist/runtime/dispatch-effect.js +43 -19
- package/dist/runtime/errors.d.ts +14 -1
- package/dist/runtime/errors.js +10 -0
- package/dist/runtime/filesystem-blob-store.d.ts +6 -0
- package/dist/runtime/filesystem-blob-store.js +59 -0
- package/dist/runtime/helpers.d.ts +15 -6
- package/dist/runtime/helpers.js +46 -6
- package/dist/runtime/index.d.ts +4 -2
- package/dist/runtime/index.js +3 -1
- package/dist/runtime/local-effect-executor.d.ts +11 -2
- package/dist/runtime/local-effect-executor.js +80 -4
- package/dist/runtime/looms.d.ts +38 -4
- package/dist/runtime/looms.js +17 -3
- package/dist/runtime/repository.d.ts +5 -4
- package/dist/runtime/repository.js +5 -2
- package/dist/runtime/retry-policy.d.ts +5 -0
- package/dist/runtime/retry-policy.js +10 -2
- package/dist/runtime/run-start.d.ts +1 -1
- package/dist/runtime/run-start.js +10 -0
- package/dist/runtime/runtime.d.ts +2 -2
- package/dist/runtime/runtime.js +191 -68
- package/dist/runtime/server/auth.d.ts +3 -0
- package/dist/runtime/server/fetch-handler.d.ts +2 -2
- package/dist/runtime/server/fetch-handler.js +35 -4
- package/dist/runtime/server/grant.d.ts +49 -0
- package/dist/runtime/server/grant.js +177 -0
- package/dist/runtime/server/routes/effects.js +47 -5
- package/dist/runtime/server/routes/runs.js +6 -1
- package/dist/runtime/server/run-route.d.ts +18 -0
- package/dist/runtime/server/run-route.js +26 -0
- package/dist/runtime/server.d.ts +3 -1
- package/dist/runtime/server.js +3 -1
- package/dist/runtime/sse.js +26 -4
- package/dist/runtime/subscription.d.ts +8 -0
- package/dist/runtime/subscription.js +23 -0
- package/dist/runtime/types.d.ts +87 -8
- package/dist/runtime/wake-engine.d.ts +4 -2
- package/dist/runtime/wake-engine.js +57 -6
- package/dist/runtime/worker-callbacks.d.ts +12 -2
- package/dist/runtime/worker-callbacks.js +102 -72
- package/dist/runtime/worker-effect-dispatch.d.ts +14 -5
- package/dist/runtime/worker-effect-dispatch.js +84 -18
- package/dist/schedule/debugger/index.d.ts +4 -0
- package/dist/schedule/debugger/index.js +11 -0
- package/dist/schedule/debugger/schedule-view.d.ts +3 -0
- package/dist/schedule/debugger/schedule-view.js +68 -0
- package/dist/schedule/debugger/summarize.d.ts +2 -0
- package/dist/schedule/debugger/summarize.js +43 -0
- package/dist/schedule/definitions-store.d.ts +10 -0
- package/dist/schedule/definitions-store.js +8 -0
- package/dist/schedule/definitions.d.ts +57 -0
- package/dist/schedule/definitions.js +30 -0
- package/dist/schedule/effects.d.ts +756 -0
- package/dist/schedule/effects.js +244 -0
- package/dist/schedule/ensure.d.ts +55 -0
- package/dist/schedule/ensure.js +109 -0
- package/dist/schedule/events.d.ts +116 -0
- package/dist/schedule/events.js +49 -0
- package/dist/schedule/index.d.ts +11 -0
- package/dist/schedule/index.js +11 -0
- package/dist/schedule/module.d.ts +1474 -0
- package/dist/schedule/module.js +22 -0
- package/dist/schedule/projections.d.ts +55 -0
- package/dist/schedule/projections.js +88 -0
- package/dist/schedule/scope.d.ts +121 -0
- package/dist/schedule/scope.js +7 -0
- package/dist/schedule/signals.d.ts +25 -0
- package/dist/schedule/signals.js +33 -0
- package/dist/schedule/specs.d.ts +59 -0
- package/dist/schedule/specs.js +231 -0
- package/dist/schedule/threads.d.ts +25 -0
- package/dist/schedule/threads.js +259 -0
- package/dist/testing/corpus-module.d.ts +34 -0
- package/dist/testing/corpus-module.js +87 -0
- package/dist/testing/index.d.ts +2 -0
- package/dist/testing/index.js +5 -6
- package/dist/testing/replay-corpus.d.ts +22 -0
- package/dist/testing/replay-corpus.js +50 -0
- package/dist/workflow/definitions-store.d.ts +1 -1
- package/dist/workflow/definitions-store.js +1 -1
- package/dist/workflow/definitions.d.ts +14 -0
- package/dist/workflow/effects.d.ts +122 -0
- package/dist/workflow/effects.js +16 -6
- package/dist/workflow/events.d.ts +42 -0
- package/dist/workflow/events.js +4 -0
- package/dist/workflow/module.d.ts +345 -32
- package/dist/workflow/module.js +7 -3
- package/dist/workflow/scope.d.ts +42 -0
- package/dist/workflow/threads.d.ts +72 -0
- package/dist/workflow/threads.js +106 -38
- package/package.json +10 -1
- package/dist/debugger/app/assets/index-D--9esm9.js +0 -22
- package/dist/debugger/app/assets/routes-Dakrdusf.js +0 -47
package/dist/agent/module.d.ts
CHANGED
|
@@ -105,6 +105,7 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
105
105
|
readonly definitionVersion: import("effect/Schema").withDecodingDefaultKey<import("effect/Schema").String, never>;
|
|
106
106
|
readonly toolCallId: import("effect/Schema").String;
|
|
107
107
|
readonly input: import("effect/Schema").Codec<import("effect/Schema").Json, import("effect/Schema").Json, never, never>;
|
|
108
|
+
readonly depth: import("effect/Schema").optional<import("effect/Schema").Finite>;
|
|
108
109
|
}>;
|
|
109
110
|
'effects.requested': import("effect/Schema").Struct<{
|
|
110
111
|
readonly toolCallId: import("effect/Schema").String;
|
|
@@ -143,6 +144,9 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
143
144
|
readonly actorId: import("effect/Schema").optional<import("effect/Schema").String>;
|
|
144
145
|
}>, import("effect/Schema").Struct<{
|
|
145
146
|
readonly type: import("effect/Schema").Literal<"system">;
|
|
147
|
+
}>, import("effect/Schema").Struct<{
|
|
148
|
+
readonly type: import("effect/Schema").Literal<"run">;
|
|
149
|
+
readonly runId: import("effect/Schema").String;
|
|
146
150
|
}>]>>;
|
|
147
151
|
readonly ephemeral: import("effect/Schema").optional<import("effect/Schema").Boolean>;
|
|
148
152
|
readonly id: import("effect/Schema").optional<import("effect/Schema").String>;
|
|
@@ -160,16 +164,56 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
160
164
|
readonly type: import("effect/Schema").Literal<"runtime.cancel">;
|
|
161
165
|
readonly threadId: import("effect/Schema").String;
|
|
162
166
|
readonly tag: import("effect/Schema").optional<import("effect/Schema").String>;
|
|
167
|
+
}>, import("effect/Schema").Struct<{
|
|
168
|
+
readonly type: import("effect/Schema").Literal<"runtime.launch">;
|
|
169
|
+
readonly runId: import("effect/Schema").String;
|
|
170
|
+
readonly kind: import("effect/Schema").String;
|
|
171
|
+
readonly definitionName: import("effect/Schema").String;
|
|
172
|
+
readonly definitionVersion: import("effect/Schema").withDecodingDefaultKey<import("effect/Schema").String, never>;
|
|
173
|
+
readonly input: import("effect/Schema").Codec<import("effect/Schema").Json, import("effect/Schema").Json, never, never>;
|
|
174
|
+
readonly close: import("effect/Schema").withDecodingDefaultKey<import("effect/Schema").Union<readonly [import("effect/Schema").Literal<"terminate">, import("effect/Schema").Literal<"wait">]>, never>;
|
|
175
|
+
readonly tag: import("effect/Schema").optional<import("effect/Schema").String>;
|
|
176
|
+
}>, import("effect/Schema").Struct<{
|
|
177
|
+
readonly type: import("effect/Schema").Literal<"runtime.cancelRun">;
|
|
178
|
+
readonly runId: import("effect/Schema").String;
|
|
179
|
+
readonly tag: import("effect/Schema").optional<import("effect/Schema").String>;
|
|
163
180
|
}>, import("effect/Schema").Struct<{
|
|
164
181
|
readonly type: import("effect/Schema").String;
|
|
165
182
|
readonly input: import("effect/Schema").Codec<import("effect/Schema").Json, import("effect/Schema").Json, never, never>;
|
|
166
183
|
readonly tag: import("effect/Schema").optional<import("effect/Schema").String>;
|
|
184
|
+
readonly at: import("effect/Schema").optional<import("effect/Schema").Finite>;
|
|
167
185
|
}>]>>;
|
|
168
186
|
readonly waitOn: import("effect/Schema").optional<import("effect/Schema").Struct<{
|
|
169
187
|
readonly type: import("effect/Schema").Union<readonly [import("effect/Schema").String, import("effect/Schema").$Array<import("effect/Schema").String>]>;
|
|
170
188
|
readonly match: import("effect/Schema").optional<import("effect/Schema").Codec<import("effect/Schema").Json, import("effect/Schema").Json, never, never>>;
|
|
171
189
|
}>>;
|
|
172
190
|
}>;
|
|
191
|
+
lineage: import("effect/Schema").Struct<{
|
|
192
|
+
readonly depth: import("effect/Schema").Finite;
|
|
193
|
+
}>;
|
|
194
|
+
'context.compacted': import("effect/Schema").Struct<{
|
|
195
|
+
readonly turn: import("effect/Schema").Finite;
|
|
196
|
+
readonly originalCount: import("effect/Schema").Finite;
|
|
197
|
+
readonly compactedCount: import("effect/Schema").Finite;
|
|
198
|
+
readonly summary: import("effect/Schema").optional<import("effect/Schema").String>;
|
|
199
|
+
readonly reason: import("effect/Schema").optional<import("effect/Schema").Union<readonly [import("effect/Schema").Literal<"overflow">, import("effect/Schema").Literal<"manual">, import("effect/Schema").Literal<"threshold">]>>;
|
|
200
|
+
readonly messages: import("effect/Schema").optional<import("effect/Schema").$Array<import("effect/Schema").Struct<{
|
|
201
|
+
readonly role: import("effect/Schema").Union<readonly [import("effect/Schema").Literal<"system">, import("effect/Schema").Literal<"user">, import("effect/Schema").Literal<"assistant">, import("effect/Schema").Literal<"tool">]>;
|
|
202
|
+
readonly content: import("effect/Schema").String;
|
|
203
|
+
readonly toolCallId: import("effect/Schema").optional<import("effect/Schema").String>;
|
|
204
|
+
readonly name: import("effect/Schema").optional<import("effect/Schema").String>;
|
|
205
|
+
readonly toolCalls: import("effect/Schema").optional<import("effect/Schema").mutable<import("effect/Schema").$Array<import("effect/Schema").Struct<{
|
|
206
|
+
readonly id: import("effect/Schema").String;
|
|
207
|
+
readonly name: import("effect/Schema").String;
|
|
208
|
+
readonly arguments: import("effect/Schema").Codec<import("effect/Schema").Json, import("effect/Schema").Json, never, never>;
|
|
209
|
+
}>>>>;
|
|
210
|
+
}>>>;
|
|
211
|
+
}>;
|
|
212
|
+
'turn.usage': import("effect/Schema").Struct<{
|
|
213
|
+
readonly turn: import("effect/Schema").Finite;
|
|
214
|
+
readonly input: import("effect/Schema").Finite;
|
|
215
|
+
readonly output: import("effect/Schema").Finite;
|
|
216
|
+
}>;
|
|
173
217
|
}>, {
|
|
174
218
|
callLLM: import("@swirls/looms/core").EffectDefinition<{
|
|
175
219
|
readonly turn: number;
|
|
@@ -187,8 +231,30 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
187
231
|
}[] | undefined;
|
|
188
232
|
}[] | undefined;
|
|
189
233
|
readonly input?: import("effect/Schema").Json | undefined;
|
|
234
|
+
readonly structuredOutput?: import("effect/Schema").Json | undefined;
|
|
235
|
+
readonly alreadyCompacted?: boolean | undefined;
|
|
190
236
|
readonly consumedSteerMessageIds?: readonly string[] | undefined;
|
|
191
237
|
}, import("./definitions-store").AgentDefinitionsTag | LlmTag, (Omit<EventInput, "payload" | "type"> & {
|
|
238
|
+
readonly type: "agent.context.compacted";
|
|
239
|
+
readonly payload: {
|
|
240
|
+
readonly turn: number;
|
|
241
|
+
readonly originalCount: number;
|
|
242
|
+
readonly compactedCount: number;
|
|
243
|
+
readonly summary?: string | undefined;
|
|
244
|
+
readonly reason?: "manual" | "overflow" | "threshold" | undefined;
|
|
245
|
+
readonly messages?: readonly {
|
|
246
|
+
readonly role: "assistant" | "system" | "tool" | "user";
|
|
247
|
+
readonly content: string;
|
|
248
|
+
readonly toolCallId?: string | undefined;
|
|
249
|
+
readonly name?: string | undefined;
|
|
250
|
+
readonly toolCalls?: {
|
|
251
|
+
readonly id: string;
|
|
252
|
+
readonly name: string;
|
|
253
|
+
readonly arguments: import("effect/Schema").Json;
|
|
254
|
+
}[] | undefined;
|
|
255
|
+
}[] | undefined;
|
|
256
|
+
};
|
|
257
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
192
258
|
readonly type: "agent.effects.requested";
|
|
193
259
|
readonly payload: {
|
|
194
260
|
readonly toolCallId: string;
|
|
@@ -227,6 +293,9 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
227
293
|
readonly actorId?: string | undefined;
|
|
228
294
|
} | {
|
|
229
295
|
readonly type: "system";
|
|
296
|
+
} | {
|
|
297
|
+
readonly type: "run";
|
|
298
|
+
readonly runId: string;
|
|
230
299
|
} | undefined;
|
|
231
300
|
readonly ephemeral?: boolean | undefined;
|
|
232
301
|
readonly id?: string | undefined;
|
|
@@ -244,16 +313,35 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
244
313
|
readonly type: "runtime.cancel";
|
|
245
314
|
readonly threadId: string;
|
|
246
315
|
readonly tag?: string | undefined;
|
|
316
|
+
} | {
|
|
317
|
+
readonly type: "runtime.launch";
|
|
318
|
+
readonly runId: string;
|
|
319
|
+
readonly kind: string;
|
|
320
|
+
readonly definitionName: string;
|
|
321
|
+
readonly definitionVersion: string;
|
|
322
|
+
readonly input: import("effect/Schema").Json;
|
|
323
|
+
readonly close: "terminate" | "wait";
|
|
324
|
+
readonly tag?: string | undefined;
|
|
325
|
+
} | {
|
|
326
|
+
readonly type: "runtime.cancelRun";
|
|
327
|
+
readonly runId: string;
|
|
328
|
+
readonly tag?: string | undefined;
|
|
247
329
|
} | {
|
|
248
330
|
readonly type: string;
|
|
249
331
|
readonly input: import("effect/Schema").Json;
|
|
250
332
|
readonly tag?: string | undefined;
|
|
333
|
+
readonly at?: number | undefined;
|
|
251
334
|
})[];
|
|
252
335
|
readonly waitOn?: {
|
|
253
336
|
readonly type: string | readonly string[];
|
|
254
337
|
readonly match?: import("effect/Schema").Json | undefined;
|
|
255
338
|
} | undefined;
|
|
256
339
|
};
|
|
340
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
341
|
+
readonly type: "agent.lineage";
|
|
342
|
+
readonly payload: {
|
|
343
|
+
readonly depth: number;
|
|
344
|
+
};
|
|
257
345
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
258
346
|
readonly type: "agent.message";
|
|
259
347
|
readonly payload: {
|
|
@@ -328,6 +416,7 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
328
416
|
readonly definitionVersion: string;
|
|
329
417
|
readonly toolCallId: string;
|
|
330
418
|
readonly input: import("effect/Schema").Json;
|
|
419
|
+
readonly depth?: number | undefined;
|
|
331
420
|
};
|
|
332
421
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
333
422
|
readonly type: "agent.steered";
|
|
@@ -380,6 +469,26 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
380
469
|
readonly turn: number;
|
|
381
470
|
readonly delta: string;
|
|
382
471
|
};
|
|
472
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
473
|
+
readonly type: "agent.turn.usage";
|
|
474
|
+
readonly payload: {
|
|
475
|
+
readonly turn: number;
|
|
476
|
+
readonly input: number;
|
|
477
|
+
readonly output: number;
|
|
478
|
+
};
|
|
479
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
480
|
+
readonly type: "runtime.child.close.requested";
|
|
481
|
+
readonly payload: {
|
|
482
|
+
readonly policy: "terminate" | "wait";
|
|
483
|
+
};
|
|
484
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
485
|
+
readonly type: "runtime.child.settled";
|
|
486
|
+
readonly payload: {
|
|
487
|
+
readonly runId: string;
|
|
488
|
+
readonly status: "cancelled" | "completed" | "failed";
|
|
489
|
+
readonly output: import("effect/Schema").Json;
|
|
490
|
+
readonly error: string | null;
|
|
491
|
+
};
|
|
383
492
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
384
493
|
readonly type: "runtime.effect.ambiguous";
|
|
385
494
|
readonly payload: {
|
|
@@ -424,6 +533,8 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
424
533
|
readonly payload: {
|
|
425
534
|
readonly effectId: string;
|
|
426
535
|
readonly error: string;
|
|
536
|
+
readonly nonRetryable?: boolean | undefined;
|
|
537
|
+
readonly retryAfterMs?: number | undefined;
|
|
427
538
|
};
|
|
428
539
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
429
540
|
readonly type: "runtime.effect.heartbeat";
|
|
@@ -432,6 +543,7 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
432
543
|
readonly attempt: number;
|
|
433
544
|
readonly heartbeatAt: number;
|
|
434
545
|
readonly deadlineAt: number | null;
|
|
546
|
+
readonly details?: import("effect/Schema").Json | undefined;
|
|
435
547
|
};
|
|
436
548
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
437
549
|
readonly type: "runtime.effect.queued";
|
|
@@ -484,6 +596,16 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
484
596
|
readonly sourceRunId: string;
|
|
485
597
|
readonly sourceSeq: number;
|
|
486
598
|
};
|
|
599
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
600
|
+
readonly type: "runtime.run.launched";
|
|
601
|
+
readonly payload: {
|
|
602
|
+
readonly runId: string;
|
|
603
|
+
readonly kind: string;
|
|
604
|
+
readonly definitionName: string;
|
|
605
|
+
readonly definitionVersion: string;
|
|
606
|
+
readonly effectId: string;
|
|
607
|
+
readonly close: "terminate" | "wait";
|
|
608
|
+
};
|
|
487
609
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
488
610
|
readonly type: "runtime.run.started";
|
|
489
611
|
readonly payload: {
|
|
@@ -493,6 +615,20 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
493
615
|
readonly definitionVersion: string;
|
|
494
616
|
readonly input: import("effect/Schema").Json;
|
|
495
617
|
readonly requestedThreadId?: string | null | undefined;
|
|
618
|
+
readonly launchedBy?: {
|
|
619
|
+
readonly runId: string;
|
|
620
|
+
readonly threadId: string;
|
|
621
|
+
readonly effectId: string;
|
|
622
|
+
readonly causationId: string;
|
|
623
|
+
readonly causationSeq: number;
|
|
624
|
+
} | undefined;
|
|
625
|
+
readonly attributes?: {
|
|
626
|
+
readonly [x: string]: string;
|
|
627
|
+
} | undefined;
|
|
628
|
+
readonly trace?: {
|
|
629
|
+
readonly traceparent: string;
|
|
630
|
+
readonly tracestate?: string | undefined;
|
|
631
|
+
} | undefined;
|
|
496
632
|
};
|
|
497
633
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
498
634
|
readonly type: "runtime.signal.received";
|
|
@@ -587,7 +723,29 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
587
723
|
readonly name: string;
|
|
588
724
|
readonly arguments: import("effect/Schema").Json;
|
|
589
725
|
};
|
|
726
|
+
readonly input?: import("effect/Schema").Json | undefined;
|
|
727
|
+
readonly depth?: number | undefined;
|
|
590
728
|
}, import("./definitions-store").AgentDefinitionsTag, (Omit<EventInput, "payload" | "type"> & {
|
|
729
|
+
readonly type: "agent.context.compacted";
|
|
730
|
+
readonly payload: {
|
|
731
|
+
readonly turn: number;
|
|
732
|
+
readonly originalCount: number;
|
|
733
|
+
readonly compactedCount: number;
|
|
734
|
+
readonly summary?: string | undefined;
|
|
735
|
+
readonly reason?: "manual" | "overflow" | "threshold" | undefined;
|
|
736
|
+
readonly messages?: readonly {
|
|
737
|
+
readonly role: "assistant" | "system" | "tool" | "user";
|
|
738
|
+
readonly content: string;
|
|
739
|
+
readonly toolCallId?: string | undefined;
|
|
740
|
+
readonly name?: string | undefined;
|
|
741
|
+
readonly toolCalls?: {
|
|
742
|
+
readonly id: string;
|
|
743
|
+
readonly name: string;
|
|
744
|
+
readonly arguments: import("effect/Schema").Json;
|
|
745
|
+
}[] | undefined;
|
|
746
|
+
}[] | undefined;
|
|
747
|
+
};
|
|
748
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
591
749
|
readonly type: "agent.effects.requested";
|
|
592
750
|
readonly payload: {
|
|
593
751
|
readonly toolCallId: string;
|
|
@@ -626,6 +784,9 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
626
784
|
readonly actorId?: string | undefined;
|
|
627
785
|
} | {
|
|
628
786
|
readonly type: "system";
|
|
787
|
+
} | {
|
|
788
|
+
readonly type: "run";
|
|
789
|
+
readonly runId: string;
|
|
629
790
|
} | undefined;
|
|
630
791
|
readonly ephemeral?: boolean | undefined;
|
|
631
792
|
readonly id?: string | undefined;
|
|
@@ -643,16 +804,35 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
643
804
|
readonly type: "runtime.cancel";
|
|
644
805
|
readonly threadId: string;
|
|
645
806
|
readonly tag?: string | undefined;
|
|
807
|
+
} | {
|
|
808
|
+
readonly type: "runtime.launch";
|
|
809
|
+
readonly runId: string;
|
|
810
|
+
readonly kind: string;
|
|
811
|
+
readonly definitionName: string;
|
|
812
|
+
readonly definitionVersion: string;
|
|
813
|
+
readonly input: import("effect/Schema").Json;
|
|
814
|
+
readonly close: "terminate" | "wait";
|
|
815
|
+
readonly tag?: string | undefined;
|
|
816
|
+
} | {
|
|
817
|
+
readonly type: "runtime.cancelRun";
|
|
818
|
+
readonly runId: string;
|
|
819
|
+
readonly tag?: string | undefined;
|
|
646
820
|
} | {
|
|
647
821
|
readonly type: string;
|
|
648
822
|
readonly input: import("effect/Schema").Json;
|
|
649
823
|
readonly tag?: string | undefined;
|
|
824
|
+
readonly at?: number | undefined;
|
|
650
825
|
})[];
|
|
651
826
|
readonly waitOn?: {
|
|
652
827
|
readonly type: string | readonly string[];
|
|
653
828
|
readonly match?: import("effect/Schema").Json | undefined;
|
|
654
829
|
} | undefined;
|
|
655
830
|
};
|
|
831
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
832
|
+
readonly type: "agent.lineage";
|
|
833
|
+
readonly payload: {
|
|
834
|
+
readonly depth: number;
|
|
835
|
+
};
|
|
656
836
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
657
837
|
readonly type: "agent.message";
|
|
658
838
|
readonly payload: {
|
|
@@ -727,6 +907,7 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
727
907
|
readonly definitionVersion: string;
|
|
728
908
|
readonly toolCallId: string;
|
|
729
909
|
readonly input: import("effect/Schema").Json;
|
|
910
|
+
readonly depth?: number | undefined;
|
|
730
911
|
};
|
|
731
912
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
732
913
|
readonly type: "agent.steered";
|
|
@@ -779,6 +960,26 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
779
960
|
readonly turn: number;
|
|
780
961
|
readonly delta: string;
|
|
781
962
|
};
|
|
963
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
964
|
+
readonly type: "agent.turn.usage";
|
|
965
|
+
readonly payload: {
|
|
966
|
+
readonly turn: number;
|
|
967
|
+
readonly input: number;
|
|
968
|
+
readonly output: number;
|
|
969
|
+
};
|
|
970
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
971
|
+
readonly type: "runtime.child.close.requested";
|
|
972
|
+
readonly payload: {
|
|
973
|
+
readonly policy: "terminate" | "wait";
|
|
974
|
+
};
|
|
975
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
976
|
+
readonly type: "runtime.child.settled";
|
|
977
|
+
readonly payload: {
|
|
978
|
+
readonly runId: string;
|
|
979
|
+
readonly status: "cancelled" | "completed" | "failed";
|
|
980
|
+
readonly output: import("effect/Schema").Json;
|
|
981
|
+
readonly error: string | null;
|
|
982
|
+
};
|
|
782
983
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
783
984
|
readonly type: "runtime.effect.ambiguous";
|
|
784
985
|
readonly payload: {
|
|
@@ -823,6 +1024,8 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
823
1024
|
readonly payload: {
|
|
824
1025
|
readonly effectId: string;
|
|
825
1026
|
readonly error: string;
|
|
1027
|
+
readonly nonRetryable?: boolean | undefined;
|
|
1028
|
+
readonly retryAfterMs?: number | undefined;
|
|
826
1029
|
};
|
|
827
1030
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
828
1031
|
readonly type: "runtime.effect.heartbeat";
|
|
@@ -831,6 +1034,7 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
831
1034
|
readonly attempt: number;
|
|
832
1035
|
readonly heartbeatAt: number;
|
|
833
1036
|
readonly deadlineAt: number | null;
|
|
1037
|
+
readonly details?: import("effect/Schema").Json | undefined;
|
|
834
1038
|
};
|
|
835
1039
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
836
1040
|
readonly type: "runtime.effect.queued";
|
|
@@ -883,6 +1087,16 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
883
1087
|
readonly sourceRunId: string;
|
|
884
1088
|
readonly sourceSeq: number;
|
|
885
1089
|
};
|
|
1090
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1091
|
+
readonly type: "runtime.run.launched";
|
|
1092
|
+
readonly payload: {
|
|
1093
|
+
readonly runId: string;
|
|
1094
|
+
readonly kind: string;
|
|
1095
|
+
readonly definitionName: string;
|
|
1096
|
+
readonly definitionVersion: string;
|
|
1097
|
+
readonly effectId: string;
|
|
1098
|
+
readonly close: "terminate" | "wait";
|
|
1099
|
+
};
|
|
886
1100
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
887
1101
|
readonly type: "runtime.run.started";
|
|
888
1102
|
readonly payload: {
|
|
@@ -892,6 +1106,20 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
892
1106
|
readonly definitionVersion: string;
|
|
893
1107
|
readonly input: import("effect/Schema").Json;
|
|
894
1108
|
readonly requestedThreadId?: string | null | undefined;
|
|
1109
|
+
readonly launchedBy?: {
|
|
1110
|
+
readonly runId: string;
|
|
1111
|
+
readonly threadId: string;
|
|
1112
|
+
readonly effectId: string;
|
|
1113
|
+
readonly causationId: string;
|
|
1114
|
+
readonly causationSeq: number;
|
|
1115
|
+
} | undefined;
|
|
1116
|
+
readonly attributes?: {
|
|
1117
|
+
readonly [x: string]: string;
|
|
1118
|
+
} | undefined;
|
|
1119
|
+
readonly trace?: {
|
|
1120
|
+
readonly traceparent: string;
|
|
1121
|
+
readonly tracestate?: string | undefined;
|
|
1122
|
+
} | undefined;
|
|
895
1123
|
};
|
|
896
1124
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
897
1125
|
readonly type: "runtime.signal.received";
|
|
@@ -1020,8 +1248,30 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1020
1248
|
}[] | undefined;
|
|
1021
1249
|
}[] | undefined;
|
|
1022
1250
|
readonly input?: import("effect/Schema").Json | undefined;
|
|
1251
|
+
readonly structuredOutput?: import("effect/Schema").Json | undefined;
|
|
1252
|
+
readonly alreadyCompacted?: boolean | undefined;
|
|
1023
1253
|
readonly consumedSteerMessageIds?: readonly string[] | undefined;
|
|
1024
1254
|
}, import("./definitions-store").AgentDefinitionsTag | LlmTag, (Omit<EventInput, "payload" | "type"> & {
|
|
1255
|
+
readonly type: "agent.context.compacted";
|
|
1256
|
+
readonly payload: {
|
|
1257
|
+
readonly turn: number;
|
|
1258
|
+
readonly originalCount: number;
|
|
1259
|
+
readonly compactedCount: number;
|
|
1260
|
+
readonly summary?: string | undefined;
|
|
1261
|
+
readonly reason?: "manual" | "overflow" | "threshold" | undefined;
|
|
1262
|
+
readonly messages?: readonly {
|
|
1263
|
+
readonly role: "assistant" | "system" | "tool" | "user";
|
|
1264
|
+
readonly content: string;
|
|
1265
|
+
readonly toolCallId?: string | undefined;
|
|
1266
|
+
readonly name?: string | undefined;
|
|
1267
|
+
readonly toolCalls?: {
|
|
1268
|
+
readonly id: string;
|
|
1269
|
+
readonly name: string;
|
|
1270
|
+
readonly arguments: import("effect/Schema").Json;
|
|
1271
|
+
}[] | undefined;
|
|
1272
|
+
}[] | undefined;
|
|
1273
|
+
};
|
|
1274
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1025
1275
|
readonly type: "agent.effects.requested";
|
|
1026
1276
|
readonly payload: {
|
|
1027
1277
|
readonly toolCallId: string;
|
|
@@ -1060,6 +1310,9 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1060
1310
|
readonly actorId?: string | undefined;
|
|
1061
1311
|
} | {
|
|
1062
1312
|
readonly type: "system";
|
|
1313
|
+
} | {
|
|
1314
|
+
readonly type: "run";
|
|
1315
|
+
readonly runId: string;
|
|
1063
1316
|
} | undefined;
|
|
1064
1317
|
readonly ephemeral?: boolean | undefined;
|
|
1065
1318
|
readonly id?: string | undefined;
|
|
@@ -1077,16 +1330,35 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1077
1330
|
readonly type: "runtime.cancel";
|
|
1078
1331
|
readonly threadId: string;
|
|
1079
1332
|
readonly tag?: string | undefined;
|
|
1333
|
+
} | {
|
|
1334
|
+
readonly type: "runtime.launch";
|
|
1335
|
+
readonly runId: string;
|
|
1336
|
+
readonly kind: string;
|
|
1337
|
+
readonly definitionName: string;
|
|
1338
|
+
readonly definitionVersion: string;
|
|
1339
|
+
readonly input: import("effect/Schema").Json;
|
|
1340
|
+
readonly close: "terminate" | "wait";
|
|
1341
|
+
readonly tag?: string | undefined;
|
|
1342
|
+
} | {
|
|
1343
|
+
readonly type: "runtime.cancelRun";
|
|
1344
|
+
readonly runId: string;
|
|
1345
|
+
readonly tag?: string | undefined;
|
|
1080
1346
|
} | {
|
|
1081
1347
|
readonly type: string;
|
|
1082
1348
|
readonly input: import("effect/Schema").Json;
|
|
1083
1349
|
readonly tag?: string | undefined;
|
|
1350
|
+
readonly at?: number | undefined;
|
|
1084
1351
|
})[];
|
|
1085
1352
|
readonly waitOn?: {
|
|
1086
1353
|
readonly type: string | readonly string[];
|
|
1087
1354
|
readonly match?: import("effect/Schema").Json | undefined;
|
|
1088
1355
|
} | undefined;
|
|
1089
1356
|
};
|
|
1357
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1358
|
+
readonly type: "agent.lineage";
|
|
1359
|
+
readonly payload: {
|
|
1360
|
+
readonly depth: number;
|
|
1361
|
+
};
|
|
1090
1362
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1091
1363
|
readonly type: "agent.message";
|
|
1092
1364
|
readonly payload: {
|
|
@@ -1161,6 +1433,7 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1161
1433
|
readonly definitionVersion: string;
|
|
1162
1434
|
readonly toolCallId: string;
|
|
1163
1435
|
readonly input: import("effect/Schema").Json;
|
|
1436
|
+
readonly depth?: number | undefined;
|
|
1164
1437
|
};
|
|
1165
1438
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1166
1439
|
readonly type: "agent.steered";
|
|
@@ -1213,6 +1486,26 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1213
1486
|
readonly turn: number;
|
|
1214
1487
|
readonly delta: string;
|
|
1215
1488
|
};
|
|
1489
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1490
|
+
readonly type: "agent.turn.usage";
|
|
1491
|
+
readonly payload: {
|
|
1492
|
+
readonly turn: number;
|
|
1493
|
+
readonly input: number;
|
|
1494
|
+
readonly output: number;
|
|
1495
|
+
};
|
|
1496
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1497
|
+
readonly type: "runtime.child.close.requested";
|
|
1498
|
+
readonly payload: {
|
|
1499
|
+
readonly policy: "terminate" | "wait";
|
|
1500
|
+
};
|
|
1501
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1502
|
+
readonly type: "runtime.child.settled";
|
|
1503
|
+
readonly payload: {
|
|
1504
|
+
readonly runId: string;
|
|
1505
|
+
readonly status: "cancelled" | "completed" | "failed";
|
|
1506
|
+
readonly output: import("effect/Schema").Json;
|
|
1507
|
+
readonly error: string | null;
|
|
1508
|
+
};
|
|
1216
1509
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1217
1510
|
readonly type: "runtime.effect.ambiguous";
|
|
1218
1511
|
readonly payload: {
|
|
@@ -1257,6 +1550,8 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1257
1550
|
readonly payload: {
|
|
1258
1551
|
readonly effectId: string;
|
|
1259
1552
|
readonly error: string;
|
|
1553
|
+
readonly nonRetryable?: boolean | undefined;
|
|
1554
|
+
readonly retryAfterMs?: number | undefined;
|
|
1260
1555
|
};
|
|
1261
1556
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1262
1557
|
readonly type: "runtime.effect.heartbeat";
|
|
@@ -1265,6 +1560,7 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1265
1560
|
readonly attempt: number;
|
|
1266
1561
|
readonly heartbeatAt: number;
|
|
1267
1562
|
readonly deadlineAt: number | null;
|
|
1563
|
+
readonly details?: import("effect/Schema").Json | undefined;
|
|
1268
1564
|
};
|
|
1269
1565
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1270
1566
|
readonly type: "runtime.effect.queued";
|
|
@@ -1317,6 +1613,16 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1317
1613
|
readonly sourceRunId: string;
|
|
1318
1614
|
readonly sourceSeq: number;
|
|
1319
1615
|
};
|
|
1616
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1617
|
+
readonly type: "runtime.run.launched";
|
|
1618
|
+
readonly payload: {
|
|
1619
|
+
readonly runId: string;
|
|
1620
|
+
readonly kind: string;
|
|
1621
|
+
readonly definitionName: string;
|
|
1622
|
+
readonly definitionVersion: string;
|
|
1623
|
+
readonly effectId: string;
|
|
1624
|
+
readonly close: "terminate" | "wait";
|
|
1625
|
+
};
|
|
1320
1626
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1321
1627
|
readonly type: "runtime.run.started";
|
|
1322
1628
|
readonly payload: {
|
|
@@ -1326,6 +1632,20 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1326
1632
|
readonly definitionVersion: string;
|
|
1327
1633
|
readonly input: import("effect/Schema").Json;
|
|
1328
1634
|
readonly requestedThreadId?: string | null | undefined;
|
|
1635
|
+
readonly launchedBy?: {
|
|
1636
|
+
readonly runId: string;
|
|
1637
|
+
readonly threadId: string;
|
|
1638
|
+
readonly effectId: string;
|
|
1639
|
+
readonly causationId: string;
|
|
1640
|
+
readonly causationSeq: number;
|
|
1641
|
+
} | undefined;
|
|
1642
|
+
readonly attributes?: {
|
|
1643
|
+
readonly [x: string]: string;
|
|
1644
|
+
} | undefined;
|
|
1645
|
+
readonly trace?: {
|
|
1646
|
+
readonly traceparent: string;
|
|
1647
|
+
readonly tracestate?: string | undefined;
|
|
1648
|
+
} | undefined;
|
|
1329
1649
|
};
|
|
1330
1650
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1331
1651
|
readonly type: "runtime.signal.received";
|
|
@@ -1420,7 +1740,29 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1420
1740
|
readonly name: string;
|
|
1421
1741
|
readonly arguments: import("effect/Schema").Json;
|
|
1422
1742
|
};
|
|
1743
|
+
readonly input?: import("effect/Schema").Json | undefined;
|
|
1744
|
+
readonly depth?: number | undefined;
|
|
1423
1745
|
}, import("./definitions-store").AgentDefinitionsTag, (Omit<EventInput, "payload" | "type"> & {
|
|
1746
|
+
readonly type: "agent.context.compacted";
|
|
1747
|
+
readonly payload: {
|
|
1748
|
+
readonly turn: number;
|
|
1749
|
+
readonly originalCount: number;
|
|
1750
|
+
readonly compactedCount: number;
|
|
1751
|
+
readonly summary?: string | undefined;
|
|
1752
|
+
readonly reason?: "manual" | "overflow" | "threshold" | undefined;
|
|
1753
|
+
readonly messages?: readonly {
|
|
1754
|
+
readonly role: "assistant" | "system" | "tool" | "user";
|
|
1755
|
+
readonly content: string;
|
|
1756
|
+
readonly toolCallId?: string | undefined;
|
|
1757
|
+
readonly name?: string | undefined;
|
|
1758
|
+
readonly toolCalls?: {
|
|
1759
|
+
readonly id: string;
|
|
1760
|
+
readonly name: string;
|
|
1761
|
+
readonly arguments: import("effect/Schema").Json;
|
|
1762
|
+
}[] | undefined;
|
|
1763
|
+
}[] | undefined;
|
|
1764
|
+
};
|
|
1765
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1424
1766
|
readonly type: "agent.effects.requested";
|
|
1425
1767
|
readonly payload: {
|
|
1426
1768
|
readonly toolCallId: string;
|
|
@@ -1459,6 +1801,9 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1459
1801
|
readonly actorId?: string | undefined;
|
|
1460
1802
|
} | {
|
|
1461
1803
|
readonly type: "system";
|
|
1804
|
+
} | {
|
|
1805
|
+
readonly type: "run";
|
|
1806
|
+
readonly runId: string;
|
|
1462
1807
|
} | undefined;
|
|
1463
1808
|
readonly ephemeral?: boolean | undefined;
|
|
1464
1809
|
readonly id?: string | undefined;
|
|
@@ -1476,16 +1821,35 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1476
1821
|
readonly type: "runtime.cancel";
|
|
1477
1822
|
readonly threadId: string;
|
|
1478
1823
|
readonly tag?: string | undefined;
|
|
1824
|
+
} | {
|
|
1825
|
+
readonly type: "runtime.launch";
|
|
1826
|
+
readonly runId: string;
|
|
1827
|
+
readonly kind: string;
|
|
1828
|
+
readonly definitionName: string;
|
|
1829
|
+
readonly definitionVersion: string;
|
|
1830
|
+
readonly input: import("effect/Schema").Json;
|
|
1831
|
+
readonly close: "terminate" | "wait";
|
|
1832
|
+
readonly tag?: string | undefined;
|
|
1833
|
+
} | {
|
|
1834
|
+
readonly type: "runtime.cancelRun";
|
|
1835
|
+
readonly runId: string;
|
|
1836
|
+
readonly tag?: string | undefined;
|
|
1479
1837
|
} | {
|
|
1480
1838
|
readonly type: string;
|
|
1481
1839
|
readonly input: import("effect/Schema").Json;
|
|
1482
1840
|
readonly tag?: string | undefined;
|
|
1841
|
+
readonly at?: number | undefined;
|
|
1483
1842
|
})[];
|
|
1484
1843
|
readonly waitOn?: {
|
|
1485
1844
|
readonly type: string | readonly string[];
|
|
1486
1845
|
readonly match?: import("effect/Schema").Json | undefined;
|
|
1487
1846
|
} | undefined;
|
|
1488
1847
|
};
|
|
1848
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1849
|
+
readonly type: "agent.lineage";
|
|
1850
|
+
readonly payload: {
|
|
1851
|
+
readonly depth: number;
|
|
1852
|
+
};
|
|
1489
1853
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1490
1854
|
readonly type: "agent.message";
|
|
1491
1855
|
readonly payload: {
|
|
@@ -1560,6 +1924,7 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1560
1924
|
readonly definitionVersion: string;
|
|
1561
1925
|
readonly toolCallId: string;
|
|
1562
1926
|
readonly input: import("effect/Schema").Json;
|
|
1927
|
+
readonly depth?: number | undefined;
|
|
1563
1928
|
};
|
|
1564
1929
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1565
1930
|
readonly type: "agent.steered";
|
|
@@ -1612,6 +1977,26 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1612
1977
|
readonly turn: number;
|
|
1613
1978
|
readonly delta: string;
|
|
1614
1979
|
};
|
|
1980
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1981
|
+
readonly type: "agent.turn.usage";
|
|
1982
|
+
readonly payload: {
|
|
1983
|
+
readonly turn: number;
|
|
1984
|
+
readonly input: number;
|
|
1985
|
+
readonly output: number;
|
|
1986
|
+
};
|
|
1987
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1988
|
+
readonly type: "runtime.child.close.requested";
|
|
1989
|
+
readonly payload: {
|
|
1990
|
+
readonly policy: "terminate" | "wait";
|
|
1991
|
+
};
|
|
1992
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1993
|
+
readonly type: "runtime.child.settled";
|
|
1994
|
+
readonly payload: {
|
|
1995
|
+
readonly runId: string;
|
|
1996
|
+
readonly status: "cancelled" | "completed" | "failed";
|
|
1997
|
+
readonly output: import("effect/Schema").Json;
|
|
1998
|
+
readonly error: string | null;
|
|
1999
|
+
};
|
|
1615
2000
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1616
2001
|
readonly type: "runtime.effect.ambiguous";
|
|
1617
2002
|
readonly payload: {
|
|
@@ -1656,6 +2041,8 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1656
2041
|
readonly payload: {
|
|
1657
2042
|
readonly effectId: string;
|
|
1658
2043
|
readonly error: string;
|
|
2044
|
+
readonly nonRetryable?: boolean | undefined;
|
|
2045
|
+
readonly retryAfterMs?: number | undefined;
|
|
1659
2046
|
};
|
|
1660
2047
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1661
2048
|
readonly type: "runtime.effect.heartbeat";
|
|
@@ -1664,6 +2051,7 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1664
2051
|
readonly attempt: number;
|
|
1665
2052
|
readonly heartbeatAt: number;
|
|
1666
2053
|
readonly deadlineAt: number | null;
|
|
2054
|
+
readonly details?: import("effect/Schema").Json | undefined;
|
|
1667
2055
|
};
|
|
1668
2056
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1669
2057
|
readonly type: "runtime.effect.queued";
|
|
@@ -1716,6 +2104,16 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1716
2104
|
readonly sourceRunId: string;
|
|
1717
2105
|
readonly sourceSeq: number;
|
|
1718
2106
|
};
|
|
2107
|
+
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
2108
|
+
readonly type: "runtime.run.launched";
|
|
2109
|
+
readonly payload: {
|
|
2110
|
+
readonly runId: string;
|
|
2111
|
+
readonly kind: string;
|
|
2112
|
+
readonly definitionName: string;
|
|
2113
|
+
readonly definitionVersion: string;
|
|
2114
|
+
readonly effectId: string;
|
|
2115
|
+
readonly close: "terminate" | "wait";
|
|
2116
|
+
};
|
|
1719
2117
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1720
2118
|
readonly type: "runtime.run.started";
|
|
1721
2119
|
readonly payload: {
|
|
@@ -1725,6 +2123,20 @@ export declare function agent(options?: AgentModuleOptions): import("@swirls/loo
|
|
|
1725
2123
|
readonly definitionVersion: string;
|
|
1726
2124
|
readonly input: import("effect/Schema").Json;
|
|
1727
2125
|
readonly requestedThreadId?: string | null | undefined;
|
|
2126
|
+
readonly launchedBy?: {
|
|
2127
|
+
readonly runId: string;
|
|
2128
|
+
readonly threadId: string;
|
|
2129
|
+
readonly effectId: string;
|
|
2130
|
+
readonly causationId: string;
|
|
2131
|
+
readonly causationSeq: number;
|
|
2132
|
+
} | undefined;
|
|
2133
|
+
readonly attributes?: {
|
|
2134
|
+
readonly [x: string]: string;
|
|
2135
|
+
} | undefined;
|
|
2136
|
+
readonly trace?: {
|
|
2137
|
+
readonly traceparent: string;
|
|
2138
|
+
readonly tracestate?: string | undefined;
|
|
2139
|
+
} | undefined;
|
|
1728
2140
|
};
|
|
1729
2141
|
}) | (Omit<EventInput, "payload" | "type"> & {
|
|
1730
2142
|
readonly type: "runtime.signal.received";
|