@opencode/schema 2.1.4 → 2.2.1
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/agent.d.ts +5 -0
- package/dist/config/experimental.d.ts +39 -0
- package/dist/config/experimental.js +19 -0
- package/dist/config/provider.d.ts +57 -11
- package/dist/config/provider.js +15 -16
- package/dist/config.d.ts +1 -0
- package/dist/config.js +3 -0
- package/dist/event-manifest.d.ts +8 -0
- package/dist/file-diff.d.ts +2 -0
- package/dist/file-diff.js +2 -0
- package/dist/generate.d.ts +355 -0
- package/dist/generate.js +134 -0
- package/dist/goal.d.ts +126 -0
- package/dist/goal.js +40 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/mcp.d.ts +1 -0
- package/dist/mcp.js +2 -0
- package/dist/model-compatibility.d.ts +15 -4
- package/dist/model-compatibility.js +15 -4
- package/dist/model.d.ts +39 -8
- package/dist/model.js +12 -7
- package/dist/plugin.d.ts +15 -0
- package/dist/plugin.js +11 -1
- package/dist/prompt.d.ts +96 -0
- package/dist/prompt.js +17 -1
- package/dist/provider.d.ts +40 -0
- package/dist/provider.js +14 -3
- package/dist/schedule.d.ts +220 -0
- package/dist/schedule.js +110 -0
- package/dist/session-event.d.ts +20 -0
- package/dist/session-inbox.d.ts +714 -86
- package/dist/session-inbox.js +10 -1
- package/dist/session-message.d.ts +968 -0
- package/dist/session-message.js +19 -1
- package/dist/session-revert.d.ts +37 -0
- package/dist/session-transfer.d.ts +4 -0
- package/dist/session.d.ts +4 -0
- package/dist/usage-limits.d.ts +227 -0
- package/dist/usage-limits.js +59 -0
- package/dist/vcs.d.ts +3 -0
- package/dist/vcs.js +2 -0
- package/package.json +2 -1
package/dist/agent.d.ts
CHANGED
|
@@ -70,6 +70,11 @@ export declare const Info: Schema.Struct<{
|
|
|
70
70
|
}>, Schema.Struct<{
|
|
71
71
|
readonly type: Schema.Literal<"native">;
|
|
72
72
|
}>]>>, never, never>;
|
|
73
|
+
readonly cache: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
74
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
75
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
76
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
77
|
+
}>>, never, never>;
|
|
73
78
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
74
79
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
75
80
|
}>, readonly [Schema.$Record<Schema.String, Schema.Any>]>>;
|
|
@@ -4,6 +4,45 @@ declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
|
4
4
|
readonly portable_shell_scanner: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
5
5
|
readonly todo: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
6
6
|
readonly background_compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
7
|
+
readonly media_blob: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
8
|
+
readonly image_generate: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
|
|
9
|
+
readonly model: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.Struct<{
|
|
10
|
+
readonly providerID: Schema.brand<Schema.String, "Provider.ID">;
|
|
11
|
+
readonly model: Schema.brand<Schema.String, "Model.ID">;
|
|
12
|
+
readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>;
|
|
13
|
+
}>, Schema.Union<readonly [Schema.String, Schema.Struct<{
|
|
14
|
+
readonly providerID: Schema.brand<Schema.String, "Provider.ID">;
|
|
15
|
+
readonly model: Schema.brand<Schema.String, "Model.ID">;
|
|
16
|
+
readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>;
|
|
17
|
+
}>]>, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.Struct<{
|
|
18
|
+
readonly providerID: Schema.brand<Schema.String, "Provider.ID">;
|
|
19
|
+
readonly model: Schema.brand<Schema.String, "Model.ID">;
|
|
20
|
+
readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>;
|
|
21
|
+
}>, Schema.Union<readonly [Schema.String, Schema.Struct<{
|
|
22
|
+
readonly providerID: Schema.brand<Schema.String, "Provider.ID">;
|
|
23
|
+
readonly model: Schema.brand<Schema.String, "Model.ID">;
|
|
24
|
+
readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>;
|
|
25
|
+
}>]>, never, never>>, never, never>;
|
|
26
|
+
}>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
|
|
27
|
+
readonly model: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.Struct<{
|
|
28
|
+
readonly providerID: Schema.brand<Schema.String, "Provider.ID">;
|
|
29
|
+
readonly model: Schema.brand<Schema.String, "Model.ID">;
|
|
30
|
+
readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>;
|
|
31
|
+
}>, Schema.Union<readonly [Schema.String, Schema.Struct<{
|
|
32
|
+
readonly providerID: Schema.brand<Schema.String, "Provider.ID">;
|
|
33
|
+
readonly model: Schema.brand<Schema.String, "Model.ID">;
|
|
34
|
+
readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>;
|
|
35
|
+
}>]>, never, never>>>, Schema.optionalKey<Schema.decodeTo<Schema.Struct<{
|
|
36
|
+
readonly providerID: Schema.brand<Schema.String, "Provider.ID">;
|
|
37
|
+
readonly model: Schema.brand<Schema.String, "Model.ID">;
|
|
38
|
+
readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>;
|
|
39
|
+
}>, Schema.Union<readonly [Schema.String, Schema.Struct<{
|
|
40
|
+
readonly providerID: Schema.brand<Schema.String, "Provider.ID">;
|
|
41
|
+
readonly model: Schema.brand<Schema.String, "Model.ID">;
|
|
42
|
+
readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>;
|
|
43
|
+
}>]>, never, never>>, never, never>;
|
|
44
|
+
}>]>>, never, never>;
|
|
45
|
+
readonly schedules: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
7
46
|
readonly subagent_depth: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
8
47
|
readonly location_idle_timeout: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.DurationFromString, Schema.Literal<false>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.DurationFromString, Schema.Literal<false>]>>, never, never>;
|
|
9
48
|
readonly policies: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Array<Schema.Struct<{
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export * as ConfigExperimental from "./experimental.js";
|
|
2
2
|
import { Schema } from "effect";
|
|
3
3
|
import { NonNegativeInt, optional } from "../schema.js";
|
|
4
|
+
import { ConfigModel } from "./model.js";
|
|
4
5
|
import { ConfigPolicy } from "./policy.js";
|
|
5
6
|
export class Info extends Schema.Class("ConfigExperimental.Info")({
|
|
6
7
|
portable_shell_scanner: Schema.Boolean.pipe(optional).annotate({
|
|
@@ -12,6 +13,24 @@ export class Info extends Schema.Class("ConfigExperimental.Info")({
|
|
|
12
13
|
background_compaction: Schema.Boolean.pipe(optional).annotate({
|
|
13
14
|
description: "Enable experimental background compaction: summarize the conversation in the background as it nears the compaction threshold, so automatic compaction does not wait for the summary. Background summaries that are never used still cost tokens. Defaults to false.",
|
|
14
15
|
}),
|
|
16
|
+
media_blob: Schema.Boolean.pipe(optional).annotate({
|
|
17
|
+
description: "Store new session media once in a deduplicated blob table instead of inline in every message row. Defaults to false.",
|
|
18
|
+
}),
|
|
19
|
+
image_generate: Schema.Union([
|
|
20
|
+
Schema.Boolean,
|
|
21
|
+
Schema.Struct({
|
|
22
|
+
model: ConfigModel.Selection.pipe(optional).annotate({
|
|
23
|
+
description: "Default model for the image_generate tool when the agent doesn't choose one, as providerID/modelID. Falls back to automatic selection when it isn't available.",
|
|
24
|
+
}),
|
|
25
|
+
}),
|
|
26
|
+
])
|
|
27
|
+
.pipe(optional)
|
|
28
|
+
.annotate({
|
|
29
|
+
description: "Enable the experimental image_generate tool, offered while a connected provider has an image model. Set to true, or to an object with an optional default model. Defaults to false.",
|
|
30
|
+
}),
|
|
31
|
+
schedules: Schema.Boolean.pipe(optional).annotate({
|
|
32
|
+
description: "Enable experimental scheduled tasks that wake a session with a prompt. Defaults to false.",
|
|
33
|
+
}),
|
|
15
34
|
subagent_depth: NonNegativeInt.pipe(optional).annotate({
|
|
16
35
|
description: "Maximum subagent nesting depth. Defaults to 1.",
|
|
17
36
|
}),
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export * as ConfigProvider from "./provider.js";
|
|
2
2
|
import { Schema } from "effect";
|
|
3
|
+
import { Model, Type } from "../model.js";
|
|
3
4
|
export declare const Settings: Schema.StructWithRest<Schema.Struct<{
|
|
4
5
|
readonly timeout: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>, never, never>;
|
|
5
6
|
readonly headerTimeout: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>>, Schema.optionalKey<Schema.Union<readonly [Schema.Finite, Schema.Literal<false>]>>, never, never>;
|
|
@@ -13,6 +14,11 @@ export declare const Settings: Schema.StructWithRest<Schema.Struct<{
|
|
|
13
14
|
}>, Schema.Struct<{
|
|
14
15
|
readonly type: Schema.Literal<"native">;
|
|
15
16
|
}>]>>, never, never>;
|
|
17
|
+
readonly cache: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
18
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
19
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
20
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
21
|
+
}>>, never, never>;
|
|
16
22
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
17
23
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
18
24
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>;
|
|
@@ -27,6 +33,11 @@ export declare const ModelSettings: Schema.StructWithRest<Schema.Struct<{
|
|
|
27
33
|
}>, Schema.Struct<{
|
|
28
34
|
readonly type: Schema.Literal<"native">;
|
|
29
35
|
}>]>>, never, never>;
|
|
36
|
+
readonly cache: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
37
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
38
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
39
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
40
|
+
}>>, never, never>;
|
|
30
41
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
31
42
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>;
|
|
32
43
|
export type ModelSettings = typeof ModelSettings.Type;
|
|
@@ -44,6 +55,11 @@ export declare const Overlays: {
|
|
|
44
55
|
}>, Schema.Struct<{
|
|
45
56
|
readonly type: Schema.Literal<"native">;
|
|
46
57
|
}>]>>, never, never>;
|
|
58
|
+
readonly cache: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
59
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
60
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
61
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
62
|
+
}>>, never, never>;
|
|
47
63
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
48
64
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
49
65
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>>>, Schema.optionalKey<Schema.StructWithRest<Schema.Struct<{
|
|
@@ -59,6 +75,11 @@ export declare const Overlays: {
|
|
|
59
75
|
}>, Schema.Struct<{
|
|
60
76
|
readonly type: Schema.Literal<"native">;
|
|
61
77
|
}>]>>, never, never>;
|
|
78
|
+
readonly cache: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
79
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
80
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
81
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
82
|
+
}>>, never, never>;
|
|
62
83
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
63
84
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
64
85
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>>, never, never>;
|
|
@@ -125,7 +146,7 @@ export declare const Reasoning: Schema.Union<readonly [Schema.Struct<{
|
|
|
125
146
|
}>>, never, never>;
|
|
126
147
|
}>]>;
|
|
127
148
|
export type Reasoning = typeof Reasoning.Type;
|
|
128
|
-
declare const
|
|
149
|
+
declare const ModelConfig_base: Schema.Class<ModelConfig, Schema.Struct<{
|
|
129
150
|
readonly settings: Schema.decodeTo<Schema.optional<Schema.toType<Schema.StructWithRest<Schema.Struct<{
|
|
130
151
|
readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
|
|
131
152
|
readonly type: Schema.Literal<"summary">;
|
|
@@ -136,6 +157,11 @@ declare const Model_base: Schema.Class<Model, Schema.Struct<{
|
|
|
136
157
|
}>, Schema.Struct<{
|
|
137
158
|
readonly type: Schema.Literal<"native">;
|
|
138
159
|
}>]>>, never, never>;
|
|
160
|
+
readonly cache: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
161
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
162
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
163
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
164
|
+
}>>, never, never>;
|
|
139
165
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
140
166
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>>>, Schema.optionalKey<Schema.StructWithRest<Schema.Struct<{
|
|
141
167
|
readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
|
|
@@ -147,16 +173,22 @@ declare const Model_base: Schema.Class<Model, Schema.Struct<{
|
|
|
147
173
|
}>, Schema.Struct<{
|
|
148
174
|
readonly type: Schema.Literal<"native">;
|
|
149
175
|
}>]>>, never, never>;
|
|
176
|
+
readonly cache: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
177
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
178
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
179
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
180
|
+
}>>, never, never>;
|
|
150
181
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
151
182
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>>, never, never>;
|
|
152
183
|
readonly headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
153
184
|
readonly body: 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>;
|
|
154
185
|
readonly modelID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.ID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.ID">>, never, never>;
|
|
186
|
+
readonly type: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Codec<Type, Type, never, never>>>, Schema.optionalKey<Schema.Codec<Type, Type, never, never>>, never, never>;
|
|
155
187
|
readonly family: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.Family">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.Family">>, never, never>;
|
|
156
188
|
readonly name: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
157
189
|
readonly releaseDate: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
158
190
|
readonly compatibility: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
159
|
-
readonly reasoningField: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Codec<
|
|
191
|
+
readonly reasoningField: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Codec<Model.ReasoningField, Model.ReasoningField, never, never>>>, Schema.optionalKey<Schema.Codec<Model.ReasoningField, Model.ReasoningField, never, never>>, never, never>;
|
|
160
192
|
readonly requireReasoning: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
161
193
|
readonly maxTokensField: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["max_completion_tokens", "max_tokens"]>>>, Schema.optionalKey<Schema.Literals<readonly ["max_completion_tokens", "max_tokens"]>>, never, never>;
|
|
162
194
|
readonly requireFinishReason: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
@@ -166,8 +198,9 @@ declare const Model_base: Schema.Class<Model, Schema.Struct<{
|
|
|
166
198
|
readonly cacheFormat: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["anthropic", "alibaba"]>>>, Schema.optionalKey<Schema.Literals<readonly ["anthropic", "alibaba"]>>, never, never>;
|
|
167
199
|
readonly supportsThinkingBlockBinding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
168
200
|
readonly supportsEffortUpdates: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
201
|
+
readonly mediaInput: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["assets", "state", "root"]>>>, Schema.optionalKey<Schema.Literals<readonly ["assets", "state", "root"]>>, never, never>;
|
|
169
202
|
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
170
|
-
readonly reasoningField: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Codec<
|
|
203
|
+
readonly reasoningField: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Codec<Model.ReasoningField, Model.ReasoningField, never, never>>>, Schema.optionalKey<Schema.Codec<Model.ReasoningField, Model.ReasoningField, never, never>>, never, never>;
|
|
171
204
|
readonly requireReasoning: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
172
205
|
readonly maxTokensField: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["max_completion_tokens", "max_tokens"]>>>, Schema.optionalKey<Schema.Literals<readonly ["max_completion_tokens", "max_tokens"]>>, never, never>;
|
|
173
206
|
readonly requireFinishReason: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
@@ -177,6 +210,7 @@ declare const Model_base: Schema.Class<Model, Schema.Struct<{
|
|
|
177
210
|
readonly cacheFormat: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["anthropic", "alibaba"]>>>, Schema.optionalKey<Schema.Literals<readonly ["anthropic", "alibaba"]>>, never, never>;
|
|
178
211
|
readonly supportsThinkingBlockBinding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
179
212
|
readonly supportsEffortUpdates: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
213
|
+
readonly mediaInput: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["assets", "state", "root"]>>>, Schema.optionalKey<Schema.Literals<readonly ["assets", "state", "root"]>>, never, never>;
|
|
180
214
|
}>>, never, never>;
|
|
181
215
|
readonly package: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
182
216
|
readonly capabilities: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
@@ -245,6 +279,9 @@ declare const Model_base: Schema.Class<Model, Schema.Struct<{
|
|
|
245
279
|
}>]>>, never, never>;
|
|
246
280
|
}>>, never, never>;
|
|
247
281
|
readonly variants: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Array<Schema.Struct<{
|
|
282
|
+
readonly headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
283
|
+
readonly body: 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>;
|
|
284
|
+
readonly id: Schema.brand<Schema.String, "Model.VariantID">;
|
|
248
285
|
readonly settings: Schema.decodeTo<Schema.optional<Schema.toType<Schema.StructWithRest<Schema.Struct<{
|
|
249
286
|
readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
|
|
250
287
|
readonly type: Schema.Literal<"summary">;
|
|
@@ -268,10 +305,10 @@ declare const Model_base: Schema.Class<Model, Schema.Struct<{
|
|
|
268
305
|
}>]>>, never, never>;
|
|
269
306
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
270
307
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>>, never, never>;
|
|
308
|
+
}>>>>, Schema.optionalKey<Schema.$Array<Schema.Struct<{
|
|
271
309
|
readonly headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
272
310
|
readonly body: 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>;
|
|
273
311
|
readonly id: Schema.brand<Schema.String, "Model.VariantID">;
|
|
274
|
-
}>>>>, Schema.optionalKey<Schema.$Array<Schema.Struct<{
|
|
275
312
|
readonly settings: Schema.decodeTo<Schema.optional<Schema.toType<Schema.StructWithRest<Schema.Struct<{
|
|
276
313
|
readonly compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Struct<{
|
|
277
314
|
readonly type: Schema.Literal<"summary">;
|
|
@@ -295,15 +332,12 @@ declare const Model_base: Schema.Class<Model, Schema.Struct<{
|
|
|
295
332
|
}>]>>, never, never>;
|
|
296
333
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
297
334
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>>, never, never>;
|
|
298
|
-
readonly headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
299
|
-
readonly body: 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>;
|
|
300
|
-
readonly id: Schema.brand<Schema.String, "Model.VariantID">;
|
|
301
335
|
}>>>, never, never>;
|
|
302
336
|
readonly cost: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [typeof Cost, Schema.$Array<typeof Cost>]>>>, Schema.optionalKey<Schema.Union<readonly [typeof Cost, Schema.$Array<typeof Cost>]>>, never, never>;
|
|
303
337
|
readonly disabled: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
304
338
|
readonly limit: Schema.decodeTo<Schema.optional<Schema.toType<typeof Limit>>, Schema.optionalKey<typeof Limit>, never, never>;
|
|
305
339
|
}>, {}>;
|
|
306
|
-
declare class
|
|
340
|
+
declare class ModelConfig extends ModelConfig_base {
|
|
307
341
|
}
|
|
308
342
|
declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
309
343
|
readonly settings: Schema.decodeTo<Schema.optional<Schema.toType<Schema.StructWithRest<Schema.Struct<{
|
|
@@ -319,6 +353,11 @@ declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
|
319
353
|
}>, Schema.Struct<{
|
|
320
354
|
readonly type: Schema.Literal<"native">;
|
|
321
355
|
}>]>>, never, never>;
|
|
356
|
+
readonly cache: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
357
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
358
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
359
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
360
|
+
}>>, never, never>;
|
|
322
361
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
323
362
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
324
363
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>>>, Schema.optionalKey<Schema.StructWithRest<Schema.Struct<{
|
|
@@ -334,6 +373,11 @@ declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
|
334
373
|
}>, Schema.Struct<{
|
|
335
374
|
readonly type: Schema.Literal<"native">;
|
|
336
375
|
}>]>>, never, never>;
|
|
376
|
+
readonly cache: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
377
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
378
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
379
|
+
readonly ttl: Schema.decodeTo<Schema.optional<Schema.toType<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>>, Schema.optionalKey<Schema.TemplateLiteral<readonly [Schema.Number, Schema.Literals<readonly ["ms", "s", "m", "h", "d"]>]>>, never, never>;
|
|
380
|
+
}>>, never, never>;
|
|
337
381
|
readonly transport: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["http", "websocket"]>>>, Schema.optionalKey<Schema.Literals<readonly ["http", "websocket"]>>, never, never>;
|
|
338
382
|
readonly encoding: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["zstd", "gzip", "none"]>>>, Schema.optionalKey<Schema.Literals<readonly ["zstd", "gzip", "none"]>>, never, never>;
|
|
339
383
|
}>, readonly [Schema.$Record<Schema.String, Schema.UndefinedOr<Schema.Codec<Schema.Json, Schema.Json, never, never>>>]>>, never, never>;
|
|
@@ -368,7 +412,7 @@ declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
|
368
412
|
readonly env: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Array<Schema.String>>>, Schema.optionalKey<Schema.$Array<Schema.String>>, never, never>;
|
|
369
413
|
readonly package: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
370
414
|
readonly compatibility: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
371
|
-
readonly reasoningField: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Codec<
|
|
415
|
+
readonly reasoningField: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Codec<Model.ReasoningField, Model.ReasoningField, never, never>>>, Schema.optionalKey<Schema.Codec<Model.ReasoningField, Model.ReasoningField, never, never>>, never, never>;
|
|
372
416
|
readonly requireReasoning: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
373
417
|
readonly maxTokensField: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["max_completion_tokens", "max_tokens"]>>>, Schema.optionalKey<Schema.Literals<readonly ["max_completion_tokens", "max_tokens"]>>, never, never>;
|
|
374
418
|
readonly requireFinishReason: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
@@ -376,8 +420,9 @@ declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
|
376
420
|
readonly supportsPromptCacheKey: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
377
421
|
readonly streamUsage: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
378
422
|
readonly cacheFormat: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["anthropic", "alibaba"]>>>, Schema.optionalKey<Schema.Literals<readonly ["anthropic", "alibaba"]>>, never, never>;
|
|
423
|
+
readonly mediaInput: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["assets", "state", "root"]>>>, Schema.optionalKey<Schema.Literals<readonly ["assets", "state", "root"]>>, never, never>;
|
|
379
424
|
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
380
|
-
readonly reasoningField: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Codec<
|
|
425
|
+
readonly reasoningField: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Codec<Model.ReasoningField, Model.ReasoningField, never, never>>>, Schema.optionalKey<Schema.Codec<Model.ReasoningField, Model.ReasoningField, never, never>>, never, never>;
|
|
381
426
|
readonly requireReasoning: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
382
427
|
readonly maxTokensField: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["max_completion_tokens", "max_tokens"]>>>, Schema.optionalKey<Schema.Literals<readonly ["max_completion_tokens", "max_tokens"]>>, never, never>;
|
|
383
428
|
readonly requireFinishReason: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
@@ -385,8 +430,9 @@ declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
|
385
430
|
readonly supportsPromptCacheKey: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
386
431
|
readonly streamUsage: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
387
432
|
readonly cacheFormat: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["anthropic", "alibaba"]>>>, Schema.optionalKey<Schema.Literals<readonly ["anthropic", "alibaba"]>>, never, never>;
|
|
433
|
+
readonly mediaInput: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literals<readonly ["assets", "state", "root"]>>>, Schema.optionalKey<Schema.Literals<readonly ["assets", "state", "root"]>>, never, never>;
|
|
388
434
|
}>>, never, never>;
|
|
389
|
-
readonly models: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, typeof
|
|
435
|
+
readonly models: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, typeof ModelConfig>>>, Schema.optionalKey<Schema.$Record<Schema.String, typeof ModelConfig>>, never, never>;
|
|
390
436
|
}>, {}>;
|
|
391
437
|
export declare class Info extends Info_base {
|
|
392
438
|
}
|
package/dist/config/provider.js
CHANGED
|
@@ -1,22 +1,16 @@
|
|
|
1
1
|
export * as ConfigProvider from "./provider.js";
|
|
2
|
-
import { Schema } from "effect";
|
|
2
|
+
import { Schema, Struct } from "effect";
|
|
3
3
|
import { Money } from "../money.js";
|
|
4
|
-
import { Capabilities, Compatibility, Family, ID, VariantID } from "../model.js";
|
|
4
|
+
import { Capabilities, Compatibility, Family, ID, Model, Type, VariantID } from "../model.js";
|
|
5
5
|
import { ProviderCompatibility } from "../model-compatibility.js";
|
|
6
6
|
import { Provider } from "../provider.js";
|
|
7
7
|
import { optional } from "../schema.js";
|
|
8
|
-
export const Settings = Schema.StructWithRest(Schema.Struct(
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
encoding: Provider.Encoding.pipe(optional),
|
|
15
|
-
}), [Schema.Record(Schema.String, Schema.UndefinedOr(Schema.Json))]).annotate({ identifier: "Config.Provider.Settings" });
|
|
16
|
-
export const ModelSettings = Schema.StructWithRest(Schema.Struct({
|
|
17
|
-
compaction: Provider.Compaction.pipe(optional),
|
|
18
|
-
encoding: Provider.Encoding.pipe(optional),
|
|
19
|
-
}), [Schema.Record(Schema.String, Schema.UndefinedOr(Schema.Json))]).annotate({ identifier: "Config.Model.Settings" });
|
|
8
|
+
export const Settings = Schema.StructWithRest(Schema.Struct(Provider.Settings.schema.fields), [
|
|
9
|
+
Schema.Record(Schema.String, Schema.UndefinedOr(Schema.Json)),
|
|
10
|
+
]).annotate({ identifier: "Config.Provider.Settings" });
|
|
11
|
+
export const ModelSettings = Schema.StructWithRest(Schema.Struct(Model.Settings.schema.fields), [
|
|
12
|
+
Schema.Record(Schema.String, Schema.UndefinedOr(Schema.Json)),
|
|
13
|
+
]).annotate({ identifier: "Config.Model.Settings" });
|
|
20
14
|
const JsonRecord = Schema.Record(Schema.String, Schema.Json);
|
|
21
15
|
export const Overlays = {
|
|
22
16
|
settings: Settings.pipe(optional),
|
|
@@ -67,8 +61,9 @@ export const Reasoning = Schema.Union([
|
|
|
67
61
|
}).pipe(optional),
|
|
68
62
|
}),
|
|
69
63
|
]).annotate({ identifier: "Config.Model.Reasoning" });
|
|
70
|
-
class
|
|
64
|
+
class ModelConfig extends Schema.Class("Config.Model")({
|
|
71
65
|
modelID: ID.pipe(optional),
|
|
66
|
+
type: Type.pipe(optional),
|
|
72
67
|
family: Family.pipe(optional),
|
|
73
68
|
name: Schema.String.pipe(optional),
|
|
74
69
|
releaseDate: Schema.String.check(Schema.isPattern(/^\d{4}-\d{2}(-\d{2})?$/u))
|
|
@@ -90,6 +85,10 @@ class Model extends Schema.Class("Config.Model")({
|
|
|
90
85
|
variants: Schema.Struct({
|
|
91
86
|
id: VariantID,
|
|
92
87
|
...ModelOverlays,
|
|
88
|
+
// The prompt cache belongs to the model, so a variant can't change it.
|
|
89
|
+
settings: Schema.StructWithRest(Schema.Struct(Struct.omit(ModelSettings.schema.fields, ["cache"])), ModelSettings.records)
|
|
90
|
+
.annotate({ identifier: "Config.Model.VariantSettings" })
|
|
91
|
+
.pipe(optional),
|
|
93
92
|
}).pipe(Schema.Array, optional),
|
|
94
93
|
cost: Schema.Union([Cost, Cost.pipe(Schema.Array)]).pipe(optional),
|
|
95
94
|
disabled: Schema.Boolean.pipe(optional),
|
|
@@ -104,6 +103,6 @@ export class Info extends Schema.Class("Config.Provider")({
|
|
|
104
103
|
// Defaults for every model of this provider; model compatibility overrides individual fields.
|
|
105
104
|
compatibility: ProviderCompatibility.pipe(optional),
|
|
106
105
|
...Overlays,
|
|
107
|
-
models: Schema.Record(Schema.String,
|
|
106
|
+
models: Schema.Record(Schema.String, ModelConfig).pipe(optional),
|
|
108
107
|
}) {
|
|
109
108
|
}
|
package/dist/config.d.ts
CHANGED
|
@@ -44,6 +44,7 @@ declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
|
44
44
|
readonly url: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
45
45
|
}>>, never, never>;
|
|
46
46
|
readonly username: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
47
|
+
readonly timezone: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
47
48
|
readonly permissions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Array<Schema.Struct<{
|
|
48
49
|
readonly action: Schema.String;
|
|
49
50
|
readonly resource: Schema.String;
|
package/dist/config.js
CHANGED
|
@@ -50,6 +50,9 @@ export class Info extends Schema.Class("Config.Info")({
|
|
|
50
50
|
username: Schema.String.pipe(optional).annotate({
|
|
51
51
|
description: "Username displayed in conversations and used for telemetry identity",
|
|
52
52
|
}),
|
|
53
|
+
timezone: Schema.String.pipe(optional).annotate({
|
|
54
|
+
description: "IANA time zone for schedules, e.g. America/Los_Angeles. Defaults to the server's local zone",
|
|
55
|
+
}),
|
|
53
56
|
permissions: Permission.Ruleset.pipe(optional).annotate({
|
|
54
57
|
description: "Ordered tool permission rules applied to agent tool use",
|
|
55
58
|
}),
|
package/dist/event-manifest.d.ts
CHANGED
|
@@ -4194,12 +4194,14 @@ export declare const ServerDefinitions: readonly [Schema.Struct<{
|
|
|
4194
4194
|
readonly additions: Schema.Int;
|
|
4195
4195
|
readonly deletions: Schema.Int;
|
|
4196
4196
|
readonly status: Schema.Literals<readonly ["added", "deleted", "modified"]>;
|
|
4197
|
+
readonly more: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literal<true>>>, Schema.optionalKey<Schema.Literal<true>>, never, never>;
|
|
4197
4198
|
}>>>>, Schema.optionalKey<Schema.$Array<Schema.Struct<{
|
|
4198
4199
|
readonly file: Schema.String;
|
|
4199
4200
|
readonly patch: Schema.String;
|
|
4200
4201
|
readonly additions: Schema.Int;
|
|
4201
4202
|
readonly deletions: Schema.Int;
|
|
4202
4203
|
readonly status: Schema.Literals<readonly ["added", "deleted", "modified"]>;
|
|
4204
|
+
readonly more: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literal<true>>>, Schema.optionalKey<Schema.Literal<true>>, never, never>;
|
|
4203
4205
|
}>>>, never, never>;
|
|
4204
4206
|
}>;
|
|
4205
4207
|
}>;
|
|
@@ -4227,12 +4229,14 @@ export declare const ServerDefinitions: readonly [Schema.Struct<{
|
|
|
4227
4229
|
readonly additions: Schema.Int;
|
|
4228
4230
|
readonly deletions: Schema.Int;
|
|
4229
4231
|
readonly status: Schema.Literals<readonly ["added", "deleted", "modified"]>;
|
|
4232
|
+
readonly more: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literal<true>>>, Schema.optionalKey<Schema.Literal<true>>, never, never>;
|
|
4230
4233
|
}>>>>, Schema.optionalKey<Schema.$Array<Schema.Struct<{
|
|
4231
4234
|
readonly file: Schema.String;
|
|
4232
4235
|
readonly patch: Schema.String;
|
|
4233
4236
|
readonly additions: Schema.Int;
|
|
4234
4237
|
readonly deletions: Schema.Int;
|
|
4235
4238
|
readonly status: Schema.Literals<readonly ["added", "deleted", "modified"]>;
|
|
4239
|
+
readonly more: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literal<true>>>, Schema.optionalKey<Schema.Literal<true>>, never, never>;
|
|
4236
4240
|
}>>>, never, never>;
|
|
4237
4241
|
}>;
|
|
4238
4242
|
}>;
|
|
@@ -10422,12 +10426,14 @@ export declare const Definitions: readonly [Schema.Struct<{
|
|
|
10422
10426
|
readonly additions: Schema.Int;
|
|
10423
10427
|
readonly deletions: Schema.Int;
|
|
10424
10428
|
readonly status: Schema.Literals<readonly ["added", "deleted", "modified"]>;
|
|
10429
|
+
readonly more: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literal<true>>>, Schema.optionalKey<Schema.Literal<true>>, never, never>;
|
|
10425
10430
|
}>>>>, Schema.optionalKey<Schema.$Array<Schema.Struct<{
|
|
10426
10431
|
readonly file: Schema.String;
|
|
10427
10432
|
readonly patch: Schema.String;
|
|
10428
10433
|
readonly additions: Schema.Int;
|
|
10429
10434
|
readonly deletions: Schema.Int;
|
|
10430
10435
|
readonly status: Schema.Literals<readonly ["added", "deleted", "modified"]>;
|
|
10436
|
+
readonly more: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literal<true>>>, Schema.optionalKey<Schema.Literal<true>>, never, never>;
|
|
10431
10437
|
}>>>, never, never>;
|
|
10432
10438
|
}>;
|
|
10433
10439
|
}>;
|
|
@@ -10455,12 +10461,14 @@ export declare const Definitions: readonly [Schema.Struct<{
|
|
|
10455
10461
|
readonly additions: Schema.Int;
|
|
10456
10462
|
readonly deletions: Schema.Int;
|
|
10457
10463
|
readonly status: Schema.Literals<readonly ["added", "deleted", "modified"]>;
|
|
10464
|
+
readonly more: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literal<true>>>, Schema.optionalKey<Schema.Literal<true>>, never, never>;
|
|
10458
10465
|
}>>>>, Schema.optionalKey<Schema.$Array<Schema.Struct<{
|
|
10459
10466
|
readonly file: Schema.String;
|
|
10460
10467
|
readonly patch: Schema.String;
|
|
10461
10468
|
readonly additions: Schema.Int;
|
|
10462
10469
|
readonly deletions: Schema.Int;
|
|
10463
10470
|
readonly status: Schema.Literals<readonly ["added", "deleted", "modified"]>;
|
|
10471
|
+
readonly more: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literal<true>>>, Schema.optionalKey<Schema.Literal<true>>, never, never>;
|
|
10464
10472
|
}>>>, never, never>;
|
|
10465
10473
|
}>;
|
|
10466
10474
|
}>;
|
package/dist/file-diff.d.ts
CHANGED
|
@@ -6,6 +6,8 @@ export declare const Info: Schema.Struct<{
|
|
|
6
6
|
readonly additions: Schema.Int;
|
|
7
7
|
readonly deletions: Schema.Int;
|
|
8
8
|
readonly status: Schema.Literals<readonly ["added", "deleted", "modified"]>;
|
|
9
|
+
/** Marks the entry a folder listing adds for itself when it stopped before showing or checking every entry. */
|
|
10
|
+
readonly more: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Literal<true>>>, Schema.optionalKey<Schema.Literal<true>>, never, never>;
|
|
9
11
|
}>;
|
|
10
12
|
export interface Info extends Schema.Schema.Type<typeof Info> {
|
|
11
13
|
}
|
package/dist/file-diff.js
CHANGED
|
@@ -7,6 +7,8 @@ export const Info = Schema.Struct({
|
|
|
7
7
|
additions: NonNegativeInt,
|
|
8
8
|
deletions: NonNegativeInt,
|
|
9
9
|
status: Schema.Literals(["added", "deleted", "modified"]),
|
|
10
|
+
/** Marks the entry a folder listing adds for itself when it stopped before showing or checking every entry. */
|
|
11
|
+
more: Schema.Literal(true).pipe(optional),
|
|
10
12
|
}).annotate({ identifier: "FileDiff.Info" });
|
|
11
13
|
/** V1 snapshot and persisted session diff shape. */
|
|
12
14
|
export const LegacyInfo = Schema.Struct({
|