Interface CfnModelPackageProps
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
CfnModelPackageProps.Jsii$Proxy
CfnModelPackage.
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.sagemaker.*;
Object modelInput;
CfnModelPackageProps cfnModelPackageProps = CfnModelPackageProps.builder()
.additionalInferenceSpecifications(List.of(AdditionalInferenceSpecificationDefinitionProperty.builder()
.containers(List.of(ModelPackageContainerDefinitionProperty.builder()
.image("image")
// the properties below are optional
.containerHostname("containerHostname")
.environment(Map.of(
"environmentKey", "environment"))
.framework("framework")
.frameworkVersion("frameworkVersion")
.imageDigest("imageDigest")
.modelDataSource(ModelDataSourceProperty.builder()
.s3DataSource(S3ModelDataSourceProperty.builder()
.compressionType("compressionType")
.s3DataType("s3DataType")
.s3Uri("s3Uri")
// the properties below are optional
.modelAccessConfig(ModelAccessConfigProperty.builder()
.acceptEula(false)
.build())
.build())
.build())
.modelDataUrl("modelDataUrl")
.modelInput(modelInput)
.nearestModelName("nearestModelName")
.build()))
.name("name")
// the properties below are optional
.description("description")
.supportedContentTypes(List.of("supportedContentTypes"))
.supportedRealtimeInferenceInstanceTypes(List.of("supportedRealtimeInferenceInstanceTypes"))
.supportedResponseMimeTypes(List.of("supportedResponseMimeTypes"))
.supportedTransformInstanceTypes(List.of("supportedTransformInstanceTypes"))
.build()))
.additionalInferenceSpecificationsToAdd(List.of(AdditionalInferenceSpecificationDefinitionProperty.builder()
.containers(List.of(ModelPackageContainerDefinitionProperty.builder()
.image("image")
// the properties below are optional
.containerHostname("containerHostname")
.environment(Map.of(
"environmentKey", "environment"))
.framework("framework")
.frameworkVersion("frameworkVersion")
.imageDigest("imageDigest")
.modelDataSource(ModelDataSourceProperty.builder()
.s3DataSource(S3ModelDataSourceProperty.builder()
.compressionType("compressionType")
.s3DataType("s3DataType")
.s3Uri("s3Uri")
// the properties below are optional
.modelAccessConfig(ModelAccessConfigProperty.builder()
.acceptEula(false)
.build())
.build())
.build())
.modelDataUrl("modelDataUrl")
.modelInput(modelInput)
.nearestModelName("nearestModelName")
.build()))
.name("name")
// the properties below are optional
.description("description")
.supportedContentTypes(List.of("supportedContentTypes"))
.supportedRealtimeInferenceInstanceTypes(List.of("supportedRealtimeInferenceInstanceTypes"))
.supportedResponseMimeTypes(List.of("supportedResponseMimeTypes"))
.supportedTransformInstanceTypes(List.of("supportedTransformInstanceTypes"))
.build()))
.approvalDescription("approvalDescription")
.certifyForMarketplace(false)
.clientToken("clientToken")
.customerMetadataProperties(Map.of(
"customerMetadataPropertiesKey", "customerMetadataProperties"))
.domain("domain")
.driftCheckBaselines(DriftCheckBaselinesProperty.builder()
.bias(DriftCheckBiasProperty.builder()
.configFile(FileSourceProperty.builder()
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.contentType("contentType")
.build())
.postTrainingConstraints(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.preTrainingConstraints(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.build())
.explainability(DriftCheckExplainabilityProperty.builder()
.configFile(FileSourceProperty.builder()
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.contentType("contentType")
.build())
.constraints(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.build())
.modelDataQuality(DriftCheckModelDataQualityProperty.builder()
.constraints(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.statistics(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.build())
.modelQuality(DriftCheckModelQualityProperty.builder()
.constraints(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.statistics(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.build())
.build())
.inferenceSpecification(InferenceSpecificationProperty.builder()
.containers(List.of(ModelPackageContainerDefinitionProperty.builder()
.image("image")
// the properties below are optional
.containerHostname("containerHostname")
.environment(Map.of(
"environmentKey", "environment"))
.framework("framework")
.frameworkVersion("frameworkVersion")
.imageDigest("imageDigest")
.modelDataSource(ModelDataSourceProperty.builder()
.s3DataSource(S3ModelDataSourceProperty.builder()
.compressionType("compressionType")
.s3DataType("s3DataType")
.s3Uri("s3Uri")
// the properties below are optional
.modelAccessConfig(ModelAccessConfigProperty.builder()
.acceptEula(false)
.build())
.build())
.build())
.modelDataUrl("modelDataUrl")
.modelInput(modelInput)
.nearestModelName("nearestModelName")
.build()))
.supportedContentTypes(List.of("supportedContentTypes"))
.supportedResponseMimeTypes(List.of("supportedResponseMimeTypes"))
// the properties below are optional
.supportedRealtimeInferenceInstanceTypes(List.of("supportedRealtimeInferenceInstanceTypes"))
.supportedTransformInstanceTypes(List.of("supportedTransformInstanceTypes"))
.build())
.lastModifiedTime("lastModifiedTime")
.metadataProperties(MetadataPropertiesProperty.builder()
.commitId("commitId")
.generatedBy("generatedBy")
.projectId("projectId")
.repository("repository")
.build())
.modelApprovalStatus("modelApprovalStatus")
.modelCard(ModelCardProperty.builder()
.modelCardContent("modelCardContent")
.modelCardStatus("modelCardStatus")
.build())
.modelMetrics(ModelMetricsProperty.builder()
.bias(BiasProperty.builder()
.postTrainingReport(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.preTrainingReport(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.report(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.build())
.explainability(ExplainabilityProperty.builder()
.report(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.build())
.modelDataQuality(ModelDataQualityProperty.builder()
.constraints(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.statistics(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.build())
.modelQuality(ModelQualityProperty.builder()
.constraints(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.statistics(MetricsSourceProperty.builder()
.contentType("contentType")
.s3Uri("s3Uri")
// the properties below are optional
.contentDigest("contentDigest")
.build())
.build())
.build())
.modelPackageDescription("modelPackageDescription")
.modelPackageGroupName("modelPackageGroupName")
.modelPackageName("modelPackageName")
.modelPackageStatusDetails(ModelPackageStatusDetailsProperty.builder()
.validationStatuses(List.of(ModelPackageStatusItemProperty.builder()
.name("name")
.status("status")
// the properties below are optional
.failureReason("failureReason")
.build()))
.build())
.modelPackageVersion(123)
.samplePayloadUrl("samplePayloadUrl")
.securityConfig(SecurityConfigProperty.builder()
.kmsKeyId("kmsKeyId")
.build())
.skipModelValidation("skipModelValidation")
.sourceAlgorithmSpecification(SourceAlgorithmSpecificationProperty.builder()
.sourceAlgorithms(List.of(SourceAlgorithmProperty.builder()
.algorithmName("algorithmName")
// the properties below are optional
.modelDataUrl("modelDataUrl")
.build()))
.build())
.sourceUri("sourceUri")
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.task("task")
.validationSpecification(ValidationSpecificationProperty.builder()
.validationProfiles(List.of(ValidationProfileProperty.builder()
.profileName("profileName")
.transformJobDefinition(TransformJobDefinitionProperty.builder()
.transformInput(TransformInputProperty.builder()
.dataSource(DataSourceProperty.builder()
.s3DataSource(S3DataSourceProperty.builder()
.s3DataType("s3DataType")
.s3Uri("s3Uri")
.build())
.build())
// the properties below are optional
.compressionType("compressionType")
.contentType("contentType")
.splitType("splitType")
.build())
.transformOutput(TransformOutputProperty.builder()
.s3OutputPath("s3OutputPath")
// the properties below are optional
.accept("accept")
.assembleWith("assembleWith")
.kmsKeyId("kmsKeyId")
.build())
.transformResources(TransformResourcesProperty.builder()
.instanceCount(123)
.instanceType("instanceType")
// the properties below are optional
.volumeKmsKeyId("volumeKmsKeyId")
.build())
// the properties below are optional
.batchStrategy("batchStrategy")
.environment(Map.of(
"environmentKey", "environment"))
.maxConcurrentTransforms(123)
.maxPayloadInMb(123)
.build())
.build()))
.validationRole("validationRole")
.build())
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forCfnModelPackagePropsstatic final classAn implementation forCfnModelPackageProps -
Method Summary
Modifier and TypeMethodDescriptionstatic CfnModelPackageProps.Builderbuilder()default ObjectAn array of additional Inference Specification objects.default ObjectAn array of additional Inference Specification objects to be added to the existing array.default StringA description provided when the model approval is set.default ObjectWhether the model package is to be certified to be listed on AWS Marketplace.default StringA unique token that guarantees that the call to this API is idempotent.default ObjectThe metadata properties for the model package.default StringThe machine learning domain of your model package and its components.default ObjectRepresents the drift check baselines that can be used when the model monitor is set using the model package.default ObjectDefines how to perform inference generation after a training job is run.default StringThe last time the model package was modified.default ObjectMetadata properties of the tracking entity, trial, or trial component.default StringThe approval status of the model.default ObjectAn Amazon SageMaker Model Card.default ObjectMetrics for the model.default StringThe description of the model package.default StringThe model group to which the model belongs.default StringThe name of the model package.default ObjectSpecifies the validation and image scan statuses of the model package.default NumberThe version number of a versioned model.default StringThe Amazon Simple Storage Service path where the sample payload are stored.default ObjectAn optional AWS Key Management Service key to encrypt, decrypt, and re-encrypt model package information for regulated workloads with highly sensitive data.default StringIndicates if you want to skip model validation.default ObjectA list of algorithms that were used to create a model package.default StringThe URI of the source for the model package.getTags()A list of the tags associated with the model package.default StringgetTask()The machine learning task your model package accomplishes.default ObjectSpecifies batch transform jobs that SageMaker runs to validate your model package.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getAdditionalInferenceSpecifications
An array of additional Inference Specification objects.Returns union: either
IResolvableor Listinvalid input: '<'eitherIResolvableorCfnModelPackage.AdditionalInferenceSpecificationDefinitionProperty>- See Also:
-
getAdditionalInferenceSpecificationsToAdd
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.
Returns union: either
IResolvableor Listinvalid input: '<'eitherIResolvableorCfnModelPackage.AdditionalInferenceSpecificationDefinitionProperty>- See Also:
-
getApprovalDescription
A description provided when the model approval is set.- See Also:
-
getCertifyForMarketplace
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 .
Returns union: either
BooleanorIResolvable- See Also:
-
getClientToken
A unique token that guarantees that the call to this API is idempotent.- See Also:
-
getCustomerMetadataProperties
The metadata properties for the model package.Returns union: either Mapinvalid input: '<'String,
String> orIResolvable- See Also:
-
getDomain
The machine learning domain of your model package and its components.Common machine learning domains include computer vision and natural language processing.
- See Also:
-
getDriftCheckBaselines
Represents the drift check baselines that can be used when the model monitor is set using the model package.Returns union: either
IResolvableorCfnModelPackage.DriftCheckBaselinesProperty- See Also:
-
getInferenceSpecification
Defines how to perform inference generation after a training job is run.Returns union: either
IResolvableorCfnModelPackage.InferenceSpecificationProperty- See Also:
-
getLastModifiedTime
The last time the model package was modified.- See Also:
-
getMetadataProperties
Metadata properties of the tracking entity, trial, or trial component.Returns union: either
IResolvableorCfnModelPackage.MetadataPropertiesProperty- See Also:
-
getModelApprovalStatus
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.
- See Also:
-
getModelCard
An Amazon SageMaker Model Card.Returns union: either
IResolvableorCfnModelPackage.ModelCardProperty- See Also:
-
getModelMetrics
Metrics for the model.Returns union: either
IResolvableorCfnModelPackage.ModelMetricsProperty- See Also:
-
getModelPackageDescription
The description of the model package.- See Also:
-
getModelPackageGroupName
The model group to which the model belongs.- See Also:
-
getModelPackageName
The name of the model package. The name can be as follows:.- For a versioned model, the name is automatically generated by SageMaker Model Registry and follows the format '
ModelPackageGroupName/ModelPackageVersion'. - For an unversioned model, you must provide the name.
- See Also:
- For a versioned model, the name is automatically generated by SageMaker Model Registry and follows the format '
-
getModelPackageStatusDetails
Specifies the validation and image scan statuses of the model package.Returns union: either
IResolvableorCfnModelPackage.ModelPackageStatusDetailsProperty- See Also:
-
getModelPackageVersion
The version number of a versioned model.- See Also:
-
getSamplePayloadUrl
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).
- See Also:
-
getSecurityConfig
An optional AWS Key Management Service key to encrypt, decrypt, and re-encrypt model package information for regulated workloads with highly sensitive data.Returns union: either
IResolvableorCfnModelPackage.SecurityConfigProperty- See Also:
-
getSkipModelValidation
Indicates if you want to skip model validation.- See Also:
-
getSourceAlgorithmSpecification
A list of algorithms that were used to create a model package.Returns union: either
IResolvableorCfnModelPackage.SourceAlgorithmSpecificationProperty- See Also:
-
getSourceUri
The URI of the source for the model package.- See Also:
-
getTags
A list of the tags associated with the model package.For more information, see Tagging AWS resources in the AWS General Reference Guide .
- See Also:
-
getTask
The machine learning task your model package accomplishes.Common machine learning tasks include object detection and image classification.
- See Also:
-
getValidationSpecification
Specifies batch transform jobs that SageMaker runs to validate your model package.Returns union: either
IResolvableorCfnModelPackage.ValidationSpecificationProperty- See Also:
-
builder
- Returns:
- a
CfnModelPackageProps.BuilderofCfnModelPackageProps
-