DescribeModelPackage
Returns a description of the specified model package, which is used to create SageMaker models or list them on AWS Marketplace.
Important
If you provided a AWS KMS Key ID when you created your model package, you will see the KMS Decrypt API call in your CloudTrail logs when you use this API.
To create models in SageMaker, buyers can subscribe to model packages listed on AWS Marketplace.
Request Syntax
{
"ModelPackageName": "string
"
}
Request Parameters
For information about the parameters that are common to all actions, see Common Parameters.
The request accepts the following data in JSON format.
- ModelPackageName
-
The name or Amazon Resource Name (ARN) of the model package to describe.
When you specify a name, the name must have 1 to 63 characters. Valid characters are a-z, A-Z, 0-9, and - (hyphen).
Type: String
Length Constraints: Minimum length of 1. Maximum length of 176.
Pattern:
(arn:aws[a-z\-]*:sagemaker:[a-z0-9\-]*:[0-9]{12}:[a-z\-]*\/)?([a-zA-Z0-9]([a-zA-Z0-9-]){0,62})(?<!-)(\/[0-9]{1,9})?$
Required: Yes
Response Syntax
{
"AdditionalInferenceSpecifications": [
{
"Containers": [
{
"AdditionalS3DataSource": {
"CompressionType": "string",
"ETag": "string",
"S3DataType": "string",
"S3Uri": "string"
},
"ContainerHostname": "string",
"Environment": {
"string" : "string"
},
"Framework": "string",
"FrameworkVersion": "string",
"Image": "string",
"ImageDigest": "string",
"ModelDataETag": "string",
"ModelDataSource": {
"S3DataSource": {
"CompressionType": "string",
"ETag": "string",
"HubAccessConfig": {
"HubContentArn": "string"
},
"ManifestEtag": "string",
"ManifestS3Uri": "string",
"ModelAccessConfig": {
"AcceptEula": boolean
},
"S3DataType": "string",
"S3Uri": "string"
}
},
"ModelDataUrl": "string",
"ModelInput": {
"DataInputConfig": "string"
},
"NearestModelName": "string",
"ProductId": "string"
}
],
"Description": "string",
"Name": "string",
"SupportedContentTypes": [ "string" ],
"SupportedRealtimeInferenceInstanceTypes": [ "string" ],
"SupportedResponseMIMETypes": [ "string" ],
"SupportedTransformInstanceTypes": [ "string" ]
}
],
"ApprovalDescription": "string",
"CertifyForMarketplace": boolean,
"CreatedBy": {
"DomainId": "string",
"IamIdentity": {
"Arn": "string",
"PrincipalId": "string",
"SourceIdentity": "string"
},
"UserProfileArn": "string",
"UserProfileName": "string"
},
"CreationTime": number,
"CustomerMetadataProperties": {
"string" : "string"
},
"Domain": "string",
"DriftCheckBaselines": {
"Bias": {
"ConfigFile": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
},
"PostTrainingConstraints": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
},
"PreTrainingConstraints": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
}
},
"Explainability": {
"ConfigFile": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
},
"Constraints": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
}
},
"ModelDataQuality": {
"Constraints": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
},
"Statistics": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
}
},
"ModelQuality": {
"Constraints": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
},
"Statistics": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
}
}
},
"InferenceSpecification": {
"Containers": [
{
"AdditionalS3DataSource": {
"CompressionType": "string",
"ETag": "string",
"S3DataType": "string",
"S3Uri": "string"
},
"ContainerHostname": "string",
"Environment": {
"string" : "string"
},
"Framework": "string",
"FrameworkVersion": "string",
"Image": "string",
"ImageDigest": "string",
"ModelDataETag": "string",
"ModelDataSource": {
"S3DataSource": {
"CompressionType": "string",
"ETag": "string",
"HubAccessConfig": {
"HubContentArn": "string"
},
"ManifestEtag": "string",
"ManifestS3Uri": "string",
"ModelAccessConfig": {
"AcceptEula": boolean
},
"S3DataType": "string",
"S3Uri": "string"
}
},
"ModelDataUrl": "string",
"ModelInput": {
"DataInputConfig": "string"
},
"NearestModelName": "string",
"ProductId": "string"
}
],
"SupportedContentTypes": [ "string" ],
"SupportedRealtimeInferenceInstanceTypes": [ "string" ],
"SupportedResponseMIMETypes": [ "string" ],
"SupportedTransformInstanceTypes": [ "string" ]
},
"LastModifiedBy": {
"DomainId": "string",
"IamIdentity": {
"Arn": "string",
"PrincipalId": "string",
"SourceIdentity": "string"
},
"UserProfileArn": "string",
"UserProfileName": "string"
},
"LastModifiedTime": number,
"MetadataProperties": {
"CommitId": "string",
"GeneratedBy": "string",
"ProjectId": "string",
"Repository": "string"
},
"ModelApprovalStatus": "string",
"ModelCard": {
"ModelCardContent": "string",
"ModelCardStatus": "string"
},
"ModelLifeCycle": {
"Stage": "string",
"StageDescription": "string",
"StageStatus": "string"
},
"ModelMetrics": {
"Bias": {
"PostTrainingReport": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
},
"PreTrainingReport": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
},
"Report": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
}
},
"Explainability": {
"Report": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
}
},
"ModelDataQuality": {
"Constraints": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
},
"Statistics": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
}
},
"ModelQuality": {
"Constraints": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
},
"Statistics": {
"ContentDigest": "string",
"ContentType": "string",
"S3Uri": "string"
}
}
},
"ModelPackageArn": "string",
"ModelPackageDescription": "string",
"ModelPackageGroupName": "string",
"ModelPackageName": "string",
"ModelPackageStatus": "string",
"ModelPackageStatusDetails": {
"ImageScanStatuses": [
{
"FailureReason": "string",
"Name": "string",
"Status": "string"
}
],
"ValidationStatuses": [
{
"FailureReason": "string",
"Name": "string",
"Status": "string"
}
]
},
"ModelPackageVersion": number,
"SamplePayloadUrl": "string",
"SecurityConfig": {
"KmsKeyId": "string"
},
"SkipModelValidation": "string",
"SourceAlgorithmSpecification": {
"SourceAlgorithms": [
{
"AlgorithmName": "string",
"ModelDataETag": "string",
"ModelDataSource": {
"S3DataSource": {
"CompressionType": "string",
"ETag": "string",
"HubAccessConfig": {
"HubContentArn": "string"
},
"ManifestEtag": "string",
"ManifestS3Uri": "string",
"ModelAccessConfig": {
"AcceptEula": boolean
},
"S3DataType": "string",
"S3Uri": "string"
}
},
"ModelDataUrl": "string"
}
]
},
"SourceUri": "string",
"Task": "string",
"ValidationSpecification": {
"ValidationProfiles": [
{
"ProfileName": "string",
"TransformJobDefinition": {
"BatchStrategy": "string",
"Environment": {
"string" : "string"
},
"MaxConcurrentTransforms": number,
"MaxPayloadInMB": number,
"TransformInput": {
"CompressionType": "string",
"ContentType": "string",
"DataSource": {
"S3DataSource": {
"S3DataType": "string",
"S3Uri": "string"
}
},
"SplitType": "string"
},
"TransformOutput": {
"Accept": "string",
"AssembleWith": "string",
"KmsKeyId": "string",
"S3OutputPath": "string"
},
"TransformResources": {
"InstanceCount": number,
"InstanceType": "string",
"VolumeKmsKeyId": "string"
}
}
}
],
"ValidationRole": "string"
}
}
Response Elements
If the action is successful, the service sends back an HTTP 200 response.
The following data is returned in JSON format by the service.
- AdditionalInferenceSpecifications
-
An array of additional Inference Specification objects. Each additional Inference Specification specifies artifacts based on this model package that can be used on inference endpoints. Generally used with SageMaker Neo to store the compiled artifacts.
Type: Array of AdditionalInferenceSpecificationDefinition objects
Array Members: Minimum number of 1 item. Maximum number of 15 items.
- ApprovalDescription
-
A description provided for the model approval.
Type: String
Length Constraints: Maximum length of 1024.
Pattern:
.*
- CertifyForMarketplace
-
Whether the model package is certified for listing on AWS Marketplace.
Type: Boolean
- CreatedBy
-
Information about the user who created or modified an experiment, trial, trial component, lineage group, project, or model card.
Type: UserContext object
- CreationTime
-
A timestamp specifying when the model package was created.
Type: Timestamp
- CustomerMetadataProperties
-
The metadata properties associated with the model package versions.
Type: String to string map
Map Entries: Maximum number of 50 items.
Key Length Constraints: Minimum length of 1. Maximum length of 128.
Key Pattern:
^([\p{L}\p{Z}\p{N}_.:\/=+\-@]*)${1,128}
Value Length Constraints: Minimum length of 1. Maximum length of 256.
Value Pattern:
^([\p{L}\p{Z}\p{N}_.:\/=+\-@]*)${1,256}
- Domain
-
The machine learning domain of the model package you specified. Common machine learning domains include computer vision and natural language processing.
Type: String
- DriftCheckBaselines
-
Represents the drift check baselines that can be used when the model monitor is set using the model package. For more information, see the topic on Drift Detection against Previous Baselines in SageMaker Pipelines in the Amazon SageMaker Developer Guide.
Type: DriftCheckBaselines object
- InferenceSpecification
-
Details about inference jobs that you can run with models based on this model package.
Type: InferenceSpecification object
- LastModifiedBy
-
Information about the user who created or modified an experiment, trial, trial component, lineage group, project, or model card.
Type: UserContext object
- LastModifiedTime
-
The last time that the model package was modified.
Type: Timestamp
- MetadataProperties
-
Metadata properties of the tracking entity, trial, or trial component.
Type: MetadataProperties object
- ModelApprovalStatus
-
The approval status of the model package.
Type: String
Valid Values:
Approved | Rejected | PendingManualApproval
- ModelCard
-
The model card associated with the model package. Since
ModelPackageModelCard
is tied to a model package, it is a specific usage of a model card and its schema is simplified compared to the schema ofModelCard
. TheModelPackageModelCard
schema does not includemodel_package_details
, andmodel_overview
is composed of themodel_creator
andmodel_artifact
properties. For more information about the model package model card schema, see Model package model card schema. For more information about the model card associated with the model package, see View the Details of a Model Version.Type: ModelPackageModelCard object
- ModelLifeCycle
-
A structure describing the current state of the model in its life cycle.
Type: ModelLifeCycle object
- ModelMetrics
-
Metrics for the model.
Type: ModelMetrics object
- ModelPackageArn
-
The Amazon Resource Name (ARN) of the model package.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 2048.
Pattern:
^arn:aws(-cn|-us-gov|-iso-f)?:sagemaker:[a-z0-9\-]{9,16}:[0-9]{12}:model-package/[\S]{1,2048}$
- ModelPackageDescription
-
A brief summary of the model package.
Type: String
Length Constraints: Maximum length of 1024.
Pattern:
[\p{L}\p{M}\p{Z}\p{S}\p{N}\p{P}]*
- ModelPackageGroupName
-
If the model is a versioned model, the name of the model group that the versioned model belongs to.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 63.
Pattern:
^[a-zA-Z0-9](-*[a-zA-Z0-9]){0,62}$
- ModelPackageName
-
The name of the model package being described.
Type: String
Length Constraints: Minimum length of 1. Maximum length of 63.
Pattern:
^[a-zA-Z0-9](-*[a-zA-Z0-9]){0,62}$
- ModelPackageStatus
-
The current status of the model package.
Type: String
Valid Values:
Pending | InProgress | Completed | Failed | Deleting
- ModelPackageStatusDetails
-
Details about the current status of the model package.
Type: ModelPackageStatusDetails object
- ModelPackageVersion
-
The version of the model package.
Type: Integer
Valid Range: Minimum value of 1.
- SamplePayloadUrl
-
The Amazon Simple Storage Service (Amazon S3) path where the sample payload are stored. This path points to a single gzip compressed tar archive (.tar.gz suffix).
Type: String
- SecurityConfig
-
The AWS KMS Key ID (
KMSKeyId
) used for encryption of model package information.Type: ModelPackageSecurityConfig object
- SkipModelValidation
-
Indicates if you want to skip model validation.
Type: String
Valid Values:
All | None
- SourceAlgorithmSpecification
-
Details about the algorithm that was used to create the model package.
Type: SourceAlgorithmSpecification object
- SourceUri
-
The URI of the source for the model package.
Type: String
Length Constraints: Minimum length of 0. Maximum length of 1024.
Pattern:
[\p{L}\p{M}\p{Z}\p{N}\p{P}]{0,1024}
- Task
-
The machine learning task you specified that your model package accomplishes. Common machine learning tasks include object detection and image classification.
Type: String
- ValidationSpecification
-
Configurations for one or more transform jobs that SageMaker runs to test the model package.
Type: ModelPackageValidationSpecification object
Errors
For information about the errors that are common to all actions, see Common Errors.
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following: