@aws-sdk/client-sagemaker-runtime 3.927.0 → 3.929.0
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-cjs/index.js +533 -416
- package/dist-cjs/runtimeConfig.shared.js +2 -0
- package/dist-es/SageMakerRuntimeClient.js +2 -0
- package/dist-es/commands/InvokeEndpointAsyncCommand.js +3 -10
- package/dist-es/commands/InvokeEndpointCommand.js +3 -10
- package/dist-es/commands/InvokeEndpointWithResponseStreamCommand.js +3 -10
- package/dist-es/models/models_0.js +0 -39
- package/dist-es/runtimeConfig.shared.js +2 -0
- package/dist-es/schemas/schemas_0.js +519 -0
- package/dist-types/SageMakerRuntimeClient.d.ts +10 -1
- package/dist-types/models/models_0.d.ts +0 -28
- package/dist-types/runtimeConfig.browser.d.ts +1 -0
- package/dist-types/runtimeConfig.d.ts +1 -0
- package/dist-types/runtimeConfig.native.d.ts +1 -0
- package/dist-types/runtimeConfig.shared.d.ts +1 -0
- package/dist-types/schemas/schemas_0.d.ts +24 -0
- package/dist-types/ts3.4/SageMakerRuntimeClient.d.ts +4 -0
- package/dist-types/ts3.4/models/models_0.d.ts +0 -19
- package/dist-types/ts3.4/runtimeConfig.browser.d.ts +4 -0
- package/dist-types/ts3.4/runtimeConfig.d.ts +4 -0
- package/dist-types/ts3.4/runtimeConfig.native.d.ts +4 -0
- package/dist-types/ts3.4/runtimeConfig.shared.d.ts +4 -0
- package/dist-types/ts3.4/schemas/schemas_0.d.ts +29 -0
- package/package.json +5 -5
- package/dist-es/protocols/Aws_restJson1.js +0 -345
- package/dist-types/protocols/Aws_restJson1.d.ts +0 -29
- package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +0 -44
package/dist-cjs/index.js
CHANGED
|
@@ -6,6 +6,7 @@ var middlewareRecursionDetection = require('@aws-sdk/middleware-recursion-detect
|
|
|
6
6
|
var middlewareUserAgent = require('@aws-sdk/middleware-user-agent');
|
|
7
7
|
var configResolver = require('@smithy/config-resolver');
|
|
8
8
|
var core = require('@smithy/core');
|
|
9
|
+
var schema = require('@smithy/core/schema');
|
|
9
10
|
var eventstreamSerdeConfigResolver = require('@smithy/eventstream-serde-config-resolver');
|
|
10
11
|
var middlewareContentLength = require('@smithy/middleware-content-length');
|
|
11
12
|
var middlewareEndpoint = require('@smithy/middleware-endpoint');
|
|
@@ -15,8 +16,6 @@ var httpAuthSchemeProvider = require('./auth/httpAuthSchemeProvider');
|
|
|
15
16
|
var runtimeConfig = require('./runtimeConfig');
|
|
16
17
|
var regionConfigResolver = require('@aws-sdk/region-config-resolver');
|
|
17
18
|
var protocolHttp = require('@smithy/protocol-http');
|
|
18
|
-
var middlewareSerde = require('@smithy/middleware-serde');
|
|
19
|
-
var core$1 = require('@aws-sdk/core');
|
|
20
19
|
|
|
21
20
|
const resolveClientEndpointParameters = (options) => {
|
|
22
21
|
return Object.assign(options, {
|
|
@@ -93,6 +92,7 @@ class SageMakerRuntimeClient extends smithyClient.Client {
|
|
|
93
92
|
const _config_8 = httpAuthSchemeProvider.resolveHttpAuthSchemeConfig(_config_7);
|
|
94
93
|
const _config_9 = resolveRuntimeExtensions(_config_8, configuration?.extensions || []);
|
|
95
94
|
this.config = _config_9;
|
|
95
|
+
this.middlewareStack.use(schema.getSchemaSerdePlugin(this.config));
|
|
96
96
|
this.middlewareStack.use(middlewareUserAgent.getUserAgentPlugin(this.config));
|
|
97
97
|
this.middlewareStack.use(middlewareRetry.getRetryPlugin(this.config));
|
|
98
98
|
this.middlewareStack.use(middlewareContentLength.getContentLengthPlugin(this.config));
|
|
@@ -112,14 +112,14 @@ class SageMakerRuntimeClient extends smithyClient.Client {
|
|
|
112
112
|
}
|
|
113
113
|
}
|
|
114
114
|
|
|
115
|
-
class SageMakerRuntimeServiceException extends smithyClient.ServiceException {
|
|
115
|
+
let SageMakerRuntimeServiceException$1 = class SageMakerRuntimeServiceException extends smithyClient.ServiceException {
|
|
116
116
|
constructor(options) {
|
|
117
117
|
super(options);
|
|
118
118
|
Object.setPrototypeOf(this, SageMakerRuntimeServiceException.prototype);
|
|
119
119
|
}
|
|
120
|
-
}
|
|
120
|
+
};
|
|
121
121
|
|
|
122
|
-
class InternalDependencyException extends SageMakerRuntimeServiceException {
|
|
122
|
+
let InternalDependencyException$1 = class InternalDependencyException extends SageMakerRuntimeServiceException$1 {
|
|
123
123
|
name = "InternalDependencyException";
|
|
124
124
|
$fault = "server";
|
|
125
125
|
Message;
|
|
@@ -132,8 +132,8 @@ class InternalDependencyException extends SageMakerRuntimeServiceException {
|
|
|
132
132
|
Object.setPrototypeOf(this, InternalDependencyException.prototype);
|
|
133
133
|
this.Message = opts.Message;
|
|
134
134
|
}
|
|
135
|
-
}
|
|
136
|
-
class InternalFailure extends SageMakerRuntimeServiceException {
|
|
135
|
+
};
|
|
136
|
+
let InternalFailure$1 = class InternalFailure extends SageMakerRuntimeServiceException$1 {
|
|
137
137
|
name = "InternalFailure";
|
|
138
138
|
$fault = "server";
|
|
139
139
|
Message;
|
|
@@ -146,8 +146,8 @@ class InternalFailure extends SageMakerRuntimeServiceException {
|
|
|
146
146
|
Object.setPrototypeOf(this, InternalFailure.prototype);
|
|
147
147
|
this.Message = opts.Message;
|
|
148
148
|
}
|
|
149
|
-
}
|
|
150
|
-
class ModelError extends SageMakerRuntimeServiceException {
|
|
149
|
+
};
|
|
150
|
+
let ModelError$1 = class ModelError extends SageMakerRuntimeServiceException$1 {
|
|
151
151
|
name = "ModelError";
|
|
152
152
|
$fault = "client";
|
|
153
153
|
Message;
|
|
@@ -166,8 +166,8 @@ class ModelError extends SageMakerRuntimeServiceException {
|
|
|
166
166
|
this.OriginalMessage = opts.OriginalMessage;
|
|
167
167
|
this.LogStreamArn = opts.LogStreamArn;
|
|
168
168
|
}
|
|
169
|
-
}
|
|
170
|
-
class ModelNotReadyException extends SageMakerRuntimeServiceException {
|
|
169
|
+
};
|
|
170
|
+
let ModelNotReadyException$1 = class ModelNotReadyException extends SageMakerRuntimeServiceException$1 {
|
|
171
171
|
name = "ModelNotReadyException";
|
|
172
172
|
$fault = "client";
|
|
173
173
|
Message;
|
|
@@ -180,8 +180,8 @@ class ModelNotReadyException extends SageMakerRuntimeServiceException {
|
|
|
180
180
|
Object.setPrototypeOf(this, ModelNotReadyException.prototype);
|
|
181
181
|
this.Message = opts.Message;
|
|
182
182
|
}
|
|
183
|
-
}
|
|
184
|
-
class ServiceUnavailable extends SageMakerRuntimeServiceException {
|
|
183
|
+
};
|
|
184
|
+
let ServiceUnavailable$1 = class ServiceUnavailable extends SageMakerRuntimeServiceException$1 {
|
|
185
185
|
name = "ServiceUnavailable";
|
|
186
186
|
$fault = "server";
|
|
187
187
|
Message;
|
|
@@ -194,8 +194,8 @@ class ServiceUnavailable extends SageMakerRuntimeServiceException {
|
|
|
194
194
|
Object.setPrototypeOf(this, ServiceUnavailable.prototype);
|
|
195
195
|
this.Message = opts.Message;
|
|
196
196
|
}
|
|
197
|
-
}
|
|
198
|
-
class ValidationError extends SageMakerRuntimeServiceException {
|
|
197
|
+
};
|
|
198
|
+
let ValidationError$1 = class ValidationError extends SageMakerRuntimeServiceException$1 {
|
|
199
199
|
name = "ValidationError";
|
|
200
200
|
$fault = "client";
|
|
201
201
|
Message;
|
|
@@ -208,8 +208,8 @@ class ValidationError extends SageMakerRuntimeServiceException {
|
|
|
208
208
|
Object.setPrototypeOf(this, ValidationError.prototype);
|
|
209
209
|
this.Message = opts.Message;
|
|
210
210
|
}
|
|
211
|
-
}
|
|
212
|
-
class InternalStreamFailure extends SageMakerRuntimeServiceException {
|
|
211
|
+
};
|
|
212
|
+
let InternalStreamFailure$1 = class InternalStreamFailure extends SageMakerRuntimeServiceException$1 {
|
|
213
213
|
name = "InternalStreamFailure";
|
|
214
214
|
$fault = "server";
|
|
215
215
|
Message;
|
|
@@ -222,8 +222,8 @@ class InternalStreamFailure extends SageMakerRuntimeServiceException {
|
|
|
222
222
|
Object.setPrototypeOf(this, InternalStreamFailure.prototype);
|
|
223
223
|
this.Message = opts.Message;
|
|
224
224
|
}
|
|
225
|
-
}
|
|
226
|
-
class ModelStreamError extends SageMakerRuntimeServiceException {
|
|
225
|
+
};
|
|
226
|
+
let ModelStreamError$1 = class ModelStreamError extends SageMakerRuntimeServiceException$1 {
|
|
227
227
|
name = "ModelStreamError";
|
|
228
228
|
$fault = "client";
|
|
229
229
|
Message;
|
|
@@ -238,7 +238,7 @@ class ModelStreamError extends SageMakerRuntimeServiceException {
|
|
|
238
238
|
this.Message = opts.Message;
|
|
239
239
|
this.ErrorCode = opts.ErrorCode;
|
|
240
240
|
}
|
|
241
|
-
}
|
|
241
|
+
};
|
|
242
242
|
exports.ResponseStream = void 0;
|
|
243
243
|
(function (ResponseStream) {
|
|
244
244
|
ResponseStream.visit = (value, visitor) => {
|
|
@@ -251,399 +251,533 @@ exports.ResponseStream = void 0;
|
|
|
251
251
|
return visitor._(value.$unknown[0], value.$unknown[1]);
|
|
252
252
|
};
|
|
253
253
|
})(exports.ResponseStream || (exports.ResponseStream = {}));
|
|
254
|
-
const InvokeEndpointInputFilterSensitiveLog = (obj) => ({
|
|
255
|
-
...obj,
|
|
256
|
-
...(obj.Body && { Body: smithyClient.SENSITIVE_STRING }),
|
|
257
|
-
...(obj.CustomAttributes && { CustomAttributes: smithyClient.SENSITIVE_STRING }),
|
|
258
|
-
});
|
|
259
|
-
const InvokeEndpointOutputFilterSensitiveLog = (obj) => ({
|
|
260
|
-
...obj,
|
|
261
|
-
...(obj.Body && { Body: smithyClient.SENSITIVE_STRING }),
|
|
262
|
-
...(obj.CustomAttributes && { CustomAttributes: smithyClient.SENSITIVE_STRING }),
|
|
263
|
-
});
|
|
264
|
-
const InvokeEndpointAsyncInputFilterSensitiveLog = (obj) => ({
|
|
265
|
-
...obj,
|
|
266
|
-
...(obj.CustomAttributes && { CustomAttributes: smithyClient.SENSITIVE_STRING }),
|
|
267
|
-
});
|
|
268
|
-
const InvokeEndpointWithResponseStreamInputFilterSensitiveLog = (obj) => ({
|
|
269
|
-
...obj,
|
|
270
|
-
...(obj.Body && { Body: smithyClient.SENSITIVE_STRING }),
|
|
271
|
-
...(obj.CustomAttributes && { CustomAttributes: smithyClient.SENSITIVE_STRING }),
|
|
272
|
-
});
|
|
273
|
-
const PayloadPartFilterSensitiveLog = (obj) => ({
|
|
274
|
-
...obj,
|
|
275
|
-
...(obj.Bytes && { Bytes: smithyClient.SENSITIVE_STRING }),
|
|
276
|
-
});
|
|
277
|
-
const ResponseStreamFilterSensitiveLog = (obj) => {
|
|
278
|
-
if (obj.PayloadPart !== undefined)
|
|
279
|
-
return { PayloadPart: PayloadPartFilterSensitiveLog(obj.PayloadPart) };
|
|
280
|
-
if (obj.ModelStreamError !== undefined)
|
|
281
|
-
return { ModelStreamError: obj.ModelStreamError };
|
|
282
|
-
if (obj.InternalStreamFailure !== undefined)
|
|
283
|
-
return { InternalStreamFailure: obj.InternalStreamFailure };
|
|
284
|
-
if (obj.$unknown !== undefined)
|
|
285
|
-
return { [obj.$unknown[0]]: "UNKNOWN" };
|
|
286
|
-
};
|
|
287
|
-
const InvokeEndpointWithResponseStreamOutputFilterSensitiveLog = (obj) => ({
|
|
288
|
-
...obj,
|
|
289
|
-
...(obj.Body && { Body: "STREAMING_CONTENT" }),
|
|
290
|
-
...(obj.CustomAttributes && { CustomAttributes: smithyClient.SENSITIVE_STRING }),
|
|
291
|
-
});
|
|
292
254
|
|
|
293
|
-
const se_InvokeEndpointCommand = async (input, context) => {
|
|
294
|
-
const b = core.requestBuilder(input, context);
|
|
295
|
-
const headers = smithyClient.map({}, smithyClient.isSerializableHeaderValue, {
|
|
296
|
-
[_ct]: input[_CT] || "application/octet-stream",
|
|
297
|
-
[_a]: input[_A],
|
|
298
|
-
[_xasca]: input[_CA],
|
|
299
|
-
[_xastm]: input[_TM],
|
|
300
|
-
[_xastv]: input[_TV],
|
|
301
|
-
[_xastch]: input[_TCH],
|
|
302
|
-
[_xasii]: input[_II],
|
|
303
|
-
[_xasee]: input[_EE],
|
|
304
|
-
[_xasic]: input[_ICN],
|
|
305
|
-
[_xassi]: input[_SI],
|
|
306
|
-
});
|
|
307
|
-
b.bp("/endpoints/{EndpointName}/invocations");
|
|
308
|
-
b.p("EndpointName", () => input.EndpointName, "{EndpointName}", false);
|
|
309
|
-
let body;
|
|
310
|
-
if (input.Body !== undefined) {
|
|
311
|
-
body = input.Body;
|
|
312
|
-
}
|
|
313
|
-
b.m("POST").h(headers).b(body);
|
|
314
|
-
return b.build();
|
|
315
|
-
};
|
|
316
|
-
const se_InvokeEndpointAsyncCommand = async (input, context) => {
|
|
317
|
-
const b = core.requestBuilder(input, context);
|
|
318
|
-
const headers = smithyClient.map({}, smithyClient.isSerializableHeaderValue, {
|
|
319
|
-
[_xasct]: input[_CT],
|
|
320
|
-
[_xasa]: input[_A],
|
|
321
|
-
[_xasca]: input[_CA],
|
|
322
|
-
[_xasii]: input[_II],
|
|
323
|
-
[_xasi]: input[_IL],
|
|
324
|
-
[_xasr]: [() => smithyClient.isSerializableHeaderValue(input[_RTTLS]), () => input[_RTTLS].toString()],
|
|
325
|
-
[_xasi_]: [() => smithyClient.isSerializableHeaderValue(input[_ITS]), () => input[_ITS].toString()],
|
|
326
|
-
});
|
|
327
|
-
b.bp("/endpoints/{EndpointName}/async-invocations");
|
|
328
|
-
b.p("EndpointName", () => input.EndpointName, "{EndpointName}", false);
|
|
329
|
-
let body;
|
|
330
|
-
b.m("POST").h(headers).b(body);
|
|
331
|
-
return b.build();
|
|
332
|
-
};
|
|
333
|
-
const se_InvokeEndpointWithResponseStreamCommand = async (input, context) => {
|
|
334
|
-
const b = core.requestBuilder(input, context);
|
|
335
|
-
const headers = smithyClient.map({}, smithyClient.isSerializableHeaderValue, {
|
|
336
|
-
[_ct]: input[_CT] || "application/octet-stream",
|
|
337
|
-
[_xasa]: input[_A],
|
|
338
|
-
[_xasca]: input[_CA],
|
|
339
|
-
[_xastv]: input[_TV],
|
|
340
|
-
[_xastch]: input[_TCH],
|
|
341
|
-
[_xasii]: input[_II],
|
|
342
|
-
[_xasic]: input[_ICN],
|
|
343
|
-
[_xassi]: input[_SI],
|
|
344
|
-
});
|
|
345
|
-
b.bp("/endpoints/{EndpointName}/invocations-response-stream");
|
|
346
|
-
b.p("EndpointName", () => input.EndpointName, "{EndpointName}", false);
|
|
347
|
-
let body;
|
|
348
|
-
if (input.Body !== undefined) {
|
|
349
|
-
body = input.Body;
|
|
350
|
-
}
|
|
351
|
-
b.m("POST").h(headers).b(body);
|
|
352
|
-
return b.build();
|
|
353
|
-
};
|
|
354
|
-
const de_InvokeEndpointCommand = async (output, context) => {
|
|
355
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
356
|
-
return de_CommandError(output, context);
|
|
357
|
-
}
|
|
358
|
-
const contents = smithyClient.map({
|
|
359
|
-
$metadata: deserializeMetadata(output),
|
|
360
|
-
[_CT]: [, output.headers[_ct]],
|
|
361
|
-
[_IPV]: [, output.headers[_xaipv]],
|
|
362
|
-
[_CA]: [, output.headers[_xasca]],
|
|
363
|
-
[_NSI]: [, output.headers[_xasnsi]],
|
|
364
|
-
[_CSI]: [, output.headers[_xascsi]],
|
|
365
|
-
});
|
|
366
|
-
const data = await smithyClient.collectBody(output.body, context);
|
|
367
|
-
contents.Body = data;
|
|
368
|
-
return contents;
|
|
369
|
-
};
|
|
370
|
-
const de_InvokeEndpointAsyncCommand = async (output, context) => {
|
|
371
|
-
if (output.statusCode !== 202 && output.statusCode >= 300) {
|
|
372
|
-
return de_CommandError(output, context);
|
|
373
|
-
}
|
|
374
|
-
const contents = smithyClient.map({
|
|
375
|
-
$metadata: deserializeMetadata(output),
|
|
376
|
-
[_OL]: [, output.headers[_xaso]],
|
|
377
|
-
[_FL]: [, output.headers[_xasf]],
|
|
378
|
-
});
|
|
379
|
-
const data = smithyClient.expectNonNull(smithyClient.expectObject(await core$1.parseJsonBody(output.body, context)), "body");
|
|
380
|
-
const doc = smithyClient.take(data, {
|
|
381
|
-
InferenceId: smithyClient.expectString,
|
|
382
|
-
});
|
|
383
|
-
Object.assign(contents, doc);
|
|
384
|
-
return contents;
|
|
385
|
-
};
|
|
386
|
-
const de_InvokeEndpointWithResponseStreamCommand = async (output, context) => {
|
|
387
|
-
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
388
|
-
return de_CommandError(output, context);
|
|
389
|
-
}
|
|
390
|
-
const contents = smithyClient.map({
|
|
391
|
-
$metadata: deserializeMetadata(output),
|
|
392
|
-
[_CT]: [, output.headers[_xasct]],
|
|
393
|
-
[_IPV]: [, output.headers[_xaipv]],
|
|
394
|
-
[_CA]: [, output.headers[_xasca]],
|
|
395
|
-
});
|
|
396
|
-
const data = output.body;
|
|
397
|
-
contents.Body = de_ResponseStream(data, context);
|
|
398
|
-
return contents;
|
|
399
|
-
};
|
|
400
|
-
const de_CommandError = async (output, context) => {
|
|
401
|
-
const parsedOutput = {
|
|
402
|
-
...output,
|
|
403
|
-
body: await core$1.parseJsonErrorBody(output.body, context),
|
|
404
|
-
};
|
|
405
|
-
const errorCode = core$1.loadRestJsonErrorCode(output, parsedOutput.body);
|
|
406
|
-
switch (errorCode) {
|
|
407
|
-
case "InternalDependencyException":
|
|
408
|
-
case "com.amazonaws.sagemakerruntime#InternalDependencyException":
|
|
409
|
-
throw await de_InternalDependencyExceptionRes(parsedOutput);
|
|
410
|
-
case "InternalFailure":
|
|
411
|
-
case "com.amazonaws.sagemakerruntime#InternalFailure":
|
|
412
|
-
throw await de_InternalFailureRes(parsedOutput);
|
|
413
|
-
case "ModelError":
|
|
414
|
-
case "com.amazonaws.sagemakerruntime#ModelError":
|
|
415
|
-
throw await de_ModelErrorRes(parsedOutput);
|
|
416
|
-
case "ModelNotReadyException":
|
|
417
|
-
case "com.amazonaws.sagemakerruntime#ModelNotReadyException":
|
|
418
|
-
throw await de_ModelNotReadyExceptionRes(parsedOutput);
|
|
419
|
-
case "ServiceUnavailable":
|
|
420
|
-
case "com.amazonaws.sagemakerruntime#ServiceUnavailable":
|
|
421
|
-
throw await de_ServiceUnavailableRes(parsedOutput);
|
|
422
|
-
case "ValidationError":
|
|
423
|
-
case "com.amazonaws.sagemakerruntime#ValidationError":
|
|
424
|
-
throw await de_ValidationErrorRes(parsedOutput);
|
|
425
|
-
case "InternalStreamFailure":
|
|
426
|
-
case "com.amazonaws.sagemakerruntime#InternalStreamFailure":
|
|
427
|
-
throw await de_InternalStreamFailureRes(parsedOutput);
|
|
428
|
-
case "ModelStreamError":
|
|
429
|
-
case "com.amazonaws.sagemakerruntime#ModelStreamError":
|
|
430
|
-
throw await de_ModelStreamErrorRes(parsedOutput);
|
|
431
|
-
default:
|
|
432
|
-
const parsedBody = parsedOutput.body;
|
|
433
|
-
return throwDefaultError({
|
|
434
|
-
output,
|
|
435
|
-
parsedBody,
|
|
436
|
-
errorCode,
|
|
437
|
-
});
|
|
438
|
-
}
|
|
439
|
-
};
|
|
440
|
-
const throwDefaultError = smithyClient.withBaseException(SageMakerRuntimeServiceException);
|
|
441
|
-
const de_InternalDependencyExceptionRes = async (parsedOutput, context) => {
|
|
442
|
-
const contents = smithyClient.map({});
|
|
443
|
-
const data = parsedOutput.body;
|
|
444
|
-
const doc = smithyClient.take(data, {
|
|
445
|
-
Message: smithyClient.expectString,
|
|
446
|
-
});
|
|
447
|
-
Object.assign(contents, doc);
|
|
448
|
-
const exception = new InternalDependencyException({
|
|
449
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
450
|
-
...contents,
|
|
451
|
-
});
|
|
452
|
-
return smithyClient.decorateServiceException(exception, parsedOutput.body);
|
|
453
|
-
};
|
|
454
|
-
const de_InternalFailureRes = async (parsedOutput, context) => {
|
|
455
|
-
const contents = smithyClient.map({});
|
|
456
|
-
const data = parsedOutput.body;
|
|
457
|
-
const doc = smithyClient.take(data, {
|
|
458
|
-
Message: smithyClient.expectString,
|
|
459
|
-
});
|
|
460
|
-
Object.assign(contents, doc);
|
|
461
|
-
const exception = new InternalFailure({
|
|
462
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
463
|
-
...contents,
|
|
464
|
-
});
|
|
465
|
-
return smithyClient.decorateServiceException(exception, parsedOutput.body);
|
|
466
|
-
};
|
|
467
|
-
const de_InternalStreamFailureRes = async (parsedOutput, context) => {
|
|
468
|
-
const contents = smithyClient.map({});
|
|
469
|
-
const data = parsedOutput.body;
|
|
470
|
-
const doc = smithyClient.take(data, {
|
|
471
|
-
Message: smithyClient.expectString,
|
|
472
|
-
});
|
|
473
|
-
Object.assign(contents, doc);
|
|
474
|
-
const exception = new InternalStreamFailure({
|
|
475
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
476
|
-
...contents,
|
|
477
|
-
});
|
|
478
|
-
return smithyClient.decorateServiceException(exception, parsedOutput.body);
|
|
479
|
-
};
|
|
480
|
-
const de_ModelErrorRes = async (parsedOutput, context) => {
|
|
481
|
-
const contents = smithyClient.map({});
|
|
482
|
-
const data = parsedOutput.body;
|
|
483
|
-
const doc = smithyClient.take(data, {
|
|
484
|
-
LogStreamArn: smithyClient.expectString,
|
|
485
|
-
Message: smithyClient.expectString,
|
|
486
|
-
OriginalMessage: smithyClient.expectString,
|
|
487
|
-
OriginalStatusCode: smithyClient.expectInt32,
|
|
488
|
-
});
|
|
489
|
-
Object.assign(contents, doc);
|
|
490
|
-
const exception = new ModelError({
|
|
491
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
492
|
-
...contents,
|
|
493
|
-
});
|
|
494
|
-
return smithyClient.decorateServiceException(exception, parsedOutput.body);
|
|
495
|
-
};
|
|
496
|
-
const de_ModelNotReadyExceptionRes = async (parsedOutput, context) => {
|
|
497
|
-
const contents = smithyClient.map({});
|
|
498
|
-
const data = parsedOutput.body;
|
|
499
|
-
const doc = smithyClient.take(data, {
|
|
500
|
-
Message: smithyClient.expectString,
|
|
501
|
-
});
|
|
502
|
-
Object.assign(contents, doc);
|
|
503
|
-
const exception = new ModelNotReadyException({
|
|
504
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
505
|
-
...contents,
|
|
506
|
-
});
|
|
507
|
-
return smithyClient.decorateServiceException(exception, parsedOutput.body);
|
|
508
|
-
};
|
|
509
|
-
const de_ModelStreamErrorRes = async (parsedOutput, context) => {
|
|
510
|
-
const contents = smithyClient.map({});
|
|
511
|
-
const data = parsedOutput.body;
|
|
512
|
-
const doc = smithyClient.take(data, {
|
|
513
|
-
ErrorCode: smithyClient.expectString,
|
|
514
|
-
Message: smithyClient.expectString,
|
|
515
|
-
});
|
|
516
|
-
Object.assign(contents, doc);
|
|
517
|
-
const exception = new ModelStreamError({
|
|
518
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
519
|
-
...contents,
|
|
520
|
-
});
|
|
521
|
-
return smithyClient.decorateServiceException(exception, parsedOutput.body);
|
|
522
|
-
};
|
|
523
|
-
const de_ServiceUnavailableRes = async (parsedOutput, context) => {
|
|
524
|
-
const contents = smithyClient.map({});
|
|
525
|
-
const data = parsedOutput.body;
|
|
526
|
-
const doc = smithyClient.take(data, {
|
|
527
|
-
Message: smithyClient.expectString,
|
|
528
|
-
});
|
|
529
|
-
Object.assign(contents, doc);
|
|
530
|
-
const exception = new ServiceUnavailable({
|
|
531
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
532
|
-
...contents,
|
|
533
|
-
});
|
|
534
|
-
return smithyClient.decorateServiceException(exception, parsedOutput.body);
|
|
535
|
-
};
|
|
536
|
-
const de_ValidationErrorRes = async (parsedOutput, context) => {
|
|
537
|
-
const contents = smithyClient.map({});
|
|
538
|
-
const data = parsedOutput.body;
|
|
539
|
-
const doc = smithyClient.take(data, {
|
|
540
|
-
Message: smithyClient.expectString,
|
|
541
|
-
});
|
|
542
|
-
Object.assign(contents, doc);
|
|
543
|
-
const exception = new ValidationError({
|
|
544
|
-
$metadata: deserializeMetadata(parsedOutput),
|
|
545
|
-
...contents,
|
|
546
|
-
});
|
|
547
|
-
return smithyClient.decorateServiceException(exception, parsedOutput.body);
|
|
548
|
-
};
|
|
549
|
-
const de_ResponseStream = (output, context) => {
|
|
550
|
-
return context.eventStreamMarshaller.deserialize(output, async (event) => {
|
|
551
|
-
if (event["PayloadPart"] != null) {
|
|
552
|
-
return {
|
|
553
|
-
PayloadPart: await de_PayloadPart_event(event["PayloadPart"]),
|
|
554
|
-
};
|
|
555
|
-
}
|
|
556
|
-
if (event["ModelStreamError"] != null) {
|
|
557
|
-
return {
|
|
558
|
-
ModelStreamError: await de_ModelStreamError_event(event["ModelStreamError"], context),
|
|
559
|
-
};
|
|
560
|
-
}
|
|
561
|
-
if (event["InternalStreamFailure"] != null) {
|
|
562
|
-
return {
|
|
563
|
-
InternalStreamFailure: await de_InternalStreamFailure_event(event["InternalStreamFailure"], context),
|
|
564
|
-
};
|
|
565
|
-
}
|
|
566
|
-
return { $unknown: event };
|
|
567
|
-
});
|
|
568
|
-
};
|
|
569
|
-
const de_InternalStreamFailure_event = async (output, context) => {
|
|
570
|
-
const parsedOutput = {
|
|
571
|
-
...output,
|
|
572
|
-
body: await core$1.parseJsonBody(output.body, context),
|
|
573
|
-
};
|
|
574
|
-
return de_InternalStreamFailureRes(parsedOutput);
|
|
575
|
-
};
|
|
576
|
-
const de_ModelStreamError_event = async (output, context) => {
|
|
577
|
-
const parsedOutput = {
|
|
578
|
-
...output,
|
|
579
|
-
body: await core$1.parseJsonBody(output.body, context),
|
|
580
|
-
};
|
|
581
|
-
return de_ModelStreamErrorRes(parsedOutput);
|
|
582
|
-
};
|
|
583
|
-
const de_PayloadPart_event = async (output, context) => {
|
|
584
|
-
const contents = {};
|
|
585
|
-
contents.Bytes = output.body;
|
|
586
|
-
return contents;
|
|
587
|
-
};
|
|
588
|
-
const deserializeMetadata = (output) => ({
|
|
589
|
-
httpStatusCode: output.statusCode,
|
|
590
|
-
requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
|
|
591
|
-
extendedRequestId: output.headers["x-amz-id-2"],
|
|
592
|
-
cfId: output.headers["x-amz-cf-id"],
|
|
593
|
-
});
|
|
594
255
|
const _A = "Accept";
|
|
256
|
+
const _B = "Body";
|
|
257
|
+
const _BB = "BodyBlob";
|
|
258
|
+
const _By = "Bytes";
|
|
595
259
|
const _CA = "CustomAttributes";
|
|
260
|
+
const _CAH = "CustomAttributesHeader";
|
|
596
261
|
const _CSI = "ClosedSessionId";
|
|
597
262
|
const _CT = "ContentType";
|
|
263
|
+
const _CT_ = "Content-Type";
|
|
264
|
+
const _EC = "ErrorCode";
|
|
598
265
|
const _EE = "EnableExplanations";
|
|
266
|
+
const _EN = "EndpointName";
|
|
599
267
|
const _FL = "FailureLocation";
|
|
600
268
|
const _ICN = "InferenceComponentName";
|
|
269
|
+
const _IDE = "InternalDependencyException";
|
|
270
|
+
const _IE = "InvokeEndpoint";
|
|
271
|
+
const _IEA = "InvokeEndpointAsync";
|
|
272
|
+
const _IEAI = "InvokeEndpointAsyncInput";
|
|
273
|
+
const _IEAO = "InvokeEndpointAsyncOutput";
|
|
274
|
+
const _IEI = "InvokeEndpointInput";
|
|
275
|
+
const _IEO = "InvokeEndpointOutput";
|
|
276
|
+
const _IEWRS = "InvokeEndpointWithResponseStream";
|
|
277
|
+
const _IEWRSI = "InvokeEndpointWithResponseStreamInput";
|
|
278
|
+
const _IEWRSO = "InvokeEndpointWithResponseStreamOutput";
|
|
279
|
+
const _IF = "InternalFailure";
|
|
601
280
|
const _II = "InferenceId";
|
|
602
281
|
const _IL = "InputLocation";
|
|
603
282
|
const _IPV = "InvokedProductionVariant";
|
|
283
|
+
const _ISF = "InternalStreamFailure";
|
|
604
284
|
const _ITS = "InvocationTimeoutSeconds";
|
|
285
|
+
const _LSA = "LogStreamArn";
|
|
286
|
+
const _M = "Message";
|
|
287
|
+
const _ME = "ModelError";
|
|
288
|
+
const _MNRE = "ModelNotReadyException";
|
|
289
|
+
const _MSE = "ModelStreamError";
|
|
605
290
|
const _NSI = "NewSessionId";
|
|
606
291
|
const _OL = "OutputLocation";
|
|
292
|
+
const _OM = "OriginalMessage";
|
|
293
|
+
const _OSC = "OriginalStatusCode";
|
|
294
|
+
const _PB = "PartBlob";
|
|
295
|
+
const _PP = "PayloadPart";
|
|
296
|
+
const _RS = "ResponseStream";
|
|
607
297
|
const _RTTLS = "RequestTTLSeconds";
|
|
608
298
|
const _SI = "SessionId";
|
|
299
|
+
const _SU = "ServiceUnavailable";
|
|
609
300
|
const _TCH = "TargetContainerHostname";
|
|
610
301
|
const _TM = "TargetModel";
|
|
611
302
|
const _TV = "TargetVariant";
|
|
612
|
-
const
|
|
613
|
-
const
|
|
614
|
-
const
|
|
615
|
-
const
|
|
616
|
-
const
|
|
617
|
-
const
|
|
618
|
-
const
|
|
619
|
-
const
|
|
620
|
-
const
|
|
621
|
-
const
|
|
622
|
-
const
|
|
623
|
-
const
|
|
624
|
-
const
|
|
625
|
-
const
|
|
626
|
-
const
|
|
627
|
-
const
|
|
628
|
-
const
|
|
629
|
-
const
|
|
630
|
-
const
|
|
631
|
-
const
|
|
303
|
+
const _VE = "ValidationError";
|
|
304
|
+
const _XASA = "X-Amzn-SageMaker-Accept";
|
|
305
|
+
const _XASCA = "X-Amzn-SageMaker-Custom-Attributes";
|
|
306
|
+
const _XASCSI = "X-Amzn-SageMaker-Closed-Session-Id";
|
|
307
|
+
const _XASCT = "X-Amzn-SageMaker-Content-Type";
|
|
308
|
+
const _XASEE = "X-Amzn-SageMaker-Enable-Explanations";
|
|
309
|
+
const _XASF = "X-Amzn-SageMaker-FailureLocation";
|
|
310
|
+
const _XASI = "X-Amzn-SageMaker-InputLocation";
|
|
311
|
+
const _XASIC = "X-Amzn-SageMaker-Inference-Component";
|
|
312
|
+
const _XASII = "X-Amzn-SageMaker-Inference-Id";
|
|
313
|
+
const _XASI_ = "X-Amzn-SageMaker-InvocationTimeoutSeconds";
|
|
314
|
+
const _XASNSI = "X-Amzn-SageMaker-New-Session-Id";
|
|
315
|
+
const _XASO = "X-Amzn-SageMaker-OutputLocation";
|
|
316
|
+
const _XASR = "X-Amzn-SageMaker-RequestTTLSeconds";
|
|
317
|
+
const _XASSI = "X-Amzn-SageMaker-Session-Id";
|
|
318
|
+
const _XASTCH = "X-Amzn-SageMaker-Target-Container-Hostname";
|
|
319
|
+
const _XASTM = "X-Amzn-SageMaker-Target-Model";
|
|
320
|
+
const _XASTV = "X-Amzn-SageMaker-Target-Variant";
|
|
321
|
+
const _aQE = "awsQueryError";
|
|
322
|
+
const _c = "client";
|
|
323
|
+
const _e = "error";
|
|
324
|
+
const _eP = "eventPayload";
|
|
325
|
+
const _h = "http";
|
|
326
|
+
const _hE = "httpError";
|
|
327
|
+
const _hH = "httpHeader";
|
|
328
|
+
const _s = "server";
|
|
329
|
+
const _sm = "smithy.ts.sdk.synthetic.com.amazonaws.sagemakerruntime";
|
|
330
|
+
const _st = "streaming";
|
|
331
|
+
const _xAIPV = "x-Amzn-Invoked-Production-Variant";
|
|
332
|
+
const n0 = "com.amazonaws.sagemakerruntime";
|
|
333
|
+
var BodyBlob = [0, n0, _BB, 8, 21];
|
|
334
|
+
var CustomAttributesHeader = [0, n0, _CAH, 8, 0];
|
|
335
|
+
var PartBlob = [0, n0, _PB, 8, 21];
|
|
336
|
+
var InternalDependencyException = [
|
|
337
|
+
-3,
|
|
338
|
+
n0,
|
|
339
|
+
_IDE,
|
|
340
|
+
{
|
|
341
|
+
[_e]: _s,
|
|
342
|
+
[_hE]: 530,
|
|
343
|
+
},
|
|
344
|
+
[_M],
|
|
345
|
+
[0],
|
|
346
|
+
];
|
|
347
|
+
schema.TypeRegistry.for(n0).registerError(InternalDependencyException, InternalDependencyException$1);
|
|
348
|
+
var InternalFailure = [
|
|
349
|
+
-3,
|
|
350
|
+
n0,
|
|
351
|
+
_IF,
|
|
352
|
+
{
|
|
353
|
+
[_e]: _s,
|
|
354
|
+
[_hE]: 500,
|
|
355
|
+
},
|
|
356
|
+
[_M],
|
|
357
|
+
[0],
|
|
358
|
+
];
|
|
359
|
+
schema.TypeRegistry.for(n0).registerError(InternalFailure, InternalFailure$1);
|
|
360
|
+
var InternalStreamFailure = [
|
|
361
|
+
-3,
|
|
362
|
+
n0,
|
|
363
|
+
_ISF,
|
|
364
|
+
{
|
|
365
|
+
[_e]: _s,
|
|
366
|
+
},
|
|
367
|
+
[_M],
|
|
368
|
+
[0],
|
|
369
|
+
];
|
|
370
|
+
schema.TypeRegistry.for(n0).registerError(InternalStreamFailure, InternalStreamFailure$1);
|
|
371
|
+
var InvokeEndpointAsyncInput = [
|
|
372
|
+
3,
|
|
373
|
+
n0,
|
|
374
|
+
_IEAI,
|
|
375
|
+
0,
|
|
376
|
+
[_EN, _CT, _A, _CA, _II, _IL, _RTTLS, _ITS],
|
|
377
|
+
[
|
|
378
|
+
[0, 1],
|
|
379
|
+
[
|
|
380
|
+
0,
|
|
381
|
+
{
|
|
382
|
+
[_hH]: _XASCT,
|
|
383
|
+
},
|
|
384
|
+
],
|
|
385
|
+
[
|
|
386
|
+
0,
|
|
387
|
+
{
|
|
388
|
+
[_hH]: _XASA,
|
|
389
|
+
},
|
|
390
|
+
],
|
|
391
|
+
[
|
|
392
|
+
() => CustomAttributesHeader,
|
|
393
|
+
{
|
|
394
|
+
[_hH]: _XASCA,
|
|
395
|
+
},
|
|
396
|
+
],
|
|
397
|
+
[
|
|
398
|
+
0,
|
|
399
|
+
{
|
|
400
|
+
[_hH]: _XASII,
|
|
401
|
+
},
|
|
402
|
+
],
|
|
403
|
+
[
|
|
404
|
+
0,
|
|
405
|
+
{
|
|
406
|
+
[_hH]: _XASI,
|
|
407
|
+
},
|
|
408
|
+
],
|
|
409
|
+
[
|
|
410
|
+
1,
|
|
411
|
+
{
|
|
412
|
+
[_hH]: _XASR,
|
|
413
|
+
},
|
|
414
|
+
],
|
|
415
|
+
[
|
|
416
|
+
1,
|
|
417
|
+
{
|
|
418
|
+
[_hH]: _XASI_,
|
|
419
|
+
},
|
|
420
|
+
],
|
|
421
|
+
],
|
|
422
|
+
];
|
|
423
|
+
var InvokeEndpointAsyncOutput = [
|
|
424
|
+
3,
|
|
425
|
+
n0,
|
|
426
|
+
_IEAO,
|
|
427
|
+
0,
|
|
428
|
+
[_II, _OL, _FL],
|
|
429
|
+
[
|
|
430
|
+
0,
|
|
431
|
+
[
|
|
432
|
+
0,
|
|
433
|
+
{
|
|
434
|
+
[_hH]: _XASO,
|
|
435
|
+
},
|
|
436
|
+
],
|
|
437
|
+
[
|
|
438
|
+
0,
|
|
439
|
+
{
|
|
440
|
+
[_hH]: _XASF,
|
|
441
|
+
},
|
|
442
|
+
],
|
|
443
|
+
],
|
|
444
|
+
];
|
|
445
|
+
var InvokeEndpointInput = [
|
|
446
|
+
3,
|
|
447
|
+
n0,
|
|
448
|
+
_IEI,
|
|
449
|
+
0,
|
|
450
|
+
[_EN, _B, _CT, _A, _CA, _TM, _TV, _TCH, _II, _EE, _ICN, _SI],
|
|
451
|
+
[
|
|
452
|
+
[0, 1],
|
|
453
|
+
[() => BodyBlob, 16],
|
|
454
|
+
[
|
|
455
|
+
0,
|
|
456
|
+
{
|
|
457
|
+
[_hH]: _CT_,
|
|
458
|
+
},
|
|
459
|
+
],
|
|
460
|
+
[
|
|
461
|
+
0,
|
|
462
|
+
{
|
|
463
|
+
[_hH]: _A,
|
|
464
|
+
},
|
|
465
|
+
],
|
|
466
|
+
[
|
|
467
|
+
() => CustomAttributesHeader,
|
|
468
|
+
{
|
|
469
|
+
[_hH]: _XASCA,
|
|
470
|
+
},
|
|
471
|
+
],
|
|
472
|
+
[
|
|
473
|
+
0,
|
|
474
|
+
{
|
|
475
|
+
[_hH]: _XASTM,
|
|
476
|
+
},
|
|
477
|
+
],
|
|
478
|
+
[
|
|
479
|
+
0,
|
|
480
|
+
{
|
|
481
|
+
[_hH]: _XASTV,
|
|
482
|
+
},
|
|
483
|
+
],
|
|
484
|
+
[
|
|
485
|
+
0,
|
|
486
|
+
{
|
|
487
|
+
[_hH]: _XASTCH,
|
|
488
|
+
},
|
|
489
|
+
],
|
|
490
|
+
[
|
|
491
|
+
0,
|
|
492
|
+
{
|
|
493
|
+
[_hH]: _XASII,
|
|
494
|
+
},
|
|
495
|
+
],
|
|
496
|
+
[
|
|
497
|
+
0,
|
|
498
|
+
{
|
|
499
|
+
[_hH]: _XASEE,
|
|
500
|
+
},
|
|
501
|
+
],
|
|
502
|
+
[
|
|
503
|
+
0,
|
|
504
|
+
{
|
|
505
|
+
[_hH]: _XASIC,
|
|
506
|
+
},
|
|
507
|
+
],
|
|
508
|
+
[
|
|
509
|
+
0,
|
|
510
|
+
{
|
|
511
|
+
[_hH]: _XASSI,
|
|
512
|
+
},
|
|
513
|
+
],
|
|
514
|
+
],
|
|
515
|
+
];
|
|
516
|
+
var InvokeEndpointOutput = [
|
|
517
|
+
3,
|
|
518
|
+
n0,
|
|
519
|
+
_IEO,
|
|
520
|
+
0,
|
|
521
|
+
[_B, _CT, _IPV, _CA, _NSI, _CSI],
|
|
522
|
+
[
|
|
523
|
+
[() => BodyBlob, 16],
|
|
524
|
+
[
|
|
525
|
+
0,
|
|
526
|
+
{
|
|
527
|
+
[_hH]: _CT_,
|
|
528
|
+
},
|
|
529
|
+
],
|
|
530
|
+
[
|
|
531
|
+
0,
|
|
532
|
+
{
|
|
533
|
+
[_hH]: _xAIPV,
|
|
534
|
+
},
|
|
535
|
+
],
|
|
536
|
+
[
|
|
537
|
+
() => CustomAttributesHeader,
|
|
538
|
+
{
|
|
539
|
+
[_hH]: _XASCA,
|
|
540
|
+
},
|
|
541
|
+
],
|
|
542
|
+
[
|
|
543
|
+
0,
|
|
544
|
+
{
|
|
545
|
+
[_hH]: _XASNSI,
|
|
546
|
+
},
|
|
547
|
+
],
|
|
548
|
+
[
|
|
549
|
+
0,
|
|
550
|
+
{
|
|
551
|
+
[_hH]: _XASCSI,
|
|
552
|
+
},
|
|
553
|
+
],
|
|
554
|
+
],
|
|
555
|
+
];
|
|
556
|
+
var InvokeEndpointWithResponseStreamInput = [
|
|
557
|
+
3,
|
|
558
|
+
n0,
|
|
559
|
+
_IEWRSI,
|
|
560
|
+
0,
|
|
561
|
+
[_EN, _B, _CT, _A, _CA, _TV, _TCH, _II, _ICN, _SI],
|
|
562
|
+
[
|
|
563
|
+
[0, 1],
|
|
564
|
+
[() => BodyBlob, 16],
|
|
565
|
+
[
|
|
566
|
+
0,
|
|
567
|
+
{
|
|
568
|
+
[_hH]: _CT_,
|
|
569
|
+
},
|
|
570
|
+
],
|
|
571
|
+
[
|
|
572
|
+
0,
|
|
573
|
+
{
|
|
574
|
+
[_hH]: _XASA,
|
|
575
|
+
},
|
|
576
|
+
],
|
|
577
|
+
[
|
|
578
|
+
() => CustomAttributesHeader,
|
|
579
|
+
{
|
|
580
|
+
[_hH]: _XASCA,
|
|
581
|
+
},
|
|
582
|
+
],
|
|
583
|
+
[
|
|
584
|
+
0,
|
|
585
|
+
{
|
|
586
|
+
[_hH]: _XASTV,
|
|
587
|
+
},
|
|
588
|
+
],
|
|
589
|
+
[
|
|
590
|
+
0,
|
|
591
|
+
{
|
|
592
|
+
[_hH]: _XASTCH,
|
|
593
|
+
},
|
|
594
|
+
],
|
|
595
|
+
[
|
|
596
|
+
0,
|
|
597
|
+
{
|
|
598
|
+
[_hH]: _XASII,
|
|
599
|
+
},
|
|
600
|
+
],
|
|
601
|
+
[
|
|
602
|
+
0,
|
|
603
|
+
{
|
|
604
|
+
[_hH]: _XASIC,
|
|
605
|
+
},
|
|
606
|
+
],
|
|
607
|
+
[
|
|
608
|
+
0,
|
|
609
|
+
{
|
|
610
|
+
[_hH]: _XASSI,
|
|
611
|
+
},
|
|
612
|
+
],
|
|
613
|
+
],
|
|
614
|
+
];
|
|
615
|
+
var InvokeEndpointWithResponseStreamOutput = [
|
|
616
|
+
3,
|
|
617
|
+
n0,
|
|
618
|
+
_IEWRSO,
|
|
619
|
+
0,
|
|
620
|
+
[_B, _CT, _IPV, _CA],
|
|
621
|
+
[
|
|
622
|
+
[() => ResponseStream, 16],
|
|
623
|
+
[
|
|
624
|
+
0,
|
|
625
|
+
{
|
|
626
|
+
[_hH]: _XASCT,
|
|
627
|
+
},
|
|
628
|
+
],
|
|
629
|
+
[
|
|
630
|
+
0,
|
|
631
|
+
{
|
|
632
|
+
[_hH]: _xAIPV,
|
|
633
|
+
},
|
|
634
|
+
],
|
|
635
|
+
[
|
|
636
|
+
() => CustomAttributesHeader,
|
|
637
|
+
{
|
|
638
|
+
[_hH]: _XASCA,
|
|
639
|
+
},
|
|
640
|
+
],
|
|
641
|
+
],
|
|
642
|
+
];
|
|
643
|
+
var ModelError = [
|
|
644
|
+
-3,
|
|
645
|
+
n0,
|
|
646
|
+
_ME,
|
|
647
|
+
{
|
|
648
|
+
[_e]: _c,
|
|
649
|
+
[_hE]: 424,
|
|
650
|
+
},
|
|
651
|
+
[_M, _OSC, _OM, _LSA],
|
|
652
|
+
[0, 1, 0, 0],
|
|
653
|
+
];
|
|
654
|
+
schema.TypeRegistry.for(n0).registerError(ModelError, ModelError$1);
|
|
655
|
+
var ModelNotReadyException = [
|
|
656
|
+
-3,
|
|
657
|
+
n0,
|
|
658
|
+
_MNRE,
|
|
659
|
+
{
|
|
660
|
+
[_e]: _c,
|
|
661
|
+
[_hE]: 429,
|
|
662
|
+
[_aQE]: [`ModelNotReadyException`, 429],
|
|
663
|
+
},
|
|
664
|
+
[_M],
|
|
665
|
+
[0],
|
|
666
|
+
];
|
|
667
|
+
schema.TypeRegistry.for(n0).registerError(ModelNotReadyException, ModelNotReadyException$1);
|
|
668
|
+
var ModelStreamError = [
|
|
669
|
+
-3,
|
|
670
|
+
n0,
|
|
671
|
+
_MSE,
|
|
672
|
+
{
|
|
673
|
+
[_e]: _c,
|
|
674
|
+
},
|
|
675
|
+
[_M, _EC],
|
|
676
|
+
[0, 0],
|
|
677
|
+
];
|
|
678
|
+
schema.TypeRegistry.for(n0).registerError(ModelStreamError, ModelStreamError$1);
|
|
679
|
+
var PayloadPart = [
|
|
680
|
+
3,
|
|
681
|
+
n0,
|
|
682
|
+
_PP,
|
|
683
|
+
0,
|
|
684
|
+
[_By],
|
|
685
|
+
[
|
|
686
|
+
[
|
|
687
|
+
() => PartBlob,
|
|
688
|
+
{
|
|
689
|
+
[_eP]: 1,
|
|
690
|
+
},
|
|
691
|
+
],
|
|
692
|
+
],
|
|
693
|
+
];
|
|
694
|
+
var ServiceUnavailable = [
|
|
695
|
+
-3,
|
|
696
|
+
n0,
|
|
697
|
+
_SU,
|
|
698
|
+
{
|
|
699
|
+
[_e]: _s,
|
|
700
|
+
[_hE]: 503,
|
|
701
|
+
},
|
|
702
|
+
[_M],
|
|
703
|
+
[0],
|
|
704
|
+
];
|
|
705
|
+
schema.TypeRegistry.for(n0).registerError(ServiceUnavailable, ServiceUnavailable$1);
|
|
706
|
+
var ValidationError = [
|
|
707
|
+
-3,
|
|
708
|
+
n0,
|
|
709
|
+
_VE,
|
|
710
|
+
{
|
|
711
|
+
[_e]: _c,
|
|
712
|
+
[_hE]: 400,
|
|
713
|
+
},
|
|
714
|
+
[_M],
|
|
715
|
+
[0],
|
|
716
|
+
];
|
|
717
|
+
schema.TypeRegistry.for(n0).registerError(ValidationError, ValidationError$1);
|
|
718
|
+
var SageMakerRuntimeServiceException = [
|
|
719
|
+
-3,
|
|
720
|
+
_sm,
|
|
721
|
+
"SageMakerRuntimeServiceException",
|
|
722
|
+
0,
|
|
723
|
+
[],
|
|
724
|
+
[],
|
|
725
|
+
];
|
|
726
|
+
schema.TypeRegistry.for(_sm).registerError(SageMakerRuntimeServiceException, SageMakerRuntimeServiceException$1);
|
|
727
|
+
var ResponseStream = [
|
|
728
|
+
3,
|
|
729
|
+
n0,
|
|
730
|
+
_RS,
|
|
731
|
+
{
|
|
732
|
+
[_st]: 1,
|
|
733
|
+
},
|
|
734
|
+
[_PP, _MSE, _ISF],
|
|
735
|
+
[
|
|
736
|
+
[() => PayloadPart, 0],
|
|
737
|
+
[() => ModelStreamError, 0],
|
|
738
|
+
[() => InternalStreamFailure, 0],
|
|
739
|
+
],
|
|
740
|
+
];
|
|
741
|
+
var InvokeEndpoint = [
|
|
742
|
+
9,
|
|
743
|
+
n0,
|
|
744
|
+
_IE,
|
|
745
|
+
{
|
|
746
|
+
[_h]: ["POST", "/endpoints/{EndpointName}/invocations", 200],
|
|
747
|
+
},
|
|
748
|
+
() => InvokeEndpointInput,
|
|
749
|
+
() => InvokeEndpointOutput,
|
|
750
|
+
];
|
|
751
|
+
var InvokeEndpointAsync = [
|
|
752
|
+
9,
|
|
753
|
+
n0,
|
|
754
|
+
_IEA,
|
|
755
|
+
{
|
|
756
|
+
[_h]: ["POST", "/endpoints/{EndpointName}/async-invocations", 202],
|
|
757
|
+
},
|
|
758
|
+
() => InvokeEndpointAsyncInput,
|
|
759
|
+
() => InvokeEndpointAsyncOutput,
|
|
760
|
+
];
|
|
761
|
+
var InvokeEndpointWithResponseStream = [
|
|
762
|
+
9,
|
|
763
|
+
n0,
|
|
764
|
+
_IEWRS,
|
|
765
|
+
{
|
|
766
|
+
[_h]: ["POST", "/endpoints/{EndpointName}/invocations-response-stream", 200],
|
|
767
|
+
},
|
|
768
|
+
() => InvokeEndpointWithResponseStreamInput,
|
|
769
|
+
() => InvokeEndpointWithResponseStreamOutput,
|
|
770
|
+
];
|
|
632
771
|
|
|
633
772
|
class InvokeEndpointAsyncCommand extends smithyClient.Command
|
|
634
773
|
.classBuilder()
|
|
635
774
|
.ep(commonParams)
|
|
636
775
|
.m(function (Command, cs, config, o) {
|
|
637
|
-
return [
|
|
638
|
-
middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
|
|
639
|
-
middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
|
|
640
|
-
];
|
|
776
|
+
return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
|
|
641
777
|
})
|
|
642
778
|
.s("AmazonSageMakerRuntime", "InvokeEndpointAsync", {})
|
|
643
779
|
.n("SageMakerRuntimeClient", "InvokeEndpointAsyncCommand")
|
|
644
|
-
.
|
|
645
|
-
.ser(se_InvokeEndpointAsyncCommand)
|
|
646
|
-
.de(de_InvokeEndpointAsyncCommand)
|
|
780
|
+
.sc(InvokeEndpointAsync)
|
|
647
781
|
.build() {
|
|
648
782
|
}
|
|
649
783
|
|
|
@@ -651,16 +785,11 @@ class InvokeEndpointCommand extends smithyClient.Command
|
|
|
651
785
|
.classBuilder()
|
|
652
786
|
.ep(commonParams)
|
|
653
787
|
.m(function (Command, cs, config, o) {
|
|
654
|
-
return [
|
|
655
|
-
middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
|
|
656
|
-
middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
|
|
657
|
-
];
|
|
788
|
+
return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
|
|
658
789
|
})
|
|
659
790
|
.s("AmazonSageMakerRuntime", "InvokeEndpoint", {})
|
|
660
791
|
.n("SageMakerRuntimeClient", "InvokeEndpointCommand")
|
|
661
|
-
.
|
|
662
|
-
.ser(se_InvokeEndpointCommand)
|
|
663
|
-
.de(de_InvokeEndpointCommand)
|
|
792
|
+
.sc(InvokeEndpoint)
|
|
664
793
|
.build() {
|
|
665
794
|
}
|
|
666
795
|
|
|
@@ -668,10 +797,7 @@ class InvokeEndpointWithResponseStreamCommand extends smithyClient.Command
|
|
|
668
797
|
.classBuilder()
|
|
669
798
|
.ep(commonParams)
|
|
670
799
|
.m(function (Command, cs, config, o) {
|
|
671
|
-
return [
|
|
672
|
-
middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
|
|
673
|
-
middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
|
|
674
|
-
];
|
|
800
|
+
return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
|
|
675
801
|
})
|
|
676
802
|
.s("AmazonSageMakerRuntime", "InvokeEndpointWithResponseStream", {
|
|
677
803
|
eventStream: {
|
|
@@ -679,9 +805,7 @@ class InvokeEndpointWithResponseStreamCommand extends smithyClient.Command
|
|
|
679
805
|
},
|
|
680
806
|
})
|
|
681
807
|
.n("SageMakerRuntimeClient", "InvokeEndpointWithResponseStreamCommand")
|
|
682
|
-
.
|
|
683
|
-
.ser(se_InvokeEndpointWithResponseStreamCommand)
|
|
684
|
-
.de(de_InvokeEndpointWithResponseStreamCommand)
|
|
808
|
+
.sc(InvokeEndpointWithResponseStream)
|
|
685
809
|
.build() {
|
|
686
810
|
}
|
|
687
811
|
|
|
@@ -702,24 +826,17 @@ Object.defineProperty(exports, "__Client", {
|
|
|
702
826
|
enumerable: true,
|
|
703
827
|
get: function () { return smithyClient.Client; }
|
|
704
828
|
});
|
|
705
|
-
exports.InternalDependencyException = InternalDependencyException;
|
|
706
|
-
exports.InternalFailure = InternalFailure;
|
|
707
|
-
exports.InternalStreamFailure = InternalStreamFailure;
|
|
829
|
+
exports.InternalDependencyException = InternalDependencyException$1;
|
|
830
|
+
exports.InternalFailure = InternalFailure$1;
|
|
831
|
+
exports.InternalStreamFailure = InternalStreamFailure$1;
|
|
708
832
|
exports.InvokeEndpointAsyncCommand = InvokeEndpointAsyncCommand;
|
|
709
|
-
exports.InvokeEndpointAsyncInputFilterSensitiveLog = InvokeEndpointAsyncInputFilterSensitiveLog;
|
|
710
833
|
exports.InvokeEndpointCommand = InvokeEndpointCommand;
|
|
711
|
-
exports.InvokeEndpointInputFilterSensitiveLog = InvokeEndpointInputFilterSensitiveLog;
|
|
712
|
-
exports.InvokeEndpointOutputFilterSensitiveLog = InvokeEndpointOutputFilterSensitiveLog;
|
|
713
834
|
exports.InvokeEndpointWithResponseStreamCommand = InvokeEndpointWithResponseStreamCommand;
|
|
714
|
-
exports.
|
|
715
|
-
exports.
|
|
716
|
-
exports.
|
|
717
|
-
exports.ModelNotReadyException = ModelNotReadyException;
|
|
718
|
-
exports.ModelStreamError = ModelStreamError;
|
|
719
|
-
exports.PayloadPartFilterSensitiveLog = PayloadPartFilterSensitiveLog;
|
|
720
|
-
exports.ResponseStreamFilterSensitiveLog = ResponseStreamFilterSensitiveLog;
|
|
835
|
+
exports.ModelError = ModelError$1;
|
|
836
|
+
exports.ModelNotReadyException = ModelNotReadyException$1;
|
|
837
|
+
exports.ModelStreamError = ModelStreamError$1;
|
|
721
838
|
exports.SageMakerRuntime = SageMakerRuntime;
|
|
722
839
|
exports.SageMakerRuntimeClient = SageMakerRuntimeClient;
|
|
723
|
-
exports.SageMakerRuntimeServiceException = SageMakerRuntimeServiceException;
|
|
724
|
-
exports.ServiceUnavailable = ServiceUnavailable;
|
|
725
|
-
exports.ValidationError = ValidationError;
|
|
840
|
+
exports.SageMakerRuntimeServiceException = SageMakerRuntimeServiceException$1;
|
|
841
|
+
exports.ServiceUnavailable = ServiceUnavailable$1;
|
|
842
|
+
exports.ValidationError = ValidationError$1;
|