@opencode-ai/schema 0.0.0-dev-17471
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 +164 -0
- package/dist/agent.js +46 -0
- package/dist/ai.d.ts +4 -0
- package/dist/ai.js +5 -0
- package/dist/catalog.d.ts +69 -0
- package/dist/catalog.js +4 -0
- package/dist/command.d.ts +124 -0
- package/dist/command.js +19 -0
- package/dist/config/agent.d.ts +42 -0
- package/dist/config/agent.js +20 -0
- package/dist/config/command.d.ts +27 -0
- package/dist/config/command.js +12 -0
- package/dist/config/compaction.d.ts +14 -0
- package/dist/config/compaction.js +13 -0
- package/dist/config/experimental.d.ts +17 -0
- package/dist/config/experimental.js +16 -0
- package/dist/config/formatter.d.ts +11 -0
- package/dist/config/formatter.js +11 -0
- package/dist/config/lsp.d.ts +20 -0
- package/dist/config/lsp.js +16 -0
- package/dist/config/mcp.d.ts +18 -0
- package/dist/config/mcp.js +14 -0
- package/dist/config/media.d.ts +15 -0
- package/dist/config/media.js +14 -0
- package/dist/config/model.d.ts +18 -0
- package/dist/config/model.js +28 -0
- package/dist/config/plugin.d.ts +11 -0
- package/dist/config/plugin.js +10 -0
- package/dist/config/policy.d.ts +10 -0
- package/dist/config/policy.js +8 -0
- package/dist/config/provider.d.ts +106 -0
- package/dist/config/provider.js +62 -0
- package/dist/config/reference.d.ts +21 -0
- package/dist/config/reference.js +18 -0
- package/dist/config/tool-output.d.ts +8 -0
- package/dist/config/tool-output.js +8 -0
- package/dist/config/warming.d.ts +10 -0
- package/dist/config/warming.js +16 -0
- package/dist/config/watcher.d.ts +7 -0
- package/dist/config/watcher.js +7 -0
- package/dist/config/websearch.d.ts +9 -0
- package/dist/config/websearch.js +8 -0
- package/dist/config.d.ts +175 -0
- package/dist/config.js +136 -0
- package/dist/connection.d.ts +28 -0
- package/dist/connection.js +15 -0
- package/dist/credential.d.ts +38 -0
- package/dist/credential.js +25 -0
- package/dist/durable-event-manifest.d.ts +3 -0
- package/dist/durable-event-manifest.js +5 -0
- package/dist/event-log.d.ts +14 -0
- package/dist/event-log.js +17 -0
- package/dist/event-manifest.d.ts +11372 -0
- package/dist/event-manifest.js +45 -0
- package/dist/event.d.ts +142 -0
- package/dist/event.js +110 -0
- package/dist/file-diff.d.ts +21 -0
- package/dist/file-diff.js +18 -0
- package/dist/filesystem-v1.d.ts +1 -0
- package/dist/filesystem-v1.js +1 -0
- package/dist/filesystem.d.ts +118 -0
- package/dist/filesystem.js +35 -0
- package/dist/form.d.ts +1259 -0
- package/dist/form.js +120 -0
- package/dist/ide-event.d.ts +76 -0
- package/dist/ide-event.js +10 -0
- package/dist/identifier.d.ts +3 -0
- package/dist/identifier.js +24 -0
- package/dist/index.d.ts +39 -0
- package/dist/index.js +39 -0
- package/dist/installation-event.d.ts +149 -0
- package/dist/installation-event.js +16 -0
- package/dist/instruction-entry.d.ts +23 -0
- package/dist/instruction-entry.js +22 -0
- package/dist/instruction.d.ts +13 -0
- package/dist/instruction.js +8 -0
- package/dist/integration-id.d.ts +5 -0
- package/dist/integration-id.js +3 -0
- package/dist/integration.d.ts +1675 -0
- package/dist/integration.js +87 -0
- package/dist/legacy-event.d.ts +1 -0
- package/dist/legacy-event.js +1 -0
- package/dist/llm.d.ts +4 -0
- package/dist/llm.js +3 -0
- package/dist/location.d.ts +37 -0
- package/dist/location.js +22 -0
- package/dist/lsp-event.d.ts +67 -0
- package/dist/lsp-event.js +4 -0
- package/dist/mcp-event.d.ts +222 -0
- package/dist/mcp-event.js +24 -0
- package/dist/mcp.d.ts +138 -0
- package/dist/mcp.js +111 -0
- package/dist/model.d.ts +186 -0
- package/dist/model.js +104 -0
- package/dist/models-dev.d.ts +69 -0
- package/dist/models-dev.js +7 -0
- package/dist/money.d.ts +10 -0
- package/dist/money.js +5 -0
- package/dist/permission-saved.d.ts +18 -0
- package/dist/permission-saved.js +12 -0
- package/dist/permission-v1.d.ts +1 -0
- package/dist/permission-v1.js +1 -0
- package/dist/permission.d.ts +306 -0
- package/dist/permission.js +45 -0
- package/dist/plugin.d.ts +150 -0
- package/dist/plugin.js +16 -0
- package/dist/project-id.d.ts +5 -0
- package/dist/project-id.js +3 -0
- package/dist/project.d.ts +241 -0
- package/dist/project.js +37 -0
- package/dist/prompt-input.d.ts +143 -0
- package/dist/prompt-input.js +25 -0
- package/dist/prompt.d.ts +297 -0
- package/dist/prompt.js +61 -0
- package/dist/provider.d.ts +60 -0
- package/dist/provider.js +42 -0
- package/dist/pty-ticket.d.ts +8 -0
- package/dist/pty-ticket.js +7 -0
- package/dist/pty.d.ts +462 -0
- package/dist/pty.js +43 -0
- package/dist/question-v1.d.ts +1 -0
- package/dist/question-v1.js +1 -0
- package/dist/question.d.ts +15 -0
- package/dist/question.js +15 -0
- package/dist/reference.d.ts +120 -0
- package/dist/reference.js +30 -0
- package/dist/schema.d.ts +10 -0
- package/dist/schema.js +14 -0
- package/dist/server-event.d.ts +132 -0
- package/dist/server-event.js +5 -0
- package/dist/session-compaction-event.d.ts +87 -0
- package/dist/session-compaction-event.js +10 -0
- package/dist/session-error.d.ts +9 -0
- package/dist/session-error.js +8 -0
- package/dist/session-event.d.ts +17994 -0
- package/dist/session-event.js +499 -0
- package/dist/session-fork.d.ts +26 -0
- package/dist/session-fork.js +11 -0
- package/dist/session-id.d.ts +6 -0
- package/dist/session-id.js +10 -0
- package/dist/session-inbox.d.ts +748 -0
- package/dist/session-inbox.js +47 -0
- package/dist/session-message.d.ts +1512 -0
- package/dist/session-message.js +209 -0
- package/dist/session-revert.d.ts +480 -0
- package/dist/session-revert.js +63 -0
- package/dist/session-status-event.d.ts +299 -0
- package/dist/session-status-event.js +43 -0
- package/dist/session-transfer.d.ts +744 -0
- package/dist/session-transfer.js +8 -0
- package/dist/session-v1.d.ts +1 -0
- package/dist/session-v1.js +1 -0
- package/dist/session.d.ts +218 -0
- package/dist/session.js +45 -0
- package/dist/shell.d.ts +381 -0
- package/dist/shell.js +58 -0
- package/dist/skill.d.ts +133 -0
- package/dist/skill.js +48 -0
- package/dist/snapshot.d.ts +4 -0
- package/dist/snapshot.js +3 -0
- package/dist/token-usage.d.ts +13 -0
- package/dist/token-usage.js +11 -0
- package/dist/tool.d.ts +74 -0
- package/dist/tool.js +22 -0
- package/dist/tui-event.d.ts +307 -0
- package/dist/tui-event.js +53 -0
- package/dist/v1/filesystem.d.ts +78 -0
- package/dist/v1/filesystem.js +8 -0
- package/dist/v1/legacy-event.d.ts +108 -0
- package/dist/v1/legacy-event.js +15 -0
- package/dist/v1/permission.d.ts +316 -0
- package/dist/v1/permission.js +41 -0
- package/dist/v1/question.d.ts +444 -0
- package/dist/v1/question.js +57 -0
- package/dist/v1/session.d.ts +7657 -0
- package/dist/v1/session.js +535 -0
- package/dist/vcs-event.d.ts +76 -0
- package/dist/vcs-event.js +11 -0
- package/dist/vcs.d.ts +26 -0
- package/dist/vcs.js +17 -0
- package/dist/websearch.d.ts +108 -0
- package/dist/websearch.js +31 -0
- package/dist/workspace-event.d.ts +247 -0
- package/dist/workspace-event.js +25 -0
- package/dist/workspace-id.d.ts +6 -0
- package/dist/workspace-id.js +16 -0
- package/dist/workspace.d.ts +9 -0
- package/dist/workspace.js +5 -0
- package/dist/worktree-event.d.ts +153 -0
- package/dist/worktree-event.js +18 -0
- package/dist/worktree.d.ts +255 -0
- package/dist/worktree.js +61 -0
- package/package.json +42 -0
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export * as ConfigFormatter from "./formatter.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
declare const Entry_base: Schema.Class<Entry, Schema.Struct<{
|
|
4
|
+
readonly disabled: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
5
|
+
readonly command: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Array<Schema.String>>>, Schema.optionalKey<Schema.$Array<Schema.String>>, never, never>;
|
|
6
|
+
readonly environment: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
7
|
+
readonly extensions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Array<Schema.String>>>, Schema.optionalKey<Schema.$Array<Schema.String>>, never, never>;
|
|
8
|
+
}>, {}>;
|
|
9
|
+
export declare class Entry extends Entry_base {
|
|
10
|
+
}
|
|
11
|
+
export declare const Info: Schema.Union<readonly [Schema.Boolean, Schema.$Record<Schema.String, typeof Entry>]>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export * as ConfigFormatter from "./formatter.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { optional } from "../schema.js";
|
|
4
|
+
export class Entry extends Schema.Class("Config.Formatter.Entry")({
|
|
5
|
+
disabled: Schema.Boolean.pipe(optional),
|
|
6
|
+
command: Schema.String.pipe(Schema.Array, optional),
|
|
7
|
+
environment: Schema.Record(Schema.String, Schema.String).pipe(optional),
|
|
8
|
+
extensions: Schema.String.pipe(Schema.Array, optional),
|
|
9
|
+
}) {
|
|
10
|
+
}
|
|
11
|
+
export const Info = Schema.Union([Schema.Boolean, Schema.Record(Schema.String, Entry)]);
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export * as ConfigLSP from "./lsp.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
export declare const Disabled: Schema.Struct<{
|
|
4
|
+
readonly disabled: Schema.Literal<true>;
|
|
5
|
+
}>;
|
|
6
|
+
declare const Server_base: Schema.Class<Server, Schema.Struct<{
|
|
7
|
+
readonly command: Schema.$Array<Schema.String>;
|
|
8
|
+
readonly extensions: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Array<Schema.String>>>, Schema.optionalKey<Schema.$Array<Schema.String>>, never, never>;
|
|
9
|
+
readonly disabled: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
10
|
+
readonly env: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
11
|
+
readonly initialization: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
12
|
+
}>, {}>;
|
|
13
|
+
export declare class Server extends Server_base {
|
|
14
|
+
}
|
|
15
|
+
export declare const Entry: Schema.Union<readonly [Schema.Struct<{
|
|
16
|
+
readonly disabled: Schema.Literal<true>;
|
|
17
|
+
}>, typeof Server]>;
|
|
18
|
+
export declare const Info: Schema.Union<readonly [Schema.Boolean, Schema.$Record<Schema.String, Schema.Union<readonly [Schema.Struct<{
|
|
19
|
+
readonly disabled: Schema.Literal<true>;
|
|
20
|
+
}>, typeof Server]>>]>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export * as ConfigLSP from "./lsp.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { optional } from "../schema.js";
|
|
4
|
+
export const Disabled = Schema.Struct({
|
|
5
|
+
disabled: Schema.Literal(true),
|
|
6
|
+
});
|
|
7
|
+
export class Server extends Schema.Class("Config.LSP.Server")({
|
|
8
|
+
command: Schema.String.pipe(Schema.Array),
|
|
9
|
+
extensions: Schema.String.pipe(Schema.Array, optional),
|
|
10
|
+
disabled: Schema.Boolean.pipe(optional),
|
|
11
|
+
env: Schema.Record(Schema.String, Schema.String).pipe(optional),
|
|
12
|
+
initialization: Schema.Record(Schema.String, Schema.Unknown).pipe(optional),
|
|
13
|
+
}) {
|
|
14
|
+
}
|
|
15
|
+
export const Entry = Schema.Union([Disabled, Server]);
|
|
16
|
+
export const Info = Schema.Union([Schema.Boolean, Schema.Record(Schema.String, Entry)]);
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export * as ConfigMCP from "./mcp.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { Mcp } from "../mcp.js";
|
|
4
|
+
export declare const Timeout: typeof Mcp.TimeoutConfig;
|
|
5
|
+
export type Timeout = Mcp.TimeoutConfig;
|
|
6
|
+
export declare const Local: typeof Mcp.LocalConfig;
|
|
7
|
+
export type Local = Mcp.LocalConfig;
|
|
8
|
+
export declare const OAuth: typeof Mcp.OAuthConfig;
|
|
9
|
+
export type OAuth = Mcp.OAuthConfig;
|
|
10
|
+
export declare const Remote: typeof Mcp.RemoteConfig;
|
|
11
|
+
export type Remote = Mcp.RemoteConfig;
|
|
12
|
+
export declare const Server: Schema.toTaggedUnion<"type", readonly [typeof Mcp.LocalConfig, typeof Mcp.RemoteConfig]>;
|
|
13
|
+
declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
14
|
+
readonly timeout: Schema.decodeTo<Schema.optional<Schema.toType<typeof Mcp.TimeoutConfig>>, Schema.optionalKey<typeof Mcp.TimeoutConfig>, never, never>;
|
|
15
|
+
readonly servers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.toTaggedUnion<"type", readonly [typeof Mcp.LocalConfig, typeof Mcp.RemoteConfig]>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.toTaggedUnion<"type", readonly [typeof Mcp.LocalConfig, typeof Mcp.RemoteConfig]>>>, never, never>;
|
|
16
|
+
}>, {}>;
|
|
17
|
+
export declare class Info extends Info_base {
|
|
18
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export * as ConfigMCP from "./mcp.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { Mcp } from "../mcp.js";
|
|
4
|
+
import { optional } from "../schema.js";
|
|
5
|
+
export const Timeout = Mcp.TimeoutConfig;
|
|
6
|
+
export const Local = Mcp.LocalConfig;
|
|
7
|
+
export const OAuth = Mcp.OAuthConfig;
|
|
8
|
+
export const Remote = Mcp.RemoteConfig;
|
|
9
|
+
export const Server = Mcp.ServerConfig;
|
|
10
|
+
export class Info extends Schema.Class("Config.MCP")({
|
|
11
|
+
timeout: Timeout.pipe(optional),
|
|
12
|
+
servers: Schema.Record(Schema.String, Server).pipe(optional),
|
|
13
|
+
}) {
|
|
14
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export * as ConfigMedia from "./media.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
declare const Image_base: Schema.Class<Image, Schema.Struct<{
|
|
4
|
+
readonly auto_resize: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
5
|
+
readonly max_width: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
6
|
+
readonly max_height: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
7
|
+
readonly max_base64_bytes: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
8
|
+
}>, {}>;
|
|
9
|
+
export declare class Image extends Image_base {
|
|
10
|
+
}
|
|
11
|
+
declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
12
|
+
readonly image: Schema.decodeTo<Schema.optional<Schema.toType<typeof Image>>, Schema.optionalKey<typeof Image>, never, never>;
|
|
13
|
+
}>, {}>;
|
|
14
|
+
export declare class Info extends Info_base {
|
|
15
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export * as ConfigMedia from "./media.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { optional, PositiveInt } from "../schema.js";
|
|
4
|
+
export class Image extends Schema.Class("Config.Media.Image")({
|
|
5
|
+
auto_resize: Schema.Boolean.pipe(optional),
|
|
6
|
+
max_width: PositiveInt.pipe(optional),
|
|
7
|
+
max_height: PositiveInt.pipe(optional),
|
|
8
|
+
max_base64_bytes: PositiveInt.pipe(optional),
|
|
9
|
+
}) {
|
|
10
|
+
}
|
|
11
|
+
export class Info extends Schema.Class("Config.Media")({
|
|
12
|
+
image: Image.pipe(optional),
|
|
13
|
+
}) {
|
|
14
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export * as ConfigModel from "./model.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
declare const Explicit: Schema.Struct<{
|
|
4
|
+
readonly providerID: Schema.brand<Schema.String, "Provider.ID">;
|
|
5
|
+
readonly model: Schema.brand<Schema.String, "Model.ID">;
|
|
6
|
+
readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>;
|
|
7
|
+
}>;
|
|
8
|
+
export interface Selection extends Schema.Schema.Type<typeof Explicit> {
|
|
9
|
+
}
|
|
10
|
+
export declare const Selection: Schema.decodeTo<Schema.Struct<{
|
|
11
|
+
readonly providerID: Schema.brand<Schema.String, "Provider.ID">;
|
|
12
|
+
readonly model: Schema.brand<Schema.String, "Model.ID">;
|
|
13
|
+
readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>;
|
|
14
|
+
}>, Schema.Union<readonly [Schema.String, Schema.Struct<{
|
|
15
|
+
readonly providerID: Schema.brand<Schema.String, "Provider.ID">;
|
|
16
|
+
readonly model: Schema.brand<Schema.String, "Model.ID">;
|
|
17
|
+
readonly variant: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.VariantID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.VariantID">>, never, never>;
|
|
18
|
+
}>]>, never, never>;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
export * as ConfigModel from "./model.js";
|
|
2
|
+
import { Schema, SchemaGetter } from "effect";
|
|
3
|
+
import { Model } from "../model.js";
|
|
4
|
+
import { Provider } from "../provider.js";
|
|
5
|
+
import { optional } from "../schema.js";
|
|
6
|
+
const ProviderID = Provider.ID.check(Schema.isPattern(/^[^/#]+$/));
|
|
7
|
+
const ModelID = Model.ID.check(Schema.isPattern(/^[^#]+$/));
|
|
8
|
+
const VariantID = Model.VariantID.check(Schema.isPattern(/^[^#]+$/));
|
|
9
|
+
const Explicit = Schema.Struct({
|
|
10
|
+
providerID: ProviderID,
|
|
11
|
+
model: ModelID,
|
|
12
|
+
variant: VariantID.pipe(optional),
|
|
13
|
+
});
|
|
14
|
+
const Short = Schema.String.check(Schema.isPattern(/^[^/#]+\/[^#]+(?:#[^#]+)?$/));
|
|
15
|
+
export const Selection = Schema.Union([Short, Explicit])
|
|
16
|
+
.pipe(Schema.decodeTo(Explicit, {
|
|
17
|
+
decode: SchemaGetter.transform((input) => (typeof input === "string" ? parse(input) : input)),
|
|
18
|
+
encode: SchemaGetter.passthrough({ strict: false }),
|
|
19
|
+
}))
|
|
20
|
+
.annotate({ identifier: "Config.ModelSelection" });
|
|
21
|
+
function parse(input) {
|
|
22
|
+
const ref = Model.Ref.parse(input);
|
|
23
|
+
return {
|
|
24
|
+
providerID: ref.providerID,
|
|
25
|
+
model: ref.id,
|
|
26
|
+
...(ref.variant ? { variant: ref.variant } : {}),
|
|
27
|
+
};
|
|
28
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export * as ConfigPlugin from "./plugin.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
declare const Entry_base: Schema.Class<Entry, Schema.Struct<{
|
|
4
|
+
readonly package: Schema.String;
|
|
5
|
+
readonly options: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
6
|
+
}>, {}>;
|
|
7
|
+
export declare class Entry extends Entry_base {
|
|
8
|
+
}
|
|
9
|
+
export declare const Plugin: Schema.Union<readonly [Schema.String, typeof Entry]>;
|
|
10
|
+
export type Plugin = typeof Plugin.Type;
|
|
11
|
+
export declare const Plugins: Schema.$Array<Schema.Union<readonly [Schema.String, typeof Entry]>>;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export * as ConfigPlugin from "./plugin.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { optional } from "../schema.js";
|
|
4
|
+
export class Entry extends Schema.Class("Config.Plugin.Entry")({
|
|
5
|
+
package: Schema.String,
|
|
6
|
+
options: Schema.Record(Schema.String, Schema.Unknown).pipe(optional),
|
|
7
|
+
}) {
|
|
8
|
+
}
|
|
9
|
+
export const Plugin = Schema.Union([Schema.String, Entry]);
|
|
10
|
+
export const Plugins = Plugin.pipe(Schema.Array);
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export * as ConfigPolicy from "./policy.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
export declare const Effect: Schema.Literals<readonly ["allow", "deny"]>;
|
|
4
|
+
export type Effect = typeof Effect.Type;
|
|
5
|
+
export declare const Info: Schema.Struct<{
|
|
6
|
+
readonly action: Schema.Literal<"provider.use">;
|
|
7
|
+
readonly resource: Schema.String;
|
|
8
|
+
readonly effect: Schema.Literals<readonly ["allow", "deny"]>;
|
|
9
|
+
}>;
|
|
10
|
+
export type Info = typeof Info.Type;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export * as ConfigPolicy from "./policy.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
export const Effect = Schema.Literals(["allow", "deny"]);
|
|
4
|
+
export const Info = Schema.Struct({
|
|
5
|
+
action: Schema.Literal("provider.use"),
|
|
6
|
+
resource: Schema.String,
|
|
7
|
+
effect: Effect,
|
|
8
|
+
});
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
export * as ConfigProvider from "./provider.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
export declare const Overlays: {
|
|
4
|
+
settings: 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>;
|
|
5
|
+
headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
6
|
+
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>;
|
|
7
|
+
};
|
|
8
|
+
declare const Request_base: Schema.Class<Request, Schema.Struct<{
|
|
9
|
+
readonly headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
10
|
+
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>;
|
|
11
|
+
}>, {}>;
|
|
12
|
+
export declare class Request extends Request_base {
|
|
13
|
+
}
|
|
14
|
+
declare const Cache_base: Schema.Class<Cache, Schema.Struct<{
|
|
15
|
+
readonly read: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.Finite, "Money.USDPerMillionTokens"> & {
|
|
16
|
+
zero: number & import("effect/Brand").Brand<"Money.USDPerMillionTokens">;
|
|
17
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.Finite, "Money.USDPerMillionTokens"> & {
|
|
18
|
+
zero: number & import("effect/Brand").Brand<"Money.USDPerMillionTokens">;
|
|
19
|
+
}>, never, never>;
|
|
20
|
+
readonly write: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.Finite, "Money.USDPerMillionTokens"> & {
|
|
21
|
+
zero: number & import("effect/Brand").Brand<"Money.USDPerMillionTokens">;
|
|
22
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.Finite, "Money.USDPerMillionTokens"> & {
|
|
23
|
+
zero: number & import("effect/Brand").Brand<"Money.USDPerMillionTokens">;
|
|
24
|
+
}>, never, never>;
|
|
25
|
+
}>, {}>;
|
|
26
|
+
declare class Cache extends Cache_base {
|
|
27
|
+
}
|
|
28
|
+
declare const Cost_base: Schema.Class<Cost, Schema.Struct<{
|
|
29
|
+
readonly tier: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
30
|
+
readonly type: Schema.Literal<"context">;
|
|
31
|
+
readonly size: Schema.Int;
|
|
32
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
33
|
+
readonly type: Schema.Literal<"context">;
|
|
34
|
+
readonly size: Schema.Int;
|
|
35
|
+
}>>, never, never>;
|
|
36
|
+
readonly input: Schema.brand<Schema.Finite, "Money.USDPerMillionTokens"> & {
|
|
37
|
+
zero: number & import("effect/Brand").Brand<"Money.USDPerMillionTokens">;
|
|
38
|
+
};
|
|
39
|
+
readonly output: Schema.brand<Schema.Finite, "Money.USDPerMillionTokens"> & {
|
|
40
|
+
zero: number & import("effect/Brand").Brand<"Money.USDPerMillionTokens">;
|
|
41
|
+
};
|
|
42
|
+
readonly cache: Schema.decodeTo<Schema.optional<Schema.toType<typeof Cache>>, Schema.optionalKey<typeof Cache>, never, never>;
|
|
43
|
+
}>, {}>;
|
|
44
|
+
declare class Cost extends Cost_base {
|
|
45
|
+
}
|
|
46
|
+
declare const Limit_base: Schema.Class<Limit, Schema.Struct<{
|
|
47
|
+
readonly context: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
48
|
+
readonly input: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
49
|
+
readonly output: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
50
|
+
}>, {}>;
|
|
51
|
+
declare class Limit extends Limit_base {
|
|
52
|
+
}
|
|
53
|
+
declare const Model_base: Schema.Class<Model, Schema.Struct<{
|
|
54
|
+
readonly capabilities: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
55
|
+
readonly tools: Schema.Boolean;
|
|
56
|
+
readonly input: Schema.$Array<Schema.String>;
|
|
57
|
+
readonly output: Schema.$Array<Schema.String>;
|
|
58
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
59
|
+
readonly tools: Schema.Boolean;
|
|
60
|
+
readonly input: Schema.$Array<Schema.String>;
|
|
61
|
+
readonly output: Schema.$Array<Schema.String>;
|
|
62
|
+
}>>, never, never>;
|
|
63
|
+
readonly variants: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Array<Schema.Struct<{
|
|
64
|
+
readonly settings: 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>;
|
|
65
|
+
readonly headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
66
|
+
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>;
|
|
67
|
+
readonly id: Schema.brand<Schema.String, "Model.VariantID">;
|
|
68
|
+
}>>>>, Schema.optionalKey<Schema.$Array<Schema.Struct<{
|
|
69
|
+
readonly settings: 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>;
|
|
70
|
+
readonly headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
71
|
+
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>;
|
|
72
|
+
readonly id: Schema.brand<Schema.String, "Model.VariantID">;
|
|
73
|
+
}>>>, never, never>;
|
|
74
|
+
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>;
|
|
75
|
+
readonly disabled: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
76
|
+
readonly limit: Schema.decodeTo<Schema.optional<Schema.toType<typeof Limit>>, Schema.optionalKey<typeof Limit>, never, never>;
|
|
77
|
+
readonly settings: 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>;
|
|
78
|
+
readonly headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
79
|
+
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>;
|
|
80
|
+
readonly modelID: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.ID">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.ID">>, never, never>;
|
|
81
|
+
readonly family: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Model.Family">>>, Schema.optionalKey<Schema.brand<Schema.String, "Model.Family">>, never, never>;
|
|
82
|
+
readonly name: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
83
|
+
readonly compatibility: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Struct<{
|
|
84
|
+
readonly reasoningField: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Codec<import("../model.js").ReasoningField, import("../model.js").ReasoningField, never, never>>>, Schema.optionalKey<Schema.Codec<import("../model.js").ReasoningField, import("../model.js").ReasoningField, never, never>>, never, never>;
|
|
85
|
+
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>;
|
|
86
|
+
readonly requireFinishReason: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
87
|
+
}>>>, Schema.optionalKey<Schema.Struct<{
|
|
88
|
+
readonly reasoningField: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Codec<import("../model.js").ReasoningField, import("../model.js").ReasoningField, never, never>>>, Schema.optionalKey<Schema.Codec<import("../model.js").ReasoningField, import("../model.js").ReasoningField, never, never>>, never, never>;
|
|
89
|
+
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>;
|
|
90
|
+
readonly requireFinishReason: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
91
|
+
}>>, never, never>;
|
|
92
|
+
readonly package: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
93
|
+
}>, {}>;
|
|
94
|
+
declare class Model extends Model_base {
|
|
95
|
+
}
|
|
96
|
+
declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
97
|
+
readonly models: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, typeof Model>>>, Schema.optionalKey<Schema.$Record<Schema.String, typeof Model>>, never, never>;
|
|
98
|
+
readonly settings: 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>;
|
|
99
|
+
readonly headers: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.String>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.String>>, never, never>;
|
|
100
|
+
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>;
|
|
101
|
+
readonly name: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
102
|
+
readonly env: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Array<Schema.String>>>, Schema.optionalKey<Schema.$Array<Schema.String>>, never, never>;
|
|
103
|
+
readonly package: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
104
|
+
}>, {}>;
|
|
105
|
+
export declare class Info extends Info_base {
|
|
106
|
+
}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
export * as ConfigProvider from "./provider.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { Money } from "../money.js";
|
|
4
|
+
import { Capabilities, Compatibility, Family, ID, VariantID } from "../model.js";
|
|
5
|
+
import { optional } from "../schema.js";
|
|
6
|
+
const JsonRecord = Schema.Record(Schema.String, Schema.Json);
|
|
7
|
+
export const Overlays = {
|
|
8
|
+
settings: JsonRecord.pipe(optional),
|
|
9
|
+
headers: Schema.Record(Schema.String, Schema.String).pipe(optional),
|
|
10
|
+
body: JsonRecord.pipe(optional),
|
|
11
|
+
};
|
|
12
|
+
export class Request extends Schema.Class("Config.Provider.Request")({
|
|
13
|
+
headers: Overlays.headers,
|
|
14
|
+
body: Overlays.body,
|
|
15
|
+
}) {
|
|
16
|
+
}
|
|
17
|
+
class Cache extends Schema.Class("Config.Model.Cost.Cache")({
|
|
18
|
+
read: Money.USDPerMillionTokens.pipe(optional),
|
|
19
|
+
write: Money.USDPerMillionTokens.pipe(optional),
|
|
20
|
+
}) {
|
|
21
|
+
}
|
|
22
|
+
class Cost extends Schema.Class("Config.Model.Cost")({
|
|
23
|
+
tier: Schema.Struct({
|
|
24
|
+
type: Schema.Literal("context"),
|
|
25
|
+
size: Schema.Int,
|
|
26
|
+
}).pipe(optional),
|
|
27
|
+
input: Money.USDPerMillionTokens,
|
|
28
|
+
output: Money.USDPerMillionTokens,
|
|
29
|
+
cache: Cache.pipe(optional),
|
|
30
|
+
}) {
|
|
31
|
+
}
|
|
32
|
+
class Limit extends Schema.Class("Config.Model.Limit")({
|
|
33
|
+
context: Schema.Int.pipe(optional),
|
|
34
|
+
input: Schema.Int.pipe(optional),
|
|
35
|
+
output: Schema.Int.pipe(optional),
|
|
36
|
+
}) {
|
|
37
|
+
}
|
|
38
|
+
class Model extends Schema.Class("Config.Model")({
|
|
39
|
+
modelID: ID.pipe(optional),
|
|
40
|
+
family: Family.pipe(optional),
|
|
41
|
+
name: Schema.String.pipe(optional),
|
|
42
|
+
compatibility: Compatibility.pipe(optional),
|
|
43
|
+
package: Schema.String.pipe(optional),
|
|
44
|
+
...Overlays,
|
|
45
|
+
capabilities: Capabilities.pipe(optional),
|
|
46
|
+
variants: Schema.Struct({
|
|
47
|
+
id: VariantID,
|
|
48
|
+
...Overlays,
|
|
49
|
+
}).pipe(Schema.Array, optional),
|
|
50
|
+
cost: Schema.Union([Cost, Cost.pipe(Schema.Array)]).pipe(optional),
|
|
51
|
+
disabled: Schema.Boolean.pipe(optional),
|
|
52
|
+
limit: Limit.pipe(optional),
|
|
53
|
+
}) {
|
|
54
|
+
}
|
|
55
|
+
export class Info extends Schema.Class("Config.Provider")({
|
|
56
|
+
name: Schema.String.pipe(optional),
|
|
57
|
+
env: Schema.String.pipe(Schema.Array, optional),
|
|
58
|
+
package: Schema.String.pipe(optional),
|
|
59
|
+
...Overlays,
|
|
60
|
+
models: Schema.Record(Schema.String, Model).pipe(optional),
|
|
61
|
+
}) {
|
|
62
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export * as ConfigReference from "./reference.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
declare const Git_base: Schema.Class<Git, Schema.Struct<{
|
|
4
|
+
readonly repository: Schema.String;
|
|
5
|
+
readonly branch: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
6
|
+
readonly description: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
7
|
+
readonly hidden: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
8
|
+
}>, {}>;
|
|
9
|
+
export declare class Git extends Git_base {
|
|
10
|
+
}
|
|
11
|
+
declare const Local_base: Schema.Class<Local, Schema.Struct<{
|
|
12
|
+
readonly path: Schema.String;
|
|
13
|
+
readonly description: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
14
|
+
readonly hidden: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
15
|
+
}>, {}>;
|
|
16
|
+
export declare class Local extends Local_base {
|
|
17
|
+
}
|
|
18
|
+
export declare const Entry: Schema.Union<readonly [Schema.String, typeof Git, typeof Local]>;
|
|
19
|
+
export type Entry = typeof Entry.Type;
|
|
20
|
+
export declare const Info: Schema.$Record<Schema.String, Schema.Union<readonly [Schema.String, typeof Git, typeof Local]>>;
|
|
21
|
+
export type Info = typeof Info.Type;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export * as ConfigReference from "./reference.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { optional } from "../schema.js";
|
|
4
|
+
export class Git extends Schema.Class("Config.Reference.Git")({
|
|
5
|
+
repository: Schema.String,
|
|
6
|
+
branch: Schema.String.pipe(optional),
|
|
7
|
+
description: Schema.String.pipe(optional),
|
|
8
|
+
hidden: Schema.Boolean.pipe(optional),
|
|
9
|
+
}) {
|
|
10
|
+
}
|
|
11
|
+
export class Local extends Schema.Class("Config.Reference.Local")({
|
|
12
|
+
path: Schema.String,
|
|
13
|
+
description: Schema.String.pipe(optional),
|
|
14
|
+
hidden: Schema.Boolean.pipe(optional),
|
|
15
|
+
}) {
|
|
16
|
+
}
|
|
17
|
+
export const Entry = Schema.Union([Schema.String, Git, Local]);
|
|
18
|
+
export const Info = Schema.Record(Schema.String, Entry);
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export * as ConfigToolOutput from "./tool-output.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
4
|
+
readonly max_lines: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
5
|
+
readonly max_bytes: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Int>>, Schema.optionalKey<Schema.Int>, never, never>;
|
|
6
|
+
}>, {}>;
|
|
7
|
+
export declare class Info extends Info_base {
|
|
8
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export * as ConfigToolOutput from "./tool-output.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { optional, PositiveInt } from "../schema.js";
|
|
4
|
+
export class Info extends Schema.Class("Config.ToolOutput")({
|
|
5
|
+
max_lines: PositiveInt.pipe(optional),
|
|
6
|
+
max_bytes: PositiveInt.pipe(optional),
|
|
7
|
+
}) {
|
|
8
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export * as ConfigWarming from "./warming.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
4
|
+
readonly prompt: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
5
|
+
readonly interval: Schema.decodeTo<Schema.optional<Schema.toType<Schema.DurationFromString>>, Schema.optionalKey<Schema.DurationFromString>, never, never>;
|
|
6
|
+
readonly duration: Schema.decodeTo<Schema.optional<Schema.toType<Schema.DurationFromString>>, Schema.optionalKey<Schema.DurationFromString>, never, never>;
|
|
7
|
+
}>, {}>;
|
|
8
|
+
export declare class Info extends Info_base {
|
|
9
|
+
}
|
|
10
|
+
export declare const Warming: Schema.Union<readonly [Schema.Boolean, typeof Info]>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export * as ConfigWarming from "./warming.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { optional } from "../schema.js";
|
|
4
|
+
export class Info extends Schema.Class("Config.Warming")({
|
|
5
|
+
prompt: Schema.String.pipe(optional).annotate({
|
|
6
|
+
description: "Prompt sent for keep-alive requests",
|
|
7
|
+
}),
|
|
8
|
+
interval: Schema.DurationFromString.pipe(optional).annotate({
|
|
9
|
+
description: 'Idle time between keep-alive requests (default: "4 minutes")',
|
|
10
|
+
}),
|
|
11
|
+
duration: Schema.DurationFromString.pipe(optional).annotate({
|
|
12
|
+
description: 'Time after the last active request to keep a session warm (default: "30 minutes")',
|
|
13
|
+
}),
|
|
14
|
+
}) {
|
|
15
|
+
}
|
|
16
|
+
export const Warming = Schema.Union([Schema.Boolean, Info]);
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export * as ConfigWatcher from "./watcher.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
4
|
+
readonly ignore: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Array<Schema.String>>>, Schema.optionalKey<Schema.$Array<Schema.String>>, never, never>;
|
|
5
|
+
}>, {}>;
|
|
6
|
+
export declare class Info extends Info_base {
|
|
7
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export * as ConfigWebSearch from "./websearch.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
declare const Info_base: Schema.Class<Info, Schema.Struct<{
|
|
4
|
+
readonly provider: Schema.Union<readonly [Schema.Literal<"random">, Schema.brand<Schema.String, "WebSearch.ID">]>;
|
|
5
|
+
}>, {}>;
|
|
6
|
+
export declare class Info extends Info_base {
|
|
7
|
+
}
|
|
8
|
+
export declare const Selection: Schema.Union<readonly [Schema.Literal<false>, typeof Info]>;
|
|
9
|
+
export type Selection = typeof Selection.Type;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export * as ConfigWebSearch from "./websearch.js";
|
|
2
|
+
import { Schema } from "effect";
|
|
3
|
+
import { WebSearch } from "../websearch.js";
|
|
4
|
+
export class Info extends Schema.Class("ConfigWebSearch.Info")({
|
|
5
|
+
provider: Schema.Union([Schema.Literal("random"), WebSearch.ID]),
|
|
6
|
+
}) {
|
|
7
|
+
}
|
|
8
|
+
export const Selection = Schema.Union([Schema.Literal(false), Info]);
|