@meetkai/mka1 0.51.11 → 0.51.12
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/bin/mcp-server.js +39 -14
- package/bin/mcp-server.js.map +11 -10
- package/dist/commonjs/lib/config.d.ts +2 -2
- package/dist/commonjs/lib/config.js +2 -2
- package/dist/commonjs/mcp-server/mcp-server.js +1 -1
- package/dist/commonjs/mcp-server/server.js +1 -1
- package/dist/commonjs/models/components/deployment.d.ts +5 -5
- package/dist/commonjs/models/components/deployment.d.ts.map +1 -1
- package/dist/commonjs/models/components/deployment.js +3 -3
- package/dist/commonjs/models/components/deployment.js.map +1 -1
- package/dist/commonjs/models/components/deploymentacceleratorspec.d.ts +55 -0
- package/dist/commonjs/models/components/deploymentacceleratorspec.d.ts.map +1 -0
- package/dist/commonjs/models/components/deploymentacceleratorspec.js +75 -0
- package/dist/commonjs/models/components/deploymentacceleratorspec.js.map +1 -0
- package/dist/commonjs/models/components/deploymentcreate.d.ts +5 -5
- package/dist/commonjs/models/components/deploymentcreate.d.ts.map +1 -1
- package/dist/commonjs/models/components/deploymentcreate.js +3 -3
- package/dist/commonjs/models/components/deploymentcreate.js.map +1 -1
- package/dist/commonjs/models/components/index.d.ts +1 -0
- package/dist/commonjs/models/components/index.d.ts.map +1 -1
- package/dist/commonjs/models/components/index.js +1 -0
- package/dist/commonjs/models/components/index.js.map +1 -1
- package/dist/commonjs/models/components/replica.d.ts +5 -5
- package/dist/commonjs/models/components/replica.d.ts.map +1 -1
- package/dist/commonjs/models/components/replica.js +3 -3
- package/dist/commonjs/models/components/replica.js.map +1 -1
- package/dist/esm/lib/config.d.ts +2 -2
- package/dist/esm/lib/config.js +2 -2
- package/dist/esm/mcp-server/mcp-server.js +1 -1
- package/dist/esm/mcp-server/server.js +1 -1
- package/dist/esm/models/components/deployment.d.ts +5 -5
- package/dist/esm/models/components/deployment.d.ts.map +1 -1
- package/dist/esm/models/components/deployment.js +3 -3
- package/dist/esm/models/components/deployment.js.map +1 -1
- package/dist/esm/models/components/deploymentacceleratorspec.d.ts +55 -0
- package/dist/esm/models/components/deploymentacceleratorspec.d.ts.map +1 -0
- package/dist/esm/models/components/deploymentacceleratorspec.js +37 -0
- package/dist/esm/models/components/deploymentacceleratorspec.js.map +1 -0
- package/dist/esm/models/components/deploymentcreate.d.ts +5 -5
- package/dist/esm/models/components/deploymentcreate.d.ts.map +1 -1
- package/dist/esm/models/components/deploymentcreate.js +3 -3
- package/dist/esm/models/components/deploymentcreate.js.map +1 -1
- package/dist/esm/models/components/index.d.ts +1 -0
- package/dist/esm/models/components/index.d.ts.map +1 -1
- package/dist/esm/models/components/index.js +1 -0
- package/dist/esm/models/components/index.js.map +1 -1
- package/dist/esm/models/components/replica.d.ts +5 -5
- package/dist/esm/models/components/replica.d.ts.map +1 -1
- package/dist/esm/models/components/replica.js +3 -3
- package/dist/esm/models/components/replica.js.map +1 -1
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/lib/config.ts +2 -2
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +1 -1
- package/src/models/components/deployment.ts +11 -11
- package/src/models/components/deploymentacceleratorspec.ts +100 -0
- package/src/models/components/deploymentcreate.ts +11 -11
- package/src/models/components/index.ts +1 -0
- package/src/models/components/replica.ts +11 -11
|
@@ -9,11 +9,11 @@ import { ClosedEnum } from "../../types/enums.js";
|
|
|
9
9
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
10
10
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
11
11
|
import {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
} from "./
|
|
12
|
+
DeploymentAcceleratorSpec,
|
|
13
|
+
DeploymentAcceleratorSpec$inboundSchema,
|
|
14
|
+
DeploymentAcceleratorSpec$Outbound,
|
|
15
|
+
DeploymentAcceleratorSpec$outboundSchema,
|
|
16
|
+
} from "./deploymentacceleratorspec.js";
|
|
17
17
|
import {
|
|
18
18
|
DeploymentEndpoint,
|
|
19
19
|
DeploymentEndpoint$inboundSchema,
|
|
@@ -50,13 +50,13 @@ export type DeploymentStatus = ClosedEnum<typeof DeploymentStatus>;
|
|
|
50
50
|
*/
|
|
51
51
|
export type Deployment = {
|
|
52
52
|
/**
|
|
53
|
-
* A hardware accelerator request — GPU, NPU, TPU, or
|
|
53
|
+
* A hardware accelerator request for a deployment — GPU, NPU, TPU, or cpu-class serving.
|
|
54
54
|
*
|
|
55
55
|
* @remarks
|
|
56
56
|
*
|
|
57
|
-
* Request an accelerator by type and count, with optional fallback types.
|
|
57
|
+
* Request an accelerator by type and count, with optional fallback types. Set class to cpu to deploy a cpu-capable managed recipe on CPU instances (type is then not required; the CPU resource floor comes from the recipe).
|
|
58
58
|
*/
|
|
59
|
-
accelerator:
|
|
59
|
+
accelerator: DeploymentAcceleratorSpec;
|
|
60
60
|
createdAt: Date;
|
|
61
61
|
/**
|
|
62
62
|
* Where and how to call the model; set while registered with the gateway
|
|
@@ -101,7 +101,7 @@ export const Deployment$inboundSchema: z.ZodType<
|
|
|
101
101
|
z.ZodTypeDef,
|
|
102
102
|
unknown
|
|
103
103
|
> = z.object({
|
|
104
|
-
accelerator:
|
|
104
|
+
accelerator: DeploymentAcceleratorSpec$inboundSchema,
|
|
105
105
|
created_at: z.string().datetime({ offset: true }).transform(v => new Date(v)),
|
|
106
106
|
endpoint: z.nullable(DeploymentEndpoint$inboundSchema).optional(),
|
|
107
107
|
engine: Engine$inboundSchema,
|
|
@@ -123,7 +123,7 @@ export const Deployment$inboundSchema: z.ZodType<
|
|
|
123
123
|
});
|
|
124
124
|
/** @internal */
|
|
125
125
|
export type Deployment$Outbound = {
|
|
126
|
-
accelerator:
|
|
126
|
+
accelerator: DeploymentAcceleratorSpec$Outbound;
|
|
127
127
|
created_at: string;
|
|
128
128
|
endpoint?: DeploymentEndpoint$Outbound | null | undefined;
|
|
129
129
|
engine: string;
|
|
@@ -144,7 +144,7 @@ export const Deployment$outboundSchema: z.ZodType<
|
|
|
144
144
|
z.ZodTypeDef,
|
|
145
145
|
Deployment
|
|
146
146
|
> = z.object({
|
|
147
|
-
accelerator:
|
|
147
|
+
accelerator: DeploymentAcceleratorSpec$outboundSchema,
|
|
148
148
|
createdAt: z.date().transform(v => v.toISOString()),
|
|
149
149
|
endpoint: z.nullable(DeploymentEndpoint$outboundSchema).optional(),
|
|
150
150
|
engine: Engine$outboundSchema,
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
+
import { ClosedEnum } from "../../types/enums.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* Accelerator class: gpu (default) or cpu. For cpu-only recipes this is inferred; type is not required for cpu.
|
|
13
|
+
*/
|
|
14
|
+
export const Class = {
|
|
15
|
+
Gpu: "gpu",
|
|
16
|
+
Cpu: "cpu",
|
|
17
|
+
} as const;
|
|
18
|
+
/**
|
|
19
|
+
* Accelerator class: gpu (default) or cpu. For cpu-only recipes this is inferred; type is not required for cpu.
|
|
20
|
+
*/
|
|
21
|
+
export type Class = ClosedEnum<typeof Class>;
|
|
22
|
+
|
|
23
|
+
/**
|
|
24
|
+
* A hardware accelerator request for a deployment — GPU, NPU, TPU, or cpu-class serving.
|
|
25
|
+
*
|
|
26
|
+
* @remarks
|
|
27
|
+
*
|
|
28
|
+
* Request an accelerator by type and count, with optional fallback types. Set class to cpu to deploy a cpu-capable managed recipe on CPU instances (type is then not required; the CPU resource floor comes from the recipe).
|
|
29
|
+
*/
|
|
30
|
+
export type DeploymentAcceleratorSpec = {
|
|
31
|
+
/**
|
|
32
|
+
* Accelerator class: gpu (default) or cpu. For cpu-only recipes this is inferred; type is not required for cpu.
|
|
33
|
+
*/
|
|
34
|
+
class?: Class | undefined;
|
|
35
|
+
/**
|
|
36
|
+
* Accelerators per replica
|
|
37
|
+
*/
|
|
38
|
+
count?: number | undefined;
|
|
39
|
+
/**
|
|
40
|
+
* Ordered fallback types if the primary is unavailable
|
|
41
|
+
*/
|
|
42
|
+
fallback?: Array<string> | undefined;
|
|
43
|
+
type?: string | undefined;
|
|
44
|
+
};
|
|
45
|
+
|
|
46
|
+
/** @internal */
|
|
47
|
+
export const Class$inboundSchema: z.ZodNativeEnum<typeof Class> = z.nativeEnum(
|
|
48
|
+
Class,
|
|
49
|
+
);
|
|
50
|
+
/** @internal */
|
|
51
|
+
export const Class$outboundSchema: z.ZodNativeEnum<typeof Class> =
|
|
52
|
+
Class$inboundSchema;
|
|
53
|
+
|
|
54
|
+
/** @internal */
|
|
55
|
+
export const DeploymentAcceleratorSpec$inboundSchema: z.ZodType<
|
|
56
|
+
DeploymentAcceleratorSpec,
|
|
57
|
+
z.ZodTypeDef,
|
|
58
|
+
unknown
|
|
59
|
+
> = z.object({
|
|
60
|
+
class: Class$inboundSchema.default("gpu"),
|
|
61
|
+
count: z.number().int().default(1),
|
|
62
|
+
fallback: z.array(z.string()).optional(),
|
|
63
|
+
type: z.string().optional(),
|
|
64
|
+
});
|
|
65
|
+
/** @internal */
|
|
66
|
+
export type DeploymentAcceleratorSpec$Outbound = {
|
|
67
|
+
class: string;
|
|
68
|
+
count: number;
|
|
69
|
+
fallback?: Array<string> | undefined;
|
|
70
|
+
type?: string | undefined;
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
/** @internal */
|
|
74
|
+
export const DeploymentAcceleratorSpec$outboundSchema: z.ZodType<
|
|
75
|
+
DeploymentAcceleratorSpec$Outbound,
|
|
76
|
+
z.ZodTypeDef,
|
|
77
|
+
DeploymentAcceleratorSpec
|
|
78
|
+
> = z.object({
|
|
79
|
+
class: Class$outboundSchema.default("gpu"),
|
|
80
|
+
count: z.number().int().default(1),
|
|
81
|
+
fallback: z.array(z.string()).optional(),
|
|
82
|
+
type: z.string().optional(),
|
|
83
|
+
});
|
|
84
|
+
|
|
85
|
+
export function deploymentAcceleratorSpecToJSON(
|
|
86
|
+
deploymentAcceleratorSpec: DeploymentAcceleratorSpec,
|
|
87
|
+
): string {
|
|
88
|
+
return JSON.stringify(
|
|
89
|
+
DeploymentAcceleratorSpec$outboundSchema.parse(deploymentAcceleratorSpec),
|
|
90
|
+
);
|
|
91
|
+
}
|
|
92
|
+
export function deploymentAcceleratorSpecFromJSON(
|
|
93
|
+
jsonString: string,
|
|
94
|
+
): SafeParseResult<DeploymentAcceleratorSpec, SDKValidationError> {
|
|
95
|
+
return safeParse(
|
|
96
|
+
jsonString,
|
|
97
|
+
(x) => DeploymentAcceleratorSpec$inboundSchema.parse(JSON.parse(x)),
|
|
98
|
+
`Failed to parse 'DeploymentAcceleratorSpec' from JSON`,
|
|
99
|
+
);
|
|
100
|
+
}
|
|
@@ -8,11 +8,11 @@ import { safeParse } from "../../lib/schemas.js";
|
|
|
8
8
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
9
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
10
|
import {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
} from "./
|
|
11
|
+
DeploymentAcceleratorSpec,
|
|
12
|
+
DeploymentAcceleratorSpec$inboundSchema,
|
|
13
|
+
DeploymentAcceleratorSpec$Outbound,
|
|
14
|
+
DeploymentAcceleratorSpec$outboundSchema,
|
|
15
|
+
} from "./deploymentacceleratorspec.js";
|
|
16
16
|
import {
|
|
17
17
|
DeploymentAPIFormat,
|
|
18
18
|
DeploymentAPIFormat$inboundSchema,
|
|
@@ -40,13 +40,13 @@ import {
|
|
|
40
40
|
*/
|
|
41
41
|
export type DeploymentCreate = {
|
|
42
42
|
/**
|
|
43
|
-
* A hardware accelerator request — GPU, NPU, TPU, or
|
|
43
|
+
* A hardware accelerator request for a deployment — GPU, NPU, TPU, or cpu-class serving.
|
|
44
44
|
*
|
|
45
45
|
* @remarks
|
|
46
46
|
*
|
|
47
|
-
* Request an accelerator by type and count, with optional fallback types.
|
|
47
|
+
* Request an accelerator by type and count, with optional fallback types. Set class to cpu to deploy a cpu-capable managed recipe on CPU instances (type is then not required; the CPU resource floor comes from the recipe).
|
|
48
48
|
*/
|
|
49
|
-
accelerator:
|
|
49
|
+
accelerator: DeploymentAcceleratorSpec;
|
|
50
50
|
/**
|
|
51
51
|
* Gateway inference surface exposed by the deployment runtime.
|
|
52
52
|
*/
|
|
@@ -112,7 +112,7 @@ export const DeploymentCreate$inboundSchema: z.ZodType<
|
|
|
112
112
|
z.ZodTypeDef,
|
|
113
113
|
unknown
|
|
114
114
|
> = z.object({
|
|
115
|
-
accelerator:
|
|
115
|
+
accelerator: DeploymentAcceleratorSpec$inboundSchema,
|
|
116
116
|
api_format: DeploymentAPIFormat$inboundSchema.optional(),
|
|
117
117
|
endpoint_auth: z.boolean().default(true),
|
|
118
118
|
engine: Engine$inboundSchema.optional(),
|
|
@@ -139,7 +139,7 @@ export const DeploymentCreate$inboundSchema: z.ZodType<
|
|
|
139
139
|
});
|
|
140
140
|
/** @internal */
|
|
141
141
|
export type DeploymentCreate$Outbound = {
|
|
142
|
-
accelerator:
|
|
142
|
+
accelerator: DeploymentAcceleratorSpec$Outbound;
|
|
143
143
|
api_format?: string | undefined;
|
|
144
144
|
endpoint_auth: boolean;
|
|
145
145
|
engine?: string | undefined;
|
|
@@ -163,7 +163,7 @@ export const DeploymentCreate$outboundSchema: z.ZodType<
|
|
|
163
163
|
z.ZodTypeDef,
|
|
164
164
|
DeploymentCreate
|
|
165
165
|
> = z.object({
|
|
166
|
-
accelerator:
|
|
166
|
+
accelerator: DeploymentAcceleratorSpec$outboundSchema,
|
|
167
167
|
apiFormat: DeploymentAPIFormat$outboundSchema.optional(),
|
|
168
168
|
endpointAuth: z.boolean().default(true),
|
|
169
169
|
engine: Engine$outboundSchema.optional(),
|
|
@@ -135,6 +135,7 @@ export * from "./deleteorgautomodelresponse.js";
|
|
|
135
135
|
export * from "./deletepromptresponse.js";
|
|
136
136
|
export * from "./deleteresponseobject.js";
|
|
137
137
|
export * from "./deployment.js";
|
|
138
|
+
export * from "./deploymentacceleratorspec.js";
|
|
138
139
|
export * from "./deploymentapiformat.js";
|
|
139
140
|
export * from "./deploymentcreate.js";
|
|
140
141
|
export * from "./deploymentendpoint.js";
|
|
@@ -8,24 +8,24 @@ import { safeParse } from "../../lib/schemas.js";
|
|
|
8
8
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
9
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
10
|
import {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
} from "./
|
|
11
|
+
DeploymentAcceleratorSpec,
|
|
12
|
+
DeploymentAcceleratorSpec$inboundSchema,
|
|
13
|
+
DeploymentAcceleratorSpec$Outbound,
|
|
14
|
+
DeploymentAcceleratorSpec$outboundSchema,
|
|
15
|
+
} from "./deploymentacceleratorspec.js";
|
|
16
16
|
|
|
17
17
|
/**
|
|
18
18
|
* A single running replica (pod/container) behind a deployment.
|
|
19
19
|
*/
|
|
20
20
|
export type Replica = {
|
|
21
21
|
/**
|
|
22
|
-
* A hardware accelerator request — GPU, NPU, TPU, or
|
|
22
|
+
* A hardware accelerator request for a deployment — GPU, NPU, TPU, or cpu-class serving.
|
|
23
23
|
*
|
|
24
24
|
* @remarks
|
|
25
25
|
*
|
|
26
|
-
* Request an accelerator by type and count, with optional fallback types.
|
|
26
|
+
* Request an accelerator by type and count, with optional fallback types. Set class to cpu to deploy a cpu-capable managed recipe on CPU instances (type is then not required; the CPU resource floor comes from the recipe).
|
|
27
27
|
*/
|
|
28
|
-
accelerator:
|
|
28
|
+
accelerator: DeploymentAcceleratorSpec;
|
|
29
29
|
id: string;
|
|
30
30
|
node?: string | null | undefined;
|
|
31
31
|
priceUsdHr?: number | undefined;
|
|
@@ -41,7 +41,7 @@ export type Replica = {
|
|
|
41
41
|
/** @internal */
|
|
42
42
|
export const Replica$inboundSchema: z.ZodType<Replica, z.ZodTypeDef, unknown> =
|
|
43
43
|
z.object({
|
|
44
|
-
accelerator:
|
|
44
|
+
accelerator: DeploymentAcceleratorSpec$inboundSchema,
|
|
45
45
|
id: z.string(),
|
|
46
46
|
node: z.nullable(z.string()).optional(),
|
|
47
47
|
price_usd_hr: z.number().optional(),
|
|
@@ -59,7 +59,7 @@ export const Replica$inboundSchema: z.ZodType<Replica, z.ZodTypeDef, unknown> =
|
|
|
59
59
|
});
|
|
60
60
|
/** @internal */
|
|
61
61
|
export type Replica$Outbound = {
|
|
62
|
-
accelerator:
|
|
62
|
+
accelerator: DeploymentAcceleratorSpec$Outbound;
|
|
63
63
|
id: string;
|
|
64
64
|
node?: string | null | undefined;
|
|
65
65
|
price_usd_hr?: number | undefined;
|
|
@@ -75,7 +75,7 @@ export const Replica$outboundSchema: z.ZodType<
|
|
|
75
75
|
z.ZodTypeDef,
|
|
76
76
|
Replica
|
|
77
77
|
> = z.object({
|
|
78
|
-
accelerator:
|
|
78
|
+
accelerator: DeploymentAcceleratorSpec$outboundSchema,
|
|
79
79
|
id: z.string(),
|
|
80
80
|
node: z.nullable(z.string()).optional(),
|
|
81
81
|
priceUsdHr: z.number().optional(),
|