@gpuai/sdk 0.3.12 → 0.3.14
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 +36 -0
- package/README.md +38 -9
- package/dist/apis/AutolaunchApi.d.ts +109 -0
- package/dist/apis/AutolaunchApi.js +286 -0
- package/dist/apis/InferenceApi.d.ts +19 -0
- package/dist/apis/InferenceApi.js +51 -0
- package/dist/apis/MarketApi.d.ts +56 -0
- package/dist/apis/MarketApi.js +112 -0
- package/dist/apis/WatchApi.d.ts +109 -0
- package/dist/apis/WatchApi.js +286 -0
- package/dist/apis/index.d.ts +3 -0
- package/dist/apis/index.js +3 -0
- package/dist/esm/apis/AutolaunchApi.d.ts +109 -0
- package/dist/esm/apis/AutolaunchApi.js +282 -0
- package/dist/esm/apis/InferenceApi.d.ts +19 -0
- package/dist/esm/apis/InferenceApi.js +51 -0
- package/dist/esm/apis/MarketApi.d.ts +56 -0
- package/dist/esm/apis/MarketApi.js +108 -0
- package/dist/esm/apis/WatchApi.d.ts +109 -0
- package/dist/esm/apis/WatchApi.js +282 -0
- package/dist/esm/apis/index.d.ts +3 -0
- package/dist/esm/apis/index.js +3 -0
- package/dist/esm/models/AutolaunchRule.d.ts +181 -0
- package/dist/esm/models/AutolaunchRule.js +142 -0
- package/dist/esm/models/AutolaunchRuleCreate.d.ts +105 -0
- package/dist/esm/models/AutolaunchRuleCreate.js +84 -0
- package/dist/esm/models/AutolaunchRuleDisarm.d.ts +34 -0
- package/dist/esm/models/AutolaunchRuleDisarm.js +43 -0
- package/dist/esm/models/AutolaunchRulePage.d.ts +39 -0
- package/dist/esm/models/AutolaunchRulePage.js +48 -0
- package/dist/esm/models/Embedding.d.ts +51 -0
- package/dist/esm/models/Embedding.js +59 -0
- package/dist/esm/models/EmbeddingsRequest.d.ts +64 -0
- package/dist/esm/models/EmbeddingsRequest.js +60 -0
- package/dist/esm/models/EmbeddingsRequestInput.d.ts +21 -0
- package/dist/esm/models/EmbeddingsRequestInput.js +47 -0
- package/dist/esm/models/EmbeddingsResponse.d.ts +59 -0
- package/dist/esm/models/EmbeddingsResponse.js +65 -0
- package/dist/esm/models/EmbeddingsUsage.d.ts +38 -0
- package/dist/esm/models/EmbeddingsUsage.js +47 -0
- package/dist/esm/models/MarketHistoryPoint.d.ts +59 -0
- package/dist/esm/models/MarketHistoryPoint.js +55 -0
- package/dist/esm/models/MarketHistoryResponse.d.ts +60 -0
- package/dist/esm/models/MarketHistoryResponse.js +60 -0
- package/dist/esm/models/Problem.d.ts +1 -0
- package/dist/esm/models/Problem.js +1 -0
- package/dist/esm/models/WatchRule.d.ts +141 -0
- package/dist/esm/models/WatchRule.js +117 -0
- package/dist/esm/models/WatchRuleCreate.d.ts +87 -0
- package/dist/esm/models/WatchRuleCreate.js +72 -0
- package/dist/esm/models/WatchRulePage.d.ts +39 -0
- package/dist/esm/models/WatchRulePage.js +48 -0
- package/dist/esm/models/WatchRuleUpdate.d.ts +86 -0
- package/dist/esm/models/WatchRuleUpdate.js +68 -0
- package/dist/esm/models/index.d.ts +15 -0
- package/dist/esm/models/index.js +15 -0
- package/dist/models/AutolaunchRule.d.ts +181 -0
- package/dist/models/AutolaunchRule.js +150 -0
- package/dist/models/AutolaunchRuleCreate.d.ts +105 -0
- package/dist/models/AutolaunchRuleCreate.js +92 -0
- package/dist/models/AutolaunchRuleDisarm.d.ts +34 -0
- package/dist/models/AutolaunchRuleDisarm.js +50 -0
- package/dist/models/AutolaunchRulePage.d.ts +39 -0
- package/dist/models/AutolaunchRulePage.js +55 -0
- package/dist/models/Embedding.d.ts +51 -0
- package/dist/models/Embedding.js +67 -0
- package/dist/models/EmbeddingsRequest.d.ts +64 -0
- package/dist/models/EmbeddingsRequest.js +68 -0
- package/dist/models/EmbeddingsRequestInput.d.ts +21 -0
- package/dist/models/EmbeddingsRequestInput.js +53 -0
- package/dist/models/EmbeddingsResponse.d.ts +59 -0
- package/dist/models/EmbeddingsResponse.js +73 -0
- package/dist/models/EmbeddingsUsage.d.ts +38 -0
- package/dist/models/EmbeddingsUsage.js +54 -0
- package/dist/models/MarketHistoryPoint.d.ts +59 -0
- package/dist/models/MarketHistoryPoint.js +62 -0
- package/dist/models/MarketHistoryResponse.d.ts +60 -0
- package/dist/models/MarketHistoryResponse.js +67 -0
- package/dist/models/Problem.d.ts +1 -0
- package/dist/models/Problem.js +1 -0
- package/dist/models/WatchRule.d.ts +141 -0
- package/dist/models/WatchRule.js +125 -0
- package/dist/models/WatchRuleCreate.d.ts +87 -0
- package/dist/models/WatchRuleCreate.js +80 -0
- package/dist/models/WatchRulePage.d.ts +39 -0
- package/dist/models/WatchRulePage.js +55 -0
- package/dist/models/WatchRuleUpdate.d.ts +86 -0
- package/dist/models/WatchRuleUpdate.js +76 -0
- package/dist/models/index.d.ts +15 -0
- package/dist/models/index.js +15 -0
- package/docs/AutolaunchApi.md +390 -0
- package/docs/AutolaunchRule.md +69 -0
- package/docs/AutolaunchRuleCreate.md +50 -0
- package/docs/AutolaunchRuleDisarm.md +35 -0
- package/docs/AutolaunchRulePage.md +36 -0
- package/docs/Embedding.md +38 -0
- package/docs/EmbeddingsRequest.md +42 -0
- package/docs/EmbeddingsRequestInput.md +33 -0
- package/docs/EmbeddingsResponse.md +40 -0
- package/docs/EmbeddingsUsage.md +37 -0
- package/docs/InferenceApi.md +83 -0
- package/docs/MarketApi.md +98 -0
- package/docs/MarketHistoryPoint.md +43 -0
- package/docs/MarketHistoryResponse.md +43 -0
- package/docs/WatchApi.md +389 -0
- package/docs/WatchRule.md +61 -0
- package/docs/WatchRuleCreate.md +46 -0
- package/docs/WatchRulePage.md +36 -0
- package/docs/WatchRuleUpdate.md +47 -0
- package/package.json +1 -1
- package/src/apis/AutolaunchApi.ts +360 -0
- package/src/apis/InferenceApi.ts +71 -0
- package/src/apis/MarketApi.ts +136 -0
- package/src/apis/WatchApi.ts +360 -0
- package/src/apis/index.ts +3 -0
- package/src/models/AutolaunchRule.ts +270 -0
- package/src/models/AutolaunchRuleCreate.ts +162 -0
- package/src/models/AutolaunchRuleDisarm.ts +68 -0
- package/src/models/AutolaunchRulePage.ts +83 -0
- package/src/models/Embedding.ts +96 -0
- package/src/models/EmbeddingsRequest.ts +117 -0
- package/src/models/EmbeddingsRequestInput.ts +59 -0
- package/src/models/EmbeddingsResponse.ts +120 -0
- package/src/models/EmbeddingsUsage.ts +75 -0
- package/src/models/MarketHistoryPoint.ts +103 -0
- package/src/models/MarketHistoryResponse.ts +113 -0
- package/src/models/Problem.ts +1 -0
- package/src/models/WatchRule.ts +219 -0
- package/src/models/WatchRuleCreate.ts +138 -0
- package/src/models/WatchRulePage.ts +83 -0
- package/src/models/WatchRuleUpdate.ts +135 -0
- package/src/models/index.ts +15 -0
|
@@ -0,0 +1,50 @@
|
|
|
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.instanceOfAutolaunchRuleDisarm = instanceOfAutolaunchRuleDisarm;
|
|
17
|
+
exports.AutolaunchRuleDisarmFromJSON = AutolaunchRuleDisarmFromJSON;
|
|
18
|
+
exports.AutolaunchRuleDisarmFromJSONTyped = AutolaunchRuleDisarmFromJSONTyped;
|
|
19
|
+
exports.AutolaunchRuleDisarmToJSON = AutolaunchRuleDisarmToJSON;
|
|
20
|
+
exports.AutolaunchRuleDisarmToJSONTyped = AutolaunchRuleDisarmToJSONTyped;
|
|
21
|
+
/**
|
|
22
|
+
* Check if a given object implements the AutolaunchRuleDisarm interface.
|
|
23
|
+
*/
|
|
24
|
+
function instanceOfAutolaunchRuleDisarm(value) {
|
|
25
|
+
if (!('enabled' in value) || value['enabled'] === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
return true;
|
|
28
|
+
}
|
|
29
|
+
function AutolaunchRuleDisarmFromJSON(json) {
|
|
30
|
+
return AutolaunchRuleDisarmFromJSONTyped(json, false);
|
|
31
|
+
}
|
|
32
|
+
function AutolaunchRuleDisarmFromJSONTyped(json, ignoreDiscriminator) {
|
|
33
|
+
if (json == null) {
|
|
34
|
+
return json;
|
|
35
|
+
}
|
|
36
|
+
return {
|
|
37
|
+
'enabled': json['enabled'],
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
function AutolaunchRuleDisarmToJSON(json) {
|
|
41
|
+
return AutolaunchRuleDisarmToJSONTyped(json, false);
|
|
42
|
+
}
|
|
43
|
+
function AutolaunchRuleDisarmToJSONTyped(value, ignoreDiscriminator = false) {
|
|
44
|
+
if (value == null) {
|
|
45
|
+
return value;
|
|
46
|
+
}
|
|
47
|
+
return {
|
|
48
|
+
'enabled': value['enabled'],
|
|
49
|
+
};
|
|
50
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
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
|
+
import type { AutolaunchRule } from './AutolaunchRule';
|
|
13
|
+
/**
|
|
14
|
+
*
|
|
15
|
+
* @export
|
|
16
|
+
* @interface AutolaunchRulePage
|
|
17
|
+
*/
|
|
18
|
+
export interface AutolaunchRulePage {
|
|
19
|
+
/**
|
|
20
|
+
*
|
|
21
|
+
* @type {Array<AutolaunchRule>}
|
|
22
|
+
* @memberof AutolaunchRulePage
|
|
23
|
+
*/
|
|
24
|
+
data: Array<AutolaunchRule>;
|
|
25
|
+
/**
|
|
26
|
+
*
|
|
27
|
+
* @type {string}
|
|
28
|
+
* @memberof AutolaunchRulePage
|
|
29
|
+
*/
|
|
30
|
+
nextCursor: string | null;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Check if a given object implements the AutolaunchRulePage interface.
|
|
34
|
+
*/
|
|
35
|
+
export declare function instanceOfAutolaunchRulePage(value: object): value is AutolaunchRulePage;
|
|
36
|
+
export declare function AutolaunchRulePageFromJSON(json: any): AutolaunchRulePage;
|
|
37
|
+
export declare function AutolaunchRulePageFromJSONTyped(json: any, ignoreDiscriminator: boolean): AutolaunchRulePage;
|
|
38
|
+
export declare function AutolaunchRulePageToJSON(json: any): AutolaunchRulePage;
|
|
39
|
+
export declare function AutolaunchRulePageToJSONTyped(value?: AutolaunchRulePage | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,55 @@
|
|
|
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.instanceOfAutolaunchRulePage = instanceOfAutolaunchRulePage;
|
|
17
|
+
exports.AutolaunchRulePageFromJSON = AutolaunchRulePageFromJSON;
|
|
18
|
+
exports.AutolaunchRulePageFromJSONTyped = AutolaunchRulePageFromJSONTyped;
|
|
19
|
+
exports.AutolaunchRulePageToJSON = AutolaunchRulePageToJSON;
|
|
20
|
+
exports.AutolaunchRulePageToJSONTyped = AutolaunchRulePageToJSONTyped;
|
|
21
|
+
const AutolaunchRule_1 = require("./AutolaunchRule");
|
|
22
|
+
/**
|
|
23
|
+
* Check if a given object implements the AutolaunchRulePage interface.
|
|
24
|
+
*/
|
|
25
|
+
function instanceOfAutolaunchRulePage(value) {
|
|
26
|
+
if (!('data' in value) || value['data'] === undefined)
|
|
27
|
+
return false;
|
|
28
|
+
if ((!('nextCursor' in value) && !('next_cursor' in value)) || (value['nextCursor'] === undefined && value['next_cursor'] === undefined))
|
|
29
|
+
return false;
|
|
30
|
+
return true;
|
|
31
|
+
}
|
|
32
|
+
function AutolaunchRulePageFromJSON(json) {
|
|
33
|
+
return AutolaunchRulePageFromJSONTyped(json, false);
|
|
34
|
+
}
|
|
35
|
+
function AutolaunchRulePageFromJSONTyped(json, ignoreDiscriminator) {
|
|
36
|
+
if (json == null) {
|
|
37
|
+
return json;
|
|
38
|
+
}
|
|
39
|
+
return {
|
|
40
|
+
'data': (json['data'].map(AutolaunchRule_1.AutolaunchRuleFromJSON)),
|
|
41
|
+
'nextCursor': json['next_cursor'],
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
function AutolaunchRulePageToJSON(json) {
|
|
45
|
+
return AutolaunchRulePageToJSONTyped(json, false);
|
|
46
|
+
}
|
|
47
|
+
function AutolaunchRulePageToJSONTyped(value, ignoreDiscriminator = false) {
|
|
48
|
+
if (value == null) {
|
|
49
|
+
return value;
|
|
50
|
+
}
|
|
51
|
+
return {
|
|
52
|
+
'data': (value['data'].map(AutolaunchRule_1.AutolaunchRuleToJSON)),
|
|
53
|
+
'next_cursor': value['nextCursor'],
|
|
54
|
+
};
|
|
55
|
+
}
|
|
@@ -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 Embedding
|
|
16
|
+
*/
|
|
17
|
+
export interface Embedding {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {EmbeddingObjectEnum}
|
|
21
|
+
* @memberof Embedding
|
|
22
|
+
*/
|
|
23
|
+
object: EmbeddingObjectEnum;
|
|
24
|
+
/**
|
|
25
|
+
* The embedding vector as 32-bit floats.
|
|
26
|
+
* @type {Array<number>}
|
|
27
|
+
* @memberof Embedding
|
|
28
|
+
*/
|
|
29
|
+
embedding: Array<number>;
|
|
30
|
+
/**
|
|
31
|
+
* Position of this vector's input in the request.
|
|
32
|
+
* @type {number}
|
|
33
|
+
* @memberof Embedding
|
|
34
|
+
*/
|
|
35
|
+
index: number;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* @export
|
|
39
|
+
*/
|
|
40
|
+
export declare const EmbeddingObjectEnum: {
|
|
41
|
+
readonly Embedding: "embedding";
|
|
42
|
+
};
|
|
43
|
+
export type EmbeddingObjectEnum = typeof EmbeddingObjectEnum[keyof typeof EmbeddingObjectEnum];
|
|
44
|
+
/**
|
|
45
|
+
* Check if a given object implements the Embedding interface.
|
|
46
|
+
*/
|
|
47
|
+
export declare function instanceOfEmbedding(value: object): value is Embedding;
|
|
48
|
+
export declare function EmbeddingFromJSON(json: any): Embedding;
|
|
49
|
+
export declare function EmbeddingFromJSONTyped(json: any, ignoreDiscriminator: boolean): Embedding;
|
|
50
|
+
export declare function EmbeddingToJSON(json: any): Embedding;
|
|
51
|
+
export declare function EmbeddingToJSONTyped(value?: Embedding | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,67 @@
|
|
|
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.EmbeddingObjectEnum = void 0;
|
|
17
|
+
exports.instanceOfEmbedding = instanceOfEmbedding;
|
|
18
|
+
exports.EmbeddingFromJSON = EmbeddingFromJSON;
|
|
19
|
+
exports.EmbeddingFromJSONTyped = EmbeddingFromJSONTyped;
|
|
20
|
+
exports.EmbeddingToJSON = EmbeddingToJSON;
|
|
21
|
+
exports.EmbeddingToJSONTyped = EmbeddingToJSONTyped;
|
|
22
|
+
/**
|
|
23
|
+
* @export
|
|
24
|
+
*/
|
|
25
|
+
exports.EmbeddingObjectEnum = {
|
|
26
|
+
Embedding: 'embedding'
|
|
27
|
+
};
|
|
28
|
+
/**
|
|
29
|
+
* Check if a given object implements the Embedding interface.
|
|
30
|
+
*/
|
|
31
|
+
function instanceOfEmbedding(value) {
|
|
32
|
+
if (!('object' in value) || value['object'] === undefined)
|
|
33
|
+
return false;
|
|
34
|
+
if (value['object'] !== 'embedding')
|
|
35
|
+
return false;
|
|
36
|
+
if (!('embedding' in value) || value['embedding'] === undefined)
|
|
37
|
+
return false;
|
|
38
|
+
if (!('index' in value) || value['index'] === undefined)
|
|
39
|
+
return false;
|
|
40
|
+
return true;
|
|
41
|
+
}
|
|
42
|
+
function EmbeddingFromJSON(json) {
|
|
43
|
+
return EmbeddingFromJSONTyped(json, false);
|
|
44
|
+
}
|
|
45
|
+
function EmbeddingFromJSONTyped(json, ignoreDiscriminator) {
|
|
46
|
+
if (json == null) {
|
|
47
|
+
return json;
|
|
48
|
+
}
|
|
49
|
+
return {
|
|
50
|
+
'object': json['object'],
|
|
51
|
+
'embedding': json['embedding'],
|
|
52
|
+
'index': json['index'],
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
function EmbeddingToJSON(json) {
|
|
56
|
+
return EmbeddingToJSONTyped(json, false);
|
|
57
|
+
}
|
|
58
|
+
function EmbeddingToJSONTyped(value, ignoreDiscriminator = false) {
|
|
59
|
+
if (value == null) {
|
|
60
|
+
return value;
|
|
61
|
+
}
|
|
62
|
+
return {
|
|
63
|
+
'object': value['object'],
|
|
64
|
+
'embedding': value['embedding'],
|
|
65
|
+
'index': value['index'],
|
|
66
|
+
};
|
|
67
|
+
}
|
|
@@ -0,0 +1,64 @@
|
|
|
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
|
+
import type { EmbeddingsRequestInput } from './EmbeddingsRequestInput';
|
|
13
|
+
/**
|
|
14
|
+
*
|
|
15
|
+
* @export
|
|
16
|
+
* @interface EmbeddingsRequest
|
|
17
|
+
*/
|
|
18
|
+
export interface EmbeddingsRequest {
|
|
19
|
+
/**
|
|
20
|
+
* Canonical embedding model id, e.g. "gpuai/qwen3-embedding-8b".
|
|
21
|
+
* @type {string}
|
|
22
|
+
* @memberof EmbeddingsRequest
|
|
23
|
+
*/
|
|
24
|
+
model: string;
|
|
25
|
+
/**
|
|
26
|
+
*
|
|
27
|
+
* @type {EmbeddingsRequestInput}
|
|
28
|
+
* @memberof EmbeddingsRequest
|
|
29
|
+
*/
|
|
30
|
+
input: EmbeddingsRequestInput;
|
|
31
|
+
/**
|
|
32
|
+
* Only "float" is supported. A value of "base64" is rejected with invalid_request_error / unsupported_parameter.
|
|
33
|
+
* @type {EmbeddingsRequestEncodingFormatEnum}
|
|
34
|
+
* @memberof EmbeddingsRequest
|
|
35
|
+
*/
|
|
36
|
+
encodingFormat?: EmbeddingsRequestEncodingFormatEnum;
|
|
37
|
+
/**
|
|
38
|
+
* Requested output dimensionality, for models that support truncated (Matryoshka) embeddings. Passed through to the model when set.
|
|
39
|
+
* @type {number}
|
|
40
|
+
* @memberof EmbeddingsRequest
|
|
41
|
+
*/
|
|
42
|
+
dimensions?: number;
|
|
43
|
+
/**
|
|
44
|
+
* Opaque end-user identifier for abuse tracing. Optional.
|
|
45
|
+
* @type {string}
|
|
46
|
+
* @memberof EmbeddingsRequest
|
|
47
|
+
*/
|
|
48
|
+
user?: string;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* @export
|
|
52
|
+
*/
|
|
53
|
+
export declare const EmbeddingsRequestEncodingFormatEnum: {
|
|
54
|
+
readonly Float: "float";
|
|
55
|
+
};
|
|
56
|
+
export type EmbeddingsRequestEncodingFormatEnum = typeof EmbeddingsRequestEncodingFormatEnum[keyof typeof EmbeddingsRequestEncodingFormatEnum];
|
|
57
|
+
/**
|
|
58
|
+
* Check if a given object implements the EmbeddingsRequest interface.
|
|
59
|
+
*/
|
|
60
|
+
export declare function instanceOfEmbeddingsRequest(value: object): value is EmbeddingsRequest;
|
|
61
|
+
export declare function EmbeddingsRequestFromJSON(json: any): EmbeddingsRequest;
|
|
62
|
+
export declare function EmbeddingsRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): EmbeddingsRequest;
|
|
63
|
+
export declare function EmbeddingsRequestToJSON(json: any): EmbeddingsRequest;
|
|
64
|
+
export declare function EmbeddingsRequestToJSONTyped(value?: EmbeddingsRequest | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,68 @@
|
|
|
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.EmbeddingsRequestEncodingFormatEnum = void 0;
|
|
17
|
+
exports.instanceOfEmbeddingsRequest = instanceOfEmbeddingsRequest;
|
|
18
|
+
exports.EmbeddingsRequestFromJSON = EmbeddingsRequestFromJSON;
|
|
19
|
+
exports.EmbeddingsRequestFromJSONTyped = EmbeddingsRequestFromJSONTyped;
|
|
20
|
+
exports.EmbeddingsRequestToJSON = EmbeddingsRequestToJSON;
|
|
21
|
+
exports.EmbeddingsRequestToJSONTyped = EmbeddingsRequestToJSONTyped;
|
|
22
|
+
const EmbeddingsRequestInput_1 = require("./EmbeddingsRequestInput");
|
|
23
|
+
/**
|
|
24
|
+
* @export
|
|
25
|
+
*/
|
|
26
|
+
exports.EmbeddingsRequestEncodingFormatEnum = {
|
|
27
|
+
Float: 'float'
|
|
28
|
+
};
|
|
29
|
+
/**
|
|
30
|
+
* Check if a given object implements the EmbeddingsRequest interface.
|
|
31
|
+
*/
|
|
32
|
+
function instanceOfEmbeddingsRequest(value) {
|
|
33
|
+
if (!('model' in value) || value['model'] === undefined)
|
|
34
|
+
return false;
|
|
35
|
+
if (!('input' in value) || value['input'] === undefined)
|
|
36
|
+
return false;
|
|
37
|
+
return true;
|
|
38
|
+
}
|
|
39
|
+
function EmbeddingsRequestFromJSON(json) {
|
|
40
|
+
return EmbeddingsRequestFromJSONTyped(json, false);
|
|
41
|
+
}
|
|
42
|
+
function EmbeddingsRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
43
|
+
if (json == null) {
|
|
44
|
+
return json;
|
|
45
|
+
}
|
|
46
|
+
return {
|
|
47
|
+
'model': json['model'],
|
|
48
|
+
'input': (0, EmbeddingsRequestInput_1.EmbeddingsRequestInputFromJSON)(json['input']),
|
|
49
|
+
'encodingFormat': json['encoding_format'] == null ? undefined : json['encoding_format'],
|
|
50
|
+
'dimensions': json['dimensions'] == null ? undefined : json['dimensions'],
|
|
51
|
+
'user': json['user'] == null ? undefined : json['user'],
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
function EmbeddingsRequestToJSON(json) {
|
|
55
|
+
return EmbeddingsRequestToJSONTyped(json, false);
|
|
56
|
+
}
|
|
57
|
+
function EmbeddingsRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
58
|
+
if (value == null) {
|
|
59
|
+
return value;
|
|
60
|
+
}
|
|
61
|
+
return {
|
|
62
|
+
'model': value['model'],
|
|
63
|
+
'input': (0, EmbeddingsRequestInput_1.EmbeddingsRequestInputToJSON)(value['input']),
|
|
64
|
+
'encoding_format': value['encodingFormat'],
|
|
65
|
+
'dimensions': value['dimensions'],
|
|
66
|
+
'user': value['user'],
|
|
67
|
+
};
|
|
68
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
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
|
+
* @type EmbeddingsRequestInput
|
|
14
|
+
* Text to embed: either a single string or an array of up to 2048 strings. Token-id arrays are not supported. The per-request ceiling is bounded so the response stays under 64 MiB — about 680 inputs at 4096 dimensions, fewer at a larger `dimensions` value; an over-limit batch is rejected with 400 invalid_request_error whose message states the limit, before any processing.
|
|
15
|
+
* @export
|
|
16
|
+
*/
|
|
17
|
+
export type EmbeddingsRequestInput = Array<string> | string;
|
|
18
|
+
export declare function EmbeddingsRequestInputFromJSON(json: any): EmbeddingsRequestInput;
|
|
19
|
+
export declare function EmbeddingsRequestInputFromJSONTyped(json: any, ignoreDiscriminator: boolean): EmbeddingsRequestInput;
|
|
20
|
+
export declare function EmbeddingsRequestInputToJSON(json: any): any;
|
|
21
|
+
export declare function EmbeddingsRequestInputToJSONTyped(value?: EmbeddingsRequestInput | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,53 @@
|
|
|
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.EmbeddingsRequestInputFromJSON = EmbeddingsRequestInputFromJSON;
|
|
17
|
+
exports.EmbeddingsRequestInputFromJSONTyped = EmbeddingsRequestInputFromJSONTyped;
|
|
18
|
+
exports.EmbeddingsRequestInputToJSON = EmbeddingsRequestInputToJSON;
|
|
19
|
+
exports.EmbeddingsRequestInputToJSONTyped = EmbeddingsRequestInputToJSONTyped;
|
|
20
|
+
function EmbeddingsRequestInputFromJSON(json) {
|
|
21
|
+
return EmbeddingsRequestInputFromJSONTyped(json, false);
|
|
22
|
+
}
|
|
23
|
+
function EmbeddingsRequestInputFromJSONTyped(json, ignoreDiscriminator) {
|
|
24
|
+
if (json == null) {
|
|
25
|
+
return json;
|
|
26
|
+
}
|
|
27
|
+
if (Array.isArray(json)) {
|
|
28
|
+
if (json.every(item => typeof item === 'string')) {
|
|
29
|
+
return json;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
if (typeof json === 'string') {
|
|
33
|
+
return json;
|
|
34
|
+
}
|
|
35
|
+
return {};
|
|
36
|
+
}
|
|
37
|
+
function EmbeddingsRequestInputToJSON(json) {
|
|
38
|
+
return EmbeddingsRequestInputToJSONTyped(json, false);
|
|
39
|
+
}
|
|
40
|
+
function EmbeddingsRequestInputToJSONTyped(value, ignoreDiscriminator = false) {
|
|
41
|
+
if (value == null) {
|
|
42
|
+
return value;
|
|
43
|
+
}
|
|
44
|
+
if (Array.isArray(value)) {
|
|
45
|
+
if (value.every(item => typeof item === 'string')) {
|
|
46
|
+
return value;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
if (typeof value === 'string') {
|
|
50
|
+
return value;
|
|
51
|
+
}
|
|
52
|
+
return {};
|
|
53
|
+
}
|
|
@@ -0,0 +1,59 @@
|
|
|
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
|
+
import type { Embedding } from './Embedding';
|
|
13
|
+
import type { EmbeddingsUsage } from './EmbeddingsUsage';
|
|
14
|
+
/**
|
|
15
|
+
*
|
|
16
|
+
* @export
|
|
17
|
+
* @interface EmbeddingsResponse
|
|
18
|
+
*/
|
|
19
|
+
export interface EmbeddingsResponse {
|
|
20
|
+
/**
|
|
21
|
+
*
|
|
22
|
+
* @type {EmbeddingsResponseObjectEnum}
|
|
23
|
+
* @memberof EmbeddingsResponse
|
|
24
|
+
*/
|
|
25
|
+
object: EmbeddingsResponseObjectEnum;
|
|
26
|
+
/**
|
|
27
|
+
*
|
|
28
|
+
* @type {Array<Embedding>}
|
|
29
|
+
* @memberof EmbeddingsResponse
|
|
30
|
+
*/
|
|
31
|
+
data: Array<Embedding>;
|
|
32
|
+
/**
|
|
33
|
+
* Canonical (gpuai/...) model id, NEVER the upstream identifier.
|
|
34
|
+
* @type {string}
|
|
35
|
+
* @memberof EmbeddingsResponse
|
|
36
|
+
*/
|
|
37
|
+
model: string;
|
|
38
|
+
/**
|
|
39
|
+
*
|
|
40
|
+
* @type {EmbeddingsUsage}
|
|
41
|
+
* @memberof EmbeddingsResponse
|
|
42
|
+
*/
|
|
43
|
+
usage: EmbeddingsUsage;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* @export
|
|
47
|
+
*/
|
|
48
|
+
export declare const EmbeddingsResponseObjectEnum: {
|
|
49
|
+
readonly List: "list";
|
|
50
|
+
};
|
|
51
|
+
export type EmbeddingsResponseObjectEnum = typeof EmbeddingsResponseObjectEnum[keyof typeof EmbeddingsResponseObjectEnum];
|
|
52
|
+
/**
|
|
53
|
+
* Check if a given object implements the EmbeddingsResponse interface.
|
|
54
|
+
*/
|
|
55
|
+
export declare function instanceOfEmbeddingsResponse(value: object): value is EmbeddingsResponse;
|
|
56
|
+
export declare function EmbeddingsResponseFromJSON(json: any): EmbeddingsResponse;
|
|
57
|
+
export declare function EmbeddingsResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): EmbeddingsResponse;
|
|
58
|
+
export declare function EmbeddingsResponseToJSON(json: any): EmbeddingsResponse;
|
|
59
|
+
export declare function EmbeddingsResponseToJSONTyped(value?: EmbeddingsResponse | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,73 @@
|
|
|
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.EmbeddingsResponseObjectEnum = void 0;
|
|
17
|
+
exports.instanceOfEmbeddingsResponse = instanceOfEmbeddingsResponse;
|
|
18
|
+
exports.EmbeddingsResponseFromJSON = EmbeddingsResponseFromJSON;
|
|
19
|
+
exports.EmbeddingsResponseFromJSONTyped = EmbeddingsResponseFromJSONTyped;
|
|
20
|
+
exports.EmbeddingsResponseToJSON = EmbeddingsResponseToJSON;
|
|
21
|
+
exports.EmbeddingsResponseToJSONTyped = EmbeddingsResponseToJSONTyped;
|
|
22
|
+
const Embedding_1 = require("./Embedding");
|
|
23
|
+
const EmbeddingsUsage_1 = require("./EmbeddingsUsage");
|
|
24
|
+
/**
|
|
25
|
+
* @export
|
|
26
|
+
*/
|
|
27
|
+
exports.EmbeddingsResponseObjectEnum = {
|
|
28
|
+
List: 'list'
|
|
29
|
+
};
|
|
30
|
+
/**
|
|
31
|
+
* Check if a given object implements the EmbeddingsResponse interface.
|
|
32
|
+
*/
|
|
33
|
+
function instanceOfEmbeddingsResponse(value) {
|
|
34
|
+
if (!('object' in value) || value['object'] === undefined)
|
|
35
|
+
return false;
|
|
36
|
+
if (value['object'] !== 'list')
|
|
37
|
+
return false;
|
|
38
|
+
if (!('data' in value) || value['data'] === undefined)
|
|
39
|
+
return false;
|
|
40
|
+
if (!('model' in value) || value['model'] === undefined)
|
|
41
|
+
return false;
|
|
42
|
+
if (!('usage' in value) || value['usage'] === undefined)
|
|
43
|
+
return false;
|
|
44
|
+
return true;
|
|
45
|
+
}
|
|
46
|
+
function EmbeddingsResponseFromJSON(json) {
|
|
47
|
+
return EmbeddingsResponseFromJSONTyped(json, false);
|
|
48
|
+
}
|
|
49
|
+
function EmbeddingsResponseFromJSONTyped(json, ignoreDiscriminator) {
|
|
50
|
+
if (json == null) {
|
|
51
|
+
return json;
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
'object': json['object'],
|
|
55
|
+
'data': (json['data'].map(Embedding_1.EmbeddingFromJSON)),
|
|
56
|
+
'model': json['model'],
|
|
57
|
+
'usage': (0, EmbeddingsUsage_1.EmbeddingsUsageFromJSON)(json['usage']),
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
function EmbeddingsResponseToJSON(json) {
|
|
61
|
+
return EmbeddingsResponseToJSONTyped(json, false);
|
|
62
|
+
}
|
|
63
|
+
function EmbeddingsResponseToJSONTyped(value, ignoreDiscriminator = false) {
|
|
64
|
+
if (value == null) {
|
|
65
|
+
return value;
|
|
66
|
+
}
|
|
67
|
+
return {
|
|
68
|
+
'object': value['object'],
|
|
69
|
+
'data': (value['data'].map(Embedding_1.EmbeddingToJSON)),
|
|
70
|
+
'model': value['model'],
|
|
71
|
+
'usage': (0, EmbeddingsUsage_1.EmbeddingsUsageToJSON)(value['usage']),
|
|
72
|
+
};
|
|
73
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
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
|
+
* Embeddings are billed on input tokens only, so this block carries no completion_tokens field — an embeddings call emits none, and total_tokens always equals prompt_tokens.
|
|
14
|
+
* @export
|
|
15
|
+
* @interface EmbeddingsUsage
|
|
16
|
+
*/
|
|
17
|
+
export interface EmbeddingsUsage {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {number}
|
|
21
|
+
* @memberof EmbeddingsUsage
|
|
22
|
+
*/
|
|
23
|
+
promptTokens: number;
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @type {number}
|
|
27
|
+
* @memberof EmbeddingsUsage
|
|
28
|
+
*/
|
|
29
|
+
totalTokens: number;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Check if a given object implements the EmbeddingsUsage interface.
|
|
33
|
+
*/
|
|
34
|
+
export declare function instanceOfEmbeddingsUsage(value: object): value is EmbeddingsUsage;
|
|
35
|
+
export declare function EmbeddingsUsageFromJSON(json: any): EmbeddingsUsage;
|
|
36
|
+
export declare function EmbeddingsUsageFromJSONTyped(json: any, ignoreDiscriminator: boolean): EmbeddingsUsage;
|
|
37
|
+
export declare function EmbeddingsUsageToJSON(json: any): EmbeddingsUsage;
|
|
38
|
+
export declare function EmbeddingsUsageToJSONTyped(value?: EmbeddingsUsage | null, ignoreDiscriminator?: boolean): any;
|