@opencode/schema 0.0.0-dev-678 → 0.0.0-dev-695
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/config/experimental.d.ts +6 -5
- package/dist/config/experimental.js +7 -15
- package/dist/config/flag.d.ts +16 -0
- package/dist/config/flag.js +15 -0
- package/package.json +1 -1
|
@@ -2,9 +2,7 @@ export * as ConfigExperimental from "./experimental.js";
|
|
|
2
2
|
import { Schema } from "effect";
|
|
3
3
|
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
|
-
readonly
|
|
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>;
|
|
5
|
+
readonly all_flags: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
8
6
|
readonly part_rows: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
9
7
|
readonly image_generate: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Union<readonly [Schema.Boolean, Schema.Struct<{
|
|
10
8
|
readonly model: Schema.decodeTo<Schema.optional<Schema.toType<Schema.decodeTo<Schema.Struct<{
|
|
@@ -43,8 +41,6 @@ declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
|
43
41
|
readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>;
|
|
44
42
|
}>]>, never, never>>, never, never>;
|
|
45
43
|
}>]>>, never, never>;
|
|
46
|
-
readonly schedules: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
47
|
-
readonly artifacts: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
48
44
|
readonly subagent_depth: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
49
45
|
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>;
|
|
50
46
|
readonly policies: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Array<Schema.decodeTo<Schema.toType<Schema.Struct<{
|
|
@@ -64,6 +60,11 @@ declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
|
64
60
|
readonly resource: Schema.String;
|
|
65
61
|
readonly effect: Schema.Literals<readonly ["allow", "deny"]>;
|
|
66
62
|
}>, never, never>>>, never, never>;
|
|
63
|
+
readonly artifacts: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
64
|
+
readonly background_compaction: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
65
|
+
readonly media_blob: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
66
|
+
readonly schedules: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
67
|
+
readonly todo: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
67
68
|
}>, {}>;
|
|
68
69
|
export declare class Info extends Info_base {
|
|
69
70
|
}
|
|
@@ -1,21 +1,19 @@
|
|
|
1
1
|
export * as ConfigExperimental from "./experimental.js";
|
|
2
|
-
import { Schema } from "effect";
|
|
2
|
+
import { Record, Schema } from "effect";
|
|
3
3
|
import { NonNegativeInt, optional } from "../schema.js";
|
|
4
|
+
import { ConfigFlag } from "./flag.js";
|
|
4
5
|
import { ConfigModel } from "./model.js";
|
|
5
6
|
import { ConfigPolicy } from "./policy.js";
|
|
6
7
|
export class Info extends Schema.Class("ConfigExperimental.Info")({
|
|
7
8
|
portable_shell_scanner: Schema.Boolean.pipe(optional).annotate({
|
|
8
9
|
description: "Deprecated: the built-in shell permission scanner is now always enabled.",
|
|
9
10
|
}),
|
|
10
|
-
|
|
11
|
-
description: "
|
|
12
|
-
}),
|
|
13
|
-
background_compaction: Schema.Boolean.pipe(optional).annotate({
|
|
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.",
|
|
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.",
|
|
11
|
+
all_flags: Schema.Boolean.pipe(optional).annotate({
|
|
12
|
+
description: "Turn every feature flag on regardless of the build channel, like OPENCODE_FLAGS=all; explicit per-flag settings still win, and false is not a kill switch.",
|
|
18
13
|
}),
|
|
14
|
+
...Record.map(ConfigFlag.registry, (description) => Schema.Boolean.pipe(optional).annotate({
|
|
15
|
+
description: `${description} Defaults to on in local and dev builds and off in releases.`,
|
|
16
|
+
})),
|
|
19
17
|
part_rows: Schema.Boolean.pipe(optional).annotate({
|
|
20
18
|
description: "Write each assistant part as its own session_part row instead of rewriting the whole message on every event. Defaults to false.",
|
|
21
19
|
}),
|
|
@@ -31,12 +29,6 @@ export class Info extends Schema.Class("ConfigExperimental.Info")({
|
|
|
31
29
|
.annotate({
|
|
32
30
|
description: "Settings for the experimental_image_generate tool, which is offered while a connected provider has an image model.",
|
|
33
31
|
}),
|
|
34
|
-
schedules: Schema.Boolean.pipe(optional).annotate({
|
|
35
|
-
description: "Enable experimental scheduled tasks that wake a session with a prompt. Defaults to false.",
|
|
36
|
-
}),
|
|
37
|
-
artifacts: Schema.Boolean.pipe(optional).annotate({
|
|
38
|
-
description: "Enable experimental artifacts backed by pluggable providers. Defaults to false.",
|
|
39
|
-
}),
|
|
40
32
|
subagent_depth: NonNegativeInt.pipe(optional).annotate({
|
|
41
33
|
description: "Maximum subagent nesting depth. Defaults to 1.",
|
|
42
34
|
}),
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export * as ConfigFlag from "./flag.js";
|
|
2
|
+
/** The `OPENCODE_FLAGS` entry that turns every flag on, as in `all,-media_blob`. It is not a flag key. */
|
|
3
|
+
export declare const wildcard = "all";
|
|
4
|
+
/**
|
|
5
|
+
* Every feature flag, by key, with what it turns on. A flag is on in local and dev builds and off in released ones;
|
|
6
|
+
* `experimental.<key>` in config and `OPENCODE_FLAGS` override that, and `OPENCODE_FLAGS=all` or
|
|
7
|
+
* `experimental.all_flags: true` turn every flag on. Read one with Core's `Flag.enabled("<key>")`.
|
|
8
|
+
*/
|
|
9
|
+
export declare const registry: {
|
|
10
|
+
readonly todo: "Enable the experimental todowrite tool.";
|
|
11
|
+
readonly background_compaction: "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.";
|
|
12
|
+
readonly media_blob: "Store new session media once in a deduplicated blob table instead of inline in every message row.";
|
|
13
|
+
readonly schedules: "Enable experimental scheduled tasks that wake a session with a prompt.";
|
|
14
|
+
readonly artifacts: "Enable experimental artifacts backed by pluggable providers.";
|
|
15
|
+
};
|
|
16
|
+
export type Key = keyof typeof registry;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export * as ConfigFlag from "./flag.js";
|
|
2
|
+
/** The `OPENCODE_FLAGS` entry that turns every flag on, as in `all,-media_blob`. It is not a flag key. */
|
|
3
|
+
export const wildcard = "all";
|
|
4
|
+
/**
|
|
5
|
+
* Every feature flag, by key, with what it turns on. A flag is on in local and dev builds and off in released ones;
|
|
6
|
+
* `experimental.<key>` in config and `OPENCODE_FLAGS` override that, and `OPENCODE_FLAGS=all` or
|
|
7
|
+
* `experimental.all_flags: true` turn every flag on. Read one with Core's `Flag.enabled("<key>")`.
|
|
8
|
+
*/
|
|
9
|
+
export const registry = {
|
|
10
|
+
todo: "Enable the experimental todowrite tool.",
|
|
11
|
+
background_compaction: "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.",
|
|
12
|
+
media_blob: "Store new session media once in a deduplicated blob table instead of inline in every message row.",
|
|
13
|
+
schedules: "Enable experimental scheduled tasks that wake a session with a prompt.",
|
|
14
|
+
artifacts: "Enable experimental artifacts backed by pluggable providers.",
|
|
15
|
+
};
|