@opencode-ai/schema 0.0.0-next-16419 → 0.0.0-next-16473
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/dist/durable-event-manifest.d.ts +28 -16
- package/dist/event-manifest.d.ts +56 -32
- package/dist/session-event.d.ts +140 -80
- package/dist/session-event.js +3 -2
- package/dist/session-fork.d.ts +26 -0
- package/dist/session-fork.js +11 -0
- package/dist/session-pending.d.ts +0 -6
- package/dist/session-pending.js +1 -2
- package/dist/session.d.ts +51 -16
- package/dist/session.js +4 -3
- package/package.json +1 -1
|
@@ -371,14 +371,20 @@ export declare const SessionDurable: {
|
|
|
371
371
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
372
372
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
373
373
|
};
|
|
374
|
-
readonly
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
374
|
+
readonly boundary: import("effect/Schema").Union<readonly [import("effect/Schema").Struct<{
|
|
375
|
+
readonly type: import("effect/Schema").Literal<"before">;
|
|
376
|
+
readonly messageID: import("effect/Schema").brand<import("effect/Schema").String, "Session.Message.ID"> & {
|
|
377
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
378
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
379
|
+
};
|
|
380
|
+
}>, import("effect/Schema").Struct<{
|
|
381
|
+
readonly type: import("effect/Schema").Literal<"through">;
|
|
382
|
+
readonly messageID: import("effect/Schema").brand<import("effect/Schema").String, "Session.Message.ID"> & {
|
|
383
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
384
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
385
|
+
};
|
|
386
|
+
}>]>;
|
|
387
|
+
readonly instructions: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").$Record<import("effect/Schema").brand<import("effect/Schema").String, "Instruction.Key">, import("effect/Schema").brand<import("effect/Schema").String, "Instruction.Hash">>>>, import("effect/Schema").optionalKey<import("effect/Schema").$Record<import("effect/Schema").brand<import("effect/Schema").String, "Instruction.Key">, import("effect/Schema").brand<import("effect/Schema").String, "Instruction.Hash">>>, never, never>;
|
|
382
388
|
readonly sessionID: import("effect/Schema").brand<import("effect/Schema").String, "SessionID"> & {
|
|
383
389
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
384
390
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
@@ -396,14 +402,20 @@ export declare const SessionDurable: {
|
|
|
396
402
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
397
403
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
398
404
|
};
|
|
399
|
-
readonly
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
405
|
+
readonly boundary: import("effect/Schema").Union<readonly [import("effect/Schema").Struct<{
|
|
406
|
+
readonly type: import("effect/Schema").Literal<"before">;
|
|
407
|
+
readonly messageID: import("effect/Schema").brand<import("effect/Schema").String, "Session.Message.ID"> & {
|
|
408
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
409
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
410
|
+
};
|
|
411
|
+
}>, import("effect/Schema").Struct<{
|
|
412
|
+
readonly type: import("effect/Schema").Literal<"through">;
|
|
413
|
+
readonly messageID: import("effect/Schema").brand<import("effect/Schema").String, "Session.Message.ID"> & {
|
|
414
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
415
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
416
|
+
};
|
|
417
|
+
}>]>;
|
|
418
|
+
readonly instructions: import("effect/Schema").decodeTo<import("effect/Schema").optional<import("effect/Schema").toType<import("effect/Schema").$Record<import("effect/Schema").brand<import("effect/Schema").String, "Instruction.Key">, import("effect/Schema").brand<import("effect/Schema").String, "Instruction.Hash">>>>, import("effect/Schema").optionalKey<import("effect/Schema").$Record<import("effect/Schema").brand<import("effect/Schema").String, "Instruction.Key">, import("effect/Schema").brand<import("effect/Schema").String, "Instruction.Hash">>>, never, never>;
|
|
407
419
|
readonly sessionID: import("effect/Schema").brand<import("effect/Schema").String, "SessionID"> & {
|
|
408
420
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
409
421
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
package/dist/event-manifest.d.ts
CHANGED
|
@@ -2920,14 +2920,20 @@ export declare const ServerDefinitions: readonly [Schema.Struct<{
|
|
|
2920
2920
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
2921
2921
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
2922
2922
|
};
|
|
2923
|
-
readonly
|
|
2924
|
-
|
|
2925
|
-
|
|
2926
|
-
|
|
2927
|
-
|
|
2928
|
-
|
|
2929
|
-
|
|
2930
|
-
|
|
2923
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
2924
|
+
readonly type: Schema.Literal<"before">;
|
|
2925
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
2926
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
2927
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
2928
|
+
};
|
|
2929
|
+
}>, Schema.Struct<{
|
|
2930
|
+
readonly type: Schema.Literal<"through">;
|
|
2931
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
2932
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
2933
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
2934
|
+
};
|
|
2935
|
+
}>]>;
|
|
2936
|
+
readonly instructions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>>, Schema.optionalKey<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>, never, never>;
|
|
2931
2937
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
2932
2938
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
2933
2939
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
@@ -2945,14 +2951,20 @@ export declare const ServerDefinitions: readonly [Schema.Struct<{
|
|
|
2945
2951
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
2946
2952
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
2947
2953
|
};
|
|
2948
|
-
readonly
|
|
2949
|
-
|
|
2950
|
-
|
|
2951
|
-
|
|
2952
|
-
|
|
2953
|
-
|
|
2954
|
-
|
|
2955
|
-
|
|
2954
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
2955
|
+
readonly type: Schema.Literal<"before">;
|
|
2956
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
2957
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
2958
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
2959
|
+
};
|
|
2960
|
+
}>, Schema.Struct<{
|
|
2961
|
+
readonly type: Schema.Literal<"through">;
|
|
2962
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
2963
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
2964
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
2965
|
+
};
|
|
2966
|
+
}>]>;
|
|
2967
|
+
readonly instructions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>>, Schema.optionalKey<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>, never, never>;
|
|
2956
2968
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
2957
2969
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
2958
2970
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
@@ -8142,14 +8154,20 @@ export declare const Definitions: readonly [Schema.Struct<{
|
|
|
8142
8154
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
8143
8155
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
8144
8156
|
};
|
|
8145
|
-
readonly
|
|
8146
|
-
|
|
8147
|
-
|
|
8148
|
-
|
|
8149
|
-
|
|
8150
|
-
|
|
8151
|
-
|
|
8152
|
-
|
|
8157
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
8158
|
+
readonly type: Schema.Literal<"before">;
|
|
8159
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
8160
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
8161
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
8162
|
+
};
|
|
8163
|
+
}>, Schema.Struct<{
|
|
8164
|
+
readonly type: Schema.Literal<"through">;
|
|
8165
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
8166
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
8167
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
8168
|
+
};
|
|
8169
|
+
}>]>;
|
|
8170
|
+
readonly instructions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>>, Schema.optionalKey<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>, never, never>;
|
|
8153
8171
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
8154
8172
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
8155
8173
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
@@ -8167,14 +8185,20 @@ export declare const Definitions: readonly [Schema.Struct<{
|
|
|
8167
8185
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
8168
8186
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
8169
8187
|
};
|
|
8170
|
-
readonly
|
|
8171
|
-
|
|
8172
|
-
|
|
8173
|
-
|
|
8174
|
-
|
|
8175
|
-
|
|
8176
|
-
|
|
8177
|
-
|
|
8188
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
8189
|
+
readonly type: Schema.Literal<"before">;
|
|
8190
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
8191
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
8192
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
8193
|
+
};
|
|
8194
|
+
}>, Schema.Struct<{
|
|
8195
|
+
readonly type: Schema.Literal<"through">;
|
|
8196
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
8197
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
8198
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
8199
|
+
};
|
|
8200
|
+
}>]>;
|
|
8201
|
+
readonly instructions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>>, Schema.optionalKey<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>, never, never>;
|
|
8178
8202
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
8179
8203
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
8180
8204
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
package/dist/session-event.d.ts
CHANGED
|
@@ -534,14 +534,20 @@ export declare const Forked: Schema.Struct<{
|
|
|
534
534
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
535
535
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
536
536
|
};
|
|
537
|
-
readonly
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
537
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
538
|
+
readonly type: Schema.Literal<"before">;
|
|
539
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
540
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
541
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
542
|
+
};
|
|
543
|
+
}>, Schema.Struct<{
|
|
544
|
+
readonly type: Schema.Literal<"through">;
|
|
545
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
546
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
547
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
548
|
+
};
|
|
549
|
+
}>]>;
|
|
550
|
+
readonly instructions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>>, Schema.optionalKey<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>, never, never>;
|
|
545
551
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
546
552
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
547
553
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
@@ -559,14 +565,20 @@ export declare const Forked: Schema.Struct<{
|
|
|
559
565
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
560
566
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
561
567
|
};
|
|
562
|
-
readonly
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
568
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
569
|
+
readonly type: Schema.Literal<"before">;
|
|
570
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
571
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
572
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
573
|
+
};
|
|
574
|
+
}>, Schema.Struct<{
|
|
575
|
+
readonly type: Schema.Literal<"through">;
|
|
576
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
577
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
578
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
579
|
+
};
|
|
580
|
+
}>]>;
|
|
581
|
+
readonly instructions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>>, Schema.optionalKey<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>, never, never>;
|
|
570
582
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
571
583
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
572
584
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
@@ -3738,14 +3750,20 @@ export declare const Definitions: readonly [Schema.Struct<{
|
|
|
3738
3750
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
3739
3751
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
3740
3752
|
};
|
|
3741
|
-
readonly
|
|
3742
|
-
|
|
3743
|
-
|
|
3744
|
-
|
|
3745
|
-
|
|
3746
|
-
|
|
3747
|
-
|
|
3748
|
-
|
|
3753
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
3754
|
+
readonly type: Schema.Literal<"before">;
|
|
3755
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
3756
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
3757
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
3758
|
+
};
|
|
3759
|
+
}>, Schema.Struct<{
|
|
3760
|
+
readonly type: Schema.Literal<"through">;
|
|
3761
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
3762
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
3763
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
3764
|
+
};
|
|
3765
|
+
}>]>;
|
|
3766
|
+
readonly instructions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>>, Schema.optionalKey<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>, never, never>;
|
|
3749
3767
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
3750
3768
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
3751
3769
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
@@ -3763,14 +3781,20 @@ export declare const Definitions: readonly [Schema.Struct<{
|
|
|
3763
3781
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
3764
3782
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
3765
3783
|
};
|
|
3766
|
-
readonly
|
|
3767
|
-
|
|
3768
|
-
|
|
3769
|
-
|
|
3770
|
-
|
|
3771
|
-
|
|
3772
|
-
|
|
3773
|
-
|
|
3784
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
3785
|
+
readonly type: Schema.Literal<"before">;
|
|
3786
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
3787
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
3788
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
3789
|
+
};
|
|
3790
|
+
}>, Schema.Struct<{
|
|
3791
|
+
readonly type: Schema.Literal<"through">;
|
|
3792
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
3793
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
3794
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
3795
|
+
};
|
|
3796
|
+
}>]>;
|
|
3797
|
+
readonly instructions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>>, Schema.optionalKey<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>, never, never>;
|
|
3774
3798
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
3775
3799
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
3776
3800
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
@@ -6779,14 +6803,20 @@ export declare const DurableDefinitions: readonly [...((Schema.Struct<{
|
|
|
6779
6803
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
6780
6804
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
6781
6805
|
};
|
|
6782
|
-
readonly
|
|
6783
|
-
|
|
6784
|
-
|
|
6785
|
-
|
|
6786
|
-
|
|
6787
|
-
|
|
6788
|
-
|
|
6789
|
-
|
|
6806
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
6807
|
+
readonly type: Schema.Literal<"before">;
|
|
6808
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
6809
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
6810
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
6811
|
+
};
|
|
6812
|
+
}>, Schema.Struct<{
|
|
6813
|
+
readonly type: Schema.Literal<"through">;
|
|
6814
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
6815
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
6816
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
6817
|
+
};
|
|
6818
|
+
}>]>;
|
|
6819
|
+
readonly instructions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>>, Schema.optionalKey<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>, never, never>;
|
|
6790
6820
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
6791
6821
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
6792
6822
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
@@ -6804,14 +6834,20 @@ export declare const DurableDefinitions: readonly [...((Schema.Struct<{
|
|
|
6804
6834
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
6805
6835
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
6806
6836
|
};
|
|
6807
|
-
readonly
|
|
6808
|
-
|
|
6809
|
-
|
|
6810
|
-
|
|
6811
|
-
|
|
6812
|
-
|
|
6813
|
-
|
|
6814
|
-
|
|
6837
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
6838
|
+
readonly type: Schema.Literal<"before">;
|
|
6839
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
6840
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
6841
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
6842
|
+
};
|
|
6843
|
+
}>, Schema.Struct<{
|
|
6844
|
+
readonly type: Schema.Literal<"through">;
|
|
6845
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
6846
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
6847
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
6848
|
+
};
|
|
6849
|
+
}>]>;
|
|
6850
|
+
readonly instructions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>>, Schema.optionalKey<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>, never, never>;
|
|
6815
6851
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
6816
6852
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
6817
6853
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
@@ -9636,14 +9672,20 @@ export declare const Durable: Schema.Union<readonly [...((Schema.Struct<{
|
|
|
9636
9672
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
9637
9673
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
9638
9674
|
};
|
|
9639
|
-
readonly
|
|
9640
|
-
|
|
9641
|
-
|
|
9642
|
-
|
|
9643
|
-
|
|
9644
|
-
|
|
9645
|
-
|
|
9646
|
-
|
|
9675
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
9676
|
+
readonly type: Schema.Literal<"before">;
|
|
9677
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
9678
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
9679
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
9680
|
+
};
|
|
9681
|
+
}>, Schema.Struct<{
|
|
9682
|
+
readonly type: Schema.Literal<"through">;
|
|
9683
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
9684
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
9685
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
9686
|
+
};
|
|
9687
|
+
}>]>;
|
|
9688
|
+
readonly instructions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>>, Schema.optionalKey<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>, never, never>;
|
|
9647
9689
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
9648
9690
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
9649
9691
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
@@ -9661,14 +9703,20 @@ export declare const Durable: Schema.Union<readonly [...((Schema.Struct<{
|
|
|
9661
9703
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
9662
9704
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
9663
9705
|
};
|
|
9664
|
-
readonly
|
|
9665
|
-
|
|
9666
|
-
|
|
9667
|
-
|
|
9668
|
-
|
|
9669
|
-
|
|
9670
|
-
|
|
9671
|
-
|
|
9706
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
9707
|
+
readonly type: Schema.Literal<"before">;
|
|
9708
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
9709
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
9710
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
9711
|
+
};
|
|
9712
|
+
}>, Schema.Struct<{
|
|
9713
|
+
readonly type: Schema.Literal<"through">;
|
|
9714
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
9715
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
9716
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
9717
|
+
};
|
|
9718
|
+
}>]>;
|
|
9719
|
+
readonly instructions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>>, Schema.optionalKey<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>, never, never>;
|
|
9672
9720
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
9673
9721
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
9674
9722
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
@@ -12560,14 +12608,20 @@ export declare const All: Schema.toTaggedUnion<"type", readonly [Schema.Struct<{
|
|
|
12560
12608
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
12561
12609
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
12562
12610
|
};
|
|
12563
|
-
readonly
|
|
12564
|
-
|
|
12565
|
-
|
|
12566
|
-
|
|
12567
|
-
|
|
12568
|
-
|
|
12569
|
-
|
|
12570
|
-
|
|
12611
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
12612
|
+
readonly type: Schema.Literal<"before">;
|
|
12613
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
12614
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
12615
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
12616
|
+
};
|
|
12617
|
+
}>, Schema.Struct<{
|
|
12618
|
+
readonly type: Schema.Literal<"through">;
|
|
12619
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
12620
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
12621
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
12622
|
+
};
|
|
12623
|
+
}>]>;
|
|
12624
|
+
readonly instructions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>>, Schema.optionalKey<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>, never, never>;
|
|
12571
12625
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
12572
12626
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
12573
12627
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
@@ -12585,14 +12639,20 @@ export declare const All: Schema.toTaggedUnion<"type", readonly [Schema.Struct<{
|
|
|
12585
12639
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
12586
12640
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
12587
12641
|
};
|
|
12588
|
-
readonly
|
|
12589
|
-
|
|
12590
|
-
|
|
12591
|
-
|
|
12592
|
-
|
|
12593
|
-
|
|
12594
|
-
|
|
12595
|
-
|
|
12642
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
12643
|
+
readonly type: Schema.Literal<"before">;
|
|
12644
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
12645
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
12646
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
12647
|
+
};
|
|
12648
|
+
}>, Schema.Struct<{
|
|
12649
|
+
readonly type: Schema.Literal<"through">;
|
|
12650
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
12651
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
12652
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
12653
|
+
};
|
|
12654
|
+
}>]>;
|
|
12655
|
+
readonly instructions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>>, Schema.optionalKey<Schema.$Record<Schema.brand<Schema.String, "Instruction.Key">, Schema.brand<Schema.String, "Instruction.Hash">>>, never, never>;
|
|
12596
12656
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
12597
12657
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
12598
12658
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
package/dist/session-event.js
CHANGED
|
@@ -21,6 +21,7 @@ import { Snapshot } from "./snapshot.js";
|
|
|
21
21
|
import { TokenUsage } from "./token-usage.js";
|
|
22
22
|
import { SessionPending } from "./session-pending.js";
|
|
23
23
|
import { Project } from "./project.js";
|
|
24
|
+
import { SessionFork } from "./session-fork.js";
|
|
24
25
|
export { FileAttachment };
|
|
25
26
|
export const Source = Schema.Struct({
|
|
26
27
|
start: NonNegativeInt,
|
|
@@ -107,8 +108,8 @@ export const Forked = Event.durable({
|
|
|
107
108
|
schema: {
|
|
108
109
|
...Base,
|
|
109
110
|
parentID: SessionID,
|
|
110
|
-
|
|
111
|
-
|
|
111
|
+
boundary: SessionFork.Boundary,
|
|
112
|
+
instructions: Instruction.Values.pipe(optional),
|
|
112
113
|
},
|
|
113
114
|
});
|
|
114
115
|
export const InputPromoted = Event.durable({
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
export * as SessionFork from "./session-fork.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
export declare const Boundary: Schema.Union<readonly [Schema.Struct<{
|
|
4
|
+
readonly type: Schema.Literal<"before">;
|
|
5
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
6
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
7
|
+
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
8
|
+
};
|
|
9
|
+
}>, Schema.Struct<{
|
|
10
|
+
readonly type: Schema.Literal<"through">;
|
|
11
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
12
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
13
|
+
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
14
|
+
};
|
|
15
|
+
}>]>;
|
|
16
|
+
export type Boundary = typeof Boundary.Type;
|
|
17
|
+
export declare const RequestBoundary: Schema.Union<readonly [Schema.Struct<{
|
|
18
|
+
readonly type: Schema.Literal<"before">;
|
|
19
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
20
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
21
|
+
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
22
|
+
};
|
|
23
|
+
}>, Schema.Struct<{
|
|
24
|
+
readonly type: Schema.Literal<"through">;
|
|
25
|
+
}>]>;
|
|
26
|
+
export type RequestBoundary = typeof RequestBoundary.Type;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export * as SessionFork from "./session-fork.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { SessionMessage } from "./session-message.js";
|
|
4
|
+
export const Boundary = Schema.Union([
|
|
5
|
+
Schema.Struct({ type: Schema.Literal("before"), messageID: SessionMessage.ID }),
|
|
6
|
+
Schema.Struct({ type: Schema.Literal("through"), messageID: SessionMessage.ID }),
|
|
7
|
+
]).annotate({ identifier: "Session.ForkBoundary" });
|
|
8
|
+
export const RequestBoundary = Schema.Union([
|
|
9
|
+
Schema.Struct({ type: Schema.Literal("before"), messageID: SessionMessage.ID }),
|
|
10
|
+
Schema.Struct({ type: Schema.Literal("through") }),
|
|
11
|
+
]).annotate({ identifier: "Session.ForkRequestBoundary" });
|
|
@@ -463,7 +463,6 @@ export declare const User: Schema.Struct<{
|
|
|
463
463
|
}>>>, never, never>;
|
|
464
464
|
}>;
|
|
465
465
|
readonly delivery: Schema.Literals<readonly ["steer", "queue"]>;
|
|
466
|
-
readonly admittedSeq: Schema.Int;
|
|
467
466
|
readonly id: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
468
467
|
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
469
468
|
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
@@ -484,7 +483,6 @@ export declare const Synthetic: Schema.Struct<{
|
|
|
484
483
|
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
485
484
|
}>;
|
|
486
485
|
readonly delivery: Schema.Literals<readonly ["steer", "queue"]>;
|
|
487
|
-
readonly admittedSeq: Schema.Int;
|
|
488
486
|
readonly id: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
489
487
|
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
490
488
|
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
@@ -499,7 +497,6 @@ export interface Compaction extends Schema.Schema.Type<typeof Compaction> {
|
|
|
499
497
|
}
|
|
500
498
|
export declare const Compaction: Schema.Struct<{
|
|
501
499
|
readonly type: Schema.tag<"compaction">;
|
|
502
|
-
readonly admittedSeq: Schema.Int;
|
|
503
500
|
readonly id: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
504
501
|
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
505
502
|
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
@@ -617,7 +614,6 @@ export declare const Info: Schema.Union<readonly [Schema.Struct<{
|
|
|
617
614
|
}>>>, never, never>;
|
|
618
615
|
}>;
|
|
619
616
|
readonly delivery: Schema.Literals<readonly ["steer", "queue"]>;
|
|
620
|
-
readonly admittedSeq: Schema.Int;
|
|
621
617
|
readonly id: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
622
618
|
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
623
619
|
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
@@ -635,7 +631,6 @@ export declare const Info: Schema.Union<readonly [Schema.Struct<{
|
|
|
635
631
|
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
636
632
|
}>;
|
|
637
633
|
readonly delivery: Schema.Literals<readonly ["steer", "queue"]>;
|
|
638
|
-
readonly admittedSeq: Schema.Int;
|
|
639
634
|
readonly id: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
640
635
|
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
641
636
|
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
@@ -647,7 +642,6 @@ export declare const Info: Schema.Union<readonly [Schema.Struct<{
|
|
|
647
642
|
readonly timeCreated: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
648
643
|
}>, Schema.Struct<{
|
|
649
644
|
readonly type: Schema.tag<"compaction">;
|
|
650
|
-
readonly admittedSeq: Schema.Int;
|
|
651
645
|
readonly id: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
652
646
|
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
653
647
|
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
package/dist/session-pending.js
CHANGED
|
@@ -2,7 +2,7 @@ export * as SessionPending from "./session-pending.js";
|
|
|
2
2
|
import { Schema } from "effect";
|
|
3
3
|
import { optional } from "./schema.js";
|
|
4
4
|
import { Prompt } from "./prompt.js";
|
|
5
|
-
import { DateTimeUtcFromMillis
|
|
5
|
+
import { DateTimeUtcFromMillis } from "./schema.js";
|
|
6
6
|
import { SessionDelivery } from "./session-delivery.js";
|
|
7
7
|
import { SessionID } from "./session-id.js";
|
|
8
8
|
import { SessionMessage } from "./session-message.js";
|
|
@@ -28,7 +28,6 @@ export const SyntheticMessage = Schema.Struct({
|
|
|
28
28
|
}).annotate({ identifier: "SessionPending.SyntheticMessage" });
|
|
29
29
|
export const Message = Schema.Union([UserMessage, SyntheticMessage]).pipe(Schema.toTaggedUnion("type"), Schema.annotate({ identifier: "SessionPending.Message" }));
|
|
30
30
|
const Admitted = {
|
|
31
|
-
admittedSeq: NonNegativeInt,
|
|
32
31
|
id: SessionMessage.ID,
|
|
33
32
|
sessionID: SessionID,
|
|
34
33
|
timeCreated: DateTimeUtcFromMillis,
|
package/dist/session.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ import { Schema } from "effect";
|
|
|
3
3
|
import { SessionEvent } from "./session-event.js";
|
|
4
4
|
import { SessionID } from "./session-id.js";
|
|
5
5
|
import { Revert } from "./session-revert.js";
|
|
6
|
+
import { SessionFork } from "./session-fork.js";
|
|
6
7
|
export declare const ID: Schema.brand<Schema.String, "SessionID"> & {
|
|
7
8
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
8
9
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
@@ -10,6 +11,30 @@ export declare const ID: Schema.brand<Schema.String, "SessionID"> & {
|
|
|
10
11
|
export type ID = SessionID;
|
|
11
12
|
export declare const Event: typeof SessionEvent;
|
|
12
13
|
export { Revert };
|
|
14
|
+
export declare const ForkBoundary: Schema.Union<readonly [Schema.Struct<{
|
|
15
|
+
readonly type: Schema.Literal<"before">;
|
|
16
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
17
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
18
|
+
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
19
|
+
};
|
|
20
|
+
}>, Schema.Struct<{
|
|
21
|
+
readonly type: Schema.Literal<"through">;
|
|
22
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
23
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
24
|
+
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
25
|
+
};
|
|
26
|
+
}>]>;
|
|
27
|
+
export type ForkBoundary = SessionFork.Boundary;
|
|
28
|
+
export declare const ForkRequestBoundary: Schema.Union<readonly [Schema.Struct<{
|
|
29
|
+
readonly type: Schema.Literal<"before">;
|
|
30
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
31
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
32
|
+
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
33
|
+
};
|
|
34
|
+
}>, Schema.Struct<{
|
|
35
|
+
readonly type: Schema.Literal<"through">;
|
|
36
|
+
}>]>;
|
|
37
|
+
export type ForkRequestBoundary = SessionFork.RequestBoundary;
|
|
13
38
|
export interface Info extends Schema.Schema.Type<typeof Info> {
|
|
14
39
|
}
|
|
15
40
|
export declare const Info: Schema.Struct<{
|
|
@@ -29,27 +54,37 @@ export declare const Info: Schema.Struct<{
|
|
|
29
54
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
30
55
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
31
56
|
};
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
57
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
58
|
+
readonly type: Schema.Literal<"before">;
|
|
59
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
60
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
61
|
+
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
62
|
+
};
|
|
63
|
+
}>, Schema.Struct<{
|
|
64
|
+
readonly type: Schema.Literal<"through">;
|
|
65
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
66
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
67
|
+
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
68
|
+
};
|
|
69
|
+
}>]>;
|
|
40
70
|
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
41
71
|
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
42
72
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
43
73
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
44
74
|
};
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
75
|
+
readonly boundary: Schema.Union<readonly [Schema.Struct<{
|
|
76
|
+
readonly type: Schema.Literal<"before">;
|
|
77
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
78
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
79
|
+
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
80
|
+
};
|
|
81
|
+
}>, Schema.Struct<{
|
|
82
|
+
readonly type: Schema.Literal<"through">;
|
|
83
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
84
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
85
|
+
fromEvent: (eventID: import("./event.js").ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
86
|
+
};
|
|
87
|
+
}>]>;
|
|
53
88
|
}>>, never, never>;
|
|
54
89
|
readonly projectID: Schema.brand<Schema.String, "Project.ID"> & {
|
|
55
90
|
global: string & import("effect/Brand").Brand<"Project.ID">;
|
package/dist/session.js
CHANGED
|
@@ -7,20 +7,21 @@ import { Project } from "./project.js";
|
|
|
7
7
|
import { DateTimeUtcFromMillis, optional, RelativePath } from "./schema.js";
|
|
8
8
|
import { SessionEvent } from "./session-event.js";
|
|
9
9
|
import { SessionID } from "./session-id.js";
|
|
10
|
-
import { SessionMessage } from "./session-message.js";
|
|
11
10
|
import { Money } from "./money.js";
|
|
12
11
|
import { TokenUsage } from "./token-usage.js";
|
|
13
12
|
import { Revert } from "./session-revert.js";
|
|
13
|
+
import { SessionFork } from "./session-fork.js";
|
|
14
14
|
export const ID = SessionID;
|
|
15
15
|
export const Event = SessionEvent;
|
|
16
16
|
export { Revert };
|
|
17
|
+
export const ForkBoundary = SessionFork.Boundary;
|
|
18
|
+
export const ForkRequestBoundary = SessionFork.RequestBoundary;
|
|
17
19
|
export const Info = Schema.Struct({
|
|
18
20
|
id: ID,
|
|
19
21
|
parentID: ID.pipe(optional),
|
|
20
22
|
fork: Schema.Struct({
|
|
21
23
|
sessionID: ID,
|
|
22
|
-
|
|
23
|
-
messageID: SessionMessage.ID.pipe(optional),
|
|
24
|
+
boundary: ForkBoundary,
|
|
24
25
|
}).pipe(optional),
|
|
25
26
|
projectID: Project.ID,
|
|
26
27
|
agent: Agent.ID.pipe(optional),
|