librechat-data-provider 0.8.500 → 0.8.502

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.
@@ -38,7 +38,8 @@ export declare enum ResourceType {
38
38
  AGENT = "agent",
39
39
  PROMPTGROUP = "promptGroup",
40
40
  MCPSERVER = "mcpServer",
41
- REMOTE_AGENT = "remoteAgent"
41
+ REMOTE_AGENT = "remoteAgent",
42
+ SKILL = "skill"
42
43
  }
43
44
  /**
44
45
  * Permission bit constants for bitwise operations
@@ -68,7 +69,10 @@ export declare enum AccessRoleIds {
68
69
  MCPSERVER_OWNER = "mcpServer_owner",
69
70
  REMOTE_AGENT_VIEWER = "remoteAgent_viewer",
70
71
  REMOTE_AGENT_EDITOR = "remoteAgent_editor",
71
- REMOTE_AGENT_OWNER = "remoteAgent_owner"
72
+ REMOTE_AGENT_OWNER = "remoteAgent_owner",
73
+ SKILL_VIEWER = "skill_viewer",
74
+ SKILL_EDITOR = "skill_editor",
75
+ SKILL_OWNER = "skill_owner"
72
76
  }
73
77
  /**
74
78
  * Principal schema - represents a user, group, role, or public access
@@ -89,6 +89,7 @@ export declare const files: () => string;
89
89
  export declare const fileUpload: () => string;
90
90
  export declare const fileDelete: () => string;
91
91
  export declare const fileDownload: (userId: string, fileId: string) => string;
92
+ export declare const filePreview: (fileId: string) => string;
92
93
  export declare const fileConfig: () => string;
93
94
  export declare const agentFiles: (agentId: string) => string;
94
95
  export declare const images: () => string;
@@ -116,6 +117,22 @@ export declare const deletePrompt: ({ _id, groupId }: {
116
117
  }) => string;
117
118
  export declare const getCategories: () => string;
118
119
  export declare const getAllPromptGroups: () => string;
120
+ export declare const skills: () => string;
121
+ export declare const importSkill: () => string;
122
+ export declare const getSkill: (id: string) => string;
123
+ export declare const listSkillsWithFilters: (filter: Record<string, string | number | undefined | null>) => string;
124
+ export declare const skillFiles: (id: string) => string;
125
+ export declare const skillFile: (id: string, relativePath: string) => string;
126
+ /**
127
+ * Skill filesystem tree (phase 2). URL shape mirrors the original UI PR so
128
+ * the tree hooks keep their call surface. `path` is pre-encoded by the
129
+ * caller (e.g. `${nodeId}/content`).
130
+ */
131
+ export declare const skillTree: ({ skillId, path }: {
132
+ skillId: string;
133
+ path?: string | undefined;
134
+ }) => string;
135
+ export declare const skillStates: () => string;
119
136
  export declare const roles: () => string;
120
137
  export declare const adminRoles: () => string;
121
138
  export declare const getRole: (roleName: string) => string;
@@ -126,6 +143,7 @@ export declare const updatePeoplePickerPermissions: (roleName: string) => string
126
143
  export declare const updateMCPServersPermissions: (roleName: string) => string;
127
144
  export declare const updateRemoteAgentsPermissions: (roleName: string) => string;
128
145
  export declare const updateMarketplacePermissions: (roleName: string) => string;
146
+ export declare const updateSkillPermissions: (roleName: string) => string;
129
147
  export declare const conversationTags: (tag?: string) => string;
130
148
  export declare const conversationTagsList: (pageNumber: string, sort?: string, order?: string) => string;
131
149
  export declare const addTagToConversation: (conversationId: string) => string;
@@ -0,0 +1,3 @@
1
+ export declare const REFILL_INTERVAL_UNITS: readonly ["seconds", "minutes", "hours", "days", "weeks", "months"];
2
+ export type RefillIntervalUnit = (typeof REFILL_INTERVAL_UNITS)[number];
3
+ export declare function getRefillEligibilityDate(lastRefill: Date, value: number, unit: RefillIntervalUnit): Date;
@@ -0,0 +1 @@
1
+ export {};
@@ -1,8 +1,22 @@
1
1
  import { z } from 'zod';
2
2
  import * as s from './schemas';
