@dremio/js-sdk 0.36.1 → 0.36.2
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/cloud/Dremio.d.ts +1 -1
- package/dist/cloud/Dremio.js +1 -1
- package/dist/cloud/Dremio.js.map +1 -1
- package/dist/cloud/ai/AIResource.d.ts +120 -5
- package/dist/cloud/ai/AIResource.js +12 -13
- package/dist/cloud/ai/AIResource.js.map +1 -1
- package/dist/cloud/ai/DremioModelProvider.d.ts +4 -3
- package/dist/cloud/ai/DremioModelProvider.js +10 -1
- package/dist/cloud/ai/DremioModelProvider.js.map +1 -1
- package/dist/cloud/ai/modelProviderCodec.d.ts +11 -64
- package/dist/cloud/ai/modelProviderCodec.js +3 -0
- package/dist/cloud/ai/modelProviderCodec.js.map +1 -1
- package/dist/enterprise/ai/AIResource.d.ts +4 -3
- package/dist/enterprise/ai/AIResource.js +18 -11
- package/dist/enterprise/ai/AIResource.js.map +1 -1
- package/dist/enterprise/ai/ModelProvider.d.ts +2 -64
- package/dist/enterprise/ai/modelProviderCodec.d.ts +6 -192
- package/dist/enterprise/ai/modelProviderConfigSchemas.d.ts +42 -193
- package/dist/enterprise/ai/modelProviderConfigSchemas.js +10 -33
- package/dist/enterprise/ai/modelProviderConfigSchemas.js.map +1 -1
- package/package.json +1 -1
|
@@ -2,38 +2,7 @@ import * as z from "zod/mini";
|
|
|
2
2
|
/**
|
|
3
3
|
* Amazon Bedrock
|
|
4
4
|
*/
|
|
5
|
-
export declare const amazonBedrockRegionSchema: z.
|
|
6
|
-
"ap-east-2": "ap-east-2";
|
|
7
|
-
"ap-northeast-1": "ap-northeast-1";
|
|
8
|
-
"ap-northeast-2": "ap-northeast-2";
|
|
9
|
-
"ap-northeast-3": "ap-northeast-3";
|
|
10
|
-
"ap-south-1": "ap-south-1";
|
|
11
|
-
"ap-south-2": "ap-south-2";
|
|
12
|
-
"ap-southeast-1": "ap-southeast-1";
|
|
13
|
-
"ap-southeast-2": "ap-southeast-2";
|
|
14
|
-
"ap-southeast-3": "ap-southeast-3";
|
|
15
|
-
"ap-southeast-4": "ap-southeast-4";
|
|
16
|
-
"ap-southeast-5": "ap-southeast-5";
|
|
17
|
-
"ap-southeast-7": "ap-southeast-7";
|
|
18
|
-
"ca-central-1": "ca-central-1";
|
|
19
|
-
"eu-central-1": "eu-central-1";
|
|
20
|
-
"eu-central-2": "eu-central-2";
|
|
21
|
-
"eu-north-1": "eu-north-1";
|
|
22
|
-
"eu-south-1": "eu-south-1";
|
|
23
|
-
"eu-south-2": "eu-south-2";
|
|
24
|
-
"eu-west-1": "eu-west-1";
|
|
25
|
-
"eu-west-2": "eu-west-2";
|
|
26
|
-
"eu-west-3": "eu-west-3";
|
|
27
|
-
"il-central-1": "il-central-1";
|
|
28
|
-
"me-central-1": "me-central-1";
|
|
29
|
-
"sa-east-1": "sa-east-1";
|
|
30
|
-
"us-east-1": "us-east-1";
|
|
31
|
-
"us-east-2": "us-east-2";
|
|
32
|
-
"us-gov-east-1": "us-gov-east-1";
|
|
33
|
-
"us-gov-west-1": "us-gov-west-1";
|
|
34
|
-
"us-west-1": "us-west-1";
|
|
35
|
-
"us-west-2": "us-west-2";
|
|
36
|
-
}>;
|
|
5
|
+
export declare const amazonBedrockRegionSchema: z.ZodMiniString<string>;
|
|
37
6
|
export declare const amazonBedrockModelProviderConfigSchema: z.ZodMiniObject<{
|
|
38
7
|
auth: z.ZodMiniUnion<readonly [z.ZodMiniObject<{
|
|
39
8
|
accessKey: z.ZodMiniObject<{
|
|
@@ -45,38 +14,7 @@ export declare const amazonBedrockModelProviderConfigSchema: z.ZodMiniObject<{
|
|
|
45
14
|
roleArn: z.ZodMiniString<string>;
|
|
46
15
|
}, z.core.$strict>;
|
|
47
16
|
}, z.core.$strict>]>;
|
|
48
|
-
region: z.
|
|
49
|
-
"ap-east-2": "ap-east-2";
|
|
50
|
-
"ap-northeast-1": "ap-northeast-1";
|
|
51
|
-
"ap-northeast-2": "ap-northeast-2";
|
|
52
|
-
"ap-northeast-3": "ap-northeast-3";
|
|
53
|
-
"ap-south-1": "ap-south-1";
|
|
54
|
-
"ap-south-2": "ap-south-2";
|
|
55
|
-
"ap-southeast-1": "ap-southeast-1";
|
|
56
|
-
"ap-southeast-2": "ap-southeast-2";
|
|
57
|
-
"ap-southeast-3": "ap-southeast-3";
|
|
58
|
-
"ap-southeast-4": "ap-southeast-4";
|
|
59
|
-
"ap-southeast-5": "ap-southeast-5";
|
|
60
|
-
"ap-southeast-7": "ap-southeast-7";
|
|
61
|
-
"ca-central-1": "ca-central-1";
|
|
62
|
-
"eu-central-1": "eu-central-1";
|
|
63
|
-
"eu-central-2": "eu-central-2";
|
|
64
|
-
"eu-north-1": "eu-north-1";
|
|
65
|
-
"eu-south-1": "eu-south-1";
|
|
66
|
-
"eu-south-2": "eu-south-2";
|
|
67
|
-
"eu-west-1": "eu-west-1";
|
|
68
|
-
"eu-west-2": "eu-west-2";
|
|
69
|
-
"eu-west-3": "eu-west-3";
|
|
70
|
-
"il-central-1": "il-central-1";
|
|
71
|
-
"me-central-1": "me-central-1";
|
|
72
|
-
"sa-east-1": "sa-east-1";
|
|
73
|
-
"us-east-1": "us-east-1";
|
|
74
|
-
"us-east-2": "us-east-2";
|
|
75
|
-
"us-gov-east-1": "us-gov-east-1";
|
|
76
|
-
"us-gov-west-1": "us-gov-west-1";
|
|
77
|
-
"us-west-1": "us-west-1";
|
|
78
|
-
"us-west-2": "us-west-2";
|
|
79
|
-
}>;
|
|
17
|
+
region: z.ZodMiniString<string>;
|
|
80
18
|
}, z.core.$strict>;
|
|
81
19
|
export declare const amazonBedrockModelProviderConfigRetrieveSchema: z.ZodMiniObject<{
|
|
82
20
|
auth: z.ZodMiniUnion<readonly [z.ZodMiniObject<{
|
|
@@ -88,38 +26,7 @@ export declare const amazonBedrockModelProviderConfigRetrieveSchema: z.ZodMiniOb
|
|
|
88
26
|
roleArn: z.ZodMiniString<string>;
|
|
89
27
|
}, z.core.$strict>;
|
|
90
28
|
}, z.core.$strict>]>;
|
|
91
|
-
region: z.
|
|
92
|
-
"ap-east-2": "ap-east-2";
|
|
93
|
-
"ap-northeast-1": "ap-northeast-1";
|
|
94
|
-
"ap-northeast-2": "ap-northeast-2";
|
|
95
|
-
"ap-northeast-3": "ap-northeast-3";
|
|
96
|
-
"ap-south-1": "ap-south-1";
|
|
97
|
-
"ap-south-2": "ap-south-2";
|
|
98
|
-
"ap-southeast-1": "ap-southeast-1";
|
|
99
|
-
"ap-southeast-2": "ap-southeast-2";
|
|
100
|
-
"ap-southeast-3": "ap-southeast-3";
|
|
101
|
-
"ap-southeast-4": "ap-southeast-4";
|
|
102
|
-
"ap-southeast-5": "ap-southeast-5";
|
|
103
|
-
"ap-southeast-7": "ap-southeast-7";
|
|
104
|
-
"ca-central-1": "ca-central-1";
|
|
105
|
-
"eu-central-1": "eu-central-1";
|
|
106
|
-
"eu-central-2": "eu-central-2";
|
|
107
|
-
"eu-north-1": "eu-north-1";
|
|
108
|
-
"eu-south-1": "eu-south-1";
|
|
109
|
-
"eu-south-2": "eu-south-2";
|
|
110
|
-
"eu-west-1": "eu-west-1";
|
|
111
|
-
"eu-west-2": "eu-west-2";
|
|
112
|
-
"eu-west-3": "eu-west-3";
|
|
113
|
-
"il-central-1": "il-central-1";
|
|
114
|
-
"me-central-1": "me-central-1";
|
|
115
|
-
"sa-east-1": "sa-east-1";
|
|
116
|
-
"us-east-1": "us-east-1";
|
|
117
|
-
"us-east-2": "us-east-2";
|
|
118
|
-
"us-gov-east-1": "us-gov-east-1";
|
|
119
|
-
"us-gov-west-1": "us-gov-west-1";
|
|
120
|
-
"us-west-1": "us-west-1";
|
|
121
|
-
"us-west-2": "us-west-2";
|
|
122
|
-
}>;
|
|
29
|
+
region: z.ZodMiniString<string>;
|
|
123
30
|
}, z.core.$strict>;
|
|
124
31
|
export declare const amazonBedrockModelProviderConfigUpdateSchema: z.ZodMiniObject<{
|
|
125
32
|
auth: z.ZodMiniOptional<z.ZodMiniUnion<readonly [z.ZodMiniObject<{
|
|
@@ -132,38 +39,7 @@ export declare const amazonBedrockModelProviderConfigUpdateSchema: z.ZodMiniObje
|
|
|
132
39
|
roleArn: z.ZodMiniString<string>;
|
|
133
40
|
}, z.core.$strict>;
|
|
134
41
|
}, z.core.$strict>]>>;
|
|
135
|
-
region: z.ZodMiniOptional<z.
|
|
136
|
-
"ap-east-2": "ap-east-2";
|
|
137
|
-
"ap-northeast-1": "ap-northeast-1";
|
|
138
|
-
"ap-northeast-2": "ap-northeast-2";
|
|
139
|
-
"ap-northeast-3": "ap-northeast-3";
|
|
140
|
-
"ap-south-1": "ap-south-1";
|
|
141
|
-
"ap-south-2": "ap-south-2";
|
|
142
|
-
"ap-southeast-1": "ap-southeast-1";
|
|
143
|
-
"ap-southeast-2": "ap-southeast-2";
|
|
144
|
-
"ap-southeast-3": "ap-southeast-3";
|
|
145
|
-
"ap-southeast-4": "ap-southeast-4";
|
|
146
|
-
"ap-southeast-5": "ap-southeast-5";
|
|
147
|
-
"ap-southeast-7": "ap-southeast-7";
|
|
148
|
-
"ca-central-1": "ca-central-1";
|
|
149
|
-
"eu-central-1": "eu-central-1";
|
|
150
|
-
"eu-central-2": "eu-central-2";
|
|
151
|
-
"eu-north-1": "eu-north-1";
|
|
152
|
-
"eu-south-1": "eu-south-1";
|
|
153
|
-
"eu-south-2": "eu-south-2";
|
|
154
|
-
"eu-west-1": "eu-west-1";
|
|
155
|
-
"eu-west-2": "eu-west-2";
|
|
156
|
-
"eu-west-3": "eu-west-3";
|
|
157
|
-
"il-central-1": "il-central-1";
|
|
158
|
-
"me-central-1": "me-central-1";
|
|
159
|
-
"sa-east-1": "sa-east-1";
|
|
160
|
-
"us-east-1": "us-east-1";
|
|
161
|
-
"us-east-2": "us-east-2";
|
|
162
|
-
"us-gov-east-1": "us-gov-east-1";
|
|
163
|
-
"us-gov-west-1": "us-gov-west-1";
|
|
164
|
-
"us-west-1": "us-west-1";
|
|
165
|
-
"us-west-2": "us-west-2";
|
|
166
|
-
}>>;
|
|
42
|
+
region: z.ZodMiniOptional<z.ZodMiniString<string>>;
|
|
167
43
|
}, z.core.$strict>;
|
|
168
44
|
/**
|
|
169
45
|
* Anthropic
|
|
@@ -225,72 +101,45 @@ export declare const openAiModelProviderConfigRetrieveSchema: z.ZodMiniObject<{
|
|
|
225
101
|
organizationId: z.ZodMiniString<string>;
|
|
226
102
|
}, z.core.$strict>;
|
|
227
103
|
export declare const listModelsPropertiesSchema: z.ZodMiniUnion<readonly [z.ZodMiniObject<{
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
"eu-central-2": "eu-central-2";
|
|
255
|
-
"eu-north-1": "eu-north-1";
|
|
256
|
-
"eu-south-1": "eu-south-1";
|
|
257
|
-
"eu-south-2": "eu-south-2";
|
|
258
|
-
"eu-west-1": "eu-west-1";
|
|
259
|
-
"eu-west-2": "eu-west-2";
|
|
260
|
-
"eu-west-3": "eu-west-3";
|
|
261
|
-
"il-central-1": "il-central-1";
|
|
262
|
-
"me-central-1": "me-central-1";
|
|
263
|
-
"sa-east-1": "sa-east-1";
|
|
264
|
-
"us-east-1": "us-east-1";
|
|
265
|
-
"us-east-2": "us-east-2";
|
|
266
|
-
"us-gov-east-1": "us-gov-east-1";
|
|
267
|
-
"us-gov-west-1": "us-gov-west-1";
|
|
268
|
-
"us-west-1": "us-west-1";
|
|
269
|
-
"us-west-2": "us-west-2";
|
|
270
|
-
}>;
|
|
271
|
-
}, z.core.$strict>;
|
|
272
|
-
}, z.core.$strict>, z.ZodMiniObject<{
|
|
273
|
-
anthropic: z.ZodMiniObject<{
|
|
274
|
-
accessKey: z.ZodMiniString<string>;
|
|
275
|
-
}, z.core.$strict>;
|
|
276
|
-
}, z.core.$strict>, z.ZodMiniObject<{
|
|
277
|
-
azureOpenAi: z.ZodMiniObject<{
|
|
278
|
-
auth: z.ZodMiniObject<{
|
|
279
|
-
clientSecretAuth: z.ZodMiniObject<{
|
|
280
|
-
azureClientId: z.ZodMiniString<string>;
|
|
281
|
-
azureClientSecret: z.ZodMiniString<string>;
|
|
282
|
-
azureTenantId: z.ZodMiniString<string>;
|
|
104
|
+
access: z.ZodMiniUnion<readonly [z.ZodMiniObject<{
|
|
105
|
+
amazonBedrock: z.ZodMiniObject<{
|
|
106
|
+
auth: z.ZodMiniUnion<readonly [z.ZodMiniObject<{
|
|
107
|
+
accessKey: z.ZodMiniObject<{
|
|
108
|
+
accessKeyId: z.ZodMiniString<string>;
|
|
109
|
+
secretAccessKey: z.ZodMiniString<string>;
|
|
110
|
+
}, z.core.$strict>;
|
|
111
|
+
}, z.core.$strict>, z.ZodMiniObject<{
|
|
112
|
+
role: z.ZodMiniObject<{
|
|
113
|
+
roleArn: z.ZodMiniString<string>;
|
|
114
|
+
}, z.core.$strict>;
|
|
115
|
+
}, z.core.$strict>]>;
|
|
116
|
+
region: z.ZodMiniString<string>;
|
|
117
|
+
}, z.core.$strict>;
|
|
118
|
+
}, z.core.$strict>, z.ZodMiniObject<{
|
|
119
|
+
anthropic: z.ZodMiniObject<{
|
|
120
|
+
accessKey: z.ZodMiniString<string>;
|
|
121
|
+
}, z.core.$strict>;
|
|
122
|
+
}, z.core.$strict>, z.ZodMiniObject<{
|
|
123
|
+
azureOpenAi: z.ZodMiniObject<{
|
|
124
|
+
auth: z.ZodMiniObject<{
|
|
125
|
+
clientSecretAuth: z.ZodMiniObject<{
|
|
126
|
+
azureClientId: z.ZodMiniString<string>;
|
|
127
|
+
azureClientSecret: z.ZodMiniString<string>;
|
|
128
|
+
azureTenantId: z.ZodMiniString<string>;
|
|
129
|
+
}, z.core.$strict>;
|
|
283
130
|
}, z.core.$strict>;
|
|
131
|
+
resourceName: z.ZodMiniString<string>;
|
|
284
132
|
}, z.core.$strict>;
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
133
|
+
}, z.core.$strict>, z.ZodMiniObject<{
|
|
134
|
+
googleGemini: z.ZodMiniObject<{
|
|
135
|
+
accessKey: z.ZodMiniString<string>;
|
|
136
|
+
}, z.core.$strict>;
|
|
137
|
+
}, z.core.$strict>, z.ZodMiniObject<{
|
|
138
|
+
openAi: z.ZodMiniObject<{
|
|
139
|
+
accessKey: z.ZodMiniString<string>;
|
|
140
|
+
organizationId: z.ZodMiniString<string>;
|
|
141
|
+
}, z.core.$strict>;
|
|
142
|
+
}, z.core.$strict>]>;
|
|
291
143
|
}, z.core.$strict>, z.ZodMiniObject<{
|
|
292
|
-
|
|
293
|
-
accessKey: z.ZodMiniString<string>;
|
|
294
|
-
organizationId: z.ZodMiniString<string>;
|
|
295
|
-
}, z.core.$strict>;
|
|
144
|
+
modelProviderName: z.ZodMiniString<string>;
|
|
296
145
|
}, z.core.$strict>]>;
|
|
@@ -17,38 +17,7 @@ import * as z from "zod/mini";
|
|
|
17
17
|
/**
|
|
18
18
|
* Amazon Bedrock
|
|
19
19
|
*/
|
|
20
|
-
export const amazonBedrockRegionSchema = z.
|
|
21
|
-
"ap-east-2",
|
|
22
|
-
"ap-northeast-1",
|
|
23
|
-
"ap-northeast-2",
|
|
24
|
-
"ap-northeast-3",
|
|
25
|
-
"ap-south-1",
|
|
26
|
-
"ap-south-2",
|
|
27
|
-
"ap-southeast-1",
|
|
28
|
-
"ap-southeast-2",
|
|
29
|
-
"ap-southeast-3",
|
|
30
|
-
"ap-southeast-4",
|
|
31
|
-
"ap-southeast-5",
|
|
32
|
-
"ap-southeast-7",
|
|
33
|
-
"ca-central-1",
|
|
34
|
-
"eu-central-1",
|
|
35
|
-
"eu-central-2",
|
|
36
|
-
"eu-north-1",
|
|
37
|
-
"eu-south-1",
|
|
38
|
-
"eu-south-2",
|
|
39
|
-
"eu-west-1",
|
|
40
|
-
"eu-west-2",
|
|
41
|
-
"eu-west-3",
|
|
42
|
-
"il-central-1",
|
|
43
|
-
"me-central-1",
|
|
44
|
-
"sa-east-1",
|
|
45
|
-
"us-east-1",
|
|
46
|
-
"us-east-2",
|
|
47
|
-
"us-gov-east-1",
|
|
48
|
-
"us-gov-west-1",
|
|
49
|
-
"us-west-1",
|
|
50
|
-
"us-west-2",
|
|
51
|
-
]);
|
|
20
|
+
export const amazonBedrockRegionSchema = z.string();
|
|
52
21
|
const amazonBedrockAccessKeyAuth = z.strictObject({
|
|
53
22
|
accessKey: z.strictObject({
|
|
54
23
|
accessKeyId: z.string(),
|
|
@@ -139,7 +108,7 @@ export const openAiModelProviderConfigSchema = z.strictObject({
|
|
|
139
108
|
export const openAiModelProviderConfigRetrieveSchema = z.strictObject({
|
|
140
109
|
organizationId: z.string(),
|
|
141
110
|
});
|
|
142
|
-
|
|
111
|
+
const listModelsAccessSchema = z.union([
|
|
143
112
|
z.strictObject({
|
|
144
113
|
amazonBedrock: amazonBedrockModelProviderConfigSchema,
|
|
145
114
|
}),
|
|
@@ -156,4 +125,12 @@ export const listModelsPropertiesSchema = z.union([
|
|
|
156
125
|
openAi: openAiModelProviderConfigSchema,
|
|
157
126
|
}),
|
|
158
127
|
]);
|
|
128
|
+
export const listModelsPropertiesSchema = z.union([
|
|
129
|
+
z.strictObject({
|
|
130
|
+
access: listModelsAccessSchema,
|
|
131
|
+
}),
|
|
132
|
+
z.strictObject({
|
|
133
|
+
modelProviderName: z.string(),
|
|
134
|
+
}),
|
|
135
|
+
]);
|
|
159
136
|
//# sourceMappingURL=modelProviderConfigSchemas.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"modelProviderConfigSchemas.js","sourceRoot":"","sources":["../../../src/enterprise/ai/modelProviderConfigSchemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,CAAC,MAAM,UAAU,CAAC;AAE9B;;GAEG;AACH,MAAM,CAAC,MAAM,yBAAyB,GAAG,CAAC,CAAC,
|
|
1
|
+
{"version":3,"file":"modelProviderConfigSchemas.js","sourceRoot":"","sources":["../../../src/enterprise/ai/modelProviderConfigSchemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,CAAC,MAAM,UAAU,CAAC;AAE9B;;GAEG;AACH,MAAM,CAAC,MAAM,yBAAyB,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC;AAEpD,MAAM,0BAA0B,GAAG,CAAC,CAAC,YAAY,CAAC;IAChD,SAAS,EAAE,CAAC,CAAC,YAAY,CAAC;QACxB,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE;QACvB,eAAe,EAAE,CAAC,CAAC,MAAM,EAAE;KAC5B,CAAC;CACH,CAAC,CAAC;AAEH,MAAM,qBAAqB,GAAG,CAAC,CAAC,YAAY,CAAC;IAC3C,IAAI,EAAE,CAAC,CAAC,YAAY,CAAC;QACnB,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE;KACpB,CAAC;CACH,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,sCAAsC,GAAG,CAAC,CAAC,YAAY,CAAC;IACnE,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,0BAA0B,EAAE,qBAAqB,CAAC,CAAC;IAClE,MAAM,EAAE,yBAAyB;CAClC,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,8CAA8C,GAAG,CAAC,CAAC,YAAY,CAAC;IAC3E,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC;QACZ,CAAC,CAAC,YAAY,CAAC;YACb,SAAS,EAAE,CAAC,CAAC,IAAI,CAAC,0BAA0B,CAAC,KAAK,CAAC,SAAS,EAAE,EAAE,eAAe,EAAE,IA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S,EAAE,CAAC,CAAC,MAAM,EAAE;IACrB,cAAc,EAAE,CAAC,CAAC,MAAM,EAAE;CAC3B,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,uCAAuC,GAAG,CAAC,CAAC,YAAY,CAAC;IACpE,cAAc,EAAE,CAAC,CAAC,MAAM,EAAE;CAC3B,CAAC,CAAC;AAEH,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC;IACrC,CAAC,CAAC,YAAY,CAAC;QACb,aAAa,EAAE,sCAAsC;KACtD,CAAC;IACF,CAAC,CAAC,YAAY,CAAC;QACb,SAAS,EAAE,kCAAkC;KAC9C,CAAC;IACF,CAAC,CAAC,YAAY,CAAC;QACb,WAAW,EAAE,oCAAoC;KAClD,CAAC;IACF,CAAC,CAAC,YAAY,CAAC;QACb,YAAY,EAAE,qCAAqC;KACpD,CAAC;IACF,CAAC,CAAC,YAAY,CAAC;QACb,MAAM,EAAE,+BAA+B;KACxC,CAAC;CACH,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC;IAChD,CAAC,CAAC,YAAY,CAAC;QACb,MAAM,EAAE,sBAAsB;KAC/B,CAAC;IACF,CAAC,CAAC,YAAY,CAAC;QACb,iBAAiB,EAAE,CAAC,CAAC,MAAM,EAAE;KAC9B,CAAC;CACH,CAAC,CAAC","sourcesContent":["/*\n * Copyright (C) 2024-2025 Dremio Corporation\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport * as z from \"zod/mini\";\n\n/**\n * Amazon Bedrock\n */\nexport const amazonBedrockRegionSchema = z.string();\n\nconst amazonBedrockAccessKeyAuth = z.strictObject({\n accessKey: z.strictObject({\n accessKeyId: z.string(),\n secretAccessKey: z.string(),\n }),\n});\n\nconst amazonBedrockRoleAuth = z.strictObject({\n role: z.strictObject({\n roleArn: z.string(),\n }),\n});\n\nexport const amazonBedrockModelProviderConfigSchema = z.strictObject({\n auth: z.union([amazonBedrockAccessKeyAuth, amazonBedrockRoleAuth]),\n region: amazonBedrockRegionSchema,\n});\n\nexport const amazonBedrockModelProviderConfigRetrieveSchema = z.strictObject({\n auth: z.union([\n z.strictObject({\n accessKey: z.omit(amazonBedrockAccessKeyAuth.shape.accessKey, { secretAccessKey: true }),\n }),\n amazonBedrockRoleAuth,\n ]),\n region: amazonBedrockRegionSchema,\n});\n\nexport const amazonBedrockModelProviderConfigUpdateSchema = z.strictObject({\n auth: z.optional(\n z.union([\n z.strictObject({\n accessKey: z.extend(\n z.omit(amazonBedrockAccessKeyAuth.shape.accessKey, { secretAccessKey: true }),\n {\n secretAccessKey: z.optional(\n amazonBedrockAccessKeyAuth.shape.accessKey.shape.secretAccessKey,\n ),\n },\n ),\n }),\n amazonBedrockRoleAuth,\n ]),\n ),\n region: z.optional(amazonBedrockRegionSchema),\n});\n\n/**\n * Anthropic\n */\nexport const anthropicModelProviderConfigSchema = z.strictObject({\n accessKey: z.string(),\n});\n\n/**\n * Azure OpenAI\n */\nconst azureOpenAiAuth = z.strictObject({\n clientSecretAuth: z.strictObject({\n azureClientId: z.string(),\n azureClientSecret: z.string(),\n azureTenantId: z.string(),\n }),\n});\n\nexport const azureOpenAiModelProviderConfigSchema = z.strictObject({\n auth: z.strictObject(azureOpenAiAuth.shape),\n resourceName: z.string(),\n});\n\nexport const azureOpenAiModelProviderConfigRetrieveSchema = z.strictObject({\n auth: z.strictObject({\n clientSecretAuth: z.omit(azureOpenAiAuth.shape.clientSecretAuth, { azureClientSecret: true }),\n }),\n resourceName: z.string(),\n});\n\nexport const azureOpenAiModelProviderConfigUpdateSchema = z.strictObject({\n auth: z.optional(\n z.union([\n azureOpenAiModelProviderConfigSchema.shape.auth,\n z.strictObject({\n clientSecretAuth: z.extend(\n z.omit(azureOpenAiAuth.shape.clientSecretAuth, { azureClientSecret: true }),\n {\n azureClientSecret: z.optional(\n azureOpenAiAuth.shape.clientSecretAuth.shape.azureClientSecret,\n ),\n },\n ),\n }),\n ]),\n ),\n resourceName: z.string(),\n});\n\nexport const anthropicModelProviderConfigRetrieveSchema = z.strictObject({});\n\n/**\n * Google Gemini\n */\nexport const googleGeminiModelProviderConfigSchema = z.strictObject({\n accessKey: z.string(),\n});\n\nexport const googleGeminiModelProviderConfigRetrieveSchema = z.strictObject({});\n\n/**\n * OpenAI\n */\nexport const openAiModelProviderConfigSchema = z.strictObject({\n accessKey: z.string(),\n organizationId: z.string(),\n});\n\nexport const openAiModelProviderConfigRetrieveSchema = z.strictObject({\n organizationId: z.string(),\n});\n\nconst listModelsAccessSchema = z.union([\n z.strictObject({\n amazonBedrock: amazonBedrockModelProviderConfigSchema,\n }),\n z.strictObject({\n anthropic: anthropicModelProviderConfigSchema,\n }),\n z.strictObject({\n azureOpenAi: azureOpenAiModelProviderConfigSchema,\n }),\n z.strictObject({\n googleGemini: googleGeminiModelProviderConfigSchema,\n }),\n z.strictObject({\n openAi: openAiModelProviderConfigSchema,\n }),\n]);\n\nexport const listModelsPropertiesSchema = z.union([\n z.strictObject({\n access: listModelsAccessSchema,\n }),\n z.strictObject({\n modelProviderName: z.string(),\n }),\n]);\n"]}
|