@codeworksh/plugin 0.0.1-canary.10.1.g65d5c167

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.
Files changed (90) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +111 -0
  3. package/error-ClDISWlT.d.mts +11 -0
  4. package/event-9PbbjnHJ.d.mts +895 -0
  5. package/event.d.mts +2 -0
  6. package/event.mjs +125 -0
  7. package/event.mjs.map +1 -0
  8. package/filesystem-Cp-KapCE.d.mts +142 -0
  9. package/ids-CHjmAdTc.d.mts +43 -0
  10. package/ids.d.mts +2 -0
  11. package/ids.mjs +48 -0
  12. package/ids.mjs.map +1 -0
  13. package/index.d.mts +3 -0
  14. package/index.mjs +3 -0
  15. package/io-BYs7hbiY.d.mts +497 -0
  16. package/location-D4hAfuXF.d.mts +61 -0
  17. package/location.d.mts +2 -0
  18. package/location.mjs +48 -0
  19. package/location.mjs.map +1 -0
  20. package/package.json +169 -0
  21. package/plugin/prompt.d.mts +2 -0
  22. package/plugin/prompt.mjs +7 -0
  23. package/plugin/prompt.mjs.map +1 -0
  24. package/plugin/tool.d.mts +2 -0
  25. package/plugin/tool.mjs +29 -0
  26. package/plugin/tool.mjs.map +1 -0
  27. package/plugin-DHCdfzdO.d.mts +140 -0
  28. package/plugin-lorpq7Oi.mjs +41 -0
  29. package/plugin-lorpq7Oi.mjs.map +1 -0
  30. package/plugin.d.mts +4 -0
  31. package/plugin.mjs +4 -0
  32. package/posix.d.mts +6 -0
  33. package/posix.mjs +8 -0
  34. package/posix.mjs.map +1 -0
  35. package/project-CLGsIFD-.d.mts +21 -0
  36. package/project.d.mts +2 -0
  37. package/project.mjs +22 -0
  38. package/project.mjs.map +1 -0
  39. package/prompt-BcpagjGh.d.mts +10 -0
  40. package/repo.d.mts +42 -0
  41. package/repo.mjs +46 -0
  42. package/repo.mjs.map +1 -0
  43. package/rolldown-runtime-D7D4PA-g.mjs +13 -0
  44. package/sandbox/driver.d.mts +2 -0
  45. package/sandbox/driver.mjs +63 -0
  46. package/sandbox/driver.mjs.map +1 -0
  47. package/sandbox/errors.d.mts +2 -0
  48. package/sandbox/errors.mjs +160 -0
  49. package/sandbox/errors.mjs.map +1 -0
  50. package/sandbox/filesystem.d.mts +2 -0
  51. package/sandbox/filesystem.mjs +142 -0
  52. package/sandbox/filesystem.mjs.map +1 -0
  53. package/sandbox/instance.d.mts +2 -0
  54. package/sandbox/instance.mjs +144 -0
  55. package/sandbox/instance.mjs.map +1 -0
  56. package/sandbox/io.d.mts +2 -0
  57. package/sandbox/io.mjs +127 -0
  58. package/sandbox/io.mjs.map +1 -0
  59. package/sandbox/resource.d.mts +28 -0
  60. package/sandbox/resource.mjs +29 -0
  61. package/sandbox/resource.mjs.map +1 -0
  62. package/sandbox/shell.d.mts +2 -0
  63. package/sandbox/shell.mjs +93 -0
  64. package/sandbox/shell.mjs.map +1 -0
  65. package/sandbox.d.mts +19 -0
  66. package/sandbox.mjs +49 -0
  67. package/sandbox.mjs.map +1 -0
  68. package/schema.d.mts +93 -0
  69. package/schema.mjs +107 -0
  70. package/schema.mjs.map +1 -0
  71. package/settings-C6RxGd-M.d.mts +557 -0
  72. package/settings.d.mts +2 -0
  73. package/settings.mjs +132 -0
  74. package/settings.mjs.map +1 -0
  75. package/shell-CZ6Y4lNU.d.mts +109 -0
  76. package/space-CR-9UxdT.d.mts +25 -0
  77. package/space.d.mts +2 -0
  78. package/space.mjs +33 -0
  79. package/space.mjs.map +1 -0
  80. package/tool/error.d.mts +2 -0
  81. package/tool/error.mjs +11 -0
  82. package/tool/error.mjs.map +1 -0
  83. package/tool/progress.d.mts +2 -0
  84. package/tool/progress.mjs +11 -0
  85. package/tool/progress.mjs.map +1 -0
  86. package/tool-BoVqkYvL.d.mts +287 -0
  87. package/tool-DuYBgiJf.d.mts +142 -0
  88. package/tool.d.mts +2 -0
  89. package/tool.mjs +71 -0
  90. package/tool.mjs.map +1 -0
