@daocloud-proto/infery 0.0.0-dev-0ec171e1 → 0.0.0-dev-6ba2995b

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.
@@ -87,9 +87,9 @@ export type CreateInferenceTemplateRequest = {
87
87
 
88
88
  export type ListInferenceTemplatesRequest = {
89
89
  workspace?: number
90
- stack?: InferyCommonCommon.InferenceStack
91
- disaggregationMode?: InferyCommonCommon.DisaggregationMode
92
- maturity?: Maturity
90
+ stack?: InferyCommonCommon.InferenceStack[]
91
+ disaggregationMode?: InferyCommonCommon.DisaggregationMode[]
92
+ maturity?: Maturity[]
93
93
  page?: InferyCommonCommon.Pagination
94
94
  }
95
95
 
@@ -17,11 +17,6 @@ type OneOf<T> =
17
17
  : never)
18
18
  : never);
19
19
 
20
- export enum ConfigurationFormat {
21
- CONFIGURATION_FORMAT_UNSPECIFIED = "CONFIGURATION_FORMAT_UNSPECIFIED",
22
- CONFIGURATION_FORMAT_HELM_VALUES_YAML = "CONFIGURATION_FORMAT_HELM_VALUES_YAML",
23
- }
24
-
25
20
  export enum RoleType {
26
21
  ROLE_TYPE_UNSPECIFIED = "ROLE_TYPE_UNSPECIFIED",
27
22
  ROLE_TYPE_LLM_D_PREFILL = "ROLE_TYPE_LLM_D_PREFILL",
@@ -78,48 +73,9 @@ export enum AvailabilityStatus {
78
73
 
79
74
  export enum ModelServingOriginType {
80
75
  MODEL_SERVING_ORIGIN_TYPE_UNSPECIFIED = "MODEL_SERVING_ORIGIN_TYPE_UNSPECIFIED",
81
- MODEL_SERVING_ORIGIN_TYPE_STRUCTURED = "MODEL_SERVING_ORIGIN_TYPE_STRUCTURED",
82
- MODEL_SERVING_ORIGIN_TYPE_INFERENCE_TEMPLATE = "MODEL_SERVING_ORIGIN_TYPE_INFERENCE_TEMPLATE",
83
- MODEL_SERVING_ORIGIN_TYPE_CUSTOM_CONFIGURATION = "MODEL_SERVING_ORIGIN_TYPE_CUSTOM_CONFIGURATION",
84
- MODEL_SERVING_ORIGIN_TYPE_EXTERNAL = "MODEL_SERVING_ORIGIN_TYPE_EXTERNAL",
85
- }
86
-
87
- export enum ModelServingAction {
88
- MODEL_SERVING_ACTION_UNSPECIFIED = "MODEL_SERVING_ACTION_UNSPECIFIED",
89
- MODEL_SERVING_ACTION_START = "MODEL_SERVING_ACTION_START",
90
- MODEL_SERVING_ACTION_STOP = "MODEL_SERVING_ACTION_STOP",
91
- MODEL_SERVING_ACTION_SYNC = "MODEL_SERVING_ACTION_SYNC",
92
- MODEL_SERVING_ACTION_PAUSE_UPDATE = "MODEL_SERVING_ACTION_PAUSE_UPDATE",
93
- MODEL_SERVING_ACTION_RESUME_UPDATE = "MODEL_SERVING_ACTION_RESUME_UPDATE",
94
- }
95
-
96
- export enum ValidationIssueSeverity {
97
- SEVERITY_UNSPECIFIED = "SEVERITY_UNSPECIFIED",
98
- SEVERITY_ERROR = "SEVERITY_ERROR",
99
- SEVERITY_WARNING = "SEVERITY_WARNING",
100
- }
101
-
102
- export type Configuration = {
103
- format?: ConfigurationFormat
104
- content?: string
105
- }
106
-
107
- export type GetModelServingConfigurationResponse = {
108
- configuration?: Configuration
109
- revision?: string
110
- }
111
-
112
- export type ValidationIssue = {
113
- severity?: ValidationIssueSeverity
114
- fieldPath?: string
115
- code?: string
116
- message?: string
117
- }
118
-
119
- export type ConfigurationPreview = {
120
- valid?: boolean
121
- normalized?: Configuration
122
- issues?: ValidationIssue[]
76
+ MODEL_SERVING_ORIGIN_TYPE_OPTIMIZED_TEMPLATE = "MODEL_SERVING_ORIGIN_TYPE_OPTIMIZED_TEMPLATE",
77
+ MODEL_SERVING_ORIGIN_TYPE_GENERIC_TEMPLATE = "MODEL_SERVING_ORIGIN_TYPE_GENERIC_TEMPLATE",
78
+ MODEL_SERVING_ORIGIN_TYPE_CUSTOM_DEPLOYMENT = "MODEL_SERVING_ORIGIN_TYPE_CUSTOM_DEPLOYMENT",
123
79
  }
124
80
 
125
81
  export type PVCModelSource = {
@@ -159,10 +115,6 @@ export type InferenceTemplateReference = {
159
115
  name?: string
160
116
  }
161
117
 
162
- export type InferenceTemplateDeployment = {
163
- inferenceTemplateName?: string
164
- }
165
-
166
118
  export type ModelServingStatusSummary = {
167
119
  phase?: OperationPhase
168
120
  syncStatus?: SyncStatus
@@ -210,17 +162,17 @@ type BasePreviewModelServingRequest = {
210
162
  alias?: string
211
163
  cluster?: string
212
164
  namespace?: string
213
- accelerator?: AcceleratorSummary
214
165
  modelConfiguration?: ModelConfiguration
166
+ origin?: ModelServingOrigin
215
167
  }
216
168
 
217
169
  export type PreviewModelServingRequest = BasePreviewModelServingRequest
218
- & OneOf<{ inferenceTemplate: InferenceTemplateDeployment; configuration: Configuration }>
170
+ & OneOf<{ form: string; helmValues: string }>
171
+ & OneOf<{ formVersion: string }>
219
172
 
220
173
  export type PreviewModelServingResponse = {
221
- configuration?: ConfigurationPreview
222
- resolvedTemplate?: InferenceTemplateReference
223
- origin?: ModelServingOrigin
174
+ helmValues?: string
175
+ message?: string
224
176
  }
225
177
 
226
178
  export type CreateModelServingRequest = {
@@ -229,7 +181,9 @@ export type CreateModelServingRequest = {
229
181
  alias?: string
230
182
  cluster?: string
231
183
  namespace?: string
232
- configuration?: Configuration
184
+ modelConfiguration?: ModelConfiguration
185
+ formVersion?: string
186
+ form?: string
233
187
  origin?: ModelServingOrigin
234
188
  }
235
189
 
@@ -357,7 +311,7 @@ type BaseModelServingResource = {
357
311
  kind?: string
358
312
  namespace?: string
359
313
  name?: string
360
- status?: string
314
+ status?: HealthStatus
361
315
  message?: string
362
316
  }
363
317
 
@@ -391,22 +345,33 @@ export type GetModelServingResourceManifestResponse = {
391
345
  manifest?: string
392
346
  }
393
347
 
394
- export type UpdateModelServingRequest = {
348
+
349
+ type BaseUpdateModelServingRequest = {
395
350
  workspace?: number
396
351
  name?: string
397
352
  alias?: string
398
353
  resourceVersion?: string
354
+ modelConfiguration?: ModelConfiguration
399
355
  }
400
356
 
357
+ export type UpdateModelServingRequest = BaseUpdateModelServingRequest
358
+ & OneOf<{ form: string }>
359
+ & OneOf<{ formVersion: string }>
360
+
401
361
  export type DeleteModelServingRequest = {
402
362
  workspace?: number
403
363
  name?: string
404
364
  }
405
365
 
406
- export type ModelServingActionRequest = {
366
+ export type SyncModelServingRequest = {
367
+ workspace?: number
368
+ name?: string
369
+ resourceVersion?: string
370
+ }
371
+
372
+ export type TerminateModelServingOperationRequest = {
407
373
  workspace?: number
408
374
  name?: string
409
- action?: ModelServingAction
410
375
  resourceVersion?: string
411
376
  }
412
377
 
@@ -424,33 +389,101 @@ export type DeleteModelServingResponse = {
424
389
  updateTime?: GoogleProtobufTimestamp.Timestamp
425
390
  }
426
391
 
427
- export type ModelServingActionResponse = {
392
+ export type SyncModelServingResponse = {
428
393
  name?: string
429
394
  phase?: OperationPhase
430
395
  resourceVersion?: string
431
396
  updateTime?: GoogleProtobufTimestamp.Timestamp
432
397
  }
433
398
 
434
- export type UpdateModelServingConfigurationResponse = {
399
+ export type TerminateModelServingOperationResponse = {
435
400
  name?: string
436
401
  phase?: OperationPhase
437
402
  resourceVersion?: string
438
403
  updateTime?: GoogleProtobufTimestamp.Timestamp
439
404
  }
440
405
 
441
- export type GetModelServingConfigurationRequest = {
406
+ export type CreateModelServingJSONRequest = {
442
407
  workspace?: number
443
408
  name?: string
409
+ alias?: string
410
+ cluster?: string
411
+ namespace?: string
412
+ helmValues?: string
413
+ }
414
+
415
+ export type GetModelServingJSONRequest = {
416
+ workspace?: number
417
+ name?: string
418
+ }
419
+
420
+ export type GetModelServingJSONResponse = {
421
+ helmValues?: string
422
+ revision?: string
444
423
  }
445
424
 
446
- export type UpdateModelServingConfigurationRequest = {
425
+ export type UpdateModelServingJSONRequest = {
447
426
  workspace?: number
448
427
  name?: string
449
- configuration?: Configuration
428
+ helmValues?: string
450
429
  baseRevision?: string
451
430
  }
452
431
 
432
+ export type UpdateModelServingJSONResponse = {
433
+ name?: string
434
+ phase?: OperationPhase
435
+ resourceVersion?: string
436
+ updateTime?: GoogleProtobufTimestamp.Timestamp
437
+ }
438
+
439
+ export type GetModelServingFormUIRequest = {
440
+ workspace?: number
441
+ stack?: InferyCommonCommon.InferenceStack
442
+ disaggregationMode?: InferyCommonCommon.DisaggregationMode
443
+ version?: string
444
+ }
445
+
446
+ export type GetModelServingFormUIResponse = {
447
+ uiConfig?: string
448
+ version?: string
449
+ }
450
+
451
+
452
+ type BaseGetModelServingFormRequest = {
453
+ workspace?: number
454
+ stack?: InferyCommonCommon.InferenceStack
455
+ disaggregationMode?: InferyCommonCommon.DisaggregationMode
456
+ version?: string
457
+ }
458
+
459
+ export type GetModelServingFormRequest = BaseGetModelServingFormRequest
460
+ & OneOf<{ inferenceTemplateName: string; modelServingName: string }>
461
+
462
+ export type ModelServingFormInstance = {
463
+ modelConfiguration?: ModelConfiguration
464
+ name?: string
465
+ workspace?: number
466
+ alias?: string
467
+ cluster?: string
468
+ namespace?: string
469
+ resourceVersion?: string
470
+ origin?: ModelServingOrigin
471
+ }
472
+
473
+ export type GetModelServingFormResponse = {
474
+ form?: string
475
+ stack?: InferyCommonCommon.InferenceStack
476
+ disaggregationMode?: InferyCommonCommon.DisaggregationMode
477
+ version?: string
478
+ }
479
+
453
480
  export class ModelServingManagement {
481
+ static GetModelServingFormUI(req: GetModelServingFormUIRequest, initReq?: fm.InitReq): Promise<GetModelServingFormUIResponse> {
482
+ return fm.fetchReq<GetModelServingFormUIRequest, GetModelServingFormUIResponse>(`/apis/infery.io/v1alpha1/workspaces/${req["workspace"]}/model-serving-form?${fm.renderURLSearchParams(req, ["workspace"])}`, {...initReq, method: "GET"})
483
+ }
484
+ static GetModelServingForm(req: GetModelServingFormRequest, initReq?: fm.InitReq): Promise<GetModelServingFormResponse> {
485
+ return fm.fetchReq<GetModelServingFormRequest, GetModelServingFormResponse>(`/apis/infery.io/v1alpha1/workspaces/${req["workspace"]}/model-serving-form:values?${fm.renderURLSearchParams(req, ["workspace"])}`, {...initReq, method: "GET"})
486
+ }
454
487
  static PreviewModelServing(req: PreviewModelServingRequest, initReq?: fm.InitReq): Promise<PreviewModelServingResponse> {
455
488
  return fm.fetchReq<PreviewModelServingRequest, PreviewModelServingResponse>(`/apis/infery.io/v1alpha1/workspaces/${req["workspace"]}/model-serving/preview`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
456
489
  }
@@ -475,13 +508,19 @@ export class ModelServingManagement {
475
508
  static DeleteModelServing(req: DeleteModelServingRequest, initReq?: fm.InitReq): Promise<DeleteModelServingResponse> {
476
509
  return fm.fetchReq<DeleteModelServingRequest, DeleteModelServingResponse>(`/apis/infery.io/v1alpha1/workspaces/${req["workspace"]}/model-serving/${req["name"]}`, {...initReq, method: "DELETE"})
477
510
  }
478
- static DoModelServingAction(req: ModelServingActionRequest, initReq?: fm.InitReq): Promise<ModelServingActionResponse> {
479
- return fm.fetchReq<ModelServingActionRequest, ModelServingActionResponse>(`/apis/infery.io/v1alpha1/workspaces/${req["workspace"]}/model-serving/${req["name"]}/actions`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
511
+ static SyncModelServing(req: SyncModelServingRequest, initReq?: fm.InitReq): Promise<SyncModelServingResponse> {
512
+ return fm.fetchReq<SyncModelServingRequest, SyncModelServingResponse>(`/apis/infery.io/v1alpha1/workspaces/${req["workspace"]}/model-serving/${req["name"]}/sync`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
513
+ }
514
+ static TerminateModelServingOperation(req: TerminateModelServingOperationRequest, initReq?: fm.InitReq): Promise<TerminateModelServingOperationResponse> {
515
+ return fm.fetchReq<TerminateModelServingOperationRequest, TerminateModelServingOperationResponse>(`/apis/infery.io/v1alpha1/workspaces/${req["workspace"]}/model-serving/${req["name"]}/operation?${fm.renderURLSearchParams(req, ["workspace", "name"])}`, {...initReq, method: "DELETE"})
516
+ }
517
+ static CreateModelServingJSON(req: CreateModelServingJSONRequest, initReq?: fm.InitReq): Promise<CreateModelServingResponse> {
518
+ return fm.fetchReq<CreateModelServingJSONRequest, CreateModelServingResponse>(`/apis/infery.io/v1alpha1/workspaces/${req["workspace"]}/model-serving:json`, {...initReq, method: "POST", body: JSON.stringify(req, fm.replacer)})
480
519
  }
481
- static GetModelServingConfiguration(req: GetModelServingConfigurationRequest, initReq?: fm.InitReq): Promise<GetModelServingConfigurationResponse> {
482
- return fm.fetchReq<GetModelServingConfigurationRequest, GetModelServingConfigurationResponse>(`/apis/infery.io/v1alpha1/workspaces/${req["workspace"]}/model-serving/${req["name"]}/configuration?${fm.renderURLSearchParams(req, ["workspace", "name"])}`, {...initReq, method: "GET"})
520
+ static GetModelServingJSON(req: GetModelServingJSONRequest, initReq?: fm.InitReq): Promise<GetModelServingJSONResponse> {
521
+ return fm.fetchReq<GetModelServingJSONRequest, GetModelServingJSONResponse>(`/apis/infery.io/v1alpha1/workspaces/${req["workspace"]}/model-serving/${req["name"]}/json?${fm.renderURLSearchParams(req, ["workspace", "name"])}`, {...initReq, method: "GET"})
483
522
  }
484
- static UpdateModelServingConfiguration(req: UpdateModelServingConfigurationRequest, initReq?: fm.InitReq): Promise<UpdateModelServingConfigurationResponse> {
485
- return fm.fetchReq<UpdateModelServingConfigurationRequest, UpdateModelServingConfigurationResponse>(`/apis/infery.io/v1alpha1/workspaces/${req["workspace"]}/model-serving/${req["name"]}/configuration`, {...initReq, method: "PUT", body: JSON.stringify(req, fm.replacer)})
523
+ static UpdateModelServingJSON(req: UpdateModelServingJSONRequest, initReq?: fm.InitReq): Promise<UpdateModelServingJSONResponse> {
524
+ return fm.fetchReq<UpdateModelServingJSONRequest, UpdateModelServingJSONResponse>(`/apis/infery.io/v1alpha1/workspaces/${req["workspace"]}/model-serving/${req["name"]}/json`, {...initReq, method: "PUT", body: JSON.stringify(req, fm.replacer)})
486
525
  }
487
526
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@daocloud-proto/infery",
3
- "version": "v0.0.0-dev-0ec171e1",
3
+ "version": "v0.0.0-dev-6ba2995b",
4
4
  "description": "Infery frontend protobuf SDK",
5
5
  "license": "ISC"
6
6
  }