librechat-data-provider 0.8.521 → 0.8.523

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 (64) hide show
  1. package/dist/{data-service-pwrlWjJs.mjs → data-service-Bx6IFaSa.mjs} +1770 -51
  2. package/dist/data-service-Bx6IFaSa.mjs.map +1 -0
  3. package/dist/{data-service-DOIF4BkW.js → data-service-CTX0tVO5.js} +2509 -112
  4. package/dist/data-service-CTX0tVO5.js.map +1 -0
  5. package/dist/index.js +1503 -54
  6. package/dist/index.js.map +1 -1
  7. package/dist/index.mjs +1314 -55
  8. package/dist/index.mjs.map +1 -1
  9. package/dist/react-query/index.js +2 -1
  10. package/dist/react-query/index.js.map +1 -1
  11. package/dist/react-query/index.mjs +2 -1
  12. package/dist/react-query/index.mjs.map +1 -1
  13. package/dist/types/accessPermissions.d.ts +58 -1
  14. package/dist/types/actions.d.ts +2 -2
  15. package/dist/types/agentToolOptions.d.ts +11 -0
  16. package/dist/types/api-endpoints.d.ts +24 -0
  17. package/dist/types/bedrock.d.ts +238 -10
  18. package/dist/types/cadence.d.ts +33 -0
  19. package/dist/types/code/approval.d.ts +26 -0
  20. package/dist/types/code/worker.d.ts +10 -0
  21. package/dist/types/code/workspace.d.ts +28 -0
  22. package/dist/types/codeEnvRef.d.ts +26 -0
  23. package/dist/types/config.d.ts +13180 -3021
  24. package/dist/types/data-service.d.ts +48 -2
  25. package/dist/types/errors.d.ts +2 -0
  26. package/dist/types/file-config.d.ts +138 -9
  27. package/dist/types/filters.d.ts +1422 -0
  28. package/dist/types/generate.d.ts +103 -1
  29. package/dist/types/index.d.ts +17 -0
  30. package/dist/types/keys.d.ts +33 -2
  31. package/dist/types/langchain.d.ts +4 -0
  32. package/dist/types/limits.d.ts +13 -0
  33. package/dist/types/mcp.d.ts +555 -460
  34. package/dist/types/messages.d.ts +24 -0
  35. package/dist/types/models.d.ts +1112 -319
  36. package/dist/types/parameterSettings.d.ts +13 -1
  37. package/dist/types/parsers.d.ts +10 -0
  38. package/dist/types/permissions.d.ts +42 -1
  39. package/dist/types/providers.d.ts +37 -0
  40. package/dist/types/request.d.ts +2 -2
  41. package/dist/types/resolve-llm-delivery-path.d.ts +68 -0
  42. package/dist/types/roles.d.ts +34 -0
  43. package/dist/types/runSteps.d.ts +59 -0
  44. package/dist/types/schemas.d.ts +1724 -248
  45. package/dist/types/stateful-code.d.ts +7 -0
  46. package/dist/types/svg.d.ts +34 -0
  47. package/dist/types/types/agents.d.ts +116 -7
  48. package/dist/types/types/assistants.d.ts +121 -6
  49. package/dist/types/types/files.d.ts +46 -2
  50. package/dist/types/types/index.d.ts +2 -0
  51. package/dist/types/types/insights.d.ts +71 -0
  52. package/dist/types/types/mutations.d.ts +1 -0
  53. package/dist/types/types/queries.d.ts +37 -2
  54. package/dist/types/types/queuedTurns.d.ts +870 -0
  55. package/dist/types/types/runs.d.ts +119 -9
  56. package/dist/types/types/schedules.d.ts +339 -0
  57. package/dist/types/types/skills.d.ts +9 -0
  58. package/dist/types/types/subagents.d.ts +159 -0
  59. package/dist/types/types/traces.d.ts +85 -0
  60. package/dist/types/types/web.d.ts +12 -2
  61. package/dist/types/types.d.ts +101 -1
  62. package/package.json +5 -3
  63. package/dist/data-service-DOIF4BkW.js.map +0 -1
  64. package/dist/data-service-pwrlWjJs.mjs.map +0 -1
