interface CfnModelPackageProps
Language | Type name |
---|---|
.NET | Amazon.CDK.AWS.Sagemaker.CfnModelPackageProps |
Java | software.amazon.awscdk.services.sagemaker.CfnModelPackageProps |
Python | aws_cdk.aws_sagemaker.CfnModelPackageProps |
TypeScript | @aws-cdk/aws-sagemaker » CfnModelPackageProps |
Properties for defining a CfnModelPackage
.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as sagemaker from '@aws-cdk/aws-sagemaker';
declare const modelInput: any;
const cfnModelPackageProps: sagemaker.CfnModelPackageProps = {
additionalInferenceSpecificationDefinition: {
containers: [{
image: 'image',
// the properties below are optional
containerHostname: 'containerHostname',
environment: {
environmentKey: 'environment',
},
framework: 'framework',
frameworkVersion: 'frameworkVersion',
imageDigest: 'imageDigest',
modelDataUrl: 'modelDataUrl',
modelInput: modelInput,
nearestModelName: 'nearestModelName',
productId: 'productId',
}],
name: 'name',
// the properties below are optional
description: 'description',
supportedContentTypes: ['supportedContentTypes'],
supportedRealtimeInferenceInstanceTypes: ['supportedRealtimeInferenceInstanceTypes'],
supportedResponseMimeTypes: ['supportedResponseMimeTypes'],
supportedTransformInstanceTypes: ['supportedTransformInstanceTypes'],
},
additionalInferenceSpecifications: [{
containers: [{
image: 'image',
// the properties below are optional
containerHostname: 'containerHostname',
environment: {
environmentKey: 'environment',
},
framework: 'framework',
frameworkVersion: 'frameworkVersion',
imageDigest: 'imageDigest',
modelDataUrl: 'modelDataUrl',
modelInput: modelInput,
nearestModelName: 'nearestModelName',
productId: 'productId',
}],
name: 'name',
// the properties below are optional
description: 'description',
supportedContentTypes: ['supportedContentTypes'],
supportedRealtimeInferenceInstanceTypes: ['supportedRealtimeInferenceInstanceTypes'],
supportedResponseMimeTypes: ['supportedResponseMimeTypes'],
supportedTransformInstanceTypes: ['supportedTransformInstanceTypes'],
}],
additionalInferenceSpecificationsToAdd: [{
containers: [{
image: 'image',
// the properties below are optional
containerHostname: 'containerHostname',
environment: {
environmentKey: 'environment',
},
framework: 'framework',
frameworkVersion: 'frameworkVersion',
imageDigest: 'imageDigest',
modelDataUrl: 'modelDataUrl',
modelInput: modelInput,
nearestModelName: 'nearestModelName',
productId: 'productId',
}],
name: 'name',
// the properties below are optional
description: 'description',
supportedContentTypes: ['supportedContentTypes'],
supportedRealtimeInferenceInstanceTypes: ['supportedRealtimeInferenceInstanceTypes'],
supportedResponseMimeTypes: ['supportedResponseMimeTypes'],
supportedTransformInstanceTypes: ['supportedTransformInstanceTypes'],
}],
approvalDescription: 'approvalDescription',
certifyForMarketplace: false,
clientToken: 'clientToken',
createdBy: {
domainId: 'domainId',
userProfileArn: 'userProfileArn',
userProfileName: 'userProfileName',
},
customerMetadataProperties: {
customerMetadataPropertiesKey: 'customerMetadataProperties',
},
domain: 'domain',
driftCheckBaselines: {
bias: {
configFile: {
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
contentType: 'contentType',
},
postTrainingConstraints: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
preTrainingConstraints: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
},
explainability: {
configFile: {
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
contentType: 'contentType',
},
constraints: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
},
modelDataQuality: {
constraints: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
statistics: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
},
modelQuality: {
constraints: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
statistics: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
},
},
environment: {
environmentKey: 'environment',
},
inferenceSpecification: {
containers: [{
image: 'image',
// the properties below are optional
containerHostname: 'containerHostname',
environment: {
environmentKey: 'environment',
},
framework: 'framework',
frameworkVersion: 'frameworkVersion',
imageDigest: 'imageDigest',
modelDataUrl: 'modelDataUrl',
modelInput: modelInput,
nearestModelName: 'nearestModelName',
productId: 'productId',
}],
supportedContentTypes: ['supportedContentTypes'],
supportedResponseMimeTypes: ['supportedResponseMimeTypes'],
// the properties below are optional
supportedRealtimeInferenceInstanceTypes: ['supportedRealtimeInferenceInstanceTypes'],
supportedTransformInstanceTypes: ['supportedTransformInstanceTypes'],
},
lastModifiedBy: {
domainId: 'domainId',
userProfileArn: 'userProfileArn',
userProfileName: 'userProfileName',
},
lastModifiedTime: 'lastModifiedTime',
metadataProperties: {
commitId: 'commitId',
generatedBy: 'generatedBy',
projectId: 'projectId',
repository: 'repository',
},
modelApprovalStatus: 'modelApprovalStatus',
modelMetrics: {
bias: {
postTrainingReport: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
preTrainingReport: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
report: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
},
explainability: {
report: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
},
modelDataQuality: {
constraints: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
statistics: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
},
modelQuality: {
constraints: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
statistics: {
contentType: 'contentType',
s3Uri: 's3Uri',
// the properties below are optional
contentDigest: 'contentDigest',
},
},
},
modelPackageDescription: 'modelPackageDescription',
modelPackageGroupName: 'modelPackageGroupName',
modelPackageName: 'modelPackageName',
modelPackageStatusDetails: {
validationStatuses: [{
name: 'name',
status: 'status',
// the properties below are optional
failureReason: 'failureReason',
}],
// the properties below are optional
imageScanStatuses: [{
name: 'name',
status: 'status',
// the properties below are optional
failureReason: 'failureReason',
}],
},
modelPackageStatusItem: {
name: 'name',
status: 'status',
// the properties below are optional
failureReason: 'failureReason',
},
modelPackageVersion: 123,
samplePayloadUrl: 'samplePayloadUrl',
sourceAlgorithmSpecification: {
sourceAlgorithms: [{
algorithmName: 'algorithmName',
// the properties below are optional
modelDataUrl: 'modelDataUrl',
}],
},
tags: [{
key: 'key',
value: 'value',
}],
task: 'task',
validationSpecification: {
validationProfiles: [{
profileName: 'profileName',
transformJobDefinition: {
transformInput: {
dataSource: {
s3DataSource: {
s3DataType: 's3DataType',
s3Uri: 's3Uri',
},
},
// the properties below are optional
compressionType: 'compressionType',
contentType: 'contentType',
splitType: 'splitType',
},
transformOutput: {
s3OutputPath: 's3OutputPath',
// the properties below are optional
accept: 'accept',
assembleWith: 'assembleWith',
kmsKeyId: 'kmsKeyId',
},
transformResources: {
instanceCount: 123,
instanceType: 'instanceType',
// the properties below are optional
volumeKmsKeyId: 'volumeKmsKeyId',
},
// the properties below are optional
batchStrategy: 'batchStrategy',
environment: {
environmentKey: 'environment',
},
maxConcurrentTransforms: 123,
maxPayloadInMb: 123,
},
}],
validationRole: 'validationRole',
},
};
Properties
Name | Type | Description |
---|---|---|
additional | IResolvable | Additional | A structure of additional Inference Specification. |
additional | IResolvable | IResolvable | Additional [] | An array of additional Inference Specification objects. |
additional | IResolvable | IResolvable | Additional [] | An array of additional Inference Specification objects to be added to the existing array. |
approval | string | A description provided when the model approval is set. |
certify | boolean | IResolvable | Whether the model package is to be certified to be listed on AWS Marketplace. |
client | string | A unique token that guarantees that the call to this API is idempotent. |
created | IResolvable | User | Information about the user who created or modified an experiment, trial, trial component, lineage group, or project. |
customer | IResolvable | { [string]: string } | The metadata properties for the model package. |
domain? | string | The machine learning domain of your model package and its components. |
drift | IResolvable | Drift | Represents the drift check baselines that can be used when the model monitor is set using the model package. |
environment? | IResolvable | { [string]: string } | The environment variables to set in the Docker container. |
inference | IResolvable | Inference | Defines how to perform inference generation after a training job is run. |
last | IResolvable | User | Information about the user who created or modified an experiment, trial, trial component, lineage group, or project. |
last | string | The last time the model package was modified. |
metadata | IResolvable | Metadata | Metadata properties of the tracking entity, trial, or trial component. |
model | string | The approval status of the model. This can be one of the following values. |
model | IResolvable | Model | Metrics for the model. |
model | string | The description of the model package. |
model | string | The model group to which the model belongs. |
model | string | The name of the model. |
model | IResolvable | Model | Specifies the validation and image scan statuses of the model package. |
model | IResolvable | Model | Represents the overall status of a model package. |
model | number | The version number of a versioned model. |
sample | string | The Amazon Simple Storage Service path where the sample payload are stored. |
source | IResolvable | Source | A list of algorithms that were used to create a model package. |
tags? | Cfn [] | A list of the tags associated with the model package. |
task? | string | The machine learning task your model package accomplishes. |
validation | IResolvable | Validation | Specifies batch transform jobs that SageMaker runs to validate your model package. |
additionalInferenceSpecificationDefinition?
Type:
IResolvable
|
Additional
(optional)
A structure of additional Inference Specification.
Additional Inference Specification specifies details about inference jobs that can be run with models based on this model package
additionalInferenceSpecifications?
Type:
IResolvable
|
IResolvable
|
Additional
[]
(optional)
An array of additional Inference Specification objects.
additionalInferenceSpecificationsToAdd?
Type:
IResolvable
|
IResolvable
|
Additional
[]
(optional)
An array of additional Inference Specification objects to be added to the existing array.
The total number of additional Inference Specification objects cannot exceed 15. Each additional Inference Specification object specifies artifacts based on this model package that can be used on inference endpoints. Generally used with SageMaker Neo to store the compiled artifacts.
approvalDescription?
Type:
string
(optional)
A description provided when the model approval is set.
certifyForMarketplace?
Type:
boolean |
IResolvable
(optional)
Whether the model package is to be certified to be listed on AWS Marketplace.
For information about listing model packages on AWS Marketplace, see List Your Algorithm or Model Package on AWS Marketplace .
clientToken?
Type:
string
(optional)
A unique token that guarantees that the call to this API is idempotent.
createdBy?
Type:
IResolvable
|
User
(optional)
Information about the user who created or modified an experiment, trial, trial component, lineage group, or project.
customerMetadataProperties?
Type:
IResolvable
| { [string]: string }
(optional)
The metadata properties for the model package.
domain?
Type:
string
(optional)
The machine learning domain of your model package and its components.
Common machine learning domains include computer vision and natural language processing.
driftCheckBaselines?
Type:
IResolvable
|
Drift
(optional)
Represents the drift check baselines that can be used when the model monitor is set using the model package.
environment?
Type:
IResolvable
| { [string]: string }
(optional)
The environment variables to set in the Docker container.
Each key and value in the Environment
string to string map can have length of up to 1024. We support up to 16 entries in the map.
inferenceSpecification?
Type:
IResolvable
|
Inference
(optional)
Defines how to perform inference generation after a training job is run.
lastModifiedBy?
Type:
IResolvable
|
User
(optional)
Information about the user who created or modified an experiment, trial, trial component, lineage group, or project.
lastModifiedTime?
Type:
string
(optional)
The last time the model package was modified.
metadataProperties?
Type:
IResolvable
|
Metadata
(optional)
Metadata properties of the tracking entity, trial, or trial component.
modelApprovalStatus?
Type:
string
(optional)
The approval status of the model. This can be one of the following values.
APPROVED
- The model is approvedREJECTED
- The model is rejected.PENDING_MANUAL_APPROVAL
- The model is waiting for manual approval.
modelMetrics?
Type:
IResolvable
|
Model
(optional)
Metrics for the model.
modelPackageDescription?
Type:
string
(optional)
The description of the model package.
modelPackageGroupName?
Type:
string
(optional)
The model group to which the model belongs.
modelPackageName?
Type:
string
(optional)
The name of the model.
modelPackageStatusDetails?
Type:
IResolvable
|
Model
(optional)
Specifies the validation and image scan statuses of the model package.
modelPackageStatusItem?
Type:
IResolvable
|
Model
(optional)
Represents the overall status of a model package.
modelPackageVersion?
Type:
number
(optional)
The version number of a versioned model.
samplePayloadUrl?
Type:
string
(optional)
The Amazon Simple Storage Service path where the sample payload are stored.
This path must point to a single gzip compressed tar archive (.tar.gz suffix).
sourceAlgorithmSpecification?
Type:
IResolvable
|
Source
(optional)
A list of algorithms that were used to create a model package.
tags?
Type:
Cfn
[]
(optional)
A list of the tags associated with the model package.
For more information, see Tagging AWS resources in the AWS General Reference Guide .
task?
Type:
string
(optional)
The machine learning task your model package accomplishes.
Common machine learning tasks include object detection and image classification.
validationSpecification?
Type:
IResolvable
|
Validation
(optional)
Specifies batch transform jobs that SageMaker runs to validate your model package.