@nosana/types 0.1.2 → 0.1.3
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/dist/Jobs/JobDefinition/logistics/index.d.ts +9 -5
- package/dist/Jobs/JobDefinition/logistics/index.js +1 -1
- package/dist/Jobs/JobDefinition/logistics/index.js.map +1 -1
- package/dist/Jobs/index.js +132 -93
- package/dist/Jobs/index.js.map +1 -1
- package/dist/Schemas/job.js +17 -2
- package/dist/Schemas/job.js.map +1 -1
- package/package.json +1 -1
|
@@ -2,16 +2,20 @@
|
|
|
2
2
|
* api - we receive and send via an endpoint endpoint
|
|
3
3
|
* api-listen - we create an endpoint to listen for incoming requests
|
|
4
4
|
*/
|
|
5
|
-
export declare const
|
|
5
|
+
export declare const LogisticType: {
|
|
6
6
|
readonly API: "api";
|
|
7
7
|
readonly API_LISTEN: "api-listen";
|
|
8
8
|
};
|
|
9
|
-
export type
|
|
10
|
-
type
|
|
9
|
+
export type LogisticType = typeof LogisticType[keyof typeof LogisticType];
|
|
10
|
+
type LogisticArgs = Partial<{
|
|
11
11
|
endpoint: string;
|
|
12
12
|
}>;
|
|
13
|
+
export type Logistic = {
|
|
14
|
+
type: LogisticType;
|
|
15
|
+
args: LogisticArgs;
|
|
16
|
+
};
|
|
13
17
|
export interface Logistics {
|
|
14
|
-
|
|
15
|
-
|
|
18
|
+
send: Logistic;
|
|
19
|
+
receive: Logistic;
|
|
16
20
|
}
|
|
17
21
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/Jobs/JobDefinition/logistics/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,CAAC,MAAM,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/Jobs/JobDefinition/logistics/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG;IAC1B,GAAG,EAAE,KAAK;IACV,UAAU,EAAE,YAAY;CAChB,CAAC"}
|
package/dist/Jobs/index.js
CHANGED
|
@@ -5,7 +5,7 @@ import typia from "typia";
|
|
|
5
5
|
export * from "./Flows/index.js";
|
|
6
6
|
export * from "./JobDefinition/index.js";
|
|
7
7
|
export * from "./Logs/index.js";
|
|
8
|
-
export const validateJobDefinition = (() => { const _io0 = (input, _exceptionable = true) => "container" === input.type && "0.1" === input.version && (undefined === input.logistics || "object" === typeof input.logistics && null !== input.logistics && _io1(input.logistics, true && _exceptionable)) && (undefined === input.deployment_id || "string" === typeof input.deployment_id) && (undefined === input.meta || "object" === typeof input.meta && null !== input.meta && false === Array.isArray(input.meta) &&
|
|
8
|
+
export const validateJobDefinition = (() => { const _io0 = (input, _exceptionable = true) => "container" === input.type && "0.1" === input.version && (undefined === input.logistics || "object" === typeof input.logistics && null !== input.logistics && _io1(input.logistics, true && _exceptionable)) && (undefined === input.deployment_id || "string" === typeof input.deployment_id) && (undefined === input.meta || "object" === typeof input.meta && null !== input.meta && false === Array.isArray(input.meta) && _io4(input.meta, true && _exceptionable)) && (undefined === input.global || "object" === typeof input.global && null !== input.global && false === Array.isArray(input.global) && _io6(input.global, true && _exceptionable)) && (Array.isArray(input.ops) && (Array.isArray(input.ops) && (() => {
|
|
9
9
|
const seen = new Set();
|
|
10
10
|
for (const it of input.ops) {
|
|
11
11
|
if (typeof it?.id !== "string")
|
|
@@ -15,64 +15,71 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
15
15
|
seen.add(it.id);
|
|
16
16
|
}
|
|
17
17
|
return true;
|
|
18
|
-
})() && input.ops.every((elem, _index1) => "object" === typeof elem && null !== elem &&
|
|
18
|
+
})() && input.ops.every((elem, _index1) => "object" === typeof elem && null !== elem && _io9(elem, true && _exceptionable)))) && (3 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
19
19
|
if (["type", "version", "logistics", "deployment_id", "meta", "global", "ops"].some(prop => key === prop))
|
|
20
20
|
return true;
|
|
21
21
|
const value = input[key];
|
|
22
22
|
if (undefined === value)
|
|
23
23
|
return true;
|
|
24
24
|
return false;
|
|
25
|
-
})); const _io1 = (input, _exceptionable = true) =>
|
|
25
|
+
})); const _io1 = (input, _exceptionable = true) => "object" === typeof input.send && null !== input.send && _io2(input.send, true && _exceptionable) && ("object" === typeof input.receive && null !== input.receive && _io2(input.receive, true && _exceptionable)) && (2 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
26
|
+
if (["send", "receive"].some(prop => key === prop))
|
|
27
|
+
return true;
|
|
28
|
+
const value = input[key];
|
|
29
|
+
if (undefined === value)
|
|
30
|
+
return true;
|
|
31
|
+
return false;
|
|
32
|
+
})); const _io2 = (input, _exceptionable = true) => ("api" === input.type || "api-listen" === input.type) && ("object" === typeof input.args && null !== input.args && false === Array.isArray(input.args) && _io3(input.args, true && _exceptionable)) && (2 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
26
33
|
if (["type", "args"].some(prop => key === prop))
|
|
27
34
|
return true;
|
|
28
35
|
const value = input[key];
|
|
29
36
|
if (undefined === value)
|
|
30
37
|
return true;
|
|
31
38
|
return false;
|
|
32
|
-
})); const
|
|
39
|
+
})); const _io3 = (input, _exceptionable = true) => (undefined === input.endpoint || "string" === typeof input.endpoint) && (0 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
33
40
|
if (["endpoint"].some(prop => key === prop))
|
|
34
41
|
return true;
|
|
35
42
|
const value = input[key];
|
|
36
43
|
if (undefined === value)
|
|
37
44
|
return true;
|
|
38
45
|
return false;
|
|
39
|
-
})); const
|
|
46
|
+
})); const _io4 = (input, _exceptionable = true) => (undefined === input.trigger || "string" === typeof input.trigger) && (undefined === input.system_resources || "object" === typeof input.system_resources && null !== input.system_resources && false === Array.isArray(input.system_resources) && _io5(input.system_resources, true && _exceptionable)) && Object.keys(input).every(key => {
|
|
40
47
|
if (["trigger", "system_resources"].some(prop => key === prop))
|
|
41
48
|
return true;
|
|
42
49
|
const value = input[key];
|
|
43
50
|
if (undefined === value)
|
|
44
51
|
return true;
|
|
45
52
|
return "string" === typeof value || "number" === typeof value;
|
|
46
|
-
}); const
|
|
53
|
+
}); const _io5 = (input, _exceptionable = true) => Object.keys(input).every(key => {
|
|
47
54
|
const value = input[key];
|
|
48
55
|
if (undefined === value)
|
|
49
56
|
return true;
|
|
50
57
|
return "string" === typeof value || "number" === typeof value;
|
|
51
|
-
}); const
|
|
58
|
+
}); const _io6 = (input, _exceptionable = true) => (undefined === input.image || "string" === typeof input.image) && (undefined === input.gpu || "boolean" === typeof input.gpu) && (null !== input.entrypoint && (undefined === input.entrypoint || "string" === typeof input.entrypoint || Array.isArray(input.entrypoint) && input.entrypoint.every((elem, _index2) => "string" === typeof elem))) && (undefined === input.env || "object" === typeof input.env && null !== input.env && false === Array.isArray(input.env) && _io7(input.env, true && _exceptionable)) && (undefined === input.work_dir || "string" === typeof input.work_dir) && (undefined === input.variables || "object" === typeof input.variables && null !== input.variables && false === Array.isArray(input.variables) && _io8(input.variables, true && _exceptionable)) && (0 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
52
59
|
if (["image", "gpu", "entrypoint", "env", "work_dir", "variables"].some(prop => key === prop))
|
|
53
60
|
return true;
|
|
54
61
|
const value = input[key];
|
|
55
62
|
if (undefined === value)
|
|
56
63
|
return true;
|
|
57
64
|
return false;
|
|
58
|
-
})); const
|
|
65
|
+
})); const _io7 = (input, _exceptionable = true) => Object.keys(input).every(key => {
|
|
59
66
|
const value = input[key];
|
|
60
67
|
if (undefined === value)
|
|
61
68
|
return true;
|
|
62
69
|
return "string" === typeof value;
|
|
63
|
-
}); const
|
|
70
|
+
}); const _io8 = (input, _exceptionable = true) => Object.keys(input).every(key => {
|
|
64
71
|
const value = input[key];
|
|
65
72
|
if (undefined === value)
|
|
66
73
|
return true;
|
|
67
74
|
return "string" === typeof value;
|
|
68
|
-
}); const
|
|
75
|
+
}); const _io9 = (input, _exceptionable = true) => ("container/run" === input.type || "container/create-volume" === input.type) && "string" === typeof input.id && ("object" === typeof input.args && null !== input.args && _iu1(input.args, true && _exceptionable)) && (undefined === input.results || "object" === typeof input.results && null !== input.results && false === Array.isArray(input.results) && _io23(input.results, true && _exceptionable)) && (undefined === input.execution || "object" === typeof input.execution && null !== input.execution && false === Array.isArray(input.execution) && _iu2(input.execution, true && _exceptionable)) && (3 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
69
76
|
if (["type", "id", "args", "results", "execution"].some(prop => key === prop))
|
|
70
77
|
return true;
|
|
71
78
|
const value = input[key];
|
|
72
79
|
if (undefined === value)
|
|
73
80
|
return true;
|
|
74
81
|
return false;
|
|
75
|
-
})); const
|
|
82
|
+
})); const _io10 = (input, _exceptionable = true) => "string" === typeof input.image && (null !== input.aliases && (undefined === input.aliases || "string" === typeof input.aliases || Array.isArray(input.aliases) && input.aliases.every((elem, _index3) => "string" === typeof elem))) && (null !== input.cmd && (undefined === input.cmd || "string" === typeof input.cmd || Array.isArray(input.cmd) && input.cmd.every((elem, _index4) => "string" === typeof elem))) && (undefined === input.volumes || Array.isArray(input.volumes) && input.volumes.every((elem, _index5) => "object" === typeof elem && null !== elem && _io11(elem, true && _exceptionable))) && (null !== input.expose && (undefined === input.expose || "number" === typeof input.expose || "string" === typeof input.expose && (typeof input.expose === "string" && /^%%(ops|global).[^%]+%%$/.test(input.expose)) || (Array.isArray(input.expose) && ((() => {
|
|
76
83
|
if (!Array.isArray(input.expose))
|
|
77
84
|
return true;
|
|
78
85
|
const numbers = new Set();
|
|
@@ -107,103 +114,103 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
107
114
|
}
|
|
108
115
|
}
|
|
109
116
|
return true;
|
|
110
|
-
})() && input.expose.every((elem, _index6) => null !== elem && undefined !== elem && ("number" === typeof elem || "string" === typeof elem && (typeof elem === "string" && /^%%(ops|global).[^%]+%%$/.test(elem)) || "object" === typeof elem && null !== elem &&
|
|
117
|
+
})() && input.expose.every((elem, _index6) => null !== elem && undefined !== elem && ("number" === typeof elem || "string" === typeof elem && (typeof elem === "string" && /^%%(ops|global).[^%]+%%$/.test(elem)) || "object" === typeof elem && null !== elem && _io12(elem, true && _exceptionable)))) || "object" === typeof input.expose && null !== input.expose && _io12(input.expose, true && _exceptionable)))) && (undefined === input.gpu || "boolean" === typeof input.gpu) && (undefined === input.work_dir || "string" === typeof input.work_dir) && (null !== input.entrypoint && (undefined === input.entrypoint || "string" === typeof input.entrypoint || Array.isArray(input.entrypoint) && input.entrypoint.every((elem, _index7) => "string" === typeof elem))) && (undefined === input.env || "object" === typeof input.env && null !== input.env && false === Array.isArray(input.env) && _io7(input.env, true && _exceptionable)) && (undefined === input.resources || Array.isArray(input.resources) && input.resources.every((elem, _index8) => null !== elem && undefined !== elem && ("__remove-if-empty__" === elem || "object" === typeof elem && null !== elem && _iu0(elem, true && _exceptionable)))) && (undefined === input.authentication || "object" === typeof input.authentication && null !== input.authentication && false === Array.isArray(input.authentication) && _io20(input.authentication, true && _exceptionable)) && (1 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
111
118
|
if (["image", "aliases", "cmd", "volumes", "expose", "gpu", "work_dir", "entrypoint", "env", "resources", "authentication"].some(prop => key === prop))
|
|
112
119
|
return true;
|
|
113
120
|
const value = input[key];
|
|
114
121
|
if (undefined === value)
|
|
115
122
|
return true;
|
|
116
123
|
return false;
|
|
117
|
-
})); const
|
|
124
|
+
})); const _io11 = (input, _exceptionable = true) => "string" === typeof input.name && "string" === typeof input.dest && (2 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
118
125
|
if (["name", "dest"].some(prop => key === prop))
|
|
119
126
|
return true;
|
|
120
127
|
const value = input[key];
|
|
121
128
|
if (undefined === value)
|
|
122
129
|
return true;
|
|
123
130
|
return false;
|
|
124
|
-
})); const
|
|
131
|
+
})); const _io12 = (input, _exceptionable = true) => "string" === typeof input.__spread__ && (typeof input.__spread__ === "string" && /^%%(ops|global).[^%]+%%$/.test(input.__spread__)) && (1 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
125
132
|
if (["__spread__"].some(prop => key === prop))
|
|
126
133
|
return true;
|
|
127
134
|
const value = input[key];
|
|
128
135
|
if (undefined === value)
|
|
129
136
|
return true;
|
|
130
137
|
return false;
|
|
131
|
-
})); const
|
|
138
|
+
})); const _io13 = (input, _exceptionable = true) => "S3" === input.type && "string" === typeof input.target && (undefined === input.url || "string" === typeof input.url) && (undefined === input.allowWrite || "boolean" === typeof input.allowWrite) && (undefined === input.files || Array.isArray(input.files) && input.files.every((elem, _index9) => "string" === typeof elem)) && (undefined === input.IAM || "object" === typeof input.IAM && null !== input.IAM && _io14(input.IAM, true && _exceptionable)) && (2 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
132
139
|
if (["type", "target", "url", "allowWrite", "files", "IAM"].some(prop => key === prop))
|
|
133
140
|
return true;
|
|
134
141
|
const value = input[key];
|
|
135
142
|
if (undefined === value)
|
|
136
143
|
return true;
|
|
137
144
|
return false;
|
|
138
|
-
})); const
|
|
145
|
+
})); const _io14 = (input, _exceptionable = true) => "string" === typeof input.REGION && "string" === typeof input.ACCESS_KEY_ID && "string" === typeof input.SECRET_ACCESS_KEY && (3 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
139
146
|
if (["REGION", "ACCESS_KEY_ID", "SECRET_ACCESS_KEY"].some(prop => key === prop))
|
|
140
147
|
return true;
|
|
141
148
|
const value = input[key];
|
|
142
149
|
if (undefined === value)
|
|
143
150
|
return true;
|
|
144
151
|
return false;
|
|
145
|
-
})); const
|
|
152
|
+
})); const _io15 = (input, _exceptionable = true) => "S3" === input.type && "string" === typeof input.target && "string" === typeof input.bucket && (undefined === input.url || "string" === typeof input.url) && (undefined === input.allowWrite || "boolean" === typeof input.allowWrite) && (undefined === input.IAM || "object" === typeof input.IAM && null !== input.IAM && _io14(input.IAM, true && _exceptionable)) && (3 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
146
153
|
if (["type", "target", "bucket", "url", "allowWrite", "IAM"].some(prop => key === prop))
|
|
147
154
|
return true;
|
|
148
155
|
const value = input[key];
|
|
149
156
|
if (undefined === value)
|
|
150
157
|
return true;
|
|
151
158
|
return false;
|
|
152
|
-
})); const
|
|
159
|
+
})); const _io16 = (input, _exceptionable = true) => "S3" === input.type && "string" === typeof input.target && (Array.isArray(input.buckets) && input.buckets.every((elem, _index10) => "object" === typeof elem && null !== elem && _io17(elem, true && _exceptionable))) && (undefined === input.url || "string" === typeof input.url) && (undefined === input.allowWrite || "boolean" === typeof input.allowWrite) && (undefined === input.IAM || "object" === typeof input.IAM && null !== input.IAM && _io14(input.IAM, true && _exceptionable)) && (3 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
153
160
|
if (["type", "target", "buckets", "url", "allowWrite", "IAM"].some(prop => key === prop))
|
|
154
161
|
return true;
|
|
155
162
|
const value = input[key];
|
|
156
163
|
if (undefined === value)
|
|
157
164
|
return true;
|
|
158
165
|
return false;
|
|
159
|
-
})); const
|
|
166
|
+
})); const _io17 = (input, _exceptionable = true) => "string" === typeof input.url && (undefined === input.files || Array.isArray(input.files) && input.files.every((elem, _index11) => "string" === typeof elem)) && (1 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
160
167
|
if (["url", "files"].some(prop => key === prop))
|
|
161
168
|
return true;
|
|
162
169
|
const value = input[key];
|
|
163
170
|
if (undefined === value)
|
|
164
171
|
return true;
|
|
165
172
|
return false;
|
|
166
|
-
})); const
|
|
173
|
+
})); const _io18 = (input, _exceptionable = true) => "HF" === input.type && "string" === typeof input.target && "string" === typeof input.repo && (undefined === input.revision || "string" === typeof input.revision) && (undefined === input.files || Array.isArray(input.files) && input.files.every((elem, _index12) => "string" === typeof elem)) && (undefined === input.accessToken || "string" === typeof input.accessToken) && (3 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
167
174
|
if (["type", "target", "repo", "revision", "files", "accessToken"].some(prop => key === prop))
|
|
168
175
|
return true;
|
|
169
176
|
const value = input[key];
|
|
170
177
|
if (undefined === value)
|
|
171
178
|
return true;
|
|
172
179
|
return false;
|
|
173
|
-
})); const
|
|
180
|
+
})); const _io19 = (input, _exceptionable = true) => "Ollama" === input.type && "string" === typeof input.model && (undefined === input.target || "string" === typeof input.target) && (2 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
174
181
|
if (["type", "model", "target"].some(prop => key === prop))
|
|
175
182
|
return true;
|
|
176
183
|
const value = input[key];
|
|
177
184
|
if (undefined === value)
|
|
178
185
|
return true;
|
|
179
186
|
return false;
|
|
180
|
-
})); const
|
|
187
|
+
})); const _io20 = (input, _exceptionable = true) => (undefined === input.docker || "object" === typeof input.docker && null !== input.docker && false === Array.isArray(input.docker) && _io21(input.docker, true && _exceptionable)) && (0 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
181
188
|
if (["docker"].some(prop => key === prop))
|
|
182
189
|
return true;
|
|
183
190
|
const value = input[key];
|
|
184
191
|
if (undefined === value)
|
|
185
192
|
return true;
|
|
186
193
|
return false;
|
|
187
|
-
})); const
|
|
194
|
+
})); const _io21 = (input, _exceptionable = true) => (undefined === input.username || "string" === typeof input.username) && (undefined === input.password || "string" === typeof input.password) && (undefined === input.email || "string" === typeof input.email) && (undefined === input.server || "string" === typeof input.server) && (0 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
188
195
|
if (["username", "password", "email", "server"].some(prop => key === prop))
|
|
189
196
|
return true;
|
|
190
197
|
const value = input[key];
|
|
191
198
|
if (undefined === value)
|
|
192
199
|
return true;
|
|
193
200
|
return false;
|
|
194
|
-
})); const
|
|
201
|
+
})); const _io22 = (input, _exceptionable = true) => "string" === typeof input.name && (1 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
195
202
|
if (["name"].some(prop => key === prop))
|
|
196
203
|
return true;
|
|
197
204
|
const value = input[key];
|
|
198
205
|
if (undefined === value)
|
|
199
206
|
return true;
|
|
200
207
|
return false;
|
|
201
|
-
})); const
|
|
208
|
+
})); const _io23 = (input, _exceptionable = true) => Object.keys(input).every(key => {
|
|
202
209
|
const value = input[key];
|
|
203
210
|
if (undefined === value)
|
|
204
211
|
return true;
|
|
205
|
-
return null !== value && undefined !== value && ("string" === typeof value || "object" === typeof value && null !== value &&
|
|
206
|
-
}); const
|
|
212
|
+
return null !== value && undefined !== value && ("string" === typeof value || "object" === typeof value && null !== value && _io24(value, true && _exceptionable));
|
|
213
|
+
}); const _io24 = (input, _exceptionable = true) => "string" === typeof input.regex && (Array.isArray(input.logType) && (Array.isArray(input.logType) && input.logType.length >= 1 && input.logType.length <= 4 && (() => {
|
|
207
214
|
const seen = new Set();
|
|
208
215
|
for (const v of input.logType) {
|
|
209
216
|
if (seen.has(v))
|
|
@@ -218,14 +225,14 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
218
225
|
if (undefined === value)
|
|
219
226
|
return true;
|
|
220
227
|
return false;
|
|
221
|
-
})); const
|
|
228
|
+
})); const _io25 = (input, _exceptionable = true) => (undefined === input.group || "string" === typeof input.group) && (null !== input.depends_on && undefined === input.depends_on) && (null !== input.stop_if_dependent_stops && undefined === input.stop_if_dependent_stops) && (0 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
222
229
|
if (["group", "depends_on", "stop_if_dependent_stops"].some(prop => key === prop))
|
|
223
230
|
return true;
|
|
224
231
|
const value = input[key];
|
|
225
232
|
if (undefined === value)
|
|
226
233
|
return true;
|
|
227
234
|
return false;
|
|
228
|
-
})); const
|
|
235
|
+
})); const _io26 = (input, _exceptionable = true) => (undefined === input.group || "string" === typeof input.group) && (Array.isArray(input.depends_on) && input.depends_on.every((elem, _index14) => "string" === typeof elem)) && (undefined === input.stop_if_dependent_stops || "boolean" === typeof input.stop_if_dependent_stops) && (1 === Object.keys(input).length || Object.keys(input).every(key => {
|
|
229
236
|
if (["group", "depends_on", "stop_if_dependent_stops"].some(prop => key === prop))
|
|
230
237
|
return true;
|
|
231
238
|
const value = input[key];
|
|
@@ -234,29 +241,29 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
234
241
|
return false;
|
|
235
242
|
})); const _iu0 = (input, _exceptionable = true) => (() => {
|
|
236
243
|
if (undefined !== input.__spread__)
|
|
237
|
-
return
|
|
244
|
+
return _io12(input, true && _exceptionable);
|
|
238
245
|
else if (undefined !== input.bucket)
|
|
239
|
-
return _io14(input, true && _exceptionable);
|
|
240
|
-
else if (undefined !== input.buckets)
|
|
241
246
|
return _io15(input, true && _exceptionable);
|
|
247
|
+
else if (undefined !== input.buckets)
|
|
248
|
+
return _io16(input, true && _exceptionable);
|
|
242
249
|
else if ("HF" === input.type)
|
|
243
|
-
return _io17(input, true && _exceptionable);
|
|
244
|
-
else if ("Ollama" === input.type)
|
|
245
250
|
return _io18(input, true && _exceptionable);
|
|
251
|
+
else if ("Ollama" === input.type)
|
|
252
|
+
return _io19(input, true && _exceptionable);
|
|
246
253
|
else
|
|
247
|
-
return
|
|
254
|
+
return _io13(input, true && _exceptionable);
|
|
248
255
|
})(); const _iu1 = (input, _exceptionable = true) => (() => {
|
|
249
256
|
if (undefined !== input.image)
|
|
250
|
-
return
|
|
257
|
+
return _io10(input, true && _exceptionable);
|
|
251
258
|
else if (undefined !== input.name)
|
|
252
|
-
return
|
|
259
|
+
return _io22(input, true && _exceptionable);
|
|
253
260
|
else
|
|
254
261
|
return false;
|
|
255
262
|
})(); const _iu2 = (input, _exceptionable = true) => (() => {
|
|
256
263
|
if (Array.isArray(input.depends_on) && input.depends_on.every((elem, _index15) => "string" === typeof elem))
|
|
257
|
-
return
|
|
264
|
+
return _io26(input, true && _exceptionable);
|
|
258
265
|
else
|
|
259
|
-
return
|
|
266
|
+
return _io25(input, true && _exceptionable);
|
|
260
267
|
})(); const _vo0 = (input, _path, _exceptionable = true) => ["container" === input.type || _report(_exceptionable, {
|
|
261
268
|
path: _path + ".type",
|
|
262
269
|
expected: "\"container\"",
|
|
@@ -281,7 +288,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
281
288
|
path: _path + ".meta",
|
|
282
289
|
expected: "(Meta | undefined)",
|
|
283
290
|
value: input.meta
|
|
284
|
-
})) &&
|
|
291
|
+
})) && _vo4(input.meta, _path + ".meta", true && _exceptionable) || _report(_exceptionable, {
|
|
285
292
|
path: _path + ".meta",
|
|
286
293
|
expected: "(Meta | undefined)",
|
|
287
294
|
value: input.meta
|
|
@@ -289,7 +296,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
289
296
|
path: _path + ".global",
|
|
290
297
|
expected: "(Global | undefined)",
|
|
291
298
|
value: input.global
|
|
292
|
-
})) &&
|
|
299
|
+
})) && _vo6(input.global, _path + ".global", true && _exceptionable) || _report(_exceptionable, {
|
|
293
300
|
path: _path + ".global",
|
|
294
301
|
expected: "(Global | undefined)",
|
|
295
302
|
value: input.global
|
|
@@ -315,7 +322,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
315
322
|
path: _path + ".ops[" + _index16 + "]",
|
|
316
323
|
expected: "Operation<keyof OperationArgsMap>",
|
|
317
324
|
value: elem
|
|
318
|
-
})) &&
|
|
325
|
+
})) && _vo9(elem, _path + ".ops[" + _index16 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
319
326
|
path: _path + ".ops[" + _index16 + "]",
|
|
320
327
|
expected: "Operation<keyof OperationArgsMap>",
|
|
321
328
|
value: elem
|
|
@@ -339,7 +346,39 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
339
346
|
"Please remove the property next time."
|
|
340
347
|
].join("\n")
|
|
341
348
|
});
|
|
342
|
-
}).every(flag => flag))].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["
|
|
349
|
+
}).every(flag => flag))].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => [("object" === typeof input.send && null !== input.send || _report(_exceptionable, {
|
|
350
|
+
path: _path + ".send",
|
|
351
|
+
expected: "Logistic",
|
|
352
|
+
value: input.send
|
|
353
|
+
})) && _vo2(input.send, _path + ".send", true && _exceptionable) || _report(_exceptionable, {
|
|
354
|
+
path: _path + ".send",
|
|
355
|
+
expected: "Logistic",
|
|
356
|
+
value: input.send
|
|
357
|
+
}), ("object" === typeof input.receive && null !== input.receive || _report(_exceptionable, {
|
|
358
|
+
path: _path + ".receive",
|
|
359
|
+
expected: "Logistic",
|
|
360
|
+
value: input.receive
|
|
361
|
+
})) && _vo2(input.receive, _path + ".receive", true && _exceptionable) || _report(_exceptionable, {
|
|
362
|
+
path: _path + ".receive",
|
|
363
|
+
expected: "Logistic",
|
|
364
|
+
value: input.receive
|
|
365
|
+
}), 2 === Object.keys(input).length || (false === _exceptionable || Object.keys(input).map(key => {
|
|
366
|
+
if (["send", "receive"].some(prop => key === prop))
|
|
367
|
+
return true;
|
|
368
|
+
const value = input[key];
|
|
369
|
+
if (undefined === value)
|
|
370
|
+
return true;
|
|
371
|
+
return _report(_exceptionable, {
|
|
372
|
+
path: _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key),
|
|
373
|
+
expected: "undefined",
|
|
374
|
+
value: value,
|
|
375
|
+
description: [
|
|
376
|
+
`The property \`${key}\` is not defined in the object type.`,
|
|
377
|
+
"",
|
|
378
|
+
"Please remove the property next time."
|
|
379
|
+
].join("\n")
|
|
380
|
+
});
|
|
381
|
+
}).every(flag => flag))].every(flag => flag); const _vo2 = (input, _path, _exceptionable = true) => ["api" === input.type || "api-listen" === input.type || _report(_exceptionable, {
|
|
343
382
|
path: _path + ".type",
|
|
344
383
|
expected: "(\"api\" | \"api-listen\")",
|
|
345
384
|
value: input.type
|
|
@@ -347,7 +386,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
347
386
|
path: _path + ".args",
|
|
348
387
|
expected: "Partial<__type>",
|
|
349
388
|
value: input.args
|
|
350
|
-
})) &&
|
|
389
|
+
})) && _vo3(input.args, _path + ".args", true && _exceptionable) || _report(_exceptionable, {
|
|
351
390
|
path: _path + ".args",
|
|
352
391
|
expected: "Partial<__type>",
|
|
353
392
|
value: input.args
|
|
@@ -367,7 +406,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
367
406
|
"Please remove the property next time."
|
|
368
407
|
].join("\n")
|
|
369
408
|
});
|
|
370
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
409
|
+
}).every(flag => flag))].every(flag => flag); const _vo3 = (input, _path, _exceptionable = true) => [undefined === input.endpoint || "string" === typeof input.endpoint || _report(_exceptionable, {
|
|
371
410
|
path: _path + ".endpoint",
|
|
372
411
|
expected: "(string | undefined)",
|
|
373
412
|
value: input.endpoint
|
|
@@ -387,7 +426,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
387
426
|
"Please remove the property next time."
|
|
388
427
|
].join("\n")
|
|
389
428
|
});
|
|
390
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
429
|
+
}).every(flag => flag))].every(flag => flag); const _vo4 = (input, _path, _exceptionable = true) => [undefined === input.trigger || "string" === typeof input.trigger || _report(_exceptionable, {
|
|
391
430
|
path: _path + ".trigger",
|
|
392
431
|
expected: "(string | undefined)",
|
|
393
432
|
value: input.trigger
|
|
@@ -395,7 +434,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
395
434
|
path: _path + ".system_resources",
|
|
396
435
|
expected: "(Record<string, string | number> | undefined)",
|
|
397
436
|
value: input.system_resources
|
|
398
|
-
})) &&
|
|
437
|
+
})) && _vo5(input.system_resources, _path + ".system_resources", true && _exceptionable) || _report(_exceptionable, {
|
|
399
438
|
path: _path + ".system_resources",
|
|
400
439
|
expected: "(Record<string, string | number> | undefined)",
|
|
401
440
|
value: input.system_resources
|
|
@@ -410,7 +449,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
410
449
|
expected: "(number | string)",
|
|
411
450
|
value: value
|
|
412
451
|
});
|
|
413
|
-
}).every(flag => flag)].every(flag => flag); const
|
|
452
|
+
}).every(flag => flag)].every(flag => flag); const _vo5 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
|
414
453
|
const value = input[key];
|
|
415
454
|
if (undefined === value)
|
|
416
455
|
return true;
|
|
@@ -419,7 +458,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
419
458
|
expected: "(number | string)",
|
|
420
459
|
value: value
|
|
421
460
|
});
|
|
422
|
-
}).every(flag => flag)].every(flag => flag); const
|
|
461
|
+
}).every(flag => flag)].every(flag => flag); const _vo6 = (input, _path, _exceptionable = true) => [undefined === input.image || "string" === typeof input.image || _report(_exceptionable, {
|
|
423
462
|
path: _path + ".image",
|
|
424
463
|
expected: "(string | undefined)",
|
|
425
464
|
value: input.image
|
|
@@ -447,7 +486,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
447
486
|
path: _path + ".env",
|
|
448
487
|
expected: "(Env | undefined)",
|
|
449
488
|
value: input.env
|
|
450
|
-
})) &&
|
|
489
|
+
})) && _vo7(input.env, _path + ".env", true && _exceptionable) || _report(_exceptionable, {
|
|
451
490
|
path: _path + ".env",
|
|
452
491
|
expected: "(Env | undefined)",
|
|
453
492
|
value: input.env
|
|
@@ -459,7 +498,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
459
498
|
path: _path + ".variables",
|
|
460
499
|
expected: "(Variables | undefined)",
|
|
461
500
|
value: input.variables
|
|
462
|
-
})) &&
|
|
501
|
+
})) && _vo8(input.variables, _path + ".variables", true && _exceptionable) || _report(_exceptionable, {
|
|
463
502
|
path: _path + ".variables",
|
|
464
503
|
expected: "(Variables | undefined)",
|
|
465
504
|
value: input.variables
|
|
@@ -479,7 +518,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
479
518
|
"Please remove the property next time."
|
|
480
519
|
].join("\n")
|
|
481
520
|
});
|
|
482
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
521
|
+
}).every(flag => flag))].every(flag => flag); const _vo7 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
|
483
522
|
const value = input[key];
|
|
484
523
|
if (undefined === value)
|
|
485
524
|
return true;
|
|
@@ -488,7 +527,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
488
527
|
expected: "string",
|
|
489
528
|
value: value
|
|
490
529
|
});
|
|
491
|
-
}).every(flag => flag)].every(flag => flag); const
|
|
530
|
+
}).every(flag => flag)].every(flag => flag); const _vo8 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
|
492
531
|
const value = input[key];
|
|
493
532
|
if (undefined === value)
|
|
494
533
|
return true;
|
|
@@ -497,7 +536,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
497
536
|
expected: "string",
|
|
498
537
|
value: value
|
|
499
538
|
});
|
|
500
|
-
}).every(flag => flag)].every(flag => flag); const
|
|
539
|
+
}).every(flag => flag)].every(flag => flag); const _vo9 = (input, _path, _exceptionable = true) => ["container/run" === input.type || "container/create-volume" === input.type || _report(_exceptionable, {
|
|
501
540
|
path: _path + ".type",
|
|
502
541
|
expected: "(\"container/create-volume\" | \"container/run\")",
|
|
503
542
|
value: input.type
|
|
@@ -517,7 +556,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
517
556
|
path: _path + ".results",
|
|
518
557
|
expected: "(OperationResults | undefined)",
|
|
519
558
|
value: input.results
|
|
520
|
-
})) &&
|
|
559
|
+
})) && _vo23(input.results, _path + ".results", true && _exceptionable) || _report(_exceptionable, {
|
|
521
560
|
path: _path + ".results",
|
|
522
561
|
expected: "(OperationResults | undefined)",
|
|
523
562
|
value: input.results
|
|
@@ -545,7 +584,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
545
584
|
"Please remove the property next time."
|
|
546
585
|
].join("\n")
|
|
547
586
|
});
|
|
548
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
587
|
+
}).every(flag => flag))].every(flag => flag); const _vo10 = (input, _path, _exceptionable = true) => ["string" === typeof input.image || _report(_exceptionable, {
|
|
549
588
|
path: _path + ".image",
|
|
550
589
|
expected: "string",
|
|
551
590
|
value: input.image
|
|
@@ -589,7 +628,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
589
628
|
path: _path + ".volumes[" + _index20 + "]",
|
|
590
629
|
expected: "Volume",
|
|
591
630
|
value: elem
|
|
592
|
-
})) &&
|
|
631
|
+
})) && _vo11(elem, _path + ".volumes[" + _index20 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
593
632
|
path: _path + ".volumes[" + _index20 + "]",
|
|
594
633
|
expected: "Volume",
|
|
595
634
|
value: elem
|
|
@@ -660,11 +699,11 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
660
699
|
path: _path + ".expose[" + _index21 + "]",
|
|
661
700
|
expected: "((__type & TagBase<__type>) | (string & TagBase<__type>) | number)",
|
|
662
701
|
value: elem
|
|
663
|
-
})) &&
|
|
702
|
+
})) && _vo12(elem, _path + ".expose[" + _index21 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
664
703
|
path: _path + ".expose[" + _index21 + "]",
|
|
665
704
|
expected: "((__type & TagBase<__type>) | (string & TagBase<__type>) | number)",
|
|
666
705
|
value: elem
|
|
667
|
-
}))).every(flag => flag)) || "object" === typeof input.expose && null !== input.expose &&
|
|
706
|
+
}))).every(flag => flag)) || "object" === typeof input.expose && null !== input.expose && _vo12(input.expose, _path + ".expose", true && _exceptionable) || _report(_exceptionable, {
|
|
668
707
|
path: _path + ".expose",
|
|
669
708
|
expected: "((Array<ExposeBase> & TagBase<__type>) | (__type & TagBase<__type>) | (string & TagBase<__type>) | number | undefined)",
|
|
670
709
|
value: input.expose
|
|
@@ -700,7 +739,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
700
739
|
path: _path + ".env",
|
|
701
740
|
expected: "(Env | undefined)",
|
|
702
741
|
value: input.env
|
|
703
|
-
})) &&
|
|
742
|
+
})) && _vo7(input.env, _path + ".env", true && _exceptionable) || _report(_exceptionable, {
|
|
704
743
|
path: _path + ".env",
|
|
705
744
|
expected: "(Env | undefined)",
|
|
706
745
|
value: input.env
|
|
@@ -732,7 +771,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
732
771
|
path: _path + ".authentication",
|
|
733
772
|
expected: "(Authentication | undefined)",
|
|
734
773
|
value: input.authentication
|
|
735
|
-
})) &&
|
|
774
|
+
})) && _vo20(input.authentication, _path + ".authentication", true && _exceptionable) || _report(_exceptionable, {
|
|
736
775
|
path: _path + ".authentication",
|
|
737
776
|
expected: "(Authentication | undefined)",
|
|
738
777
|
value: input.authentication
|
|
@@ -752,7 +791,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
752
791
|
"Please remove the property next time."
|
|
753
792
|
].join("\n")
|
|
754
793
|
});
|
|
755
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
794
|
+
}).every(flag => flag))].every(flag => flag); const _vo11 = (input, _path, _exceptionable = true) => ["string" === typeof input.name || _report(_exceptionable, {
|
|
756
795
|
path: _path + ".name",
|
|
757
796
|
expected: "string",
|
|
758
797
|
value: input.name
|
|
@@ -776,7 +815,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
776
815
|
"Please remove the property next time."
|
|
777
816
|
].join("\n")
|
|
778
817
|
});
|
|
779
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
818
|
+
}).every(flag => flag))].every(flag => flag); const _vo12 = (input, _path, _exceptionable = true) => ["string" === typeof input.__spread__ && (typeof input.__spread__ === "string" && /^%%(ops|global).[^%]+%%$/.test(input.__spread__) || _report(_exceptionable, {
|
|
780
819
|
path: _path + ".__spread__",
|
|
781
820
|
expected: "string & TagBase<__type>",
|
|
782
821
|
value: input.__spread__
|
|
@@ -800,7 +839,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
800
839
|
"Please remove the property next time."
|
|
801
840
|
].join("\n")
|
|
802
841
|
});
|
|
803
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
842
|
+
}).every(flag => flag))].every(flag => flag); const _vo13 = (input, _path, _exceptionable = true) => ["S3" === input.type || _report(_exceptionable, {
|
|
804
843
|
path: _path + ".type",
|
|
805
844
|
expected: "\"S3\"",
|
|
806
845
|
value: input.type
|
|
@@ -832,7 +871,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
832
871
|
path: _path + ".IAM",
|
|
833
872
|
expected: "(S3Auth | undefined)",
|
|
834
873
|
value: input.IAM
|
|
835
|
-
})) &&
|
|
874
|
+
})) && _vo14(input.IAM, _path + ".IAM", true && _exceptionable) || _report(_exceptionable, {
|
|
836
875
|
path: _path + ".IAM",
|
|
837
876
|
expected: "(S3Auth | undefined)",
|
|
838
877
|
value: input.IAM
|
|
@@ -852,7 +891,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
852
891
|
"Please remove the property next time."
|
|
853
892
|
].join("\n")
|
|
854
893
|
});
|
|
855
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
894
|
+
}).every(flag => flag))].every(flag => flag); const _vo14 = (input, _path, _exceptionable = true) => ["string" === typeof input.REGION || _report(_exceptionable, {
|
|
856
895
|
path: _path + ".REGION",
|
|
857
896
|
expected: "string",
|
|
858
897
|
value: input.REGION
|
|
@@ -880,7 +919,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
880
919
|
"Please remove the property next time."
|
|
881
920
|
].join("\n")
|
|
882
921
|
});
|
|
883
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
922
|
+
}).every(flag => flag))].every(flag => flag); const _vo15 = (input, _path, _exceptionable = true) => ["S3" === input.type || _report(_exceptionable, {
|
|
884
923
|
path: _path + ".type",
|
|
885
924
|
expected: "\"S3\"",
|
|
886
925
|
value: input.type
|
|
@@ -904,7 +943,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
904
943
|
path: _path + ".IAM",
|
|
905
944
|
expected: "(S3Auth | undefined)",
|
|
906
945
|
value: input.IAM
|
|
907
|
-
})) &&
|
|
946
|
+
})) && _vo14(input.IAM, _path + ".IAM", true && _exceptionable) || _report(_exceptionable, {
|
|
908
947
|
path: _path + ".IAM",
|
|
909
948
|
expected: "(S3Auth | undefined)",
|
|
910
949
|
value: input.IAM
|
|
@@ -924,7 +963,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
924
963
|
"Please remove the property next time."
|
|
925
964
|
].join("\n")
|
|
926
965
|
});
|
|
927
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
966
|
+
}).every(flag => flag))].every(flag => flag); const _vo16 = (input, _path, _exceptionable = true) => ["S3" === input.type || _report(_exceptionable, {
|
|
928
967
|
path: _path + ".type",
|
|
929
968
|
expected: "\"S3\"",
|
|
930
969
|
value: input.type
|
|
@@ -940,7 +979,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
940
979
|
path: _path + ".buckets[" + _index25 + "]",
|
|
941
980
|
expected: "__type.o4",
|
|
942
981
|
value: elem
|
|
943
|
-
})) &&
|
|
982
|
+
})) && _vo17(elem, _path + ".buckets[" + _index25 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
944
983
|
path: _path + ".buckets[" + _index25 + "]",
|
|
945
984
|
expected: "__type.o4",
|
|
946
985
|
value: elem
|
|
@@ -960,7 +999,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
960
999
|
path: _path + ".IAM",
|
|
961
1000
|
expected: "(S3Auth | undefined)",
|
|
962
1001
|
value: input.IAM
|
|
963
|
-
})) &&
|
|
1002
|
+
})) && _vo14(input.IAM, _path + ".IAM", true && _exceptionable) || _report(_exceptionable, {
|
|
964
1003
|
path: _path + ".IAM",
|
|
965
1004
|
expected: "(S3Auth | undefined)",
|
|
966
1005
|
value: input.IAM
|
|
@@ -980,7 +1019,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
980
1019
|
"Please remove the property next time."
|
|
981
1020
|
].join("\n")
|
|
982
1021
|
});
|
|
983
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1022
|
+
}).every(flag => flag))].every(flag => flag); const _vo17 = (input, _path, _exceptionable = true) => ["string" === typeof input.url || _report(_exceptionable, {
|
|
984
1023
|
path: _path + ".url",
|
|
985
1024
|
expected: "string",
|
|
986
1025
|
value: input.url
|
|
@@ -1012,7 +1051,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1012
1051
|
"Please remove the property next time."
|
|
1013
1052
|
].join("\n")
|
|
1014
1053
|
});
|
|
1015
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1054
|
+
}).every(flag => flag))].every(flag => flag); const _vo18 = (input, _path, _exceptionable = true) => ["HF" === input.type || _report(_exceptionable, {
|
|
1016
1055
|
path: _path + ".type",
|
|
1017
1056
|
expected: "\"HF\"",
|
|
1018
1057
|
value: input.type
|
|
@@ -1060,7 +1099,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1060
1099
|
"Please remove the property next time."
|
|
1061
1100
|
].join("\n")
|
|
1062
1101
|
});
|
|
1063
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1102
|
+
}).every(flag => flag))].every(flag => flag); const _vo19 = (input, _path, _exceptionable = true) => ["Ollama" === input.type || _report(_exceptionable, {
|
|
1064
1103
|
path: _path + ".type",
|
|
1065
1104
|
expected: "\"Ollama\"",
|
|
1066
1105
|
value: input.type
|
|
@@ -1088,11 +1127,11 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1088
1127
|
"Please remove the property next time."
|
|
1089
1128
|
].join("\n")
|
|
1090
1129
|
});
|
|
1091
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1130
|
+
}).every(flag => flag))].every(flag => flag); const _vo20 = (input, _path, _exceptionable = true) => [undefined === input.docker || ("object" === typeof input.docker && null !== input.docker && false === Array.isArray(input.docker) || _report(_exceptionable, {
|
|
1092
1131
|
path: _path + ".docker",
|
|
1093
1132
|
expected: "(DockerAuth | undefined)",
|
|
1094
1133
|
value: input.docker
|
|
1095
|
-
})) &&
|
|
1134
|
+
})) && _vo21(input.docker, _path + ".docker", true && _exceptionable) || _report(_exceptionable, {
|
|
1096
1135
|
path: _path + ".docker",
|
|
1097
1136
|
expected: "(DockerAuth | undefined)",
|
|
1098
1137
|
value: input.docker
|
|
@@ -1112,7 +1151,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1112
1151
|
"Please remove the property next time."
|
|
1113
1152
|
].join("\n")
|
|
1114
1153
|
});
|
|
1115
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1154
|
+
}).every(flag => flag))].every(flag => flag); const _vo21 = (input, _path, _exceptionable = true) => [undefined === input.username || "string" === typeof input.username || _report(_exceptionable, {
|
|
1116
1155
|
path: _path + ".username",
|
|
1117
1156
|
expected: "(string | undefined)",
|
|
1118
1157
|
value: input.username
|
|
@@ -1144,7 +1183,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1144
1183
|
"Please remove the property next time."
|
|
1145
1184
|
].join("\n")
|
|
1146
1185
|
});
|
|
1147
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1186
|
+
}).every(flag => flag))].every(flag => flag); const _vo22 = (input, _path, _exceptionable = true) => ["string" === typeof input.name || _report(_exceptionable, {
|
|
1148
1187
|
path: _path + ".name",
|
|
1149
1188
|
expected: "string",
|
|
1150
1189
|
value: input.name
|
|
@@ -1164,7 +1203,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1164
1203
|
"Please remove the property next time."
|
|
1165
1204
|
].join("\n")
|
|
1166
1205
|
});
|
|
1167
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1206
|
+
}).every(flag => flag))].every(flag => flag); const _vo23 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
|
1168
1207
|
const value = input[key];
|
|
1169
1208
|
if (undefined === value)
|
|
1170
1209
|
return true;
|
|
@@ -1180,12 +1219,12 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1180
1219
|
path: _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key),
|
|
1181
1220
|
expected: "(OperationResult | string)",
|
|
1182
1221
|
value: value
|
|
1183
|
-
})) &&
|
|
1222
|
+
})) && _vo24(value, _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key), true && _exceptionable) || _report(_exceptionable, {
|
|
1184
1223
|
path: _path + __typia_transform__accessExpressionAsString._accessExpressionAsString(key),
|
|
1185
1224
|
expected: "(OperationResult | string)",
|
|
1186
1225
|
value: value
|
|
1187
1226
|
}));
|
|
1188
|
-
}).every(flag => flag)].every(flag => flag); const
|
|
1227
|
+
}).every(flag => flag)].every(flag => flag); const _vo24 = (input, _path, _exceptionable = true) => ["string" === typeof input.regex || _report(_exceptionable, {
|
|
1189
1228
|
path: _path + ".regex",
|
|
1190
1229
|
expected: "string",
|
|
1191
1230
|
value: input.regex
|
|
@@ -1229,7 +1268,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1229
1268
|
"Please remove the property next time."
|
|
1230
1269
|
].join("\n")
|
|
1231
1270
|
});
|
|
1232
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1271
|
+
}).every(flag => flag))].every(flag => flag); const _vo25 = (input, _path, _exceptionable = true) => [undefined === input.group || "string" === typeof input.group || _report(_exceptionable, {
|
|
1233
1272
|
path: _path + ".group",
|
|
1234
1273
|
expected: "(string | undefined)",
|
|
1235
1274
|
value: input.group
|
|
@@ -1265,7 +1304,7 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1265
1304
|
"Please remove the property next time."
|
|
1266
1305
|
].join("\n")
|
|
1267
1306
|
});
|
|
1268
|
-
}).every(flag => flag))].every(flag => flag); const
|
|
1307
|
+
}).every(flag => flag))].every(flag => flag); const _vo26 = (input, _path, _exceptionable = true) => [undefined === input.group || "string" === typeof input.group || _report(_exceptionable, {
|
|
1269
1308
|
path: _path + ".group",
|
|
1270
1309
|
expected: "(string | undefined)",
|
|
1271
1310
|
value: input.group
|
|
@@ -1303,22 +1342,22 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1303
1342
|
});
|
|
1304
1343
|
}).every(flag => flag))].every(flag => flag); const _vu0 = (input, _path, _exceptionable = true) => (() => {
|
|
1305
1344
|
if (undefined !== input.__spread__)
|
|
1306
|
-
return
|
|
1345
|
+
return _vo12(input, _path, true && _exceptionable);
|
|
1307
1346
|
else if (undefined !== input.bucket)
|
|
1308
|
-
return _vo14(input, _path, true && _exceptionable);
|
|
1309
|
-
else if (undefined !== input.buckets)
|
|
1310
1347
|
return _vo15(input, _path, true && _exceptionable);
|
|
1348
|
+
else if (undefined !== input.buckets)
|
|
1349
|
+
return _vo16(input, _path, true && _exceptionable);
|
|
1311
1350
|
else if ("HF" === input.type)
|
|
1312
|
-
return _vo17(input, _path, true && _exceptionable);
|
|
1313
|
-
else if ("Ollama" === input.type)
|
|
1314
1351
|
return _vo18(input, _path, true && _exceptionable);
|
|
1352
|
+
else if ("Ollama" === input.type)
|
|
1353
|
+
return _vo19(input, _path, true && _exceptionable);
|
|
1315
1354
|
else
|
|
1316
|
-
return
|
|
1355
|
+
return _vo13(input, _path, true && _exceptionable);
|
|
1317
1356
|
})(); const _vu1 = (input, _path, _exceptionable = true) => (() => {
|
|
1318
1357
|
if (undefined !== input.image)
|
|
1319
|
-
return
|
|
1358
|
+
return _vo10(input, _path, true && _exceptionable);
|
|
1320
1359
|
else if (undefined !== input.name)
|
|
1321
|
-
return
|
|
1360
|
+
return _vo22(input, _path, true && _exceptionable);
|
|
1322
1361
|
else
|
|
1323
1362
|
return _report(_exceptionable, {
|
|
1324
1363
|
path: _path,
|
|
@@ -1327,9 +1366,9 @@ export const validateJobDefinition = (() => { const _io0 = (input, _exceptionabl
|
|
|
1327
1366
|
});
|
|
1328
1367
|
})(); const _vu2 = (input, _path, _exceptionable = true) => (() => {
|
|
1329
1368
|
if (Array.isArray(input.depends_on) && input.depends_on.map((elem, _index30) => "string" === typeof elem).every(flag => flag))
|
|
1330
|
-
return
|
|
1369
|
+
return _vo26(input, _path, true && _exceptionable);
|
|
1331
1370
|
else
|
|
1332
|
-
return
|
|
1371
|
+
return _vo25(input, _path, true && _exceptionable);
|
|
1333
1372
|
})(); const __is = (input, _exceptionable = true) => "object" === typeof input && null !== input && _io0(input, true); let errors; let _report; return __typia_transform__createStandardSchema._createStandardSchema(input => {
|
|
1334
1373
|
if (false === __is(input)) {
|
|
1335
1374
|
errors = [];
|
package/dist/Jobs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/Jobs/index.ts"],"names":[],"mappings":";;;AAAA,OAAO,KAAe,MAAM,OAAO,CAAC;AAGpC,cAAc,kBAAkB,CAAA;AAChC,cAAc,0BAA0B,CAAA;AACxC,cAAc,iBAAiB,CAAA;AAwB/B,MAAM,CAAC,MAAM,qBAAqB,yvBA7BD,EAAE;;;qBAGV,EAAE;;;;;IAIT,CAAC;;AACP,CAAC
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/Jobs/index.ts"],"names":[],"mappings":";;;AAAA,OAAO,KAAe,MAAM,OAAO,CAAC;AAGpC,cAAc,kBAAkB,CAAA;AAChC,cAAc,0BAA0B,CAAA;AACxC,cAAc,iBAAiB,CAAA;AAwB/B,MAAM,CAAC,MAAM,qBAAqB,yvBA7BD,EAAE;;;qBAGV,EAAE;;;;;IAIT,CAAC;;AACP,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;04BARH,EAAG;;;;;;;;;;4CAgBJ,CAAE,SAAQ,CAAE;;;;;QAOrB,CAAC;;;;;;;;;YAMwR,CAAC;;QAAoD,CAAC;IAAW,CAAC;;;;;QAA0J,CAAC;IAAW,CAAC;;AAA8B,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;uNA5B7e,EAAG;;;;;;IAM1C,CAAC;;AACN,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6CARwB,EAAE;;;yBAGV,EAAE;;;;;QAIT,CAAC;;IACP,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iDARH,EAAG;;;;;;;;;;gDAgBJ,CAAE,SAAQ,CAAE;;;;;YAOrB,CAAC;;;;;;;;;gBAMwR,CAAC;;YAAoD,CAAC;QAAW,CAAC;;;;;YAA0J,CAAC;QAAW,CAAC;;IAA8B,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2GA5B7e,EAAG;;;;;;QAM1C,CAAC;;IACN,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAqB+E,CAAC"}
|
package/dist/Schemas/job.js
CHANGED
|
@@ -41,10 +41,25 @@ export const jobSchemas = {
|
|
|
41
41
|
]
|
|
42
42
|
},
|
|
43
43
|
Logistics: {
|
|
44
|
+
type: "object",
|
|
45
|
+
properties: {
|
|
46
|
+
send: {
|
|
47
|
+
$ref: "#/components/schemas/Logistic"
|
|
48
|
+
},
|
|
49
|
+
receive: {
|
|
50
|
+
$ref: "#/components/schemas/Logistic"
|
|
51
|
+
}
|
|
52
|
+
},
|
|
53
|
+
required: [
|
|
54
|
+
"send",
|
|
55
|
+
"receive"
|
|
56
|
+
]
|
|
57
|
+
},
|
|
58
|
+
Logistic: {
|
|
44
59
|
type: "object",
|
|
45
60
|
properties: {
|
|
46
61
|
type: {
|
|
47
|
-
$ref: "#/components/schemas/
|
|
62
|
+
$ref: "#/components/schemas/LogisticType"
|
|
48
63
|
},
|
|
49
64
|
args: {
|
|
50
65
|
$ref: "#/components/schemas/Partial__type"
|
|
@@ -55,7 +70,7 @@ export const jobSchemas = {
|
|
|
55
70
|
"args"
|
|
56
71
|
]
|
|
57
72
|
},
|
|
58
|
-
|
|
73
|
+
LogisticType: {
|
|
59
74
|
type: "string",
|
|
60
75
|
"enum": [
|
|
61
76
|
"api",
|
package/dist/Schemas/job.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"job.js","sourceRoot":"","sources":["../../src/Schemas/job.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,MAAM,CAAC,MAAM,UAAU
|
|
1
|
+
{"version":3,"file":"job.js","sourceRoot":"","sources":["../../src/Schemas/job.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,MAAM,CAAC,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAA0D,CAAC"}
|
package/package.json
CHANGED