@mlhub/models-ts-sdk 0.1.1 → 0.3.0
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/.openapi-generator/FILES +4 -1
- package/README.md +2 -2
- package/dist/apis/ArtifactsApi.d.ts +2 -2
- package/dist/apis/ArtifactsApi.js +3 -3
- package/dist/apis/ModelsApi.d.ts +17 -11
- package/dist/apis/ModelsApi.js +27 -20
- package/dist/models/AssociateModelMetadataBody.d.ts +33 -0
- package/dist/models/{AssociateModelMetadata.js → AssociateModelMetadataBody.js} +7 -7
- package/dist/models/Canonical.d.ts +76 -0
- package/dist/models/Canonical.js +58 -0
- package/dist/models/CreateModelMetadataBody.d.ts +245 -0
- package/dist/models/CreateModelMetadataBody.js +114 -0
- package/dist/models/DiscoveryCriteria.d.ts +0 -6
- package/dist/models/DiscoveryCriteria.js +0 -2
- package/dist/models/Locator.d.ts +27 -0
- package/dist/models/Locator.js +40 -0
- package/dist/models/ModelMetadata.d.ts +13 -1
- package/dist/models/ModelMetadata.js +4 -0
- package/dist/models/index.d.ts +4 -1
- package/dist/models/index.js +4 -1
- package/package.json +1 -1
- package/src/apis/ArtifactsApi.ts +7 -7
- package/src/apis/ModelsApi.ts +34 -31
- package/src/models/{AssociateModelMetadata.ts → AssociateModelMetadataBody.ts} +8 -8
- package/src/models/Canonical.ts +131 -0
- package/src/models/CreateModelMetadataBody.ts +360 -0
- package/src/models/DiscoveryCriteria.ts +0 -8
- package/src/models/Locator.ts +56 -0
- package/src/models/ModelMetadata.ts +20 -0
- package/src/models/index.ts +4 -1
- package/dist/models/AssociateModelMetadata.d.ts +0 -33
|
@@ -0,0 +1,360 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* MLHub Models API
|
|
5
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 0.1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { exists, mapValues } from '../runtime';
|
|
16
|
+
import {
|
|
17
|
+
HardwareRequirements,
|
|
18
|
+
HardwareRequirementsFromJSON,
|
|
19
|
+
HardwareRequirementsFromJSONTyped,
|
|
20
|
+
HardwareRequirementsToJSON,
|
|
21
|
+
ModelIO,
|
|
22
|
+
ModelIOFromJSON,
|
|
23
|
+
ModelIOFromJSONTyped,
|
|
24
|
+
ModelIOToJSON,
|
|
25
|
+
Task,
|
|
26
|
+
TaskFromJSON,
|
|
27
|
+
TaskFromJSONTyped,
|
|
28
|
+
TaskToJSON,
|
|
29
|
+
} from './';
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
*
|
|
33
|
+
* @export
|
|
34
|
+
* @interface CreateModelMetadataBody
|
|
35
|
+
*/
|
|
36
|
+
export interface CreateModelMetadataBody {
|
|
37
|
+
/**
|
|
38
|
+
*
|
|
39
|
+
* @type {any}
|
|
40
|
+
* @memberof CreateModelMetadataBody
|
|
41
|
+
*/
|
|
42
|
+
annotations?: any | null;
|
|
43
|
+
/**
|
|
44
|
+
*
|
|
45
|
+
* @type {string}
|
|
46
|
+
* @memberof CreateModelMetadataBody
|
|
47
|
+
*/
|
|
48
|
+
author?: string | null;
|
|
49
|
+
/**
|
|
50
|
+
*
|
|
51
|
+
* @type {number}
|
|
52
|
+
* @memberof CreateModelMetadataBody
|
|
53
|
+
*/
|
|
54
|
+
bias_evaluation_score?: number | null;
|
|
55
|
+
/**
|
|
56
|
+
*
|
|
57
|
+
* @type {boolean}
|
|
58
|
+
* @memberof CreateModelMetadataBody
|
|
59
|
+
*/
|
|
60
|
+
edge_optimized?: boolean | null;
|
|
61
|
+
/**
|
|
62
|
+
*
|
|
63
|
+
* @type {Array<string>}
|
|
64
|
+
* @memberof CreateModelMetadataBody
|
|
65
|
+
*/
|
|
66
|
+
finetuning_datasets?: Array<string> | null;
|
|
67
|
+
/**
|
|
68
|
+
*
|
|
69
|
+
* @type {string}
|
|
70
|
+
* @memberof CreateModelMetadataBody
|
|
71
|
+
*/
|
|
72
|
+
image?: string | null;
|
|
73
|
+
/**
|
|
74
|
+
*
|
|
75
|
+
* @type {boolean}
|
|
76
|
+
* @memberof CreateModelMetadataBody
|
|
77
|
+
*/
|
|
78
|
+
inference_distributed?: boolean | null;
|
|
79
|
+
/**
|
|
80
|
+
*
|
|
81
|
+
* @type {HardwareRequirements}
|
|
82
|
+
* @memberof CreateModelMetadataBody
|
|
83
|
+
*/
|
|
84
|
+
inference_hardware?: HardwareRequirements;
|
|
85
|
+
/**
|
|
86
|
+
*
|
|
87
|
+
* @type {number}
|
|
88
|
+
* @memberof CreateModelMetadataBody
|
|
89
|
+
*/
|
|
90
|
+
inference_max_compute_utilization_percentage?: number | null;
|
|
91
|
+
/**
|
|
92
|
+
*
|
|
93
|
+
* @type {number}
|
|
94
|
+
* @memberof CreateModelMetadataBody
|
|
95
|
+
*/
|
|
96
|
+
inference_max_energy_consumption_watts?: number | null;
|
|
97
|
+
/**
|
|
98
|
+
* Inference performance fields
|
|
99
|
+
* @type {number}
|
|
100
|
+
* @memberof CreateModelMetadataBody
|
|
101
|
+
*/
|
|
102
|
+
inference_max_latency_ms?: number | null;
|
|
103
|
+
/**
|
|
104
|
+
*
|
|
105
|
+
* @type {number}
|
|
106
|
+
* @memberof CreateModelMetadataBody
|
|
107
|
+
*/
|
|
108
|
+
inference_max_memory_usage_mb?: number | null;
|
|
109
|
+
/**
|
|
110
|
+
*
|
|
111
|
+
* @type {number}
|
|
112
|
+
* @memberof CreateModelMetadataBody
|
|
113
|
+
*/
|
|
114
|
+
inference_min_throughput?: number | null;
|
|
115
|
+
/**
|
|
116
|
+
*
|
|
117
|
+
* @type {string}
|
|
118
|
+
* @memberof CreateModelMetadataBody
|
|
119
|
+
*/
|
|
120
|
+
inference_precision?: string | null;
|
|
121
|
+
/**
|
|
122
|
+
*
|
|
123
|
+
* @type {Array<string>}
|
|
124
|
+
* @memberof CreateModelMetadataBody
|
|
125
|
+
*/
|
|
126
|
+
inference_software_dependencies?: Array<string> | null;
|
|
127
|
+
/**
|
|
128
|
+
* Arbitrary labels
|
|
129
|
+
* @type {Array<string>}
|
|
130
|
+
* @memberof CreateModelMetadataBody
|
|
131
|
+
*/
|
|
132
|
+
keywords?: Array<string> | null;
|
|
133
|
+
/**
|
|
134
|
+
*
|
|
135
|
+
* @type {Array<string>}
|
|
136
|
+
* @memberof CreateModelMetadataBody
|
|
137
|
+
*/
|
|
138
|
+
libraries?: Array<string> | null;
|
|
139
|
+
/**
|
|
140
|
+
*
|
|
141
|
+
* @type {string}
|
|
142
|
+
* @memberof CreateModelMetadataBody
|
|
143
|
+
*/
|
|
144
|
+
license?: string | null;
|
|
145
|
+
/**
|
|
146
|
+
*
|
|
147
|
+
* @type {Array<ModelIO>}
|
|
148
|
+
* @memberof CreateModelMetadataBody
|
|
149
|
+
*/
|
|
150
|
+
model_inputs?: Array<ModelIO> | null;
|
|
151
|
+
/**
|
|
152
|
+
*
|
|
153
|
+
* @type {Array<ModelIO>}
|
|
154
|
+
* @memberof CreateModelMetadataBody
|
|
155
|
+
*/
|
|
156
|
+
model_outputs?: Array<ModelIO> | null;
|
|
157
|
+
/**
|
|
158
|
+
*
|
|
159
|
+
* @type {string}
|
|
160
|
+
* @memberof CreateModelMetadataBody
|
|
161
|
+
*/
|
|
162
|
+
model_type?: string | null;
|
|
163
|
+
/**
|
|
164
|
+
* Architecture fields
|
|
165
|
+
* @type {boolean}
|
|
166
|
+
* @memberof CreateModelMetadataBody
|
|
167
|
+
*/
|
|
168
|
+
multi_modal?: boolean | null;
|
|
169
|
+
/**
|
|
170
|
+
*
|
|
171
|
+
* @type {string}
|
|
172
|
+
* @memberof CreateModelMetadataBody
|
|
173
|
+
*/
|
|
174
|
+
name?: string | null;
|
|
175
|
+
/**
|
|
176
|
+
*
|
|
177
|
+
* @type {boolean}
|
|
178
|
+
* @memberof CreateModelMetadataBody
|
|
179
|
+
*/
|
|
180
|
+
pretrained?: boolean | null;
|
|
181
|
+
/**
|
|
182
|
+
*
|
|
183
|
+
* @type {Array<string>}
|
|
184
|
+
* @memberof CreateModelMetadataBody
|
|
185
|
+
*/
|
|
186
|
+
pretraining_datasets?: Array<string> | null;
|
|
187
|
+
/**
|
|
188
|
+
*
|
|
189
|
+
* @type {boolean}
|
|
190
|
+
* @memberof CreateModelMetadataBody
|
|
191
|
+
*/
|
|
192
|
+
pruned?: boolean | null;
|
|
193
|
+
/**
|
|
194
|
+
*
|
|
195
|
+
* @type {boolean}
|
|
196
|
+
* @memberof CreateModelMetadataBody
|
|
197
|
+
*/
|
|
198
|
+
quantization_aware?: boolean | null;
|
|
199
|
+
/**
|
|
200
|
+
* Regulatory and Compliance Fields
|
|
201
|
+
* A vector or strings that represent regulatory standards. Ex HIPPA
|
|
202
|
+
* @type {Array<string>}
|
|
203
|
+
* @memberof CreateModelMetadataBody
|
|
204
|
+
*/
|
|
205
|
+
regulatory?: Array<string> | null;
|
|
206
|
+
/**
|
|
207
|
+
*
|
|
208
|
+
* @type {boolean}
|
|
209
|
+
* @memberof CreateModelMetadataBody
|
|
210
|
+
*/
|
|
211
|
+
slimmed?: boolean | null;
|
|
212
|
+
/**
|
|
213
|
+
*
|
|
214
|
+
* @type {boolean}
|
|
215
|
+
* @memberof CreateModelMetadataBody
|
|
216
|
+
*/
|
|
217
|
+
supports_quantization?: boolean | null;
|
|
218
|
+
/**
|
|
219
|
+
* Inference Fields
|
|
220
|
+
* @type {Array<Task>}
|
|
221
|
+
* @memberof CreateModelMetadataBody
|
|
222
|
+
*/
|
|
223
|
+
task_types?: Array<Task> | null;
|
|
224
|
+
/**
|
|
225
|
+
*
|
|
226
|
+
* @type {string}
|
|
227
|
+
* @memberof CreateModelMetadataBody
|
|
228
|
+
*/
|
|
229
|
+
tenant_id?: string | null;
|
|
230
|
+
/**
|
|
231
|
+
*
|
|
232
|
+
* @type {boolean}
|
|
233
|
+
* @memberof CreateModelMetadataBody
|
|
234
|
+
*/
|
|
235
|
+
training_distributed?: boolean | null;
|
|
236
|
+
/**
|
|
237
|
+
*
|
|
238
|
+
* @type {HardwareRequirements}
|
|
239
|
+
* @memberof CreateModelMetadataBody
|
|
240
|
+
*/
|
|
241
|
+
training_hardware?: HardwareRequirements;
|
|
242
|
+
/**
|
|
243
|
+
* Training performance fields
|
|
244
|
+
* @type {number}
|
|
245
|
+
* @memberof CreateModelMetadataBody
|
|
246
|
+
*/
|
|
247
|
+
training_max_energy_consumption_watts?: number | null;
|
|
248
|
+
/**
|
|
249
|
+
*
|
|
250
|
+
* @type {string}
|
|
251
|
+
* @memberof CreateModelMetadataBody
|
|
252
|
+
*/
|
|
253
|
+
training_precision?: string | null;
|
|
254
|
+
/**
|
|
255
|
+
* Training-related Fields
|
|
256
|
+
* @type {number}
|
|
257
|
+
* @memberof CreateModelMetadataBody
|
|
258
|
+
*/
|
|
259
|
+
training_time?: number | null;
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
export function CreateModelMetadataBodyFromJSON(json: any): CreateModelMetadataBody {
|
|
263
|
+
return CreateModelMetadataBodyFromJSONTyped(json, false);
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
export function CreateModelMetadataBodyFromJSONTyped(json: any, ignoreDiscriminator: boolean): CreateModelMetadataBody {
|
|
267
|
+
if ((json === undefined) || (json === null)) {
|
|
268
|
+
return json;
|
|
269
|
+
}
|
|
270
|
+
return {
|
|
271
|
+
|
|
272
|
+
'annotations': !exists(json, 'annotations') ? undefined : json['annotations'],
|
|
273
|
+
'author': !exists(json, 'author') ? undefined : json['author'],
|
|
274
|
+
'bias_evaluation_score': !exists(json, 'bias_evaluation_score') ? undefined : json['bias_evaluation_score'],
|
|
275
|
+
'edge_optimized': !exists(json, 'edge_optimized') ? undefined : json['edge_optimized'],
|
|
276
|
+
'finetuning_datasets': !exists(json, 'finetuning_datasets') ? undefined : json['finetuning_datasets'],
|
|
277
|
+
'image': !exists(json, 'image') ? undefined : json['image'],
|
|
278
|
+
'inference_distributed': !exists(json, 'inference_distributed') ? undefined : json['inference_distributed'],
|
|
279
|
+
'inference_hardware': !exists(json, 'inference_hardware') ? undefined : HardwareRequirementsFromJSON(json['inference_hardware']),
|
|
280
|
+
'inference_max_compute_utilization_percentage': !exists(json, 'inference_max_compute_utilization_percentage') ? undefined : json['inference_max_compute_utilization_percentage'],
|
|
281
|
+
'inference_max_energy_consumption_watts': !exists(json, 'inference_max_energy_consumption_watts') ? undefined : json['inference_max_energy_consumption_watts'],
|
|
282
|
+
'inference_max_latency_ms': !exists(json, 'inference_max_latency_ms') ? undefined : json['inference_max_latency_ms'],
|
|
283
|
+
'inference_max_memory_usage_mb': !exists(json, 'inference_max_memory_usage_mb') ? undefined : json['inference_max_memory_usage_mb'],
|
|
284
|
+
'inference_min_throughput': !exists(json, 'inference_min_throughput') ? undefined : json['inference_min_throughput'],
|
|
285
|
+
'inference_precision': !exists(json, 'inference_precision') ? undefined : json['inference_precision'],
|
|
286
|
+
'inference_software_dependencies': !exists(json, 'inference_software_dependencies') ? undefined : json['inference_software_dependencies'],
|
|
287
|
+
'keywords': !exists(json, 'keywords') ? undefined : json['keywords'],
|
|
288
|
+
'libraries': !exists(json, 'libraries') ? undefined : json['libraries'],
|
|
289
|
+
'license': !exists(json, 'license') ? undefined : json['license'],
|
|
290
|
+
'model_inputs': !exists(json, 'model_inputs') ? undefined : (json['model_inputs'] === null ? null : (json['model_inputs'] as Array<any>).map(ModelIOFromJSON)),
|
|
291
|
+
'model_outputs': !exists(json, 'model_outputs') ? undefined : (json['model_outputs'] === null ? null : (json['model_outputs'] as Array<any>).map(ModelIOFromJSON)),
|
|
292
|
+
'model_type': !exists(json, 'model_type') ? undefined : json['model_type'],
|
|
293
|
+
'multi_modal': !exists(json, 'multi_modal') ? undefined : json['multi_modal'],
|
|
294
|
+
'name': !exists(json, 'name') ? undefined : json['name'],
|
|
295
|
+
'pretrained': !exists(json, 'pretrained') ? undefined : json['pretrained'],
|
|
296
|
+
'pretraining_datasets': !exists(json, 'pretraining_datasets') ? undefined : json['pretraining_datasets'],
|
|
297
|
+
'pruned': !exists(json, 'pruned') ? undefined : json['pruned'],
|
|
298
|
+
'quantization_aware': !exists(json, 'quantization_aware') ? undefined : json['quantization_aware'],
|
|
299
|
+
'regulatory': !exists(json, 'regulatory') ? undefined : json['regulatory'],
|
|
300
|
+
'slimmed': !exists(json, 'slimmed') ? undefined : json['slimmed'],
|
|
301
|
+
'supports_quantization': !exists(json, 'supports_quantization') ? undefined : json['supports_quantization'],
|
|
302
|
+
'task_types': !exists(json, 'task_types') ? undefined : (json['task_types'] === null ? null : (json['task_types'] as Array<any>).map(TaskFromJSON)),
|
|
303
|
+
'tenant_id': !exists(json, 'tenant_id') ? undefined : json['tenant_id'],
|
|
304
|
+
'training_distributed': !exists(json, 'training_distributed') ? undefined : json['training_distributed'],
|
|
305
|
+
'training_hardware': !exists(json, 'training_hardware') ? undefined : HardwareRequirementsFromJSON(json['training_hardware']),
|
|
306
|
+
'training_max_energy_consumption_watts': !exists(json, 'training_max_energy_consumption_watts') ? undefined : json['training_max_energy_consumption_watts'],
|
|
307
|
+
'training_precision': !exists(json, 'training_precision') ? undefined : json['training_precision'],
|
|
308
|
+
'training_time': !exists(json, 'training_time') ? undefined : json['training_time'],
|
|
309
|
+
};
|
|
310
|
+
}
|
|
311
|
+
|
|
312
|
+
export function CreateModelMetadataBodyToJSON(value?: CreateModelMetadataBody | null): any {
|
|
313
|
+
if (value === undefined) {
|
|
314
|
+
return undefined;
|
|
315
|
+
}
|
|
316
|
+
if (value === null) {
|
|
317
|
+
return null;
|
|
318
|
+
}
|
|
319
|
+
return {
|
|
320
|
+
|
|
321
|
+
'annotations': value.annotations,
|
|
322
|
+
'author': value.author,
|
|
323
|
+
'bias_evaluation_score': value.bias_evaluation_score,
|
|
324
|
+
'edge_optimized': value.edge_optimized,
|
|
325
|
+
'finetuning_datasets': value.finetuning_datasets,
|
|
326
|
+
'image': value.image,
|
|
327
|
+
'inference_distributed': value.inference_distributed,
|
|
328
|
+
'inference_hardware': HardwareRequirementsToJSON(value.inference_hardware),
|
|
329
|
+
'inference_max_compute_utilization_percentage': value.inference_max_compute_utilization_percentage,
|
|
330
|
+
'inference_max_energy_consumption_watts': value.inference_max_energy_consumption_watts,
|
|
331
|
+
'inference_max_latency_ms': value.inference_max_latency_ms,
|
|
332
|
+
'inference_max_memory_usage_mb': value.inference_max_memory_usage_mb,
|
|
333
|
+
'inference_min_throughput': value.inference_min_throughput,
|
|
334
|
+
'inference_precision': value.inference_precision,
|
|
335
|
+
'inference_software_dependencies': value.inference_software_dependencies,
|
|
336
|
+
'keywords': value.keywords,
|
|
337
|
+
'libraries': value.libraries,
|
|
338
|
+
'license': value.license,
|
|
339
|
+
'model_inputs': value.model_inputs === undefined ? undefined : (value.model_inputs === null ? null : (value.model_inputs as Array<any>).map(ModelIOToJSON)),
|
|
340
|
+
'model_outputs': value.model_outputs === undefined ? undefined : (value.model_outputs === null ? null : (value.model_outputs as Array<any>).map(ModelIOToJSON)),
|
|
341
|
+
'model_type': value.model_type,
|
|
342
|
+
'multi_modal': value.multi_modal,
|
|
343
|
+
'name': value.name,
|
|
344
|
+
'pretrained': value.pretrained,
|
|
345
|
+
'pretraining_datasets': value.pretraining_datasets,
|
|
346
|
+
'pruned': value.pruned,
|
|
347
|
+
'quantization_aware': value.quantization_aware,
|
|
348
|
+
'regulatory': value.regulatory,
|
|
349
|
+
'slimmed': value.slimmed,
|
|
350
|
+
'supports_quantization': value.supports_quantization,
|
|
351
|
+
'task_types': value.task_types === undefined ? undefined : (value.task_types === null ? null : (value.task_types as Array<any>).map(TaskToJSON)),
|
|
352
|
+
'tenant_id': value.tenant_id,
|
|
353
|
+
'training_distributed': value.training_distributed,
|
|
354
|
+
'training_hardware': HardwareRequirementsToJSON(value.training_hardware),
|
|
355
|
+
'training_max_energy_consumption_watts': value.training_max_energy_consumption_watts,
|
|
356
|
+
'training_precision': value.training_precision,
|
|
357
|
+
'training_time': value.training_time,
|
|
358
|
+
};
|
|
359
|
+
}
|
|
360
|
+
|
|
@@ -26,12 +26,6 @@ import {
|
|
|
26
26
|
* @interface DiscoveryCriteria
|
|
27
27
|
*/
|
|
28
28
|
export interface DiscoveryCriteria {
|
|
29
|
-
/**
|
|
30
|
-
*
|
|
31
|
-
* @type {number}
|
|
32
|
-
* @memberof DiscoveryCriteria
|
|
33
|
-
*/
|
|
34
|
-
confidence_threshold?: number | null;
|
|
35
29
|
/**
|
|
36
30
|
*
|
|
37
31
|
* @type {Array<DiscoveryCriterion>}
|
|
@@ -56,7 +50,6 @@ export function DiscoveryCriteriaFromJSONTyped(json: any, ignoreDiscriminator: b
|
|
|
56
50
|
}
|
|
57
51
|
return {
|
|
58
52
|
|
|
59
|
-
'confidence_threshold': !exists(json, 'confidence_threshold') ? undefined : json['confidence_threshold'],
|
|
60
53
|
'criteria': ((json['criteria'] as Array<any>).map(DiscoveryCriterionFromJSON)),
|
|
61
54
|
'prompt': !exists(json, 'prompt') ? undefined : json['prompt'],
|
|
62
55
|
};
|
|
@@ -71,7 +64,6 @@ export function DiscoveryCriteriaToJSON(value?: DiscoveryCriteria | null): any {
|
|
|
71
64
|
}
|
|
72
65
|
return {
|
|
73
66
|
|
|
74
|
-
'confidence_threshold': value.confidence_threshold,
|
|
75
67
|
'criteria': ((value.criteria as Array<any>).map(DiscoveryCriterionToJSON)),
|
|
76
68
|
'prompt': value.prompt,
|
|
77
69
|
};
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* MLHub Models API
|
|
5
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 0.1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { exists, mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface Locator
|
|
20
|
+
*/
|
|
21
|
+
export interface Locator {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof Locator
|
|
26
|
+
*/
|
|
27
|
+
url: string;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export function LocatorFromJSON(json: any): Locator {
|
|
31
|
+
return LocatorFromJSONTyped(json, false);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
export function LocatorFromJSONTyped(json: any, ignoreDiscriminator: boolean): Locator {
|
|
35
|
+
if ((json === undefined) || (json === null)) {
|
|
36
|
+
return json;
|
|
37
|
+
}
|
|
38
|
+
return {
|
|
39
|
+
|
|
40
|
+
'url': json['url'],
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export function LocatorToJSON(value?: Locator | null): any {
|
|
45
|
+
if (value === undefined) {
|
|
46
|
+
return undefined;
|
|
47
|
+
}
|
|
48
|
+
if (value === null) {
|
|
49
|
+
return null;
|
|
50
|
+
}
|
|
51
|
+
return {
|
|
52
|
+
|
|
53
|
+
'url': value.url,
|
|
54
|
+
};
|
|
55
|
+
}
|
|
56
|
+
|
|
@@ -14,6 +14,10 @@
|
|
|
14
14
|
|
|
15
15
|
import { exists, mapValues } from '../runtime';
|
|
16
16
|
import {
|
|
17
|
+
Canonical,
|
|
18
|
+
CanonicalFromJSON,
|
|
19
|
+
CanonicalFromJSONTyped,
|
|
20
|
+
CanonicalToJSON,
|
|
17
21
|
HardwareRequirements,
|
|
18
22
|
HardwareRequirementsFromJSON,
|
|
19
23
|
HardwareRequirementsFromJSONTyped,
|
|
@@ -52,6 +56,12 @@ export interface ModelMetadata {
|
|
|
52
56
|
* @memberof ModelMetadata
|
|
53
57
|
*/
|
|
54
58
|
bias_evaluation_score?: number | null;
|
|
59
|
+
/**
|
|
60
|
+
*
|
|
61
|
+
* @type {Canonical}
|
|
62
|
+
* @memberof ModelMetadata
|
|
63
|
+
*/
|
|
64
|
+
canonical?: Canonical;
|
|
55
65
|
/**
|
|
56
66
|
*
|
|
57
67
|
* @type {boolean}
|
|
@@ -221,6 +231,12 @@ export interface ModelMetadata {
|
|
|
221
231
|
* @memberof ModelMetadata
|
|
222
232
|
*/
|
|
223
233
|
task_types?: Array<Task> | null;
|
|
234
|
+
/**
|
|
235
|
+
*
|
|
236
|
+
* @type {string}
|
|
237
|
+
* @memberof ModelMetadata
|
|
238
|
+
*/
|
|
239
|
+
tenant_id?: string | null;
|
|
224
240
|
/**
|
|
225
241
|
*
|
|
226
242
|
* @type {boolean}
|
|
@@ -266,6 +282,7 @@ export function ModelMetadataFromJSONTyped(json: any, ignoreDiscriminator: boole
|
|
|
266
282
|
'annotations': !exists(json, 'annotations') ? undefined : json['annotations'],
|
|
267
283
|
'author': !exists(json, 'author') ? undefined : json['author'],
|
|
268
284
|
'bias_evaluation_score': !exists(json, 'bias_evaluation_score') ? undefined : json['bias_evaluation_score'],
|
|
285
|
+
'canonical': !exists(json, 'canonical') ? undefined : CanonicalFromJSON(json['canonical']),
|
|
269
286
|
'edge_optimized': !exists(json, 'edge_optimized') ? undefined : json['edge_optimized'],
|
|
270
287
|
'finetuning_datasets': !exists(json, 'finetuning_datasets') ? undefined : json['finetuning_datasets'],
|
|
271
288
|
'image': !exists(json, 'image') ? undefined : json['image'],
|
|
@@ -294,6 +311,7 @@ export function ModelMetadataFromJSONTyped(json: any, ignoreDiscriminator: boole
|
|
|
294
311
|
'slimmed': !exists(json, 'slimmed') ? undefined : json['slimmed'],
|
|
295
312
|
'supports_quantization': !exists(json, 'supports_quantization') ? undefined : json['supports_quantization'],
|
|
296
313
|
'task_types': !exists(json, 'task_types') ? undefined : (json['task_types'] === null ? null : (json['task_types'] as Array<any>).map(TaskFromJSON)),
|
|
314
|
+
'tenant_id': !exists(json, 'tenant_id') ? undefined : json['tenant_id'],
|
|
297
315
|
'training_distributed': !exists(json, 'training_distributed') ? undefined : json['training_distributed'],
|
|
298
316
|
'training_hardware': !exists(json, 'training_hardware') ? undefined : HardwareRequirementsFromJSON(json['training_hardware']),
|
|
299
317
|
'training_max_energy_consumption_watts': !exists(json, 'training_max_energy_consumption_watts') ? undefined : json['training_max_energy_consumption_watts'],
|
|
@@ -314,6 +332,7 @@ export function ModelMetadataToJSON(value?: ModelMetadata | null): any {
|
|
|
314
332
|
'annotations': value.annotations,
|
|
315
333
|
'author': value.author,
|
|
316
334
|
'bias_evaluation_score': value.bias_evaluation_score,
|
|
335
|
+
'canonical': CanonicalToJSON(value.canonical),
|
|
317
336
|
'edge_optimized': value.edge_optimized,
|
|
318
337
|
'finetuning_datasets': value.finetuning_datasets,
|
|
319
338
|
'image': value.image,
|
|
@@ -342,6 +361,7 @@ export function ModelMetadataToJSON(value?: ModelMetadata | null): any {
|
|
|
342
361
|
'slimmed': value.slimmed,
|
|
343
362
|
'supports_quantization': value.supports_quantization,
|
|
344
363
|
'task_types': value.task_types === undefined ? undefined : (value.task_types === null ? null : (value.task_types as Array<any>).map(TaskToJSON)),
|
|
364
|
+
'tenant_id': value.tenant_id,
|
|
345
365
|
'training_distributed': value.training_distributed,
|
|
346
366
|
'training_hardware': HardwareRequirementsToJSON(value.training_hardware),
|
|
347
367
|
'training_max_energy_consumption_watts': value.training_max_energy_consumption_watts,
|
package/src/models/index.ts
CHANGED
|
@@ -7,9 +7,11 @@ export * from './ArtifactIngestionStatus';
|
|
|
7
7
|
export * from './ArtifactPublication';
|
|
8
8
|
export * from './ArtifactPublicationStatus';
|
|
9
9
|
export * from './ArtifactType';
|
|
10
|
-
export * from './
|
|
10
|
+
export * from './AssociateModelMetadataBody';
|
|
11
11
|
export * from './AssociateModelMetadataResponse';
|
|
12
12
|
export * from './BadRequestResponse';
|
|
13
|
+
export * from './Canonical';
|
|
14
|
+
export * from './CreateModelMetadataBody';
|
|
13
15
|
export * from './CreateModelMetadataResponse';
|
|
14
16
|
export * from './DiscoverModelsByPlatformResponse';
|
|
15
17
|
export * from './DiscoverModelsResponse';
|
|
@@ -31,6 +33,7 @@ export * from './ListModelsByPlatformResponse';
|
|
|
31
33
|
export * from './ListModelsResponse';
|
|
32
34
|
export * from './ListPlatformsResponse';
|
|
33
35
|
export * from './ListTasksResponse';
|
|
36
|
+
export * from './Locator';
|
|
34
37
|
export * from './ModelArtifact';
|
|
35
38
|
export * from './ModelIO';
|
|
36
39
|
export * from './ModelMetadata';
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* MLHub Models API
|
|
3
|
-
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
-
*
|
|
5
|
-
* The version of the OpenAPI document: 0.1.0
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
-
* https://openapi-generator.tech
|
|
10
|
-
* Do not edit the class manually.
|
|
11
|
-
*/
|
|
12
|
-
/**
|
|
13
|
-
*
|
|
14
|
-
* @export
|
|
15
|
-
* @interface AssociateModelMetadata
|
|
16
|
-
*/
|
|
17
|
-
export interface AssociateModelMetadata {
|
|
18
|
-
/**
|
|
19
|
-
*
|
|
20
|
-
* @type {string}
|
|
21
|
-
* @memberof AssociateModelMetadata
|
|
22
|
-
*/
|
|
23
|
-
author: string;
|
|
24
|
-
/**
|
|
25
|
-
*
|
|
26
|
-
* @type {string}
|
|
27
|
-
* @memberof AssociateModelMetadata
|
|
28
|
-
*/
|
|
29
|
-
name: string;
|
|
30
|
-
}
|
|
31
|
-
export declare function AssociateModelMetadataFromJSON(json: any): AssociateModelMetadata;
|
|
32
|
-
export declare function AssociateModelMetadataFromJSONTyped(json: any, ignoreDiscriminator: boolean): AssociateModelMetadata;
|
|
33
|
-
export declare function AssociateModelMetadataToJSON(value?: AssociateModelMetadata | null): any;
|