@@ -0,0 +1,557 @@
1
+ import { Model } from "@codeworksh/aikit";
2
+ import { Schema } from "effect";
3
+ //#region src/settings.d.ts
4
+ declare const ThinkingLevel: Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "off" | "xhigh")[]>;
5
+ declare const ToolExecution: Schema.Literals<readonly ["sequential", "parallel"]>;
6
+ type ToolExecution = typeof ToolExecution.Type;
7
+ /** Aikit does not export its request schema; keep this routing surface checked against its public types. */
8
+ declare const requestFields: {
9
+ temperature: Schema.optional<Schema.Finite>;
10
+ maxTokens: Schema.optional<Schema.Finite>;
11
+ cacheRetention: Schema.optional<Schema.Literals<readonly ["none", "short", "long"]>>;
12
+ headers: Schema.optional<Schema.$Record<Schema.String, Schema.String>>;
13
+ timeoutMs: Schema.optional<Schema.Finite>;
14
+ maxRetries: Schema.optional<Schema.Finite>;
15
+ metadata: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
16
+ thinkingBudgets: Schema.optional<Schema.$Record<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "xhigh")[]>, Schema.optional<Schema.Finite>>>;
17
+ baseURL: Schema.optional<Schema.String>;
18
+ method: Schema.optional<Schema.Literals<("chat" | "completion" | "completionModel" | "languageModel" | "messages" | "responses")[]>>;
19
+ };
20
+ declare const KeyReference: Schema.String;
21
+ /** The variable a `"${NAME}"` reference names. */
22
+ declare const keyName: (reference: string) => string;
23
+ /** The wire protocol a model speaks, which a catalog entry may have wrong for a local endpoint. */
24
+ declare const ModelProtocol: Schema.Literals<("anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai")[]>;
25
+ declare const Block: Schema.StructWithRest<Schema.Struct<{
26
+ readonly temperature: Schema.optional<Schema.Finite>;
27
+ readonly maxTokens: Schema.optional<Schema.Finite>;
28
+ readonly cacheRetention: Schema.optional<Schema.Literals<readonly ["none", "short", "long"]>>;
29
+ readonly headers: Schema.optional<Schema.$Record<Schema.String, Schema.String>>;
30
+ readonly timeoutMs: Schema.optional<Schema.Finite>;
31
+ readonly maxRetries: Schema.optional<Schema.Finite>;
32
+ readonly metadata: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
33
+ readonly thinkingBudgets: Schema.optional<Schema.$Record<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "xhigh")[]>, Schema.optional<Schema.Finite>>>;
34
+ readonly baseURL: Schema.optional<Schema.String>;
35
+ readonly method: Schema.optional<Schema.Literals<("chat" | "completion" | "completionModel" | "languageModel" | "messages" | "responses")[]>>;
36
+ readonly protocol: Schema.optional<Schema.Literals<("anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai")[]>>;
37
+ readonly thinkingLevel: Schema.optional<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "off" | "xhigh")[]>>;
38
+ readonly toolExecution: Schema.optional<Schema.Literals<readonly ["sequential", "parallel"]>>;
39
+ readonly contextWindow: Schema.optional<Schema.Finite>;
40
+ /** Which environment variable holds the key for this model: `"${NAME}"`. */
41
+ readonly apiKey: Schema.optional<Schema.String>;
42
+ readonly extras: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
43
+ }>, readonly [Schema.$Record<Schema.String, Schema.Unknown>]>;
44
+ type Block = typeof Block.Type;
45
+ declare const Model$1: Schema.Struct<{
46
+ readonly provider: Schema.optional<Schema.String>;
47
+ readonly id: Schema.optional<Schema.String>;
48
+ readonly thinkingLevel: Schema.optional<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "off" | "xhigh")[]>>;
49
+ readonly toolExecution: Schema.optional<Schema.Literals<readonly ["sequential", "parallel"]>>;
50
+ readonly thinkingBudgets: Schema.optional<Schema.$Record<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "xhigh")[]>, Schema.optional<Schema.Finite>>>;
51
+ readonly options: Schema.optional<Schema.StructWithRest<Schema.Struct<{
52
+ readonly temperature: Schema.optional<Schema.Finite>;
53
+ readonly maxTokens: Schema.optional<Schema.Finite>;
54
+ readonly cacheRetention: Schema.optional<Schema.Literals<readonly ["none", "short", "long"]>>;
55
+ readonly headers: Schema.optional<Schema.$Record<Schema.String, Schema.String>>;
56
+ readonly timeoutMs: Schema.optional<Schema.Finite>;
57
+ readonly maxRetries: Schema.optional<Schema.Finite>;
58
+ readonly metadata: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
59
+ readonly thinkingBudgets: Schema.optional<Schema.$Record<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "xhigh")[]>, Schema.optional<Schema.Finite>>>;
60
+ readonly baseURL: Schema.optional<Schema.String>;
61
+ readonly method: Schema.optional<Schema.Literals<("chat" | "completion" | "completionModel" | "languageModel" | "messages" | "responses")[]>>;
62
+ readonly protocol: Schema.optional<Schema.Literals<("anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai")[]>>;
63
+ readonly thinkingLevel: Schema.optional<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "off" | "xhigh")[]>>;
64
+ readonly toolExecution: Schema.optional<Schema.Literals<readonly ["sequential", "parallel"]>>;
65
+ readonly contextWindow: Schema.optional<Schema.Finite>;
66
+ /** Which environment variable holds the key for this model: `"${NAME}"`. */
67
+ readonly apiKey: Schema.optional<Schema.String>;
68
+ readonly extras: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
69
+ }>, readonly [Schema.$Record<Schema.String, Schema.Unknown>]>>;
70
+ readonly providerOptions: Schema.optional<Schema.$Record<Schema.String, Schema.$Record<Schema.String, Schema.StructWithRest<Schema.Struct<{
71
+ readonly temperature: Schema.optional<Schema.Finite>;
72
+ readonly maxTokens: Schema.optional<Schema.Finite>;
73
+ readonly cacheRetention: Schema.optional<Schema.Literals<readonly ["none", "short", "long"]>>;
74
+ readonly headers: Schema.optional<Schema.$Record<Schema.String, Schema.String>>;
75
+ readonly timeoutMs: Schema.optional<Schema.Finite>;
76
+ readonly maxRetries: Schema.optional<Schema.Finite>;
77
+ readonly metadata: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
78
+ readonly thinkingBudgets: Schema.optional<Schema.$Record<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "xhigh")[]>, Schema.optional<Schema.Finite>>>;
79
+ readonly baseURL: Schema.optional<Schema.String>;
80
+ readonly method: Schema.optional<Schema.Literals<("chat" | "completion" | "completionModel" | "languageModel" | "messages" | "responses")[]>>;
81
+ readonly protocol: Schema.optional<Schema.Literals<("anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai")[]>>;
82
+ readonly thinkingLevel: Schema.optional<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "off" | "xhigh")[]>>;
83
+ readonly toolExecution: Schema.optional<Schema.Literals<readonly ["sequential", "parallel"]>>;
84
+ readonly contextWindow: Schema.optional<Schema.Finite>;
85
+ /** Which environment variable holds the key for this model: `"${NAME}"`. */
86
+ readonly apiKey: Schema.optional<Schema.String>;
87
+ readonly extras: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
88
+ }>, readonly [Schema.$Record<Schema.String, Schema.Unknown>]>>>>;
89
+ }>;
90
+ /**
91
+ * A catalog entry in settings: an aikit `Model.Info`, read exactly like an entry of the generated
92
+ * catalog. The one difference is `provider.key`, which must be a `"${NAME}"` reference.
93
+ */
94
+ declare const ModelEntry: Schema.decodeTo<Schema.declare<{
95
+ api?: {
96
+ id?: string;
97
+ url?: string;
98
+ method?: "chat" | "completion" | "completionModel" | "languageModel" | "messages" | "responses";
99
+ };
100
+ baseUrl: string;
101
+ compat?: {
102
+ supportsThinkingLevel?: boolean;
103
+ supportsToolSearch?: boolean;
104
+ supportsAdditionalTools?: boolean;
105
+ supportsStrictMode?: boolean;
106
+ supportsOpenAIGrammarTools?: boolean;
107
+ supportsThinkingTokenBudget?: boolean;
108
+ forceAdaptiveThinking?: boolean;
109
+ thinkingTokenBudgetField?: string;
110
+ };
111
+ contextWindow: number;
112
+ cost: {
113
+ input: number;
114
+ output: number;
115
+ cacheRead: number;
116
+ cacheWrite: number;
117
+ tiers?: {
118
+ input: number;
119
+ output: number;
120
+ cacheRead: number;
121
+ cacheWrite: number;
122
+ inputTokensAbove: number;
123
+ }[];
124
+ serviceTierMultipliers?: Record<string, number>;
125
+ };
126
+ headers?: Record<string, string>;
127
+ id: string;
128
+ input: ("image" | "text")[];
129
+ maxTokens: number;
130
+ name: string;
131
+ npm?: string;
132
+ options?: Record<string, unknown>;
133
+ protocol: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
134
+ provider: {
135
+ id: string;
136
+ name: string;
137
+ source: "api" | "config" | "custom" | "env" | "unknown";
138
+ env: string[];
139
+ key?: string;
140
+ options?: Record<string, any>;
141
+ };
142
+ providerOptions?: Record<string, unknown>;
143
+ providerOptionsKey?: string;
144
+ reasoning: boolean;
145
+ supportedProtocols?: {
146
+ anthropic?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
147
+ google?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
148
+ googleVertex?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
149
+ googleVertexAnthropic?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
150
+ githubCopilot?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
151
+ openai?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
152
+ openaiCompatible?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
153
+ openaiCodex?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
154
+ openrouter?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
155
+ xai?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
156
+ };
157
+ thinkingBudgets?: {
158
+ high?: number;
159
+ low?: number;
160
+ max?: number;
161
+ medium?: number;
162
+ minimal?: number;
163
+ xhigh?: number;
164
+ };
165
+ thinkingLevelMap?: {
166
+ high?: string | null;
167
+ low?: string | null;
168
+ max?: string | null;
169
+ medium?: string | null;
170
+ minimal?: string | null;
171
+ off?: string | null;
172
+ xhigh?: string | null;
173
+ };
174
+ }, {
175
+ api?: {
176
+ id?: string;
177
+ url?: string;
178
+ method?: "chat" | "completion" | "completionModel" | "languageModel" | "messages" | "responses";
179
+ };
180
+ baseUrl: string;
181
+ compat?: {
182
+ supportsThinkingLevel?: boolean;
183
+ supportsToolSearch?: boolean;
184
+ supportsAdditionalTools?: boolean;
185
+ supportsStrictMode?: boolean;
186
+ supportsOpenAIGrammarTools?: boolean;
187
+ supportsThinkingTokenBudget?: boolean;
188
+ forceAdaptiveThinking?: boolean;
189
+ thinkingTokenBudgetField?: string;
190
+ };
191
+ contextWindow: number;
192
+ cost: {
193
+ input: number;
194
+ output: number;
195
+ cacheRead: number;
196
+ cacheWrite: number;
197
+ tiers?: {
198
+ input: number;
199
+ output: number;
200
+ cacheRead: number;
201
+ cacheWrite: number;
202
+ inputTokensAbove: number;
203
+ }[];
204
+ serviceTierMultipliers?: Record<string, number>;
205
+ };
206
+ headers?: Record<string, string>;
207
+ id: string;
208
+ input: ("image" | "text")[];
209
+ maxTokens: number;
210
+ name: string;
211
+ npm?: string;
212
+ options?: Record<string, unknown>;
213
+ protocol: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
214
+ provider: {
215
+ id: string;
216
+ name: string;
217
+ source: "api" | "config" | "custom" | "env" | "unknown";
218
+ env: string[];
219
+ key?: string;
220
+ options?: Record<string, any>;
221
+ };
222
+ providerOptions?: Record<string, unknown>;
223
+ providerOptionsKey?: string;
224
+ reasoning: boolean;
225
+ supportedProtocols?: {
226
+ anthropic?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
227
+ google?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
228
+ googleVertex?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
229
+ googleVertexAnthropic?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
230
+ githubCopilot?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
231
+ openai?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
232
+ openaiCompatible?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
233
+ openaiCodex?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
234
+ openrouter?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
235
+ xai?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
236
+ };
237
+ thinkingBudgets?: {
238
+ high?: number;
239
+ low?: number;
240
+ max?: number;
241
+ medium?: number;
242
+ minimal?: number;
243
+ xhigh?: number;
244
+ };
245
+ thinkingLevelMap?: {
246
+ high?: string | null;
247
+ low?: string | null;
248
+ max?: string | null;
249
+ medium?: string | null;
250
+ minimal?: string | null;
251
+ off?: string | null;
252
+ xhigh?: string | null;
253
+ };
254
+ }>, Schema.Unknown, never, never>;
255
+ type ModelEntry = typeof ModelEntry.Type;
256
+ declare const PluginPatch: Schema.Union<readonly [Schema.Struct<{
257
+ readonly enabled: Schema.optional<Schema.Boolean>;
258
+ readonly options: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
259
+ readonly plugin: Schema.String;
260
+ }>, Schema.Struct<{
261
+ readonly enabled: Schema.optional<Schema.Boolean>;
262
+ readonly options: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
263
+ readonly package: Schema.String;
264
+ }>]>;
265
+ declare const PluginEntry: Schema.Union<readonly [Schema.String, Schema.Union<readonly [Schema.Struct<{
266
+ readonly enabled: Schema.optional<Schema.Boolean>;
267
+ readonly options: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
268
+ readonly plugin: Schema.String;
269
+ }>, Schema.Struct<{
270
+ readonly enabled: Schema.optional<Schema.Boolean>;
271
+ readonly options: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
272
+ readonly package: Schema.String;
273
+ }>]>]>;
274
+ type PluginEntry = typeof PluginEntry.Type;
275
+ declare const Patch: Schema.Struct<{
276
+ readonly $schema: Schema.optional<Schema.String>;
277
+ readonly plugins: Schema.optional<Schema.$Array<Schema.Union<readonly [Schema.String, Schema.Union<readonly [Schema.Struct<{
278
+ readonly enabled: Schema.optional<Schema.Boolean>;
279
+ readonly options: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
280
+ readonly plugin: Schema.String;
281
+ }>, Schema.Struct<{
282
+ readonly enabled: Schema.optional<Schema.Boolean>;
283
+ readonly options: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
284
+ readonly package: Schema.String;
285
+ }>]>]>>>;
286
+ readonly model: Schema.optional<Schema.Struct<{
287
+ readonly provider: Schema.optional<Schema.String>;
288
+ readonly id: Schema.optional<Schema.String>;
289
+ readonly thinkingLevel: Schema.optional<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "off" | "xhigh")[]>>;
290
+ readonly toolExecution: Schema.optional<Schema.Literals<readonly ["sequential", "parallel"]>>;
291
+ readonly thinkingBudgets: Schema.optional<Schema.$Record<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "xhigh")[]>, Schema.optional<Schema.Finite>>>;
292
+ readonly options: Schema.optional<Schema.StructWithRest<Schema.Struct<{
293
+ readonly temperature: Schema.optional<Schema.Finite>;
294
+ readonly maxTokens: Schema.optional<Schema.Finite>;
295
+ readonly cacheRetention: Schema.optional<Schema.Literals<readonly ["none", "short", "long"]>>;
296
+ readonly headers: Schema.optional<Schema.$Record<Schema.String, Schema.String>>;
297
+ readonly timeoutMs: Schema.optional<Schema.Finite>;
298
+ readonly maxRetries: Schema.optional<Schema.Finite>;
299
+ readonly metadata: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
300
+ readonly thinkingBudgets: Schema.optional<Schema.$Record<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "xhigh")[]>, Schema.optional<Schema.Finite>>>;
301
+ readonly baseURL: Schema.optional<Schema.String>;
302
+ readonly method: Schema.optional<Schema.Literals<("chat" | "completion" | "completionModel" | "languageModel" | "messages" | "responses")[]>>;
303
+ readonly protocol: Schema.optional<Schema.Literals<("anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai")[]>>;
304
+ readonly thinkingLevel: Schema.optional<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "off" | "xhigh")[]>>;
305
+ readonly toolExecution: Schema.optional<Schema.Literals<readonly ["sequential", "parallel"]>>;
306
+ readonly contextWindow: Schema.optional<Schema.Finite>;
307
+ /** Which environment variable holds the key for this model: `"${NAME}"`. */
308
+ readonly apiKey: Schema.optional<Schema.String>;
309
+ readonly extras: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
310
+ }>, readonly [Schema.$Record<Schema.String, Schema.Unknown>]>>;
311
+ readonly providerOptions: Schema.optional<Schema.$Record<Schema.String, Schema.$Record<Schema.String, Schema.StructWithRest<Schema.Struct<{
312
+ readonly temperature: Schema.optional<Schema.Finite>;
313
+ readonly maxTokens: Schema.optional<Schema.Finite>;
314
+ readonly cacheRetention: Schema.optional<Schema.Literals<readonly ["none", "short", "long"]>>;
315
+ readonly headers: Schema.optional<Schema.$Record<Schema.String, Schema.String>>;
316
+ readonly timeoutMs: Schema.optional<Schema.Finite>;
317
+ readonly maxRetries: Schema.optional<Schema.Finite>;
318
+ readonly metadata: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
319
+ readonly thinkingBudgets: Schema.optional<Schema.$Record<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "xhigh")[]>, Schema.optional<Schema.Finite>>>;
320
+ readonly baseURL: Schema.optional<Schema.String>;
321
+ readonly method: Schema.optional<Schema.Literals<("chat" | "completion" | "completionModel" | "languageModel" | "messages" | "responses")[]>>;
322
+ readonly protocol: Schema.optional<Schema.Literals<("anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai")[]>>;
323
+ readonly thinkingLevel: Schema.optional<Schema.Literals<("high" | "low" | "max" | "medium" | "minimal" | "off" | "xhigh")[]>>;
324
+ readonly toolExecution: Schema.optional<Schema.Literals<readonly ["sequential", "parallel"]>>;
325
+ readonly contextWindow: Schema.optional<Schema.Finite>;
326
+ /** Which environment variable holds the key for this model: `"${NAME}"`. */
327
+ readonly apiKey: Schema.optional<Schema.String>;
328
+ readonly extras: Schema.optional<Schema.$Record<Schema.String, Schema.Unknown>>;
329
+ }>, readonly [Schema.$Record<Schema.String, Schema.Unknown>]>>>>;
330
+ }>>;
331
+ readonly models: Schema.optional<Schema.$Array<Schema.decodeTo<Schema.declare<{
332
+ api?: {
333
+ id?: string;
334
+ url?: string;
335
+ method?: "chat" | "completion" | "completionModel" | "languageModel" | "messages" | "responses";
336
+ };
337
+ baseUrl: string;
338
+ compat?: {
339
+ supportsThinkingLevel?: boolean;
340
+ supportsToolSearch?: boolean;
341
+ supportsAdditionalTools?: boolean;
342
+ supportsStrictMode?: boolean;
343
+ supportsOpenAIGrammarTools?: boolean;
344
+ supportsThinkingTokenBudget?: boolean;
345
+ forceAdaptiveThinking?: boolean;
346
+ thinkingTokenBudgetField?: string;
347
+ };
348
+ contextWindow: number;
349
+ cost: {
350
+ input: number;
351
+ output: number;
352
+ cacheRead: number;
353
+ cacheWrite: number;
354
+ tiers?: {
355
+ input: number;
356
+ output: number;
357
+ cacheRead: number;
358
+ cacheWrite: number;
359
+ inputTokensAbove: number;
360
+ }[];
361
+ serviceTierMultipliers?: Record<string, number>;
362
+ };
363
+ headers?: Record<string, string>;
364
+ id: string;
365
+ input: ("image" | "text")[];
366
+ maxTokens: number;
367
+ name: string;
368
+ npm?: string;
369
+ options?: Record<string, unknown>;
370
+ protocol: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
371
+ provider: {
372
+ id: string;
373
+ name: string;
374
+ source: "api" | "config" | "custom" | "env" | "unknown";
375
+ env: string[];
376
+ key?: string;
377
+ options?: Record<string, any>;
378
+ };
379
+ providerOptions?: Record<string, unknown>;
380
+ providerOptionsKey?: string;
381
+ reasoning: boolean;
382
+ supportedProtocols?: {
383
+ anthropic?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
384
+ google?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
385
+ googleVertex?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
386
+ googleVertexAnthropic?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
387
+ githubCopilot?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
388
+ openai?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
389
+ openaiCompatible?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
390
+ openaiCodex?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
391
+ openrouter?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
392
+ xai?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
393
+ };
394
+ thinkingBudgets?: {
395
+ high?: number;
396
+ low?: number;
397
+ max?: number;
398
+ medium?: number;
399
+ minimal?: number;
400
+ xhigh?: number;
401
+ };
402
+ thinkingLevelMap?: {
403
+ high?: string | null;
404
+ low?: string | null;
405
+ max?: string | null;
406
+ medium?: string | null;
407
+ minimal?: string | null;
408
+ off?: string | null;
409
+ xhigh?: string | null;
410
+ };
411
+ }, {
412
+ api?: {
413
+ id?: string;
414
+ url?: string;
415
+ method?: "chat" | "completion" | "completionModel" | "languageModel" | "messages" | "responses";
416
+ };
417
+ baseUrl: string;
418
+ compat?: {
419
+ supportsThinkingLevel?: boolean;
420
+ supportsToolSearch?: boolean;
421
+ supportsAdditionalTools?: boolean;
422
+ supportsStrictMode?: boolean;
423
+ supportsOpenAIGrammarTools?: boolean;
424
+ supportsThinkingTokenBudget?: boolean;
425
+ forceAdaptiveThinking?: boolean;
426
+ thinkingTokenBudgetField?: string;
427
+ };
428
+ contextWindow: number;
429
+ cost: {
430
+ input: number;
431
+ output: number;
432
+ cacheRead: number;
433
+ cacheWrite: number;
434
+ tiers?: {
435
+ input: number;
436
+ output: number;
437
+ cacheRead: number;
438
+ cacheWrite: number;
439
+ inputTokensAbove: number;
440
+ }[];
441
+ serviceTierMultipliers?: Record<string, number>;
442
+ };
443
+ headers?: Record<string, string>;
444
+ id: string;
445
+ input: ("image" | "text")[];
446
+ maxTokens: number;
447
+ name: string;
448
+ npm?: string;
449
+ options?: Record<string, unknown>;
450
+ protocol: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
451
+ provider: {
452
+ id: string;
453
+ name: string;
454
+ source: "api" | "config" | "custom" | "env" | "unknown";
455
+ env: string[];
456
+ key?: string;
457
+ options?: Record<string, any>;
458
+ };
459
+ providerOptions?: Record<string, unknown>;
460
+ providerOptionsKey?: string;
461
+ reasoning: boolean;
462
+ supportedProtocols?: {
463
+ anthropic?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
464
+ google?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
465
+ googleVertex?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
466
+ googleVertexAnthropic?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
467
+ githubCopilot?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
468
+ openai?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
469
+ openaiCompatible?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
470
+ openaiCodex?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
471
+ openrouter?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
472
+ xai?: "anthropic" | "github-copilot" | "google" | "google-vertex" | "google-vertex-anthropic" | "openai" | "openai-codex" | "openai-compatible" | "openrouter" | "xai";
473
+ };
474
+ thinkingBudgets?: {
475
+ high?: number;
476
+ low?: number;
477
+ max?: number;
478
+ medium?: number;
479
+ minimal?: number;
480
+ xhigh?: number;
481
+ };
482
+ thinkingLevelMap?: {
483
+ high?: string | null;
484
+ low?: string | null;
485
+ max?: string | null;
486
+ medium?: string | null;
487
+ minimal?: string | null;
488
+ off?: string | null;
489
+ xhigh?: string | null;
490
+ };
491
+ }>, Schema.Unknown, never, never>>>;
492
+ }>;
493
+ type Patch = typeof Patch.Type;
494
+ /**
495
+ * One plugin entry, and where it came from.
496
+ *
497
+ * Flattening every layer's `plugins` into one array loses the file that declared each entry, and
498
+ * that cannot be recovered afterwards: two layers may declare the same string, so attribution is
499
+ * genuinely gone rather than merely inconvenient. Three things need it -- anchoring a relative
500
+ * path, naming the declaring layer in `plugin list`, and the missing-plugin diagnostic -- so the
501
+ * loaded shape carries it from the start.
502
+ *
503
+ * In simple terms:
504
+ * `written` - is what module the developer is declaring - what
505
+ * `file` - where the module is being declared - where
506
+ * `entry` - the resolved path of the module, relative to the `file`; especially needed for local.
507
+ *
508
+ * Example:
509
+ * written: "@acme/x@^1"
510
+ * entry: "@acme/x@^1"
511
+ * file: "/Users/me/.codework/settings.jsonc"
512
+ *
513
+ * written: "./plugins/mine.mjs"
514
+ * entry: "/Users/me/.codework/plugins/mine.mjs"
515
+ * file: "/Users/me/.codework/settings.jsonc"
516
+ */
517
+ interface Declared {
518
+ /** The entry exactly as the file spells it, which is the string a person will search for. */
519
+ readonly written: PluginEntry;
520
+ /** The same entry with any relative path anchored to the directory of its declaring file. */
521
+ readonly entry: PluginEntry;
522
+ /** The settings file that declared it. */
523
+ readonly file: string;
524
+ }
525
+ /** A `models` entry, and the settings file that declared it. */
526
+ interface DeclaredModel {
527
+ readonly entry: Model.Info;
528
+ readonly file: string;
529
+ }
530
+ interface Info {
531
+ /**
532
+ * Plugin entries added to the harness selection, in order: every layer's entries, lowest
533
+ * priority first, so a project's list extends the user's rather than replacing it.
534
+ *
535
+ * Anchored, and stripped of provenance: this is the list the loader consumes. {@link Info.declared}
536
+ * is the same list with the file each entry came from.
537
+ */
538
+ readonly plugins: ReadonlyArray<PluginEntry>;
539
+ /** {@link Info.plugins}, with the origin of each entry. Same order, same length. */
540
+ readonly declared: ReadonlyArray<Declared>;
541
+ /**
542
+ * Catalog entries from every layer, lowest priority first. Applied over the generated catalog
543
+ * in this order, so for one `provider.id` + `id` the last entry wins.
544
+ */
545
+ readonly models: ReadonlyArray<DeclaredModel>;
546
+ readonly model: typeof Model$1.Type & {
547
+ readonly provider: string;
548
+ readonly id: string;
549
+ readonly thinkingLevel: Model.ThinkingLevel;
550
+ readonly toolExecution: ToolExecution;
551
+ };
552
+ }
553
+ /** Let aikit supply model-aware generation defaults. */
554
+ declare const defaults: Info;
555
+ //#endregion
556
+ export { KeyReference as a, ModelProtocol as c, PluginPatch as d, ThinkingLevel as f, requestFields as g, keyName as h, Info as i, Patch as l, defaults as m, Declared as n, Model$1 as o, ToolExecution as p, DeclaredModel as r, ModelEntry as s, Block as t, PluginEntry as u };
557
+ //# sourceMappingURL=settings-C6RxGd-M.d.mts.map
package/settings.d.mts ADDED
@@ -0,0 +1,2 @@
1
+ import { a as KeyReference, c as ModelProtocol, d as PluginPatch, f as ThinkingLevel, g as requestFields, h as keyName, i as Info, l as Patch, m as defaults, n as Declared, o as Model, p as ToolExecution, r as DeclaredModel, s as ModelEntry, t as Block, u as PluginEntry } from "./settings-C6RxGd-M.mjs";
2
+ export { Block, Declared, DeclaredModel, Info, KeyReference, Model, ModelEntry, ModelProtocol, Patch, PluginEntry, PluginPatch, ThinkingLevel, ToolExecution, defaults, keyName, requestFields };