@opencode-ai/protocol 0.0.0-dev-18293 → 0.0.0-dev-18296
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/groups/event.d.ts +536 -0
- package/dist/groups/session.d.ts +586 -1
- package/dist/groups/session.js +10 -0
- package/package.json +2 -2
package/dist/groups/event.d.ts
CHANGED
|
@@ -3881,6 +3881,214 @@ export declare const EventGroup: HttpApiGroup.HttpApiGroup<"server.event", HttpA
|
|
|
3881
3881
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
3882
3882
|
};
|
|
3883
3883
|
}>;
|
|
3884
|
+
}, Schema.Struct<{
|
|
3885
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
3886
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
3887
|
+
};
|
|
3888
|
+
readonly created: Schema.Finite;
|
|
3889
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
3890
|
+
readonly type: Schema.Literal<"session.message.content.updated">;
|
|
3891
|
+
readonly durable: Schema.Struct<{
|
|
3892
|
+
readonly aggregateID: Schema.String;
|
|
3893
|
+
readonly seq: Schema.brand<Schema.Int, "Event.Seq">;
|
|
3894
|
+
readonly version: Schema.decodeTo<Schema.toType<Schema.brand<Schema.Int, "Event.Version">>, Schema.Literal<number>, never, never>;
|
|
3895
|
+
}>;
|
|
3896
|
+
readonly location: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
3897
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
3898
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
3899
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
3900
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
3901
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
3902
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
3903
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
3904
|
+
}>, never, never>;
|
|
3905
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
3906
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
3907
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
3908
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
3909
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
3910
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
3911
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
3912
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
3913
|
+
}>, never, never>;
|
|
3914
|
+
}>>, never, never>;
|
|
3915
|
+
readonly data: Schema.Struct<{
|
|
3916
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
3917
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
3918
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
3919
|
+
};
|
|
3920
|
+
readonly content: Schema.$Array<Schema.toEncoded<Schema.toTaggedUnion<"type", readonly [Schema.Struct<{
|
|
3921
|
+
readonly type: Schema.tag<"text">;
|
|
3922
|
+
readonly text: Schema.String;
|
|
3923
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
3924
|
+
}>, Schema.Struct<{
|
|
3925
|
+
readonly type: Schema.tag<"reasoning">;
|
|
3926
|
+
readonly text: Schema.String;
|
|
3927
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
3928
|
+
readonly time: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
3929
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
3930
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
3931
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
3932
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
3933
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
3934
|
+
}>>, never, never>;
|
|
3935
|
+
}>, Schema.Struct<{
|
|
3936
|
+
readonly type: Schema.tag<"tool">;
|
|
3937
|
+
readonly id: Schema.String;
|
|
3938
|
+
readonly name: Schema.String;
|
|
3939
|
+
readonly executed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
3940
|
+
readonly providerState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
3941
|
+
readonly providerResultState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
3942
|
+
readonly state: Schema.toTaggedUnion<"status", readonly [Schema.Struct<{
|
|
3943
|
+
readonly status: Schema.tag<"streaming">;
|
|
3944
|
+
readonly input: Schema.String;
|
|
3945
|
+
}>, Schema.Struct<{
|
|
3946
|
+
readonly status: Schema.tag<"running">;
|
|
3947
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
3948
|
+
readonly metadata: Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>;
|
|
3949
|
+
}>, Schema.Struct<{
|
|
3950
|
+
readonly status: Schema.tag<"completed">;
|
|
3951
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
3952
|
+
readonly content: Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
3953
|
+
readonly type: Schema.Literal<"text">;
|
|
3954
|
+
readonly text: Schema.String;
|
|
3955
|
+
}>, Schema.Struct<{
|
|
3956
|
+
readonly type: Schema.Literal<"file">;
|
|
3957
|
+
readonly uri: Schema.String;
|
|
3958
|
+
readonly mime: Schema.String;
|
|
3959
|
+
readonly name: Schema.optional<Schema.String>;
|
|
3960
|
+
}>]>>;
|
|
3961
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
3962
|
+
}>, Schema.Struct<{
|
|
3963
|
+
readonly status: Schema.tag<"error">;
|
|
3964
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
3965
|
+
readonly error: Schema.Struct<{
|
|
3966
|
+
readonly type: Schema.String;
|
|
3967
|
+
readonly message: Schema.String;
|
|
3968
|
+
readonly status: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
3969
|
+
}>;
|
|
3970
|
+
readonly content: Schema.decodeTo<Schema.optional<Schema.toType<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
3971
|
+
readonly type: Schema.Literal<"text">;
|
|
3972
|
+
readonly text: Schema.String;
|
|
3973
|
+
}>, Schema.Struct<{
|
|
3974
|
+
readonly type: Schema.Literal<"file">;
|
|
3975
|
+
readonly uri: Schema.String;
|
|
3976
|
+
readonly mime: Schema.String;
|
|
3977
|
+
readonly name: Schema.optional<Schema.String>;
|
|
3978
|
+
}>]>>>>, Schema.optionalKey<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
3979
|
+
readonly type: Schema.Literal<"text">;
|
|
3980
|
+
readonly text: Schema.String;
|
|
3981
|
+
}>, Schema.Struct<{
|
|
3982
|
+
readonly type: Schema.Literal<"file">;
|
|
3983
|
+
readonly uri: Schema.String;
|
|
3984
|
+
readonly mime: Schema.String;
|
|
3985
|
+
readonly name: Schema.optional<Schema.String>;
|
|
3986
|
+
}>]>>>, never, never>;
|
|
3987
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
3988
|
+
}>]>;
|
|
3989
|
+
readonly time: Schema.Struct<{
|
|
3990
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
3991
|
+
readonly ran: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
3992
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
3993
|
+
}>;
|
|
3994
|
+
}>]>>>;
|
|
3995
|
+
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
3996
|
+
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
3997
|
+
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
3998
|
+
};
|
|
3999
|
+
}>;
|
|
4000
|
+
}> & {
|
|
4001
|
+
type: "session.message.content.updated";
|
|
4002
|
+
durability: "durable";
|
|
4003
|
+
durable: {
|
|
4004
|
+
readonly version: number;
|
|
4005
|
+
readonly aggregate: string;
|
|
4006
|
+
};
|
|
4007
|
+
data: Schema.Struct<{
|
|
4008
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
4009
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
4010
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
4011
|
+
};
|
|
4012
|
+
readonly content: Schema.$Array<Schema.toEncoded<Schema.toTaggedUnion<"type", readonly [Schema.Struct<{
|
|
4013
|
+
readonly type: Schema.tag<"text">;
|
|
4014
|
+
readonly text: Schema.String;
|
|
4015
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
4016
|
+
}>, Schema.Struct<{
|
|
4017
|
+
readonly type: Schema.tag<"reasoning">;
|
|
4018
|
+
readonly text: Schema.String;
|
|
4019
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
4020
|
+
readonly time: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
4021
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
4022
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
4023
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
4024
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
4025
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
4026
|
+
}>>, never, never>;
|
|
4027
|
+
}>, Schema.Struct<{
|
|
4028
|
+
readonly type: Schema.tag<"tool">;
|
|
4029
|
+
readonly id: Schema.String;
|
|
4030
|
+
readonly name: Schema.String;
|
|
4031
|
+
readonly executed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
4032
|
+
readonly providerState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
4033
|
+
readonly providerResultState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
4034
|
+
readonly state: Schema.toTaggedUnion<"status", readonly [Schema.Struct<{
|
|
4035
|
+
readonly status: Schema.tag<"streaming">;
|
|
4036
|
+
readonly input: Schema.String;
|
|
4037
|
+
}>, Schema.Struct<{
|
|
4038
|
+
readonly status: Schema.tag<"running">;
|
|
4039
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
4040
|
+
readonly metadata: Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>;
|
|
4041
|
+
}>, Schema.Struct<{
|
|
4042
|
+
readonly status: Schema.tag<"completed">;
|
|
4043
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
4044
|
+
readonly content: Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
4045
|
+
readonly type: Schema.Literal<"text">;
|
|
4046
|
+
readonly text: Schema.String;
|
|
4047
|
+
}>, Schema.Struct<{
|
|
4048
|
+
readonly type: Schema.Literal<"file">;
|
|
4049
|
+
readonly uri: Schema.String;
|
|
4050
|
+
readonly mime: Schema.String;
|
|
4051
|
+
readonly name: Schema.optional<Schema.String>;
|
|
4052
|
+
}>]>>;
|
|
4053
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
4054
|
+
}>, Schema.Struct<{
|
|
4055
|
+
readonly status: Schema.tag<"error">;
|
|
4056
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
4057
|
+
readonly error: Schema.Struct<{
|
|
4058
|
+
readonly type: Schema.String;
|
|
4059
|
+
readonly message: Schema.String;
|
|
4060
|
+
readonly status: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
4061
|
+
}>;
|
|
4062
|
+
readonly content: Schema.decodeTo<Schema.optional<Schema.toType<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
4063
|
+
readonly type: Schema.Literal<"text">;
|
|
4064
|
+
readonly text: Schema.String;
|
|
4065
|
+
}>, Schema.Struct<{
|
|
4066
|
+
readonly type: Schema.Literal<"file">;
|
|
4067
|
+
readonly uri: Schema.String;
|
|
4068
|
+
readonly mime: Schema.String;
|
|
4069
|
+
readonly name: Schema.optional<Schema.String>;
|
|
4070
|
+
}>]>>>>, Schema.optionalKey<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
4071
|
+
readonly type: Schema.Literal<"text">;
|
|
4072
|
+
readonly text: Schema.String;
|
|
4073
|
+
}>, Schema.Struct<{
|
|
4074
|
+
readonly type: Schema.Literal<"file">;
|
|
4075
|
+
readonly uri: Schema.String;
|
|
4076
|
+
readonly mime: Schema.String;
|
|
4077
|
+
readonly name: Schema.optional<Schema.String>;
|
|
4078
|
+
}>]>>>, never, never>;
|
|
4079
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
4080
|
+
}>]>;
|
|
4081
|
+
readonly time: Schema.Struct<{
|
|
4082
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
4083
|
+
readonly ran: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
4084
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
4085
|
+
}>;
|
|
4086
|
+
}>]>>>;
|
|
4087
|
+
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
4088
|
+
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
4089
|
+
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
4090
|
+
};
|
|
4091
|
+
}>;
|
|
3884
4092
|
}, Schema.Struct<{
|
|
3885
4093
|
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
3886
4094
|
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
@@ -6398,6 +6606,126 @@ export declare const EventGroup: HttpApiGroup.HttpApiGroup<"server.event", HttpA
|
|
|
6398
6606
|
readonly metadata?: {
|
|
6399
6607
|
readonly [x: string]: unknown;
|
|
6400
6608
|
} | undefined;
|
|
6609
|
+
} | {
|
|
6610
|
+
readonly id: string & import("effect/Brand").Brand<"Event.ID">;
|
|
6611
|
+
readonly data: {
|
|
6612
|
+
readonly messageID: string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
6613
|
+
readonly content: readonly ({
|
|
6614
|
+
readonly id: string;
|
|
6615
|
+
readonly type: "tool";
|
|
6616
|
+
readonly name: string;
|
|
6617
|
+
readonly time: {
|
|
6618
|
+
readonly created: number;
|
|
6619
|
+
readonly completed?: number | undefined;
|
|
6620
|
+
readonly ran?: number | undefined;
|
|
6621
|
+
};
|
|
6622
|
+
readonly state: {
|
|
6623
|
+
readonly status: "streaming";
|
|
6624
|
+
readonly input: string;
|
|
6625
|
+
} | {
|
|
6626
|
+
readonly status: "running";
|
|
6627
|
+
readonly input: {
|
|
6628
|
+
readonly [x: string]: unknown;
|
|
6629
|
+
};
|
|
6630
|
+
readonly metadata: {
|
|
6631
|
+
readonly [x: string]: Schema.Json;
|
|
6632
|
+
};
|
|
6633
|
+
} | {
|
|
6634
|
+
readonly content: readonly [{
|
|
6635
|
+
readonly type: "text";
|
|
6636
|
+
readonly text: string;
|
|
6637
|
+
} | {
|
|
6638
|
+
readonly type: "file";
|
|
6639
|
+
readonly uri: string;
|
|
6640
|
+
readonly mime: string;
|
|
6641
|
+
readonly name?: string | undefined;
|
|
6642
|
+
}, ...({
|
|
6643
|
+
readonly type: "text";
|
|
6644
|
+
readonly text: string;
|
|
6645
|
+
} | {
|
|
6646
|
+
readonly type: "file";
|
|
6647
|
+
readonly uri: string;
|
|
6648
|
+
readonly mime: string;
|
|
6649
|
+
readonly name?: string | undefined;
|
|
6650
|
+
})[]];
|
|
6651
|
+
readonly status: "completed";
|
|
6652
|
+
readonly input: {
|
|
6653
|
+
readonly [x: string]: unknown;
|
|
6654
|
+
};
|
|
6655
|
+
readonly metadata?: {
|
|
6656
|
+
readonly [x: string]: Schema.Json;
|
|
6657
|
+
} | undefined;
|
|
6658
|
+
} | {
|
|
6659
|
+
readonly error: {
|
|
6660
|
+
readonly type: string;
|
|
6661
|
+
readonly message: string;
|
|
6662
|
+
readonly status?: number | undefined;
|
|
6663
|
+
};
|
|
6664
|
+
readonly status: "error";
|
|
6665
|
+
readonly input: {
|
|
6666
|
+
readonly [x: string]: unknown;
|
|
6667
|
+
};
|
|
6668
|
+
readonly metadata?: {
|
|
6669
|
+
readonly [x: string]: Schema.Json;
|
|
6670
|
+
} | undefined;
|
|
6671
|
+
readonly content?: readonly [{
|
|
6672
|
+
readonly type: "text";
|
|
6673
|
+
readonly text: string;
|
|
6674
|
+
} | {
|
|
6675
|
+
readonly type: "file";
|
|
6676
|
+
readonly uri: string;
|
|
6677
|
+
readonly mime: string;
|
|
6678
|
+
readonly name?: string | undefined;
|
|
6679
|
+
}, ...({
|
|
6680
|
+
readonly type: "text";
|
|
6681
|
+
readonly text: string;
|
|
6682
|
+
} | {
|
|
6683
|
+
readonly type: "file";
|
|
6684
|
+
readonly uri: string;
|
|
6685
|
+
readonly mime: string;
|
|
6686
|
+
readonly name?: string | undefined;
|
|
6687
|
+
})[]] | undefined;
|
|
6688
|
+
};
|
|
6689
|
+
readonly executed?: boolean | undefined;
|
|
6690
|
+
readonly providerState?: {
|
|
6691
|
+
readonly [x: string]: unknown;
|
|
6692
|
+
} | undefined;
|
|
6693
|
+
readonly providerResultState?: {
|
|
6694
|
+
readonly [x: string]: unknown;
|
|
6695
|
+
} | undefined;
|
|
6696
|
+
} | {
|
|
6697
|
+
readonly type: "text";
|
|
6698
|
+
readonly text: string;
|
|
6699
|
+
readonly state?: {
|
|
6700
|
+
readonly [x: string]: unknown;
|
|
6701
|
+
} | undefined;
|
|
6702
|
+
} | {
|
|
6703
|
+
readonly type: "reasoning";
|
|
6704
|
+
readonly text: string;
|
|
6705
|
+
readonly time?: {
|
|
6706
|
+
readonly created: number;
|
|
6707
|
+
readonly completed?: number | undefined;
|
|
6708
|
+
} | undefined;
|
|
6709
|
+
readonly state?: {
|
|
6710
|
+
readonly [x: string]: unknown;
|
|
6711
|
+
} | undefined;
|
|
6712
|
+
})[];
|
|
6713
|
+
readonly sessionID: string & import("effect/Brand").Brand<"SessionID">;
|
|
6714
|
+
};
|
|
6715
|
+
readonly durable: {
|
|
6716
|
+
readonly aggregateID: string;
|
|
6717
|
+
readonly seq: number & import("effect/Brand").Brand<"Event.Seq">;
|
|
6718
|
+
readonly version: number & import("effect/Brand").Brand<"Event.Version">;
|
|
6719
|
+
};
|
|
6720
|
+
readonly type: "session.message.content.updated";
|
|
6721
|
+
readonly created: number;
|
|
6722
|
+
readonly location?: {
|
|
6723
|
+
readonly directory: string & import("effect/Brand").Brand<"AbsolutePath">;
|
|
6724
|
+
readonly workspaceID?: (string & import("effect/Brand").Brand<"Workspace.ID">) | undefined;
|
|
6725
|
+
} | undefined;
|
|
6726
|
+
readonly metadata?: {
|
|
6727
|
+
readonly [x: string]: unknown;
|
|
6728
|
+
} | undefined;
|
|
6401
6729
|
} | {
|
|
6402
6730
|
readonly id: string & import("effect/Brand").Brand<"Event.ID">;
|
|
6403
6731
|
readonly data: {
|
|
@@ -11786,6 +12114,214 @@ export declare const OpenCodeEvent: Schema.Union<readonly [Schema.Struct<{
|
|
|
11786
12114
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
11787
12115
|
};
|
|
11788
12116
|
}>;
|
|
12117
|
+
}, Schema.Struct<{
|
|
12118
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
12119
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
12120
|
+
};
|
|
12121
|
+
readonly created: Schema.Finite;
|
|
12122
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
12123
|
+
readonly type: Schema.Literal<"session.message.content.updated">;
|
|
12124
|
+
readonly durable: Schema.Struct<{
|
|
12125
|
+
readonly aggregateID: Schema.String;
|
|
12126
|
+
readonly seq: Schema.brand<Schema.Int, "Event.Seq">;
|
|
12127
|
+
readonly version: Schema.decodeTo<Schema.toType<Schema.brand<Schema.Int, "Event.Version">>, Schema.Literal<number>, never, never>;
|
|
12128
|
+
}>;
|
|
12129
|
+
readonly location: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
12130
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
12131
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
12132
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
12133
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
12134
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
12135
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
12136
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
12137
|
+
}>, never, never>;
|
|
12138
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
12139
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
12140
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
12141
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
12142
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
12143
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
12144
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
12145
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
12146
|
+
}>, never, never>;
|
|
12147
|
+
}>>, never, never>;
|
|
12148
|
+
readonly data: Schema.Struct<{
|
|
12149
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
12150
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
12151
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
12152
|
+
};
|
|
12153
|
+
readonly content: Schema.$Array<Schema.toEncoded<Schema.toTaggedUnion<"type", readonly [Schema.Struct<{
|
|
12154
|
+
readonly type: Schema.tag<"text">;
|
|
12155
|
+
readonly text: Schema.String;
|
|
12156
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
12157
|
+
}>, Schema.Struct<{
|
|
12158
|
+
readonly type: Schema.tag<"reasoning">;
|
|
12159
|
+
readonly text: Schema.String;
|
|
12160
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
12161
|
+
readonly time: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
12162
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
12163
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
12164
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
12165
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
12166
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
12167
|
+
}>>, never, never>;
|
|
12168
|
+
}>, Schema.Struct<{
|
|
12169
|
+
readonly type: Schema.tag<"tool">;
|
|
12170
|
+
readonly id: Schema.String;
|
|
12171
|
+
readonly name: Schema.String;
|
|
12172
|
+
readonly executed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
12173
|
+
readonly providerState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
12174
|
+
readonly providerResultState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
12175
|
+
readonly state: Schema.toTaggedUnion<"status", readonly [Schema.Struct<{
|
|
12176
|
+
readonly status: Schema.tag<"streaming">;
|
|
12177
|
+
readonly input: Schema.String;
|
|
12178
|
+
}>, Schema.Struct<{
|
|
12179
|
+
readonly status: Schema.tag<"running">;
|
|
12180
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
12181
|
+
readonly metadata: Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>;
|
|
12182
|
+
}>, Schema.Struct<{
|
|
12183
|
+
readonly status: Schema.tag<"completed">;
|
|
12184
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
12185
|
+
readonly content: Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
12186
|
+
readonly type: Schema.Literal<"text">;
|
|
12187
|
+
readonly text: Schema.String;
|
|
12188
|
+
}>, Schema.Struct<{
|
|
12189
|
+
readonly type: Schema.Literal<"file">;
|
|
12190
|
+
readonly uri: Schema.String;
|
|
12191
|
+
readonly mime: Schema.String;
|
|
12192
|
+
readonly name: Schema.optional<Schema.String>;
|
|
12193
|
+
}>]>>;
|
|
12194
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
12195
|
+
}>, Schema.Struct<{
|
|
12196
|
+
readonly status: Schema.tag<"error">;
|
|
12197
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
12198
|
+
readonly error: Schema.Struct<{
|
|
12199
|
+
readonly type: Schema.String;
|
|
12200
|
+
readonly message: Schema.String;
|
|
12201
|
+
readonly status: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
12202
|
+
}>;
|
|
12203
|
+
readonly content: Schema.decodeTo<Schema.optional<Schema.toType<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
12204
|
+
readonly type: Schema.Literal<"text">;
|
|
12205
|
+
readonly text: Schema.String;
|
|
12206
|
+
}>, Schema.Struct<{
|
|
12207
|
+
readonly type: Schema.Literal<"file">;
|
|
12208
|
+
readonly uri: Schema.String;
|
|
12209
|
+
readonly mime: Schema.String;
|
|
12210
|
+
readonly name: Schema.optional<Schema.String>;
|
|
12211
|
+
}>]>>>>, Schema.optionalKey<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
12212
|
+
readonly type: Schema.Literal<"text">;
|
|
12213
|
+
readonly text: Schema.String;
|
|
12214
|
+
}>, Schema.Struct<{
|
|
12215
|
+
readonly type: Schema.Literal<"file">;
|
|
12216
|
+
readonly uri: Schema.String;
|
|
12217
|
+
readonly mime: Schema.String;
|
|
12218
|
+
readonly name: Schema.optional<Schema.String>;
|
|
12219
|
+
}>]>>>, never, never>;
|
|
12220
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
12221
|
+
}>]>;
|
|
12222
|
+
readonly time: Schema.Struct<{
|
|
12223
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
12224
|
+
readonly ran: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
12225
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
12226
|
+
}>;
|
|
12227
|
+
}>]>>>;
|
|
12228
|
+
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
12229
|
+
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
12230
|
+
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
12231
|
+
};
|
|
12232
|
+
}>;
|
|
12233
|
+
}> & {
|
|
12234
|
+
type: "session.message.content.updated";
|
|
12235
|
+
durability: "durable";
|
|
12236
|
+
durable: {
|
|
12237
|
+
readonly version: number;
|
|
12238
|
+
readonly aggregate: string;
|
|
12239
|
+
};
|
|
12240
|
+
data: Schema.Struct<{
|
|
12241
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
12242
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
12243
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
12244
|
+
};
|
|
12245
|
+
readonly content: Schema.$Array<Schema.toEncoded<Schema.toTaggedUnion<"type", readonly [Schema.Struct<{
|
|
12246
|
+
readonly type: Schema.tag<"text">;
|
|
12247
|
+
readonly text: Schema.String;
|
|
12248
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
12249
|
+
}>, Schema.Struct<{
|
|
12250
|
+
readonly type: Schema.tag<"reasoning">;
|
|
12251
|
+
readonly text: Schema.String;
|
|
12252
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
12253
|
+
readonly time: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
12254
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
12255
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
12256
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
12257
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
12258
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
12259
|
+
}>>, never, never>;
|
|
12260
|
+
}>, Schema.Struct<{
|
|
12261
|
+
readonly type: Schema.tag<"tool">;
|
|
12262
|
+
readonly id: Schema.String;
|
|
12263
|
+
readonly name: Schema.String;
|
|
12264
|
+
readonly executed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
12265
|
+
readonly providerState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
12266
|
+
readonly providerResultState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
12267
|
+
readonly state: Schema.toTaggedUnion<"status", readonly [Schema.Struct<{
|
|
12268
|
+
readonly status: Schema.tag<"streaming">;
|
|
12269
|
+
readonly input: Schema.String;
|
|
12270
|
+
}>, Schema.Struct<{
|
|
12271
|
+
readonly status: Schema.tag<"running">;
|
|
12272
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
12273
|
+
readonly metadata: Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>;
|
|
12274
|
+
}>, Schema.Struct<{
|
|
12275
|
+
readonly status: Schema.tag<"completed">;
|
|
12276
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
12277
|
+
readonly content: Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
12278
|
+
readonly type: Schema.Literal<"text">;
|
|
12279
|
+
readonly text: Schema.String;
|
|
12280
|
+
}>, Schema.Struct<{
|
|
12281
|
+
readonly type: Schema.Literal<"file">;
|
|
12282
|
+
readonly uri: Schema.String;
|
|
12283
|
+
readonly mime: Schema.String;
|
|
12284
|
+
readonly name: Schema.optional<Schema.String>;
|
|
12285
|
+
}>]>>;
|
|
12286
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
12287
|
+
}>, Schema.Struct<{
|
|
12288
|
+
readonly status: Schema.tag<"error">;
|
|
12289
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
12290
|
+
readonly error: Schema.Struct<{
|
|
12291
|
+
readonly type: Schema.String;
|
|
12292
|
+
readonly message: Schema.String;
|
|
12293
|
+
readonly status: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
12294
|
+
}>;
|
|
12295
|
+
readonly content: Schema.decodeTo<Schema.optional<Schema.toType<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
12296
|
+
readonly type: Schema.Literal<"text">;
|
|
12297
|
+
readonly text: Schema.String;
|
|
12298
|
+
}>, Schema.Struct<{
|
|
12299
|
+
readonly type: Schema.Literal<"file">;
|
|
12300
|
+
readonly uri: Schema.String;
|
|
12301
|
+
readonly mime: Schema.String;
|
|
12302
|
+
readonly name: Schema.optional<Schema.String>;
|
|
12303
|
+
}>]>>>>, Schema.optionalKey<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
12304
|
+
readonly type: Schema.Literal<"text">;
|
|
12305
|
+
readonly text: Schema.String;
|
|
12306
|
+
}>, Schema.Struct<{
|
|
12307
|
+
readonly type: Schema.Literal<"file">;
|
|
12308
|
+
readonly uri: Schema.String;
|
|
12309
|
+
readonly mime: Schema.String;
|
|
12310
|
+
readonly name: Schema.optional<Schema.String>;
|
|
12311
|
+
}>]>>>, never, never>;
|
|
12312
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
12313
|
+
}>]>;
|
|
12314
|
+
readonly time: Schema.Struct<{
|
|
12315
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
12316
|
+
readonly ran: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
12317
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
12318
|
+
}>;
|
|
12319
|
+
}>]>>>;
|
|
12320
|
+
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
12321
|
+
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
12322
|
+
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
12323
|
+
};
|
|
12324
|
+
}>;
|
|
11789
12325
|
}, Schema.Struct<{
|
|
11790
12326
|
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
11791
12327
|
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
package/dist/groups/session.d.ts
CHANGED
|
@@ -4778,6 +4778,214 @@ export declare const makeSessionGroup: <I extends HttpApiMiddleware.AnyId, S>(se
|
|
|
4778
4778
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
4779
4779
|
};
|
|
4780
4780
|
}>;
|
|
4781
|
+
}) | (Schema.Struct<{
|
|
4782
|
+
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
4783
|
+
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
4784
|
+
};
|
|
4785
|
+
readonly created: Schema.Finite;
|
|
4786
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
4787
|
+
readonly type: Schema.Literal<"session.message.content.updated">;
|
|
4788
|
+
readonly durable: Schema.Struct<{
|
|
4789
|
+
readonly aggregateID: Schema.String;
|
|
4790
|
+
readonly seq: Schema.brand<Schema.Int, "Event.Seq">;
|
|
4791
|
+
readonly version: Schema.decodeTo<Schema.toType<Schema.brand<Schema.Int, "Event.Version">>, Schema.Literal<number>, never, never>;
|
|
4792
|
+
}>;
|
|
4793
|
+
readonly location: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
4794
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
4795
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
4796
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
4797
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
4798
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
4799
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
4800
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
4801
|
+
}>, never, never>;
|
|
4802
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
4803
|
+
readonly directory: Schema.brand<Schema.String, "AbsolutePath">;
|
|
4804
|
+
readonly workspaceID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
4805
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
4806
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
4807
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Workspace.ID"> & {
|
|
4808
|
+
ascending: (id?: string) => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
4809
|
+
create: () => string & import("effect/Brand").Brand<"Workspace.ID">;
|
|
4810
|
+
}>, never, never>;
|
|
4811
|
+
}>>, never, never>;
|
|
4812
|
+
readonly data: Schema.Struct<{
|
|
4813
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
4814
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
4815
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
4816
|
+
};
|
|
4817
|
+
readonly content: Schema.$Array<Schema.toEncoded<Schema.toTaggedUnion<"type", readonly [Schema.Struct<{
|
|
4818
|
+
readonly type: Schema.tag<"text">;
|
|
4819
|
+
readonly text: Schema.String;
|
|
4820
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
4821
|
+
}>, Schema.Struct<{
|
|
4822
|
+
readonly type: Schema.tag<"reasoning">;
|
|
4823
|
+
readonly text: Schema.String;
|
|
4824
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
4825
|
+
readonly time: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
4826
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
4827
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
4828
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
4829
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
4830
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
4831
|
+
}>>, never, never>;
|
|
4832
|
+
}>, Schema.Struct<{
|
|
4833
|
+
readonly type: Schema.tag<"tool">;
|
|
4834
|
+
readonly id: Schema.String;
|
|
4835
|
+
readonly name: Schema.String;
|
|
4836
|
+
readonly executed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
4837
|
+
readonly providerState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
4838
|
+
readonly providerResultState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
4839
|
+
readonly state: Schema.toTaggedUnion<"status", readonly [Schema.Struct<{
|
|
4840
|
+
readonly status: Schema.tag<"streaming">;
|
|
4841
|
+
readonly input: Schema.String;
|
|
4842
|
+
}>, Schema.Struct<{
|
|
4843
|
+
readonly status: Schema.tag<"running">;
|
|
4844
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
4845
|
+
readonly metadata: Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>;
|
|
4846
|
+
}>, Schema.Struct<{
|
|
4847
|
+
readonly status: Schema.tag<"completed">;
|
|
4848
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
4849
|
+
readonly content: Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
4850
|
+
readonly type: Schema.Literal<"text">;
|
|
4851
|
+
readonly text: Schema.String;
|
|
4852
|
+
}>, Schema.Struct<{
|
|
4853
|
+
readonly type: Schema.Literal<"file">;
|
|
4854
|
+
readonly uri: Schema.String;
|
|
4855
|
+
readonly mime: Schema.String;
|
|
4856
|
+
readonly name: Schema.optional<Schema.String>;
|
|
4857
|
+
}>]>>;
|
|
4858
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
4859
|
+
}>, Schema.Struct<{
|
|
4860
|
+
readonly status: Schema.tag<"error">;
|
|
4861
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
4862
|
+
readonly error: Schema.Struct<{
|
|
4863
|
+
readonly type: Schema.String;
|
|
4864
|
+
readonly message: Schema.String;
|
|
4865
|
+
readonly status: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
4866
|
+
}>;
|
|
4867
|
+
readonly content: Schema.decodeTo<Schema.optional<Schema.toType<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
4868
|
+
readonly type: Schema.Literal<"text">;
|
|
4869
|
+
readonly text: Schema.String;
|
|
4870
|
+
}>, Schema.Struct<{
|
|
4871
|
+
readonly type: Schema.Literal<"file">;
|
|
4872
|
+
readonly uri: Schema.String;
|
|
4873
|
+
readonly mime: Schema.String;
|
|
4874
|
+
readonly name: Schema.optional<Schema.String>;
|
|
4875
|
+
}>]>>>>, Schema.optionalKey<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
4876
|
+
readonly type: Schema.Literal<"text">;
|
|
4877
|
+
readonly text: Schema.String;
|
|
4878
|
+
}>, Schema.Struct<{
|
|
4879
|
+
readonly type: Schema.Literal<"file">;
|
|
4880
|
+
readonly uri: Schema.String;
|
|
4881
|
+
readonly mime: Schema.String;
|
|
4882
|
+
readonly name: Schema.optional<Schema.String>;
|
|
4883
|
+
}>]>>>, never, never>;
|
|
4884
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
4885
|
+
}>]>;
|
|
4886
|
+
readonly time: Schema.Struct<{
|
|
4887
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
4888
|
+
readonly ran: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
4889
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
4890
|
+
}>;
|
|
4891
|
+
}>]>>>;
|
|
4892
|
+
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
4893
|
+
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
4894
|
+
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
4895
|
+
};
|
|
4896
|
+
}>;
|
|
4897
|
+
}> & {
|
|
4898
|
+
type: "session.message.content.updated";
|
|
4899
|
+
durability: "durable";
|
|
4900
|
+
durable: {
|
|
4901
|
+
readonly version: number;
|
|
4902
|
+
readonly aggregate: string;
|
|
4903
|
+
};
|
|
4904
|
+
data: Schema.Struct<{
|
|
4905
|
+
readonly messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
4906
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
4907
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
4908
|
+
};
|
|
4909
|
+
readonly content: Schema.$Array<Schema.toEncoded<Schema.toTaggedUnion<"type", readonly [Schema.Struct<{
|
|
4910
|
+
readonly type: Schema.tag<"text">;
|
|
4911
|
+
readonly text: Schema.String;
|
|
4912
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
4913
|
+
}>, Schema.Struct<{
|
|
4914
|
+
readonly type: Schema.tag<"reasoning">;
|
|
4915
|
+
readonly text: Schema.String;
|
|
4916
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
4917
|
+
readonly time: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
4918
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
4919
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
4920
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
4921
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
4922
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
4923
|
+
}>>, never, never>;
|
|
4924
|
+
}>, Schema.Struct<{
|
|
4925
|
+
readonly type: Schema.tag<"tool">;
|
|
4926
|
+
readonly id: Schema.String;
|
|
4927
|
+
readonly name: Schema.String;
|
|
4928
|
+
readonly executed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
4929
|
+
readonly providerState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
4930
|
+
readonly providerResultState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
4931
|
+
readonly state: Schema.toTaggedUnion<"status", readonly [Schema.Struct<{
|
|
4932
|
+
readonly status: Schema.tag<"streaming">;
|
|
4933
|
+
readonly input: Schema.String;
|
|
4934
|
+
}>, Schema.Struct<{
|
|
4935
|
+
readonly status: Schema.tag<"running">;
|
|
4936
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
4937
|
+
readonly metadata: Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>;
|
|
4938
|
+
}>, Schema.Struct<{
|
|
4939
|
+
readonly status: Schema.tag<"completed">;
|
|
4940
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
4941
|
+
readonly content: Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
4942
|
+
readonly type: Schema.Literal<"text">;
|
|
4943
|
+
readonly text: Schema.String;
|
|
4944
|
+
}>, Schema.Struct<{
|
|
4945
|
+
readonly type: Schema.Literal<"file">;
|
|
4946
|
+
readonly uri: Schema.String;
|
|
4947
|
+
readonly mime: Schema.String;
|
|
4948
|
+
readonly name: Schema.optional<Schema.String>;
|
|
4949
|
+
}>]>>;
|
|
4950
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
4951
|
+
}>, Schema.Struct<{
|
|
4952
|
+
readonly status: Schema.tag<"error">;
|
|
4953
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
4954
|
+
readonly error: Schema.Struct<{
|
|
4955
|
+
readonly type: Schema.String;
|
|
4956
|
+
readonly message: Schema.String;
|
|
4957
|
+
readonly status: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
4958
|
+
}>;
|
|
4959
|
+
readonly content: Schema.decodeTo<Schema.optional<Schema.toType<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
4960
|
+
readonly type: Schema.Literal<"text">;
|
|
4961
|
+
readonly text: Schema.String;
|
|
4962
|
+
}>, Schema.Struct<{
|
|
4963
|
+
readonly type: Schema.Literal<"file">;
|
|
4964
|
+
readonly uri: Schema.String;
|
|
4965
|
+
readonly mime: Schema.String;
|
|
4966
|
+
readonly name: Schema.optional<Schema.String>;
|
|
4967
|
+
}>]>>>>, Schema.optionalKey<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
4968
|
+
readonly type: Schema.Literal<"text">;
|
|
4969
|
+
readonly text: Schema.String;
|
|
4970
|
+
}>, Schema.Struct<{
|
|
4971
|
+
readonly type: Schema.Literal<"file">;
|
|
4972
|
+
readonly uri: Schema.String;
|
|
4973
|
+
readonly mime: Schema.String;
|
|
4974
|
+
readonly name: Schema.optional<Schema.String>;
|
|
4975
|
+
}>]>>>, never, never>;
|
|
4976
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
4977
|
+
}>]>;
|
|
4978
|
+
readonly time: Schema.Struct<{
|
|
4979
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
4980
|
+
readonly ran: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
4981
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
4982
|
+
}>;
|
|
4983
|
+
}>]>>>;
|
|
4984
|
+
readonly sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
4985
|
+
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
4986
|
+
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
4987
|
+
};
|
|
4988
|
+
}>;
|
|
4781
4989
|
}) | (Schema.Struct<{
|
|
4782
4990
|
readonly id: Schema.brand<Schema.String, "Event.ID"> & {
|
|
4783
4991
|
create: () => string & import("effect/Brand").Brand<"Event.ID">;
|
|
@@ -7718,6 +7926,126 @@ export declare const makeSessionGroup: <I extends HttpApiMiddleware.AnyId, S>(se
|
|
|
7718
7926
|
readonly metadata?: {
|
|
7719
7927
|
readonly [x: string]: unknown;
|
|
7720
7928
|
} | undefined;
|
|
7929
|
+
} | {
|
|
7930
|
+
readonly id: string & import("effect/Brand").Brand<"Event.ID">;
|
|
7931
|
+
readonly data: {
|
|
7932
|
+
readonly messageID: string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
7933
|
+
readonly content: readonly ({
|
|
7934
|
+
readonly id: string;
|
|
7935
|
+
readonly type: "tool";
|
|
7936
|
+
readonly name: string;
|
|
7937
|
+
readonly time: {
|
|
7938
|
+
readonly created: number;
|
|
7939
|
+
readonly completed?: number | undefined;
|
|
7940
|
+
readonly ran?: number | undefined;
|
|
7941
|
+
};
|
|
7942
|
+
readonly state: {
|
|
7943
|
+
readonly status: "streaming";
|
|
7944
|
+
readonly input: string;
|
|
7945
|
+
} | {
|
|
7946
|
+
readonly status: "running";
|
|
7947
|
+
readonly input: {
|
|
7948
|
+
readonly [x: string]: unknown;
|
|
7949
|
+
};
|
|
7950
|
+
readonly metadata: {
|
|
7951
|
+
readonly [x: string]: Schema.Json;
|
|
7952
|
+
};
|
|
7953
|
+
} | {
|
|
7954
|
+
readonly content: readonly [{
|
|
7955
|
+
readonly type: "text";
|
|
7956
|
+
readonly text: string;
|
|
7957
|
+
} | {
|
|
7958
|
+
readonly type: "file";
|
|
7959
|
+
readonly uri: string;
|
|
7960
|
+
readonly mime: string;
|
|
7961
|
+
readonly name?: string | undefined;
|
|
7962
|
+
}, ...({
|
|
7963
|
+
readonly type: "text";
|
|
7964
|
+
readonly text: string;
|
|
7965
|
+
} | {
|
|
7966
|
+
readonly type: "file";
|
|
7967
|
+
readonly uri: string;
|
|
7968
|
+
readonly mime: string;
|
|
7969
|
+
readonly name?: string | undefined;
|
|
7970
|
+
})[]];
|
|
7971
|
+
readonly status: "completed";
|
|
7972
|
+
readonly input: {
|
|
7973
|
+
readonly [x: string]: unknown;
|
|
7974
|
+
};
|
|
7975
|
+
readonly metadata?: {
|
|
7976
|
+
readonly [x: string]: Schema.Json;
|
|
7977
|
+
} | undefined;
|
|
7978
|
+
} | {
|
|
7979
|
+
readonly error: {
|
|
7980
|
+
readonly type: string;
|
|
7981
|
+
readonly message: string;
|
|
7982
|
+
readonly status?: number | undefined;
|
|
7983
|
+
};
|
|
7984
|
+
readonly status: "error";
|
|
7985
|
+
readonly input: {
|
|
7986
|
+
readonly [x: string]: unknown;
|
|
7987
|
+
};
|
|
7988
|
+
readonly metadata?: {
|
|
7989
|
+
readonly [x: string]: Schema.Json;
|
|
7990
|
+
} | undefined;
|
|
7991
|
+
readonly content?: readonly [{
|
|
7992
|
+
readonly type: "text";
|
|
7993
|
+
readonly text: string;
|
|
7994
|
+
} | {
|
|
7995
|
+
readonly type: "file";
|
|
7996
|
+
readonly uri: string;
|
|
7997
|
+
readonly mime: string;
|
|
7998
|
+
readonly name?: string | undefined;
|
|
7999
|
+
}, ...({
|
|
8000
|
+
readonly type: "text";
|
|
8001
|
+
readonly text: string;
|
|
8002
|
+
} | {
|
|
8003
|
+
readonly type: "file";
|
|
8004
|
+
readonly uri: string;
|
|
8005
|
+
readonly mime: string;
|
|
8006
|
+
readonly name?: string | undefined;
|
|
8007
|
+
})[]] | undefined;
|
|
8008
|
+
};
|
|
8009
|
+
readonly executed?: boolean | undefined;
|
|
8010
|
+
readonly providerState?: {
|
|
8011
|
+
readonly [x: string]: unknown;
|
|
8012
|
+
} | undefined;
|
|
8013
|
+
readonly providerResultState?: {
|
|
8014
|
+
readonly [x: string]: unknown;
|
|
8015
|
+
} | undefined;
|
|
8016
|
+
} | {
|
|
8017
|
+
readonly type: "text";
|
|
8018
|
+
readonly text: string;
|
|
8019
|
+
readonly state?: {
|
|
8020
|
+
readonly [x: string]: unknown;
|
|
8021
|
+
} | undefined;
|
|
8022
|
+
} | {
|
|
8023
|
+
readonly type: "reasoning";
|
|
8024
|
+
readonly text: string;
|
|
8025
|
+
readonly time?: {
|
|
8026
|
+
readonly created: number;
|
|
8027
|
+
readonly completed?: number | undefined;
|
|
8028
|
+
} | undefined;
|
|
8029
|
+
readonly state?: {
|
|
8030
|
+
readonly [x: string]: unknown;
|
|
8031
|
+
} | undefined;
|
|
8032
|
+
})[];
|
|
8033
|
+
readonly sessionID: string & import("effect/Brand").Brand<"SessionID">;
|
|
8034
|
+
};
|
|
8035
|
+
readonly durable: {
|
|
8036
|
+
readonly aggregateID: string;
|
|
8037
|
+
readonly seq: number & import("effect/Brand").Brand<"Event.Seq">;
|
|
8038
|
+
readonly version: number & import("effect/Brand").Brand<"Event.Version">;
|
|
8039
|
+
};
|
|
8040
|
+
readonly type: "session.message.content.updated";
|
|
8041
|
+
readonly created: number;
|
|
8042
|
+
readonly location?: {
|
|
8043
|
+
readonly directory: string & import("effect/Brand").Brand<"AbsolutePath">;
|
|
8044
|
+
readonly workspaceID?: (string & import("effect/Brand").Brand<"Workspace.ID">) | undefined;
|
|
8045
|
+
} | undefined;
|
|
8046
|
+
readonly metadata?: {
|
|
8047
|
+
readonly [x: string]: unknown;
|
|
8048
|
+
} | undefined;
|
|
7721
8049
|
} | {
|
|
7722
8050
|
readonly id: string & import("effect/Brand").Brand<"Event.ID">;
|
|
7723
8051
|
readonly data: {
|
|
@@ -9316,7 +9644,264 @@ export declare const makeSessionGroup: <I extends HttpApiMiddleware.AnyId, S>(se
|
|
|
9316
9644
|
}>;
|
|
9317
9645
|
readonly type: Schema.tag<"compaction">;
|
|
9318
9646
|
}>]>]>;
|
|
9319
|
-
}>>, Schema.toCodecJson<typeof SessionNotFoundError | typeof MessageNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"session.
|
|
9647
|
+
}>>, Schema.toCodecJson<typeof SessionNotFoundError | typeof MessageNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"session.messageUpdate", "PATCH", "/api/session/:sessionID/message/:messageID", Schema.toCodecStringTree<Schema.Struct<{
|
|
9648
|
+
sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
9649
|
+
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
9650
|
+
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
|
9651
|
+
};
|
|
9652
|
+
messageID: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
9653
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
9654
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
9655
|
+
};
|
|
9656
|
+
}>>, never, Schema.toCodecJson<Schema.Struct<{
|
|
9657
|
+
readonly content: Schema.$Array<Schema.toTaggedUnion<"type", readonly [Schema.Struct<{
|
|
9658
|
+
readonly type: Schema.tag<"text">;
|
|
9659
|
+
readonly text: Schema.String;
|
|
9660
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
9661
|
+
}>, Schema.Struct<{
|
|
9662
|
+
readonly type: Schema.tag<"reasoning">;
|
|
9663
|
+
readonly text: Schema.String;
|
|
9664
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
9665
|
+
readonly time: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
9666
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
9667
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
9668
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
9669
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
9670
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
9671
|
+
}>>, never, never>;
|
|
9672
|
+
}>, Schema.Struct<{
|
|
9673
|
+
readonly type: Schema.tag<"tool">;
|
|
9674
|
+
readonly id: Schema.String;
|
|
9675
|
+
readonly name: Schema.String;
|
|
9676
|
+
readonly executed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
9677
|
+
readonly providerState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
9678
|
+
readonly providerResultState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
9679
|
+
readonly state: Schema.toTaggedUnion<"status", readonly [Schema.Struct<{
|
|
9680
|
+
readonly status: Schema.tag<"streaming">;
|
|
9681
|
+
readonly input: Schema.String;
|
|
9682
|
+
}>, Schema.Struct<{
|
|
9683
|
+
readonly status: Schema.tag<"running">;
|
|
9684
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
9685
|
+
readonly metadata: Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>;
|
|
9686
|
+
}>, Schema.Struct<{
|
|
9687
|
+
readonly status: Schema.tag<"completed">;
|
|
9688
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
9689
|
+
readonly content: Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
9690
|
+
readonly type: Schema.Literal<"text">;
|
|
9691
|
+
readonly text: Schema.String;
|
|
9692
|
+
}>, Schema.Struct<{
|
|
9693
|
+
readonly type: Schema.Literal<"file">;
|
|
9694
|
+
readonly uri: Schema.String;
|
|
9695
|
+
readonly mime: Schema.String;
|
|
9696
|
+
readonly name: Schema.optional<Schema.String>;
|
|
9697
|
+
}>]>>;
|
|
9698
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
9699
|
+
}>, Schema.Struct<{
|
|
9700
|
+
readonly status: Schema.tag<"error">;
|
|
9701
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
9702
|
+
readonly error: Schema.Struct<{
|
|
9703
|
+
readonly type: Schema.String;
|
|
9704
|
+
readonly message: Schema.String;
|
|
9705
|
+
readonly status: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
9706
|
+
}>;
|
|
9707
|
+
readonly content: Schema.decodeTo<Schema.optional<Schema.toType<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
9708
|
+
readonly type: Schema.Literal<"text">;
|
|
9709
|
+
readonly text: Schema.String;
|
|
9710
|
+
}>, Schema.Struct<{
|
|
9711
|
+
readonly type: Schema.Literal<"file">;
|
|
9712
|
+
readonly uri: Schema.String;
|
|
9713
|
+
readonly mime: Schema.String;
|
|
9714
|
+
readonly name: Schema.optional<Schema.String>;
|
|
9715
|
+
}>]>>>>, Schema.optionalKey<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
9716
|
+
readonly type: Schema.Literal<"text">;
|
|
9717
|
+
readonly text: Schema.String;
|
|
9718
|
+
}>, Schema.Struct<{
|
|
9719
|
+
readonly type: Schema.Literal<"file">;
|
|
9720
|
+
readonly uri: Schema.String;
|
|
9721
|
+
readonly mime: Schema.String;
|
|
9722
|
+
readonly name: Schema.optional<Schema.String>;
|
|
9723
|
+
}>]>>>, never, never>;
|
|
9724
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
9725
|
+
}>]>;
|
|
9726
|
+
readonly time: Schema.Struct<{
|
|
9727
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
9728
|
+
readonly ran: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
9729
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
9730
|
+
}>;
|
|
9731
|
+
}>]>>;
|
|
9732
|
+
}>>, never, Schema.toCodecJson<Schema.Struct<{
|
|
9733
|
+
readonly data: Schema.Struct<{
|
|
9734
|
+
readonly type: Schema.tag<"assistant">;
|
|
9735
|
+
readonly agent: Schema.brand<Schema.String, "Agent.ID">;
|
|
9736
|
+
readonly model: Schema.Struct<{
|
|
9737
|
+
readonly id: Schema.brand<Schema.String, "Model.ID">;
|
|
9738
|
+
readonly providerID: Schema.brand<Schema.String, "Provider.ID"> & {
|
|
9739
|
+
opencode: string & import("effect/Brand").Brand<"Provider.ID">;
|
|
9740
|
+
anthropic: string & import("effect/Brand").Brand<"Provider.ID">;
|
|
9741
|
+
openai: string & import("effect/Brand").Brand<"Provider.ID">;
|
|
9742
|
+
google: string & import("effect/Brand").Brand<"Provider.ID">;
|
|
9743
|
+
googleVertex: string & import("effect/Brand").Brand<"Provider.ID">;
|
|
9744
|
+
githubCopilot: string & import("effect/Brand").Brand<"Provider.ID">;
|
|
9745
|
+
amazonBedrock: string & import("effect/Brand").Brand<"Provider.ID">;
|
|
9746
|
+
azure: string & import("effect/Brand").Brand<"Provider.ID">;
|
|
9747
|
+
openrouter: string & import("effect/Brand").Brand<"Provider.ID">;
|
|
9748
|
+
mistral: string & import("effect/Brand").Brand<"Provider.ID">;
|
|
9749
|
+
gitlab: string & import("effect/Brand").Brand<"Provider.ID">;
|
|
9750
|
+
};
|
|
9751
|
+
readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>;
|
|
9752
|
+
}> & {
|
|
9753
|
+
parse: (input: string) => {
|
|
9754
|
+
readonly id: string & import("effect/Brand").Brand<"Model.ID">;
|
|
9755
|
+
readonly providerID: string & import("effect/Brand").Brand<"Provider.ID">;
|
|
9756
|
+
readonly variant?: (string & import("effect/Brand").Brand<"Model.VariantID">) | undefined;
|
|
9757
|
+
};
|
|
9758
|
+
};
|
|
9759
|
+
readonly content: Schema.$Array<Schema.toTaggedUnion<"type", readonly [Schema.Struct<{
|
|
9760
|
+
readonly type: Schema.tag<"text">;
|
|
9761
|
+
readonly text: Schema.String;
|
|
9762
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
9763
|
+
}>, Schema.Struct<{
|
|
9764
|
+
readonly type: Schema.tag<"reasoning">;
|
|
9765
|
+
readonly text: Schema.String;
|
|
9766
|
+
readonly state: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
9767
|
+
readonly time: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
9768
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
9769
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
9770
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
9771
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
9772
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
9773
|
+
}>>, never, never>;
|
|
9774
|
+
}>, Schema.Struct<{
|
|
9775
|
+
readonly type: Schema.tag<"tool">;
|
|
9776
|
+
readonly id: Schema.String;
|
|
9777
|
+
readonly name: Schema.String;
|
|
9778
|
+
readonly executed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
9779
|
+
readonly providerState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
9780
|
+
readonly providerResultState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
9781
|
+
readonly state: Schema.toTaggedUnion<"status", readonly [Schema.Struct<{
|
|
9782
|
+
readonly status: Schema.tag<"streaming">;
|
|
9783
|
+
readonly input: Schema.String;
|
|
9784
|
+
}>, Schema.Struct<{
|
|
9785
|
+
readonly status: Schema.tag<"running">;
|
|
9786
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
9787
|
+
readonly metadata: Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>;
|
|
9788
|
+
}>, Schema.Struct<{
|
|
9789
|
+
readonly status: Schema.tag<"completed">;
|
|
9790
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
9791
|
+
readonly content: Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
9792
|
+
readonly type: Schema.Literal<"text">;
|
|
9793
|
+
readonly text: Schema.String;
|
|
9794
|
+
}>, Schema.Struct<{
|
|
9795
|
+
readonly type: Schema.Literal<"file">;
|
|
9796
|
+
readonly uri: Schema.String;
|
|
9797
|
+
readonly mime: Schema.String;
|
|
9798
|
+
readonly name: Schema.optional<Schema.String>;
|
|
9799
|
+
}>]>>;
|
|
9800
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
9801
|
+
}>, Schema.Struct<{
|
|
9802
|
+
readonly status: Schema.tag<"error">;
|
|
9803
|
+
readonly input: Schema.$Record<Schema.String, Schema.Unknown>;
|
|
9804
|
+
readonly error: Schema.Struct<{
|
|
9805
|
+
readonly type: Schema.String;
|
|
9806
|
+
readonly message: Schema.String;
|
|
9807
|
+
readonly status: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
9808
|
+
}>;
|
|
9809
|
+
readonly content: Schema.decodeTo<Schema.optional<Schema.toType<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
9810
|
+
readonly type: Schema.Literal<"text">;
|
|
9811
|
+
readonly text: Schema.String;
|
|
9812
|
+
}>, Schema.Struct<{
|
|
9813
|
+
readonly type: Schema.Literal<"file">;
|
|
9814
|
+
readonly uri: Schema.String;
|
|
9815
|
+
readonly mime: Schema.String;
|
|
9816
|
+
readonly name: Schema.optional<Schema.String>;
|
|
9817
|
+
}>]>>>>, Schema.optionalKey<Schema.NonEmptyArray<Schema.Union<readonly [Schema.Struct<{
|
|
9818
|
+
readonly type: Schema.Literal<"text">;
|
|
9819
|
+
readonly text: Schema.String;
|
|
9820
|
+
}>, Schema.Struct<{
|
|
9821
|
+
readonly type: Schema.Literal<"file">;
|
|
9822
|
+
readonly uri: Schema.String;
|
|
9823
|
+
readonly mime: Schema.String;
|
|
9824
|
+
readonly name: Schema.optional<Schema.String>;
|
|
9825
|
+
}>]>>>, never, never>;
|
|
9826
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Codec<Schema.Json, Schema.Json, never, never>>>, never, never>;
|
|
9827
|
+
}>]>;
|
|
9828
|
+
readonly time: Schema.Struct<{
|
|
9829
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
9830
|
+
readonly ran: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
9831
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
9832
|
+
}>;
|
|
9833
|
+
}>]>>;
|
|
9834
|
+
readonly snapshot: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
9835
|
+
readonly start: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Snapshot.ID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Snapshot.ID">>, never, never>;
|
|
9836
|
+
readonly end: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Snapshot.ID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Snapshot.ID">>, never, never>;
|
|
9837
|
+
readonly files: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Array<Schema.brand<Schema.String, "RelativePath">>>>, Schema.optionalKey<Schema.$Array<Schema.brand<Schema.String, "RelativePath">>>, never, never>;
|
|
9838
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
9839
|
+
readonly start: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Snapshot.ID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Snapshot.ID">>, never, never>;
|
|
9840
|
+
readonly end: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Snapshot.ID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Snapshot.ID">>, never, never>;
|
|
9841
|
+
readonly files: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Array<Schema.brand<Schema.String, "RelativePath">>>>, Schema.optionalKey<Schema.$Array<Schema.brand<Schema.String, "RelativePath">>>, never, never>;
|
|
9842
|
+
}>>, never, never>;
|
|
9843
|
+
readonly finish: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["stop", "length", "tool-calls", "content-filter", "error", "unknown"]>>>, Schema.optionalKey<Schema.Literals<readonly ["stop", "length", "tool-calls", "content-filter", "error", "unknown"]>>, never, never>;
|
|
9844
|
+
readonly rawFinish: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
9845
|
+
readonly providerState: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
9846
|
+
readonly cost: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.Finite, "Money.USD"> & {
|
|
9847
|
+
zero: number & import("effect/Brand").Brand<"Money.USD">;
|
|
9848
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.Finite, "Money.USD"> & {
|
|
9849
|
+
zero: number & import("effect/Brand").Brand<"Money.USD">;
|
|
9850
|
+
}>, never, never>;
|
|
9851
|
+
readonly tokens: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
9852
|
+
readonly input: Schema.Finite;
|
|
9853
|
+
readonly output: Schema.Finite;
|
|
9854
|
+
readonly reasoning: Schema.Finite;
|
|
9855
|
+
readonly cache: Schema.Struct<{
|
|
9856
|
+
readonly read: Schema.Finite;
|
|
9857
|
+
readonly write: Schema.Finite;
|
|
9858
|
+
}>;
|
|
9859
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
9860
|
+
readonly input: Schema.Finite;
|
|
9861
|
+
readonly output: Schema.Finite;
|
|
9862
|
+
readonly reasoning: Schema.Finite;
|
|
9863
|
+
readonly cache: Schema.Struct<{
|
|
9864
|
+
readonly read: Schema.Finite;
|
|
9865
|
+
readonly write: Schema.Finite;
|
|
9866
|
+
}>;
|
|
9867
|
+
}>>, never, never>;
|
|
9868
|
+
readonly error: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
9869
|
+
readonly type: Schema.String;
|
|
9870
|
+
readonly message: Schema.String;
|
|
9871
|
+
readonly status: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
9872
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
9873
|
+
readonly type: Schema.String;
|
|
9874
|
+
readonly message: Schema.String;
|
|
9875
|
+
readonly status: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
9876
|
+
}>>, never, never>;
|
|
9877
|
+
readonly retry: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
9878
|
+
readonly attempt: Schema.Int;
|
|
9879
|
+
readonly at: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
9880
|
+
readonly error: Schema.Struct<{
|
|
9881
|
+
readonly type: Schema.String;
|
|
9882
|
+
readonly message: Schema.String;
|
|
9883
|
+
readonly status: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
9884
|
+
}>;
|
|
9885
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
9886
|
+
readonly attempt: Schema.Int;
|
|
9887
|
+
readonly at: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
9888
|
+
readonly error: Schema.Struct<{
|
|
9889
|
+
readonly type: Schema.String;
|
|
9890
|
+
readonly message: Schema.String;
|
|
9891
|
+
readonly status: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
9892
|
+
}>;
|
|
9893
|
+
}>>, never, never>;
|
|
9894
|
+
readonly time: Schema.Struct<{
|
|
9895
|
+
readonly created: Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>;
|
|
9896
|
+
readonly completed: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.DateTimeUtc, Schema.Finite, never, never>>, never, never>;
|
|
9897
|
+
}>;
|
|
9898
|
+
readonly id: Schema.brand<Schema.String, "Session.Message.ID"> & {
|
|
9899
|
+
create: () => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
9900
|
+
fromEvent: (eventID: Event.ID) => string & import("effect/Brand").Brand<"Session.Message.ID">;
|
|
9901
|
+
};
|
|
9902
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
9903
|
+
}>;
|
|
9904
|
+
}>>, Schema.toCodecJson<typeof InvalidRequestError | typeof ConflictError | typeof SessionBusyError | typeof SessionNotFoundError | typeof MessageNotFoundError>, never, never> | HttpApiEndpoint.HttpApiEndpoint<"session.environment", "PUT", "/api/session/:sessionID/environment", Schema.toCodecStringTree<Schema.Struct<{
|
|
9320
9905
|
sessionID: Schema.brand<Schema.String, "SessionID"> & {
|
|
9321
9906
|
create: () => string & import("effect/Brand").Brand<"SessionID">;
|
|
9322
9907
|
descending: (id?: string) => string & import("effect/Brand").Brand<"SessionID">;
|
package/dist/groups/session.js
CHANGED
|
@@ -521,6 +521,16 @@ export const makeSessionGroup = (sessionLocationMiddleware) => HttpApiGroup.make
|
|
|
521
521
|
identifier: "v2.session.message",
|
|
522
522
|
summary: "Get session message",
|
|
523
523
|
description: "Retrieve one projected message owned by the Session.",
|
|
524
|
+
})))
|
|
525
|
+
.add(HttpApiEndpoint.patch("session.messageUpdate", "/api/session/:sessionID/message/:messageID", {
|
|
526
|
+
params: { sessionID: Session.ID, messageID: SessionMessage.ID },
|
|
527
|
+
payload: Schema.Struct({ content: Schema.Array(SessionMessage.AssistantContent) }),
|
|
528
|
+
success: Schema.Struct({ data: SessionMessage.Assistant }),
|
|
529
|
+
error: [SessionNotFoundError, MessageNotFoundError, InvalidRequestError, SessionBusyError, ConflictError],
|
|
530
|
+
}).annotateMerge(OpenApi.annotations({
|
|
531
|
+
identifier: "v2.session.messageUpdate",
|
|
532
|
+
summary: "Update assistant message content",
|
|
533
|
+
description: "Replace the content of a completed assistant message in an idle session.",
|
|
524
534
|
})))
|
|
525
535
|
.add(HttpApiEndpoint.put("session.environment", "/api/session/:sessionID/environment", {
|
|
526
536
|
params: { sessionID: Session.ID },
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/package.json",
|
|
3
3
|
"name": "@opencode-ai/protocol",
|
|
4
|
-
"version": "0.0.0-dev-
|
|
4
|
+
"version": "0.0.0-dev-18296",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"repository": {
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"typecheck": "tsgo --noEmit"
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
|
-
"@opencode-ai/schema": "0.0.0-dev-
|
|
35
|
+
"@opencode-ai/schema": "0.0.0-dev-18296",
|
|
36
36
|
"effect": "4.0.0-rc.111"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|