3
+ export declare const BEDROCK_OUTPUT_128K_BETA = "output-128k-2025-02-19";
4
+ export declare const BEDROCK_FINE_GRAINED_TOOL_STREAMING_BETA = "fine-grained-tool-streaming-2025-05-14";
5
+ export declare function resolveThinkingDisplay(model: string, explicit?: s.ThinkingDisplay | string | null): s.ThinkingDisplayWireValue | undefined;
3
6
  /** Checks if a model supports adaptive thinking (Opus 4.6+, Sonnet 4.6+) */
4
7
  export declare function supportsAdaptiveThinking(model: string): boolean;
5
- /** Checks if a model qualifies for the context-1m beta header (Sonnet 4+, Opus 4.6+, Opus 5+) */
8
+ /**
9
+ * Checks if a model omits `thinking` content from responses by default.
10
+ *
11
+ * Starting with Claude Opus 4.7, the Messages API returns empty `thinking`
12
+ * blocks unless the request explicitly opts in via `thinking.display =
13
+ * "summarized"`. This helper narrows the opt-in to Opus 4.7+ (and any future
14
+ * major Opus version) so older adaptive-thinking models are left untouched.
15
+ *
16
+ * See https://platform.claude.com/docs/en/about-claude/models/whats-new-claude-4-7#thinking-content-omitted-by-default
17
+ */
18
+ export declare function omitsThinkingByDefault(model: string): boolean;
19
+ /** Checks if a model has a 1M context window (Sonnet 4.6+, Opus 4.6+, Opus 5+) */
6
20
  export declare function supportsContext1m(model: string): boolean;
7
21
  export declare const bedrockInputSchema: z.ZodCatch<z.ZodEffects<z.ZodObject<Pick<{
8
22
  conversationId: z.ZodNullable<z.ZodString>;
@@ -131,6 +145,7 @@ export declare const bedrockInputSchema: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
131
145
  verbosity: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.Verbosity>>>;
132
146
  useResponsesApi: z.ZodOptional<z.ZodBoolean>;
133
147
  effort: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.AnthropicEffort>>>;
148
+ thinkingDisplay: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.ThinkingDisplay>>>;
134
149
  web_search: z.ZodOptional<z.ZodBoolean>;
135
150
  disableStreaming: z.ZodOptional<z.ZodBoolean>;
136
151
  assistant_id: z.ZodOptional<z.ZodString>;
@@ -198,7 +213,8 @@ export declare const bedrockInputSchema: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
198
213
  fileTokenLimit: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodNumber, z.ZodString]>, number | undefined, string | number>>;
199
214
  resendImages: z.ZodOptional<z.ZodBoolean>;
200
215
  chatGptLabel: z.ZodOptional<z.ZodNullable<z.ZodString>>;