@@ -1,6 +1,6 @@
1
1
  import { z } from 'zod';
2
- import { googleSettings as google } from './schemas';
3
2
  import type { TConversation, TSetOption, TPreset } from './schemas';
3
+ import { googleSettings as google } from './schemas';
4
4
  export type GoogleSettings = Partial<typeof google>;
5
5
  export type OpenAISettings = Partial<typeof google>;
6
6
  export type ComponentType = 'input' | 'textarea' | 'slider' | 'checkbox' | 'switch' | 'dropdown' | 'combobox' | 'tags';
@@ -78,7 +78,21 @@ export interface SettingRange {
78
78
  min: number;
79
79
  max: number;
80
80
  step?: number;
81
+ /**
82
+ * Inclusive floor for non-negative values. Use when `min` is a sentinel
83
+ * (Google thinkingBudget `-1` for auto) and positive values have a higher
84
+ * documented minimum.
85
+ */
86
+ positiveMin?: number;
87
+ /**
88
+ * Set when this range came from the selected model rather than the shared
89
+ * fallback. Only then is it safe to normalize a stored value against it: a
90
+ * model that does not use the parameter leaves the generic range in place,
91
+ * and clamping to that would discard a value set for another model.
92
+ */
93
+ modelSpecific?: boolean;
81
94
  }
95
+ export declare function clampSettingRange(value: number, range: SettingRange): number;
82
96
  export type SettingsConfiguration = SettingDefinition[];
83
97
  export declare function generateDynamicSchema(settings: SettingsConfiguration): z.ZodObject<{
84
98
  [key: string]: z.ZodTypeAny;
@@ -97,8 +111,21 @@ export declare const generateOpenAISchema: (customOpenAI: OpenAISettings) => z.Z
97
111
  endpoint: z.ZodNullable<z.ZodNativeEnum<typeof import("./schemas").EModelEndpoint>>;
98
112
  endpointType: z.ZodOptional<z.ZodNullable<z.ZodNativeEnum<typeof import("./schemas").EModelEndpoint>>>;
99
113
  isArchived: z.ZodOptional<z.ZodBoolean>;
114
+ archivedAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
100
115
  pinned: z.ZodOptional<z.ZodBoolean>;
101
116
  isShared: z.ZodOptional<z.ZodBoolean>;
117
+ codeApprovalMode: z.ZodOptional<z.ZodEnum<["ask", "acceptEdits", "fullAccess"]>>;
118
+ codeEnvironmentMode: z.ZodOptional<z.ZodEnum<["attached", "without_attached"]>>;
119
+ codeWorkspaces: z.ZodOptional<z.ZodArray<z.ZodObject<{
120
+ environmentId: z.ZodString;
121
+ workspaceId: z.ZodString;
122
+ }, "strict", z.ZodTypeAny, {
123
+ environmentId: string;
124
+ workspaceId: string;
125
+ }, {
126
+ environmentId: string;
127
+ workspaceId: string;
128
+ }>, "many">>;
102
129
  title: z.ZodDefault<z.ZodUnion<[z.ZodNullable<z.ZodString>, z.ZodLiteral<"New Chat">]>>;
103
130
  user: z.ZodOptional<z.ZodString>;
104
131
  messages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
@@ -130,6 +157,7 @@ export declare const generateOpenAISchema: (customOpenAI: OpenAISettings) => z.Z
130
157
  chatMenu: z.ZodOptional<z.ZodBoolean>;
131
158
  isButton: z.ZodOptional<z.ZodBoolean>;
132
159
  toolkit: z.ZodOptional<z.ZodBoolean>;
160
+ serverToolName: z.ZodOptional<z.ZodString>;
133
161
  }, "strip", z.ZodTypeAny, {
134
162
  name: string;
135
163
  pluginKey: string;
@@ -146,6 +174,7 @@ export declare const generateOpenAISchema: (customOpenAI: OpenAISettings) => z.Z
146
174
  chatMenu?: boolean | undefined;
147
175
  isButton?: boolean | undefined;
148
176
  toolkit?: boolean | undefined;
177
+ serverToolName?: string | undefined;
149
178
  }, {
150
179
  name: string;
151
180
  pluginKey: string;
@@ -162,6 +191,7 @@ export declare const generateOpenAISchema: (customOpenAI: OpenAISettings) => z.Z
162
191
  chatMenu?: boolean | undefined;
163
192
  isButton?: boolean | undefined;
164
193
  toolkit?: boolean | undefined;
194
+ serverToolName?: string | undefined;
165
195
  }>, "many">, z.ZodArray<z.ZodString, "many">]>>;
