@gpuai/sdk 0.5.0 → 0.5.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/.openapi-generator/FILES +6 -0
- package/README.md +7 -2
- package/dist/apis/InferenceApi.d.ts +60 -0
- package/dist/apis/InferenceApi.js +126 -1
- package/dist/esm/apis/InferenceApi.d.ts +60 -0
- package/dist/esm/apis/InferenceApi.js +125 -0
- package/dist/esm/models/DataRetention.d.ts +51 -0
- package/dist/esm/models/DataRetention.js +57 -0
- package/dist/esm/models/Model.d.ts +6 -0
- package/dist/esm/models/Model.js +2 -0
- package/dist/esm/models/OfferingAlternative.d.ts +68 -0
- package/dist/esm/models/OfferingAlternative.js +67 -0
- package/dist/esm/models/OperationError.d.ts +20 -1
- package/dist/esm/models/OperationError.js +7 -0
- package/dist/esm/models/Problem.d.ts +1 -0
- package/dist/esm/models/Problem.js +1 -0
- package/dist/esm/models/UpdateDataRetentionRequest.d.ts +32 -0
- package/dist/esm/models/UpdateDataRetentionRequest.js +43 -0
- package/dist/esm/models/index.d.ts +3 -0
- package/dist/esm/models/index.js +3 -0
- package/dist/esm/runtime.js +1 -1
- package/dist/models/DataRetention.d.ts +51 -0
- package/dist/models/DataRetention.js +65 -0
- package/dist/models/Model.d.ts +6 -0
- package/dist/models/Model.js +2 -0
- package/dist/models/OfferingAlternative.d.ts +68 -0
- package/dist/models/OfferingAlternative.js +74 -0
- package/dist/models/OperationError.d.ts +20 -1
- package/dist/models/OperationError.js +7 -0
- package/dist/models/Problem.d.ts +1 -0
- package/dist/models/Problem.js +1 -0
- package/dist/models/UpdateDataRetentionRequest.d.ts +32 -0
- package/dist/models/UpdateDataRetentionRequest.js +50 -0
- package/dist/models/index.d.ts +3 -0
- package/dist/models/index.js +3 -0
- package/dist/runtime.js +1 -1
- package/docs/DataRetention.md +38 -0
- package/docs/FineTuningApi.md +2 -2
- package/docs/InferenceApi.md +163 -12
- package/docs/Model.md +2 -0
- package/docs/OfferingAlternative.md +47 -0
- package/docs/OperationError.md +6 -0
- package/docs/UpdateDataRetentionRequest.md +34 -0
- package/package.json +1 -1
- package/src/apis/InferenceApi.ts +162 -0
- package/src/models/DataRetention.ts +95 -0
- package/src/models/Model.ts +8 -0
- package/src/models/OfferingAlternative.ts +120 -0
- package/src/models/OperationError.ts +33 -1
- package/src/models/Problem.ts +1 -0
- package/src/models/UpdateDataRetentionRequest.ts +66 -0
- package/src/models/index.ts +3 -0
- package/src/runtime.ts +1 -1
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GPU.ai Public Developer API
|
|
3
|
+
* Programmatic API for GPU.ai. Authenticate with API keys minted from the dashboard. See https://gpu.ai/docs for details.
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
* Contact: support@gpu.ai
|
|
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 DataRetention
|
|
16
|
+
*/
|
|
17
|
+
export interface DataRetention {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {DataRetentionObjectEnum}
|
|
21
|
+
* @memberof DataRetention
|
|
22
|
+
*/
|
|
23
|
+
object: DataRetentionObjectEnum;
|
|
24
|
+
/**
|
|
25
|
+
* True when the org's inference requests route only to zero-data-retention model hosts.
|
|
26
|
+
* @type {boolean}
|
|
27
|
+
* @memberof DataRetention
|
|
28
|
+
*/
|
|
29
|
+
zeroDataRetention: boolean;
|
|
30
|
+
/**
|
|
31
|
+
* When the setting last changed; absent if it never has.
|
|
32
|
+
* @type {Date}
|
|
33
|
+
* @memberof DataRetention
|
|
34
|
+
*/
|
|
35
|
+
updatedAt?: Date;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* @export
|
|
39
|
+
*/
|
|
40
|
+
export declare const DataRetentionObjectEnum: {
|
|
41
|
+
readonly OrganizationDataRetention: "organization.data_retention";
|
|
42
|
+
};
|
|
43
|
+
export type DataRetentionObjectEnum = typeof DataRetentionObjectEnum[keyof typeof DataRetentionObjectEnum];
|
|
44
|
+
/**
|
|
45
|
+
* Check if a given object implements the DataRetention interface.
|
|
46
|
+
*/
|
|
47
|
+
export declare function instanceOfDataRetention(value: object): value is DataRetention;
|
|
48
|
+
export declare function DataRetentionFromJSON(json: any): DataRetention;
|
|
49
|
+
export declare function DataRetentionFromJSONTyped(json: any, ignoreDiscriminator: boolean): DataRetention;
|
|
50
|
+
export declare function DataRetentionToJSON(json: any): DataRetention;
|
|
51
|
+
export declare function DataRetentionToJSONTyped(value?: DataRetention | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* GPU.ai Public Developer API
|
|
5
|
+
* Programmatic API for GPU.ai. Authenticate with API keys minted from the dashboard. See https://gpu.ai/docs for details.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
* Contact: support@gpu.ai
|
|
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
|
+
* @export
|
|
16
|
+
*/
|
|
17
|
+
export const DataRetentionObjectEnum = {
|
|
18
|
+
OrganizationDataRetention: 'organization.data_retention'
|
|
19
|
+
};
|
|
20
|
+
/**
|
|
21
|
+
* Check if a given object implements the DataRetention interface.
|
|
22
|
+
*/
|
|
23
|
+
export function instanceOfDataRetention(value) {
|
|
24
|
+
if (!('object' in value) || value['object'] === undefined)
|
|
25
|
+
return false;
|
|
26
|
+
if (value['object'] !== 'organization.data_retention')
|
|
27
|
+
return false;
|
|
28
|
+
if ((!('zeroDataRetention' in value) && !('zero_data_retention' in value)) || (value['zeroDataRetention'] === undefined && value['zero_data_retention'] === undefined))
|
|
29
|
+
return false;
|
|
30
|
+
return true;
|
|
31
|
+
}
|
|
32
|
+
export function DataRetentionFromJSON(json) {
|
|
33
|
+
return DataRetentionFromJSONTyped(json, false);
|
|
34
|
+
}
|
|
35
|
+
export function DataRetentionFromJSONTyped(json, ignoreDiscriminator) {
|
|
36
|
+
if (json == null) {
|
|
37
|
+
return json;
|
|
38
|
+
}
|
|
39
|
+
return {
|
|
40
|
+
'object': json['object'],
|
|
41
|
+
'zeroDataRetention': json['zero_data_retention'],
|
|
42
|
+
'updatedAt': json['updated_at'] == null ? undefined : (new Date(json['updated_at'])),
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
export function DataRetentionToJSON(json) {
|
|
46
|
+
return DataRetentionToJSONTyped(json, false);
|
|
47
|
+
}
|
|
48
|
+
export function DataRetentionToJSONTyped(value, ignoreDiscriminator = false) {
|
|
49
|
+
if (value == null) {
|
|
50
|
+
return value;
|
|
51
|
+
}
|
|
52
|
+
return {
|
|
53
|
+
'object': value['object'],
|
|
54
|
+
'zero_data_retention': value['zeroDataRetention'],
|
|
55
|
+
'updated_at': value['updatedAt'] == null ? value['updatedAt'] : value['updatedAt'].toISOString(),
|
|
56
|
+
};
|
|
57
|
+
}
|
|
@@ -83,6 +83,12 @@ export interface Model {
|
|
|
83
83
|
* @memberof Model
|
|
84
84
|
*/
|
|
85
85
|
supportsStructuredOutputs?: boolean;
|
|
86
|
+
/**
|
|
87
|
+
* True when this model and tier can be served with zero data retention: at least one model host keeps no prompt or output content. Only these models are callable by an org with zero data retention on, or with the X-GPUAI-Zero-Data-Retention header. Always false for video.
|
|
88
|
+
* @type {boolean}
|
|
89
|
+
* @memberof Model
|
|
90
|
+
*/
|
|
91
|
+
zeroDataRetention?: boolean;
|
|
86
92
|
/**
|
|
87
93
|
* Typed parameter descriptors for media (image/video) models — name, type, enum/bounds/default. Playgrounds render input forms from these.
|
|
88
94
|
* @type {Array<ModelParametersInner>}
|
package/dist/esm/models/Model.js
CHANGED
|
@@ -75,6 +75,7 @@ export function ModelFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
75
75
|
'supportedParameters': json['supported_parameters'] == null ? undefined : json['supported_parameters'],
|
|
76
76
|
'supportsTools': json['supports_tools'] == null ? undefined : json['supports_tools'],
|
|
77
77
|
'supportsStructuredOutputs': json['supports_structured_outputs'] == null ? undefined : json['supports_structured_outputs'],
|
|
78
|
+
'zeroDataRetention': json['zero_data_retention'] == null ? undefined : json['zero_data_retention'],
|
|
78
79
|
'parameters': json['parameters'] == null ? undefined : (json['parameters'].map(ModelParametersInnerFromJSON)),
|
|
79
80
|
'pricing': ModelPricingFromJSON(json['pricing']),
|
|
80
81
|
'aliases': json['aliases'] == null ? undefined : json['aliases'],
|
|
@@ -102,6 +103,7 @@ export function ModelToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
102
103
|
'supported_parameters': value['supportedParameters'],
|
|
103
104
|
'supports_tools': value['supportsTools'],
|
|
104
105
|
'supports_structured_outputs': value['supportsStructuredOutputs'],
|
|
106
|
+
'zero_data_retention': value['zeroDataRetention'],
|
|
105
107
|
'parameters': value['parameters'] == null ? undefined : (value['parameters'].map(ModelParametersInnerToJSON)),
|
|
106
108
|
'pricing': ModelPricingToJSON(value['pricing']),
|
|
107
109
|
'aliases': value['aliases'],
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GPU.ai Public Developer API
|
|
3
|
+
* Programmatic API for GPU.ai. Authenticate with API keys minted from the dashboard. See https://gpu.ai/docs for details.
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
* Contact: support@gpu.ai
|
|
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
|
+
* A live catalog row a launch whose pinned offering was gone could take instead. Same fields and meaning as the matching GET /pricing row.
|
|
14
|
+
* @export
|
|
15
|
+
* @interface OfferingAlternative
|
|
16
|
+
*/
|
|
17
|
+
export interface OfferingAlternative {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof OfferingAlternative
|
|
22
|
+
*/
|
|
23
|
+
offeringId: string;
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @type {string}
|
|
27
|
+
* @memberof OfferingAlternative
|
|
28
|
+
*/
|
|
29
|
+
gpuType: string;
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {number}
|
|
33
|
+
* @memberof OfferingAlternative
|
|
34
|
+
*/
|
|
35
|
+
gpuCount: number;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @type {string}
|
|
39
|
+
* @memberof OfferingAlternative
|
|
40
|
+
*/
|
|
41
|
+
region: string;
|
|
42
|
+
/**
|
|
43
|
+
*
|
|
44
|
+
* @type {string}
|
|
45
|
+
* @memberof OfferingAlternative
|
|
46
|
+
*/
|
|
47
|
+
tier: string;
|
|
48
|
+
/**
|
|
49
|
+
*
|
|
50
|
+
* @type {number}
|
|
51
|
+
* @memberof OfferingAlternative
|
|
52
|
+
*/
|
|
53
|
+
pricePerHour: number;
|
|
54
|
+
/**
|
|
55
|
+
*
|
|
56
|
+
* @type {number}
|
|
57
|
+
* @memberof OfferingAlternative
|
|
58
|
+
*/
|
|
59
|
+
available: number;
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* Check if a given object implements the OfferingAlternative interface.
|
|
63
|
+
*/
|
|
64
|
+
export declare function instanceOfOfferingAlternative(value: object): value is OfferingAlternative;
|
|
65
|
+
export declare function OfferingAlternativeFromJSON(json: any): OfferingAlternative;
|
|
66
|
+
export declare function OfferingAlternativeFromJSONTyped(json: any, ignoreDiscriminator: boolean): OfferingAlternative;
|
|
67
|
+
export declare function OfferingAlternativeToJSON(json: any): OfferingAlternative;
|
|
68
|
+
export declare function OfferingAlternativeToJSONTyped(value?: OfferingAlternative | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* GPU.ai Public Developer API
|
|
5
|
+
* Programmatic API for GPU.ai. Authenticate with API keys minted from the dashboard. See https://gpu.ai/docs for details.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
* Contact: support@gpu.ai
|
|
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
|
+
* Check if a given object implements the OfferingAlternative interface.
|
|
16
|
+
*/
|
|
17
|
+
export function instanceOfOfferingAlternative(value) {
|
|
18
|
+
if ((!('offeringId' in value) && !('offering_id' in value)) || (value['offeringId'] === undefined && value['offering_id'] === undefined))
|
|
19
|
+
return false;
|
|
20
|
+
if ((!('gpuType' in value) && !('gpu_type' in value)) || (value['gpuType'] === undefined && value['gpu_type'] === undefined))
|
|
21
|
+
return false;
|
|
22
|
+
if ((!('gpuCount' in value) && !('gpu_count' in value)) || (value['gpuCount'] === undefined && value['gpu_count'] === undefined))
|
|
23
|
+
return false;
|
|
24
|
+
if (!('region' in value) || value['region'] === undefined)
|
|
25
|
+
return false;
|
|
26
|
+
if (!('tier' in value) || value['tier'] === undefined)
|
|
27
|
+
return false;
|
|
28
|
+
if ((!('pricePerHour' in value) && !('price_per_hour' in value)) || (value['pricePerHour'] === undefined && value['price_per_hour'] === undefined))
|
|
29
|
+
return false;
|
|
30
|
+
if (!('available' in value) || value['available'] === undefined)
|
|
31
|
+
return false;
|
|
32
|
+
return true;
|
|
33
|
+
}
|
|
34
|
+
export function OfferingAlternativeFromJSON(json) {
|
|
35
|
+
return OfferingAlternativeFromJSONTyped(json, false);
|
|
36
|
+
}
|
|
37
|
+
export function OfferingAlternativeFromJSONTyped(json, ignoreDiscriminator) {
|
|
38
|
+
if (json == null) {
|
|
39
|
+
return json;
|
|
40
|
+
}
|
|
41
|
+
return {
|
|
42
|
+
'offeringId': json['offering_id'],
|
|
43
|
+
'gpuType': json['gpu_type'],
|
|
44
|
+
'gpuCount': json['gpu_count'],
|
|
45
|
+
'region': json['region'],
|
|
46
|
+
'tier': json['tier'],
|
|
47
|
+
'pricePerHour': json['price_per_hour'],
|
|
48
|
+
'available': json['available'],
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
export function OfferingAlternativeToJSON(json) {
|
|
52
|
+
return OfferingAlternativeToJSONTyped(json, false);
|
|
53
|
+
}
|
|
54
|
+
export function OfferingAlternativeToJSONTyped(value, ignoreDiscriminator = false) {
|
|
55
|
+
if (value == null) {
|
|
56
|
+
return value;
|
|
57
|
+
}
|
|
58
|
+
return {
|
|
59
|
+
'offering_id': value['offeringId'],
|
|
60
|
+
'gpu_type': value['gpuType'],
|
|
61
|
+
'gpu_count': value['gpuCount'],
|
|
62
|
+
'region': value['region'],
|
|
63
|
+
'tier': value['tier'],
|
|
64
|
+
'price_per_hour': value['pricePerHour'],
|
|
65
|
+
'available': value['available'],
|
|
66
|
+
};
|
|
67
|
+
}
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
* https://openapi-generator.tech
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
|
+
import type { OfferingAlternative } from './OfferingAlternative';
|
|
12
13
|
/**
|
|
13
14
|
*
|
|
14
15
|
* @export
|
|
@@ -16,7 +17,7 @@
|
|
|
16
17
|
*/
|
|
17
18
|
export interface OperationError {
|
|
18
19
|
/**
|
|
19
|
-
*
|
|
20
|
+
* Stable machine-readable failure code (see Problem.code), for example operation_failed (retryable after a backoff), price_changed or offering_unavailable (not retryable as sent).
|
|
20
21
|
* @type {string}
|
|
21
22
|
* @memberof OperationError
|
|
22
23
|
*/
|
|
@@ -27,6 +28,24 @@ export interface OperationError {
|
|
|
27
28
|
* @memberof OperationError
|
|
28
29
|
*/
|
|
29
30
|
detail?: string;
|
|
31
|
+
/**
|
|
32
|
+
* Present only when code is offering_unavailable: up to three live catalog rows of the same GPU type, count and tier, cheapest first. Pass one's offering_id as the new pin.
|
|
33
|
+
* @type {Array<OfferingAlternative>}
|
|
34
|
+
* @memberof OperationError
|
|
35
|
+
*/
|
|
36
|
+
alternatives?: Array<OfferingAlternative>;
|
|
37
|
+
/**
|
|
38
|
+
* Present only when code is price_changed: the live hourly price the launch found.
|
|
39
|
+
* @type {number}
|
|
40
|
+
* @memberof OperationError
|
|
41
|
+
*/
|
|
42
|
+
currentPricePerHour?: number;
|
|
43
|
+
/**
|
|
44
|
+
* Present only when code is price_changed: the hourly price the launch was approved at (max_price_per_hour, or the viewed price). Relaunch with max_price_per_hour of at least current_price_per_hour to accept the new price.
|
|
45
|
+
* @type {number}
|
|
46
|
+
* @memberof OperationError
|
|
47
|
+
*/
|
|
48
|
+
maxPricePerHour?: number;
|
|
30
49
|
}
|
|
31
50
|
/**
|
|
32
51
|
* Check if a given object implements the OperationError interface.
|
|
@@ -11,6 +11,7 @@
|
|
|
11
11
|
* https://openapi-generator.tech
|
|
12
12
|
* Do not edit the class manually.
|
|
13
13
|
*/
|
|
14
|
+
import { OfferingAlternativeFromJSON, OfferingAlternativeToJSON, } from './OfferingAlternative';
|
|
14
15
|
/**
|
|
15
16
|
* Check if a given object implements the OperationError interface.
|
|
16
17
|
*/
|
|
@@ -27,6 +28,9 @@ export function OperationErrorFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
27
28
|
return {
|
|
28
29
|
'code': json['code'] == null ? undefined : json['code'],
|
|
29
30
|
'detail': json['detail'] == null ? undefined : json['detail'],
|
|
31
|
+
'alternatives': json['alternatives'] == null ? undefined : (json['alternatives'].map(OfferingAlternativeFromJSON)),
|
|
32
|
+
'currentPricePerHour': json['current_price_per_hour'] == null ? undefined : json['current_price_per_hour'],
|
|
33
|
+
'maxPricePerHour': json['max_price_per_hour'] == null ? undefined : json['max_price_per_hour'],
|
|
30
34
|
};
|
|
31
35
|
}
|
|
32
36
|
export function OperationErrorToJSON(json) {
|
|
@@ -39,5 +43,8 @@ export function OperationErrorToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
39
43
|
return {
|
|
40
44
|
'code': value['code'],
|
|
41
45
|
'detail': value['detail'],
|
|
46
|
+
'alternatives': value['alternatives'] == null ? undefined : (value['alternatives'].map(OfferingAlternativeToJSON)),
|
|
47
|
+
'current_price_per_hour': value['currentPricePerHour'],
|
|
48
|
+
'max_price_per_hour': value['maxPricePerHour'],
|
|
42
49
|
};
|
|
43
50
|
}
|
|
@@ -69,6 +69,7 @@ export declare const ProblemCodeEnum: {
|
|
|
69
69
|
readonly ModelTooLarge: "model_too_large";
|
|
70
70
|
readonly GpuVramTooSmall: "gpu_vram_too_small";
|
|
71
71
|
readonly PriceChanged: "price_changed";
|
|
72
|
+
readonly OfferingUnavailable: "offering_unavailable";
|
|
72
73
|
readonly DedicatedIpLimit: "dedicated_ip_limit";
|
|
73
74
|
readonly DedicatedIpUnavailable: "dedicated_ip_unavailable";
|
|
74
75
|
readonly InsufficientBalance: "insufficient_balance";
|
|
@@ -28,6 +28,7 @@ export const ProblemCodeEnum = {
|
|
|
28
28
|
ModelTooLarge: 'model_too_large',
|
|
29
29
|
GpuVramTooSmall: 'gpu_vram_too_small',
|
|
30
30
|
PriceChanged: 'price_changed',
|
|
31
|
+
OfferingUnavailable: 'offering_unavailable',
|
|
31
32
|
DedicatedIpLimit: 'dedicated_ip_limit',
|
|
32
33
|
DedicatedIpUnavailable: 'dedicated_ip_unavailable',
|
|
33
34
|
InsufficientBalance: 'insufficient_balance',
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GPU.ai Public Developer API
|
|
3
|
+
* Programmatic API for GPU.ai. Authenticate with API keys minted from the dashboard. See https://gpu.ai/docs for details.
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
* Contact: support@gpu.ai
|
|
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 UpdateDataRetentionRequest
|
|
16
|
+
*/
|
|
17
|
+
export interface UpdateDataRetentionRequest {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {boolean}
|
|
21
|
+
* @memberof UpdateDataRetentionRequest
|
|
22
|
+
*/
|
|
23
|
+
zeroDataRetention: boolean;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Check if a given object implements the UpdateDataRetentionRequest interface.
|
|
27
|
+
*/
|
|
28
|
+
export declare function instanceOfUpdateDataRetentionRequest(value: object): value is UpdateDataRetentionRequest;
|
|
29
|
+
export declare function UpdateDataRetentionRequestFromJSON(json: any): UpdateDataRetentionRequest;
|
|
30
|
+
export declare function UpdateDataRetentionRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): UpdateDataRetentionRequest;
|
|
31
|
+
export declare function UpdateDataRetentionRequestToJSON(json: any): UpdateDataRetentionRequest;
|
|
32
|
+
export declare function UpdateDataRetentionRequestToJSONTyped(value?: UpdateDataRetentionRequest | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* GPU.ai Public Developer API
|
|
5
|
+
* Programmatic API for GPU.ai. Authenticate with API keys minted from the dashboard. See https://gpu.ai/docs for details.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
* Contact: support@gpu.ai
|
|
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
|
+
* Check if a given object implements the UpdateDataRetentionRequest interface.
|
|
16
|
+
*/
|
|
17
|
+
export function instanceOfUpdateDataRetentionRequest(value) {
|
|
18
|
+
if ((!('zeroDataRetention' in value) && !('zero_data_retention' in value)) || (value['zeroDataRetention'] === undefined && value['zero_data_retention'] === undefined))
|
|
19
|
+
return false;
|
|
20
|
+
return true;
|
|
21
|
+
}
|
|
22
|
+
export function UpdateDataRetentionRequestFromJSON(json) {
|
|
23
|
+
return UpdateDataRetentionRequestFromJSONTyped(json, false);
|
|
24
|
+
}
|
|
25
|
+
export function UpdateDataRetentionRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
26
|
+
if (json == null) {
|
|
27
|
+
return json;
|
|
28
|
+
}
|
|
29
|
+
return {
|
|
30
|
+
'zeroDataRetention': json['zero_data_retention'],
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
export function UpdateDataRetentionRequestToJSON(json) {
|
|
34
|
+
return UpdateDataRetentionRequestToJSONTyped(json, false);
|
|
35
|
+
}
|
|
36
|
+
export function UpdateDataRetentionRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
37
|
+
if (value == null) {
|
|
38
|
+
return value;
|
|
39
|
+
}
|
|
40
|
+
return {
|
|
41
|
+
'zero_data_retention': value['zeroDataRetention'],
|
|
42
|
+
};
|
|
43
|
+
}
|
|
@@ -35,6 +35,7 @@ export * from './CreateRegistryCredentialRequest';
|
|
|
35
35
|
export * from './CreateSshKeyRequest';
|
|
36
36
|
export * from './CreateWebhookEndpointRequest';
|
|
37
37
|
export * from './CryptoDeposit';
|
|
38
|
+
export * from './DataRetention';
|
|
38
39
|
export * from './DedicatedIPRequest';
|
|
39
40
|
export * from './Embedding';
|
|
40
41
|
export * from './EmbeddingsRequest';
|
|
@@ -88,6 +89,7 @@ export * from './ModelList';
|
|
|
88
89
|
export * from './ModelParametersInner';
|
|
89
90
|
export * from './ModelPricing';
|
|
90
91
|
export * from './ModelRate';
|
|
92
|
+
export * from './OfferingAlternative';
|
|
91
93
|
export * from './OpenAIErrorEnvelope';
|
|
92
94
|
export * from './OpenAIErrorEnvelopeError';
|
|
93
95
|
export * from './Operation';
|
|
@@ -109,6 +111,7 @@ export * from './TemplateEnvInner';
|
|
|
109
111
|
export * from './TemplateList';
|
|
110
112
|
export * from './TemplatePortsInner';
|
|
111
113
|
export * from './UpdateBillingDetailsRequest';
|
|
114
|
+
export * from './UpdateDataRetentionRequest';
|
|
112
115
|
export * from './UpdateInstanceRequest';
|
|
113
116
|
export * from './UpdateSpendingLimitRequest';
|
|
114
117
|
export * from './Usage';
|
package/dist/esm/models/index.js
CHANGED
|
@@ -37,6 +37,7 @@ export * from './CreateRegistryCredentialRequest';
|
|
|
37
37
|
export * from './CreateSshKeyRequest';
|
|
38
38
|
export * from './CreateWebhookEndpointRequest';
|
|
39
39
|
export * from './CryptoDeposit';
|
|
40
|
+
export * from './DataRetention';
|
|
40
41
|
export * from './DedicatedIPRequest';
|
|
41
42
|
export * from './Embedding';
|
|
42
43
|
export * from './EmbeddingsRequest';
|
|
@@ -90,6 +91,7 @@ export * from './ModelList';
|
|
|
90
91
|
export * from './ModelParametersInner';
|
|
91
92
|
export * from './ModelPricing';
|
|
92
93
|
export * from './ModelRate';
|
|
94
|
+
export * from './OfferingAlternative';
|
|
93
95
|
export * from './OpenAIErrorEnvelope';
|
|
94
96
|
export * from './OpenAIErrorEnvelopeError';
|
|
95
97
|
export * from './Operation';
|
|
@@ -111,6 +113,7 @@ export * from './TemplateEnvInner';
|
|
|
111
113
|
export * from './TemplateList';
|
|
112
114
|
export * from './TemplatePortsInner';
|
|
113
115
|
export * from './UpdateBillingDetailsRequest';
|
|
116
|
+
export * from './UpdateDataRetentionRequest';
|
|
114
117
|
export * from './UpdateInstanceRequest';
|
|
115
118
|
export * from './UpdateSpendingLimitRequest';
|
|
116
119
|
export * from './Usage';
|
package/dist/esm/runtime.js
CHANGED
|
@@ -61,7 +61,7 @@ export class Configuration {
|
|
|
61
61
|
return undefined;
|
|
62
62
|
}
|
|
63
63
|
get headers() {
|
|
64
|
-
return Object.assign({ 'User-Agent': 'gpuai-sdk-ts/0.5.
|
|
64
|
+
return Object.assign({ 'User-Agent': 'gpuai-sdk-ts/0.5.2' }, this.configuration.headers);
|
|
65
65
|
}
|
|
66
66
|
get credentials() {
|
|
67
67
|
return this.configuration.credentials;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GPU.ai Public Developer API
|
|
3
|
+
* Programmatic API for GPU.ai. Authenticate with API keys minted from the dashboard. See https://gpu.ai/docs for details.
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
* Contact: support@gpu.ai
|
|
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 DataRetention
|
|
16
|
+
*/
|
|
17
|
+
export interface DataRetention {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {DataRetentionObjectEnum}
|
|
21
|
+
* @memberof DataRetention
|
|
22
|
+
*/
|
|
23
|
+
object: DataRetentionObjectEnum;
|
|
24
|
+
/**
|
|
25
|
+
* True when the org's inference requests route only to zero-data-retention model hosts.
|
|
26
|
+
* @type {boolean}
|
|
27
|
+
* @memberof DataRetention
|
|
28
|
+
*/
|
|
29
|
+
zeroDataRetention: boolean;
|
|
30
|
+
/**
|
|
31
|
+
* When the setting last changed; absent if it never has.
|
|
32
|
+
* @type {Date}
|
|
33
|
+
* @memberof DataRetention
|
|
34
|
+
*/
|
|
35
|
+
updatedAt?: Date;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* @export
|
|
39
|
+
*/
|
|
40
|
+
export declare const DataRetentionObjectEnum: {
|
|
41
|
+
readonly OrganizationDataRetention: "organization.data_retention";
|
|
42
|
+
};
|
|
43
|
+
export type DataRetentionObjectEnum = typeof DataRetentionObjectEnum[keyof typeof DataRetentionObjectEnum];
|
|
44
|
+
/**
|
|
45
|
+
* Check if a given object implements the DataRetention interface.
|
|
46
|
+
*/
|
|
47
|
+
export declare function instanceOfDataRetention(value: object): value is DataRetention;
|
|
48
|
+
export declare function DataRetentionFromJSON(json: any): DataRetention;
|
|
49
|
+
export declare function DataRetentionFromJSONTyped(json: any, ignoreDiscriminator: boolean): DataRetention;
|
|
50
|
+
export declare function DataRetentionToJSON(json: any): DataRetention;
|
|
51
|
+
export declare function DataRetentionToJSONTyped(value?: DataRetention | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* GPU.ai Public Developer API
|
|
6
|
+
* Programmatic API for GPU.ai. Authenticate with API keys minted from the dashboard. See https://gpu.ai/docs for details.
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
* Contact: support@gpu.ai
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.DataRetentionObjectEnum = void 0;
|
|
17
|
+
exports.instanceOfDataRetention = instanceOfDataRetention;
|
|
18
|
+
exports.DataRetentionFromJSON = DataRetentionFromJSON;
|
|
19
|
+
exports.DataRetentionFromJSONTyped = DataRetentionFromJSONTyped;
|
|
20
|
+
exports.DataRetentionToJSON = DataRetentionToJSON;
|
|
21
|
+
exports.DataRetentionToJSONTyped = DataRetentionToJSONTyped;
|
|
22
|
+
/**
|
|
23
|
+
* @export
|
|
24
|
+
*/
|
|
25
|
+
exports.DataRetentionObjectEnum = {
|
|
26
|
+
OrganizationDataRetention: 'organization.data_retention'
|
|
27
|
+
};
|
|
28
|
+
/**
|
|
29
|
+
* Check if a given object implements the DataRetention interface.
|
|
30
|
+
*/
|
|
31
|
+
function instanceOfDataRetention(value) {
|
|
32
|
+
if (!('object' in value) || value['object'] === undefined)
|
|
33
|
+
return false;
|
|
34
|
+
if (value['object'] !== 'organization.data_retention')
|
|
35
|
+
return false;
|
|
36
|
+
if ((!('zeroDataRetention' in value) && !('zero_data_retention' in value)) || (value['zeroDataRetention'] === undefined && value['zero_data_retention'] === undefined))
|
|
37
|
+
return false;
|
|
38
|
+
return true;
|
|
39
|
+
}
|
|
40
|
+
function DataRetentionFromJSON(json) {
|
|
41
|
+
return DataRetentionFromJSONTyped(json, false);
|
|
42
|
+
}
|
|
43
|
+
function DataRetentionFromJSONTyped(json, ignoreDiscriminator) {
|
|
44
|
+
if (json == null) {
|
|
45
|
+
return json;
|
|
46
|
+
}
|
|
47
|
+
return {
|
|
48
|
+
'object': json['object'],
|
|
49
|
+
'zeroDataRetention': json['zero_data_retention'],
|
|
50
|
+
'updatedAt': json['updated_at'] == null ? undefined : (new Date(json['updated_at'])),
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
function DataRetentionToJSON(json) {
|
|
54
|
+
return DataRetentionToJSONTyped(json, false);
|
|
55
|
+
}
|
|
56
|
+
function DataRetentionToJSONTyped(value, ignoreDiscriminator = false) {
|
|
57
|
+
if (value == null) {
|
|
58
|
+
return value;
|
|
59
|
+
}
|
|
60
|
+
return {
|
|
61
|
+
'object': value['object'],
|
|
62
|
+
'zero_data_retention': value['zeroDataRetention'],
|
|
63
|
+
'updated_at': value['updatedAt'] == null ? value['updatedAt'] : value['updatedAt'].toISOString(),
|
|
64
|
+
};
|
|
65
|
+
}
|
package/dist/models/Model.d.ts
CHANGED
|
@@ -83,6 +83,12 @@ export interface Model {
|
|
|
83
83
|
* @memberof Model
|
|
84
84
|
*/
|
|
85
85
|
supportsStructuredOutputs?: boolean;
|
|
86
|
+
/**
|
|
87
|
+
* True when this model and tier can be served with zero data retention: at least one model host keeps no prompt or output content. Only these models are callable by an org with zero data retention on, or with the X-GPUAI-Zero-Data-Retention header. Always false for video.
|
|
88
|
+
* @type {boolean}
|
|
89
|
+
* @memberof Model
|
|
90
|
+
*/
|
|
91
|
+
zeroDataRetention?: boolean;
|
|
86
92
|
/**
|
|
87
93
|
* Typed parameter descriptors for media (image/video) models — name, type, enum/bounds/default. Playgrounds render input forms from these.
|
|
88
94
|
* @type {Array<ModelParametersInner>}
|
package/dist/models/Model.js
CHANGED
|
@@ -83,6 +83,7 @@ function ModelFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
83
83
|
'supportedParameters': json['supported_parameters'] == null ? undefined : json['supported_parameters'],
|
|
84
84
|
'supportsTools': json['supports_tools'] == null ? undefined : json['supports_tools'],
|
|
85
85
|
'supportsStructuredOutputs': json['supports_structured_outputs'] == null ? undefined : json['supports_structured_outputs'],
|
|
86
|
+
'zeroDataRetention': json['zero_data_retention'] == null ? undefined : json['zero_data_retention'],
|
|
86
87
|
'parameters': json['parameters'] == null ? undefined : (json['parameters'].map(ModelParametersInner_1.ModelParametersInnerFromJSON)),
|
|
87
88
|
'pricing': (0, ModelPricing_1.ModelPricingFromJSON)(json['pricing']),
|
|
88
89
|
'aliases': json['aliases'] == null ? undefined : json['aliases'],
|
|
@@ -110,6 +111,7 @@ function ModelToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
110
111
|
'supported_parameters': value['supportedParameters'],
|
|
111
112
|
'supports_tools': value['supportsTools'],
|
|
112
113
|
'supports_structured_outputs': value['supportsStructuredOutputs'],
|
|
114
|
+
'zero_data_retention': value['zeroDataRetention'],
|
|
113
115
|
'parameters': value['parameters'] == null ? undefined : (value['parameters'].map(ModelParametersInner_1.ModelParametersInnerToJSON)),
|
|
114
116
|
'pricing': (0, ModelPricing_1.ModelPricingToJSON)(value['pricing']),
|
|
115
117
|
'aliases': value['aliases'],
|