@codeworksh/harness 0.3.0 → 0.4.0-canary.52.1.ge7df22a4
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/{daytona-D4sNwzSr.mjs → daytona-BqRoRhe7.mjs} +5 -8
- package/daytona-BqRoRhe7.mjs.map +1 -0
- package/effect.d.mts +1275 -147
- package/effect.mjs +692 -97
- package/effect.mjs.map +1 -1
- package/package.json +11 -7
- package/sandboxes/daytona/index.mjs +1 -1
- package/daytona-D4sNwzSr.mjs.map +0 -1
package/effect.d.mts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "./index-BlvIgEtU.mjs";
|
|
2
2
|
import "./index-BEZ8eL--.mjs";
|
|
3
|
-
import { Cause, Config, Context, Duration, Effect, JsonSchema, Layer, Option, Ref, Schema, Stream } from "effect";
|
|
3
|
+
import { Cause, Config, Context, DateTime, Duration, Effect, JsonSchema, Layer, Option, Ref, Schema, Stream } from "effect";
|
|
4
4
|
import { Event, Message, Model, Protocol } from "@codeworksh/aikit";
|
|
5
5
|
import { MessageID as ID, SessionID as ID$1 } from "@codeworksh/plugin/ids";
|
|
6
6
|
import { SqlClient, SqlClient as SqlClient$1, SqlSchema as SqlSchema$1 } from "effect/sql";
|
|
@@ -8,7 +8,7 @@ import { SqliteClient } from "@effect/sql-sqlite-node";
|
|
|
8
8
|
import { Model as Model$1 } from "effect/schema";
|
|
9
9
|
import { SqliteProvider, create } from "@platformatic/vfs";
|
|
10
10
|
import { ChildProcessSpawner } from "effect/process";
|
|
11
|
-
import { DirectoryNotFoundError, Error, Error as Error$1, Info as Info$5, Interface as Interface$
|
|
11
|
+
import { DirectoryNotFoundError, Error, Error as Error$1, Info as Info$5, Interface as Interface$10, NotDirectoryError, Service, Service as Service$10 } from "@codeworksh/plugin/location";
|
|
12
12
|
import * as Section from "@codeworksh/plugin/plugin/section";
|
|
13
13
|
import { Config as Config$1, Events, PluginOptions, PluginRef, PluginRegistry, PromptResolver, SharedPluginContext } from "@codeworksh/plugin/plugin";
|
|
14
14
|
import * as AikitFailure from "@codeworksh/aikit/failure";
|
|
@@ -284,6 +284,8 @@ declare const SessionRow_base: import("effect/schema/VariantSchema").Class<Sessi
|
|
|
284
284
|
readonly tokensOutput: Model$1.GeneratedByDb<Schema.Int>;
|
|
285
285
|
readonly tokensCacheRead: Model$1.GeneratedByDb<Schema.Int>;
|
|
286
286
|
readonly tokensCacheWrite: Model$1.GeneratedByDb<Schema.Int>;
|
|
287
|
+
readonly execution: Model$1.FieldOption<Schema.Literals<readonly ["running", "closed"]>>;
|
|
288
|
+
readonly restarts: Model$1.GeneratedByDb<Schema.Int>;
|
|
287
289
|
}, Schema.Struct<import("effect/schema/VariantSchema").ExtractFields<"select", {
|
|
288
290
|
readonly createdAt: Model$1.DateTimeInsertFromNumber;
|
|
289
291
|
readonly updatedAt: Model$1.DateTimeUpdateFromNumber;
|
|
@@ -371,6 +373,8 @@ declare const SessionRow_base: import("effect/schema/VariantSchema").Class<Sessi
|
|
|
371
373
|
readonly tokensOutput: Model$1.GeneratedByDb<Schema.Int>;
|
|
372
374
|
readonly tokensCacheRead: Model$1.GeneratedByDb<Schema.Int>;
|
|
373
375
|
readonly tokensCacheWrite: Model$1.GeneratedByDb<Schema.Int>;
|
|
376
|
+
readonly execution: Model$1.FieldOption<Schema.Literals<readonly ["running", "closed"]>>;
|
|
377
|
+
readonly restarts: Model$1.GeneratedByDb<Schema.Int>;
|
|
374
378
|
}, true>>> & {
|
|
375
379
|
readonly insert: Schema.Struct<{
|
|
376
380
|
readonly createdAt: import("effect/schema/VariantSchema").Overrideable<Schema.DateTimeUtcFromMillis>;
|
|
@@ -395,6 +399,7 @@ declare const SessionRow_base: import("effect/schema/VariantSchema").Class<Sessi
|
|
|
395
399
|
readonly tag: Schema.OptionFromNullOr<Schema.String>;
|
|
396
400
|
readonly metadata: Schema.OptionFromNullOr<Schema.fromJsonString<Schema.$Record<Schema.String, Schema.String>>>;
|
|
397
401
|
readonly leafEntryId: Schema.OptionFromNullOr<Schema.String>;
|
|
402
|
+
readonly execution: Schema.OptionFromNullOr<Schema.Literals<readonly ["running", "closed"]>>;
|
|
398
403
|
}>;
|
|
399
404
|
readonly json: Schema.Struct<{
|
|
400
405
|
readonly createdAt: Schema.DateTimeUtcFromMillis;
|
|
@@ -424,6 +429,8 @@ declare const SessionRow_base: import("effect/schema/VariantSchema").Class<Sessi
|
|
|
424
429
|
readonly tokensOutput: Schema.Int;
|
|
425
430
|
readonly tokensCacheRead: Schema.Int;
|
|
426
431
|
readonly tokensCacheWrite: Schema.Int;
|
|
432
|
+
readonly execution: Model$1.optionalOption<Schema.Literals<readonly ["running", "closed"]>>;
|
|
433
|
+
readonly restarts: Schema.Int;
|
|
427
434
|
}>;
|
|
428
435
|
readonly jsonCreate: Schema.Struct<{
|
|
429
436
|
readonly id: Schema.brand<Schema.String, "Session.ID">;
|
|
@@ -446,6 +453,7 @@ declare const SessionRow_base: import("effect/schema/VariantSchema").Class<Sessi
|
|
|
446
453
|
readonly tag: Model$1.optionalOption<Schema.String>;
|
|
447
454
|
readonly metadata: Model$1.optionalOption<Schema.$Record<Schema.String, Schema.String>>;
|
|
448
455
|
readonly leafEntryId: Model$1.optionalOption<Schema.String>;
|
|
456
|
+
readonly execution: Model$1.optionalOption<Schema.Literals<readonly ["running", "closed"]>>;
|
|
449
457
|
}>;
|
|
450
458
|
readonly jsonUpdate: Schema.Struct<{
|
|
451
459
|
readonly id: Schema.brand<Schema.String, "Session.ID">;
|
|
@@ -468,6 +476,7 @@ declare const SessionRow_base: import("effect/schema/VariantSchema").Class<Sessi
|
|
|
468
476
|
readonly tag: Model$1.optionalOption<Schema.String>;
|
|
469
477
|
readonly metadata: Model$1.optionalOption<Schema.$Record<Schema.String, Schema.String>>;
|
|
470
478
|
readonly leafEntryId: Model$1.optionalOption<Schema.String>;
|
|
479
|
+
readonly execution: Model$1.optionalOption<Schema.Literals<readonly ["running", "closed"]>>;
|
|
471
480
|
}>;
|
|
472
481
|
readonly select: Schema.Struct<{
|
|
473
482
|
readonly createdAt: Schema.DateTimeUtcFromMillis;
|
|
@@ -497,6 +506,8 @@ declare const SessionRow_base: import("effect/schema/VariantSchema").Class<Sessi
|
|
|
497
506
|
readonly tokensOutput: Schema.Int;
|
|
498
507
|
readonly tokensCacheRead: Schema.Int;
|
|
499
508
|
readonly tokensCacheWrite: Schema.Int;
|
|
509
|
+
readonly execution: Schema.OptionFromNullOr<Schema.Literals<readonly ["running", "closed"]>>;
|
|
510
|
+
readonly restarts: Schema.Int;
|
|
500
511
|
}>;
|
|
501
512
|
readonly update: Schema.Struct<{
|
|
502
513
|
readonly updatedAt: import("effect/schema/VariantSchema").Overrideable<Schema.DateTimeUtcFromMillis>;
|
|
@@ -520,6 +531,7 @@ declare const SessionRow_base: import("effect/schema/VariantSchema").Class<Sessi
|
|
|
520
531
|
readonly tag: Schema.OptionFromNullOr<Schema.String>;
|
|
521
532
|
readonly metadata: Schema.OptionFromNullOr<Schema.fromJsonString<Schema.$Record<Schema.String, Schema.String>>>;
|
|
522
533
|
readonly leafEntryId: Schema.OptionFromNullOr<Schema.String>;
|
|
534
|
+
readonly execution: Schema.OptionFromNullOr<Schema.Literals<readonly ["running", "closed"]>>;
|
|
523
535
|
}>;
|
|
524
536
|
};
|
|
525
537
|
declare class SessionRow extends SessionRow_base {}
|
|
@@ -739,7 +751,7 @@ declare const SessionEntryPartRow_base: import("effect/schema/VariantSchema").Cl
|
|
|
739
751
|
declare class SessionEntryPartRow extends SessionEntryPartRow_base {}
|
|
740
752
|
import * as import__codeworksh_plugin_event from "@codeworksh/plugin/event";
|
|
741
753
|
declare namespace event_d_exports {
|
|
742
|
-
export { event_d_exports as Event, Interface$
|
|
754
|
+
export { event_d_exports as Event, Interface$18 as Interface, InvalidDurableEventError, LogInput, LogItem, Manifest, PublishOptions, ReadAggregateInput, ReadAggregateResult, SerializedEvent, Service$17 as Service, Subscribe, SubscribeOptions, Subscriber, SubscriptionOverflowError, Synced, Unsubscribe, isSynced, layer$19 as layer };
|
|
743
755
|
}
|
|
744
756
|
type SerializedEvent = {
|
|
745
757
|
readonly id: schema_d_exports$10.ID;
|
|
@@ -835,7 +847,7 @@ interface Subscribe {
|
|
|
835
847
|
(options?: SubscribeOptions): Stream.Stream<schema_d_exports$10.Payload, SubscriptionOverflowError>;
|
|
836
848
|
<D extends schema_d_exports$10.Definition>(definition: D, options?: SubscribeOptions): Stream.Stream<schema_d_exports$10.Payload<D>, SubscriptionOverflowError>;
|
|
837
849
|
}
|
|
838
|
-
interface Interface$
|
|
850
|
+
interface Interface$18 {
|
|
839
851
|
/** Current sequence head, or -1 if absent. A version position, not a row count. */
|
|
840
852
|
readonly latestSequence: (aggregateId: string) => Effect.Effect<number>;
|
|
841
853
|
/**
|
|
@@ -893,14 +905,14 @@ interface Interface$17 {
|
|
|
893
905
|
*/
|
|
894
906
|
readonly advance: (aggregateId: string, seq: number) => Effect.Effect<void>;
|
|
895
907
|
}
|
|
896
|
-
declare const Service_base$15: Context.ServiceClass<Service$17, "@codeworksh/harness/event/event/Service", Interface$
|
|
908
|
+
declare const Service_base$15: Context.ServiceClass<Service$17, "@codeworksh/harness/event/event/Service", Interface$18>;
|
|
897
909
|
declare class Service$17 extends Service_base$15 {}
|
|
898
910
|
declare const layer$19: Layer.Layer<Service$17, never, SqlClient.SqlClient>;
|
|
899
911
|
import * as import__codeworksh_plugin_project from "@codeworksh/plugin/project";
|
|
900
912
|
import * as import__codeworksh_plugin_schema from "@codeworksh/plugin/schema";
|
|
901
913
|
import * as import__codeworksh_plugin_space from "@codeworksh/plugin/space";
|
|
902
914
|
declare namespace schema_d_exports$6 {
|
|
903
|
-
export { AssistantEnvelopeUsage, CompactionData, Config$2 as Config, DEFAULT_TITLE, ID$1 as ID, IDFromDb, InterruptReason, JsonObject, MessageEnvelopeIdentity, schema_d_exports$6 as SessionSchema, TITLE_MAX_LENGTH, ThinkingLevel, Usage, titleFrom };
|
|
915
|
+
export { AssistantEnvelopeUsage, CompactionData, Config$2 as Config, DEFAULT_TITLE, Execution, ID$1 as ID, IDFromDb, InterruptReason, JsonObject, MessageEnvelopeIdentity, schema_d_exports$6 as SessionSchema, TITLE_MAX_LENGTH, ThinkingLevel, Usage, titleFrom };
|
|
904
916
|
}
|
|
905
917
|
declare const IDFromDb: Schema.brand<Schema.String, "Session.ID">;
|
|
906
918
|
/** The title of a session created without one; its first prompt replaces it. */
|
|
@@ -935,6 +947,13 @@ type Config$2 = typeof Config$2.Type;
|
|
|
935
947
|
*/
|
|
936
948
|
declare const InterruptReason: Schema.Literals<readonly ["user", "shutdown"]>;
|
|
937
949
|
type InterruptReason = typeof InterruptReason.Type;
|
|
950
|
+
/**
|
|
951
|
+
* A run left unfinished: `running` while one is in flight, and still after the process died during
|
|
952
|
+
* it; `closed` once a shutdown stopped it. Either resumes when the server starts again; a run that
|
|
953
|
+
* ended any other way leaves none.
|
|
954
|
+
*/
|
|
955
|
+
declare const Execution: Schema.Literals<readonly ["running", "closed"]>;
|
|
956
|
+
type Execution = typeof Execution.Type;
|
|
938
957
|
declare const JsonObject: Schema.fromJsonString<Schema.$Record<Schema.String, Schema.Unknown>>;
|
|
939
958
|
declare const MessageEnvelopeIdentity: Schema.fromJsonString<Schema.Struct<{
|
|
940
959
|
readonly messageId: Schema.String;
|
|
@@ -977,7 +996,7 @@ declare const AssistantEnvelopeUsage: Schema.fromJsonString<Schema.Struct<{
|
|
|
977
996
|
}>;
|
|
978
997
|
}>>;
|
|
979
998
|
declare namespace session_d_exports$1 {
|
|
980
|
-
export { AbortAssistant, AppendEntry, AppendPart, CreateSession, EntryNotFoundError, EntryState, EntryType, ForkInput, HydratedEntry, Interface$
|
|
999
|
+
export { AbortAssistant, AppendEntry, AppendPart, CreateSession, EntryNotFoundError, EntryState, EntryType, ForkInput, HydratedEntry, Interface$17 as Interface, InvalidEntryDataError, ListInput$1 as ListInput, MessageEntryType, PartType, RelinkError, RelinkInput$1 as RelinkInput, RelinkReason, ReplaceAssistant, Service$16 as Service, session_d_exports$1 as Session, SessionEntryPartRow, SessionEntryRow, SessionLinkedSpaceNotFoundError, SessionNotFoundError, SessionNotLinkedError, SessionRow, SetEntryState, SettleToolCall, ToolCallNotFoundError, ToolStatus, defaultLayer$6 as defaultLayer, entryStates, entryTypes, layer$18 as layer, messageEntryTypes, partTypes, rebaseDirectory, toolStatuses };
|
|
981
1000
|
}
|
|
982
1001
|
declare const SessionNotFoundError_base: Schema.Class<SessionNotFoundError, Schema.TaggedStruct<"SessionNotFoundError", {
|
|
983
1002
|
readonly sessionId: Schema.String;
|
|
@@ -1129,7 +1148,7 @@ interface HydratedEntry {
|
|
|
1129
1148
|
readonly entry: SessionEntryRow;
|
|
1130
1149
|
readonly parts: ReadonlyArray<SessionEntryPartRow>;
|
|
1131
1150
|
}
|
|
1132
|
-
interface Interface$
|
|
1151
|
+
interface Interface$17 {
|
|
1133
1152
|
readonly create: (input: CreateSession) => Effect.Effect<SessionRow>;
|
|
1134
1153
|
/**
|
|
1135
1154
|
* Point an existing session at a host directory, or clear it with `null`.
|
|
@@ -1153,9 +1172,31 @@ interface Interface$16 {
|
|
|
1153
1172
|
* value. The projection of `session.config.changed`, so it runs inside that event's commit.
|
|
1154
1173
|
*/
|
|
1155
1174
|
readonly configure: (sessionId: ID$1, config: Config$2) => Effect.Effect<void>;
|
|
1175
|
+
/** Records that the session has a run to do: one starting, or one a prompt just woke. */
|
|
1176
|
+
readonly markRunning: (sessionId: ID$1) => Effect.Effect<void>;
|
|
1177
|
+
/**
|
|
1178
|
+
* Records how a run ended. `closed` (a shutdown) leaves it to resume. `stopped` (the user) and
|
|
1179
|
+
* `finished` clear it and the restart count, except that a finished run with prompts still
|
|
1180
|
+
* pending stays marked: they are accepted work a successor, or the next server start, runs.
|
|
1181
|
+
*/
|
|
1182
|
+
readonly endExecution: (sessionId: ID$1, end: "finished" | "stopped" | "closed",
|
|
1183
|
+
/** For a stop: the log position it was asked at. A prompt admitted after it keeps the mark. */
|
|
1184
|
+
stoppedAt?: number) => Effect.Effect<void>;
|
|
1185
|
+
/**
|
|
1186
|
+
* Claims a session's unfinished run for recovery: marks it running again, counting a restart when
|
|
1187
|
+
* a dying process left it running (a shutdown's closed run is not counted). The new count, or none
|
|
1188
|
+
* when nothing is unfinished any more, say because the user stopped it since.
|
|
1189
|
+
*/
|
|
1190
|
+
readonly claimRestart: (sessionId: ID$1) => Effect.Effect<Option.Option<number>>;
|
|
1191
|
+
/** A committed turn is progress: the restart count starts over. Runs inside `TurnEnded`'s commit. */
|
|
1192
|
+
readonly resetRestarts: (sessionId: ID$1) => Effect.Effect<void>;
|
|
1193
|
+
/** Sessions with a run left unfinished, oldest first. */
|
|
1194
|
+
readonly unfinished: Effect.Effect<ReadonlyArray<SessionRow>>;
|
|
1156
1195
|
readonly get: (sessionId: ID$1) => Effect.Effect<Option.Option<SessionRow>>;
|
|
1157
1196
|
/** The space a session attaches to — its env and absolute location. None when the session is unknown. */
|
|
1158
1197
|
readonly space: (sessionId: ID$1) => Effect.Effect<Option.Option<schema_d_exports$7.SpaceSchema.Info>>;
|
|
1198
|
+
/** The project a session belongs to, through its space. None when the session is unknown. */
|
|
1199
|
+
readonly project: (sessionId: ID$1) => Effect.Effect<Option.Option<schema_d_exports$9.ProjectSchema.Info>>;
|
|
1159
1200
|
/** Sessions newest first, across the whole database when no scope is given. */
|
|
1160
1201
|
readonly list: (input?: ListInput$1) => Effect.Effect<SessionRow[]>;
|
|
1161
1202
|
readonly entry: (entryId: string) => Effect.Effect<Option.Option<HydratedEntry>>;
|
|
@@ -1198,7 +1239,7 @@ interface Interface$16 {
|
|
|
1198
1239
|
label: string | null;
|
|
1199
1240
|
}) => Effect.Effect<void, EntryNotFoundError>;
|
|
1200
1241
|
}
|
|
1201
|
-
declare const Service_base$14: Context.ServiceClass<Service$16, "@codeworksh/harness/session/session/Service", Interface$
|
|
1242
|
+
declare const Service_base$14: Context.ServiceClass<Service$16, "@codeworksh/harness/session/session/Service", Interface$17>;
|
|
1202
1243
|
declare class Service$16 extends Service_base$14 {}
|
|
1203
1244
|
declare const layer$18: Layer.Layer<Service$16, never, Service$17 | SqlClient.SqlClient>;
|
|
1204
1245
|
declare const defaultLayer$6: Layer.Layer<Service$16, import("effect/Config").ConfigError, Service$17>;
|
|
@@ -1226,7 +1267,7 @@ import * as import__codeworksh_plugin_sandbox_io from "@codeworksh/plugin/sandbo
|
|
|
1226
1267
|
import * as import__codeworksh_plugin_sandbox_driver from "@codeworksh/plugin/sandbox/driver";
|
|
1227
1268
|
import * as import__codeworksh_plugin_sandbox_errors from "@codeworksh/plugin/sandbox/errors";
|
|
1228
1269
|
declare namespace registry_d_exports$1 {
|
|
1229
|
-
export { DriverInfo, Registry, RegistryService, registry_d_exports$1 as SandboxDriverRegistry, layer$17 as layer, make$
|
|
1270
|
+
export { DriverInfo, Registry, RegistryService, registry_d_exports$1 as SandboxDriverRegistry, layer$17 as layer, make$6 as make };
|
|
1230
1271
|
}
|
|
1231
1272
|
interface DriverInfo {
|
|
1232
1273
|
readonly name: driver_d_exports.SandboxDriver.Name;
|
|
@@ -1247,10 +1288,10 @@ interface RegistryService {
|
|
|
1247
1288
|
}
|
|
1248
1289
|
declare const Registry_base: Context.ServiceClass<Registry, "@codeworksh/harness/sandbox/registry", RegistryService>;
|
|
1249
1290
|
declare class Registry extends Registry_base {}
|
|
1250
|
-
declare const make$
|
|
1291
|
+
declare const make$6: (drivers: ReadonlyArray<driver_d_exports.SandboxDriver.Registration>) => Effect.Effect<RegistryService, errors_d_exports.SandboxDriverRegistrationError>;
|
|
1251
1292
|
declare const layer$17: (...drivers: ReadonlyArray<driver_d_exports.SandboxDriver.Registration>) => Layer.Layer<Registry, errors_d_exports.SandboxDriverRegistrationError, never>;
|
|
1252
1293
|
declare namespace control_d_exports$1 {
|
|
1253
|
-
export { Controller, CreateInput$2 as CreateInput, DestroyOptions, Interface$
|
|
1294
|
+
export { Controller, CreateInput$2 as CreateInput, DestroyOptions, Interface$16 as Interface, ListInput, MountOptions, Options$5 as Options, RegisterInput$1 as RegisterInput, control_d_exports$1 as SandboxController, layer$16 as layer, make$5 as make };
|
|
1254
1295
|
}
|
|
1255
1296
|
interface CreateInput$2<CreateConfig, RuntimeConfig extends driver_d_exports.SandboxDriver.RuntimeConfigBase> {
|
|
1256
1297
|
readonly driver: driver_d_exports.SandboxDriver.Definition<CreateConfig, RuntimeConfig>;
|
|
@@ -1278,7 +1319,7 @@ interface ListInput {
|
|
|
1278
1319
|
readonly status?: instance_d_exports.SandboxInstance.Status;
|
|
1279
1320
|
readonly usage?: instance_d_exports.SandboxInstance.Usage;
|
|
1280
1321
|
}
|
|
1281
|
-
interface Interface$
|
|
1322
|
+
interface Interface$16 {
|
|
1282
1323
|
readonly create: <CreateConfig, RuntimeConfig extends driver_d_exports.SandboxDriver.RuntimeConfigBase>(input: CreateInput$2<CreateConfig, RuntimeConfig>) => Effect.Effect<instance_d_exports.SandboxInstance.Info, errors_d_exports.SandboxCreateError>;
|
|
1283
1324
|
readonly createAndMount: <CreateConfig, RuntimeConfig extends driver_d_exports.SandboxDriver.RuntimeConfigBase>(input: CreateInput$2<CreateConfig, RuntimeConfig>, options?: MountOptions) => io_d_exports.SandboxIO.Layer<errors_d_exports.SandboxCreateError | errors_d_exports.SandboxMountError>;
|
|
1284
1325
|
readonly register: <CreateConfig, RuntimeConfig extends driver_d_exports.SandboxDriver.RuntimeConfigBase>(input: RegisterInput$1<CreateConfig, RuntimeConfig>) => Effect.Effect<instance_d_exports.SandboxInstance.Info, errors_d_exports.SandboxRegisterError>;
|
|
@@ -1293,7 +1334,7 @@ interface Interface$15 {
|
|
|
1293
1334
|
readonly stop: (id: instance_d_exports.SandboxInstance.ID) => Effect.Effect<instance_d_exports.SandboxInstance.Info, errors_d_exports.SandboxStopError>;
|
|
1294
1335
|
readonly destroy: (id: instance_d_exports.SandboxInstance.ID, options?: DestroyOptions) => Effect.Effect<void, errors_d_exports.SandboxDestroyError>;
|
|
1295
1336
|
}
|
|
1296
|
-
declare const Controller_base: Context.ServiceClass<Controller, "@codeworksh/harness/sandbox/control/Controller", Interface$
|
|
1337
|
+
declare const Controller_base: Context.ServiceClass<Controller, "@codeworksh/harness/sandbox/control/Controller", Interface$16>;
|
|
1297
1338
|
declare class Controller extends Controller_base {}
|
|
1298
1339
|
interface Options$5 {
|
|
1299
1340
|
/** Absolute host cwd used by the local instance. Never inferred from ambient process state. */
|
|
@@ -1301,7 +1342,7 @@ interface Options$5 {
|
|
|
1301
1342
|
readonly transportIdleTimeToLive?: Duration.Input;
|
|
1302
1343
|
readonly provisioningTimeoutMs?: number;
|
|
1303
1344
|
}
|
|
1304
|
-
declare const make$
|
|
1345
|
+
declare const make$5: (options: Options$5) => Effect.Effect<Interface$16, errors_d_exports.SandboxDriverRegistrationError, Registry | import("effect/Scope").Scope | SqlClient.SqlClient>;
|
|
1305
1346
|
declare const layer$16: (options: Options$5) => Layer.Layer<Controller, errors_d_exports.SandboxDriverRegistrationError, Registry | SqlClient.SqlClient>;
|
|
1306
1347
|
//#endregion
|
|
1307
1348
|
//#region src/sandbox/sandbox.d.ts
|
|
@@ -1319,7 +1360,7 @@ type Provides = io_d_exports.SandboxIO.Provides;
|
|
|
1319
1360
|
/** A sandbox is any Layer providing the runtime services above. */
|
|
1320
1361
|
type Sandbox<E = never, RIn = never> = Layer.Layer<Provides, E, RIn>;
|
|
1321
1362
|
declare namespace git_d_exports {
|
|
1322
|
-
export { AppProcessError, git_d_exports as Git, Interface$
|
|
1363
|
+
export { AppProcessError, git_d_exports as Git, Interface$15 as Interface, Result$1 as Result, RevParse, Service$15 as Service, defaultLayer$5 as defaultLayer, layer$15 as layer, layerWith$5 as layerWith, resolvePath };
|
|
1323
1364
|
}
|
|
1324
1365
|
declare const AppProcessError_base: Schema.Class<AppProcessError, Schema.TaggedStruct<"AppProcessError", {
|
|
1325
1366
|
readonly command: Schema.String;
|
|
@@ -1334,7 +1375,7 @@ interface Result$1 {
|
|
|
1334
1375
|
readonly stderr: string;
|
|
1335
1376
|
}
|
|
1336
1377
|
type RevParse = "--show-toplevel" | "--git-dir" | "--git-common-dir";
|
|
1337
|
-
interface Interface$
|
|
1378
|
+
interface Interface$15 {
|
|
1338
1379
|
/** Run `git <args>` in `directory`; fails only when the process cannot be spawned. */
|
|
1339
1380
|
readonly exec: (directory: string, args: ReadonlyArray<string>) => Effect.Effect<Result$1, AppProcessError>;
|
|
1340
1381
|
readonly revParse: (directory: string, arg: RevParse) => Effect.Effect<string | undefined>;
|
|
@@ -1362,7 +1403,7 @@ interface Interface$14 {
|
|
|
1362
1403
|
readonly env?: Record<string, string>;
|
|
1363
1404
|
}) => Effect.Effect<Result$1, AppProcessError>;
|
|
1364
1405
|
}
|
|
1365
|
-
declare const Service_base$13: Context.ServiceClass<Service$15, "@codeworksh/harness/git/git/Service", Interface$
|
|
1406
|
+
declare const Service_base$13: Context.ServiceClass<Service$15, "@codeworksh/harness/git/git/Service", Interface$15>;
|
|
1366
1407
|
declare class Service$15 extends Service_base$13 {}
|
|
1367
1408
|
declare const layer$15: Layer.Layer<Service$15, never, import("@codeworksh/plugin/sandbox/shell").Shell>;
|
|
1368
1409
|
/**
|
|
@@ -1380,7 +1421,7 @@ declare const defaultLayer$5: (rootPath: string) => Layer.Layer<Service$15, neve
|
|
|
1380
1421
|
declare function resolvePath(cwd: string, value: string): string;
|
|
1381
1422
|
import * as import__codeworksh_plugin_repo from "@codeworksh/plugin/repo";
|
|
1382
1423
|
declare namespace repo_d_exports {
|
|
1383
|
-
export { Identity, Interface$
|
|
1424
|
+
export { Identity, Interface$14 as Interface, MARKER, repo_d_exports as Repo, Service$14 as Service, defaultLayer$4 as defaultLayer, layer$14 as layer, layerWith$4 as layerWith, normalize };
|
|
1384
1425
|
}
|
|
1385
1426
|
/** Per-clone file under the store that pins the project id (see PROJECT.md §1 "marker"). */
|
|
1386
1427
|
declare const MARKER = "codework";
|
|
@@ -1391,13 +1432,13 @@ interface Identity {
|
|
|
1391
1432
|
/** True when a portable id was computed and written to the marker this call. */
|
|
1392
1433
|
readonly stamp: boolean;
|
|
1393
1434
|
}
|
|
1394
|
-
interface Interface$
|
|
1435
|
+
interface Interface$14 {
|
|
1395
1436
|
/** Locate the checkout containing `input`, or undefined when there is none git can read. */
|
|
1396
1437
|
readonly find: (input: schema_d_exports$8.AbsolutePath) => Effect.Effect<schema_d_exports$5.RepoSchema.Info | undefined>;
|
|
1397
1438
|
/** PROJECT.md §5.1 PHASE 2. Stamps the marker when a portable id is found for the first time. */
|
|
1398
1439
|
readonly identity: (repo: schema_d_exports$5.RepoSchema.Info) => Effect.Effect<Identity>;
|
|
1399
1440
|
}
|
|
1400
|
-
declare const Service_base$12: Context.ServiceClass<Service$14, "@codeworksh/harness/repo/repo/Service", Interface$
|
|
1441
|
+
declare const Service_base$12: Context.ServiceClass<Service$14, "@codeworksh/harness/repo/repo/Service", Interface$14>;
|
|
1401
1442
|
declare class Service$14 extends Service_base$12 {}
|
|
1402
1443
|
/**
|
|
1403
1444
|
* Canonical `host/path` for a remote url (D-URL): host and path lowercased,
|
|
@@ -1409,7 +1450,7 @@ declare const layer$14: Layer.Layer<Service$14, never, import("@codeworksh/plugi
|
|
|
1409
1450
|
declare const layerWith$4: <E, RIn>(sandbox: Sandbox.Sandbox<E, RIn>) => Layer.Layer<Service$14, E, RIn>;
|
|
1410
1451
|
declare const defaultLayer$4: (rootPath: string) => Layer.Layer<Service$14, never, never>;
|
|
1411
1452
|
declare namespace space_d_exports {
|
|
1412
|
-
export { AbsorbInput, Interface$
|
|
1453
|
+
export { AbsorbInput, Interface$13 as Interface, RehomeInput, Service$13 as Service, space_d_exports as Space, archiveEnv, fromRow, id, layer$13 as layer, layerWith$3 as layerWith };
|
|
1413
1454
|
}
|
|
1414
1455
|
/** `hash(env, location)` — no project component (D-SPACEID). */
|
|
1415
1456
|
declare const id: (env: instance_d_exports.SandboxInstance.ID, location: string) => schema_d_exports$7.SpaceSchema.ID;
|
|
@@ -1424,7 +1465,7 @@ interface AbsorbInput {
|
|
|
1424
1465
|
readonly strayId: schema_d_exports$7.SpaceSchema.ID;
|
|
1425
1466
|
readonly into: schema_d_exports$7.SpaceSchema.ID;
|
|
1426
1467
|
}
|
|
1427
|
-
interface Interface$
|
|
1468
|
+
interface Interface$13 {
|
|
1428
1469
|
readonly get: (id: schema_d_exports$7.SpaceSchema.ID) => Effect.Effect<Option.Option<schema_d_exports$7.SpaceSchema.Info>>;
|
|
1429
1470
|
/** Active spaces of the project in this env, sorted by location. */
|
|
1430
1471
|
readonly list: (projectId: schema_d_exports$9.ProjectSchema.ID) => Effect.Effect<schema_d_exports$7.SpaceSchema.Info[]>;
|
|
@@ -1437,7 +1478,7 @@ interface Interface$12 {
|
|
|
1437
1478
|
/** Re-point a stray subdirectory space's sessions at its parent, then delete it (§5.3). `session.directory` is absolute and stays put. */
|
|
1438
1479
|
readonly absorb: (input: AbsorbInput) => Effect.Effect<void>;
|
|
1439
1480
|
}
|
|
1440
|
-
declare const Service_base$11: Context.ServiceClass<Service$13, "@codeworksh/harness/space/space/Service", Interface$
|
|
1481
|
+
declare const Service_base$11: Context.ServiceClass<Service$13, "@codeworksh/harness/space/space/Service", Interface$13>;
|
|
1441
1482
|
declare class Service$13 extends Service_base$11 {}
|
|
1442
1483
|
/** Row → public shape. Shared with `Session.space`, which reads the same row through a join. */
|
|
1443
1484
|
declare const fromRow: (row: SpaceRow) => schema_d_exports$7.SpaceSchema.Info;
|
|
@@ -1451,7 +1492,7 @@ declare const archiveEnv: (env: string & import("effect/Brand").Brand<"SandboxIn
|
|
|
1451
1492
|
declare const layer$13: Layer.Layer<Service$13, never, io_d_exports.SandboxIO.Current | import("@codeworksh/plugin/sandbox/filesystem").Service | SqlClient.SqlClient>;
|
|
1452
1493
|
declare const layerWith$3: <E, RIn>(sandbox: Sandbox.Sandbox<E, RIn>) => Layer.Layer<Service$13, E, RIn | SqlClient.SqlClient>;
|
|
1453
1494
|
declare namespace worktree_d_exports {
|
|
1454
|
-
export { Entry$2 as Entry, Input$1 as Input, Interface$
|
|
1495
|
+
export { Entry$2 as Entry, Input$1 as Input, Interface$12 as Interface, Service$12 as Service, worktree_d_exports as Worktree, WorktreeError, defaultLayer$3 as defaultLayer, layer$12 as layer, layerWith$2 as layerWith };
|
|
1455
1496
|
}
|
|
1456
1497
|
declare const WorktreeError_base: Schema.Class<WorktreeError, Schema.TaggedStruct<"Worktree.WorktreeError", {
|
|
1457
1498
|
readonly operation: Schema.Literals<readonly ["add", "remove", "list"]>;
|
|
@@ -1470,7 +1511,7 @@ interface Input$1 {
|
|
|
1470
1511
|
readonly repo: schema_d_exports$5.RepoSchema.Info;
|
|
1471
1512
|
readonly directory: schema_d_exports$8.AbsolutePath;
|
|
1472
1513
|
}
|
|
1473
|
-
interface Interface$
|
|
1514
|
+
interface Interface$12 {
|
|
1474
1515
|
/** `git worktree list`, main checkout first. Never prunes (D-PRUNE). */
|
|
1475
1516
|
readonly list: (repo: schema_d_exports$5.RepoSchema.Info) => Effect.Effect<ReadonlyArray<Entry$2>, WorktreeError>;
|
|
1476
1517
|
/** Detached worktree at `directory` checked out at the repo's HEAD. */
|
|
@@ -1478,13 +1519,13 @@ interface Interface$11 {
|
|
|
1478
1519
|
/** Force-remove the worktree, then prune stale administrative entries. */
|
|
1479
1520
|
readonly remove: (input: Input$1) => Effect.Effect<void, WorktreeError>;
|
|
1480
1521
|
}
|
|
1481
|
-
declare const Service_base$10: Context.ServiceClass<Service$12, "@codeworksh/harness/worktree/worktree/Service", Interface$
|
|
1522
|
+
declare const Service_base$10: Context.ServiceClass<Service$12, "@codeworksh/harness/worktree/worktree/Service", Interface$12>;
|
|
1482
1523
|
declare class Service$12 extends Service_base$10 {}
|
|
1483
1524
|
declare const layer$12: Layer.Layer<Service$12, never, import("@codeworksh/plugin/sandbox/filesystem").Service | Service$15>;
|
|
1484
1525
|
declare const layerWith$2: <E, RIn>(sandbox: Sandbox.Sandbox<E, RIn>) => Layer.Layer<Service$12, E, RIn>;
|
|
1485
1526
|
declare const defaultLayer$3: (rootPath: string) => Layer.Layer<Service$12, never, never>;
|
|
1486
1527
|
declare namespace project_d_exports {
|
|
1487
|
-
export { Interface$
|
|
1528
|
+
export { Interface$11 as Interface, project_d_exports as Project, ProjectNotFoundError, ResolveOptions, Resolved$2 as Resolved, Service$11 as Service, defaultLayer$2 as defaultLayer, layer$11 as layer, layerWith$1 as layerWith, provisional, rename };
|
|
1488
1529
|
}
|
|
1489
1530
|
/** Deterministic, env-local id for a directory without a portable identity. Never written to a marker. */
|
|
1490
1531
|
declare const provisional: (env: instance_d_exports.SandboxInstance.ID, location: string) => schema_d_exports$9.ProjectSchema.ID;
|
|
@@ -1496,43 +1537,59 @@ interface Resolved$2 {
|
|
|
1496
1537
|
/** `space.kind ∈ { primary, plain }` */
|
|
1497
1538
|
readonly isDefault: boolean;
|
|
1498
1539
|
}
|
|
1499
|
-
interface
|
|
1500
|
-
|
|
1540
|
+
interface ResolveOptions {
|
|
1541
|
+
/**
|
|
1542
|
+
* Names the project when this resolution creates it, ahead of the repository's and the
|
|
1543
|
+
* folder's name. An existing project keeps its name; {@link rename} changes it.
|
|
1544
|
+
*/
|
|
1545
|
+
readonly name?: string;
|
|
1546
|
+
}
|
|
1547
|
+
interface Interface$11 {
|
|
1548
|
+
readonly resolveOrCreate: (cwd: schema_d_exports$8.AbsolutePath, options?: ResolveOptions) => Effect.Effect<Resolved$2, Error$1>;
|
|
1501
1549
|
readonly get: (id: schema_d_exports$9.ProjectSchema.ID) => Effect.Effect<Option.Option<schema_d_exports$9.ProjectSchema.Info>>;
|
|
1502
1550
|
readonly list: () => Effect.Effect<schema_d_exports$9.ProjectSchema.Info[]>;
|
|
1503
1551
|
}
|
|
1504
|
-
declare const Service_base$9: Context.ServiceClass<Service$11, "@codeworksh/harness/project/project/Service", Interface$
|
|
1552
|
+
declare const Service_base$9: Context.ServiceClass<Service$11, "@codeworksh/harness/project/project/Service", Interface$11>;
|
|
1505
1553
|
declare class Service$11 extends Service_base$9 {}
|
|
1506
1554
|
declare const layer$11: Layer.Layer<Service$11, never, io_d_exports.SandboxIO.Current | import("@codeworksh/plugin/sandbox/filesystem").Service | Service$13 | Service$14 | Service$12 | SqlClient.SqlClient>;
|
|
1555
|
+
declare const ProjectNotFoundError_base: Schema.Class<ProjectNotFoundError, Schema.TaggedStruct<"ProjectNotFoundError", {
|
|
1556
|
+
readonly projectId: Schema.String;
|
|
1557
|
+
}>, import("effect/Cause").YieldableError>;
|
|
1558
|
+
declare class ProjectNotFoundError extends ProjectNotFoundError_base {}
|
|
1559
|
+
/** Renames a project. Needs only the database, not a mount: a name is the same in every env. */
|
|
1560
|
+
declare const rename: (input: {
|
|
1561
|
+
readonly projectId: string;
|
|
1562
|
+
readonly name: string;
|
|
1563
|
+
}) => Effect.Effect<schema_d_exports$9.ProjectSchema.Info, ProjectNotFoundError, SqlClient.SqlClient>;
|
|
1507
1564
|
/** Takes an assembled sandbox — local or remote — not a local backend. */
|
|
1508
1565
|
declare const layerWith$1: <E, RIn>(sandbox: Sandbox.Sandbox<E, RIn>) => Layer.Layer<Service$11, E | import("effect/Config").ConfigError, Exclude<RIn, SqlClient.SqlClient | import("@effect/sql-sqlite-node/SqliteClient").SqliteClient>>;
|
|
1509
1566
|
declare const defaultLayer$2: (path: string) => Layer.Layer<Service$11, import("effect/Config").ConfigError, never>;
|
|
1510
1567
|
declare namespace location_d_exports {
|
|
1511
|
-
export { DirectoryNotFoundError, Error, Info$5 as Info, Interface$
|
|
1568
|
+
export { DirectoryNotFoundError, Error, Info$5 as Info, Interface$10 as Interface, location_d_exports as Location, NotDirectoryError, Service$10 as Service, layer$10 as layer, layerMounted };
|
|
1512
1569
|
}
|
|
1513
|
-
declare const layer$10: () => Layer.Layer<Service, import("@codeworksh/plugin/location").Error, io_d_exports.SandboxIO.Current | Service$11>;
|
|
1570
|
+
declare const layer$10: (options?: ResolveOptions) => Layer.Layer<Service, import("@codeworksh/plugin/location").Error, io_d_exports.SandboxIO.Current | Service$11>;
|
|
1514
1571
|
/**
|
|
1515
1572
|
* `layer` with the whole resolution stack (Project, Space, Repo, Worktree, Git)
|
|
1516
1573
|
* folded in. What remains is exactly the mount and the database — for callers
|
|
1517
1574
|
* that already hold both, such as the runner and `Session.create`.
|
|
1518
1575
|
*/
|
|
1519
|
-
declare const layerMounted: () => Layer.Layer<Service, import("@codeworksh/plugin/location").Error, io_d_exports.SandboxIO.Current | import("@codeworksh/plugin/sandbox/filesystem").Service | import("@codeworksh/plugin/sandbox/shell").Shell | import("effect/sql/SqlClient").SqlClient>;
|
|
1576
|
+
declare const layerMounted: (options?: ResolveOptions) => Layer.Layer<Service, import("@codeworksh/plugin/location").Error, io_d_exports.SandboxIO.Current | import("@codeworksh/plugin/sandbox/filesystem").Service | import("@codeworksh/plugin/sandbox/shell").Shell | import("effect/sql/SqlClient").SqlClient>;
|
|
1520
1577
|
declare namespace global_d_exports {
|
|
1521
|
-
export { global_d_exports as Global, Interface$
|
|
1578
|
+
export { global_d_exports as Global, Interface$9 as Interface, Service$9 as Service, app, appConfigDir, authFile, defaultLayer$1 as defaultLayer, homeConfig, layer$9 as layer, layerWith, make$4 as make, resolve$3 as resolve };
|
|
1522
1579
|
}
|
|
1523
1580
|
declare const appConfigDir = ".codework";
|
|
1524
1581
|
declare const app = "codework";
|
|
1525
1582
|
declare const homeConfig: Config.Config<string>;
|
|
1526
|
-
declare const Service_base$8: Context.ServiceClass<Service$9, "@codeworksh/harness/global/Service", Interface$
|
|
1583
|
+
declare const Service_base$8: Context.ServiceClass<Service$9, "@codeworksh/harness/global/Service", Interface$9>;
|
|
1527
1584
|
declare class Service$9 extends Service_base$8 {}
|
|
1528
|
-
interface Interface$
|
|
1585
|
+
interface Interface$9 {
|
|
1529
1586
|
readonly home: string;
|
|
1530
1587
|
readonly cache: string;
|
|
1531
1588
|
readonly data: string;
|
|
1532
1589
|
readonly log: string;
|
|
1533
1590
|
readonly bin: string;
|
|
1534
1591
|
}
|
|
1535
|
-
declare function make$
|
|
1592
|
+
declare function make$4(input?: Partial<Interface$9>): Interface$9;
|
|
1536
1593
|
/**
|
|
1537
1594
|
* Where a Codework home keeps its OAuth credentials, or undefined to let aikit
|
|
1538
1595
|
* resolve them (`CODEWORK_CREDENTIALS`, then the default home).
|
|
@@ -1543,13 +1600,13 @@ declare function make$3(input?: Partial<Interface$8>): Interface$8;
|
|
|
1543
1600
|
* would be invisible to the other.
|
|
1544
1601
|
*/
|
|
1545
1602
|
declare const authFile: (home: string | undefined) => string | undefined;
|
|
1546
|
-
declare const resolve$3: (input?: Partial<Interface$
|
|
1603
|
+
declare const resolve$3: (input?: Partial<Interface$9> | undefined) => Effect.Effect<Interface$9, Config.ConfigError, never>;
|
|
1547
1604
|
declare const layer$9: Layer.Layer<Service$9, Config.ConfigError, never>;
|
|
1548
1605
|
declare const defaultLayer$1: Layer.Layer<Service$9, Config.ConfigError, never>;
|
|
1549
|
-
declare const layerWith: (input: Partial<Interface$
|
|
1606
|
+
declare const layerWith: (input: Partial<Interface$9>) => Layer.Layer<Service$9, Config.ConfigError, never>;
|
|
1550
1607
|
import * as import__codeworksh_plugin_settings from "@codeworksh/plugin/settings";
|
|
1551
1608
|
declare namespace settings_d_exports {
|
|
1552
|
-
export { Interface$
|
|
1609
|
+
export { Interface$8 as Interface, Options$4 as Options, Service$8 as Service, settings_d_exports as Settings, SettingsError, schema_d_exports$4.defaults as defaults, layer$8 as layer, load$1 as load, modules, parse$1 as parse, paths, projectRoot, userConfigDir };
|
|
1553
1610
|
}
|
|
1554
1611
|
interface Options$4 {
|
|
1555
1612
|
/**
|
|
@@ -1736,6 +1793,7 @@ declare const parse$1: (path: string, source: string) => Effect.Effect<{
|
|
|
1736
1793
|
supportsOpenAIGrammarTools?: boolean;
|
|
1737
1794
|
supportsThinkingTokenBudget?: boolean;
|
|
1738
1795
|
forceAdaptiveThinking?: boolean;
|
|
1796
|
+
supportsTemperature?: boolean;
|
|
1739
1797
|
thinkingTokenBudgetField?: string;
|
|
1740
1798
|
};
|
|
1741
1799
|
contextWindow: number;
|
|
@@ -1808,7 +1866,7 @@ declare const parse$1: (path: string, source: string) => Effect.Effect<{
|
|
|
1808
1866
|
readonly maxDelayMs?: number | undefined;
|
|
1809
1867
|
} | undefined;
|
|
1810
1868
|
}, SettingsError, never>;
|
|
1811
|
-
interface Interface$
|
|
1869
|
+
interface Interface$8 {
|
|
1812
1870
|
/**
|
|
1813
1871
|
* Await fresh host files at each exchange. No cache, mutation, or reload API. Fails when a
|
|
1814
1872
|
* file exists and cannot be used, including on an edit made mid-session.
|
|
@@ -1820,7 +1878,7 @@ interface Interface$7 {
|
|
|
1820
1878
|
*/
|
|
1821
1879
|
readonly load: (hostDir: string | undefined) => Effect.Effect<schema_d_exports$4.Info, SettingsError>;
|
|
1822
1880
|
}
|
|
1823
|
-
declare const Service_base$7: Context.ServiceClass<Service$8, "@codeworksh/harness/settings/settings/Service", Interface$
|
|
1881
|
+
declare const Service_base$7: Context.ServiceClass<Service$8, "@codeworksh/harness/settings/settings/Service", Interface$8>;
|
|
1824
1882
|
declare class Service$8 extends Service_base$7 {}
|
|
1825
1883
|
/**
|
|
1826
1884
|
* One read of every layer. Exported for the harness constructor, which needs the plugin
|
|
@@ -1948,21 +2006,21 @@ declare const modules: (declared: ReadonlyArray<schema_d_exports$4.Declared>) =>
|
|
|
1948
2006
|
declare const layer$8: (options?: Omit<Options$4, "hostDir">) => Layer.Layer<Service$8, never, Service$9>;
|
|
1949
2007
|
import * as import__codeworksh_plugin_plugin from "@codeworksh/plugin/plugin";
|
|
1950
2008
|
declare namespace registry_d_exports {
|
|
1951
|
-
export { EventRegistrationError, registry_d_exports as EventRegistry, Interface$
|
|
2009
|
+
export { EventRegistrationError, registry_d_exports as EventRegistry, Interface$7 as Interface, Service$7 as Service, flatten, layer$7 as layer };
|
|
1952
2010
|
}
|
|
1953
2011
|
/**
|
|
1954
2012
|
* Every event definition this harness knows: the kernel's, plus whatever the
|
|
1955
2013
|
* configured plugins registered. A validated replacement lands with each new
|
|
1956
2014
|
* plugin generation; published events retain the schema they were encoded with.
|
|
1957
2015
|
*/
|
|
1958
|
-
interface Interface$
|
|
2016
|
+
interface Interface$7 {
|
|
1959
2017
|
readonly definitions: ReadonlyArray<schema_d_exports$10.EventSchema.Definition>;
|
|
1960
2018
|
/** The latest definition for a type, or `undefined` when nothing declares it. */
|
|
1961
2019
|
readonly get: (type: string) => schema_d_exports$10.EventSchema.Definition | undefined;
|
|
1962
2020
|
/** Validate and atomically replace the definitions for a newly loaded plugin pool. */
|
|
1963
2021
|
readonly replace: (plugins: ReadonlyArray<plugin_d_exports.Plugin>) => Effect.Effect<void, EventRegistrationError>;
|
|
1964
2022
|
}
|
|
1965
|
-
declare const Service_base$6: Context.ServiceClass<Service$7, "@codeworksh/harness/event/registry/Service", Interface$
|
|
2023
|
+
declare const Service_base$6: Context.ServiceClass<Service$7, "@codeworksh/harness/event/registry/Service", Interface$7>;
|
|
1966
2024
|
declare class Service$7 extends Service_base$6 {}
|
|
1967
2025
|
declare const EventRegistrationError_base: Schema.Class<EventRegistrationError, Schema.TaggedStruct<"EventRegistrationError", {
|
|
1968
2026
|
readonly pluginId: Schema.String;
|
|
@@ -2192,7 +2250,7 @@ interface Origin {
|
|
|
2192
2250
|
readonly file?: string;
|
|
2193
2251
|
}
|
|
2194
2252
|
declare namespace runtime_d_exports {
|
|
2195
|
-
export { Bindings, Interface$
|
|
2253
|
+
export { Bindings, Interface$6 as Interface, Service$6 as Service, runtime_d_exports as SessionRuntime, layer$6 as layer };
|
|
2196
2254
|
}
|
|
2197
2255
|
/**
|
|
2198
2256
|
* Per-session configuration, held in process.
|
|
@@ -2202,20 +2260,20 @@ declare namespace runtime_d_exports {
|
|
|
2202
2260
|
* thinking level are not held here: they are the session's durable `SessionSchema.Config`.
|
|
2203
2261
|
*/
|
|
2204
2262
|
type Bindings = Options$2;
|
|
2205
|
-
interface Interface$
|
|
2263
|
+
interface Interface$6 {
|
|
2206
2264
|
readonly get: (sessionId: ID$1) => Effect.Effect<Option.Option<Bindings>>;
|
|
2207
2265
|
readonly set: (sessionId: ID$1, bindings: Bindings) => Effect.Effect<void>;
|
|
2208
2266
|
readonly update: (sessionId: ID$1, patch: Bindings) => Effect.Effect<void>;
|
|
2209
2267
|
readonly remove: (sessionId: ID$1) => Effect.Effect<void>;
|
|
2210
2268
|
}
|
|
2211
|
-
declare const Service_base$5: Context.ServiceClass<Service$6, "@codeworksh/harness/session/runtime/Service", Interface$
|
|
2269
|
+
declare const Service_base$5: Context.ServiceClass<Service$6, "@codeworksh/harness/session/runtime/Service", Interface$6>;
|
|
2212
2270
|
declare class Service$6 extends Service_base$5 {}
|
|
2213
2271
|
declare const layer$6: Layer.Layer<Service$6, never, never>;
|
|
2214
2272
|
import * as import__codeworksh_plugin_plugin_tool from "@codeworksh/plugin/plugin/tool";
|
|
2215
2273
|
import * as import__codeworksh_plugin_tool_progress from "@codeworksh/plugin/tool/progress";
|
|
2216
2274
|
import * as import__codeworksh_plugin_tool from "@codeworksh/plugin/tool";
|
|
2217
2275
|
declare namespace executor_d_exports {
|
|
2218
|
-
export { Executor, HandleOptions, ProgressEvent, ToolOutcome, make$
|
|
2276
|
+
export { Executor, HandleOptions, ProgressEvent, ToolOutcome, make$3 as make };
|
|
2219
2277
|
}
|
|
2220
2278
|
/**
|
|
2221
2279
|
* `ToolExecutor` — the uniform pipeline run for every tool call:
|
|
@@ -2279,7 +2337,7 @@ interface Executor {
|
|
|
2279
2337
|
* already discharged at registration (`Tool.provide`). The executor therefore needs no tool
|
|
2280
2338
|
* `R`; only a progress sink's `RProgress` (if any) surfaces from `handle`.
|
|
2281
2339
|
*/
|
|
2282
|
-
declare const make$
|
|
2340
|
+
declare const make$3: (tools: ReadonlyArray<tool_d_exports.RegisteredTool | schema_d_exports$3.ToolRegistration>) => Executor;
|
|
2283
2341
|
//#endregion
|
|
2284
2342
|
//#region src/tool/registry.d.ts
|
|
2285
2343
|
/**
|
|
@@ -2312,7 +2370,7 @@ interface Resolved$1 {
|
|
|
2312
2370
|
readonly handle: Executor["handle"];
|
|
2313
2371
|
}
|
|
2314
2372
|
declare namespace state_d_exports {
|
|
2315
|
-
export { Configuration, Interface$
|
|
2373
|
+
export { Configuration, Interface$5 as Interface, Options$2 as Options, Reloaded, RequestOptions, Service$5 as Service, Snapshot$1 as Snapshot, SnapshotError, state_d_exports as State, ToolExecutionMode, layer$5 as layer };
|
|
2316
2374
|
}
|
|
2317
2375
|
/**
|
|
2318
2376
|
* How a turn's tool calls are scheduled once the array has been re-read.
|
|
@@ -2409,7 +2467,7 @@ interface Reloaded {
|
|
|
2409
2467
|
/** Why the swap did not happen. The previous set is still the one in use. */
|
|
2410
2468
|
readonly failure?: string;
|
|
2411
2469
|
}
|
|
2412
|
-
interface Interface$
|
|
2470
|
+
interface Interface$5 {
|
|
2413
2471
|
/**
|
|
2414
2472
|
* Re-import every configured plugin, and swap the loaded set if it works.
|
|
2415
2473
|
*
|
|
@@ -2442,7 +2500,7 @@ interface Interface$4 {
|
|
|
2442
2500
|
*/
|
|
2443
2501
|
readonly snapshot: (sessionId: ID$1) => Effect.Effect<Snapshot$1, SnapshotError | SettingsError | ModelCatalogError | ModelNotFoundError | ProviderError, io_d_exports.SandboxIO.Provides | Service$10>;
|
|
2444
2502
|
}
|
|
2445
|
-
declare const Service_base$4: Context.ServiceClass<Service$5, "@codeworksh/harness/state/state/Service", Interface$
|
|
2503
|
+
declare const Service_base$4: Context.ServiceClass<Service$5, "@codeworksh/harness/state/state/Service", Interface$5>;
|
|
2446
2504
|
declare class Service$5 extends Service_base$4 {}
|
|
2447
2505
|
/**
|
|
2448
2506
|
* `pool` is the loaded module set, behind a `Ref` rather than a frozen array.
|
|
@@ -2491,7 +2549,7 @@ rebuild: (root: string | undefined, current: Pool) => Effect.Effect<Pool, {
|
|
|
2491
2549
|
/** The view a session in `hostDir` runs from: its project root, or the process view. */
|
|
2492
2550
|
viewOf?: (hostDir: string | undefined) => Effect.Effect<string | undefined>) => Layer.Layer<Service$5, never, Service$9 | Service$8 | Service$17 | Service$16 | Service$7 | Service$6>;
|
|
2493
2551
|
declare namespace run_d_exports {
|
|
2494
|
-
export { Interface$
|
|
2552
|
+
export { Interface$4 as Interface, LLMStreamError, ModelCatalogError, ModelNotFoundError, ProviderAuthenticationError, ProviderAuthorizationError, ProviderConfigurationError, ProviderContentPolicyError, ProviderError, ProviderFailureReason, ProviderInvalidRequestError, ProviderInvalidResponseError, ProviderModelUnavailableError, ProviderQuotaError, ProviderRateLimitError, ProviderTimeoutError, ProviderTransportError, ProviderUnavailableError, ProviderUnknownError, RunError, run_d_exports as Runner, SandboxDirectoryNotFoundError, Service$4 as Service };
|
|
2495
2553
|
}
|
|
2496
2554
|
declare const SandboxDirectoryNotFoundError_base: Schema.Class<SandboxDirectoryNotFoundError, Schema.TaggedStruct<"Runner.SandboxDirectoryNotFoundError", {
|
|
2497
2555
|
readonly sessionId: Schema.String;
|
|
@@ -2637,7 +2695,7 @@ declare class ProviderError extends ProviderError_base {
|
|
|
2637
2695
|
}
|
|
2638
2696
|
declare const ModelCatalogError_base: Schema.Class<ModelCatalogError, Schema.TaggedStruct<"Runner.ModelCatalogError", {
|
|
2639
2697
|
readonly path: Schema.String;
|
|
2640
|
-
readonly reason: Schema.Literals<readonly ["
|
|
2698
|
+
readonly reason: Schema.Literals<readonly ["unreadable", "empty", "invalid"]>;
|
|
2641
2699
|
readonly detail: Schema.String;
|
|
2642
2700
|
}>, import("effect/Cause").YieldableError>;
|
|
2643
2701
|
declare class ModelCatalogError extends ModelCatalogError_base {
|
|
@@ -2658,23 +2716,31 @@ declare class LLMStreamError extends LLMStreamError_base {
|
|
|
2658
2716
|
get message(): string;
|
|
2659
2717
|
}
|
|
2660
2718
|
type RunError = ModelCatalogError | ModelNotFoundError | ProviderError | LLMStreamError | ContextDecodeError | ContextEncodeError | SessionNotFoundError | SessionLinkedSpaceNotFoundError | SettingsError | SnapshotError | SandboxDirectoryNotFoundError | errors_d_exports.SandboxMountError | filesystem_d_exports.SandboxFileSystem.FileSystemError;
|
|
2661
|
-
interface Interface$
|
|
2719
|
+
interface Interface$4 {
|
|
2662
2720
|
/** Drains eligible durable work. Explicit runs perform one provider attempt even when no work is eligible. */
|
|
2663
2721
|
readonly run: (input: {
|
|
2664
2722
|
readonly sessionId: ID$1;
|
|
2665
2723
|
readonly force: boolean;
|
|
2724
|
+
/** Resuming a run a previous process left unfinished: its cut-off reply is answered first. */
|
|
2725
|
+
readonly recovered?: boolean;
|
|
2666
2726
|
}) => Effect.Effect<void, RunError, io_d_exports.SandboxIO.Provides | Service$10>;
|
|
2667
2727
|
}
|
|
2668
|
-
declare const Service_base$3: Context.ServiceClass<Service$4, "@codeworksh/harness/runner/run/Service", Interface$
|
|
2728
|
+
declare const Service_base$3: Context.ServiceClass<Service$4, "@codeworksh/harness/runner/run/Service", Interface$4>;
|
|
2669
2729
|
declare class Service$4 extends Service_base$3 {}
|
|
2670
2730
|
declare namespace execution_d_exports {
|
|
2671
|
-
export { Interface$
|
|
2731
|
+
export { Interface$3 as Interface, execution_d_exports as RunnerExecution, Service$3 as Service, noopLayer };
|
|
2672
2732
|
}
|
|
2673
|
-
interface Interface$
|
|
2733
|
+
interface Interface$3 {
|
|
2674
2734
|
/** Snapshots active execution owned by this process. */
|
|
2675
2735
|
readonly active: Effect.Effect<ReadonlySet<ID$1>>;
|
|
2676
2736
|
/** Starts execution while idle or joins the active execution. */
|
|
2677
2737
|
readonly resume: (sessionId: ID$1) => Effect.Effect<void, RunError>;
|
|
2738
|
+
/**
|
|
2739
|
+
* Resumes a run the last process left unfinished. Like `resume`, except that it marks nothing,
|
|
2740
|
+
* and runs nothing when the session is no longer marked as it begins: a stop that landed since
|
|
2741
|
+
* recovery chose the session stands.
|
|
2742
|
+
*/
|
|
2743
|
+
readonly recover: (sessionId: ID$1) => Effect.Effect<void, RunError>;
|
|
2678
2744
|
/** Registers newly recorded work. Repeated wakeups may coalesce. */
|
|
2679
2745
|
readonly wake: (sessionId: ID$1) => Effect.Effect<void>;
|
|
2680
2746
|
/**
|
|
@@ -2687,7 +2753,7 @@ interface Interface$2 {
|
|
|
2687
2753
|
/** Waits until this process owns no execution for the session. */
|
|
2688
2754
|
readonly awaitIdle: (sessionId: ID$1) => Effect.Effect<void>;
|
|
2689
2755
|
}
|
|
2690
|
-
declare const Service_base$2: Context.ServiceClass<Service$3, "@codeworksh/harness/runner/execution/Service", Interface$
|
|
2756
|
+
declare const Service_base$2: Context.ServiceClass<Service$3, "@codeworksh/harness/runner/execution/Service", Interface$3>;
|
|
2691
2757
|
declare class Service$3 extends Service_base$2 {}
|
|
2692
2758
|
declare const noopLayer: Layer.Layer<Service$3, never, never>;
|
|
2693
2759
|
declare namespace assemble_d_exports {
|
|
@@ -3367,15 +3433,18 @@ declare const decodeMessage: (hydrated: HydratedEntry) => Effect.Effect<{
|
|
|
3367
3433
|
messageId: string;
|
|
3368
3434
|
}, ContextDecodeError, never>;
|
|
3369
3435
|
declare namespace context_d_exports {
|
|
3370
|
-
export { context_d_exports as Context, assemble_d_exports as ContextAssembly, codec_d_exports as ContextCodec, ContextDecodeError, ContextEncodeError, ContextInvariantError, ContextReadError, EncodedMessage, Interface$
|
|
3436
|
+
export { context_d_exports as Context, assemble_d_exports as ContextAssembly, codec_d_exports as ContextCodec, ContextDecodeError, ContextEncodeError, ContextInvariantError, ContextReadError, EncodedMessage, Interface$2 as Interface, Service$2 as Service, Snapshot, assemblePath, decodeMessage, decodeSyntheticMessage, encodeMessage, encodePart, layer$4 as layer, validateUserMessage };
|
|
3371
3437
|
}
|
|
3372
3438
|
type ContextReadError = SessionNotFoundError | ContextDecodeError;
|
|
3373
|
-
interface Interface$
|
|
3439
|
+
interface Interface$2 {
|
|
3374
3440
|
readonly assemble: (sessionId: ID$1) => Effect.Effect<Snapshot, ContextReadError>;
|
|
3375
3441
|
}
|
|
3376
|
-
declare const Service_base$1: Context.ServiceClass<Service$2, "@codeworksh/harness/context/context/Service", Interface$
|
|
3442
|
+
declare const Service_base$1: Context.ServiceClass<Service$2, "@codeworksh/harness/context/context/Service", Interface$2>;
|
|
3377
3443
|
declare class Service$2 extends Service_base$1 {}
|
|
3378
3444
|
declare const layer$4: Layer.Layer<Service$2, never, Service$16>;
|
|
3445
|
+
declare namespace schema_d_exports$2 {
|
|
3446
|
+
export { ID, schema_d_exports$2 as SessionMessageSchema };
|
|
3447
|
+
}
|
|
3379
3448
|
//#endregion
|
|
3380
3449
|
//#region src/session/input/schema.d.ts
|
|
3381
3450
|
declare const Admitted: Schema.Struct<{
|
|
@@ -3423,13 +3492,128 @@ declare const Admitted: Schema.Struct<{
|
|
|
3423
3492
|
readonly delivery: Schema.Literals<readonly ["steer", "followUp"]>;
|
|
3424
3493
|
readonly timeCreated: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
3425
3494
|
readonly promotedSeq: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
3495
|
+
readonly cancelledSeq: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
3426
3496
|
}>;
|
|
3427
3497
|
interface Admitted extends Schema.Schema.Type<typeof Admitted> {}
|
|
3428
|
-
declare namespace
|
|
3429
|
-
export {
|
|
3498
|
+
declare namespace input_d_exports {
|
|
3499
|
+
export { AdmitInput, Interface$1 as Interface, LifecycleConflict, ProjectAdmittedInput, ProjectCancelledInput, ProjectPromptedInput, ProjectUpdatedInput, input_d_exports as SessionInput, UpdatePatch, equivalent, make$2 as make };
|
|
3500
|
+
}
|
|
3501
|
+
declare const LifecycleConflict_base: Schema.Class<LifecycleConflict, Schema.TaggedStruct<"SessionInput.LifecycleConflict", {
|
|
3502
|
+
readonly id: Schema.brand<Schema.String, "Message.ID"> & {
|
|
3503
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
3504
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
3505
|
+
};
|
|
3506
|
+
}>, import("effect/Cause").YieldableError>;
|
|
3507
|
+
/**
|
|
3508
|
+
* Raised when a durable input is already past the lifecycle point being
|
|
3509
|
+
* projected -- a second admission of the same id, or a second promotion.
|
|
3510
|
+
*
|
|
3511
|
+
* It is a defect, not an error: projectors run inside the event commit, so
|
|
3512
|
+
* raising it rolls the event back and leaves the store untouched. `admit` and
|
|
3513
|
+
* `promote*` then recover by reading the row that won.
|
|
3514
|
+
*/
|
|
3515
|
+
declare class LifecycleConflict extends LifecycleConflict_base {}
|
|
3516
|
+
/**
|
|
3517
|
+
* Whether a stored input carries the prompt the caller believes it admitted.
|
|
3518
|
+
* A retry that reuses an id with different content is a conflict, not an
|
|
3519
|
+
* idempotent replay.
|
|
3520
|
+
*/
|
|
3521
|
+
declare const equivalent: (input: Admitted, expected: {
|
|
3522
|
+
readonly sessionId: ID$1;
|
|
3523
|
+
readonly prompt: Prompt;
|
|
3524
|
+
readonly delivery: Delivery;
|
|
3525
|
+
}) => boolean;
|
|
3526
|
+
interface AdmitInput {
|
|
3527
|
+
readonly id: ID;
|
|
3528
|
+
readonly sessionId: ID$1;
|
|
3529
|
+
readonly prompt: Prompt;
|
|
3530
|
+
readonly delivery: Delivery;
|
|
3531
|
+
}
|
|
3532
|
+
interface ProjectAdmittedInput extends AdmitInput {
|
|
3533
|
+
readonly admittedSeq: number;
|
|
3534
|
+
readonly timeCreated: DateTime.Utc;
|
|
3535
|
+
}
|
|
3536
|
+
interface ProjectCancelledInput {
|
|
3537
|
+
readonly id: ID;
|
|
3538
|
+
readonly sessionId: ID$1;
|
|
3539
|
+
readonly cancelledSeq: number;
|
|
3540
|
+
}
|
|
3541
|
+
interface ProjectUpdatedInput {
|
|
3542
|
+
readonly id: ID;
|
|
3543
|
+
readonly sessionId: ID$1;
|
|
3544
|
+
readonly prompt?: Prompt | undefined;
|
|
3545
|
+
readonly delivery?: Delivery | undefined;
|
|
3546
|
+
}
|
|
3547
|
+
/** What `update` changes; an absent field stays as it is. */
|
|
3548
|
+
interface UpdatePatch {
|
|
3549
|
+
readonly prompt?: Prompt;
|
|
3550
|
+
readonly delivery?: Delivery;
|
|
3551
|
+
}
|
|
3552
|
+
interface ProjectPromptedInput extends AdmitInput {
|
|
3553
|
+
readonly promotedSeq: number;
|
|
3554
|
+
readonly timeCreated: DateTime.Utc;
|
|
3555
|
+
}
|
|
3556
|
+
interface Interface$1 {
|
|
3557
|
+
readonly find: (id: ID) => Effect.Effect<Option.Option<Admitted>>;
|
|
3558
|
+
/** Records a prompt durably. Re-admitting the same id returns the stored row. */
|
|
3559
|
+
readonly admit: (input: AdmitInput) => Effect.Effect<Admitted>;
|
|
3560
|
+
/** Projector for `PromptAdmitted`. Runs inside the event commit. */
|
|
3561
|
+
readonly projectAdmitted: (input: ProjectAdmittedInput) => Effect.Effect<void>;
|
|
3562
|
+
/** Projector for `Prompted`. Runs inside the event commit. */
|
|
3563
|
+
readonly projectPrompted: (input: ProjectPromptedInput) => Effect.Effect<void>;
|
|
3564
|
+
/** Projector for `PromptCancelled`. Runs inside the event commit. */
|
|
3565
|
+
readonly projectCancelled: (input: ProjectCancelledInput) => Effect.Effect<void>;
|
|
3566
|
+
/** Projector for `PromptUpdated`. Runs inside the event commit. */
|
|
3567
|
+
readonly projectUpdated: (input: ProjectUpdatedInput) => Effect.Effect<void>;
|
|
3568
|
+
/**
|
|
3569
|
+
* Moves a pending input to the other lane, or rewrites it, keeping its place in admission
|
|
3570
|
+
* order. The stored input after the change, or none when it was promoted, cancelled, or unknown.
|
|
3571
|
+
*/
|
|
3572
|
+
readonly update: (sessionId: ID$1, id: ID, patch: UpdatePatch) => Effect.Effect<Option.Option<Admitted>>;
|
|
3573
|
+
/**
|
|
3574
|
+
* Withdraws a pending input of the session. False when there is none by that id, or it was
|
|
3575
|
+
* promoted or cancelled first: a cancel that loses to promotion leaves the prompt in the
|
|
3576
|
+
* conversation.
|
|
3577
|
+
*/
|
|
3578
|
+
readonly cancel: (sessionId: ID$1, id: ID) => Effect.Effect<boolean>;
|
|
3579
|
+
/** Inputs not promoted yet, both lanes, in admission order. */
|
|
3580
|
+
readonly pending: (sessionId: ID$1) => Effect.Effect<ReadonlyArray<Admitted>>;
|
|
3581
|
+
/** Whether the lane holds an input that has not been promoted yet. */
|
|
3582
|
+
readonly hasPending: (sessionId: ID$1, delivery: Delivery) => Effect.Effect<boolean>;
|
|
3583
|
+
/**
|
|
3584
|
+
* Promotes every pending steer admitted at or before `cutoff`, in admission
|
|
3585
|
+
* order. The cutoff keeps a steer that lands mid-promotion out of a request
|
|
3586
|
+
* that is already being assembled.
|
|
3587
|
+
*
|
|
3588
|
+
* Counts promotions *this* caller won. A row another drainer promoted first
|
|
3589
|
+
* is not counted: callers treat a positive count as new work to answer, and
|
|
3590
|
+
* counting a promotion someone else committed would have two workers answer
|
|
3591
|
+
* one prompt.
|
|
3592
|
+
*/
|
|
3593
|
+
readonly promoteSteers: (sessionId: ID$1, cutoff: number) => Effect.Effect<number>;
|
|
3594
|
+
/**
|
|
3595
|
+
* Promotes the single oldest pending follow-up, if any. One per run, unlike
|
|
3596
|
+
* steers, which is what makes the follow-up lane strictly turn-at-a-time.
|
|
3597
|
+
* False when there was none, or when another caller promoted it first.
|
|
3598
|
+
*/
|
|
3599
|
+
readonly promoteFollowUp: (sessionId: ID$1) => Effect.Effect<boolean>;
|
|
3430
3600
|
}
|
|
3601
|
+
declare const make$2: Effect.Effect<{
|
|
3602
|
+
find: (id: string & import("effect/Brand").Brand<"Message.ID">) => Effect.Effect<Option.Option<Admitted>, never, never>;
|
|
3603
|
+
admit: (input: AdmitInput) => Effect.Effect<Admitted, never, never>;
|
|
3604
|
+
projectAdmitted: (input: ProjectAdmittedInput) => Effect.Effect<undefined, never, never>;
|
|
3605
|
+
projectPrompted: (input: ProjectPromptedInput) => Effect.Effect<undefined, never, never>;
|
|
3606
|
+
projectCancelled: (input: ProjectCancelledInput) => Effect.Effect<undefined, never, never>;
|
|
3607
|
+
projectUpdated: (input: ProjectUpdatedInput) => Effect.Effect<undefined, never, never>;
|
|
3608
|
+
update: (sessionId: string & import("effect/Brand").Brand<"Session.ID">, id: string & import("effect/Brand").Brand<"Message.ID">, patch: UpdatePatch) => Effect.Effect<Option.Option<Admitted>, never, never>;
|
|
3609
|
+
cancel: (sessionId: string & import("effect/Brand").Brand<"Session.ID">, id: string & import("effect/Brand").Brand<"Message.ID">) => Effect.Effect<boolean, never, never>;
|
|
3610
|
+
pending: (sessionId: string & import("effect/Brand").Brand<"Session.ID">) => Effect.Effect<Admitted[], never, never>;
|
|
3611
|
+
hasPending: (sessionId: string & import("effect/Brand").Brand<"Session.ID">, delivery: "followUp" | "steer") => Effect.Effect<boolean, never, never>;
|
|
3612
|
+
promoteSteers: (sessionId: string & import("effect/Brand").Brand<"Session.ID">, cutoff: number) => Effect.Effect<number, never, never>;
|
|
3613
|
+
promoteFollowUp: (sessionId: string & import("effect/Brand").Brand<"Session.ID">) => Effect.Effect<boolean, never, never>;
|
|
3614
|
+
}, never, Service$17 | SqlClient.SqlClient>;
|
|
3431
3615
|
declare namespace control_d_exports {
|
|
3432
|
-
export { control_d_exports as Control, Interface, PromptConflictError, PromptInput$1 as PromptInput, Service$1 as Service, layer$3 as layer };
|
|
3616
|
+
export { control_d_exports as Control, Interface, PromptConflictError, PromptInput$1 as PromptInput, RESTART_LIMIT, Service$1 as Service, layer$3 as layer };
|
|
3433
3617
|
}
|
|
3434
3618
|
declare const PromptConflictError_base: Schema.Class<PromptConflictError, Schema.TaggedStruct<"PromptConflictError", {
|
|
3435
3619
|
readonly sessionId: Schema.String;
|
|
@@ -3449,6 +3633,11 @@ interface PromptInput$1 {
|
|
|
3449
3633
|
/** Defaults to "steer": join the running turn rather than waiting for the next. */
|
|
3450
3634
|
readonly delivery?: Delivery;
|
|
3451
3635
|
}
|
|
3636
|
+
/**
|
|
3637
|
+
* Times a run may be cut off by a dying process before the session is parked instead of resumed.
|
|
3638
|
+
* A committed turn starts the count over.
|
|
3639
|
+
*/
|
|
3640
|
+
declare const RESTART_LIMIT = 5;
|
|
3452
3641
|
interface Interface {
|
|
3453
3642
|
/**
|
|
3454
3643
|
* Records a prompt in the session's durable inbox, then wakes its drain.
|
|
@@ -3478,6 +3667,22 @@ interface Interface {
|
|
|
3478
3667
|
}) => Effect.Effect<boolean>;
|
|
3479
3668
|
/** Sessions this process is currently draining. */
|
|
3480
3669
|
readonly active: Effect.Effect<ReadonlySet<ID$1>>;
|
|
3670
|
+
/**
|
|
3671
|
+
* Resumes the runs the last process left unfinished, as the server starts. One a crash cut off
|
|
3672
|
+
* counts a restart, one a shutdown closed does not; at {@link RESTART_LIMIT} the session is parked
|
|
3673
|
+
* and waits for its next prompt. Resolves once every resumed run has settled.
|
|
3674
|
+
*/
|
|
3675
|
+
readonly resumeUnfinished: Effect.Effect<void>;
|
|
3676
|
+
/** Prompts admitted but not yet in the conversation, steers and follow-ups, in admission order. */
|
|
3677
|
+
readonly pending: (sessionId: ID$1) => Effect.Effect<ReadonlyArray<Admitted>>;
|
|
3678
|
+
/**
|
|
3679
|
+
* Moves a pending prompt to the other lane or rewrites it, keeping its place; false when it was
|
|
3680
|
+
* already promoted, cancelled, or is unknown. Asking for the steer lane also wakes the session, so
|
|
3681
|
+
* a prompt left waiting by a stop or a failure runs now.
|
|
3682
|
+
*/
|
|
3683
|
+
readonly update: (sessionId: ID$1, id: ID, patch: UpdatePatch) => Effect.Effect<boolean>;
|
|
3684
|
+
/** Withdraws a pending prompt; false when it was already promoted, cancelled, or is unknown. */
|
|
3685
|
+
readonly cancel: (sessionId: ID$1, id: ID) => Effect.Effect<boolean>;
|
|
3481
3686
|
}
|
|
3482
3687
|
declare const Service_base: Context.ServiceClass<Service$1, "@codeworksh/harness/control/Service", Interface>;
|
|
3483
3688
|
declare class Service$1 extends Service_base {}
|
|
@@ -3546,6 +3751,7 @@ declare const models: Effect.Effect<Partial<Record<string, Record<string, {
|
|
|
3546
3751
|
supportsOpenAIGrammarTools?: boolean;
|
|
3547
3752
|
supportsThinkingTokenBudget?: boolean;
|
|
3548
3753
|
forceAdaptiveThinking?: boolean;
|
|
3754
|
+
supportsTemperature?: boolean;
|
|
3549
3755
|
thinkingTokenBudgetField?: string;
|
|
3550
3756
|
};
|
|
3551
3757
|
contextWindow: number;
|
|
@@ -3653,6 +3859,7 @@ declare const effective: (declared: readonly schema_d_exports$4.DeclaredModel[])
|
|
|
3653
3859
|
supportsOpenAIGrammarTools?: boolean;
|
|
3654
3860
|
supportsThinkingTokenBudget?: boolean;
|
|
3655
3861
|
forceAdaptiveThinking?: boolean;
|
|
3862
|
+
supportsTemperature?: boolean;
|
|
3656
3863
|
thinkingTokenBudgetField?: string;
|
|
3657
3864
|
};
|
|
3658
3865
|
contextWindow: number;
|
|
@@ -3997,6 +4204,10 @@ interface CreateInput extends RuntimeInput {
|
|
|
3997
4204
|
* own directory. {@link link} assigns one afterwards.
|
|
3998
4205
|
*/
|
|
3999
4206
|
readonly hostDir?: string;
|
|
4207
|
+
/** Names the session's project if this creates it; an existing project keeps its name. */
|
|
4208
|
+
readonly project?: {
|
|
4209
|
+
readonly name: string;
|
|
4210
|
+
};
|
|
4000
4211
|
}
|
|
4001
4212
|
interface AttachInput extends RuntimeInput {
|
|
4002
4213
|
readonly sessionId: ID$1;
|
|
@@ -4029,6 +4240,25 @@ interface Info$1 {
|
|
|
4029
4240
|
*/
|
|
4030
4241
|
readonly hasHostLink: boolean;
|
|
4031
4242
|
readonly sandbox?: Info$2;
|
|
4243
|
+
/** Absent only when the session's space or project row is missing. */
|
|
4244
|
+
readonly project?: {
|
|
4245
|
+
readonly id: schema_d_exports$9.ProjectSchema.ID;
|
|
4246
|
+
readonly name: string;
|
|
4247
|
+
};
|
|
4248
|
+
/** Last activity, epoch milliseconds: every appended entry moves it. */
|
|
4249
|
+
readonly updatedAt: number;
|
|
4250
|
+
/** The model chosen for this session over settings; absent when settings decide. */
|
|
4251
|
+
readonly model?: {
|
|
4252
|
+
readonly provider: string;
|
|
4253
|
+
readonly id: string;
|
|
4254
|
+
};
|
|
4255
|
+
/** The thinking level chosen for this session over settings; absent when settings decide. */
|
|
4256
|
+
readonly thinkingLevel?: Model.ThinkingLevel;
|
|
4257
|
+
/**
|
|
4258
|
+
* Its unfinished run was cut off {@link Control.RESTART_LIMIT} times, so the server no longer
|
|
4259
|
+
* resumes it; the next prompt runs it again.
|
|
4260
|
+
*/
|
|
4261
|
+
readonly parked: boolean;
|
|
4032
4262
|
}
|
|
4033
4263
|
interface Handle {
|
|
4034
4264
|
readonly id: ID$1;
|
|
@@ -4054,6 +4284,17 @@ declare const create$1: (input?: CreateInput | undefined) => Effect.Effect<{
|
|
|
4054
4284
|
hostDir?: string & import("effect/Brand").Brand<"AbsolutePath">;
|
|
4055
4285
|
hasHostLink: boolean;
|
|
4056
4286
|
sandbox?: instance_d_exports.SandboxInstance.Info;
|
|
4287
|
+
project?: {
|
|
4288
|
+
id: string & import("effect/Brand").Brand<"Project.ID">;
|
|
4289
|
+
name: string;
|
|
4290
|
+
};
|
|
4291
|
+
updatedAt: number;
|
|
4292
|
+
model?: {
|
|
4293
|
+
readonly provider: string;
|
|
4294
|
+
readonly id: string;
|
|
4295
|
+
};
|
|
4296
|
+
thinkingLevel?: "high" | "low" | "max" | "medium" | "minimal" | "off" | "xhigh";
|
|
4297
|
+
parked: boolean;
|
|
4057
4298
|
}, SessionNotFoundError, never>;
|
|
4058
4299
|
prompt: (input: PromptInput) => Effect.Effect<Admitted, InvalidPromptError | PromptConflictError | SessionNotFoundError, never>;
|
|
4059
4300
|
run: (input: PromptInput) => Effect.Effect<Admitted, InvalidPromptError | PromptConflictError | SessionNotFoundError, never>;
|
|
@@ -4082,6 +4323,17 @@ declare const link: (input: {
|
|
|
4082
4323
|
hostDir?: string & import("effect/Brand").Brand<"AbsolutePath">;
|
|
4083
4324
|
hasHostLink: boolean;
|
|
4084
4325
|
sandbox?: instance_d_exports.SandboxInstance.Info;
|
|
4326
|
+
project?: {
|
|
4327
|
+
id: string & import("effect/Brand").Brand<"Project.ID">;
|
|
4328
|
+
name: string;
|
|
4329
|
+
};
|
|
4330
|
+
updatedAt: number;
|
|
4331
|
+
model?: {
|
|
4332
|
+
readonly provider: string;
|
|
4333
|
+
readonly id: string;
|
|
4334
|
+
};
|
|
4335
|
+
thinkingLevel?: "high" | "low" | "max" | "medium" | "minimal" | "off" | "xhigh";
|
|
4336
|
+
parked: boolean;
|
|
4085
4337
|
}, SessionNotFoundError, never>;
|
|
4086
4338
|
prompt: (input: PromptInput) => Effect.Effect<Admitted, InvalidPromptError | PromptConflictError | SessionNotFoundError, never>;
|
|
4087
4339
|
run: (input: PromptInput) => Effect.Effect<Admitted, InvalidPromptError | PromptConflictError | SessionNotFoundError, never>;
|
|
@@ -4108,6 +4360,17 @@ declare const relink: (input: RelinkInput) => Effect.Effect<{
|
|
|
4108
4360
|
hostDir?: string & import("effect/Brand").Brand<"AbsolutePath">;
|
|
4109
4361
|
hasHostLink: boolean;
|
|
4110
4362
|
sandbox?: instance_d_exports.SandboxInstance.Info;
|
|
4363
|
+
project?: {
|
|
4364
|
+
id: string & import("effect/Brand").Brand<"Project.ID">;
|
|
4365
|
+
name: string;
|
|
4366
|
+
};
|
|
4367
|
+
updatedAt: number;
|
|
4368
|
+
model?: {
|
|
4369
|
+
readonly provider: string;
|
|
4370
|
+
readonly id: string;
|
|
4371
|
+
};
|
|
4372
|
+
thinkingLevel?: "high" | "low" | "max" | "medium" | "minimal" | "off" | "xhigh";
|
|
4373
|
+
parked: boolean;
|
|
4111
4374
|
}, SessionNotFoundError, never>;
|
|
4112
4375
|
prompt: (input: PromptInput) => Effect.Effect<Admitted, InvalidPromptError | PromptConflictError | SessionNotFoundError, never>;
|
|
4113
4376
|
run: (input: PromptInput) => Effect.Effect<Admitted, InvalidPromptError | PromptConflictError | SessionNotFoundError, never>;
|
|
@@ -4126,7 +4389,7 @@ declare const attach: (input: AttachInput) => Effect.Effect<Handle, SessionNotFo
|
|
|
4126
4389
|
*/
|
|
4127
4390
|
declare const configuration: (sessionId: string & import("effect/Brand").Brand<"Session.ID">) => Effect.Effect<Configuration, ModelCatalogError | ModelNotFoundError | ProviderError | SessionNotFoundError | SettingsError, Service$16 | Service$5>;
|
|
4128
4391
|
declare namespace list_d_exports {
|
|
4129
|
-
export { ConfigChanged, Definitions, DurableDefinitions, list_d_exports as EventList, ExecutionFailed, ExecutionInterrupted, ExecutionStarted, ExecutionSucceeded, LLMEnded, LLMFailed, LLMStarted, LLMTextDelta, LLMTextEnd, LLMTextStart, LLMThinkingDelta, LLMThinkingEnd, LLMThinkingStart, PluginUpdated, PromptAdmitted, Prompted, PublicDefinitions, RetryFinished, RetryScheduled, SessionForked, ToolProgress, ToolSettled, ToolStarted, TurnAbortCause, TurnAborted, TurnEnded, TurnStarted };
|
|
4392
|
+
export { ConfigChanged, Definitions, DurableDefinitions, list_d_exports as EventList, ExecutionFailed, ExecutionInterrupted, ExecutionStarted, ExecutionSucceeded, LLMEnded, LLMFailed, LLMStarted, LLMTextDelta, LLMTextEnd, LLMTextStart, LLMThinkingDelta, LLMThinkingEnd, LLMThinkingStart, PluginUpdated, PromptAdmitted, PromptCancelled, PromptUpdated, Prompted, PublicDefinitions, RetryFinished, RetryScheduled, SessionForked, ToolProgress, ToolSettled, ToolStarted, TurnAbortCause, TurnAborted, TurnEnded, TurnStarted };
|
|
4130
4393
|
}
|
|
4131
4394
|
declare const PromptAdmitted: Schema.Struct<{
|
|
4132
4395
|
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
@@ -4350,6 +4613,229 @@ declare const Prompted: Schema.Struct<{
|
|
|
4350
4613
|
}>;
|
|
4351
4614
|
};
|
|
4352
4615
|
type Prompted = typeof Prompted.Type;
|
|
4616
|
+
/** A pending prompt withdrawn before promotion; it never enters the conversation. */
|
|
4617
|
+
declare const PromptCancelled: Schema.Struct<{
|
|
4618
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
4619
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
4620
|
+
};
|
|
4621
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
4622
|
+
readonly type: Schema.Literal<"session.prompt.cancelled">;
|
|
4623
|
+
readonly durable: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
4624
|
+
readonly aggregateId: Schema.String;
|
|
4625
|
+
readonly seq: Schema.Int;
|
|
4626
|
+
readonly version: Schema.Int;
|
|
4627
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
4628
|
+
readonly aggregateId: Schema.String;
|
|
4629
|
+
readonly seq: Schema.Int;
|
|
4630
|
+
readonly version: Schema.Int;
|
|
4631
|
+
}>>, never, never>;
|
|
4632
|
+
readonly data: Schema.Struct<{
|
|
4633
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
4634
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
4635
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
4636
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
4637
|
+
};
|
|
4638
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
4639
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
4640
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
4641
|
+
};
|
|
4642
|
+
}>;
|
|
4643
|
+
}> & {
|
|
4644
|
+
type: "session.prompt.cancelled";
|
|
4645
|
+
durable?: {
|
|
4646
|
+
readonly version: number;
|
|
4647
|
+
readonly aggregate: string;
|
|
4648
|
+
};
|
|
4649
|
+
data: Schema.Struct<{
|
|
4650
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
4651
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
4652
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
4653
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
4654
|
+
};
|
|
4655
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
4656
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
4657
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
4658
|
+
};
|
|
4659
|
+
}>;
|
|
4660
|
+
};
|
|
4661
|
+
type PromptCancelled = typeof PromptCancelled.Type;
|
|
4662
|
+
/**
|
|
4663
|
+
* A pending prompt moved to the other lane or rewritten before promotion; it keeps its place. Only
|
|
4664
|
+
* what changed is carried, so two updates of different fields both stand.
|
|
4665
|
+
*/
|
|
4666
|
+
declare const PromptUpdated: Schema.Struct<{
|
|
4667
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
4668
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
4669
|
+
};
|
|
4670
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
4671
|
+
readonly type: Schema.Literal<"session.prompt.updated">;
|
|
4672
|
+
readonly durable: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
4673
|
+
readonly aggregateId: Schema.String;
|
|
4674
|
+
readonly seq: Schema.Int;
|
|
4675
|
+
readonly version: Schema.Int;
|
|
4676
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
4677
|
+
readonly aggregateId: Schema.String;
|
|
4678
|
+
readonly seq: Schema.Int;
|
|
4679
|
+
readonly version: Schema.Int;
|
|
4680
|
+
}>>, never, never>;
|
|
4681
|
+
readonly data: Schema.Struct<{
|
|
4682
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
4683
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
4684
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
4685
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
4686
|
+
};
|
|
4687
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
4688
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
4689
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
4690
|
+
};
|
|
4691
|
+
readonly prompt: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
4692
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
4693
|
+
readonly type: Schema.Literal<"text">;
|
|
4694
|
+
readonly text: Schema.String;
|
|
4695
|
+
}>, Schema.Struct<{
|
|
4696
|
+
readonly type: Schema.Literal<"image">;
|
|
4697
|
+
readonly data: Schema.String;
|
|
4698
|
+
readonly mimeType: Schema.String;
|
|
4699
|
+
}>]>>;
|
|
4700
|
+
}> & {
|
|
4701
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
4702
|
+
readonly parts: readonly ({
|
|
4703
|
+
readonly type: "text";
|
|
4704
|
+
readonly text: string;
|
|
4705
|
+
} | {
|
|
4706
|
+
readonly type: "image";
|
|
4707
|
+
readonly data: string;
|
|
4708
|
+
readonly mimeType: string;
|
|
4709
|
+
})[];
|
|
4710
|
+
}>;
|
|
4711
|
+
fromText: (text: string) => {
|
|
4712
|
+
readonly parts: readonly ({
|
|
4713
|
+
readonly type: "text";
|
|
4714
|
+
readonly text: string;
|
|
4715
|
+
} | {
|
|
4716
|
+
readonly type: "image";
|
|
4717
|
+
readonly data: string;
|
|
4718
|
+
readonly mimeType: string;
|
|
4719
|
+
})[];
|
|
4720
|
+
};
|
|
4721
|
+
text: (prompt: Prompt) => string;
|
|
4722
|
+
}>>, Schema.optionalKey<Schema.Struct<{
|
|
4723
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
4724
|
+
readonly type: Schema.Literal<"text">;
|
|
4725
|
+
readonly text: Schema.String;
|
|
4726
|
+
}>, Schema.Struct<{
|
|
4727
|
+
readonly type: Schema.Literal<"image">;
|
|
4728
|
+
readonly data: Schema.String;
|
|
4729
|
+
readonly mimeType: Schema.String;
|
|
4730
|
+
}>]>>;
|
|
4731
|
+
}> & {
|
|
4732
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
4733
|
+
readonly parts: readonly ({
|
|
4734
|
+
readonly type: "text";
|
|
4735
|
+
readonly text: string;
|
|
4736
|
+
} | {
|
|
4737
|
+
readonly type: "image";
|
|
4738
|
+
readonly data: string;
|
|
4739
|
+
readonly mimeType: string;
|
|
4740
|
+
})[];
|
|
4741
|
+
}>;
|
|
4742
|
+
fromText: (text: string) => {
|
|
4743
|
+
readonly parts: readonly ({
|
|
4744
|
+
readonly type: "text";
|
|
4745
|
+
readonly text: string;
|
|
4746
|
+
} | {
|
|
4747
|
+
readonly type: "image";
|
|
4748
|
+
readonly data: string;
|
|
4749
|
+
readonly mimeType: string;
|
|
4750
|
+
})[];
|
|
4751
|
+
};
|
|
4752
|
+
text: (prompt: Prompt) => string;
|
|
4753
|
+
}>, never, never>;
|
|
4754
|
+
readonly delivery: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["steer", "followUp"]>>>, Schema.optionalKey<Schema.Literals<readonly ["steer", "followUp"]>>, never, never>;
|
|
4755
|
+
}>;
|
|
4756
|
+
}> & {
|
|
4757
|
+
type: "session.prompt.updated";
|
|
4758
|
+
durable?: {
|
|
4759
|
+
readonly version: number;
|
|
4760
|
+
readonly aggregate: string;
|
|
4761
|
+
};
|
|
4762
|
+
data: Schema.Struct<{
|
|
4763
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
4764
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
4765
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
4766
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
4767
|
+
};
|
|
4768
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
4769
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
4770
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
4771
|
+
};
|
|
4772
|
+
readonly prompt: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
4773
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
4774
|
+
readonly type: Schema.Literal<"text">;
|
|
4775
|
+
readonly text: Schema.String;
|
|
4776
|
+
}>, Schema.Struct<{
|
|
4777
|
+
readonly type: Schema.Literal<"image">;
|
|
4778
|
+
readonly data: Schema.String;
|
|
4779
|
+
readonly mimeType: Schema.String;
|
|
4780
|
+
}>]>>;
|
|
4781
|
+
}> & {
|
|
4782
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
4783
|
+
readonly parts: readonly ({
|
|
4784
|
+
readonly type: "text";
|
|
4785
|
+
readonly text: string;
|
|
4786
|
+
} | {
|
|
4787
|
+
readonly type: "image";
|
|
4788
|
+
readonly data: string;
|
|
4789
|
+
readonly mimeType: string;
|
|
4790
|
+
})[];
|
|
4791
|
+
}>;
|
|
4792
|
+
fromText: (text: string) => {
|
|
4793
|
+
readonly parts: readonly ({
|
|
4794
|
+
readonly type: "text";
|
|
4795
|
+
readonly text: string;
|
|
4796
|
+
} | {
|
|
4797
|
+
readonly type: "image";
|
|
4798
|
+
readonly data: string;
|
|
4799
|
+
readonly mimeType: string;
|
|
4800
|
+
})[];
|
|
4801
|
+
};
|
|
4802
|
+
text: (prompt: Prompt) => string;
|
|
4803
|
+
}>>, Schema.optionalKey<Schema.Struct<{
|
|
4804
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
4805
|
+
readonly type: Schema.Literal<"text">;
|
|
4806
|
+
readonly text: Schema.String;
|
|
4807
|
+
}>, Schema.Struct<{
|
|
4808
|
+
readonly type: Schema.Literal<"image">;
|
|
4809
|
+
readonly data: Schema.String;
|
|
4810
|
+
readonly mimeType: Schema.String;
|
|
4811
|
+
}>]>>;
|
|
4812
|
+
}> & {
|
|
4813
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
4814
|
+
readonly parts: readonly ({
|
|
4815
|
+
readonly type: "text";
|
|
4816
|
+
readonly text: string;
|
|
4817
|
+
} | {
|
|
4818
|
+
readonly type: "image";
|
|
4819
|
+
readonly data: string;
|
|
4820
|
+
readonly mimeType: string;
|
|
4821
|
+
})[];
|
|
4822
|
+
}>;
|
|
4823
|
+
fromText: (text: string) => {
|
|
4824
|
+
readonly parts: readonly ({
|
|
4825
|
+
readonly type: "text";
|
|
4826
|
+
readonly text: string;
|
|
4827
|
+
} | {
|
|
4828
|
+
readonly type: "image";
|
|
4829
|
+
readonly data: string;
|
|
4830
|
+
readonly mimeType: string;
|
|
4831
|
+
})[];
|
|
4832
|
+
};
|
|
4833
|
+
text: (prompt: Prompt) => string;
|
|
4834
|
+
}>, never, never>;
|
|
4835
|
+
readonly delivery: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["steer", "followUp"]>>>, Schema.optionalKey<Schema.Literals<readonly ["steer", "followUp"]>>, never, never>;
|
|
4836
|
+
}>;
|
|
4837
|
+
};
|
|
4838
|
+
type PromptUpdated = typeof PromptUpdated.Type;
|
|
4353
4839
|
declare const ConfigChanged: Schema.Struct<{
|
|
4354
4840
|
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
4355
4841
|
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
@@ -9708,14 +10194,275 @@ declare const Definitions: readonly [Schema.Struct<{
|
|
|
9708
10194
|
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
9709
10195
|
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
9710
10196
|
};
|
|
9711
|
-
readonly reason: Schema.Literals<readonly ["user", "shutdown"]>;
|
|
10197
|
+
readonly reason: Schema.Literals<readonly ["user", "shutdown"]>;
|
|
10198
|
+
}>;
|
|
10199
|
+
}, Schema.Struct<{
|
|
10200
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
10201
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
10202
|
+
};
|
|
10203
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
10204
|
+
readonly type: Schema.Literal<"session.prompt.admitted">;
|
|
10205
|
+
readonly durable: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
10206
|
+
readonly aggregateId: Schema.String;
|
|
10207
|
+
readonly seq: Schema.Int;
|
|
10208
|
+
readonly version: Schema.Int;
|
|
10209
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
10210
|
+
readonly aggregateId: Schema.String;
|
|
10211
|
+
readonly seq: Schema.Int;
|
|
10212
|
+
readonly version: Schema.Int;
|
|
10213
|
+
}>>, never, never>;
|
|
10214
|
+
readonly data: Schema.Struct<{
|
|
10215
|
+
timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
10216
|
+
sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
10217
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
10218
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
10219
|
+
};
|
|
10220
|
+
messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
10221
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
10222
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
10223
|
+
};
|
|
10224
|
+
prompt: Schema.Struct<{
|
|
10225
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
10226
|
+
readonly type: Schema.Literal<"text">;
|
|
10227
|
+
readonly text: Schema.String;
|
|
10228
|
+
}>, Schema.Struct<{
|
|
10229
|
+
readonly type: Schema.Literal<"image">;
|
|
10230
|
+
readonly data: Schema.String;
|
|
10231
|
+
readonly mimeType: Schema.String;
|
|
10232
|
+
}>]>>;
|
|
10233
|
+
}> & {
|
|
10234
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
10235
|
+
readonly parts: readonly ({
|
|
10236
|
+
readonly type: "text";
|
|
10237
|
+
readonly text: string;
|
|
10238
|
+
} | {
|
|
10239
|
+
readonly type: "image";
|
|
10240
|
+
readonly data: string;
|
|
10241
|
+
readonly mimeType: string;
|
|
10242
|
+
})[];
|
|
10243
|
+
}>;
|
|
10244
|
+
fromText: (text: string) => {
|
|
10245
|
+
readonly parts: readonly ({
|
|
10246
|
+
readonly type: "text";
|
|
10247
|
+
readonly text: string;
|
|
10248
|
+
} | {
|
|
10249
|
+
readonly type: "image";
|
|
10250
|
+
readonly data: string;
|
|
10251
|
+
readonly mimeType: string;
|
|
10252
|
+
})[];
|
|
10253
|
+
};
|
|
10254
|
+
text: (prompt: Prompt) => string;
|
|
10255
|
+
};
|
|
10256
|
+
delivery: Schema.Literals<readonly ["steer", "followUp"]>;
|
|
10257
|
+
}>;
|
|
10258
|
+
}> & {
|
|
10259
|
+
type: "session.prompt.admitted";
|
|
10260
|
+
durable?: {
|
|
10261
|
+
readonly version: number;
|
|
10262
|
+
readonly aggregate: string;
|
|
10263
|
+
};
|
|
10264
|
+
data: Schema.Struct<{
|
|
10265
|
+
timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
10266
|
+
sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
10267
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
10268
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
10269
|
+
};
|
|
10270
|
+
messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
10271
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
10272
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
10273
|
+
};
|
|
10274
|
+
prompt: Schema.Struct<{
|
|
10275
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
10276
|
+
readonly type: Schema.Literal<"text">;
|
|
10277
|
+
readonly text: Schema.String;
|
|
10278
|
+
}>, Schema.Struct<{
|
|
10279
|
+
readonly type: Schema.Literal<"image">;
|
|
10280
|
+
readonly data: Schema.String;
|
|
10281
|
+
readonly mimeType: Schema.String;
|
|
10282
|
+
}>]>>;
|
|
10283
|
+
}> & {
|
|
10284
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
10285
|
+
readonly parts: readonly ({
|
|
10286
|
+
readonly type: "text";
|
|
10287
|
+
readonly text: string;
|
|
10288
|
+
} | {
|
|
10289
|
+
readonly type: "image";
|
|
10290
|
+
readonly data: string;
|
|
10291
|
+
readonly mimeType: string;
|
|
10292
|
+
})[];
|
|
10293
|
+
}>;
|
|
10294
|
+
fromText: (text: string) => {
|
|
10295
|
+
readonly parts: readonly ({
|
|
10296
|
+
readonly type: "text";
|
|
10297
|
+
readonly text: string;
|
|
10298
|
+
} | {
|
|
10299
|
+
readonly type: "image";
|
|
10300
|
+
readonly data: string;
|
|
10301
|
+
readonly mimeType: string;
|
|
10302
|
+
})[];
|
|
10303
|
+
};
|
|
10304
|
+
text: (prompt: Prompt) => string;
|
|
10305
|
+
};
|
|
10306
|
+
delivery: Schema.Literals<readonly ["steer", "followUp"]>;
|
|
10307
|
+
}>;
|
|
10308
|
+
}, Schema.Struct<{
|
|
10309
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
10310
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
10311
|
+
};
|
|
10312
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
10313
|
+
readonly type: Schema.Literal<"session.prompt.promoted">;
|
|
10314
|
+
readonly durable: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
10315
|
+
readonly aggregateId: Schema.String;
|
|
10316
|
+
readonly seq: Schema.Int;
|
|
10317
|
+
readonly version: Schema.Int;
|
|
10318
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
10319
|
+
readonly aggregateId: Schema.String;
|
|
10320
|
+
readonly seq: Schema.Int;
|
|
10321
|
+
readonly version: Schema.Int;
|
|
10322
|
+
}>>, never, never>;
|
|
10323
|
+
readonly data: Schema.Struct<{
|
|
10324
|
+
timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
10325
|
+
sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
10326
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
10327
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
10328
|
+
};
|
|
10329
|
+
messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
10330
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
10331
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
10332
|
+
};
|
|
10333
|
+
prompt: Schema.Struct<{
|
|
10334
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
10335
|
+
readonly type: Schema.Literal<"text">;
|
|
10336
|
+
readonly text: Schema.String;
|
|
10337
|
+
}>, Schema.Struct<{
|
|
10338
|
+
readonly type: Schema.Literal<"image">;
|
|
10339
|
+
readonly data: Schema.String;
|
|
10340
|
+
readonly mimeType: Schema.String;
|
|
10341
|
+
}>]>>;
|
|
10342
|
+
}> & {
|
|
10343
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
10344
|
+
readonly parts: readonly ({
|
|
10345
|
+
readonly type: "text";
|
|
10346
|
+
readonly text: string;
|
|
10347
|
+
} | {
|
|
10348
|
+
readonly type: "image";
|
|
10349
|
+
readonly data: string;
|
|
10350
|
+
readonly mimeType: string;
|
|
10351
|
+
})[];
|
|
10352
|
+
}>;
|
|
10353
|
+
fromText: (text: string) => {
|
|
10354
|
+
readonly parts: readonly ({
|
|
10355
|
+
readonly type: "text";
|
|
10356
|
+
readonly text: string;
|
|
10357
|
+
} | {
|
|
10358
|
+
readonly type: "image";
|
|
10359
|
+
readonly data: string;
|
|
10360
|
+
readonly mimeType: string;
|
|
10361
|
+
})[];
|
|
10362
|
+
};
|
|
10363
|
+
text: (prompt: Prompt) => string;
|
|
10364
|
+
};
|
|
10365
|
+
delivery: Schema.Literals<readonly ["steer", "followUp"]>;
|
|
10366
|
+
}>;
|
|
10367
|
+
}> & {
|
|
10368
|
+
type: "session.prompt.promoted";
|
|
10369
|
+
durable?: {
|
|
10370
|
+
readonly version: number;
|
|
10371
|
+
readonly aggregate: string;
|
|
10372
|
+
};
|
|
10373
|
+
data: Schema.Struct<{
|
|
10374
|
+
timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
10375
|
+
sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
10376
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
10377
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
10378
|
+
};
|
|
10379
|
+
messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
10380
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
10381
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
10382
|
+
};
|
|
10383
|
+
prompt: Schema.Struct<{
|
|
10384
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
10385
|
+
readonly type: Schema.Literal<"text">;
|
|
10386
|
+
readonly text: Schema.String;
|
|
10387
|
+
}>, Schema.Struct<{
|
|
10388
|
+
readonly type: Schema.Literal<"image">;
|
|
10389
|
+
readonly data: Schema.String;
|
|
10390
|
+
readonly mimeType: Schema.String;
|
|
10391
|
+
}>]>>;
|
|
10392
|
+
}> & {
|
|
10393
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
10394
|
+
readonly parts: readonly ({
|
|
10395
|
+
readonly type: "text";
|
|
10396
|
+
readonly text: string;
|
|
10397
|
+
} | {
|
|
10398
|
+
readonly type: "image";
|
|
10399
|
+
readonly data: string;
|
|
10400
|
+
readonly mimeType: string;
|
|
10401
|
+
})[];
|
|
10402
|
+
}>;
|
|
10403
|
+
fromText: (text: string) => {
|
|
10404
|
+
readonly parts: readonly ({
|
|
10405
|
+
readonly type: "text";
|
|
10406
|
+
readonly text: string;
|
|
10407
|
+
} | {
|
|
10408
|
+
readonly type: "image";
|
|
10409
|
+
readonly data: string;
|
|
10410
|
+
readonly mimeType: string;
|
|
10411
|
+
})[];
|
|
10412
|
+
};
|
|
10413
|
+
text: (prompt: Prompt) => string;
|
|
10414
|
+
};
|
|
10415
|
+
delivery: Schema.Literals<readonly ["steer", "followUp"]>;
|
|
10416
|
+
}>;
|
|
10417
|
+
}, Schema.Struct<{
|
|
10418
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
10419
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
10420
|
+
};
|
|
10421
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
10422
|
+
readonly type: Schema.Literal<"session.prompt.cancelled">;
|
|
10423
|
+
readonly durable: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
10424
|
+
readonly aggregateId: Schema.String;
|
|
10425
|
+
readonly seq: Schema.Int;
|
|
10426
|
+
readonly version: Schema.Int;
|
|
10427
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
10428
|
+
readonly aggregateId: Schema.String;
|
|
10429
|
+
readonly seq: Schema.Int;
|
|
10430
|
+
readonly version: Schema.Int;
|
|
10431
|
+
}>>, never, never>;
|
|
10432
|
+
readonly data: Schema.Struct<{
|
|
10433
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
10434
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
10435
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
10436
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
10437
|
+
};
|
|
10438
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
10439
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
10440
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
10441
|
+
};
|
|
10442
|
+
}>;
|
|
10443
|
+
}> & {
|
|
10444
|
+
type: "session.prompt.cancelled";
|
|
10445
|
+
durable?: {
|
|
10446
|
+
readonly version: number;
|
|
10447
|
+
readonly aggregate: string;
|
|
10448
|
+
};
|
|
10449
|
+
data: Schema.Struct<{
|
|
10450
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
10451
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
10452
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
10453
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
10454
|
+
};
|
|
10455
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
10456
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
10457
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
10458
|
+
};
|
|
9712
10459
|
}>;
|
|
9713
10460
|
}, Schema.Struct<{
|
|
9714
10461
|
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
9715
10462
|
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
9716
10463
|
};
|
|
9717
10464
|
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
9718
|
-
readonly type: Schema.Literal<"session.prompt.
|
|
10465
|
+
readonly type: Schema.Literal<"session.prompt.updated">;
|
|
9719
10466
|
readonly durable: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
9720
10467
|
readonly aggregateId: Schema.String;
|
|
9721
10468
|
readonly seq: Schema.Int;
|
|
@@ -9726,16 +10473,16 @@ declare const Definitions: readonly [Schema.Struct<{
|
|
|
9726
10473
|
readonly version: Schema.Int;
|
|
9727
10474
|
}>>, never, never>;
|
|
9728
10475
|
readonly data: Schema.Struct<{
|
|
9729
|
-
timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
9730
|
-
sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
10476
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
10477
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
9731
10478
|
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
9732
10479
|
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
9733
10480
|
};
|
|
9734
|
-
messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
10481
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
9735
10482
|
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
9736
10483
|
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
9737
10484
|
};
|
|
9738
|
-
prompt: Schema.Struct<{
|
|
10485
|
+
readonly prompt: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
9739
10486
|
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
9740
10487
|
readonly type: Schema.Literal<"text">;
|
|
9741
10488
|
readonly text: Schema.String;
|
|
@@ -9766,26 +10513,7 @@ declare const Definitions: readonly [Schema.Struct<{
|
|
|
9766
10513
|
})[];
|
|
9767
10514
|
};
|
|
9768
10515
|
text: (prompt: Prompt) => string;
|
|
9769
|
-
}
|
|
9770
|
-
delivery: Schema.Literals<readonly ["steer", "followUp"]>;
|
|
9771
|
-
}>;
|
|
9772
|
-
}> & {
|
|
9773
|
-
type: "session.prompt.admitted";
|
|
9774
|
-
durable?: {
|
|
9775
|
-
readonly version: number;
|
|
9776
|
-
readonly aggregate: string;
|
|
9777
|
-
};
|
|
9778
|
-
data: Schema.Struct<{
|
|
9779
|
-
timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
9780
|
-
sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
9781
|
-
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
9782
|
-
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
9783
|
-
};
|
|
9784
|
-
messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
9785
|
-
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
9786
|
-
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
9787
|
-
};
|
|
9788
|
-
prompt: Schema.Struct<{
|
|
10516
|
+
}>>, Schema.optionalKey<Schema.Struct<{
|
|
9789
10517
|
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
9790
10518
|
readonly type: Schema.Literal<"text">;
|
|
9791
10519
|
readonly text: Schema.String;
|
|
@@ -9816,35 +10544,26 @@ declare const Definitions: readonly [Schema.Struct<{
|
|
|
9816
10544
|
})[];
|
|
9817
10545
|
};
|
|
9818
10546
|
text: (prompt: Prompt) => string;
|
|
9819
|
-
}
|
|
9820
|
-
delivery: Schema.Literals<readonly ["steer", "followUp"]>;
|
|
10547
|
+
}>, never, never>;
|
|
10548
|
+
readonly delivery: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["steer", "followUp"]>>>, Schema.optionalKey<Schema.Literals<readonly ["steer", "followUp"]>>, never, never>;
|
|
9821
10549
|
}>;
|
|
9822
|
-
}
|
|
9823
|
-
|
|
9824
|
-
|
|
10550
|
+
}> & {
|
|
10551
|
+
type: "session.prompt.updated";
|
|
10552
|
+
durable?: {
|
|
10553
|
+
readonly version: number;
|
|
10554
|
+
readonly aggregate: string;
|
|
9825
10555
|
};
|
|
9826
|
-
|
|
9827
|
-
|
|
9828
|
-
|
|
9829
|
-
readonly aggregateId: Schema.String;
|
|
9830
|
-
readonly seq: Schema.Int;
|
|
9831
|
-
readonly version: Schema.Int;
|
|
9832
|
-
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
9833
|
-
readonly aggregateId: Schema.String;
|
|
9834
|
-
readonly seq: Schema.Int;
|
|
9835
|
-
readonly version: Schema.Int;
|
|
9836
|
-
}>>, never, never>;
|
|
9837
|
-
readonly data: Schema.Struct<{
|
|
9838
|
-
timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
9839
|
-
sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
10556
|
+
data: Schema.Struct<{
|
|
10557
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
10558
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
9840
10559
|
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
9841
10560
|
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
9842
10561
|
};
|
|
9843
|
-
messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
10562
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
9844
10563
|
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
9845
10564
|
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
9846
10565
|
};
|
|
9847
|
-
prompt: Schema.Struct<{
|
|
10566
|
+
readonly prompt: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
9848
10567
|
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
9849
10568
|
readonly type: Schema.Literal<"text">;
|
|
9850
10569
|
readonly text: Schema.String;
|
|
@@ -9875,26 +10594,7 @@ declare const Definitions: readonly [Schema.Struct<{
|
|
|
9875
10594
|
})[];
|
|
9876
10595
|
};
|
|
9877
10596
|
text: (prompt: Prompt) => string;
|
|
9878
|
-
}
|
|
9879
|
-
delivery: Schema.Literals<readonly ["steer", "followUp"]>;
|
|
9880
|
-
}>;
|
|
9881
|
-
}> & {
|
|
9882
|
-
type: "session.prompt.promoted";
|
|
9883
|
-
durable?: {
|
|
9884
|
-
readonly version: number;
|
|
9885
|
-
readonly aggregate: string;
|
|
9886
|
-
};
|
|
9887
|
-
data: Schema.Struct<{
|
|
9888
|
-
timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
9889
|
-
sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
9890
|
-
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
9891
|
-
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
9892
|
-
};
|
|
9893
|
-
messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
9894
|
-
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
9895
|
-
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
9896
|
-
};
|
|
9897
|
-
prompt: Schema.Struct<{
|
|
10597
|
+
}>>, Schema.optionalKey<Schema.Struct<{
|
|
9898
10598
|
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
9899
10599
|
readonly type: Schema.Literal<"text">;
|
|
9900
10600
|
readonly text: Schema.String;
|
|
@@ -9925,8 +10625,8 @@ declare const Definitions: readonly [Schema.Struct<{
|
|
|
9925
10625
|
})[];
|
|
9926
10626
|
};
|
|
9927
10627
|
text: (prompt: Prompt) => string;
|
|
9928
|
-
}
|
|
9929
|
-
delivery: Schema.Literals<readonly ["steer", "followUp"]>;
|
|
10628
|
+
}>, never, never>;
|
|
10629
|
+
readonly delivery: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["steer", "followUp"]>>>, Schema.optionalKey<Schema.Literals<readonly ["steer", "followUp"]>>, never, never>;
|
|
9930
10630
|
}>;
|
|
9931
10631
|
}, Schema.Struct<{
|
|
9932
10632
|
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
@@ -15223,26 +15923,209 @@ declare const PublicDefinitions: readonly [Schema.Struct<{
|
|
|
15223
15923
|
})[];
|
|
15224
15924
|
};
|
|
15225
15925
|
text: (prompt: Prompt) => string;
|
|
15226
|
-
};
|
|
15227
|
-
delivery: Schema.Literals<readonly ["steer", "followUp"]>;
|
|
15926
|
+
};
|
|
15927
|
+
delivery: Schema.Literals<readonly ["steer", "followUp"]>;
|
|
15928
|
+
}>;
|
|
15929
|
+
}> & {
|
|
15930
|
+
type: "session.prompt.promoted";
|
|
15931
|
+
durable?: {
|
|
15932
|
+
readonly version: number;
|
|
15933
|
+
readonly aggregate: string;
|
|
15934
|
+
};
|
|
15935
|
+
data: Schema.Struct<{
|
|
15936
|
+
timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
15937
|
+
sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
15938
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
15939
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
15940
|
+
};
|
|
15941
|
+
messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
15942
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
15943
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
15944
|
+
};
|
|
15945
|
+
prompt: Schema.Struct<{
|
|
15946
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
15947
|
+
readonly type: Schema.Literal<"text">;
|
|
15948
|
+
readonly text: Schema.String;
|
|
15949
|
+
}>, Schema.Struct<{
|
|
15950
|
+
readonly type: Schema.Literal<"image">;
|
|
15951
|
+
readonly data: Schema.String;
|
|
15952
|
+
readonly mimeType: Schema.String;
|
|
15953
|
+
}>]>>;
|
|
15954
|
+
}> & {
|
|
15955
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
15956
|
+
readonly parts: readonly ({
|
|
15957
|
+
readonly type: "text";
|
|
15958
|
+
readonly text: string;
|
|
15959
|
+
} | {
|
|
15960
|
+
readonly type: "image";
|
|
15961
|
+
readonly data: string;
|
|
15962
|
+
readonly mimeType: string;
|
|
15963
|
+
})[];
|
|
15964
|
+
}>;
|
|
15965
|
+
fromText: (text: string) => {
|
|
15966
|
+
readonly parts: readonly ({
|
|
15967
|
+
readonly type: "text";
|
|
15968
|
+
readonly text: string;
|
|
15969
|
+
} | {
|
|
15970
|
+
readonly type: "image";
|
|
15971
|
+
readonly data: string;
|
|
15972
|
+
readonly mimeType: string;
|
|
15973
|
+
})[];
|
|
15974
|
+
};
|
|
15975
|
+
text: (prompt: Prompt) => string;
|
|
15976
|
+
};
|
|
15977
|
+
delivery: Schema.Literals<readonly ["steer", "followUp"]>;
|
|
15978
|
+
}>;
|
|
15979
|
+
}, Schema.Struct<{
|
|
15980
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
15981
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
15982
|
+
};
|
|
15983
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
15984
|
+
readonly type: Schema.Literal<"session.prompt.cancelled">;
|
|
15985
|
+
readonly durable: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
15986
|
+
readonly aggregateId: Schema.String;
|
|
15987
|
+
readonly seq: Schema.Int;
|
|
15988
|
+
readonly version: Schema.Int;
|
|
15989
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
15990
|
+
readonly aggregateId: Schema.String;
|
|
15991
|
+
readonly seq: Schema.Int;
|
|
15992
|
+
readonly version: Schema.Int;
|
|
15993
|
+
}>>, never, never>;
|
|
15994
|
+
readonly data: Schema.Struct<{
|
|
15995
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
15996
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
15997
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
15998
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
15999
|
+
};
|
|
16000
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
16001
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
16002
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
16003
|
+
};
|
|
16004
|
+
}>;
|
|
16005
|
+
}> & {
|
|
16006
|
+
type: "session.prompt.cancelled";
|
|
16007
|
+
durable?: {
|
|
16008
|
+
readonly version: number;
|
|
16009
|
+
readonly aggregate: string;
|
|
16010
|
+
};
|
|
16011
|
+
data: Schema.Struct<{
|
|
16012
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
16013
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
16014
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
16015
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
16016
|
+
};
|
|
16017
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
16018
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
16019
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
16020
|
+
};
|
|
16021
|
+
}>;
|
|
16022
|
+
}, Schema.Struct<{
|
|
16023
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
16024
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
16025
|
+
};
|
|
16026
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
16027
|
+
readonly type: Schema.Literal<"session.prompt.updated">;
|
|
16028
|
+
readonly durable: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
16029
|
+
readonly aggregateId: Schema.String;
|
|
16030
|
+
readonly seq: Schema.Int;
|
|
16031
|
+
readonly version: Schema.Int;
|
|
16032
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
16033
|
+
readonly aggregateId: Schema.String;
|
|
16034
|
+
readonly seq: Schema.Int;
|
|
16035
|
+
readonly version: Schema.Int;
|
|
16036
|
+
}>>, never, never>;
|
|
16037
|
+
readonly data: Schema.Struct<{
|
|
16038
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
16039
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
16040
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
16041
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
16042
|
+
};
|
|
16043
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
16044
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
16045
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
16046
|
+
};
|
|
16047
|
+
readonly prompt: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
16048
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
16049
|
+
readonly type: Schema.Literal<"text">;
|
|
16050
|
+
readonly text: Schema.String;
|
|
16051
|
+
}>, Schema.Struct<{
|
|
16052
|
+
readonly type: Schema.Literal<"image">;
|
|
16053
|
+
readonly data: Schema.String;
|
|
16054
|
+
readonly mimeType: Schema.String;
|
|
16055
|
+
}>]>>;
|
|
16056
|
+
}> & {
|
|
16057
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
16058
|
+
readonly parts: readonly ({
|
|
16059
|
+
readonly type: "text";
|
|
16060
|
+
readonly text: string;
|
|
16061
|
+
} | {
|
|
16062
|
+
readonly type: "image";
|
|
16063
|
+
readonly data: string;
|
|
16064
|
+
readonly mimeType: string;
|
|
16065
|
+
})[];
|
|
16066
|
+
}>;
|
|
16067
|
+
fromText: (text: string) => {
|
|
16068
|
+
readonly parts: readonly ({
|
|
16069
|
+
readonly type: "text";
|
|
16070
|
+
readonly text: string;
|
|
16071
|
+
} | {
|
|
16072
|
+
readonly type: "image";
|
|
16073
|
+
readonly data: string;
|
|
16074
|
+
readonly mimeType: string;
|
|
16075
|
+
})[];
|
|
16076
|
+
};
|
|
16077
|
+
text: (prompt: Prompt) => string;
|
|
16078
|
+
}>>, Schema.optionalKey<Schema.Struct<{
|
|
16079
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
16080
|
+
readonly type: Schema.Literal<"text">;
|
|
16081
|
+
readonly text: Schema.String;
|
|
16082
|
+
}>, Schema.Struct<{
|
|
16083
|
+
readonly type: Schema.Literal<"image">;
|
|
16084
|
+
readonly data: Schema.String;
|
|
16085
|
+
readonly mimeType: Schema.String;
|
|
16086
|
+
}>]>>;
|
|
16087
|
+
}> & {
|
|
16088
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
16089
|
+
readonly parts: readonly ({
|
|
16090
|
+
readonly type: "text";
|
|
16091
|
+
readonly text: string;
|
|
16092
|
+
} | {
|
|
16093
|
+
readonly type: "image";
|
|
16094
|
+
readonly data: string;
|
|
16095
|
+
readonly mimeType: string;
|
|
16096
|
+
})[];
|
|
16097
|
+
}>;
|
|
16098
|
+
fromText: (text: string) => {
|
|
16099
|
+
readonly parts: readonly ({
|
|
16100
|
+
readonly type: "text";
|
|
16101
|
+
readonly text: string;
|
|
16102
|
+
} | {
|
|
16103
|
+
readonly type: "image";
|
|
16104
|
+
readonly data: string;
|
|
16105
|
+
readonly mimeType: string;
|
|
16106
|
+
})[];
|
|
16107
|
+
};
|
|
16108
|
+
text: (prompt: Prompt) => string;
|
|
16109
|
+
}>, never, never>;
|
|
16110
|
+
readonly delivery: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["steer", "followUp"]>>>, Schema.optionalKey<Schema.Literals<readonly ["steer", "followUp"]>>, never, never>;
|
|
15228
16111
|
}>;
|
|
15229
16112
|
}> & {
|
|
15230
|
-
type: "session.prompt.
|
|
16113
|
+
type: "session.prompt.updated";
|
|
15231
16114
|
durable?: {
|
|
15232
16115
|
readonly version: number;
|
|
15233
16116
|
readonly aggregate: string;
|
|
15234
16117
|
};
|
|
15235
16118
|
data: Schema.Struct<{
|
|
15236
|
-
timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
15237
|
-
sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
16119
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
16120
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
15238
16121
|
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
15239
16122
|
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
15240
16123
|
};
|
|
15241
|
-
messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
16124
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
15242
16125
|
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
15243
16126
|
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
15244
16127
|
};
|
|
15245
|
-
prompt: Schema.Struct<{
|
|
16128
|
+
readonly prompt: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
15246
16129
|
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
15247
16130
|
readonly type: Schema.Literal<"text">;
|
|
15248
16131
|
readonly text: Schema.String;
|
|
@@ -15273,8 +16156,39 @@ declare const PublicDefinitions: readonly [Schema.Struct<{
|
|
|
15273
16156
|
})[];
|
|
15274
16157
|
};
|
|
15275
16158
|
text: (prompt: Prompt) => string;
|
|
15276
|
-
}
|
|
15277
|
-
|
|
16159
|
+
}>>, Schema.optionalKey<Schema.Struct<{
|
|
16160
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
16161
|
+
readonly type: Schema.Literal<"text">;
|
|
16162
|
+
readonly text: Schema.String;
|
|
16163
|
+
}>, Schema.Struct<{
|
|
16164
|
+
readonly type: Schema.Literal<"image">;
|
|
16165
|
+
readonly data: Schema.String;
|
|
16166
|
+
readonly mimeType: Schema.String;
|
|
16167
|
+
}>]>>;
|
|
16168
|
+
}> & {
|
|
16169
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
16170
|
+
readonly parts: readonly ({
|
|
16171
|
+
readonly type: "text";
|
|
16172
|
+
readonly text: string;
|
|
16173
|
+
} | {
|
|
16174
|
+
readonly type: "image";
|
|
16175
|
+
readonly data: string;
|
|
16176
|
+
readonly mimeType: string;
|
|
16177
|
+
})[];
|
|
16178
|
+
}>;
|
|
16179
|
+
fromText: (text: string) => {
|
|
16180
|
+
readonly parts: readonly ({
|
|
16181
|
+
readonly type: "text";
|
|
16182
|
+
readonly text: string;
|
|
16183
|
+
} | {
|
|
16184
|
+
readonly type: "image";
|
|
16185
|
+
readonly data: string;
|
|
16186
|
+
readonly mimeType: string;
|
|
16187
|
+
})[];
|
|
16188
|
+
};
|
|
16189
|
+
text: (prompt: Prompt) => string;
|
|
16190
|
+
}>, never, never>;
|
|
16191
|
+
readonly delivery: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["steer", "followUp"]>>>, Schema.optionalKey<Schema.Literals<readonly ["steer", "followUp"]>>, never, never>;
|
|
15278
16192
|
}>;
|
|
15279
16193
|
}, Schema.Struct<{
|
|
15280
16194
|
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
@@ -20467,6 +21381,220 @@ declare const DurableDefinitions: readonly [Schema.Struct<{
|
|
|
20467
21381
|
};
|
|
20468
21382
|
delivery: Schema.Literals<readonly ["steer", "followUp"]>;
|
|
20469
21383
|
}>;
|
|
21384
|
+
}, Schema.Struct<{
|
|
21385
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
21386
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
21387
|
+
};
|
|
21388
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
21389
|
+
readonly type: Schema.Literal<"session.prompt.cancelled">;
|
|
21390
|
+
readonly durable: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
21391
|
+
readonly aggregateId: Schema.String;
|
|
21392
|
+
readonly seq: Schema.Int;
|
|
21393
|
+
readonly version: Schema.Int;
|
|
21394
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
21395
|
+
readonly aggregateId: Schema.String;
|
|
21396
|
+
readonly seq: Schema.Int;
|
|
21397
|
+
readonly version: Schema.Int;
|
|
21398
|
+
}>>, never, never>;
|
|
21399
|
+
readonly data: Schema.Struct<{
|
|
21400
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
21401
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
21402
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
21403
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
21404
|
+
};
|
|
21405
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
21406
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
21407
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
21408
|
+
};
|
|
21409
|
+
}>;
|
|
21410
|
+
}> & {
|
|
21411
|
+
type: "session.prompt.cancelled";
|
|
21412
|
+
durable?: {
|
|
21413
|
+
readonly version: number;
|
|
21414
|
+
readonly aggregate: string;
|
|
21415
|
+
};
|
|
21416
|
+
data: Schema.Struct<{
|
|
21417
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
21418
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
21419
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
21420
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
21421
|
+
};
|
|
21422
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
21423
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
21424
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
21425
|
+
};
|
|
21426
|
+
}>;
|
|
21427
|
+
}, Schema.Struct<{
|
|
21428
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
21429
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
21430
|
+
};
|
|
21431
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
21432
|
+
readonly type: Schema.Literal<"session.prompt.updated">;
|
|
21433
|
+
readonly durable: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
21434
|
+
readonly aggregateId: Schema.String;
|
|
21435
|
+
readonly seq: Schema.Int;
|
|
21436
|
+
readonly version: Schema.Int;
|
|
21437
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
21438
|
+
readonly aggregateId: Schema.String;
|
|
21439
|
+
readonly seq: Schema.Int;
|
|
21440
|
+
readonly version: Schema.Int;
|
|
21441
|
+
}>>, never, never>;
|
|
21442
|
+
readonly data: Schema.Struct<{
|
|
21443
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
21444
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
21445
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
21446
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
21447
|
+
};
|
|
21448
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
21449
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
21450
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
21451
|
+
};
|
|
21452
|
+
readonly prompt: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
21453
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
21454
|
+
readonly type: Schema.Literal<"text">;
|
|
21455
|
+
readonly text: Schema.String;
|
|
21456
|
+
}>, Schema.Struct<{
|
|
21457
|
+
readonly type: Schema.Literal<"image">;
|
|
21458
|
+
readonly data: Schema.String;
|
|
21459
|
+
readonly mimeType: Schema.String;
|
|
21460
|
+
}>]>>;
|
|
21461
|
+
}> & {
|
|
21462
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
21463
|
+
readonly parts: readonly ({
|
|
21464
|
+
readonly type: "text";
|
|
21465
|
+
readonly text: string;
|
|
21466
|
+
} | {
|
|
21467
|
+
readonly type: "image";
|
|
21468
|
+
readonly data: string;
|
|
21469
|
+
readonly mimeType: string;
|
|
21470
|
+
})[];
|
|
21471
|
+
}>;
|
|
21472
|
+
fromText: (text: string) => {
|
|
21473
|
+
readonly parts: readonly ({
|
|
21474
|
+
readonly type: "text";
|
|
21475
|
+
readonly text: string;
|
|
21476
|
+
} | {
|
|
21477
|
+
readonly type: "image";
|
|
21478
|
+
readonly data: string;
|
|
21479
|
+
readonly mimeType: string;
|
|
21480
|
+
})[];
|
|
21481
|
+
};
|
|
21482
|
+
text: (prompt: Prompt) => string;
|
|
21483
|
+
}>>, Schema.optionalKey<Schema.Struct<{
|
|
21484
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
21485
|
+
readonly type: Schema.Literal<"text">;
|
|
21486
|
+
readonly text: Schema.String;
|
|
21487
|
+
}>, Schema.Struct<{
|
|
21488
|
+
readonly type: Schema.Literal<"image">;
|
|
21489
|
+
readonly data: Schema.String;
|
|
21490
|
+
readonly mimeType: Schema.String;
|
|
21491
|
+
}>]>>;
|
|
21492
|
+
}> & {
|
|
21493
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
21494
|
+
readonly parts: readonly ({
|
|
21495
|
+
readonly type: "text";
|
|
21496
|
+
readonly text: string;
|
|
21497
|
+
} | {
|
|
21498
|
+
readonly type: "image";
|
|
21499
|
+
readonly data: string;
|
|
21500
|
+
readonly mimeType: string;
|
|
21501
|
+
})[];
|
|
21502
|
+
}>;
|
|
21503
|
+
fromText: (text: string) => {
|
|
21504
|
+
readonly parts: readonly ({
|
|
21505
|
+
readonly type: "text";
|
|
21506
|
+
readonly text: string;
|
|
21507
|
+
} | {
|
|
21508
|
+
readonly type: "image";
|
|
21509
|
+
readonly data: string;
|
|
21510
|
+
readonly mimeType: string;
|
|
21511
|
+
})[];
|
|
21512
|
+
};
|
|
21513
|
+
text: (prompt: Prompt) => string;
|
|
21514
|
+
}>, never, never>;
|
|
21515
|
+
readonly delivery: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["steer", "followUp"]>>>, Schema.optionalKey<Schema.Literals<readonly ["steer", "followUp"]>>, never, never>;
|
|
21516
|
+
}>;
|
|
21517
|
+
}> & {
|
|
21518
|
+
type: "session.prompt.updated";
|
|
21519
|
+
durable?: {
|
|
21520
|
+
readonly version: number;
|
|
21521
|
+
readonly aggregate: string;
|
|
21522
|
+
};
|
|
21523
|
+
data: Schema.Struct<{
|
|
21524
|
+
readonly timestamp: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
21525
|
+
readonly sessionId: Schema.brand<Schema.String, "Session.ID"> & {
|
|
21526
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Session.ID">;
|
|
21527
|
+
create: () => string & import("effect/Brand").Brand<"Session.ID">;
|
|
21528
|
+
};
|
|
21529
|
+
readonly messageId: Schema.brand<Schema.String, "Message.ID"> & {
|
|
21530
|
+
create: () => string & import("effect/Brand").Brand<"Message.ID">;
|
|
21531
|
+
from: (id: string) => string & import("effect/Brand").Brand<"Message.ID">;
|
|
21532
|
+
};
|
|
21533
|
+
readonly prompt: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
21534
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
21535
|
+
readonly type: Schema.Literal<"text">;
|
|
21536
|
+
readonly text: Schema.String;
|
|
21537
|
+
}>, Schema.Struct<{
|
|
21538
|
+
readonly type: Schema.Literal<"image">;
|
|
21539
|
+
readonly data: Schema.String;
|
|
21540
|
+
readonly mimeType: Schema.String;
|
|
21541
|
+
}>]>>;
|
|
21542
|
+
}> & {
|
|
21543
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
21544
|
+
readonly parts: readonly ({
|
|
21545
|
+
readonly type: "text";
|
|
21546
|
+
readonly text: string;
|
|
21547
|
+
} | {
|
|
21548
|
+
readonly type: "image";
|
|
21549
|
+
readonly data: string;
|
|
21550
|
+
readonly mimeType: string;
|
|
21551
|
+
})[];
|
|
21552
|
+
}>;
|
|
21553
|
+
fromText: (text: string) => {
|
|
21554
|
+
readonly parts: readonly ({
|
|
21555
|
+
readonly type: "text";
|
|
21556
|
+
readonly text: string;
|
|
21557
|
+
} | {
|
|
21558
|
+
readonly type: "image";
|
|
21559
|
+
readonly data: string;
|
|
21560
|
+
readonly mimeType: string;
|
|
21561
|
+
})[];
|
|
21562
|
+
};
|
|
21563
|
+
text: (prompt: Prompt) => string;
|
|
21564
|
+
}>>, Schema.optionalKey<Schema.Struct<{
|
|
21565
|
+
readonly parts: Schema.$Array<Schema.Union<readonly [Schema.Struct<{
|
|
21566
|
+
readonly type: Schema.Literal<"text">;
|
|
21567
|
+
readonly text: Schema.String;
|
|
21568
|
+
}>, Schema.Struct<{
|
|
21569
|
+
readonly type: Schema.Literal<"image">;
|
|
21570
|
+
readonly data: Schema.String;
|
|
21571
|
+
readonly mimeType: Schema.String;
|
|
21572
|
+
}>]>>;
|
|
21573
|
+
}> & {
|
|
21574
|
+
equivalence: import("effect/Equivalence").Equivalence<{
|
|
21575
|
+
readonly parts: readonly ({
|
|
21576
|
+
readonly type: "text";
|
|
21577
|
+
readonly text: string;
|
|
21578
|
+
} | {
|
|
21579
|
+
readonly type: "image";
|
|
21580
|
+
readonly data: string;
|
|
21581
|
+
readonly mimeType: string;
|
|
21582
|
+
})[];
|
|
21583
|
+
}>;
|
|
21584
|
+
fromText: (text: string) => {
|
|
21585
|
+
readonly parts: readonly ({
|
|
21586
|
+
readonly type: "text";
|
|
21587
|
+
readonly text: string;
|
|
21588
|
+
} | {
|
|
21589
|
+
readonly type: "image";
|
|
21590
|
+
readonly data: string;
|
|
21591
|
+
readonly mimeType: string;
|
|
21592
|
+
})[];
|
|
21593
|
+
};
|
|
21594
|
+
text: (prompt: Prompt) => string;
|
|
21595
|
+
}>, never, never>;
|
|
21596
|
+
readonly delivery: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["steer", "followUp"]>>>, Schema.optionalKey<Schema.Literals<readonly ["steer", "followUp"]>>, never, never>;
|
|
21597
|
+
}>;
|
|
20470
21598
|
}, Schema.Struct<{
|
|
20471
21599
|
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
20472
21600
|
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
@@ -25063,5 +26191,5 @@ type DateTimeUtcFromMillis = import__codeworksh_plugin_schema.DateTimeUtcFromMil
|
|
|
25063
26191
|
type EventSchema = import__codeworksh_plugin_event.EventSchema;
|
|
25064
26192
|
type SandboxError = import__codeworksh_plugin_sandbox_errors.SandboxError;
|
|
25065
26193
|
type optional = import__codeworksh_plugin_schema.optional;
|
|
25066
|
-
export { control_d_exports as Control, db_d_exports as Database, DateTimeUtcFromMillis, event_d_exports as Event, list_d_exports as EventList, registry_d_exports as EventRegistry, EventSchema, global_d_exports as Global, harness_d_exports as Harness, location_d_exports as Location, catalog_d_exports as ModelCatalog, index_d_exports as Plugin, schema_d_exports as PromptSchema, run_d_exports as Runner, sandbox_d_exports as Sandbox, SandboxError, session_d_exports as Session, session_d_exports$1 as SessionStore, settings_d_exports as Settings, state_d_exports as State, tool_d_exports as Tool, optional };
|
|
26194
|
+
export { control_d_exports as Control, db_d_exports as Database, DateTimeUtcFromMillis, event_d_exports as Event, list_d_exports as EventList, registry_d_exports as EventRegistry, EventSchema, global_d_exports as Global, harness_d_exports as Harness, location_d_exports as Location, catalog_d_exports as ModelCatalog, index_d_exports as Plugin, project_d_exports as Project, schema_d_exports as PromptSchema, run_d_exports as Runner, sandbox_d_exports as Sandbox, SandboxError, session_d_exports as Session, session_d_exports$1 as SessionStore, settings_d_exports as Settings, state_d_exports as State, tool_d_exports as Tool, optional };
|
|
25067
26195
|
//# sourceMappingURL=effect.d.mts.map
|