166
196
  modelLabel: z.ZodOptional<z.ZodNullable<z.ZodString>>;
167
197
  userLabel: z.ZodOptional<z.ZodString>;
@@ -236,6 +266,34 @@ export declare const generateOpenAISchema: (customOpenAI: OpenAISettings) => z.Z
236
266
  disableStreaming: z.ZodOptional<z.ZodBoolean>;
237
267
  assistant_id: z.ZodOptional<z.ZodString>;
238
268
  agent_id: z.ZodOptional<z.ZodString>;
269
+ subagentThread: z.ZodOptional<z.ZodObject<{
270
+ rootConversationId: z.ZodString;
271
+ parentConversationId: z.ZodString;
272
+ parentMessageId: z.ZodString;
273
+ parentToolCallId: z.ZodString;
274
+ parentAgentId: z.ZodOptional<z.ZodString>;
275
+ subagentType: z.ZodString;
276
+ subagentKind: z.ZodEnum<["agent", "graph"]>;
277
+ depth: z.ZodNumber;
278
+ }, "strip", z.ZodTypeAny, {
279
+ subagentKind: "agent" | "graph";
280
+ parentMessageId: string;
281
+ rootConversationId: string;
282
+ parentConversationId: string;
283
+ parentToolCallId: string;
284
+ subagentType: string;
285
+ depth: number;
286
+ parentAgentId?: string | undefined;
287
+ }, {
288
+ subagentKind: "agent" | "graph";
289
+ parentMessageId: string;
290
+ rootConversationId: string;
291
+ parentConversationId: string;
292
+ parentToolCallId: string;
293
+ subagentType: string;
294
+ depth: number;
295
+ parentAgentId?: string | undefined;
296
+ }>>;
239
297
  region: z.ZodOptional<z.ZodString>;
240
298
  maxTokens: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodNumber, z.ZodString]>, number | undefined, string | number>>;