201
- }, "modelLabel" | "model" | "promptPrefix" | "temperature" | "topP" | "topK" | "maxOutputTokens" | "maxContextTokens" | "promptCache" | "system" | "thinking" | "thinkingBudget" | "artifacts" | "resendFiles" | "reasoning_effort" | "effort" | "region" | "maxTokens" | "additionalModelRequestFields" | "stop" | "greeting" | "spec" | "iconURL">, "strip", z.ZodTypeAny, {
216
+ }, "thinking" | "modelLabel" | "model" | "promptPrefix" | "temperature" | "topP" | "topK" | "maxOutputTokens" | "maxContextTokens" | "promptCache" | "system" | "thinkingBudget" | "artifacts" | "resendFiles" | "reasoning_effort" | "effort" | "thinkingDisplay" | "region" | "maxTokens" | "additionalModelRequestFields" | "stop" | "greeting" | "spec" | "iconURL">, "strip", z.ZodTypeAny, {
217
+ thinking?: boolean | undefined;
202
218
  modelLabel?: string | null | undefined;
203
219
  model?: string | null | undefined;
204
220
  promptPrefix?: string | null | undefined;
@@ -209,12 +225,12 @@ export declare const bedrockInputSchema: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
209
225
  maxContextTokens?: number | undefined;
210
226
  promptCache?: boolean | undefined;
211
227
  system?: string | undefined;
212
- thinking?: boolean | undefined;
213
228
  thinkingBudget?: number | undefined;
214
229
  artifacts?: string | undefined;
215
230
  resendFiles?: boolean | undefined;
216
231
  reasoning_effort?: s.ReasoningEffort | null | undefined;
217
232
  effort?: s.AnthropicEffort | null | undefined;
233
+ thinkingDisplay?: s.ThinkingDisplay | null | undefined;
218
234
  region?: string | undefined;
219
235
  maxTokens?: number | undefined;
220
236
  additionalModelRequestFields?: (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | any | {
@@ -247,6 +263,7 @@ export declare const bedrockInputSchema: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
247
263
  spec?: string | null | undefined;
248
264
  iconURL?: string | null | undefined;
249
265
  }, {
266
+ thinking?: boolean | undefined;
250
267
  modelLabel?: string | null | undefined;
251
268
  model?: string | null | undefined;
252
269
  promptPrefix?: string | null | undefined;
@@ -257,12 +274,12 @@ export declare const bedrockInputSchema: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
257
274
  maxContextTokens?: string | number | undefined;
258
275
  promptCache?: boolean | undefined;
259
276
  system?: string | undefined;
260
- thinking?: boolean | undefined;
261
277
  thinkingBudget?: string | number | undefined;
262
278
  artifacts?: string | undefined;
263
279
  resendFiles?: boolean | undefined;
264
280
  reasoning_effort?: s.ReasoningEffort | null | undefined;
265
281
  effort?: s.AnthropicEffort | null | undefined;
282
+ thinkingDisplay?: s.ThinkingDisplay | null | undefined;
266
283
  region?: string | undefined;
267
284
  maxTokens?: string | number | undefined;
268
285
  additionalModelRequestFields?: (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | any | {
@@ -295,6 +312,7 @@ export declare const bedrockInputSchema: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
295
312
  spec?: string | null | undefined;
296
313
  iconURL?: string | null | undefined;
297
314
  }>, Partial<{
315
+ thinking?: boolean | undefined;
298
316
  modelLabel?: string | null | undefined;
299
317
  model?: string | null | undefined;
300
318
  promptPrefix?: string | null | undefined;
@@ -305,12 +323,12 @@ export declare const bedrockInputSchema: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
305
323
  maxContextTokens?: number | undefined;
306
324
  promptCache?: boolean | undefined;
307
325
  system?: string | undefined;
308
- thinking?: boolean | undefined;
309
326
  thinkingBudget?: number | undefined;
310
327
  artifacts?: string | undefined;
311
328
  resendFiles?: boolean | undefined;
312
329
  reasoning_effort?: s.ReasoningEffort | null | undefined;
313
330
  effort?: s.AnthropicEffort | null | undefined;
331
+ thinkingDisplay?: s.ThinkingDisplay | null | undefined;
314
332
  region?: string | undefined;
315
333
  maxTokens?: number | undefined;
316
334
  additionalModelRequestFields?: (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | any | {
@@ -343,6 +361,7 @@ export declare const bedrockInputSchema: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
343
361
  spec?: string | null | undefined;
344
362
  iconURL?: string | null | undefined;
345
363
  }>, {
364
+ thinking?: boolean | undefined;
346
365
  modelLabel?: string | null | undefined;
347
366
  model?: string | null | undefined;
348
367
  promptPrefix?: string | null | undefined;
@@ -353,12 +372,12 @@ export declare const bedrockInputSchema: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
353
372
  maxContextTokens?: string | number | undefined;
354
373
  promptCache?: boolean | undefined;
355
374
  system?: string | undefined;
356
- thinking?: boolean | undefined;
357
375
  thinkingBudget?: string | number | undefined;
358
376
  artifacts?: string | undefined;
359
377
  resendFiles?: boolean | undefined;
360
378
  reasoning_effort?: s.ReasoningEffort | null | undefined;
361
379
  effort?: s.AnthropicEffort | null | undefined;
380
+ thinkingDisplay?: s.ThinkingDisplay | null | undefined;
362
381
  region?: string | undefined;
363
382
  maxTokens?: string | number | undefined;
364
383
  additionalModelRequestFields?: (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | any | {
@@ -519,6 +538,7 @@ export declare const bedrockInputParser: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
519
538
  verbosity: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.Verbosity>>>;
520
539
  useResponsesApi: z.ZodOptional<z.ZodBoolean>;
521
540
  effort: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.AnthropicEffort>>>;
541
+ thinkingDisplay: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.ThinkingDisplay>>>;
522
542
  web_search: z.ZodOptional<z.ZodBoolean>;
523
543
  disableStreaming: z.ZodOptional<z.ZodBoolean>;
524
544
  assistant_id: z.ZodOptional<z.ZodString>;
@@ -586,7 +606,7 @@ export declare const bedrockInputParser: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
586
606
  fileTokenLimit: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodNumber, z.ZodString]>, number | undefined, string | number>>;
587
607
  resendImages: z.ZodOptional<z.ZodBoolean>;
588
608
  chatGptLabel: z.ZodOptional<z.ZodNullable<z.ZodString>>;
589
- }, "modelLabel" | "model" | "promptPrefix" | "temperature" | "topP" | "topK" | "maxOutputTokens" | "maxContextTokens" | "promptCache" | "thinking" | "thinkingBudget" | "artifacts" | "resendFiles" | "reasoning_effort" | "effort" | "region" | "maxTokens" | "additionalModelRequestFields" | "stop" | "greeting" | "spec" | "iconURL">, "strip", z.ZodAny, z.objectOutputType<Pick<{
609
+ }, "thinking" | "modelLabel" | "model" | "promptPrefix" | "temperature" | "topP" | "topK" | "maxOutputTokens" | "maxContextTokens" | "promptCache" | "thinkingBudget" | "artifacts" | "resendFiles" | "reasoning_effort" | "effort" | "thinkingDisplay" | "region" | "maxTokens" | "additionalModelRequestFields" | "stop" | "greeting" | "spec" | "iconURL">, "strip", z.ZodAny, z.objectOutputType<Pick<{
590
610
  conversationId: z.ZodNullable<z.ZodString>;
591
611
  endpoint: z.ZodNullable<z.ZodNativeEnum<typeof s.EModelEndpoint>>;
592
612
  endpointType: z.ZodOptional<z.ZodNullable<z.ZodNativeEnum<typeof s.EModelEndpoint>>>;
@@ -713,6 +733,7 @@ export declare const bedrockInputParser: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
713
733
  verbosity: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.Verbosity>>>;
714
734
  useResponsesApi: z.ZodOptional<z.ZodBoolean>;
715
735
  effort: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.AnthropicEffort>>>;
736
+ thinkingDisplay: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.ThinkingDisplay>>>;
716
737
  web_search: z.ZodOptional<z.ZodBoolean>;
717
738
  disableStreaming: z.ZodOptional<z.ZodBoolean>;
718
739
  assistant_id: z.ZodOptional<z.ZodString>;
@@ -780,7 +801,7 @@ export declare const bedrockInputParser: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
780
801
  fileTokenLimit: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodNumber, z.ZodString]>, number | undefined, string | number>>;
781
802
  resendImages: z.ZodOptional<z.ZodBoolean>;
782
803
  chatGptLabel: z.ZodOptional<z.ZodNullable<z.ZodString>>;
783
- }, "modelLabel" | "model" | "promptPrefix" | "temperature" | "topP" | "topK" | "maxOutputTokens" | "maxContextTokens" | "promptCache" | "thinking" | "thinkingBudget" | "artifacts" | "resendFiles" | "reasoning_effort" | "effort" | "region" | "maxTokens" | "additionalModelRequestFields" | "stop" | "greeting" | "spec" | "iconURL">, z.ZodAny, "strip">, z.objectInputType<Pick<{
804
+ }, "thinking" | "modelLabel" | "model" | "promptPrefix" | "temperature" | "topP" | "topK" | "maxOutputTokens" | "maxContextTokens" | "promptCache" | "thinkingBudget" | "artifacts" | "resendFiles" | "reasoning_effort" | "effort" | "thinkingDisplay" | "region" | "maxTokens" | "additionalModelRequestFields" | "stop" | "greeting" | "spec" | "iconURL">, z.ZodAny, "strip">, z.objectInputType<Pick<{
784
805
  conversationId: z.ZodNullable<z.ZodString>;
785
806
  endpoint: z.ZodNullable<z.ZodNativeEnum<typeof s.EModelEndpoint>>;
786
807
  endpointType: z.ZodOptional<z.ZodNullable<z.ZodNativeEnum<typeof s.EModelEndpoint>>>;
@@ -907,6 +928,7 @@ export declare const bedrockInputParser: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
907
928
  verbosity: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.Verbosity>>>;
908
929
  useResponsesApi: z.ZodOptional<z.ZodBoolean>;
909
930
  effort: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.AnthropicEffort>>>;
931
+ thinkingDisplay: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.ThinkingDisplay>>>;
910
932
  web_search: z.ZodOptional<z.ZodBoolean>;
911
933
  disableStreaming: z.ZodOptional<z.ZodBoolean>;
912
934
  assistant_id: z.ZodOptional<z.ZodString>;
@@ -974,7 +996,8 @@ export declare const bedrockInputParser: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
974
996
  fileTokenLimit: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodNumber, z.ZodString]>, number | undefined, string | number>>;
975
997
  resendImages: z.ZodOptional<z.ZodBoolean>;
976
998
  chatGptLabel: z.ZodOptional<z.ZodNullable<z.ZodString>>;
977
- }, "modelLabel" | "model" | "promptPrefix" | "temperature" | "topP" | "topK" | "maxOutputTokens" | "maxContextTokens" | "promptCache" | "thinking" | "thinkingBudget" | "artifacts" | "resendFiles" | "reasoning_effort" | "effort" | "region" | "maxTokens" | "additionalModelRequestFields" | "stop" | "greeting" | "spec" | "iconURL">, z.ZodAny, "strip">>, Partial<{
999
+ }, "thinking" | "modelLabel" | "model" | "promptPrefix" | "temperature" | "topP" | "topK" | "maxOutputTokens" | "maxContextTokens" | "promptCache" | "thinkingBudget" | "artifacts" | "resendFiles" | "reasoning_effort" | "effort" | "thinkingDisplay" | "region" | "maxTokens" | "additionalModelRequestFields" | "stop" | "greeting" | "spec" | "iconURL">, z.ZodAny, "strip">>, Partial<{
1000
+ thinking?: boolean | undefined;
978
1001
  modelLabel?: string | null | undefined;
979
1002
  model?: string | null | undefined;
980
1003
  promptPrefix?: string | null | undefined;
@@ -985,12 +1008,12 @@ export declare const bedrockInputParser: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
985
1008
  maxContextTokens?: number | undefined;
986
1009
  promptCache?: boolean | undefined;
987
1010
  system?: string | undefined;
988
- thinking?: boolean | undefined;
989
1011
  thinkingBudget?: number | undefined;
990
1012
  artifacts?: string | undefined;
991
1013
  resendFiles?: boolean | undefined;
992
1014
  reasoning_effort?: s.ReasoningEffort | null | undefined;
993
1015
  effort?: s.AnthropicEffort | null | undefined;
1016
+ thinkingDisplay?: s.ThinkingDisplay | null | undefined;
994
1017
  region?: string | undefined;
995
1018
  maxTokens?: number | undefined;
996
1019
  additionalModelRequestFields?: (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | (string | number | boolean | any | {
@@ -1149,6 +1172,7 @@ export declare const bedrockInputParser: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
1149
1172
  verbosity: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.Verbosity>>>;
1150
1173
  useResponsesApi: z.ZodOptional<z.ZodBoolean>;
1151
1174
  effort: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.AnthropicEffort>>>;
1175
+ thinkingDisplay: z.ZodNullable<z.ZodOptional<z.ZodNativeEnum<typeof s.ThinkingDisplay>>>;
1152
1176
  web_search: z.ZodOptional<z.ZodBoolean>;
1153
1177
  disableStreaming: z.ZodOptional<z.ZodBoolean>;
1154
1178
  assistant_id: z.ZodOptional<z.ZodString>;
@@ -1216,5 +1240,5 @@ export declare const bedrockInputParser: z.ZodCatch<z.ZodEffects<z.ZodObject<Pic
1216
1240
  fileTokenLimit: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodNumber, z.ZodString]>, number | undefined, string | number>>;
1217
1241
  resendImages: z.ZodOptional<z.ZodBoolean>;
1218
1242
  chatGptLabel: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1219
- }, "modelLabel" | "model" | "promptPrefix" | "temperature" | "topP" | "topK" | "maxOutputTokens" | "maxContextTokens" | "promptCache" | "thinking" | "thinkingBudget" | "artifacts" | "resendFiles" | "reasoning_effort" | "effort" | "region" | "maxTokens" | "additionalModelRequestFields" | "stop" | "greeting" | "spec" | "iconURL">, z.ZodAny, "strip">>>;
1243
+ }, "thinking" | "modelLabel" | "model" | "promptPrefix" | "temperature" | "topP" | "topK" | "maxOutputTokens" | "maxContextTokens" | "promptCache" | "thinkingBudget" | "artifacts" | "resendFiles" | "reasoning_effort" | "effort" | "thinkingDisplay" | "region" | "maxTokens" | "additionalModelRequestFields" | "stop" | "greeting" | "spec" | "iconURL">, z.ZodAny, "strip">>>;
1220
1244
  export declare const bedrockOutputParser: (data: Record<string, unknown>) => Record<string, unknown>;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,62 @@
1
+ /**
2
+ * Closed set of resource kinds for sandbox file caching. Defined as a
3
+ * `as const` tuple so the runtime list and the TypeScript union can't
4
+ * drift on future additions — adding a new kind to the tuple updates
5
+ * both at once.
6
+ *
7
+ * - `skill`: shared per skill identity. Cross-user-within-tenant
8
+ * sharing. Code API sessionKey omits the user dimension.
9
+ * `version` is required (the skill's monotonic counter scopes the
10
+ * cache per revision so any edit invalidates the prior cache
11
+ * entry naturally).
12
+ * - `agent`: shared per agent identity. Same sharing semantic as
13
+ * skills (agents are addressable resources accessible to a
14
+ * permission-defined audience).
15
+ * - `user`: user-private. Code API sessionKey is keyed by the
16
+ * requesting user from auth context. Used for chat attachments
17
+ * and code-output artifacts.
18
+ */
19
+ export declare const CODE_ENV_KINDS: readonly ["skill", "agent", "user"];
20
+ export type CodeEnvKind = (typeof CODE_ENV_KINDS)[number];
21
+ /**
22
+ * Typed reference to a file in the code-execution sandbox.
23
+ *
24
+ * `storage_session_id` is intentionally distinct from the *execution*
25
+ * session id at the top level of an execute response — they are
26
+ * different concepts that historically shared the field name
27
+ * `session_id`. This is the long-lived storage session keyed by the
28
+ * resource's identity (skill/agent/user), not the transient
29
+ * sandbox-run session.
30
+ *
31
+ * `kind` and `id` together name the resource that owns this file's
32
+ * storage session. Code API uses them (plus the auth-context tenant
33
+ * id) to derive the sessionKey, which determines who shares the
34
+ * cache. Cross-user sharing for shared resources (skills, agents) is
35
+ * a designed property of the kind switch, not an emergent side
36
+ * effect. See codeapi #1455 / agents #148 / LC #12960.
37
+ *
38
+ * `version` is statically required when `kind === 'skill'` and
39
+ * statically forbidden otherwise via the discriminated union below —
40
+ * the constraint is enforced at compile time, not just by codeapi's
41
+ * runtime validator.
42
+ */
43
+ interface CodeEnvRefBase {
44
+ /** Resource identity. Semantics depend on `kind`:
45
+ * - `skill`: skill `_id` (sessionKey-meaningful, cross-user shared).
46
+ * - `agent`: agent id (sessionKey-meaningful, cross-user shared).
47
+ * - `user`: informational only — sessionKey derivation uses the
48
+ * requesting user from auth context. Kept on the type for shape
49
+ * uniformity across kinds; do not rely on it for routing. */
50
+ id: string;
51
+ storage_session_id: string;
52
+ file_id: string;
53
+ }
54
+ export type CodeEnvRef = (CodeEnvRefBase & {
55
+ kind: 'skill';
56
+ version: number;
57
+ }) | (CodeEnvRefBase & {
58
+ kind: 'agent';
59
+ }) | (CodeEnvRefBase & {
60
+ kind: 'user';
61
+ });
62
+ export {};
@@ -0,0 +1 @@
1
+ export {};