241
299
  additionalModelRequestFields: z.ZodOptional<z.ZodType<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 | /*elided*/ any | {
@@ -350,8 +408,21 @@ export declare const generateGoogleSchema: (customGoogle: GoogleSettings) => z.Z
350
408
  endpoint: z.ZodNullable<z.ZodNativeEnum<typeof import("./schemas").EModelEndpoint>>;
351
409
  endpointType: z.ZodOptional<z.ZodNullable<z.ZodNativeEnum<typeof import("./schemas").EModelEndpoint>>>;
352
410
  isArchived: z.ZodOptional<z.ZodBoolean>;
411
+ archivedAt: z.ZodOptional<z.ZodNullable<z.ZodString>>;
353
412
  pinned: z.ZodOptional<z.ZodBoolean>;
354
413
  isShared: z.ZodOptional<z.ZodBoolean>;
414
+ codeApprovalMode: z.ZodOptional<z.ZodEnum<["ask", "acceptEdits", "fullAccess"]>>;
415
+ codeEnvironmentMode: z.ZodOptional<z.ZodEnum<["attached", "without_attached"]>>;
416
+ codeWorkspaces: z.ZodOptional<z.ZodArray<z.ZodObject<{
417
+ environmentId: z.ZodString;
418
+ workspaceId: z.ZodString;
419
+ }, "strict", z.ZodTypeAny, {
420
+ environmentId: string;
421
+ workspaceId: string;
422
+ }, {
423
+ environmentId: string;
424
+ workspaceId: string;
425
+ }>, "many">>;
355
426
  title: z.ZodDefault<z.ZodUnion<[z.ZodNullable<z.ZodString>, z.ZodLiteral<"New Chat">]>>;
356
427
  user: z.ZodOptional<z.ZodString>;
357
428
  messages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
@@ -383,6 +454,7 @@ export declare const generateGoogleSchema: (customGoogle: GoogleSettings) => z.Z
383
454
  chatMenu: z.ZodOptional<z.ZodBoolean>;
384
455
  isButton: z.ZodOptional<z.ZodBoolean>;
385
456
  toolkit: z.ZodOptional<z.ZodBoolean>;
457
+ serverToolName: z.ZodOptional<z.ZodString>;
386
458
  }, "strip", z.ZodTypeAny, {
387
459
  name: string;
388
460
  pluginKey: string;
@@ -399,6 +471,7 @@ export declare const generateGoogleSchema: (customGoogle: GoogleSettings) => z.Z
399
471
  chatMenu?: boolean | undefined;
400
472
  isButton?: boolean | undefined;
401
473
  toolkit?: boolean | undefined;
474
+ serverToolName?: string | undefined;
402
475
  }, {
403
476
  name: string;
404
477
  pluginKey: string;
@@ -415,6 +488,7 @@ export declare const generateGoogleSchema: (customGoogle: GoogleSettings) => z.Z
415
488
  chatMenu?: boolean | undefined;
416
489
  isButton?: boolean | undefined;
417
490
  toolkit?: boolean | undefined;
491
+ serverToolName?: string | undefined;
418
492
  }>, "many">, z.ZodArray<z.ZodString, "many">]>>;
419
493
  modelLabel: z.ZodOptional<z.ZodNullable<z.ZodString>>;
420
494
  userLabel: z.ZodOptional<z.ZodString>;
@@ -489,6 +563,34 @@ export declare const generateGoogleSchema: (customGoogle: GoogleSettings) => z.Z
489
563
  disableStreaming: z.ZodOptional<z.ZodBoolean>;
490
564
  assistant_id: z.ZodOptional<z.ZodString>;
491
565
  agent_id: z.ZodOptional<z.ZodString>;
566
+ subagentThread: z.ZodOptional<z.ZodObject<{
567
+ rootConversationId: z.ZodString;
568
+ parentConversationId: z.ZodString;
569
+ parentMessageId: z.ZodString;
570
+ parentToolCallId: z.ZodString;
571
+ parentAgentId: z.ZodOptional<z.ZodString>;
572
+ subagentType: z.ZodString;
573
+ subagentKind: z.ZodEnum<["agent", "graph"]>;
574
+ depth: z.ZodNumber;
575
+ }, "strip", z.ZodTypeAny, {
576
+ subagentKind: "agent" | "graph";
577
+ parentMessageId: string;
578
+ rootConversationId: string;
579
+ parentConversationId: string;
580
+ parentToolCallId: string;
581
+ subagentType: string;
582
+ depth: number;
583
+ parentAgentId?: string | undefined;
584
+ }, {
585
+ subagentKind: "agent" | "graph";
586
+ parentMessageId: string;
587
+ rootConversationId: string;
588
+ parentConversationId: string;
589
+ parentToolCallId: string;
590
+ subagentType: string;
591
+ depth: number;
592
+ parentAgentId?: string | undefined;
593
+ }>>;
492
594
  region: z.ZodOptional<z.ZodString>;
493
595
  maxTokens: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodNumber, z.ZodString]>, number | undefined, string | number>>;
494
596
  additionalModelRequestFields: z.ZodOptional<z.ZodType<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 | /*elided*/ any | {
@@ -2,8 +2,13 @@ export * from './azure';
2
2
  export * from './bedrock';
3
3
  export * from './balance';
4
4
  export * from './config';
5
+ export * from './langchain';
6
+ export * from './filters';
5
7
  export * from './file-config';
8
+ export * from './resolve-llm-delivery-path';
6
9
  export * from './messages';
10
+ export * from './errors';
11
+ export * from './runSteps';
7
12
  export * from './artifacts';
8
13
  export * from './parsers';
9
14
  export * from './generate';
@@ -18,10 +23,16 @@ export * from './types/files';
18
23
  export * from './types/mcpServers';
19
24
  export * from './types/mutations';
20
25
  export * from './types/queries';
26
+ export * from './types/schedules';
27
+ export * from './cadence';
21
28
  export * from './types/skills';
22
29
  export * from './types/runs';
23
30
  export * from './types/web';
24
31
  export * from './types/graph';
32
+ export * from './types/insights';
33
+ export * from './types/traces';
34
+ export * from './types/subagents';
35
+ export * from './types/queuedTurns';
25
36
  export * from './accessPermissions';
26
37
  export * from './keys';
27
38
  export * from './headers-helpers';
@@ -29,9 +40,15 @@ export { loginPage, registerPage, apiBaseUrl, sharedFileDownload, buildLoginRedi
29
40
  export { default as request } from './request';
30
41
  export { dataService };
31
42
  import * as dataService from './data-service';
43
+ export * from './providers';
44
+ export * from './svg';
32
45
  export * from './utils';
33
46
  export * from './actions';
34
47
  export { default as createPayload } from './createPayload';
35
48
  export * from './feedback';
36
49
  export * from './parameterSettings';
50
+ export * from './agentToolOptions';
37
51
  export * from './codeEnvRef';
52
+ export * from './code/worker';
53
+ export * from './code/approval';
54
+ export * from './code/workspace';
@@ -5,11 +5,15 @@ export declare enum QueryKeys {
5
5
  sharedLinks = "sharedLinks",
6
6
  allConversations = "allConversations",
7
7
  archivedConversations = "archivedConversations",
8
+ pinnedConversations = "pinnedConversations",
8
9
  searchConversations = "searchConversations",
9
10
  conversation = "conversation",
10
11
  searchEnabled = "searchEnabled",
11
12
  langfuseConnection = "langfuseConnection",
12
13
  langfuseSessionLink = "langfuseSessionLink",
14
+ conversationTraceAvailability = "conversationTraceAvailability",
15
+ conversationTraceRecords = "conversationTraceRecords",
16
+ conversationTraceRecord = "conversationTraceRecord",
13
17
  user = "user",
14
18
  name = "name",// user key name
15
19
  models = "models",
@@ -21,6 +25,8 @@ export declare enum QueryKeys {
21
25
  tokenCount = "tokenCount",
22
26
  availablePlugins = "availablePlugins",
23
27
  startupConfig = "startupConfig",
28
+ insights = "insights",
29
+ insightsAccess = "insightsAccess",
24
30
  assistants = "assistants",
25
31
  assistant = "assistant",
26
32
  agents = "agents",
@@ -77,12 +83,28 @@ export declare enum QueryKeys {
77
83
  skillNodeContent = "skillNodeContent",
78
84
  toolFavorites = "toolFavorites",
79
85
  skillStates = "skillStates",
80
- favorites = "favorites"
86
+ favorites = "favorites",
87
+ schedules = "schedules",
88
+ schedule = "schedule",
89
+ parentSubagents = "parentSubagents",
90
+ subagentThread = "subagentThread",
91
+ codeEnvironments = "codeEnvironments",
92
+ agentQueuedTurns = "agentQueuedTurns",
93
+ pinnedOrder = "pinnedOrder"
81
94
  }
82
95
  export declare const DynamicQueryKeys: {
83
96
  readonly agentFiles: (agentId: string) => readonly ["agentFiles", string];
97
+ readonly codeEnvironmentStatus: (id: string) => readonly [QueryKeys.codeEnvironments, string, "status"];
84
98
  };
85
99
  export declare enum MutationKeys {
100
+ subagentControl = "subagentControl",
101
+ enqueueAgentQueuedTurn = "enqueueAgentQueuedTurn",
102
+ cancelAgentQueuedTurn = "cancelAgentQueuedTurn",
103
+ /** Whole-array favorites write, keyed so every hook instance's write is
104
+ * visible to the others through the query client. */
105
+ updateFavorites = "updateFavorites",
106
+ /** Pinned-section display order write, keyed for the same reason. */
107
+ updatePinnedOrder = "updatePinnedOrder",
86
108
  updateLangfuseConnection = "updateLangfuseConnection",
87
109
  testLangfuseConnection = "testLangfuseConnection",
88
110
  createAgentApiKey = "createAgentApiKey",
@@ -106,6 +128,7 @@ export declare enum MutationKeys {
106
128
  deleteAgentAction = "deleteAgentAction",
107
129
  revertAgentVersion = "revertAgentVersion",
108
130
  deleteUser = "deleteUser",
131
+ updateUserPreferences = "updateUserPreferences",
109
132
  updateRole = "updateRole",
110
133
  enableTwoFactor = "enableTwoFactor",
111
134
  verifyTwoFactor = "verifyTwoFactor",
@@ -118,5 +141,13 @@ export declare enum MutationKeys {
118
141
  updateSkillNode = "updateSkillNode",
119
142
  deleteSkillNode = "deleteSkillNode",
120
143
  updateSkillNodeContent = "updateSkillNodeContent",
121
- convoPin = "convoPin"
144
+ convoPin = "convoPin",
145
+ archiveAllConversations = "archiveAllConversations",
146
+ createSchedule = "createSchedule",
147
+ updateSchedule = "updateSchedule",
148
+ deleteSchedule = "deleteSchedule",
149
+ runSchedule = "runSchedule",
150
+ pairCodeEnvironment = "pairCodeEnvironment",
151
+ updateCodeEnvironmentSettings = "updateCodeEnvironmentSettings",
152
+ deleteCodeEnvironment = "deleteCodeEnvironment"
122
153
  }
@@ -0,0 +1,4 @@
1
+ /** Removes LangChain's appended docs URL so provider text carries no third-party attribution. */
2
+ export declare function stripLangChainTroubleshootingUrl(message: unknown): string;
3
+ /** The classification LangChain encoded in the docs URL it appended, when the text carries one. */
4
+ export declare function parseLangChainErrorCode(message: unknown): string | undefined;
@@ -1,2 +1,15 @@
1
1
  /** Maximum number of explicit subagents per parent agent. UI + Zod schema share this. */
2
2
  export declare const MAX_SUBAGENTS = 10;
3
+ /** Hard upper bound for `endpoints.agents.maxSubagents`, keeping the request-validation
4
+ * cap bounded no matter what the config file says. */
5
+ export declare const MAX_SUBAGENTS_CEILING = 50;
6
+ /** Effective subagents-per-agent cap; initialized from `endpoints.agents.maxSubagents` at startup. */
7
+ export declare const getMaxSubagents: () => number;
8
+ /** Applies a configured cap; any missing or out-of-range value resets to the default. */
9
+ export declare const setMaxSubagents: (value: number | undefined) => void;
10
+ /** Chat project field limits. The dialogs and the persistence layer share these,
11
+ * so the inputs stop at the same point the server would otherwise truncate. */
12
+ export declare const MAX_CHAT_PROJECT_NAME_LENGTH = 100;
13
+ export declare const MAX_CHAT_PROJECT_DESCRIPTION_LENGTH = 1000;
14
+ /** Mirrors the bounded graph-child member limit in `@librechat/agents`. */
15
+ export declare const MAX_GRAPH_SUBAGENT_MEMBERS = 32;