From 837c52c0257e984d9cf2877333242d7a84d46024 Mon Sep 17 00:00:00 2001 From: Xichao Wang Date: Tue, 13 Oct 2026 03:02:48 +0000 Subject: [PATCH] chore(core): sync the bundled SageMaker service model with botocore Refreshes sagemaker-core's codegen input from the public botocore model and regenerates the layers built from it. The model file is the upstream bytes verbatim; the generated layers are the output of ``python -m sagemaker.core.tools.codegen``. Model: 403 -> 409 operations, 3005 -> 3084 shapes. What the refresh brings in -------------------------- * Six new operations: AttachClusterNodeNetworkInterface, and the five training-session operations (Create, Describe, List, Stop, Delete). * 79 new shapes, of which 19 belong to the training-session operations and 60 to other parts of the API. * 66 existing shapes whose definitions have moved upstream, spanning AIBenchmark, AIRecommendation, App and Cluster among others. * NotebookInstance gains the PendingMaintenance and InMaintenance states. * MlflowApp gains kms_key_id in the configuration schema. * A TrainingSession resource, derived from the standard CRUD naming: create / get / get_all, and delete / refresh / stop / wait_for_delete / wait_for_status. No caller is switched over to any newly generated resource here. This change only brings the generated layer back in line with the model. One codegen change, for a resource whose identifier is nested ------------------------------------------------------------- DescribeTrainingSession returns everything inside a single TrainingSessionDetail member, so TrainingSessionName is not hoisted onto the resource class. Without the identifier as a class attribute, stop() raised AttributeError, refresh() and delete() took it as a required positional while wait_for_status() and wait_for_delete() called refresh() with none, and get_name() returned None. resources_codegen.py already keeps a list of resources whose identifier is absent from their describe output (ImageVersion, Workteam, Workforce, SubscribedWorkteam, HubContent) and injects it as a class attribute for exactly this reason. TrainingSession is added to that list. The nested value stays reachable at training_session_detail.training_session_name. The general fix would be to unwrap a single-member describe response when collecting class attributes, the way resources_extractor already does when building status chains. That touches generation for every resource and is left alone here. Notes for anyone regenerating ----------------------------- Two things about the generator are worth knowing, since both produce a diff that looks plausible but is wrong: * ``codegen`` needs two passes to converge. ``generate_resources()`` reads the existing config_schema.py to decide which resources get a ``populate_inputs_decorator``, and the schema is regenerated after it, so a single pass emits new resources without one. Those resources then silently ignore sagemaker_config defaults. A third pass is a no-op, so two is enough. * ``resources_extractor`` writes resource_plan.csv to the current working directory, so running the unit tests from sagemaker-core/ overwrites the tracked file with a partial plan. Regenerate before diffing, not after running tests. Separately, codegen does not emit the module docstrings at the top of config_schema.py or shape_dag.py. Neither file is excluded from flake8 or docstyle, so dropping them fails the codestyle gate. Both are preserved here. --- sagemaker-core/resource_plan.csv | 3 +- .../sagemaker/2017-07-24/service-2.json | 1794 ++++++++++++++++- .../src/sagemaker/core/config_schema.py | 26 +- .../src/sagemaker/core/resources.py | 490 ++++- .../src/sagemaker/core/shapes/shapes.py | 704 ++++++- .../sagemaker/core/tools/resources_codegen.py | 8 + .../core/utils/code_injection/shape_dag.py | 520 ++++- 7 files changed, 3341 insertions(+), 204 deletions(-) diff --git a/sagemaker-core/resource_plan.csv b/sagemaker-core/resource_plan.csv index a435777d71..88c4734e81 100644 --- a/sagemaker-core/resource_plan.csv +++ b/sagemaker-core/resource_plan.csv @@ -56,7 +56,7 @@ ModelQualityJobDefinition,resource,"['create', 'get', 'get_all']","['delete', 'r MonitoringAlert,resource,['get_all'],['update'],[],[],"['ListMonitoringAlerts', 'UpdateMonitoringAlert']",[],[] MonitoringExecution,resource,['get_all'],[],[],[],['ListMonitoringExecutions'],[],[] MonitoringSchedule,resource,"['create', 'get', 'get_all']","['delete', 'refresh', 'start', 'stop', 'update', 'wait_for_status']",[],[],"['CreateMonitoringSchedule', 'DeleteMonitoringSchedule', 'DescribeMonitoringSchedule', 'ListMonitoringSchedules', 'StartMonitoringSchedule', 'StopMonitoringSchedule', 'UpdateMonitoringSchedule']","[{'name': 'MonitoringScheduleStatus', 'shape_name': 'ScheduleStatus'}]","['Pending', 'Failed', 'Scheduled', 'Stopped']" -NotebookInstance,resource,"['create', 'get', 'get_all']","['delete', 'refresh', 'start', 'stop', 'update', 'wait_for_delete', 'wait_for_status']",[],[],"['CreateNotebookInstance', 'DeleteNotebookInstance', 'DescribeNotebookInstance', 'ListNotebookInstances', 'StartNotebookInstance', 'StopNotebookInstance', 'UpdateNotebookInstance']","[{'name': 'NotebookInstanceStatus', 'shape_name': 'NotebookInstanceStatus'}]","['Pending', 'InService', 'Stopping', 'Stopped', 'Failed', 'Deleting', 'Updating']" +NotebookInstance,resource,"['create', 'get', 'get_all']","['delete', 'refresh', 'start', 'stop', 'update', 'wait_for_delete', 'wait_for_status']",[],[],"['CreateNotebookInstance', 'DeleteNotebookInstance', 'DescribeNotebookInstance', 'ListNotebookInstances', 'StartNotebookInstance', 'StopNotebookInstance', 'UpdateNotebookInstance']","[{'name': 'NotebookInstanceStatus', 'shape_name': 'NotebookInstanceStatus'}]","['Pending', 'InService', 'Stopping', 'Stopped', 'Failed', 'Deleting', 'Updating', 'PendingMaintenance', 'InMaintenance']" NotebookInstanceLifecycleConfig,resource,"['create', 'get', 'get_all']","['delete', 'refresh', 'update']",[],[],"['CreateNotebookInstanceLifecycleConfig', 'DeleteNotebookInstanceLifecycleConfig', 'DescribeNotebookInstanceLifecycleConfig', 'ListNotebookInstanceLifecycleConfigs', 'UpdateNotebookInstanceLifecycleConfig']",[],[] OptimizationJob,resource,"['create', 'get', 'get_all']","['delete', 'refresh', 'stop', 'wait']",[],[],"['CreateOptimizationJob', 'DeleteOptimizationJob', 'DescribeOptimizationJob', 'ListOptimizationJobs', 'StopOptimizationJob']","[{'name': 'OptimizationJobStatus', 'shape_name': 'OptimizationJobStatus'}]","['INPROGRESS', 'COMPLETED', 'FAILED', 'STARTING', 'STOPPING', 'STOPPED']" PartnerApp,resource,"['create', 'get', 'get_all']","['delete', 'refresh', 'update', 'wait_for_delete', 'wait_for_status']",[],[],"['CreatePartnerApp', 'DeletePartnerApp', 'DescribePartnerApp', 'ListPartnerApps', 'UpdatePartnerApp']","[{'name': 'Status', 'shape_name': 'PartnerAppStatus'}]","['Creating', 'Updating', 'Deleting', 'Available', 'Failed', 'UpdateFailed', 'Deleted']" @@ -77,6 +77,7 @@ SubscribedWorkteam,resource,"['get', 'get_all']",['refresh'],[],[],"['DescribeSu Tag,resource,['get_all'],[],[],[],['ListTags'],[],[] TrainingJob,resource,"['create', 'get', 'get_all']","['delete', 'refresh', 'stop', 'update', 'wait', 'wait_for_delete']",[],[],"['CreateTrainingJob', 'DeleteTrainingJob', 'DescribeTrainingJob', 'ListTrainingJobs', 'StopTrainingJob', 'UpdateTrainingJob']","[{'name': 'TrainingJobStatus', 'shape_name': 'TrainingJobStatus'}]","['InProgress', 'Completed', 'Failed', 'Stopping', 'Stopped', 'Deleting']" TrainingPlan,resource,"['create', 'get', 'get_all']","['refresh', 'wait_for_status']",[],['ExtendTrainingPlan'],"['CreateTrainingPlan', 'DescribeTrainingPlan', 'ExtendTrainingPlan', 'ListTrainingPlans']","[{'name': 'Status', 'shape_name': 'TrainingPlanStatus'}]","['Pending', 'Active', 'Scheduled', 'Expired', 'Failed']" +TrainingSession,resource,"['create', 'get', 'get_all']","['delete', 'refresh', 'stop', 'wait_for_delete', 'wait_for_status']",[],[],"['CreateTrainingSession', 'DeleteTrainingSession', 'DescribeTrainingSession', 'ListTrainingSessions', 'StopTrainingSession']","[{'name': 'TrainingSessionDetail', 'shape_name': 'TrainingSessionDetail'}, {'name': 'TrainingSessionStatus', 'shape_name': 'TrainingSessionStatus'}]","['Created', 'Blocked', 'Running', 'Failed', 'Scheduled', 'Stopping', 'Stopped', 'Expired', 'Deleting', 'DeletionFailed']" TransformJob,resource,"['create', 'get', 'get_all']","['refresh', 'stop', 'wait']",['Model'],[],"['CreateTransformJob', 'DescribeTransformJob', 'ListTransformJobs', 'StopTransformJob']","[{'name': 'TransformJobStatus', 'shape_name': 'TransformJobStatus'}]","['InProgress', 'Completed', 'Failed', 'Stopping', 'Stopped']" Trial,resource,"['create', 'get', 'get_all']","['delete', 'refresh', 'update']",['Experiment'],[],"['CreateTrial', 'DeleteTrial', 'DescribeTrial', 'ListTrials', 'UpdateTrial']",[],[] TrialComponent,resource,"['create', 'get', 'get_all']","['delete', 'refresh', 'update', 'wait_for_status']",[],[],"['CreateTrialComponent', 'DeleteTrialComponent', 'DescribeTrialComponent', 'ListTrialComponents', 'UpdateTrialComponent']","[{'name': 'Status', 'shape_name': 'TrialComponentStatus'}, {'name': 'PrimaryStatus', 'shape_name': 'TrialComponentPrimaryStatus'}]","['InProgress', 'Completed', 'Failed', 'Stopping', 'Stopped']" diff --git a/sagemaker-core/sample/sagemaker/2017-07-24/service-2.json b/sagemaker-core/sample/sagemaker/2017-07-24/service-2.json index e903657013..e596e34099 100644 --- a/sagemaker-core/sample/sagemaker/2017-07-24/service-2.json +++ b/sagemaker-core/sample/sagemaker/2017-07-24/service-2.json @@ -54,6 +54,20 @@ ], "documentation":"

Associates a trial component with a trial. A trial component can be associated with multiple trials. To disassociate a trial component from a trial, call the DisassociateTrialComponent API.

" }, + "AttachClusterNodeNetworkInterface":{ + "name":"AttachClusterNodeNetworkInterface", + "http":{ + "method":"POST", + "requestUri":"/" + }, + "input":{"shape":"AttachClusterNodeNetworkInterfaceRequest"}, + "output":{"shape":"AttachClusterNodeNetworkInterfaceResponse"}, + "errors":[ + {"shape":"ResourceNotFound"}, + {"shape":"ResourceLimitExceeded"} + ], + "documentation":"

Attaches an elastic network interface (ENI) to a node in a HyperPod cluster.

To use this operation, you must have the sagemaker:AttachClusterNodeNetworkInterface permission.

" + }, "AttachClusterNodeVolume":{ "name":"AttachClusterNodeVolume", "http":{ @@ -1022,6 +1036,21 @@ ], "documentation":"

Creates a new training plan in SageMaker to reserve compute capacity.

Amazon SageMaker Training Plan is a capability within SageMaker that allows customers to reserve and manage GPU capacity for large-scale AI model training. It provides a way to secure predictable access to computational resources within specific timelines and budgets, without the need to manage underlying infrastructure.

How it works

Plans can be created for specific resources such as SageMaker Training Jobs or SageMaker HyperPod clusters, automatically provisioning resources, setting up infrastructure, executing workloads, and handling infrastructure failures.

Plan creation workflow

Plan composition

A plan can consist of one or more Reserved Capacities, each defined by a specific instance type, quantity, Availability Zone, duration, and start and end times. For more information about Reserved Capacity, see ReservedCapacitySummary .

" }, + "CreateTrainingSession":{ + "name":"CreateTrainingSession", + "http":{ + "method":"POST", + "requestUri":"/" + }, + "input":{"shape":"CreateTrainingSessionRequest"}, + "output":{"shape":"CreateTrainingSessionResponse"}, + "errors":[ + {"shape":"ResourceNotFound"}, + {"shape":"ResourceInUse"}, + {"shape":"ResourceLimitExceeded"} + ], + "documentation":"

Creates a training session in Amazon SageMaker. A training session provisions compute resources for fine-tuning a foundation model using Low-Rank Adaptation (LoRA). After the session is created, you can submit training operations and sample inference requests through the Amazon SageMaker Training Session Runtime API.

The following operations are related to CreateTrainingSession:

" + }, "CreateTransformJob":{ "name":"CreateTransformJob", "http":{ @@ -1795,6 +1824,19 @@ ], "documentation":"

Deletes a training job. After SageMaker deletes a training job, all of the metadata for the training job is lost. You can delete only training jobs that are in a terminal state (Stopped, Failed, or Completed) and don't retain an Available managed warm pool. You cannot delete a job that is in the InProgress or Stopping state. After deleting the job, you can reuse its name to create another training job.

" }, + "DeleteTrainingSession":{ + "name":"DeleteTrainingSession", + "http":{ + "method":"POST", + "requestUri":"/" + }, + "input":{"shape":"DeleteTrainingSessionRequest"}, + "output":{"shape":"DeleteTrainingSessionResponse"}, + "errors":[ + {"shape":"ResourceNotFound"} + ], + "documentation":"

Deletes a training session. You must stop a running session before deleting it. Use the StopTrainingSession operation to stop the session first.

The following operations are related to DeleteTrainingSession:

" + }, "DeleteTrial":{ "name":"DeleteTrial", "http":{ @@ -2472,7 +2514,7 @@ "errors":[ {"shape":"ResourceNotFound"} ], - "documentation":"

Describes the content, creation time, and security configuration of an Amazon SageMaker Model Card.

" + "documentation":"

Describes the content, creation time, and security configuration of an Amazon SageMaker Model Card.

To retrieve only metadata about a model card without requiring kms:Decrypt permission on the associated customer-managed Amazon Web Services KMS key, set IncludedData to MetadataOnly. The default is AllData, which returns the full model card Content and requires kms:Decrypt permission when a customer-managed key is configured.

" }, "DescribeModelCardExportJob":{ "name":"DescribeModelCardExportJob", @@ -2508,7 +2550,7 @@ }, "input":{"shape":"DescribeModelPackageInput"}, "output":{"shape":"DescribeModelPackageOutput"}, - "documentation":"

Returns a description of the specified model package, which is used to create SageMaker models or list them on Amazon Web Services Marketplace.

If you provided a 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 Amazon Web Services Marketplace.

" + "documentation":"

Returns a description of the specified model package, which is used to create SageMaker models or list them on Amazon Web Services Marketplace.

If you provided a 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 call this operation without requiring kms:Decrypt permission on the customer-managed key, set IncludedData to MetadataOnly; the response is returned with the embedded ModelCard.ModelCardContent field sanitized.

To create models in SageMaker, buyers can subscribe to model packages listed on Amazon Web Services Marketplace.

" }, "DescribeModelPackageGroup":{ "name":"DescribeModelPackageGroup", @@ -2742,6 +2784,20 @@ ], "documentation":"

Retrieves the extension history for a specified training plan. The response includes details about each extension, such as the offering ID, start and end dates, status, payment status, and cost information.

" }, + "DescribeTrainingSession":{ + "name":"DescribeTrainingSession", + "http":{ + "method":"POST", + "requestUri":"/" + }, + "input":{"shape":"DescribeTrainingSessionRequest"}, + "output":{"shape":"DescribeTrainingSessionResponse"}, + "errors":[ + {"shape":"ResourceNotFound"} + ], + "documentation":"

Retrieves detailed information about a training session, including its current status, model configuration, Low-Rank Adaptation (LoRA) parameters, and timestamps.

The following operations are related to DescribeTrainingSession:

", + "readonly":true + }, "DescribeTransformJob":{ "name":"DescribeTransformJob", "http":{ @@ -3856,6 +3912,17 @@ "output":{"shape":"ListTrainingPlansResponse"}, "documentation":"

Retrieves a list of training plans for the current account.

" }, + "ListTrainingSessions":{ + "name":"ListTrainingSessions", + "http":{ + "method":"POST", + "requestUri":"/" + }, + "input":{"shape":"ListTrainingSessionsRequest"}, + "output":{"shape":"ListTrainingSessionsResponse"}, + "documentation":"

Lists training sessions in your account. You can filter results by creation time, name, and status. The operation paginates results. To retrieve additional results, use the NextToken parameter.

The following operations are related to ListTrainingSessions:

", + "readonly":true + }, "ListTransformJobs":{ "name":"ListTransformJobs", "http":{ @@ -4373,6 +4440,19 @@ ], "documentation":"

Stops a training job. To stop a job, SageMaker sends the algorithm the SIGTERM signal, which delays job termination for 120 seconds. Algorithms might use this 120-second window to save the model artifacts, so the results of the training is not lost.

When it receives a StopTrainingJob request, SageMaker changes the status of the job to Stopping. After SageMaker stops the job, it sets the status to Stopped.

" }, + "StopTrainingSession":{ + "name":"StopTrainingSession", + "http":{ + "method":"POST", + "requestUri":"/" + }, + "input":{"shape":"StopTrainingSessionRequest"}, + "output":{"shape":"StopTrainingSessionResponse"}, + "errors":[ + {"shape":"ResourceNotFound"} + ], + "documentation":"

Stops a running training session and sets the session status to Stopping. After the session stops, the status changes to Stopped. To delete a stopped session, use the DeleteTrainingSession operation.

The following operations are related to StopTrainingSession:

" + }, "StopTransformJob":{ "name":"StopTransformJob", "http":{ @@ -5003,6 +5083,76 @@ } }, "shapes":{ + "AIAdapterId":{ + "type":"string", + "documentation":"

A unique identifier for a LoRA adapter within a recommendation job request. The ID must start and end with an alphanumeric character, can contain hyphens between alphanumeric characters, and can be up to 63 characters long. This ID is used as the inference component name when the adapter is deployed.

", + "max":63, + "min":1, + "pattern":"[a-zA-Z0-9](-*[a-zA-Z0-9])*" + }, + "AIAdapterModelPackageEntry":{ + "type":"structure", + "required":[ + "AdapterId", + "ModelPackageArn" + ], + "members":{ + "AdapterId":{ + "shape":"AIAdapterId", + "documentation":"

A unique identifier for the adapter. This ID is used as the inference component name when the adapter is deployed. The ID must start and end with an alphanumeric character, can contain hyphens between alphanumeric characters, and can be up to 63 characters long.

" + }, + "ModelPackageArn":{ + "shape":"ModelPackageArn", + "documentation":"

The Amazon Resource Name (ARN) of the model package that contains the LoRA adapter artifacts.

" + } + }, + "documentation":"

A LoRA adapter entry identified by a model package ARN.

" + }, + "AIAdapterModelPackageEntryList":{ + "type":"list", + "member":{"shape":"AIAdapterModelPackageEntry"}, + "max":10, + "min":1 + }, + "AIAdapterS3Entry":{ + "type":"structure", + "required":[ + "AdapterId", + "S3Uri" + ], + "members":{ + "AdapterId":{ + "shape":"AIAdapterId", + "documentation":"

A unique identifier for the adapter. This ID is used as the inference component name when the adapter is deployed. The ID must start and end with an alphanumeric character, can contain hyphens between alphanumeric characters, and can be up to 63 characters long.

" + }, + "S3Uri":{ + "shape":"S3Uri", + "documentation":"

The Amazon S3 URI of the directory that contains the LoRA adapter artifacts in PEFT format.

" + } + }, + "documentation":"

A LoRA adapter entry identified by an Amazon S3 URI.

" + }, + "AIAdapterS3EntryList":{ + "type":"list", + "member":{"shape":"AIAdapterS3Entry"}, + "max":10, + "min":1 + }, + "AIAdapterSource":{ + "type":"structure", + "members":{ + "ModelPackageArns":{ + "shape":"AIAdapterModelPackageEntryList", + "documentation":"

A list of LoRA adapters identified by their model package ARNs. Use this when your adapters were produced by a SageMaker AI fine-tuning workflow that registers model packages.

" + }, + "S3Uris":{ + "shape":"AIAdapterS3EntryList", + "documentation":"

A list of LoRA adapters identified by their Amazon S3 URIs. Use this when your adapters are stored as raw artifacts in Amazon S3.

" + } + }, + "documentation":"

The source of LoRA adapters for an AI recommendation job. This is a union type — specify exactly one of the members.

", + "union":true + }, "AIBenchmarkEndpoint":{ "type":"structure", "required":["Identifier"], @@ -5110,6 +5260,10 @@ "S3OutputLocation":{ "shape":"S3Uri", "documentation":"

The Amazon S3 URI where benchmark results are stored.

" + }, + "MlflowConfig":{ + "shape":"AIMlflowConfig", + "documentation":"

The MLflow tracking configuration for the job. If you don't specify this parameter, MLflow tracking is disabled.

" } }, "documentation":"

The output configuration for an AI benchmark job.

" @@ -5125,6 +5279,10 @@ "CloudWatchLogs":{ "shape":"AICloudWatchLogsList", "documentation":"

The CloudWatch log information for the benchmark job.

" + }, + "MlflowConfig":{ + "shape":"AIMlflowConfig", + "documentation":"

The MLflow tracking configuration for the job.

" } }, "documentation":"

The output result of an AI benchmark job, including the Amazon S3 location and CloudWatch log information.

" @@ -5215,6 +5373,43 @@ "type":"list", "member":{"shape":"AIMlReservationArn"} }, + "AIMlflowConfig":{ + "type":"structure", + "required":["MlflowResourceArn"], + "members":{ + "MlflowResourceArn":{ + "shape":"AIMlflowResourceArn", + "documentation":"

The Amazon Resource Name (ARN) of the SageMaker managed MLflow resource.

" + }, + "MlflowExperimentName":{ + "shape":"AIMlflowExperimentName", + "documentation":"

The MLflow experiment name used for tracking.

" + }, + "MlflowRunName":{ + "shape":"AIMlflowRunName", + "documentation":"

The MLflow run name used for tracking.

" + } + }, + "documentation":"

The MLflow tracking configuration for logging metrics and parameters to a SageMaker managed MLflow tracking server.

" + }, + "AIMlflowExperimentName":{ + "type":"string", + "max":256, + "min":1, + "pattern":"[a-zA-Z0-9\\-_./]+" + }, + "AIMlflowResourceArn":{ + "type":"string", + "max":2048, + "min":20, + "pattern":"arn:aws[a-z\\-]*:sagemaker:[a-z0-9\\-]*:[0-9]{12}:mlflow-(app|tracking-server)/.*" + }, + "AIMlflowRunName":{ + "type":"string", + "max":256, + "min":1, + "pattern":"[a-zA-Z0-9\\-_./]+" + }, "AIModelSource":{ "type":"structure", "members":{ @@ -5262,10 +5457,32 @@ "ExpectedPerformance":{ "shape":"ExpectedPerformanceList", "documentation":"

The expected performance metrics for this recommendation.

" + }, + "AdapterDetails":{ + "shape":"AIRecommendationAdapterDetails", + "documentation":"

The LoRA adapter details for this recommendation. This field contains both the model package ARNs and Amazon S3 URIs for each adapter, regardless of which form was originally supplied. This field is absent when the job was created without LoRA adapters.

" } }, "documentation":"

An optimization recommendation generated by an AI recommendation job.

" }, + "AIRecommendationAdapterDetails":{ + "type":"structure", + "required":[ + "ModelPackageArns", + "S3Uris" + ], + "members":{ + "ModelPackageArns":{ + "shape":"AIAdapterModelPackageEntryList", + "documentation":"

The list of LoRA adapters with their model package ARNs.

" + }, + "S3Uris":{ + "shape":"AIAdapterS3EntryList", + "documentation":"

The list of LoRA adapters with their Amazon S3 URIs.

" + } + }, + "documentation":"

The per-recommendation LoRA adapter details. Contains both the model package ARNs and Amazon S3 URIs for each adapter, regardless of which form was originally supplied in the request. When you supply only Amazon S3 URIs, Amazon SageMaker AI creates model packages on your behalf.

" + }, "AIRecommendationAllowOptimization":{ "type":"boolean", "box":true @@ -5329,6 +5546,10 @@ "EnvironmentVariables":{ "shape":"EnvironmentMap", "documentation":"

The environment variables for the deployment.

" + }, + "MinCpuMemoryRequiredInMb":{ + "shape":"AIRecommendationMinCpuMemoryRequiredInMb", + "documentation":"

The minimum host (CPU) memory, in MiB, to reserve for each model copy when deploying the recommendation as an Inference Component. This value maps to the Inference Component's ComputeResourceRequirements$MinMemoryRequiredInMb field.

" } }, "documentation":"

The deployment configuration for a recommendation.

" @@ -5421,6 +5642,12 @@ "ml.g6e.16xlarge", "ml.g6e.24xlarge", "ml.g6e.48xlarge", + "ml.g7.2xlarge", + "ml.g7.4xlarge", + "ml.g7.8xlarge", + "ml.g7.12xlarge", + "ml.g7.24xlarge", + "ml.g7.48xlarge", "ml.g7e.2xlarge", "ml.g7e.4xlarge", "ml.g7e.8xlarge", @@ -5509,6 +5736,11 @@ "cost" ] }, + "AIRecommendationMinCpuMemoryRequiredInMb":{ + "type":"integer", + "box":true, + "min":1 + }, "AIRecommendationModelDetails":{ "type":"structure", "members":{ @@ -5568,6 +5800,10 @@ "ModelPackageGroupIdentifier":{ "shape":"AIResourceIdentifier", "documentation":"

The name or Amazon Resource Name (ARN) of the model package group where the optimized model is registered as a new model package version.

" + }, + "MlflowConfig":{ + "shape":"AIMlflowConfig", + "documentation":"

The MLflow tracking configuration for the job. If you don't specify this parameter, MLflow tracking is disabled.

" } }, "documentation":"

The output configuration for an AI recommendation job.

" @@ -5583,6 +5819,10 @@ "ModelPackageGroupIdentifier":{ "shape":"AIResourceIdentifier", "documentation":"

The name or Amazon Resource Name (ARN) of the model package group where deployment-ready model packages are registered.

" + }, + "MlflowConfig":{ + "shape":"AIMlflowConfig", + "documentation":"

The MLflow tracking configuration for the job.

" } }, "documentation":"

The output configuration for an AI recommendation job, including the S3 location for results and the model package group for deployment.

" @@ -6637,7 +6877,19 @@ "ml.r6id.16xlarge", "ml.r6id.24xlarge", "ml.r6id.32xlarge", - "ml.p5.4xlarge" + "ml.p5.4xlarge", + "ml.g7.2xlarge", + "ml.g7.4xlarge", + "ml.g7.8xlarge", + "ml.g7.12xlarge", + "ml.g7.24xlarge", + "ml.g7.48xlarge", + "ml.g7e.2xlarge", + "ml.g7e.4xlarge", + "ml.g7e.8xlarge", + "ml.g7e.12xlarge", + "ml.g7e.24xlarge", + "ml.g7e.48xlarge" ] }, "AppLifecycleManagement":{ @@ -6722,6 +6974,12 @@ "Canvas" ] }, + "ApplicationArn":{ + "type":"string", + "max":128, + "min":1, + "pattern":"arn:aws[a-z\\-]*:sso::[0-9]{12}:application/(sso)?ins-[a-zA-Z0-9.-]{16}/apl-[a-zA-Z0-9.-]{16}" + }, "ApprovalDescription":{ "type":"string", "max":1024, @@ -7122,6 +7380,55 @@ "min":1, "pattern":"[a-zA-Z0-9._-]+" }, + "AttachClusterNodeNetworkInterfaceRequest":{ + "type":"structure", + "required":[ + "ClusterName", + "NodeId", + "NetworkInterfaceId" + ], + "members":{ + "ClusterName":{ + "shape":"ClusterNameOrArn", + "documentation":"

The name or Amazon Resource Name (ARN) of the SageMaker HyperPod cluster that contains the target node.

" + }, + "NodeId":{ + "shape":"ClusterNodeId", + "documentation":"

The unique identifier of the cluster node to which you want to attach the network interface. The node must belong to your specified HyperPod cluster and cannot be part of a Restricted Instance Group (RIG).

" + }, + "NetworkInterfaceId":{ + "shape":"ClusterNetworkInterfaceId", + "documentation":"

The unique identifier of the elastic network interface (ENI) to attach.

" + } + } + }, + "AttachClusterNodeNetworkInterfaceResponse":{ + "type":"structure", + "required":[ + "ClusterArn", + "NodeId", + "NetworkInterfaceId", + "AttachmentId" + ], + "members":{ + "ClusterArn":{ + "shape":"ClusterArn", + "documentation":"

The Amazon Resource Name (ARN) of your SageMaker HyperPod cluster where the network interface attachment operation was performed.

" + }, + "NodeId":{ + "shape":"ClusterNodeId", + "documentation":"

The unique identifier of the cluster node where your network interface was attached.

" + }, + "NetworkInterfaceId":{ + "shape":"ClusterNetworkInterfaceId", + "documentation":"

The unique identifier of the elastic network interface (ENI) that was attached.

" + }, + "AttachmentId":{ + "shape":"ClusterNetworkInterfaceAttachmentId", + "documentation":"

The unique identifier of the network interface attachment. Use this value to reference or detach the network interface later.

" + } + } + }, "AttachClusterNodeVolumeRequest":{ "type":"structure", "required":[ @@ -8092,6 +8399,12 @@ }, "documentation":"

Identifies the foundation model that was used as the starting point for model customization.

" }, + "BaseModelArn":{ + "type":"string", + "max":2048, + "min":1, + "pattern":"(arn:[a-z0-9-.]{1,63}:sagemaker:[a-zA-Z0-9]+(?:-[a-zA-Z0-9]+)+:([0-9]{12}|aws):hub-content/)[a-zA-Z0-9](-*[a-zA-Z0-9]){0,62}/Model/[a-zA-Z0-9](-*[a-zA-Z0-9]){0,63}(/[0-9]{1,4}\\.[0-9]{1,4}\\.[0-9]{1,4})?" + }, "BaseModelName":{ "type":"string", "max":256, @@ -8793,6 +9106,24 @@ "box":true, "min":0 }, + "BillableTokenUsage":{ + "type":"structure", + "members":{ + "PrefillTokenCount":{ + "shape":"JavaLong", + "documentation":"

The number of prefill tokens consumed.

" + }, + "SampleTokenCount":{ + "shape":"JavaLong", + "documentation":"

The number of sample tokens consumed.

" + }, + "TrainingTokenCount":{ + "shape":"JavaLong", + "documentation":"

The number of training tokens consumed.

" + } + }, + "documentation":"

The billable token usage for a training session, broken down by operation type.

" + }, "BlockedReason":{ "type":"string", "max":1024, @@ -9895,12 +10226,103 @@ "min":1, "pattern":"[a-zA-Z0-9-]+" }, + "ClusterAccountingDatabase":{ + "type":"structure", + "required":[ + "Endpoint", + "SecretArn" + ], + "members":{ + "Endpoint":{ + "shape":"ClusterAccountingDatabaseEndpoint", + "documentation":"

The hostname or endpoint of the accounting database, such as the endpoint of an Amazon RDS for MySQL or Aurora MySQL database. The database must be reachable from the subnets and security groups that you configure for the cluster.

" + }, + "Port":{ + "shape":"ClusterAccountingDatabasePort", + "documentation":"

The port that the accounting database listens on. The default is 3306.

" + }, + "Name":{ + "shape":"ClusterAccountingDatabaseName", + "documentation":"

The name of the database schema that stores the Slurm accounting data. The default is slurm_acct_db_ followed by the cluster ID from the cluster ARN, for example slurm_acct_db_a1b2c3d4e5f6.

" + }, + "SecretArn":{ + "shape":"ClusterAccountingDatabaseSecretArn", + "documentation":"

The Amazon Resource Name (ARN) of the Amazon Web Services Secrets Manager secret that contains the user name and password for the accounting database. The database user must be able to create the schema and to read from and write to it.

" + } + }, + "documentation":"

The external MySQL-compatible database that the Slurm accounting daemon (slurmdbd) connects to for a SageMaker HyperPod cluster. You provide the database credentials in an Amazon Web Services Secrets Manager secret instead of in the request.

" + }, + "ClusterAccountingDatabaseEndpoint":{ + "type":"string", + "max":255, + "min":1, + "pattern":"(?=.{1,255}$)([a-zA-Z0-9]([a-zA-Z0-9\\-]{0,61}[a-zA-Z0-9])?)(\\.[a-zA-Z0-9]([a-zA-Z0-9\\-]{0,61}[a-zA-Z0-9])?)*" + }, + "ClusterAccountingDatabaseName":{ + "type":"string", + "max":64, + "min":1, + "pattern":"[a-zA-Z0-9$_]+" + }, + "ClusterAccountingDatabasePort":{ + "type":"integer", + "box":true, + "max":65535, + "min":1 + }, + "ClusterAccountingDatabaseSecretArn":{ + "type":"string", + "max":2048, + "min":20, + "pattern":"arn:aws[a-z\\-]*:secretsmanager:[a-z0-9\\-]*:[0-9]{12}:secret:.+" + }, "ClusterArn":{ "type":"string", "max":256, "min":0, "pattern":"arn:aws[a-z\\-]*:sagemaker:[a-z0-9\\-]*:[0-9]{12}:cluster/[a-z0-9]{12}" }, + "ClusterAutoPatchConfig":{ + "type":"structure", + "required":["PatchingStrategy"], + "members":{ + "PatchingStrategy":{ + "shape":"ClusterPatchingStrategy", + "documentation":"

The strategy for applying patches to instances in the group.

" + }, + "PatchSchedule":{ + "shape":"ClusterPatchSchedule", + "documentation":"

The schedule for automatic patching, including the next patch date.

" + }, + "DeploymentConfig":{ + "shape":"DeploymentConfiguration", + "documentation":"

The deployment configuration for rolling patch updates, including rollback settings and batch sizes. Only applicable when using a rolling patching strategy.

" + } + }, + "documentation":"

The configuration for automatic patching of the instance group. When configured, the system automatically applies security patch AMI updates to the instance group.

" + }, + "ClusterAutoPatchConfigDetails":{ + "type":"structure", + "members":{ + "PatchingStrategy":{ + "shape":"ClusterPatchingStrategy", + "documentation":"

The strategy used for applying patches to instances in the group.

" + }, + "CurrentPatchSchedule":{ + "shape":"ClusterPatchScheduleDetails", + "documentation":"

The currently active patch schedule that the system will execute.

" + }, + "DesiredPatchSchedule":{ + "shape":"ClusterPatchScheduleDetails", + "documentation":"

The requested patch schedule. Differs from CurrentPatchSchedule when a reschedule request is pending.

" + }, + "DeploymentConfig":{ + "shape":"DeploymentConfiguration", + "documentation":"

The deployment configuration for rolling patch updates.

" + } + }, + "documentation":"

The auto-patching configuration details for the instance group, including the patching strategy and schedule.

" + }, "ClusterAutoScalerType":{ "type":"string", "enum":["Karpenter"] @@ -9968,7 +10390,7 @@ }, "ClusterAvailabilityZoneId":{ "type":"string", - "pattern":"[a-z]{3}\\d-az\\d" + "pattern":"[a-z]{3,5}\\d-az\\d" }, "ClusterAvailabilityZones":{ "type":"list", @@ -10219,10 +10641,12 @@ }, "ClusterImageVersionStatus":{ "type":"string", - "documentation":"

The status of the Amazon Machine Image (AMI) version for the HyperPod cluster instance group, node, or cluster. The AMI version is determined at the instance group level, and all nodes within an instance group run the same AMI. The cluster-level status is aggregated across all instance groups.

", + "documentation":"

The status of the Amazon Machine Image (AMI) version for the HyperPod cluster instance group, node, or cluster. The AMI version is determined at the instance group level, and all nodes within an instance group run the same AMI. The cluster-level status is aggregated across all instance groups.

", "enum":[ "UpToDate", - "UpdateAvailable" + "UpdateAvailable", + "SecurityUpdateRequired", + "EndOfLife" ] }, "ClusterInstanceCount":{ @@ -10302,6 +10726,10 @@ "shape":"ScheduledUpdateConfig", "documentation":"

The configuration object of the schedule that SageMaker follows when updating the AMI.

" }, + "AutoPatchConfig":{ + "shape":"ClusterAutoPatchConfigDetails", + "documentation":"

The auto-patching configuration for the instance group, including the current patching strategy and next scheduled patch date.

" + }, "CurrentImageId":{ "shape":"ImageId", "documentation":"

The ID of the Amazon Machine Image (AMI) currently in use by the instance group.

" @@ -10310,6 +10738,14 @@ "shape":"ImageId", "documentation":"

The ID of the Amazon Machine Image (AMI) desired for the instance group.

" }, + "CurrentImageReleaseVersion":{ + "shape":"ImageReleaseVersion", + "documentation":"

The version of the HyperPod-managed AMI currently running on the instance group.

" + }, + "DesiredImageReleaseVersion":{ + "shape":"ImageReleaseVersion", + "documentation":"

The desired version of the HyperPod-managed AMI for the instance group. This may differ from the current version when an update is pending.

" + }, "ImageVersionStatus":{ "shape":"ClusterImageVersionStatus", "documentation":"

The status of the image version for the instance group. Indicates whether the instance group is running the latest image version or if an update is available.

" @@ -10418,7 +10854,15 @@ }, "ImageId":{ "shape":"ImageId", - "documentation":"

When configuring your HyperPod cluster, you can specify an image ID using one of the following options:

If you choose to use a custom AMI (CustomAmiId), ensure it meets the following requirements:

When updating the instance group's AMI through the UpdateClusterSoftware operation, if an instance group uses a custom AMI, you must provide an ImageId or use the default as input. Note that if you don't specify an instance group in your UpdateClusterSoftware request, then all of the instance groups are patched with the specified image.

" + "documentation":"

When configuring your HyperPod cluster, you can specify an image ID using one of the following options:

If you choose to use a custom AMI (CustomAmiId), ensure it meets the following requirements:

When updating the instance group's AMI through the UpdateClusterSoftware operation, if an instance group uses a custom AMI, you must provide an ImageId or use the default as input. Note that if you don't specify an instance group in your UpdateClusterSoftware request, then all of the instance groups are patched with the specified image.

" + }, + "AutoPatchConfig":{ + "shape":"ClusterAutoPatchConfig", + "documentation":"

The configuration for automatic OS security patching. If present, the system automatically applies PATCH AMI updates to this instance group.

" + }, + "ImageReleaseVersion":{ + "shape":"ImageReleaseVersion", + "documentation":"

The version of the HyperPod-managed AMI to use for the instance group. Uses semantic versioning in the format MAJOR.MINOR.PATCH (for example, 1.2.3). If omitted, the latest available version is used.

" }, "KubernetesConfig":{ "shape":"ClusterKubernetesConfig", @@ -10673,7 +11117,93 @@ "ml.g7e.12xlarge", "ml.g7e.24xlarge", "ml.g7e.48xlarge", - "ml.p6-b300.48xlarge" + "ml.p6-b300.48xlarge", + "ml.g4dn.xlarge", + "ml.g4dn.2xlarge", + "ml.g4dn.4xlarge", + "ml.g4dn.8xlarge", + "ml.g4dn.12xlarge", + "ml.g4dn.16xlarge", + "ml.c6g.medium", + "ml.c6g.large", + "ml.c6g.xlarge", + "ml.c6g.2xlarge", + "ml.c6g.4xlarge", + "ml.c6g.8xlarge", + "ml.c6g.12xlarge", + "ml.c6g.16xlarge", + "ml.c7g.medium", + "ml.c7g.large", + "ml.c7g.xlarge", + "ml.c7g.2xlarge", + "ml.c7g.4xlarge", + "ml.c7g.8xlarge", + "ml.c7g.12xlarge", + "ml.c7g.16xlarge", + "ml.c8g.medium", + "ml.c8g.large", + "ml.c8g.xlarge", + "ml.c8g.2xlarge", + "ml.c8g.4xlarge", + "ml.c8g.8xlarge", + "ml.c8g.12xlarge", + "ml.c8g.16xlarge", + "ml.c8g.24xlarge", + "ml.c8g.48xlarge", + "ml.c6a.large", + "ml.c6a.xlarge", + "ml.c6a.2xlarge", + "ml.c6a.4xlarge", + "ml.c6a.8xlarge", + "ml.c6a.12xlarge", + "ml.c6a.16xlarge", + "ml.c6a.24xlarge", + "ml.c6a.32xlarge", + "ml.c6a.48xlarge", + "ml.m6a.large", + "ml.m6a.xlarge", + "ml.m6a.2xlarge", + "ml.m6a.4xlarge", + "ml.m6a.8xlarge", + "ml.m6a.12xlarge", + "ml.m6a.16xlarge", + "ml.m6a.24xlarge", + "ml.m6a.32xlarge", + "ml.m6a.48xlarge", + "ml.m6g.medium", + "ml.m6g.large", + "ml.m6g.xlarge", + "ml.m6g.2xlarge", + "ml.m6g.4xlarge", + "ml.m6g.8xlarge", + "ml.m6g.12xlarge", + "ml.m6g.16xlarge", + "ml.m7g.medium", + "ml.m7g.large", + "ml.m7g.xlarge", + "ml.m7g.2xlarge", + "ml.m7g.4xlarge", + "ml.m7g.8xlarge", + "ml.m7g.12xlarge", + "ml.m7g.16xlarge", + "ml.m8g.medium", + "ml.m8g.large", + "ml.m8g.xlarge", + "ml.m8g.2xlarge", + "ml.m8g.4xlarge", + "ml.m8g.8xlarge", + "ml.m8g.12xlarge", + "ml.m8g.16xlarge", + "ml.m8g.24xlarge", + "ml.m8g.48xlarge", + "ml.g7.2xlarge", + "ml.g7.4xlarge", + "ml.g7.8xlarge", + "ml.g7.12xlarge", + "ml.g7.24xlarge", + "ml.g7.48xlarge", + "ml.c8a.16xlarge", + "ml.m8a.16xlarge" ] }, "ClusterInstanceTypeDetail":{ @@ -10908,6 +11438,12 @@ }, "documentation":"

The network interface configuration for a Amazon SageMaker HyperPod cluster instance group.

" }, + "ClusterNetworkInterfaceAttachmentId":{ + "type":"string", + "max":28, + "min":1, + "pattern":"eni-attach-[0-9a-f]{8}(?:[0-9a-f]{9})?" + }, "ClusterNetworkInterfaceDetails":{ "type":"structure", "members":{ @@ -10918,6 +11454,12 @@ }, "documentation":"

The network interface configuration details for a Amazon SageMaker HyperPod cluster instance group.

" }, + "ClusterNetworkInterfaceId":{ + "type":"string", + "max":21, + "min":1, + "pattern":"eni-[0-9a-f]{8}(?:[0-9a-f]{9})?" + }, "ClusterNodeDetails":{ "type":"structure", "members":{ @@ -10989,6 +11531,14 @@ "shape":"ImageId", "documentation":"

The ID of the Amazon Machine Image (AMI) desired for the node.

" }, + "CurrentImageReleaseVersion":{ + "shape":"ImageReleaseVersion", + "documentation":"

The version of the HyperPod-managed AMI currently running on the node.

" + }, + "DesiredImageReleaseVersion":{ + "shape":"ImageReleaseVersion", + "documentation":"

The desired version of the HyperPod-managed AMI for the node. This may differ from the current version when an update is pending.

" + }, "ImageVersionStatus":{ "shape":"ClusterImageVersionStatus", "documentation":"

The status of the image version for the cluster node.

" @@ -11097,6 +11647,10 @@ "shape":"ClusterPrivateDnsHostname", "documentation":"

The private DNS hostname of the SageMaker HyperPod cluster node.

" }, + "CurrentImageReleaseVersion":{ + "shape":"ImageReleaseVersion", + "documentation":"

The version of the HyperPod-managed AMI currently running on the node.

" + }, "ImageVersionStatus":{ "shape":"ClusterImageVersionStatus", "documentation":"

The status of the image version for the cluster node.

" @@ -11145,6 +11699,10 @@ "SlurmConfigStrategy":{ "shape":"ClusterSlurmConfigStrategy", "documentation":"

The strategy for managing partitions for the Slurm configuration. Valid values are Managed, Overwrite, and Merge.

" + }, + "AccountingDatabase":{ + "shape":"ClusterAccountingDatabase", + "documentation":"

The external database that stores the Slurm accounting data for the cluster, such as job history, associations, and usage. When you omit this field, Slurm accounting uses a database on the cluster's controller node.

This field is only supported for clusters using Continuous as the NodeProvisioningMode.

" } }, "documentation":"

The configuration settings for the Slurm orchestrator used with the SageMaker HyperPod cluster.

" @@ -11161,6 +11719,34 @@ "max":1, "min":0 }, + "ClusterPatchSchedule":{ + "type":"structure", + "members":{ + "NextPatchDate":{ + "shape":"Timestamp", + "documentation":"

The date and time of the next scheduled automatic patch. The system sets this automatically when a patch is detected. Use this field to reschedule the patch to a different date.

" + } + }, + "documentation":"

The schedule configuration for automatic patching.

" + }, + "ClusterPatchScheduleDetails":{ + "type":"structure", + "members":{ + "NextPatchDate":{ + "shape":"Timestamp", + "documentation":"

The date and time of the next scheduled automatic patch.

" + } + }, + "documentation":"

The schedule details for automatic patching, including the next scheduled patch date.

" + }, + "ClusterPatchingStrategy":{ + "type":"string", + "documentation":"

The strategy for applying automatic patches to instances.

", + "enum":[ + "WhenIdle", + "WhenAllIdle" + ] + }, "ClusterPrivateDnsHostname":{ "type":"string", "pattern":"ip-((25[0-5]|(2[0-4]|1\\d|[1-9]|)\\d)-?\\b){4}\\..*" @@ -11518,6 +12104,10 @@ "TrainingPlanArns":{ "shape":"TrainingPlanArns", "documentation":"

A list of Amazon Resource Names (ARNs) of the training plans associated with this cluster.

For more information about how to reserve GPU capacity for your SageMaker HyperPod clusters using Amazon SageMaker Training Plan, see CreateTrainingPlan .

" + }, + "ImageVersionStatus":{ + "shape":"ClusterImageVersionStatus", + "documentation":"

The aggregate status of the image version across the cluster's instance groups.

" } }, "documentation":"

Lists a summary of the properties of a SageMaker HyperPod cluster.

" @@ -12139,6 +12729,10 @@ "MultiModelConfig":{ "shape":"MultiModelConfig", "documentation":"

Specifies additional configuration for multi-model endpoints.

" + }, + "ContainerMetricsConfig":{ + "shape":"ContainerMetricsConfig", + "documentation":"

The configuration for container metrics scraping. Specifies the metrics endpoint path and publishing frequency. If not specified when EnableDetailedObservability is True, the default path /metrics on port 8080 is used. For first-party and Deep Learning Containers (DLC), the endpoint path is determined automatically and this configuration is optional.

" } }, "documentation":"

Describes the container, as part of model definition.

" @@ -12173,6 +12767,16 @@ "min":0, "pattern":"[\\S]+" }, + "ContainerMetricsConfig":{ + "type":"structure", + "members":{ + "MetricsEndpoints":{ + "shape":"MetricsEndpointList", + "documentation":"

A list of metrics endpoints to scrape from the container. Each endpoint specifies the path where the container exposes Prometheus-formatted metrics and the frequency at which to publish them. You can specify a maximum of 1 endpoint.

" + } + }, + "documentation":"

The configuration for container-level metrics scraping. Use this configuration to specify a custom metrics endpoint path and publishing frequency for container metrics. When EnableDetailedObservability is set to True in MetricsConfig, metrics are scraped from the container's Prometheus endpoint. If this configuration is not provided, the default path /metrics on port 8080 is used with a default publishing frequency of 60 seconds. For first-party and Deep Learning Containers (DLC), the endpoint path is determined automatically and this configuration is optional.

" + }, "ContainerMode":{ "type":"string", "enum":[ @@ -12449,6 +13053,10 @@ "shape":"AIRecommendationComputeSpec", "documentation":"

The compute resource specification for the recommendation job. You can specify up to 3 instance types to consider, and optionally provide capacity reservation configuration.

" }, + "AdapterSource":{ + "shape":"AIAdapterSource", + "documentation":"

The LoRA adapter source for the recommendation job. Specify either a list of model package ARNs or Amazon S3 URIs for your LoRA adapters. When this parameter is absent, the recommendation job runs without LoRA adapter support.

" + }, "Tags":{ "shape":"TagList", "documentation":"

The metadata that you apply to Amazon Web Services resources to help you categorize and organize them.

" @@ -12921,7 +13529,7 @@ "members":{ "Name":{ "shape":"EntityName", - "documentation":"

Name for the cluster policy.

" + "documentation":"

The name for the cluster policy. The name must be unique within the SageMaker AI HyperPod cluster specified by ClusterArn. You can use the same name in other clusters within a Region or across Regions.

" }, "ClusterArn":{ "shape":"ClusterArn", @@ -13053,7 +13661,7 @@ "members":{ "Name":{ "shape":"EntityName", - "documentation":"

Name to the compute allocation definition.

" + "documentation":"

The name of the compute allocation definition. The name must be unique within the SageMaker AI HyperPod cluster specified by ClusterArn. You can use the same name in other clusters within a Region or across Regions.

" }, "Description":{ "shape":"EntityDescription", @@ -13437,7 +14045,7 @@ }, "KmsKeyId":{ "shape":"KmsKeyId", - "documentation":"

The Amazon Resource Name (ARN) of a Amazon Web Services Key Management Service key that SageMaker uses to encrypt data on the storage volume attached to the ML compute instance that hosts the endpoint.

The KmsKeyId can be any of the following formats:

The KMS key policy must grant permission to the IAM role that you specify in your CreateEndpoint, UpdateEndpoint requests. For more information, refer to the Amazon Web Services Key Management Service section Using Key Policies in Amazon Web Services KMS

Certain Nitro-based instances include local storage, dependent on the instance type. Local storage volumes are encrypted using a hardware module on the instance. You can't request a KmsKeyId when using an instance type with local storage. If any of the models that you specify in the ProductionVariants parameter use nitro-based instances with local storage, do not specify a value for the KmsKeyId parameter. If you specify a value for KmsKeyId when using any nitro-based instances with local storage, the call to CreateEndpointConfig fails.

For a list of instance types that support local instance storage, see Instance Store Volumes.

For more information about local instance storage encryption, see SSD Instance Store Volumes.

" + "documentation":"

The Amazon Resource Name (ARN) of a Amazon Web Services Key Management Service key that SageMaker uses to encrypt data on the storage volume attached to the ML compute instance that hosts the endpoint.

The KmsKeyId can be any of the following formats:

The KMS key policy must grant permission to the IAM role that you specify in your CreateEndpoint, UpdateEndpoint requests. For more information, refer to the Amazon Web Services Key Management Service section Using Key Policies in Amazon Web Services KMS

Certain Nitro-based instances include local storage, dependent on the instance type. Local storage volumes are encrypted using a hardware module on the instance. If any of the models that you specify in the ProductionVariants parameter use nitro-based instances with local storage, the KmsKeyId parameter does not encrypt instance local storage.

For a list of instance types that support local instance storage, see Instance Store Volumes.

For more information about local instance storage encryption, see SSD Instance Store Volumes.

" }, "AsyncInferenceConfig":{ "shape":"AsyncInferenceConfig", @@ -14261,6 +14869,10 @@ "shape":"RoleArn", "documentation":"

The Amazon Resource Name (ARN) for an IAM role in your account that the MLflow App uses to access the artifact store in Amazon S3. The role should have the AmazonS3FullAccess permission.

" }, + "KmsKeyId":{ + "shape":"KmsKeyId", + "documentation":"

The ID of the Amazon Web Services KMS key used to encrypt the data at rest associated with the MLflow App. If you don't specify a value, the MLflow App is not encrypted with a customer-managed key.

" + }, "ModelRegistrationMode":{ "shape":"ModelRegistrationMode", "documentation":"

Whether to enable or disable automatic registration of new MLflow models to the SageMaker Model Registry. To enable automatic model registration, set this value to AutoModelRegistrationEnabled. To disable automatic model registration, set this value to AutoModelRegistrationDisabled. If not specified, AutomaticModelRegistration defaults to AutoModelRegistrationDisabled.

" @@ -14988,6 +15600,10 @@ "VpcConfig":{ "shape":"OptimizationVpcConfig", "documentation":"

A VPC in Amazon VPC that your optimized model has access to.

" + }, + "TrainingPlanArns":{ + "shape":"OptimizationJobTrainingPlanArns", + "documentation":"

The Amazon Resource Name (ARN) of the training plan to use for this optimization job.

When you use reserved capacity from a training plan, the optimization job runs on that reserved capacity instead of on-demand capacity. If you omit this field, the job uses on-demand capacity. You can specify at most one training plan.

For more information about how to reserve GPU capacity for your optimization jobs using Amazon SageMaker Training Plans, see Reserve capacity with training plans.

" } } }, @@ -15066,9 +15682,13 @@ "shape":"PartnerAppConfig", "documentation":"

Configuration settings for the SageMaker Partner AI App.

" }, + "IdcConfig":{ + "shape":"IdcConfigInput", + "documentation":"

Specifies the Amazon Web Services IAM Identity Center configuration for the SageMaker Partner AI App. Specify this parameter when AuthType is IDC. Apps that use IAM authorization don't use this parameter.

" + }, "AuthType":{ "shape":"PartnerAppAuthType", - "documentation":"

The authorization type that users use to access the SageMaker Partner AI App.

" + "documentation":"

The authorization type that users use to access the SageMaker Partner AI App. Valid values:

" }, "EnableIamSessionBasedIdentity":{ "shape":"Boolean", @@ -15635,6 +16255,60 @@ } } }, + "CreateTrainingSessionRequest":{ + "type":"structure", + "required":[ + "TrainingSessionName", + "LoraConfig", + "RoleArn", + "ModelConfig", + "OutputConfig" + ], + "members":{ + "TrainingSessionName":{ + "shape":"TrainingSessionName", + "documentation":"

The name of the training session.

" + }, + "ModelPackageGroupArn":{ + "shape":"ModelPackageGroupArn", + "documentation":"

The Amazon Resource Name (ARN) of the model package group where checkpoints and fine-tuned model artifacts are published.

" + }, + "LoraConfig":{ + "shape":"LoraConfig", + "documentation":"

The Low-Rank Adaptation (LoRA) configuration for the training session, including the rank and alpha parameters.

" + }, + "RoleArn":{ + "shape":"RoleArn", + "documentation":"

The Amazon Resource Name (ARN) of the IAM role that Amazon SageMaker assumes to access resources on your behalf. The role must have permissions to access the output S3 path and model package group.

" + }, + "VpcConfig":{ + "shape":"VpcConfig", + "documentation":"

The Virtual Private Cloud (VPC) configuration for the training session. Specify subnets and security groups to run the training session in your VPC.

" + }, + "ModelConfig":{ + "shape":"TrainingSessionModelConfig", + "documentation":"

The configuration for the base model, including the model ARN and end-user license agreement (EULA) acceptance.

" + }, + "OutputConfig":{ + "shape":"TrainingSessionOutputConfig", + "documentation":"

The output configuration for the training session, including the S3 location and optional encryption settings.

" + }, + "Tags":{ + "shape":"TagList", + "documentation":"

An array of key-value pairs to apply to the training session as tags. For more information, see Tagging Amazon Web Services Resources.

" + } + } + }, + "CreateTrainingSessionResponse":{ + "type":"structure", + "required":["TrainingSessionArn"], + "members":{ + "TrainingSessionArn":{ + "shape":"TrainingSessionArn", + "documentation":"

The Amazon Resource Name (ARN) of the training session.

" + } + } + }, "CreateTransformJobRequest":{ "type":"structure", "required":[ @@ -16068,6 +16742,12 @@ }, "documentation":"

Details about the POSIX identity that is used for file system operations.

" }, + "CustomerKmsKeyArn":{ + "type":"string", + "max":2048, + "min":1, + "pattern":"arn:aws[a-z\\-]*:kms:[a-z0-9\\-]+:[0-9]{12}:key/(mrk-)?[a-f0-9\\-]+" + }, "CustomerMetadataKey":{ "type":"string", "max":128, @@ -16331,6 +17011,32 @@ "min":1, "pattern":"[\\u0020-\\uD7FF\\uE000-\\uFFFD\\uD800\\uDC00-\\uDBFF\\uDFFF\\t]*" }, + "DatabaseConfigurationMetadata":{ + "type":"structure", + "members":{ + "RollbackStatus":{ + "shape":"DatabaseConfigurationRollbackStatus", + "documentation":"

Whether HyperPod restored the previous accounting database configuration after the change failed. Valid values:

This field is omitted when the change succeeds.

" + }, + "Advisory":{ + "shape":"String", + "documentation":"

Additional information about a change that succeeded, such as an action to take on the cluster.

" + }, + "FailureMessage":{ + "shape":"String", + "documentation":"

An error message describing why the accounting database change failed, and how to resolve it.

" + } + }, + "documentation":"

Metadata information about a change to the external Slurm accounting database of a HyperPod cluster.

" + }, + "DatabaseConfigurationRollbackStatus":{ + "type":"string", + "enum":[ + "NotApplicable", + "Reverted", + "RevertFailed" + ] + }, "DatasetDefinition":{ "type":"structure", "members":{ @@ -16478,7 +17184,7 @@ "DeepHealthChecks":{ "type":"list", "member":{"shape":"DeepHealthCheckType"}, - "max":2, + "max":3, "min":1 }, "DefaultDomainIdList":{ @@ -17384,6 +18090,20 @@ } } }, + "DeleteTrainingSessionRequest":{ + "type":"structure", + "required":["TrainingSessionName"], + "members":{ + "TrainingSessionName":{ + "shape":"TrainingSessionName", + "documentation":"

The name of the training session to delete.

" + } + } + }, + "DeleteTrainingSessionResponse":{ + "type":"structure", + "members":{} + }, "DeleteTrialComponentRequest":{ "type":"structure", "required":["TrialComponentName"], @@ -17800,6 +18520,10 @@ "shape":"AIRecommendationComputeSpec", "documentation":"

The compute resource specification for the recommendation job.

" }, + "AdapterSource":{ + "shape":"AIAdapterSource", + "documentation":"

The LoRA adapter source that you specified when you created the recommendation job. This field is absent when you created the job without LoRA adapters.

" + }, "CreationTime":{ "shape":"Timestamp", "documentation":"

A timestamp that indicates when the recommendation job was created.

" @@ -20770,6 +21494,10 @@ "shape":"RoleArn", "documentation":"

The Amazon Resource Name (ARN) for an IAM role in your account that the MLflow App uses to access the artifact store in Amazon S3.

" }, + "KmsKeyId":{ + "shape":"KmsKeyId", + "documentation":"

The ID of the Amazon Web Services KMS key used to encrypt the data at rest associated with the MLflow App. This field is absent if the MLflow App is not encrypted with a customer-managed key.

" + }, "Status":{ "shape":"MlflowAppStatus", "documentation":"

The current creation status of the described MLflow App.

" @@ -21027,6 +21755,10 @@ "shape":"Integer", "documentation":"

The version of the model card to describe. If a version is not provided, then the latest version of the model card is described.

", "box":true + }, + "IncludedData":{ + "shape":"IncludedData", + "documentation":"

Specifies the level of model card data to include in the response. Use this parameter to call DescribeModelCard without requiring kms:Decrypt permission on the customer-managed Amazon Web Services KMS key.

If you don't specify a value, SageMaker returns AllData.

" } } }, @@ -21057,7 +21789,7 @@ }, "Content":{ "shape":"ModelCardContent", - "documentation":"

The content of the model card.

" + "documentation":"

The content of the model card. Content is provided as a string in the model card JSON schema.

When you set IncludedData to MetadataOnly in the request, SageMaker returns a sanitized version of Content that includes only the following JSON paths, when present in the model card:

All other fields are removed from Content when IncludedData is MetadataOnly, including model description, training details, evaluation details, business details, and additional information. To retrieve the complete Content, set IncludedData to AllData or omit the parameter.

" }, "ModelCardStatus":{ "shape":"ModelCardStatus", @@ -21258,6 +21990,10 @@ "ModelPackageName":{ "shape":"VersionedArnOrName", "documentation":"

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).

" + }, + "IncludedData":{ + "shape":"IncludedData", + "documentation":"

Specifies the level of model package data to include in the response. Use this parameter to call DescribeModelPackage on a model package that has an associated model card without requiring kms:Decrypt permission on the customer-managed KMS key associated with the embedded model card.

If you don't specify a value, SageMaker returns AllData.

" } } }, @@ -21381,7 +22117,7 @@ }, "ModelCard":{ "shape":"ModelPackageModelCard", - "documentation":"

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 of ModelCard. The ModelPackageModelCard schema does not include model_package_details, and model_overview is composed of the model_creator and model_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.

" + "documentation":"

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 of ModelCard. The ModelPackageModelCard schema does not include model_package_details, and model_overview is composed of the model_creator and model_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.

When you set IncludedData to MetadataOnly in the request, ModelCardStatus is preserved and ModelCardContent is sanitized to include only the following JSON paths, when present in the model card:

Because the ModelPackageModelCard schema does not include model_package_details and limits model_overview to model_creator and model_artifact, the sanitized ModelCardContent for a model package typically contains only intended_uses.risk_rating if it was provided when the model card was created. To retrieve the complete ModelCardContent, set IncludedData to AllData or omit the parameter.

" }, "ModelLifeCycle":{ "shape":"ModelLifeCycle", @@ -21756,6 +22492,10 @@ "VpcConfig":{ "shape":"OptimizationVpcConfig", "documentation":"

A VPC in Amazon VPC that your optimized model has access to.

" + }, + "TrainingPlanArns":{ + "shape":"OptimizationJobTrainingPlanArns", + "documentation":"

The Amazon Resource Name (ARN) of the training plan associated with this optimization job. This field appears only when you specified a training plan when you created the job. Optimization jobs that use on-demand capacity don't return this field.

" } } }, @@ -21831,7 +22571,7 @@ }, "AuthType":{ "shape":"PartnerAppAuthType", - "documentation":"

The authorization type that users use to access the SageMaker Partner AI App.

" + "documentation":"

The authorization type that users use to access the SageMaker Partner AI App. Valid values:

" }, "EnableIamSessionBasedIdentity":{ "shape":"Boolean", @@ -21854,6 +22594,10 @@ "AvailableUpgrade":{ "shape":"AvailableUpgrade", "documentation":"

A map of available minor version upgrades for the SageMaker Partner AI App. The key is the semantic version number, and the value is a list of release notes for that version. A null value indicates no upgrades are available.

" + }, + "IdcConfig":{ + "shape":"IdcConfigOutput", + "documentation":"

Contains the Amazon Web Services IAM Identity Center configuration for the SageMaker Partner AI App, including the Identity Center instance and the Identity Center application that SageMaker creates for the app. The service returns this field for apps that use IDC authorization.

" } } }, @@ -22644,7 +23388,7 @@ "required":["TrainingPlanName"], "members":{ "TrainingPlanName":{ - "shape":"TrainingPlanName", + "shape":"TrainingPlanNameOrArn", "documentation":"

The name of the training plan to describe.

" } } @@ -22731,6 +23475,26 @@ } } }, + "DescribeTrainingSessionRequest":{ + "type":"structure", + "required":["TrainingSessionName"], + "members":{ + "TrainingSessionName":{ + "shape":"TrainingSessionName", + "documentation":"

The name of the training session to describe.

" + } + } + }, + "DescribeTrainingSessionResponse":{ + "type":"structure", + "required":["TrainingSessionDetail"], + "members":{ + "TrainingSessionDetail":{ + "shape":"TrainingSessionDetail", + "documentation":"

The detailed information about the training session.

" + } + } + }, "DescribeTransformJobRequest":{ "type":"structure", "required":["TransformJobName"], @@ -23601,7 +24365,6 @@ }, "DomainId":{ "type":"string", - "documentation":"

Types duplicated from IronmanApiServiceModel for federation. These types are defined in other service directories and are not available via IronmanApiServiceCommonModel.

", "max":63, "min":0, "pattern":"d-(-*[a-z0-9]){1,61}" @@ -24357,6 +25120,10 @@ }, "EnableCaching":{"type":"boolean"}, "EnableCapture":{"type":"boolean"}, + "EnableDetailedObservability":{ + "type":"boolean", + "box":true + }, "EnableEnhancedMetrics":{ "type":"boolean", "box":true @@ -24918,6 +25685,14 @@ "Instance":{ "shape":"InstanceMetadata", "documentation":"

Metadata specific to instance-level events.

" + }, + "DatabaseConfiguration":{ + "shape":"DatabaseConfigurationMetadata", + "documentation":"

Metadata specific to events about the external Slurm accounting database of the cluster.

" + }, + "SlurmHealth":{ + "shape":"SlurmHealthMetadata", + "documentation":"

Metadata specific to events about the health of the Slurm components on the controller node of the cluster.

" } }, "documentation":"

Metadata associated with a cluster event, which may include details about various resource types.

", @@ -26284,6 +27059,107 @@ "min":0, "pattern":".*" }, + "HubContent":{ + "type":"structure", + "required":[ + "HubContentName", + "HubContentArn", + "HubContentVersion", + "HubContentType", + "DocumentSchemaVersion", + "HubName", + "HubArn", + "HubContentStatus", + "CreationTime" + ], + "members":{ + "HubContentName":{ + "shape":"HubContentName", + "documentation":"

The name of the hub content.

" + }, + "HubContentArn":{ + "shape":"HubContentArn", + "documentation":"

The Amazon Resource Name (ARN) of the hub content.

" + }, + "HubContentVersion":{ + "shape":"HubContentVersion", + "documentation":"

The version of the hub content.

" + }, + "HubContentType":{ + "shape":"HubContentType", + "documentation":"

The type of hub content.

" + }, + "DocumentSchemaVersion":{ + "shape":"DocumentSchemaVersion", + "documentation":"

The document schema version for the hub content.

" + }, + "HubName":{ + "shape":"HubName", + "documentation":"

The name of the hub that contains the content.

" + }, + "HubArn":{ + "shape":"HubArn", + "documentation":"

The Amazon Resource Name (ARN) of the hub that contains the content.

" + }, + "HubContentDisplayName":{ + "shape":"HubContentDisplayName", + "documentation":"

The display name of the hub content.

" + }, + "HubContentDescription":{ + "shape":"HubContentDescription", + "documentation":"

A description of the hub content.

" + }, + "HubContentMarkdown":{ + "shape":"HubContentMarkdown", + "documentation":"

A string that provides a description of the hub content. This string can include links, tables, and standard markdown formatting.

" + }, + "HubContentDocument":{ + "shape":"HubContentDocument", + "documentation":"

The hub content document that describes information about the hub content such as type, associated containers, scripts, and more.

" + }, + "SageMakerPublicHubContentArn":{ + "shape":"SageMakerPublicHubContentArn", + "documentation":"

The Amazon Resource Name (ARN) of the public hub content.

" + }, + "ReferenceMinVersion":{ + "shape":"ReferenceMinVersion", + "documentation":"

The minimum version of the hub content.

" + }, + "SupportStatus":{ + "shape":"HubContentSupportStatus", + "documentation":"

The support status of the hub content.

" + }, + "HubContentSearchKeywords":{ + "shape":"HubContentSearchKeywordList", + "documentation":"

The searchable keywords for the hub content.

" + }, + "HubContentDependencies":{ + "shape":"HubContentDependencyList", + "documentation":"

The location of any dependencies that the hub content has, such as scripts, model artifacts, datasets, or notebooks.

" + }, + "HubContentStatus":{ + "shape":"HubContentStatus", + "documentation":"

The status of the hub content.

" + }, + "FailureReason":{ + "shape":"FailureReason", + "documentation":"

The failure reason if importing hub content failed.

" + }, + "CreationTime":{ + "shape":"Timestamp", + "documentation":"

The date and time that hub content was created.

" + }, + "LastModifiedTime":{ + "shape":"Timestamp", + "documentation":"

The last modified time of the hub content.

" + }, + "Tags":{ + "shape":"TagList", + "documentation":"

Any tags associated with the hub content.

" + } + }, + "documentation":"

Contains information about a hub content resource, including its name, version, type, associated documents, dependencies, and status, as returned by a search result.

" + }, "HubContentArn":{ "type":"string", "max":255, @@ -27473,6 +28349,32 @@ }, "documentation":"

Use this parameter to specify a supported global condition key that is added to the IAM policy.

" }, + "IdcConfigInput":{ + "type":"structure", + "required":["InstanceArn"], + "members":{ + "InstanceArn":{ + "shape":"InstanceArn", + "documentation":"

The ARN of the Amazon Web Services IAM Identity Center instance that the SageMaker Partner AI App uses to authenticate users.

" + } + }, + "documentation":"

Specifies the Amazon Web Services IAM Identity Center configuration to use for a SageMaker Partner AI App that uses IDC authorization.

" + }, + "IdcConfigOutput":{ + "type":"structure", + "required":["InstanceArn"], + "members":{ + "InstanceArn":{ + "shape":"InstanceArn", + "documentation":"

The ARN of the Amazon Web Services IAM Identity Center instance that the SageMaker Partner AI App uses to authenticate users.

" + }, + "ApplicationArn":{ + "shape":"ApplicationArn", + "documentation":"

The ARN of the Amazon Web Services IAM Identity Center application that SageMaker creates for the SageMaker Partner AI App.

" + } + }, + "documentation":"

Contains the Amazon Web Services IAM Identity Center configuration of a SageMaker Partner AI App that uses IDC authorization.

" + }, "IdempotencyToken":{ "type":"string", "max":128, @@ -27672,6 +28574,12 @@ "min":0, "pattern":"[a-zA-Z0-9\\-.]+" }, + "ImageReleaseVersion":{ + "type":"string", + "max":64, + "min":0, + "pattern":"[0-9]+\\.[0-9]+\\.[0-9]+" + }, "ImageSortBy":{ "type":"string", "enum":[ @@ -27889,6 +28797,13 @@ "type":"boolean", "box":true }, + "IncludedData":{ + "type":"string", + "enum":[ + "AllData", + "MetadataOnly" + ] + }, "InferenceComponentArn":{ "type":"string", "max":2048, @@ -27971,6 +28886,10 @@ "Environment":{ "shape":"EnvironmentMap", "documentation":"

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.

" + }, + "ContainerMetricsConfig":{ + "shape":"ContainerMetricsConfig", + "documentation":"

The configuration for container metrics scraping. Specifies the metrics endpoint path and publishing frequency for the inference component's container. If not specified when EnableDetailedObservability is True, the default path /metrics on port 8080 is used. For first-party and Deep Learning Containers (DLC), the endpoint path is determined automatically and this configuration is optional.

" } }, "documentation":"

Defines a container that provides the runtime environment for a model that you deploy with an inference component.

" @@ -27986,6 +28905,10 @@ "Environment":{ "shape":"EnvironmentMap", "documentation":"

The environment variables to set in the Docker container.

" + }, + "ContainerMetricsConfig":{ + "shape":"ContainerMetricsConfig", + "documentation":"

The container metrics scraping configuration for this inference component, including the metrics endpoint path and publishing frequency.

" } }, "documentation":"

Details about the resources that are deployed with this inference component.

" @@ -28757,6 +29680,12 @@ "member":{"shape":"TrainingInputMode"}, "min":1 }, + "InstanceArn":{ + "type":"string", + "max":128, + "min":1, + "pattern":"arn:aws[a-z\\-]*:sso:::instance/(sso)?ins-[a-zA-Z0-9.-]{16}" + }, "InstanceCount":{ "type":"integer", "box":true, @@ -28787,33 +29716,6 @@ }, "documentation":"

Defines an instance group for heterogeneous cluster training. When requesting a training job using the CreateTrainingJob API, you can configure multiple instance groups .

" }, - "InstancePreference":{ - "type":"structure", - "required":["InstanceType"], - "members":{ - "InstanceType":{ - "shape":"TrainingInstanceType", - "documentation":"

The ML compute instance type for this candidate.

" - }, - "InstanceCount":{ - "shape":"TrainingInstanceCount", - "documentation":"

The number of ML compute instances to use for this candidate. Optional; mutually exclusive with the uniform ResourceConfig.InstanceCount (either every preference sets its own count, or the uniform count is used for whichever type wins).

", - "box":true - }, - "TrainingPlanArns":{ - "shape":"TrainingPlanArnList", - "documentation":"

The training plan(s) to target for this candidate type. Optional; list is capped at 1. Training-only; mutually exclusive with the whole-job ResourceConfig.TrainingPlanArn.

" - } - }, - "documentation":"

Defines a single candidate instance type in an ordered InstancePreferences list. When a training job specifies InstancePreferences, the platform tries each candidate type in list order and launches the job on the first type with available capacity.

" - }, - "InstancePreferenceList":{ - "type":"list", - "member":{"shape":"InstancePreference"}, - "documentation":"

An ordered list of candidate instance types for a training job (array position is the priority). Currently limited to a minimum of 1 and a maximum of 5 entries; the limit is enforced by the service.

", - "max":5, - "min":1 - }, "InstanceGroupHealthCheckConfiguration":{ "type":"structure", "required":[ @@ -29046,6 +29948,33 @@ "member":{"shape":"InstancePoolSummary"}, "min":1 }, + "InstancePreference":{ + "type":"structure", + "required":["InstanceType"], + "members":{ + "InstanceType":{ + "shape":"TrainingInstanceType", + "documentation":"

The ML compute instance type. An instance type can appear only once in an InstancePreferences list.

" + }, + "InstanceCount":{ + "shape":"TrainingInstanceCount", + "documentation":"

The number of instances to launch if this instance type is selected. Specify the instance count for the training job in one of the following two ways:

  1. Per preference – Set InstanceCount on every preference in the InstancePreferences list and don't set ResourceConfig$InstanceCount. Use this when each instance type needs a different number of instances to deliver equivalent compute.

  2. One count for the job – Set ResourceConfig$InstanceCount and omit it from every preference. SageMaker applies this to all instance types in the list.

For example, in a list of five preferences, either all five specify InstanceCount or none of them do. SageMaker rejects requests that set InstanceCount on only some preferences, that set it both per preference and in ResourceConfig, or that omit it in both places.

", + "box":true + }, + "TrainingPlanArns":{ + "shape":"TrainingPlanArnList", + "documentation":"

The Amazon Resource Name (ARN) of a training plan to use if this instance type is selected. The plan's instance type must match InstanceType. A preference with a training plan uses that plan's reserved capacity; a preference without one uses on-demand capacity. Per-preference TrainingPlanArns is mutually exclusive with the job-level TrainingPlanArn in ResourceConfig.

" + } + }, + "documentation":"

A candidate instance type preference in an InstancePreferences list.

" + }, + "InstancePreferenceList":{ + "type":"list", + "member":{"shape":"InstancePreference"}, + "documentation":"

Ordered list of candidate instance types, in priority order.

", + "max":5, + "min":1 + }, "InstanceRequirementsEniConfiguration":{ "type":"structure", "members":{ @@ -29240,8 +30169,22 @@ "ml.g6.16xlarge", "ml.g6.24xlarge", "ml.g6.48xlarge", + "ml.g7e.2xlarge", + "ml.g7e.4xlarge", + "ml.g7e.8xlarge", + "ml.g7e.12xlarge", + "ml.g7e.24xlarge", + "ml.g7e.48xlarge", "ml.p5.4xlarge", - "ml.p5en.48xlarge" + "ml.p5en.48xlarge", + "ml.g6e.xlarge", + "ml.g6e.2xlarge", + "ml.g6e.4xlarge", + "ml.g6e.8xlarge", + "ml.g6e.12xlarge", + "ml.g6e.16xlarge", + "ml.g6e.24xlarge", + "ml.g6e.48xlarge" ] }, "Integer":{"type":"integer"}, @@ -29326,6 +30269,80 @@ "max":256, "min":1 }, + "JavaBoolean":{ + "type":"boolean", + "box":true + }, + "JavaInteger":{ + "type":"integer", + "box":true + }, + "JavaLong":{ + "type":"long", + "box":true + }, + "Job":{ + "type":"structure", + "members":{ + "JobName":{ + "shape":"JobName", + "documentation":"

The name of the job.

" + }, + "JobArn":{ + "shape":"JobArn", + "documentation":"

The Amazon Resource Name (ARN) of the job.

" + }, + "RoleArn":{ + "shape":"RoleArn", + "documentation":"

The ARN of the IAM role associated with the job.

" + }, + "JobCategory":{ + "shape":"JobCategory", + "documentation":"

The category of the job.

" + }, + "JobConfigSchemaVersion":{ + "shape":"JobSchemaVersion", + "documentation":"

The schema version used for the job configuration document.

" + }, + "JobConfigDocument":{ + "shape":"JobConfigDocument", + "documentation":"

The JSON configuration document for the job.

" + }, + "CreationTime":{ + "shape":"Timestamp", + "documentation":"

The date and time that the job was created.

" + }, + "LastModifiedTime":{ + "shape":"Timestamp", + "documentation":"

The date and time that the job was last modified.

" + }, + "EndTime":{ + "shape":"Timestamp", + "documentation":"

The date and time that the job ended.

" + }, + "JobStatus":{ + "shape":"JobStatus", + "documentation":"

The current status of the job.

" + }, + "SecondaryStatus":{ + "shape":"JobSecondaryStatus", + "documentation":"

The detailed secondary status of the job, providing more granular information about the job's progress.

" + }, + "SecondaryStatusTransitions":{ + "shape":"JobSecondaryStatusTransitions", + "documentation":"

A list of secondary status transitions for the job, with timestamps and optional status messages.

" + }, + "FailureReason":{ + "shape":"FailureReason", + "documentation":"

If the job failed, the reason it failed.

" + }, + "Tags":{ + "shape":"TagList", + "documentation":"

The tags associated with the job.

" + } + }, + "documentation":"

The properties of a job returned by the Search API.

" + }, "JobArn":{ "type":"string", "max":256, @@ -34503,6 +35520,48 @@ } } }, + "ListTrainingSessionsRequest":{ + "type":"structure", + "members":{ + "NextToken":{ + "shape":"NextToken", + "documentation":"

If the response was truncated, use the token returned in the previous response to retrieve the next page of results.

" + }, + "MaxResults":{ + "shape":"MaxResults", + "documentation":"

The maximum number of training sessions to return in the response.

" + }, + "CreationTimeAfter":{ + "shape":"Timestamp", + "documentation":"

A filter that returns only training sessions created after the specified time.

" + }, + "CreationTimeBefore":{ + "shape":"Timestamp", + "documentation":"

A filter that returns only training sessions created before the specified time.

" + }, + "NameContains":{ + "shape":"NameContains", + "documentation":"

A string in the training session name to filter results. Only sessions whose name contains the specified string are returned.

" + }, + "StatusEquals":{ + "shape":"TrainingSessionStatus", + "documentation":"

A filter that returns only training sessions with the specified status.

" + } + } + }, + "ListTrainingSessionsResponse":{ + "type":"structure", + "members":{ + "NextToken":{ + "shape":"NextToken", + "documentation":"

If the response is truncated, this token retrieves the next set of results.

" + }, + "TrainingSessionSummaries":{ + "shape":"TrainingSessionSummaries", + "documentation":"

An array of TrainingSessionSummary objects that provide summary information about the training sessions.

" + } + } + }, "ListTransformJobsRequest":{ "type":"structure", "members":{ @@ -34849,6 +35908,29 @@ "min":0, "pattern":"(https|s3)://([^/]+)/?(.*)" }, + "LoraAlpha":{ + "type":"integer", + "box":true, + "min":1 + }, + "LoraConfig":{ + "type":"structure", + "required":[ + "Rank", + "Alpha" + ], + "members":{ + "Rank":{ + "shape":"Rank", + "documentation":"

The rank of the Low-Rank Adaptation (LoRA) adapter matrices.

" + }, + "Alpha":{ + "shape":"LoraAlpha", + "documentation":"

The Low-Rank Adaptation (LoRA) scaling factor.

" + } + }, + "documentation":"

The Low-Rank Adaptation (LoRA) configuration for a training session, including the rank and alpha parameters.

" + }, "MIGProfileType":{ "type":"string", "enum":[ @@ -35273,13 +36355,46 @@ "shape":"EnableEnhancedMetrics", "documentation":"

Specifies whether to enable enhanced metrics for the endpoint. Enhanced metrics provide utilization and invocation data at instance and container granularity. Container granularity is supported for Inference Components. The default is False.

" }, + "EnableDetailedObservability":{ + "shape":"EnableDetailedObservability", + "documentation":"

Indicates whether detailed observability is enabled for the endpoint. When set to True, the following metrics are published at the configured frequency:

For first-party and Deep Learning Containers (DLC), the Prometheus endpoint path is determined automatically. For Bring-Your-Own-Container (BYOC) cases, you can optionally set ContainerMetricsConfig to specify a custom endpoint path. If not specified, the default path /metrics on port 8080 is used.

When set to False, these additional metrics are not published. Standard invocation and utilization metrics controlled by EnableEnhancedMetrics are unaffected.

The default value for new endpoint configurations is True. For existing endpoint configurations created before this feature, the value is False unless explicitly set.

" + }, "MetricPublishFrequencyInSeconds":{ "shape":"MetricPublishFrequencyInSeconds", - "documentation":"

The interval, in seconds, at which metrics are published to Amazon CloudWatch. Defaults to 60. Valid values: 10, 30, 60, 120, 180, 240, 300. When EnableEnhancedMetrics is set to False, this interval applies to utilization metrics only; invocation metrics continue to be published at the default 60-second interval. When EnableEnhancedMetrics is set to True, this interval applies to both utilization and invocation metrics.

" + "documentation":"

The interval, in seconds, at which metrics are published to Amazon CloudWatch. Defaults to 60. Valid values: 10, 30, 60, 120, 180, 240, 300.

When EnableEnhancedMetrics is set to False, this interval applies to utilization metrics only. Invocation metrics continue to be published at the default 60-second interval. When EnableEnhancedMetrics is set to True, this interval applies to both utilization and invocation metrics.

When EnableDetailedObservability is set to True, this interval applies to per-GPU metrics, per-instance host metrics, container metrics, and fleet-level inference component lifecycle and placement metrics.

" } }, "documentation":"

The configuration for Utilization metrics.

" }, + "MetricsEndpoint":{ + "type":"structure", + "required":["MetricsEndpointPath"], + "members":{ + "MetricsEndpointPath":{ + "shape":"MetricsEndpointPath", + "documentation":"

The path to the metrics endpoint exposed by the container. For example, /metrics or /server/metrics. The path must start with / and can contain alphanumeric characters, forward slashes, underscores, hyphens, and periods. Maximum length is 256 characters. If not specified, defaults to /metrics.

" + }, + "MetricPublishFrequencyInSeconds":{ + "shape":"MetricPublishFrequencyInSeconds", + "documentation":"

The interval, in seconds, at which container metrics scraped from the endpoint are published to Amazon CloudWatch. Valid values: 10, 30, 60, 120, 180, 240, 300. Defaults to 60.

" + } + }, + "documentation":"

Specifies a metrics endpoint for a container, including the path where the container exposes Prometheus-formatted metrics and the frequency at which to publish them to Amazon CloudWatch.

" + }, + "MetricsEndpointList":{ + "type":"list", + "member":{"shape":"MetricsEndpoint"}, + "documentation":"

A list of metrics endpoints for a container.

", + "max":1, + "min":0 + }, + "MetricsEndpointPath":{ + "type":"string", + "documentation":"

Per-container Prometheus metrics scraping configuration

", + "max":256, + "min":0, + "pattern":"/(?!.*\\.\\.)[a-zA-Z0-9/_.\\-]+" + }, "MetricsSource":{ "type":"structure", "required":[ @@ -38340,7 +39455,9 @@ "Stopped", "Failed", "Deleting", - "Updating" + "Updating", + "PendingMaintenance", + "InMaintenance" ] }, "NotebookInstanceSummary":{ @@ -38643,7 +39760,7 @@ "OnStartDeepHealthChecks":{ "type":"list", "member":{"shape":"DeepHealthCheckType"}, - "max":2, + "max":3, "min":1 }, "OnlineStoreConfig":{ @@ -38664,7 +39781,7 @@ }, "StorageType":{ "shape":"StorageType", - "documentation":"

Option for different tiers of low latency storage for real-time data retrieval.

" + "documentation":"

Option for different tiers of low latency storage for real-time data retrieval.

" } }, "documentation":"

Use this to specify the Amazon Web Services Key Management Service (KMS) Key ID, or KMSKeyId, for at rest data encryption. You can turn OnlineStore on or off by specifying the EnableOnlineStore flag at General Assembly.

The default value is False.

" @@ -38797,7 +39914,20 @@ "ml.inf2.48xlarge", "ml.trn1.2xlarge", "ml.trn1.32xlarge", - "ml.trn1n.32xlarge" + "ml.trn1n.32xlarge", + "ml.p6-b200.48xlarge", + "ml.g7e.2xlarge", + "ml.g7e.4xlarge", + "ml.g7e.8xlarge", + "ml.g7e.12xlarge", + "ml.g7e.24xlarge", + "ml.g7e.48xlarge", + "ml.g7.2xlarge", + "ml.g7.4xlarge", + "ml.g7.8xlarge", + "ml.g7.12xlarge", + "ml.g7.24xlarge", + "ml.g7.48xlarge" ] }, "OptimizationJobEnvironmentVariables":{ @@ -38928,6 +40058,13 @@ }, "documentation":"

Summarizes an optimization job by providing some of its key properties.

" }, + "OptimizationJobTrainingPlanArns":{ + "type":"list", + "member":{"shape":"TrainingPlanArn"}, + "documentation":"

Amazon Resource Names (ARNs) of the training plans whose reserved capacity backs the optimization job. Bounded to a single plan for now; the list shape allows widening to multiple plans in the future without a breaking scalar-to-list change.

", + "max":1, + "min":0 + }, "OptimizationModelAcceptEula":{"type":"boolean"}, "OptimizationModelAccessConfig":{ "type":"structure", @@ -39104,6 +40241,12 @@ "max":50, "min":0 }, + "OutputS3Path":{ + "type":"string", + "max":1024, + "min":1, + "pattern":"(https|s3)://([^/]+)/?(.*)" + }, "OwnershipSettings":{ "type":"structure", "required":["OwnerUserProfileName"], @@ -39295,7 +40438,10 @@ }, "PartnerAppAuthType":{ "type":"string", - "enum":["IAM"] + "enum":[ + "IAM", + "IDC" + ] }, "PartnerAppConfig":{ "type":"structure", @@ -40117,6 +41263,32 @@ "LowerPriority" ] }, + "PrefixAwareRoutingConcurrencyThreshold":{ + "type":"integer", + "box":true, + "max":1024, + "min":1 + }, + "PrefixAwareRoutingConfig":{ + "type":"structure", + "members":{ + "PrefixLength":{ + "shape":"PrefixAwareRoutingPrefixLength", + "documentation":"

The maximum length of the prefix used for routing decisions. Required when RoutingStrategy is PREFIX_AWARE.

The endpoint routes requests that share the same prefix to the same instance. Set this value to cover shared content (such as system prompts) plus enough unique content to distribute workloads across instances.

" + }, + "ConcurrencyThreshold":{ + "shape":"PrefixAwareRoutingConcurrencyThreshold", + "documentation":"

The maximum number of in-flight requests on the target instance before the endpoint routes to another instance. Required when RoutingStrategy is PREFIX_AWARE. When in-flight requests on the prefix-selected instance reach this threshold, the endpoint routes the request to an instance with more available capacity.

" + } + }, + "documentation":"

The configuration for prefix-aware routing on a SageMaker real-time inference endpoint. Specify PrefixLength and ConcurrencyThreshold to control routing behavior.

" + }, + "PrefixAwareRoutingPrefixLength":{ + "type":"integer", + "box":true, + "max":65536, + "min":1024 + }, "PresignedDomainUrl":{"type":"string"}, "PresignedUrlAccessConfig":{ "type":"structure", @@ -40177,9 +41349,7 @@ }, "ProcessingClusterConfig":{ "type":"structure", - "required":[ - "VolumeSizeInGB" - ], + "required":["VolumeSizeInGB"], "members":{ "InstanceCount":{ "shape":"ProcessingInstanceCount", @@ -40199,15 +41369,15 @@ }, "InstancePreferences":{ "shape":"ProcessingInstancePreferenceList", - "documentation":"

An ordered list of candidate instance types (maximum 5). When set, the platform tries each candidate in list order and launches the job on the first type with available capacity. Mutually exclusive with InstanceType and InstanceCount.

" + "documentation":"

An ordered list of ML compute instance types for the processing job, in priority order. Amazon SageMaker launches the job on the first instance type in the list that has available capacity. If capacity is insufficient, Amazon SageMaker evaluates the next instance type in the list. Exactly one instance type is selected for the job.

InstancePreferences is mutually exclusive with InstanceType.

" }, "SelectedInstanceType":{ "shape":"ProcessingInstanceType", - "documentation":"

The instance type the job was launched on when InstancePreferences is used. Output-only (returned in DescribeProcessingJob); ignored on CreateProcessingJob.

" + "documentation":"

The instance type that Amazon SageMaker selected for the job from InstancePreferences. Returned by DescribeProcessingJob after an instance type is selected. This field is read-only and isn't accepted in CreateProcessingJob requests.

" }, "SelectedInstanceCount":{ "shape":"ProcessingInstanceCount", - "documentation":"

The resolved number of instances the job was launched with when InstancePreferences is used. Output-only (returned in DescribeProcessingJob); ignored on CreateProcessingJob.

" + "documentation":"

The number of instances of SelectedInstanceType that the job launched with. The job is billed for this instance type and count. Returned by DescribeProcessingJob after an instance type is selected. This field is read-only and isn't accepted in CreateProcessingJob requests.

" } }, "documentation":"

Configuration for the cluster used to run a processing job.

" @@ -40284,19 +41454,19 @@ "members":{ "InstanceType":{ "shape":"ProcessingInstanceType", - "documentation":"

The ML compute instance type for this candidate.

" + "documentation":"

The ML compute instance type. An instance type can appear only once in an InstancePreferences list.

" }, "InstanceCount":{ "shape":"ProcessingInstanceCount", - "documentation":"

The number of ML compute instances to use for this candidate. Optional; mutually exclusive with the uniform ProcessingClusterConfig.InstanceCount (either every preference sets its own count, or the uniform count is used for whichever type wins).

" + "documentation":"

The number of instances to launch if this instance type is selected. Specify the instance count for the processing job in one of the following two ways:

  1. Per preference – Set InstanceCount on every preference in the InstancePreferences list and don't set ProcessingClusterConfig$InstanceCount. Use this when each instance type needs a different number of instances to deliver equivalent compute.

  2. One count for the job – Set ProcessingClusterConfig$InstanceCount and omit it from every preference. Amazon SageMaker applies this to all instance types in the list.

For example, in a list of five preferences, either all five specify InstanceCount or none of them do. Amazon SageMaker rejects requests that set InstanceCount on only some preferences, that set it both per preference and in ProcessingClusterConfig, or that omit it in both places.

" } }, - "documentation":"

Defines a single candidate instance type in an ordered InstancePreferences list for a processing job. InstanceType is required; InstanceCount is optional per element. Per-type training plans are training-only and do not apply to processing.

" + "documentation":"

A candidate instance type preference in a processing InstancePreferences list.

" }, "ProcessingInstancePreferenceList":{ "type":"list", "member":{"shape":"ProcessingInstancePreference"}, - "documentation":"

An ordered list of candidate instance types for a processing job (array position is the priority). Currently limited to a minimum of 1 and a maximum of 5 entries; the limit is enforced by the service.

", + "documentation":"

Ordered list of candidate instance types, in priority order.

", "max":5, "min":1 }, @@ -40429,7 +41599,87 @@ "ml.g7e.8xlarge", "ml.g7e.12xlarge", "ml.g7e.24xlarge", - "ml.g7e.48xlarge" + "ml.g7e.48xlarge", + "ml.g7.2xlarge", + "ml.g7.4xlarge", + "ml.g7.8xlarge", + "ml.g7.12xlarge", + "ml.g7.24xlarge", + "ml.g7.48xlarge", + "ml.r6i.large", + "ml.r6i.xlarge", + "ml.r6i.2xlarge", + "ml.r6i.4xlarge", + "ml.r6i.8xlarge", + "ml.r6i.12xlarge", + "ml.r6i.16xlarge", + "ml.r6i.24xlarge", + "ml.r6i.32xlarge", + "ml.m8i.large", + "ml.m8i.xlarge", + "ml.m8i.2xlarge", + "ml.m8i.4xlarge", + "ml.m8i.8xlarge", + "ml.m8i.12xlarge", + "ml.m8i.16xlarge", + "ml.m8i.24xlarge", + "ml.m8i.32xlarge", + "ml.m8i.48xlarge", + "ml.m8i.96xlarge", + "ml.c8i.xlarge", + "ml.c8i.2xlarge", + "ml.c8i.4xlarge", + "ml.c8i.8xlarge", + "ml.c8i.12xlarge", + "ml.c8i.16xlarge", + "ml.c8i.24xlarge", + "ml.c8i.32xlarge", + "ml.c8i.48xlarge", + "ml.c8i.96xlarge", + "ml.r8i.large", + "ml.r8i.xlarge", + "ml.r8i.2xlarge", + "ml.r8i.4xlarge", + "ml.r8i.8xlarge", + "ml.r8i.12xlarge", + "ml.r8i.16xlarge", + "ml.r8i.24xlarge", + "ml.r8i.32xlarge", + "ml.r8i.48xlarge", + "ml.r8i.96xlarge", + "ml.m7i-flex.large", + "ml.m7i-flex.xlarge", + "ml.m7i-flex.2xlarge", + "ml.m7i-flex.4xlarge", + "ml.m7i-flex.8xlarge", + "ml.m7i-flex.12xlarge", + "ml.m7i-flex.16xlarge", + "ml.c7i-flex.xlarge", + "ml.c7i-flex.2xlarge", + "ml.c7i-flex.4xlarge", + "ml.c7i-flex.8xlarge", + "ml.c7i-flex.12xlarge", + "ml.c7i-flex.16xlarge", + "ml.m8i-flex.large", + "ml.m8i-flex.xlarge", + "ml.m8i-flex.2xlarge", + "ml.m8i-flex.4xlarge", + "ml.m8i-flex.8xlarge", + "ml.m8i-flex.12xlarge", + "ml.m8i-flex.16xlarge", + "ml.c8i-flex.xlarge", + "ml.c8i-flex.2xlarge", + "ml.c8i-flex.4xlarge", + "ml.c8i-flex.8xlarge", + "ml.c8i-flex.12xlarge", + "ml.c8i-flex.16xlarge", + "ml.r8i-flex.large", + "ml.r8i-flex.xlarge", + "ml.r8i-flex.2xlarge", + "ml.r8i-flex.4xlarge", + "ml.r8i-flex.8xlarge", + "ml.r8i-flex.12xlarge", + "ml.r8i-flex.16xlarge" ] }, "ProcessingJob":{ @@ -41083,6 +42333,12 @@ "ml.g7e.12xlarge", "ml.g7e.24xlarge", "ml.g7e.48xlarge", + "ml.g7.2xlarge", + "ml.g7.4xlarge", + "ml.g7.8xlarge", + "ml.g7.12xlarge", + "ml.g7.24xlarge", + "ml.g7.48xlarge", "ml.p4d.24xlarge", "ml.c7g.large", "ml.c7g.xlarge", @@ -41281,7 +42537,11 @@ "members":{ "RoutingStrategy":{ "shape":"RoutingStrategy", - "documentation":"

Sets how the endpoint routes incoming traffic:

" + "documentation":"

Sets how the endpoint routes incoming traffic:

" + }, + "PrefixAwareRoutingConfig":{ + "shape":"PrefixAwareRoutingConfig", + "documentation":"

The configuration for prefix-aware routing. Specify this parameter only when you set RoutingStrategy to PREFIX_AWARE.

" } }, "documentation":"

Settings that control how the endpoint routes incoming traffic to the instances that the endpoint hosts.

" @@ -42063,6 +43323,12 @@ "box":true, "min":0 }, + "Rank":{ + "type":"integer", + "box":true, + "max":256, + "min":1 + }, "RealTimeInferenceConfig":{ "type":"structure", "required":[ @@ -43064,15 +44330,15 @@ }, "InstancePreferences":{ "shape":"InstancePreferenceList", - "documentation":"

An ordered list of candidate instance types (maximum 5). When set, the platform tries each candidate in list order and launches the job on the first type with available capacity. Mutually exclusive with InstanceType, InstanceGroups, and InstancePlacementConfig.

" + "documentation":"

An ordered list of ML compute instance types for the training job, in priority order. SageMaker launches the training job on the first instance type in the list that has available capacity. If capacity is insufficient, SageMaker evaluates the next instance type in the preferred list. Exactly one instance type is selected for the job.

InstancePreferences is mutually exclusive with InstanceType, InstanceGroups, InstancePlacementConfig, and EnableManagedSpotTraining, and supports only Flexible Training Plans (FTP) and On-Demand capacity.

" }, "SelectedInstanceType":{ "shape":"TrainingInstanceType", - "documentation":"

The instance type the job was launched on when InstancePreferences is used. Output-only (returned in DescribeTrainingJob); ignored on CreateTrainingJob.

" + "documentation":"

The instance type that SageMaker selected for the job from the provided InstancePreferences. The job is billed for this instance type and count. Returned by DescribeTrainingJob after an instance type is selected. This field is read-only and isn't accepted in CreateTrainingJob requests.

" }, "SelectedInstanceCount":{ "shape":"TrainingInstanceCount", - "documentation":"

The resolved number of instances the job was launched with when InstancePreferences is used. Output-only (returned in DescribeTrainingJob); ignored on CreateTrainingJob.

", + "documentation":"

The number of instances of SelectedInstanceType that the training job launched with. The job is billed for this instance type and count. Returned by DescribeTrainingJob after an instance type is selected. This field is read-only and isn't accepted in CreateTrainingJob requests.

", "box":true } }, @@ -43239,7 +44505,9 @@ "Project", "HyperParameterTuningJob", "ModelCard", - "PipelineVersion" + "PipelineVersion", + "Job", + "HubContent" ] }, "ResponseMIMEType":{ @@ -43394,7 +44662,8 @@ "type":"string", "enum":[ "LEAST_OUTSTANDING_REQUESTS", - "RANDOM" + "RANDOM", + "PREFIX_AWARE" ] }, "RuleConfigurationName":{ @@ -43871,7 +45140,15 @@ "shape":"ModelCard", "documentation":"

An Amazon SageMaker Model Card that documents details about a machine learning model.

" }, - "Model":{"shape":"ModelDashboardModel"} + "Model":{"shape":"ModelDashboardModel"}, + "Job":{ + "shape":"Job", + "documentation":"

The properties of a job.

" + }, + "HubContent":{ + "shape":"HubContent", + "documentation":"

The properties of a hub content resource.

" + } }, "documentation":"

A single resource returned as part of the Search API response.

" }, @@ -44166,6 +45443,12 @@ } } }, + "SequenceLength":{ + "type":"string", + "max":50, + "min":1, + "pattern":"\\d+K" + }, "ServerlessJobBaseModelArn":{ "type":"string", "documentation":"

ServerlessJobConfig relevant fields

", @@ -44211,7 +45494,7 @@ }, "SequenceLength":{ "shape":"SequenceLength", - "documentation":"

The sequence length for the training job.

" + "documentation":"

The maximum sequence length, in tokens, that the customization job supports. SageMaker uses this value to select a training configuration for the base model that you specify. The parameter supports the following values:

If you don't specify a value, SageMaker selects a training configuration based on the other values that you specify. The selection is not restricted to a particular sequence length.

" } }, "documentation":"

The configuration for the serverless training job.

" @@ -44223,19 +45506,6 @@ "Evaluation" ] }, - "SequenceLength":{ - "type":"string", - "enum":[ - "1K", - "2K", - "4K", - "8K", - "16K", - "32K", - "64K", - "128K" - ] - }, "ServerlessMaxConcurrency":{ "type":"integer", "box":true, @@ -44427,6 +45697,47 @@ "None" ] }, + "SlurmHealthComponent":{ + "type":"string", + "enum":["Slurmdbd"] + }, + "SlurmHealthMetadata":{ + "type":"structure", + "required":[ + "Component", + "Status" + ], + "members":{ + "Component":{ + "shape":"SlurmHealthComponent", + "documentation":"

The Slurm component that the health information describes. The valid value is Slurmdbd, the Slurm accounting daemon.

" + }, + "Status":{ + "shape":"SlurmHealthStatus", + "documentation":"

The health of the component. Valid values are Healthy and Unhealthy.

" + }, + "Reason":{ + "shape":"SlurmHealthReason", + "documentation":"

The reason the component is unhealthy. Valid values:

This field is omitted when the component is healthy.

" + } + }, + "documentation":"

Metadata information about the health of a Slurm component on the controller node of a HyperPod cluster.

" + }, + "SlurmHealthReason":{ + "type":"string", + "enum":[ + "DaemonDown", + "DaemonDisabled", + "DbUnreachable" + ] + }, + "SlurmHealthStatus":{ + "type":"string", + "enum":[ + "Healthy", + "Unhealthy" + ] + }, "SnsTopicArn":{ "type":"string", "max":2048, @@ -45411,6 +46722,20 @@ } } }, + "StopTrainingSessionRequest":{ + "type":"structure", + "required":["TrainingSessionName"], + "members":{ + "TrainingSessionName":{ + "shape":"TrainingSessionName", + "documentation":"

The name of the training session to stop.

" + } + } + }, + "StopTrainingSessionResponse":{ + "type":"structure", + "members":{} + }, "StopTransformJobRequest":{ "type":"structure", "required":["TransformJobName"], @@ -45435,7 +46760,7 @@ }, "MaxPendingTimeInSeconds":{ "shape":"MaxPendingTimeInSeconds", - "documentation":"

The maximum length of time, in seconds, that a training or compilation job can be pending before it is stopped.

When working with training jobs that use capacity from training plans, not all Pending job states count against the MaxPendingTimeInSeconds limit. The following scenarios do not increment the MaxPendingTimeInSeconds counter:

MaxPendingTimeInSeconds only increments when jobs are actively waiting for capacity in an Active plan.

" + "documentation":"

The maximum length of time, in seconds, that a training or compilation job can be pending before it is stopped.

When working with training jobs that use capacity from training plans, not all Pending job states count against the MaxPendingTimeInSeconds limit. The following scenarios do not increment the MaxPendingTimeInSeconds counter:

MaxPendingTimeInSeconds only increments when jobs are actively waiting for capacity in an Active plan.

" } }, "documentation":"

Specifies a limit to how long a job can run. When the job reaches the time limit, SageMaker ends the job. Use this API to cap costs.

To stop a training job, SageMaker sends the algorithm the SIGTERM signal, which delays job termination for 120 seconds. Algorithms can use this 120-second window to save the model artifacts, so the results of training are not lost.

The training algorithms provided by SageMaker automatically save the intermediate results of a model training job when possible. This attempt to save artifacts is only a best effort case as model might not be in a state from which it can be saved. For example, if training has just started, the model might not be ready to save. When saved, this intermediate data is a valid model artifact. You can use it to create a model with CreateModel.

The Neural Topic Model (NTM) currently does not support saving intermediate model artifacts. When training NTMs, make sure that the maximum runtime is sufficient for the training job to complete.

" @@ -46666,7 +47991,87 @@ "ml.g7e.8xlarge", "ml.g7e.12xlarge", "ml.g7e.24xlarge", - "ml.g7e.48xlarge" + "ml.g7e.48xlarge", + "ml.g7.2xlarge", + "ml.g7.4xlarge", + "ml.g7.8xlarge", + "ml.g7.12xlarge", + "ml.g7.24xlarge", + "ml.g7.48xlarge", + "ml.r6i.large", + "ml.r6i.xlarge", + "ml.r6i.2xlarge", + "ml.r6i.4xlarge", + "ml.r6i.8xlarge", + "ml.r6i.12xlarge", + "ml.r6i.16xlarge", + "ml.r6i.24xlarge", + "ml.r6i.32xlarge", + "ml.m8i.large", + "ml.m8i.xlarge", + "ml.m8i.2xlarge", + "ml.m8i.4xlarge", + "ml.m8i.8xlarge", + "ml.m8i.12xlarge", + "ml.m8i.16xlarge", + "ml.m8i.24xlarge", + "ml.m8i.32xlarge", + "ml.m8i.48xlarge", + "ml.m8i.96xlarge", + "ml.c8i.xlarge", + "ml.c8i.2xlarge", + "ml.c8i.4xlarge", + "ml.c8i.8xlarge", + "ml.c8i.12xlarge", + "ml.c8i.16xlarge", + "ml.c8i.24xlarge", + "ml.c8i.32xlarge", + "ml.c8i.48xlarge", + "ml.c8i.96xlarge", + "ml.r8i.large", + "ml.r8i.xlarge", + "ml.r8i.2xlarge", + "ml.r8i.4xlarge", + "ml.r8i.8xlarge", + "ml.r8i.12xlarge", + "ml.r8i.16xlarge", + "ml.r8i.24xlarge", + "ml.r8i.32xlarge", + "ml.r8i.48xlarge", + "ml.r8i.96xlarge", + "ml.m7i-flex.large", + "ml.m7i-flex.xlarge", + "ml.m7i-flex.2xlarge", + "ml.m7i-flex.4xlarge", + "ml.m7i-flex.8xlarge", + "ml.m7i-flex.12xlarge", + "ml.m7i-flex.16xlarge", + "ml.c7i-flex.xlarge", + "ml.c7i-flex.2xlarge", + "ml.c7i-flex.4xlarge", + "ml.c7i-flex.8xlarge", + "ml.c7i-flex.12xlarge", + "ml.c7i-flex.16xlarge", + "ml.m8i-flex.large", + "ml.m8i-flex.xlarge", + "ml.m8i-flex.2xlarge", + "ml.m8i-flex.4xlarge", + "ml.m8i-flex.8xlarge", + "ml.m8i-flex.12xlarge", + "ml.m8i-flex.16xlarge", + "ml.c8i-flex.xlarge", + "ml.c8i-flex.2xlarge", + "ml.c8i-flex.4xlarge", + "ml.c8i-flex.8xlarge", + "ml.c8i-flex.12xlarge", + "ml.c8i-flex.16xlarge", + "ml.r8i-flex.large", + "ml.r8i-flex.xlarge", + "ml.r8i-flex.2xlarge", + "ml.r8i-flex.4xlarge", + "ml.r8i-flex.8xlarge", + "ml.r8i-flex.12xlarge", + "ml.r8i-flex.16xlarge" ] }, "TrainingInstanceTypes":{ @@ -47007,17 +48412,17 @@ "min":50, "pattern":"arn:aws[a-z\\-]*:sagemaker:[a-z0-9\\-]*:[0-9]{12}:training-plan/.*" }, - "TrainingPlanArns":{ - "type":"list", - "member":{"shape":"TrainingPlanArn"} - }, "TrainingPlanArnList":{ "type":"list", "member":{"shape":"TrainingPlanArn"}, - "documentation":"

The training plan(s) targeted by a single instance preference. Currently limited to exactly 1 training plan per preference; the limit is enforced by the service.

", + "documentation":"

Training plan ARNs for a single instance preference.

", "max":1, "min":1 }, + "TrainingPlanArns":{ + "type":"list", + "member":{"shape":"TrainingPlanArn"} + }, "TrainingPlanDurationHours":{ "type":"long", "box":true, @@ -47173,6 +48578,13 @@ "min":1, "pattern":"[a-zA-Z0-9](-*[a-zA-Z0-9]){0,63}" }, + "TrainingPlanNameOrArn":{ + "type":"string", + "documentation":"

A training plan name, or the ARN of a training plan.

", + "max":2048, + "min":1, + "pattern":"(arn:aws[a-z\\-]*:sagemaker:[a-z0-9\\-]*:[0-9]{12}:training-plan/)?[a-zA-Z0-9](-*[a-zA-Z0-9]){0,63}" + }, "TrainingPlanOffering":{ "type":"structure", "required":[ @@ -47385,6 +48797,184 @@ "min":1, "pattern":"arn:[\\p{Alnum}\\-]+:lambda:[\\p{Alnum}\\-]+:[0-9]{12}:function:.*" }, + "TrainingSessionArn":{ + "type":"string", + "max":256, + "min":0, + "pattern":"arn:(aws[a-z\\-]*):sagemaker:[a-z0-9\\-]+:[0-9]{12}:training-session/[a-zA-Z0-9](-*[a-zA-Z0-9]){0,62}" + }, + "TrainingSessionDetail":{ + "type":"structure", + "required":[ + "TrainingSessionArn", + "TrainingSessionName", + "TrainingSessionStatus", + "CreationTime" + ], + "members":{ + "TrainingSessionArn":{ + "shape":"TrainingSessionArn", + "documentation":"

The Amazon Resource Name (ARN) of the training session.

" + }, + "TrainingSessionName":{ + "shape":"TrainingSessionName", + "documentation":"

The name of the training session.

" + }, + "TrainingSessionStatus":{ + "shape":"TrainingSessionStatus", + "documentation":"

The current status of the training session.

" + }, + "ModelPackageGroupArn":{ + "shape":"ModelPackageGroupArn", + "documentation":"

The Amazon Resource Name (ARN) of the model package group where checkpoints are published.

" + }, + "CreationTime":{ + "shape":"Timestamp", + "documentation":"

The date and time that the training session was created.

" + }, + "LastModifiedTime":{ + "shape":"Timestamp", + "documentation":"

The date and time that the training session was last modified.

" + }, + "EndTime":{ + "shape":"Timestamp", + "documentation":"

The date and time that the training session ended.

" + }, + "ErrorDetails":{ + "shape":"FailureReason", + "documentation":"

If the training session failed or is blocked, detailed error information.

" + }, + "LastReceivedSequenceNumber":{ + "shape":"JavaInteger", + "documentation":"

The sequence number of the last training operation received by the session.

" + }, + "BillableTokenUsage":{ + "shape":"BillableTokenUsage", + "documentation":"

The billable token usage for the training session.

" + }, + "VpcConfig":{ + "shape":"VpcConfig", + "documentation":"

The Virtual Private Cloud (VPC) configuration for the training session.

" + }, + "RoleArn":{ + "shape":"RoleArn", + "documentation":"

The Amazon Resource Name (ARN) of the IAM role associated with the training session.

" + }, + "LoraConfig":{ + "shape":"LoraConfig", + "documentation":"

The Low-Rank Adaptation (LoRA) configuration for the training session.

" + }, + "ModelConfig":{ + "shape":"TrainingSessionModelConfig", + "documentation":"

The configuration for the base model.

" + }, + "OutputConfig":{ + "shape":"TrainingSessionOutputConfig", + "documentation":"

The output configuration for the training session.

" + }, + "Tags":{ + "shape":"TagList", + "documentation":"

The tags associated with the training session.

" + } + }, + "documentation":"

Contains detailed information about a training session.

" + }, + "TrainingSessionModelConfig":{ + "type":"structure", + "required":["BaseModelArn"], + "members":{ + "BaseModelArn":{ + "shape":"BaseModelArn", + "documentation":"

The Amazon Resource Name (ARN) of the base foundation model from SageMaker Hub.

" + }, + "AcceptEula":{ + "shape":"JavaBoolean", + "documentation":"

Specifies whether you accept the end-user license agreement (EULA) for gated models.

" + } + }, + "documentation":"

The configuration for the base model used in a training session.

" + }, + "TrainingSessionName":{ + "type":"string", + "max":63, + "min":1, + "pattern":"[a-zA-Z0-9](-*[a-zA-Z0-9]){0,62}" + }, + "TrainingSessionOutputConfig":{ + "type":"structure", + "required":["S3Location"], + "members":{ + "S3Location":{ + "shape":"TrainingSessionS3Location", + "documentation":"

The Amazon S3 location where training session outputs, including checkpoints and model artifacts, are stored.

" + } + }, + "documentation":"

The output configuration for a training session, including the Amazon S3 location for checkpoints and model artifacts, and optional encryption settings.

" + }, + "TrainingSessionS3Location":{ + "type":"structure", + "required":["Path"], + "members":{ + "Path":{ + "shape":"OutputS3Path", + "documentation":"

The Amazon S3 path where training session outputs are stored.

" + }, + "KmsKeyArn":{ + "shape":"CustomerKmsKeyArn", + "documentation":"

The Amazon Resource Name (ARN) of the KMS key used to encrypt output data. If not specified, the default Amazon S3 encryption is used.

" + } + }, + "documentation":"

Specifies the Amazon S3 path and optional encryption settings for training session output data, including checkpoints, model artifacts, and invocation results.

" + }, + "TrainingSessionStatus":{ + "type":"string", + "documentation":"

The status of a training session.

", + "enum":[ + "Created", + "Blocked", + "Running", + "Failed", + "Scheduled", + "Stopping", + "Stopped", + "Expired", + "Deleting", + "DeletionFailed" + ] + }, + "TrainingSessionSummaries":{ + "type":"list", + "member":{"shape":"TrainingSessionSummary"}, + "max":100, + "min":0 + }, + "TrainingSessionSummary":{ + "type":"structure", + "required":[ + "TrainingSessionArn", + "TrainingSessionStatus", + "CreationTime" + ], + "members":{ + "TrainingSessionArn":{ + "shape":"TrainingSessionArn", + "documentation":"

The Amazon Resource Name (ARN) of the training session.

" + }, + "TrainingSessionStatus":{ + "shape":"TrainingSessionStatus", + "documentation":"

The current status of the training session.

" + }, + "CreationTime":{ + "shape":"Timestamp", + "documentation":"

The date and time that the training session was created.

" + }, + "LastModifiedTime":{ + "shape":"Timestamp", + "documentation":"

The date and time that the training session was last modified.

" + } + }, + "documentation":"

Contains summary information about a training session.

" + }, "TrainingSpecification":{ "type":"structure", "required":[ @@ -47617,7 +49207,15 @@ "ml.g6.12xlarge", "ml.g6.16xlarge", "ml.g6.24xlarge", - "ml.g6.48xlarge" + "ml.g6.48xlarge", + "ml.g6e.xlarge", + "ml.g6e.2xlarge", + "ml.g6e.4xlarge", + "ml.g6e.8xlarge", + "ml.g6e.12xlarge", + "ml.g6e.16xlarge", + "ml.g6e.24xlarge", + "ml.g6e.48xlarge" ] }, "TransformInstanceTypes":{ @@ -48860,6 +50458,10 @@ "InstanceGroupName":{ "shape":"ClusterInstanceGroupName", "documentation":"

The name of the instance group to update.

" + }, + "ImageReleaseVersion":{ + "shape":"ImageReleaseVersion", + "documentation":"

The version of the HyperPod-managed AMI to update to for the instance group. Uses semantic versioning in the format MAJOR.MINOR.PATCH.

" } }, "documentation":"

The configuration that describes specifications of the instance groups to update.

" @@ -49976,6 +51578,14 @@ "shape":"PartnerAppConfig", "documentation":"

Configuration settings for the SageMaker Partner AI App.

" }, + "IdcConfig":{ + "shape":"IdcConfigInput", + "documentation":"

Specifies the Amazon Web Services IAM Identity Center configuration for the SageMaker Partner AI App. Specify this parameter when AuthType is IDC. Apps that use IAM authorization don't use this parameter.

" + }, + "AuthType":{ + "shape":"PartnerAppAuthType", + "documentation":"

The authorization type that users use to access the SageMaker Partner AI App. Use this parameter to migrate an existing SageMaker Partner AI App from IAM authorization to IDC authorization. Valid values:

" + }, "EnableIamSessionBasedIdentity":{ "shape":"Boolean", "documentation":"

When set to TRUE, the SageMaker Partner AI App sets the Amazon Web Services IAM session name or the authenticated IAM user as the identity of the SageMaker Partner AI App user.

", diff --git a/sagemaker-core/src/sagemaker/core/config_schema.py b/sagemaker-core/src/sagemaker/core/config_schema.py index 123ad3cf1f..de041068fb 100644 --- a/sagemaker-core/src/sagemaker/core/config_schema.py +++ b/sagemaker-core/src/sagemaker/core/config_schema.py @@ -501,7 +501,10 @@ }, "MlflowApp": { "type": "object", - "properties": {"role_arn": {"type": "string"}}, + "properties": { + "role_arn": {"type": "string"}, + "kms_key_id": {"type": "string"}, + }, }, "MlflowTrackingServer": { "type": "object", @@ -873,6 +876,27 @@ "profiler_config": {"s3_output_path": {"type": "string"}}, }, }, + "TrainingSession": { + "type": "object", + "properties": { + "training_session_detail": { + "vpc_config": { + "security_group_ids": { + "type": "array", + "items": {"type": "string"}, + }, + "subnets": { + "type": "array", + "items": {"type": "string"}, + }, + }, + "role_arn": {"type": "string"}, + "output_config": { + "s3_location": {"kms_key_arn": {"type": "string"}} + }, + } + }, + }, "TransformJob": { "type": "object", "properties": { diff --git a/sagemaker-core/src/sagemaker/core/resources.py b/sagemaker-core/src/sagemaker/core/resources.py index a780c829eb..dc44a8923c 100644 --- a/sagemaker-core/src/sagemaker/core/resources.py +++ b/sagemaker-core/src/sagemaker/core/resources.py @@ -626,6 +626,7 @@ class AIRecommendationJob(Base): performance_target: The performance targets specified for the recommendation job. recommendations: The list of optimization recommendations generated by the job. Each recommendation includes optimization details, deployment configuration, expected performance metrics, and the associated benchmark job ARN. compute_spec: The compute resource specification for the recommendation job. + adapter_source: The LoRA adapter source that you specified when you created the recommendation job. This field is absent when you created the job without LoRA adapters. start_time: A timestamp that indicates when the recommendation job started running. end_time: A timestamp that indicates when the recommendation job completed. tags: The tags associated with the recommendation job. @@ -645,6 +646,7 @@ class AIRecommendationJob(Base): recommendations: Optional[List[AIRecommendation]] = Unassigned() role_arn: Optional[StrPipeVar] = Unassigned() compute_spec: Optional[AIRecommendationComputeSpec] = Unassigned() + adapter_source: Optional[AIAdapterSource] = Unassigned() creation_time: Optional[datetime.datetime] = Unassigned() start_time: Optional[datetime.datetime] = Unassigned() end_time: Optional[datetime.datetime] = Unassigned() @@ -697,6 +699,7 @@ def create( inference_specification: Optional[AIRecommendationInferenceSpecification] = Unassigned(), optimize_model: Optional[bool] = Unassigned(), compute_spec: Optional[AIRecommendationComputeSpec] = Unassigned(), + adapter_source: Optional[AIAdapterSource] = Unassigned(), tags: Optional[List[Tag]] = Unassigned(), session: Optional[Session] = None, region: Optional[StrPipeVar] = None, @@ -714,6 +717,7 @@ def create( inference_specification: The inference framework configuration. Specify the framework (such as LMI or vLLM) for the recommendation job. optimize_model: Whether to allow model optimization techniques such as quantization, speculative decoding, and kernel tuning. The default is true. compute_spec: The compute resource specification for the recommendation job. You can specify up to 3 instance types to consider, and optionally provide capacity reservation configuration. + adapter_source: The LoRA adapter source for the recommendation job. Specify either a list of model package ARNs or Amazon S3 URIs for your LoRA adapters. When this parameter is absent, the recommendation job runs without LoRA adapter support. tags: The metadata that you apply to Amazon Web Services resources to help you categorize and organize them. session: Boto3 session. region: Region name. @@ -754,6 +758,7 @@ def create( "InferenceSpecification": inference_specification, "OptimizeModel": optimize_model, "ComputeSpec": compute_spec, + "AdapterSource": adapter_source, "Tags": tags, } @@ -5318,7 +5323,7 @@ def create( Create a ClusterSchedulerConfig resource Parameters: - name: Name for the cluster policy. + name: The name for the cluster policy. The name must be unique within the SageMaker AI HyperPod cluster specified by ClusterArn. You can use the same name in other clusters within a Region or across Regions. cluster_arn: ARN of the cluster. scheduler_config: Configuration about the monitoring schedule. description: Description of the cluster policy. @@ -6643,7 +6648,7 @@ def create( Create a ComputeQuota resource Parameters: - name: Name to the compute allocation definition. + name: The name of the compute allocation definition. The name must be unique within the SageMaker AI HyperPod cluster specified by ClusterArn. You can use the same name in other clusters within a Region or across Regions. cluster_arn: ARN of the cluster. compute_quota_config: Configuration of the compute allocation definition. This includes the resource sharing option, and the setting to preempt low priority tasks. compute_quota_target: The target entity to allocate compute resources to. @@ -11096,7 +11101,7 @@ def create( production_variants: An array of ProductionVariant objects, one for each model that you want to host at this endpoint. data_capture_config: tags: An array of key-value pairs. You can use tags to categorize your Amazon Web Services resources in different ways, for example, by purpose, owner, or environment. For more information, see Tagging Amazon Web Services Resources. - kms_key_id: The Amazon Resource Name (ARN) of a Amazon Web Services Key Management Service key that SageMaker uses to encrypt data on the storage volume attached to the ML compute instance that hosts the endpoint. The KmsKeyId can be any of the following formats: Key ID: 1234abcd-12ab-34cd-56ef-1234567890ab Key ARN: arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab Alias name: alias/ExampleAlias Alias name ARN: arn:aws:kms:us-west-2:111122223333:alias/ExampleAlias The KMS key policy must grant permission to the IAM role that you specify in your CreateEndpoint, UpdateEndpoint requests. For more information, refer to the Amazon Web Services Key Management Service section Using Key Policies in Amazon Web Services KMS Certain Nitro-based instances include local storage, dependent on the instance type. Local storage volumes are encrypted using a hardware module on the instance. You can't request a KmsKeyId when using an instance type with local storage. If any of the models that you specify in the ProductionVariants parameter use nitro-based instances with local storage, do not specify a value for the KmsKeyId parameter. If you specify a value for KmsKeyId when using any nitro-based instances with local storage, the call to CreateEndpointConfig fails. For a list of instance types that support local instance storage, see Instance Store Volumes. For more information about local instance storage encryption, see SSD Instance Store Volumes. + kms_key_id: The Amazon Resource Name (ARN) of a Amazon Web Services Key Management Service key that SageMaker uses to encrypt data on the storage volume attached to the ML compute instance that hosts the endpoint. The KmsKeyId can be any of the following formats: Key ID: 1234abcd-12ab-34cd-56ef-1234567890ab Key ARN: arn:aws:kms:us-west-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab Alias name: alias/ExampleAlias Alias name ARN: arn:aws:kms:us-west-2:111122223333:alias/ExampleAlias The KMS key policy must grant permission to the IAM role that you specify in your CreateEndpoint, UpdateEndpoint requests. For more information, refer to the Amazon Web Services Key Management Service section Using Key Policies in Amazon Web Services KMS Certain Nitro-based instances include local storage, dependent on the instance type. Local storage volumes are encrypted using a hardware module on the instance. If any of the models that you specify in the ProductionVariants parameter use nitro-based instances with local storage, the KmsKeyId parameter does not encrypt instance local storage. For a list of instance types that support local instance storage, see Instance Store Volumes. For more information about local instance storage encryption, see SSD Instance Store Volumes. async_inference_config: Specifies configuration for how an endpoint performs asynchronous inference. This is a required field in order for your Endpoint to be invoked using InvokeEndpointAsync. explainer_config: A member of CreateEndpointConfig that enables explainers. shadow_production_variants: An array of ProductionVariant objects, one for each model that you want to host at this endpoint in shadow mode with production traffic replicated from the model specified on ProductionVariants. If you use this field, you can only specify one variant for ProductionVariants and one variant for ShadowProductionVariants. @@ -12363,11 +12368,11 @@ def update_record( region: Optional[str] = None, ) -> None: """ - The UpdateRecord API performs a feature-level write to a Record in a feature group whose OnlineStoreConfig StorageType is Standard_V2 or InMemory. Only the supplied Features are written; features not included are preserved. The record must already exist in the online store. + Updates one or more feature values for an existing record in the specified feature group. Parameters: record_identifier_value_as_string: The value for the RecordIdentifier that uniquely identifies the record to update, in string format. - features: The list of FeatureValues to update. Only the features included here are written; features that are not listed are preserved. Pass EventTime as a feature in this list. A maximum of 100 features can be updated in a single request. + features: The feature values to write to the record. Only the features included here are written; features that are not listed are preserved. Pass EventTime as a feature in this list. You can update up to 100 features per call. target_stores: A list of stores to which the update is applied. By default, Feature Store applies the update to all of the stores that you're using for the FeatureGroup. A value that resolves to the OfflineStore only is rejected. ttl_duration: Time to live duration, where the record is hard deleted after the expiration time is reached; ExpiresAt = EventTime + TtlDuration. Specifying TtlDuration requires EventTime to be present in Features. session: Boto3 session. @@ -12384,9 +12389,9 @@ def update_record( error_code = e.response['Error']['Code'] ``` AccessForbidden: You do not have permission to perform an action. - ConflictException: There was a conflict when you attempted to modify a record; the supplied EventTime was not greater than the record's current EventTime. + ConflictException: There was a conflict when you attempted to modify a SageMaker entity such as an Experiment or Artifact. InternalFailure: An internal failure occurred. Try your request again. If the problem persists, contact Amazon Web Services customer support. - ResourceNotFound: A resource that is required to perform an action was not found. + ResourceNotFound: Resource being access is not found. ServiceUnavailable: The service is currently unavailable. ValidationError: There was an error validating your request. """ @@ -19473,6 +19478,7 @@ class MlflowApp(Base): artifact_store_uri: The S3 URI of the general purpose bucket used as the MLflow App artifact store. mlflow_version: The MLflow version used. role_arn: The Amazon Resource Name (ARN) for an IAM role in your account that the MLflow App uses to access the artifact store in Amazon S3. + kms_key_id: The ID of the Amazon Web Services KMS key used to encrypt the data at rest associated with the MLflow App. This field is absent if the MLflow App is not encrypted with a customer-managed key. status: The current creation status of the described MLflow App. model_registration_mode: Whether automatic registration of new MLflow models to the SageMaker Model Registry is enabled. account_default_status: Indicates whether this MLflow app is the default for the entire account. @@ -19491,6 +19497,7 @@ class MlflowApp(Base): artifact_store_uri: Optional[StrPipeVar] = Unassigned() mlflow_version: Optional[StrPipeVar] = Unassigned() role_arn: Optional[StrPipeVar] = Unassigned() + kms_key_id: Optional[StrPipeVar] = Unassigned() status: Optional[StrPipeVar] = Unassigned() model_registration_mode: Optional[StrPipeVar] = Unassigned() account_default_status: Optional[StrPipeVar] = Unassigned() @@ -19521,7 +19528,10 @@ def get_name(self) -> str: def populate_inputs_decorator(create_func): @functools.wraps(create_func) def wrapper(*args, **kwargs): - config_schema_for_resource = {"role_arn": {"type": "string"}} + config_schema_for_resource = { + "role_arn": {"type": "string"}, + "kms_key_id": {"type": "string"}, + } return create_func( *args, **Base.get_updated_kwargs_with_configured_attributes( @@ -19539,6 +19549,7 @@ def create( name: StrPipeVar, artifact_store_uri: StrPipeVar, role_arn: StrPipeVar, + kms_key_id: Optional[StrPipeVar] = Unassigned(), model_registration_mode: Optional[StrPipeVar] = Unassigned(), weekly_maintenance_window_start: Optional[StrPipeVar] = Unassigned(), account_default_status: Optional[StrPipeVar] = Unassigned(), @@ -19554,6 +19565,7 @@ def create( name: A string identifying the MLflow app name. This string is not part of the tracking server ARN. artifact_store_uri: The S3 URI for a general purpose bucket to use as the MLflow App artifact store. role_arn: The Amazon Resource Name (ARN) for an IAM role in your account that the MLflow App uses to access the artifact store in Amazon S3. The role should have the AmazonS3FullAccess permission. + kms_key_id: The ID of the Amazon Web Services KMS key used to encrypt the data at rest associated with the MLflow App. If you don't specify a value, the MLflow App is not encrypted with a customer-managed key. model_registration_mode: Whether to enable or disable automatic registration of new MLflow models to the SageMaker Model Registry. To enable automatic model registration, set this value to AutoModelRegistrationEnabled. To disable automatic model registration, set this value to AutoModelRegistrationDisabled. If not specified, AutomaticModelRegistration defaults to AutoModelRegistrationDisabled. weekly_maintenance_window_start: The day and time of the week in Coordinated Universal Time (UTC) 24-hour standard time that weekly maintenance updates are scheduled. For example: TUE:03:30. account_default_status: Indicates whether this MLflow app is the default for the entire account. @@ -19590,6 +19602,7 @@ def create( "Name": name, "ArtifactStoreUri": artifact_store_uri, "RoleArn": role_arn, + "KmsKeyId": kms_key_id, "ModelRegistrationMode": model_registration_mode, "WeeklyMaintenanceWindowStart": weekly_maintenance_window_start, "AccountDefaultStatus": account_default_status, @@ -21401,7 +21414,7 @@ class ModelCard(Base): model_card_arn: The Amazon Resource Name (ARN) of the model card. model_card_name: The name of the model card. model_card_version: The version of the model card. - content: The content of the model card. + content: The content of the model card. Content is provided as a string in the model card JSON schema. When you set IncludedData to MetadataOnly in the request, SageMaker returns a sanitized version of Content that includes only the following JSON paths, when present in the model card: model_overview.model_id model_overview.model_name intended_uses.risk_rating model_package_details.model_package_group_name model_package_details.model_package_arn All other fields are removed from Content when IncludedData is MetadataOnly, including model description, training details, evaluation details, business details, and additional information. To retrieve the complete Content, set IncludedData to AllData or omit the parameter. model_card_status: The approval status of the model card within your organization. Different organizations might have different criteria for model card review and approval. Draft: The model card is a work in progress. PendingReview: The model card is pending review. Approved: The model card is approved. Archived: The model card is archived. No more updates should be made to the model card, but it can still be exported. creation_time: The date and time the model card was created. created_by: @@ -21532,6 +21545,7 @@ def get( cls, model_card_name: StrPipeVar, model_card_version: Optional[int] = Unassigned(), + included_data: Optional[StrPipeVar] = Unassigned(), session: Optional[Session] = None, region: Optional[StrPipeVar] = None, ) -> Optional["ModelCard"]: @@ -21541,6 +21555,7 @@ def get( Parameters: model_card_name: The name or Amazon Resource Name (ARN) of the model card to describe. model_card_version: The version of the model card to describe. If a version is not provided, then the latest version of the model card is described. + included_data: Specifies the level of model card data to include in the response. Use this parameter to call DescribeModelCard without requiring kms:Decrypt permission on the customer-managed Amazon Web Services KMS key. AllData: Returns the full model card Content. This option requires kms:Decrypt permission on the customer-managed key, if one is associated with the model card. This is the default. MetadataOnly: Returns the model card with sanitized Content that includes only a small set of unencrypted metadata fields. This option does not require kms:Decrypt permission. For the list of fields preserved in the response, see Content. If you don't specify a value, SageMaker returns AllData. session: Boto3 session. region: Region name. @@ -21563,6 +21578,7 @@ def get( operation_input_args = { "ModelCardName": model_card_name, "ModelCardVersion": model_card_version, + "IncludedData": included_data, } # serialize the input request operation_input_args = serialize(operation_input_args) @@ -21584,6 +21600,7 @@ def get( @Base.add_validate_call def refresh( self, + included_data: Optional[StrPipeVar] = Unassigned(), ) -> Optional["ModelCard"]: """ Refresh a ModelCard resource @@ -21607,6 +21624,7 @@ def refresh( operation_input_args = { "ModelCardName": self.model_card_name, "ModelCardVersion": self.model_card_version, + "IncludedData": included_data, } # serialize the input request operation_input_args = serialize(operation_input_args) @@ -22665,7 +22683,7 @@ class ModelPackage(Base): skip_model_validation: Indicates if you want to skip model validation. source_uri: The URI of the source for the model package. security_config: The KMS Key ID (KMSKeyId) used for encryption of model package information. - model_card: 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 of ModelCard. The ModelPackageModelCard schema does not include model_package_details, and model_overview is composed of the model_creator and model_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. + model_card: 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 of ModelCard. The ModelPackageModelCard schema does not include model_package_details, and model_overview is composed of the model_creator and model_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. When you set IncludedData to MetadataOnly in the request, ModelCardStatus is preserved and ModelCardContent is sanitized to include only the following JSON paths, when present in the model card: model_overview.model_id model_overview.model_name intended_uses.risk_rating model_package_details.model_package_group_name model_package_details.model_package_arn Because the ModelPackageModelCard schema does not include model_package_details and limits model_overview to model_creator and model_artifact, the sanitized ModelCardContent for a model package typically contains only intended_uses.risk_rating if it was provided when the model card was created. To retrieve the complete ModelCardContent, set IncludedData to AllData or omit the parameter. model_life_cycle: A structure describing the current state of the model in its life cycle. managed_storage_type: The storage type of the model package. @@ -22915,6 +22933,7 @@ def create( def get( cls, model_package_name: StrPipeVar, + included_data: Optional[StrPipeVar] = Unassigned(), session: Optional[Session] = None, region: Optional[StrPipeVar] = None, ) -> Optional["ModelPackage"]: @@ -22923,6 +22942,7 @@ def get( Parameters: model_package_name: 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). + included_data: Specifies the level of model package data to include in the response. Use this parameter to call DescribeModelPackage on a model package that has an associated model card without requiring kms:Decrypt permission on the customer-managed KMS key associated with the embedded model card. AllData: Returns the full model package response, including the unredacted ModelCard.ModelCardContent. This option requires kms:Decrypt permission on the customer-managed key, if one is associated with the embedded model card. This is the default. MetadataOnly: Returns the full model package response, but with the embedded ModelCard.ModelCardContent sanitized to include only a small set of unencrypted metadata fields. This option does not require kms:Decrypt permission. All other top-level response fields, including InferenceSpecification, ModelMetrics, DriftCheckBaselines, and SecurityConfig, are returned unchanged. For the list of fields preserved within ModelCardContent, see ModelCard. If you don't specify a value, SageMaker returns AllData. session: Boto3 session. region: Region name. @@ -22943,6 +22963,7 @@ def get( operation_input_args = { "ModelPackageName": model_package_name, + "IncludedData": included_data, } # serialize the input request operation_input_args = serialize(operation_input_args) @@ -22964,6 +22985,7 @@ def get( @Base.add_validate_call def refresh( self, + included_data: Optional[StrPipeVar] = Unassigned(), ) -> Optional["ModelPackage"]: """ Refresh a ModelPackage resource @@ -22989,6 +23011,7 @@ def refresh( if not isinstance(self.model_package_name, Unassigned) else self.model_package_arn ), + "IncludedData": included_data, } # serialize the input request operation_input_args = serialize(operation_input_args) @@ -25633,7 +25656,15 @@ def stop(self) -> None: def wait_for_status( self, target_status: Literal[ - "Pending", "InService", "Stopping", "Stopped", "Failed", "Deleting", "Updating" + "Pending", + "InService", + "Stopping", + "Stopped", + "Failed", + "Deleting", + "Updating", + "PendingMaintenance", + "InMaintenance", ], poll: int = 5, timeout: Optional[int] = None, @@ -26213,6 +26244,7 @@ class OptimizationJob(Base): max_instance_count: The maximum number of instances to use for the optimization job. optimization_output: Output values produced by an optimization job. vpc_config: A VPC in Amazon VPC that your optimized model has access to. + training_plan_arns: The Amazon Resource Name (ARN) of the training plan associated with this optimization job. This field appears only when you specified a training plan when you created the job. Optimization jobs that use on-demand capacity don't return this field. """ @@ -26234,6 +26266,7 @@ class OptimizationJob(Base): role_arn: Optional[StrPipeVar] = Unassigned() stopping_condition: Optional[StoppingCondition] = Unassigned() vpc_config: Optional[OptimizationVpcConfig] = Unassigned() + training_plan_arns: Optional[List[StrPipeVar]] = Unassigned() def get_name(self) -> str: attributes = vars(self) @@ -26291,6 +26324,7 @@ def create( optimization_environment: Optional[Dict[StrPipeVar, StrPipeVar]] = Unassigned(), tags: Optional[List[Tag]] = Unassigned(), vpc_config: Optional[OptimizationVpcConfig] = Unassigned(), + training_plan_arns: Optional[List[StrPipeVar]] = Unassigned(), session: Optional[Session] = None, region: Optional[StrPipeVar] = None, ) -> Optional["OptimizationJob"]: @@ -26309,6 +26343,7 @@ def create( optimization_environment: The environment variables to set in the model container. tags: A list of key-value pairs associated with the optimization job. For more information, see Tagging Amazon Web Services resources in the Amazon Web Services General Reference Guide. vpc_config: A VPC in Amazon VPC that your optimized model has access to. + training_plan_arns: The Amazon Resource Name (ARN) of the training plan to use for this optimization job. When you use reserved capacity from a training plan, the optimization job runs on that reserved capacity instead of on-demand capacity. If you omit this field, the job uses on-demand capacity. You can specify at most one training plan. For more information about how to reserve GPU capacity for your optimization jobs using Amazon SageMaker Training Plans, see Reserve capacity with training plans. session: Boto3 session. region: Region name. @@ -26349,6 +26384,7 @@ def create( "StoppingCondition": stopping_condition, "Tags": tags, "VpcConfig": vpc_config, + "TrainingPlanArns": training_plan_arns, } operation_input_args = Base.populate_chained_attributes( @@ -26681,12 +26717,13 @@ class PartnerApp(Base): tier: The instance type and size of the cluster attached to the SageMaker Partner AI App. version: The version of the SageMaker Partner AI App. application_config: Configuration settings for the SageMaker Partner AI App. - auth_type: The authorization type that users use to access the SageMaker Partner AI App. + auth_type: The authorization type that users use to access the SageMaker Partner AI App. Valid values: IAM: Users access the SageMaker Partner AI App with their Amazon Web Services IAM identity. IDC: Users access the SageMaker Partner AI App with their Amazon Web Services IAM Identity Center identity. enable_iam_session_based_identity: When set to TRUE, the SageMaker Partner AI App sets the Amazon Web Services IAM session name or the authenticated IAM user as the identity of the SageMaker Partner AI App user. error: This is an error field object that contains the error code and the reason for an operation failure. enable_auto_minor_version_upgrade: Indicates whether the SageMaker Partner AI App is configured for automatic minor version upgrades during scheduled maintenance windows. current_version_eol_date: The end-of-life date for the current version of the SageMaker Partner AI App. available_upgrade: A map of available minor version upgrades for the SageMaker Partner AI App. The key is the semantic version number, and the value is a list of release notes for that version. A null value indicates no upgrades are available. + idc_config: Contains the Amazon Web Services IAM Identity Center configuration for the SageMaker Partner AI App, including the Identity Center instance and the Identity Center application that SageMaker creates for the app. The service returns this field for apps that use IDC authorization. """ @@ -26709,6 +26746,7 @@ class PartnerApp(Base): enable_auto_minor_version_upgrade: Optional[bool] = Unassigned() current_version_eol_date: Optional[datetime.datetime] = Unassigned() available_upgrade: Optional[AvailableUpgrade] = Unassigned() + idc_config: Optional[IdcConfigOutput] = Unassigned() def get_name(self) -> str: attributes = vars(self) @@ -26755,6 +26793,7 @@ def create( kms_key_id: Optional[StrPipeVar] = Unassigned(), maintenance_config: Optional[PartnerAppMaintenanceConfig] = Unassigned(), application_config: Optional[PartnerAppConfig] = Unassigned(), + idc_config: Optional[IdcConfigInput] = Unassigned(), enable_iam_session_based_identity: Optional[bool] = Unassigned(), enable_auto_minor_version_upgrade: Optional[bool] = Unassigned(), client_token: Optional[StrPipeVar] = Unassigned(), @@ -26770,10 +26809,11 @@ def create( type: The type of SageMaker Partner AI App to create. Must be one of the following: lakera-guard, comet, deepchecks-llm-evaluation, or fiddler. execution_role_arn: The ARN of the IAM role that the partner application uses. tier: Indicates the instance type and size of the cluster attached to the SageMaker Partner AI App. - auth_type: The authorization type that users use to access the SageMaker Partner AI App. + auth_type: The authorization type that users use to access the SageMaker Partner AI App. Valid values: IAM: Users access the SageMaker Partner AI App with their Amazon Web Services IAM identity. IDC: Users access the SageMaker Partner AI App with their Amazon Web Services IAM Identity Center identity. Specify the Identity Center instance to use in IdcConfig. kms_key_id: SageMaker Partner AI Apps uses Amazon Web Services KMS to encrypt data at rest using an Amazon Web Services managed key by default. For more control, specify a customer managed key. maintenance_config: Maintenance configuration settings for the SageMaker Partner AI App. application_config: Configuration settings for the SageMaker Partner AI App. + idc_config: Specifies the Amazon Web Services IAM Identity Center configuration for the SageMaker Partner AI App. Specify this parameter when AuthType is IDC. Apps that use IAM authorization don't use this parameter. enable_iam_session_based_identity: When set to TRUE, the SageMaker Partner AI App sets the Amazon Web Services IAM session name or the authenticated IAM user as the identity of the SageMaker Partner AI App user. enable_auto_minor_version_upgrade: When set to TRUE, the SageMaker Partner AI App is automatically upgraded to the latest minor version during the next scheduled maintenance window, if one is available. Default is FALSE. client_token: A unique token that guarantees that the call to this API is idempotent. @@ -26814,6 +26854,7 @@ def create( "MaintenanceConfig": maintenance_config, "Tier": tier, "ApplicationConfig": application_config, + "IdcConfig": idc_config, "AuthType": auth_type, "EnableIamSessionBasedIdentity": enable_iam_session_based_identity, "EnableAutoMinorVersionUpgrade": enable_auto_minor_version_upgrade, @@ -26937,6 +26978,8 @@ def update( maintenance_config: Optional[PartnerAppMaintenanceConfig] = Unassigned(), tier: Optional[StrPipeVar] = Unassigned(), application_config: Optional[PartnerAppConfig] = Unassigned(), + idc_config: Optional[IdcConfigInput] = Unassigned(), + auth_type: Optional[StrPipeVar] = Unassigned(), enable_iam_session_based_identity: Optional[bool] = Unassigned(), enable_auto_minor_version_upgrade: Optional[bool] = Unassigned(), app_version: Optional[StrPipeVar] = Unassigned(), @@ -26976,6 +27019,8 @@ def update( "MaintenanceConfig": maintenance_config, "Tier": tier, "ApplicationConfig": application_config, + "IdcConfig": idc_config, + "AuthType": auth_type, "EnableIamSessionBasedIdentity": enable_iam_session_based_identity, "EnableAutoMinorVersionUpgrade": enable_auto_minor_version_upgrade, "AppVersion": app_version, @@ -32311,6 +32356,425 @@ def get_all( ) +class TrainingSession(Base): + """ + Class representing resource TrainingSession + + Attributes: + training_session_detail: The detailed information about the training session. + + """ + + training_session_name: StrPipeVar + training_session_detail: Optional[TrainingSessionDetail] = Unassigned() + + def get_name(self) -> str: + attributes = vars(self) + resource_name = "training_session_name" + resource_name_split = resource_name.split("_") + attribute_name_candidates = [] + + l = len(resource_name_split) + for i in range(0, l): + attribute_name_candidates.append("_".join(resource_name_split[i:l])) + + for attribute, value in attributes.items(): + if attribute == "name" or attribute in attribute_name_candidates: + return value + logger.error("Name attribute not found for object training_session") + return None + + def populate_inputs_decorator(create_func): + @functools.wraps(create_func) + def wrapper(*args, **kwargs): + config_schema_for_resource = { + "training_session_detail": { + "vpc_config": { + "security_group_ids": {"type": "array", "items": {"type": "string"}}, + "subnets": {"type": "array", "items": {"type": "string"}}, + }, + "role_arn": {"type": "string"}, + "output_config": {"s3_location": {"kms_key_arn": {"type": "string"}}}, + } + } + return create_func( + *args, + **Base.get_updated_kwargs_with_configured_attributes( + config_schema_for_resource, "TrainingSession", **kwargs + ), + ) + + return wrapper + + @classmethod + @populate_inputs_decorator + @Base.add_validate_call + def create( + cls, + training_session_name: StrPipeVar, + lora_config: LoraConfig, + role_arn: StrPipeVar, + model_config: TrainingSessionModelConfig, + output_config: TrainingSessionOutputConfig, + model_package_group_arn: Optional[StrPipeVar] = Unassigned(), + vpc_config: Optional[VpcConfig] = Unassigned(), + tags: Optional[List[Tag]] = Unassigned(), + session: Optional[Session] = None, + region: Optional[StrPipeVar] = None, + ) -> Optional["TrainingSession"]: + """ + Create a TrainingSession resource + + Parameters: + training_session_name: The name of the training session. + lora_config: The Low-Rank Adaptation (LoRA) configuration for the training session, including the rank and alpha parameters. + role_arn: The Amazon Resource Name (ARN) of the IAM role that Amazon SageMaker assumes to access resources on your behalf. The role must have permissions to access the output S3 path and model package group. + model_config: The configuration for the base model, including the model ARN and end-user license agreement (EULA) acceptance. + output_config: The output configuration for the training session, including the S3 location and optional encryption settings. + model_package_group_arn: The Amazon Resource Name (ARN) of the model package group where checkpoints and fine-tuned model artifacts are published. + vpc_config: The Virtual Private Cloud (VPC) configuration for the training session. Specify subnets and security groups to run the training session in your VPC. + tags: An array of key-value pairs to apply to the training session as tags. For more information, see Tagging Amazon Web Services Resources. + session: Boto3 session. + region: Region name. + + Returns: + The TrainingSession resource. + + Raises: + botocore.exceptions.ClientError: This exception is raised for AWS service related errors. + The error message and error code can be parsed from the exception as follows: + ``` + try: + # AWS service call here + except botocore.exceptions.ClientError as e: + error_message = e.response['Error']['Message'] + error_code = e.response['Error']['Code'] + ``` + ResourceInUse: Resource being accessed is in use. + ResourceLimitExceeded: You have exceeded an SageMaker resource limit. For example, you might have too many training jobs created. + ResourceNotFound: Resource being access is not found. + ConfigSchemaValidationError: Raised when a configuration file does not adhere to the schema + LocalConfigNotFoundError: Raised when a configuration file is not found in local file system + S3ConfigNotFoundError: Raised when a configuration file is not found in S3 + """ + + logger.info("Creating training_session resource.") + client = Base.get_sagemaker_client( + session=session, region_name=region, service_name="sagemaker" + ) + + operation_input_args = { + "TrainingSessionName": training_session_name, + "ModelPackageGroupArn": model_package_group_arn, + "LoraConfig": lora_config, + "RoleArn": role_arn, + "VpcConfig": vpc_config, + "ModelConfig": model_config, + "OutputConfig": output_config, + "Tags": tags, + } + + operation_input_args = Base.populate_chained_attributes( + resource_name="TrainingSession", operation_input_args=operation_input_args + ) + + logger.debug(f"Input request: {operation_input_args}") + # serialize the input request + operation_input_args = serialize(operation_input_args) + logger.debug(f"Serialized input request: {operation_input_args}") + + # create the resource + response = client.create_training_session(**operation_input_args) + logger.debug(f"Response: {response}") + + return cls.get(training_session_name=training_session_name, session=session, region=region) + + @classmethod + @Base.add_validate_call + def get( + cls, + training_session_name: StrPipeVar, + session: Optional[Session] = None, + region: Optional[StrPipeVar] = None, + ) -> Optional["TrainingSession"]: + """ + Get a TrainingSession resource + + Parameters: + training_session_name: The name of the training session to describe. + session: Boto3 session. + region: Region name. + + Returns: + The TrainingSession resource. + + Raises: + botocore.exceptions.ClientError: This exception is raised for AWS service related errors. + The error message and error code can be parsed from the exception as follows: + ``` + try: + # AWS service call here + except botocore.exceptions.ClientError as e: + error_message = e.response['Error']['Message'] + error_code = e.response['Error']['Code'] + ``` + ResourceNotFound: Resource being access is not found. + """ + + operation_input_args = { + "TrainingSessionName": training_session_name, + } + # serialize the input request + operation_input_args = serialize(operation_input_args) + logger.debug(f"Serialized input request: {operation_input_args}") + + client = Base.get_sagemaker_client( + session=session, region_name=region, service_name="sagemaker" + ) + response = client.describe_training_session(**operation_input_args) + + logger.debug(response) + + # deserialize the response + transformed_response = transform(response, "DescribeTrainingSessionResponse") + training_session = cls(**transformed_response) + training_session._set_client_context(session=session, region=region) + return training_session + + @Base.add_validate_call + def refresh( + self, + ) -> Optional["TrainingSession"]: + """ + Refresh a TrainingSession resource + + Returns: + The TrainingSession resource. + + Raises: + botocore.exceptions.ClientError: This exception is raised for AWS service related errors. + The error message and error code can be parsed from the exception as follows: + ``` + try: + # AWS service call here + except botocore.exceptions.ClientError as e: + error_message = e.response['Error']['Message'] + error_code = e.response['Error']['Code'] + ``` + ResourceNotFound: Resource being access is not found. + """ + + operation_input_args = { + "TrainingSessionName": self.training_session_name, + } + # serialize the input request + operation_input_args = serialize(operation_input_args) + logger.debug(f"Serialized input request: {operation_input_args}") + + client = self._get_client() + response = client.describe_training_session(**operation_input_args) + + # deserialize response and update self + transform(response, "DescribeTrainingSessionResponse", self) + return self + + @Base.add_validate_call + def delete( + self, + ) -> None: + """ + Delete a TrainingSession resource + + Raises: + botocore.exceptions.ClientError: This exception is raised for AWS service related errors. + The error message and error code can be parsed from the exception as follows: + ``` + try: + # AWS service call here + except botocore.exceptions.ClientError as e: + error_message = e.response['Error']['Message'] + error_code = e.response['Error']['Code'] + ``` + ResourceNotFound: Resource being access is not found. + """ + + client = self._get_client() + + operation_input_args = { + "TrainingSessionName": self.training_session_name, + } + # serialize the input request + operation_input_args = serialize(operation_input_args) + logger.debug(f"Serialized input request: {operation_input_args}") + + client.delete_training_session(**operation_input_args) + + logger.info(f"Deleting {self.__class__.__name__} - {self.get_name()}") + + @Base.add_validate_call + def stop(self) -> None: + """ + Stop a TrainingSession resource + + Raises: + botocore.exceptions.ClientError: This exception is raised for AWS service related errors. + The error message and error code can be parsed from the exception as follows: + ``` + try: + # AWS service call here + except botocore.exceptions.ClientError as e: + error_message = e.response['Error']['Message'] + error_code = e.response['Error']['Code'] + ``` + ResourceNotFound: Resource being access is not found. + """ + + client = self._get_client() + + operation_input_args = { + "TrainingSessionName": self.training_session_name, + } + # serialize the input request + operation_input_args = serialize(operation_input_args) + logger.debug(f"Serialized input request: {operation_input_args}") + + client.stop_training_session(**operation_input_args) + + logger.info(f"Stopping {self.__class__.__name__} - {self.get_name()}") + + @Base.add_validate_call + def wait_for_status( + self, + target_status: Literal[ + "Created", + "Blocked", + "Running", + "Failed", + "Scheduled", + "Stopping", + "Stopped", + "Expired", + "Deleting", + "DeletionFailed", + ], + poll: int = 5, + timeout: Optional[int] = None, + ) -> None: + """ + Wait for a TrainingSession resource to reach certain status. + + Parameters: + target_status: The status to wait for. + poll: The number of seconds to wait between each poll. + timeout: The maximum number of seconds to wait before timing out. + + Raises: + TimeoutExceededError: If the resource does not reach a terminal state before the timeout. + FailedStatusError: If the resource reaches a failed state. + WaiterError: Raised when an error occurs while waiting. + """ + start_time = time.time() + + progress = Progress( + SpinnerColumn("bouncingBar"), + TextColumn("{task.description}"), + TimeElapsedColumn(), + ) + progress.add_task(f"Waiting for TrainingSession to reach [bold]{target_status} status...") + status = Status("Current status:") + + with Live( + Panel( + Group(progress, status), + title="Wait Log Panel", + border_style=Style(color=Color.BLUE.value), + ), + transient=True, + ): + while True: + self.refresh() + current_status = self.training_session_detail.training_session_status + status.update(f"Current status: [bold]{current_status}") + + if target_status == current_status: + logger.info(f"Final Resource Status: [bold]{current_status}") + return + + if "failed" in current_status.lower(): + raise FailedStatusError( + resource_type="TrainingSession", status=current_status, reason="(Unknown)" + ) + + if timeout is not None and time.time() - start_time >= timeout: + raise TimeoutExceededError( + resource_type="TrainingSession", status=current_status + ) + time.sleep(poll) + + @Base.add_validate_call + def wait_for_delete( + self, + poll: int = 5, + timeout: Optional[int] = None, + ) -> None: + """ + Wait for a TrainingSession resource to be deleted. + + Parameters: + poll: The number of seconds to wait between each poll. + timeout: The maximum number of seconds to wait before timing out. + + Raises: + botocore.exceptions.ClientError: This exception is raised for AWS service related errors. + The error message and error code can be parsed from the exception as follows: + ``` + try: + # AWS service call here + except botocore.exceptions.ClientError as e: + error_message = e.response['Error']['Message'] + error_code = e.response['Error']['Code'] + ``` + TimeoutExceededError: If the resource does not reach a terminal state before the timeout. + DeleteFailedStatusError: If the resource reaches a failed state. + WaiterError: Raised when an error occurs while waiting. + """ + start_time = time.time() + + progress = Progress( + SpinnerColumn("bouncingBar"), + TextColumn("{task.description}"), + TimeElapsedColumn(), + ) + progress.add_task("Waiting for TrainingSession to be deleted...") + status = Status("Current status:") + + with Live( + Panel( + Group(progress, status), + title="Wait Log Panel", + border_style=Style(color=Color.BLUE.value), + ) + ): + while True: + try: + self.refresh() + current_status = self.training_session_detail.training_session_status + status.update(f"Current status: [bold]{current_status}") + + if timeout is not None and time.time() - start_time >= timeout: + raise TimeoutExceededError( + resource_type="TrainingSession", status=current_status + ) + except botocore.exceptions.ClientError as e: + error_code = e.response["Error"]["Code"] + + if "ResourceNotFound" in error_code or "ValidationException" in error_code: + logger.info("Resource was not found. It may have been deleted.") + return + raise e + time.sleep(poll) + + class TransformJob(Base): """ Class representing resource TransformJob diff --git a/sagemaker-core/src/sagemaker/core/shapes/shapes.py b/sagemaker-core/src/sagemaker/core/shapes/shapes.py index f0376b2dd5..8b2e9f6f9d 100644 --- a/sagemaker-core/src/sagemaker/core/shapes/shapes.py +++ b/sagemaker-core/src/sagemaker/core/shapes/shapes.py @@ -237,6 +237,19 @@ class AccessForbidden(Base): message: Optional[StrPipeVar] = Unassigned() +class ConflictException(Base): + """ + ConflictException + There was a conflict when you attempted to modify a SageMaker entity such as an Experiment or Artifact. + + Attributes + ---------------------- + message + """ + + message: Optional[StrPipeVar] = Unassigned() + + class BatchGetRecordError(Base): """ BatchGetRecordError @@ -521,6 +534,51 @@ class RawMetricData(Base): step: Optional[int] = Unassigned() +class AIAdapterModelPackageEntry(Base): + """ + AIAdapterModelPackageEntry + A LoRA adapter entry identified by a model package ARN. + + Attributes + ---------------------- + adapter_id: A unique identifier for the adapter. This ID is used as the inference component name when the adapter is deployed. The ID must start and end with an alphanumeric character, can contain hyphens between alphanumeric characters, and can be up to 63 characters long. + model_package_arn: The Amazon Resource Name (ARN) of the model package that contains the LoRA adapter artifacts. + """ + + adapter_id: StrPipeVar + model_package_arn: StrPipeVar + + +class AIAdapterS3Entry(Base): + """ + AIAdapterS3Entry + A LoRA adapter entry identified by an Amazon S3 URI. + + Attributes + ---------------------- + adapter_id: A unique identifier for the adapter. This ID is used as the inference component name when the adapter is deployed. The ID must start and end with an alphanumeric character, can contain hyphens between alphanumeric characters, and can be up to 63 characters long. + s3_uri: The Amazon S3 URI of the directory that contains the LoRA adapter artifacts in PEFT format. + """ + + adapter_id: StrPipeVar + s3_uri: StrPipeVar + + +class AIAdapterSource(Base): + """ + AIAdapterSource + The source of LoRA adapters for an AI recommendation job. This is a union type — specify exactly one of the members. + + Attributes + ---------------------- + model_package_arns: A list of LoRA adapters identified by their model package ARNs. Use this when your adapters were produced by a SageMaker AI fine-tuning workflow that registers model packages. + s3_uris: A list of LoRA adapters identified by their Amazon S3 URIs. Use this when your adapters are stored as raw artifacts in Amazon S3. + """ + + model_package_arns: Optional[List[AIAdapterModelPackageEntry]] = Unassigned() + s3_uris: Optional[List[AIAdapterS3Entry]] = Unassigned() + + class AIBenchmarkInferenceComponent(Base): """ AIBenchmarkInferenceComponent @@ -602,6 +660,23 @@ class AIBenchmarkNetworkConfig(Base): vpc_config: Optional[VpcConfig] = Unassigned() +class AIMlflowConfig(Base): + """ + AIMlflowConfig + The MLflow tracking configuration for logging metrics and parameters to a SageMaker managed MLflow tracking server. + + Attributes + ---------------------- + mlflow_resource_arn: The Amazon Resource Name (ARN) of the SageMaker managed MLflow resource. + mlflow_experiment_name: The MLflow experiment name used for tracking. + mlflow_run_name: The MLflow run name used for tracking. + """ + + mlflow_resource_arn: StrPipeVar + mlflow_experiment_name: Optional[StrPipeVar] = Unassigned() + mlflow_run_name: Optional[StrPipeVar] = Unassigned() + + class AIBenchmarkOutputConfig(Base): """ AIBenchmarkOutputConfig @@ -610,9 +685,11 @@ class AIBenchmarkOutputConfig(Base): Attributes ---------------------- s3_output_location: The Amazon S3 URI where benchmark results are stored. + mlflow_config: The MLflow tracking configuration for the job. If you don't specify this parameter, MLflow tracking is disabled. """ s3_output_location: StrPipeVar + mlflow_config: Optional[AIMlflowConfig] = Unassigned() class AICloudWatchLogs(Base): @@ -639,10 +716,12 @@ class AIBenchmarkOutputResult(Base): ---------------------- s3_output_location: The Amazon S3 URI where benchmark results are stored. cloud_watch_logs: The CloudWatch log information for the benchmark job. + mlflow_config: The MLflow tracking configuration for the job. """ s3_output_location: StrPipeVar cloud_watch_logs: Optional[List[AICloudWatchLogs]] = Unassigned() + mlflow_config: Optional[AIMlflowConfig] = Unassigned() class AIBenchmarkTarget(Base): @@ -830,6 +909,7 @@ class AIRecommendationDeploymentConfiguration(Base): instance_count: The recommended number of instances for the deployment. copy_count_per_instance: The number of model copies per instance. environment_variables: The environment variables for the deployment. + min_cpu_memory_required_in_mb: The minimum host (CPU) memory, in MiB, to reserve for each model copy when deploying the recommendation as an Inference Component. This value maps to the Inference Component's ComputeResourceRequirements$MinMemoryRequiredInMb field. """ s3: Optional[List[AIRecommendationDeploymentS3Channel]] = Unassigned() @@ -838,6 +918,7 @@ class AIRecommendationDeploymentConfiguration(Base): instance_count: Optional[int] = Unassigned() copy_count_per_instance: Optional[int] = Unassigned() environment_variables: Optional[Dict[StrPipeVar, StrPipeVar]] = Unassigned() + min_cpu_memory_required_in_mb: Optional[int] = Unassigned() class AIRecommendationPerformanceMetric(Base): @@ -859,6 +940,21 @@ class AIRecommendationPerformanceMetric(Base): unit: Optional[StrPipeVar] = Unassigned() +class AIRecommendationAdapterDetails(Base): + """ + AIRecommendationAdapterDetails + The per-recommendation LoRA adapter details. Contains both the model package ARNs and Amazon S3 URIs for each adapter, regardless of which form was originally supplied in the request. When you supply only Amazon S3 URIs, Amazon SageMaker AI creates model packages on your behalf. + + Attributes + ---------------------- + model_package_arns: The list of LoRA adapters with their model package ARNs. + s3_uris: The list of LoRA adapters with their Amazon S3 URIs. + """ + + model_package_arns: List[AIAdapterModelPackageEntry] + s3_uris: List[AIAdapterS3Entry] + + class AIRecommendation(Base): """ AIRecommendation @@ -872,6 +968,7 @@ class AIRecommendation(Base): deployment_configuration: The deployment configuration for this recommendation, including the container image, instance type, instance count, and environment variables. ai_benchmark_job_arn: The Amazon Resource Name (ARN) of the benchmark job associated with this recommendation. expected_performance: The expected performance metrics for this recommendation. + adapter_details: The LoRA adapter details for this recommendation. This field contains both the model package ARNs and Amazon S3 URIs for each adapter, regardless of which form was originally supplied. This field is absent when the job was created without LoRA adapters. """ recommendation_description: Optional[StrPipeVar] = Unassigned() @@ -880,6 +977,7 @@ class AIRecommendation(Base): deployment_configuration: Optional[AIRecommendationDeploymentConfiguration] = Unassigned() ai_benchmark_job_arn: Optional[StrPipeVar] = Unassigned() expected_performance: Optional[List[AIRecommendationPerformanceMetric]] = Unassigned() + adapter_details: Optional[AIRecommendationAdapterDetails] = Unassigned() class AIRecommendationComputeSpec(Base): @@ -953,10 +1051,12 @@ class AIRecommendationOutputConfig(Base): ---------------------- s3_output_location: The Amazon S3 URI where recommendation results are stored. model_package_group_identifier: The name or Amazon Resource Name (ARN) of the model package group where the optimized model is registered as a new model package version. + mlflow_config: The MLflow tracking configuration for the job. If you don't specify this parameter, MLflow tracking is disabled. """ s3_output_location: Optional[StrPipeVar] = Unassigned() model_package_group_identifier: Optional[StrPipeVar] = Unassigned() + mlflow_config: Optional[AIMlflowConfig] = Unassigned() class AIRecommendationOutputResult(Base): @@ -968,10 +1068,12 @@ class AIRecommendationOutputResult(Base): ---------------------- s3_output_location: The Amazon S3 URI where the recommendation job writes its output results. model_package_group_identifier: The name or Amazon Resource Name (ARN) of the model package group where deployment-ready model packages are registered. + mlflow_config: The MLflow tracking configuration for the job. """ s3_output_location: StrPipeVar model_package_group_identifier: Optional[StrPipeVar] = Unassigned() + mlflow_config: Optional[AIMlflowConfig] = Unassigned() class AIRecommendationPerformanceTarget(Base): @@ -1655,23 +1757,6 @@ class InstanceGroup(Base): instance_group_name: StrPipeVar -class InstancePreference(Base): - """ - InstancePreference - Defines a single candidate instance type in an ordered InstancePreferences list. When a training job specifies InstancePreferences, the platform tries each candidate type in list order and launches the job on the first type with available capacity. - - Attributes - ---------------------- - instance_type: The ML compute instance type for this candidate. - instance_count: The number of ML compute instances to use for this candidate. Optional; mutually exclusive with the uniform ResourceConfig.InstanceCount (either every preference sets its own count, or the uniform count is used for whichever type wins). - training_plan_arns: The training plan(s) to target for this candidate type. Optional; list is capped at 1. Training-only; mutually exclusive with the whole-job ResourceConfig.TrainingPlanArn. - """ - - instance_type: StrPipeVar - instance_count: Optional[IntPipeVar] = Unassigned() - training_plan_arns: Optional[List[StrPipeVar]] = Unassigned() - - class PlacementSpecification(Base): """ PlacementSpecification @@ -1702,6 +1787,23 @@ class InstancePlacementConfig(Base): placement_specifications: Optional[List[PlacementSpecification]] = Unassigned() +class InstancePreference(Base): + """ + InstancePreference + A candidate instance type preference in an InstancePreferences list. + + Attributes + ---------------------- + instance_type: The ML compute instance type. An instance type can appear only once in an InstancePreferences list. + instance_count: The number of instances to launch if this instance type is selected. Specify the instance count for the training job in one of the following two ways: Per preference – Set InstanceCount on every preference in the InstancePreferences list and don't set ResourceConfig$InstanceCount. Use this when each instance type needs a different number of instances to deliver equivalent compute. One count for the job – Set ResourceConfig$InstanceCount and omit it from every preference. SageMaker applies this to all instance types in the list. For example, in a list of five preferences, either all five specify InstanceCount or none of them do. SageMaker rejects requests that set InstanceCount on only some preferences, that set it both per preference and in ResourceConfig, or that omit it in both places. + training_plan_arns: The Amazon Resource Name (ARN) of a training plan to use if this instance type is selected. The plan's instance type must match InstanceType. A preference with a training plan uses that plan's reserved capacity; a preference without one uses on-demand capacity. Per-preference TrainingPlanArns is mutually exclusive with the job-level TrainingPlanArn in ResourceConfig. + """ + + instance_type: StrPipeVar + instance_count: Optional[IntPipeVar] = Unassigned() + training_plan_arns: Optional[List[StrPipeVar]] = Unassigned() + + class ResourceConfig(Base): """ ResourceConfig @@ -1717,9 +1819,9 @@ class ResourceConfig(Base): instance_groups: The configuration of a heterogeneous cluster in JSON format. training_plan_arn: The Amazon Resource Name (ARN); of the training plan to use for this resource configuration. instance_placement_config: Configuration for how training job instances are placed and allocated within UltraServers. Only applicable for UltraServer capacity. - instance_preferences: An ordered list of candidate instance types (max 5). When set, the platform tries each candidate in list order and launches the job on the first type with available capacity. Mutually exclusive with instance_type, instance_groups, and instance_placement_config. - selected_instance_type: The instance type the job was launched on when instance_preferences is used. Output-only (returned in DescribeTrainingJob); ignored on CreateTrainingJob. - selected_instance_count: The resolved number of instances the job was launched with when instance_preferences is used. Output-only (returned in DescribeTrainingJob); ignored on CreateTrainingJob. + instance_preferences: An ordered list of ML compute instance types for the training job, in priority order. SageMaker launches the training job on the first instance type in the list that has available capacity. If capacity is insufficient, SageMaker evaluates the next instance type in the preferred list. Exactly one instance type is selected for the job. InstancePreferences is mutually exclusive with InstanceType, InstanceGroups, InstancePlacementConfig, and EnableManagedSpotTraining, and supports only Flexible Training Plans (FTP) and On-Demand capacity. + selected_instance_type: The instance type that SageMaker selected for the job from the provided InstancePreferences. The job is billed for this instance type and count. Returned by DescribeTrainingJob after an instance type is selected. This field is read-only and isn't accepted in CreateTrainingJob requests. + selected_instance_count: The number of instances of SelectedInstanceType that the training job launched with. The job is billed for this instance type and count. Returned by DescribeTrainingJob after an instance type is selected. This field is read-only and isn't accepted in CreateTrainingJob requests. """ instance_type: Optional[StrPipeVar] = Unassigned() @@ -1744,7 +1846,7 @@ class StoppingCondition(Base): ---------------------- max_runtime_in_seconds: The maximum length of time, in seconds, that a training or compilation job can run before it is stopped. For compilation jobs, if the job does not complete during this time, a TimeOut error is generated. We recommend starting with 900 seconds and increasing as necessary based on your model. For all other jobs, if the job does not complete during this time, SageMaker ends the job. When RetryStrategy is specified in the job request, MaxRuntimeInSeconds specifies the maximum time for all of the attempts in total, not each individual attempt. The default value is 1 day. The maximum value is 28 days. The maximum time that a TrainingJob can run in total, including any time spent publishing metrics or archiving and uploading models after it has been stopped, is 30 days. max_wait_time_in_seconds: The maximum length of time, in seconds, that a managed Spot training job has to complete. It is the amount of time spent waiting for Spot capacity plus the amount of time the job can run. It must be equal to or greater than MaxRuntimeInSeconds. If the job does not complete during this time, SageMaker ends the job. When RetryStrategy is specified in the job request, MaxWaitTimeInSeconds specifies the maximum time for all of the attempts in total, not each individual attempt. - max_pending_time_in_seconds: The maximum length of time, in seconds, that a training or compilation job can be pending before it is stopped. When working with training jobs that use capacity from training plans, not all Pending job states count against the MaxPendingTimeInSeconds limit. The following scenarios do not increment the MaxPendingTimeInSeconds counter: The plan is in a Scheduled state: Jobs queued (in Pending status) before a plan's start date (waiting for scheduled start time) Between capacity reservations: Jobs temporarily back to Pending status between two capacity reservation periods MaxPendingTimeInSeconds only increments when jobs are actively waiting for capacity in an Active plan. + max_pending_time_in_seconds: The maximum length of time, in seconds, that a training or compilation job can be pending before it is stopped. When working with training jobs that use capacity from training plans, not all Pending job states count against the MaxPendingTimeInSeconds limit. The following scenarios do not increment the MaxPendingTimeInSeconds counter: The plan is in a Scheduled state: Jobs queued (in Pending status) before a plan's start date (waiting for scheduled start time) Between capacity reservations: Jobs temporarily back to Pending status between two capacity reservation periods MaxPendingTimeInSeconds only increments when jobs are actively waiting for capacity in an Active plan. MaxPendingTimeInSeconds takes effect only for jobs that request accelerated computing instance types, such as instances in the ml.p, ml.g, and ml.trn families. It has no effect on jobs that request CPU-only instance types. If the job specifies InstancePreferences, MaxPendingTimeInSeconds bounds the total time SageMaker spends working through your list of instance types. It is not applied per instance type preference, and takes effect only when the list includes at least one accelerated computing instance type. """ max_runtime_in_seconds: Optional[int] = Unassigned() @@ -3586,6 +3688,23 @@ class Bias(Base): post_training_report: Optional[MetricsSource] = Unassigned() +class BillableTokenUsage(Base): + """ + BillableTokenUsage + The billable token usage for a training session, broken down by operation type. + + Attributes + ---------------------- + prefill_token_count: The number of prefill tokens consumed. + sample_token_count: The number of sample tokens consumed. + training_token_count: The number of training tokens consumed. + """ + + prefill_token_count: Optional[int] = Unassigned() + sample_token_count: Optional[int] = Unassigned() + training_token_count: Optional[int] = Unassigned() + + class CapacitySize(Base): """ CapacitySize @@ -4213,6 +4332,119 @@ class ClarifyExplainerConfig(Base): inference_config: Optional[ClarifyInferenceConfig] = Unassigned() +class ClusterAccountingDatabase(Base): + """ + ClusterAccountingDatabase + The external MySQL-compatible database that the Slurm accounting daemon (slurmdbd) connects to for a SageMaker HyperPod cluster. You provide the database credentials in an Amazon Web Services Secrets Manager secret instead of in the request. + + Attributes + ---------------------- + endpoint: The hostname or endpoint of the accounting database, such as the endpoint of an Amazon RDS for MySQL or Aurora MySQL database. The database must be reachable from the subnets and security groups that you configure for the cluster. + port: The port that the accounting database listens on. The default is 3306. + name: The name of the database schema that stores the Slurm accounting data. The default is slurm_acct_db_ followed by the cluster ID from the cluster ARN, for example slurm_acct_db_a1b2c3d4e5f6. + secret_arn: The Amazon Resource Name (ARN) of the Amazon Web Services Secrets Manager secret that contains the user name and password for the accounting database. The database user must be able to create the schema and to read from and write to it. + """ + + endpoint: StrPipeVar + secret_arn: StrPipeVar + port: Optional[int] = Unassigned() + name: Optional[StrPipeVar] = Unassigned() + + +class ClusterPatchSchedule(Base): + """ + ClusterPatchSchedule + The schedule configuration for automatic patching. + + Attributes + ---------------------- + next_patch_date: The date and time of the next scheduled automatic patch. The system sets this automatically when a patch is detected. Use this field to reschedule the patch to a different date. + """ + + next_patch_date: Optional[datetime.datetime] = Unassigned() + + +class RollingDeploymentPolicy(Base): + """ + RollingDeploymentPolicy + The configurations that SageMaker uses when updating the AMI versions. + + Attributes + ---------------------- + maximum_batch_size: The maximum amount of instances in the cluster that SageMaker can update at a time. + rollback_maximum_batch_size: The maximum amount of instances in the cluster that SageMaker can roll back at a time. + """ + + maximum_batch_size: CapacitySizeConfig + rollback_maximum_batch_size: Optional[CapacitySizeConfig] = Unassigned() + + +class DeploymentConfiguration(Base): + """ + DeploymentConfiguration + The configuration to use when updating the AMI versions. + + Attributes + ---------------------- + rolling_update_policy: The policy that SageMaker uses when updating the AMI versions of the cluster. + wait_interval_in_seconds: The duration in seconds that SageMaker waits before updating more instances in the cluster. + auto_rollback_configuration: An array that contains the alarms that SageMaker monitors to know whether to roll back the AMI update. + """ + + rolling_update_policy: Optional[RollingDeploymentPolicy] = Unassigned() + wait_interval_in_seconds: Optional[int] = Unassigned() + auto_rollback_configuration: Optional[List[AlarmDetails]] = Unassigned() + + +class ClusterAutoPatchConfig(Base): + """ + ClusterAutoPatchConfig + The configuration for automatic patching of the instance group. When configured, the system automatically applies security patch AMI updates to the instance group. + + Attributes + ---------------------- + patching_strategy: The strategy for applying patches to instances in the group. WhenIdle: Cordons all instances and patches each instance as it becomes idle (no running jobs). Each instance is uncordoned immediately after patching and becomes available for new jobs. If instances do not become idle, they remain on the previous AMI version. You can then use UpdateClusterSoftware with the desired ImageReleaseVersion to manually update the remaining instances. WhenAllIdle: Cordons all instances and waits for all to become idle before patching. All instances are uncordoned after patching completes. If not all instances become idle, no patching occurs and all instances remain on the previous AMI version. + patch_schedule: The schedule for automatic patching, including the next patch date. + deployment_config: The deployment configuration for rolling patch updates, including rollback settings and batch sizes. Only applicable when using a rolling patching strategy. + """ + + patching_strategy: StrPipeVar + patch_schedule: Optional[ClusterPatchSchedule] = Unassigned() + deployment_config: Optional[DeploymentConfiguration] = Unassigned() + + +class ClusterPatchScheduleDetails(Base): + """ + ClusterPatchScheduleDetails + The schedule details for automatic patching, including the next scheduled patch date. + + Attributes + ---------------------- + next_patch_date: The date and time of the next scheduled automatic patch. + """ + + next_patch_date: Optional[datetime.datetime] = Unassigned() + + +class ClusterAutoPatchConfigDetails(Base): + """ + ClusterAutoPatchConfigDetails + The auto-patching configuration details for the instance group, including the patching strategy and schedule. + + Attributes + ---------------------- + patching_strategy: The strategy used for applying patches to instances in the group. WhenIdle: Cordons all instances and patches each instance as it becomes idle (no running jobs). Each instance is uncordoned immediately after patching and becomes available for new jobs. If instances do not become idle, they remain on the previous AMI version. You can then use UpdateClusterSoftware with the desired ImageReleaseVersion to manually update the remaining instances. WhenAllIdle: Cordons all instances and waits for all to become idle before patching. All instances are uncordoned after patching completes. If not all instances become idle, no patching occurs and all instances remain on the previous AMI version. + current_patch_schedule: The currently active patch schedule that the system will execute. + desired_patch_schedule: The requested patch schedule. Differs from CurrentPatchSchedule when a reschedule request is pending. + deployment_config: The deployment configuration for rolling patch updates. + """ + + patching_strategy: Optional[StrPipeVar] = Unassigned() + current_patch_schedule: Optional[ClusterPatchScheduleDetails] = Unassigned() + desired_patch_schedule: Optional[ClusterPatchScheduleDetails] = Unassigned() + deployment_config: Optional[DeploymentConfiguration] = Unassigned() + + class ClusterAutoScalingConfig(Base): """ ClusterAutoScalingConfig @@ -4400,6 +4632,40 @@ class InstanceMetadata(Base): node_logical_id: Optional[StrPipeVar] = Unassigned() +class DatabaseConfigurationMetadata(Base): + """ + DatabaseConfigurationMetadata + Metadata information about a change to the external Slurm accounting database of a HyperPod cluster. + + Attributes + ---------------------- + rollback_status: Whether HyperPod restored the previous accounting database configuration after the change failed. Valid values: NotApplicable: The change failed before HyperPod modified the cluster, for example because the database could not be reached or rejected the credentials, so there was nothing to restore. Reverted: The change failed after it was applied, and HyperPod restored the previous configuration. The cluster continues to use the previous accounting database. RevertFailed: The change failed and HyperPod could not restore the previous configuration, so Slurm accounting on the cluster might not be working. This field is omitted when the change succeeds. + advisory: Additional information about a change that succeeded, such as an action to take on the cluster. + failure_message: An error message describing why the accounting database change failed, and how to resolve it. + """ + + rollback_status: Optional[StrPipeVar] = Unassigned() + advisory: Optional[StrPipeVar] = Unassigned() + failure_message: Optional[StrPipeVar] = Unassigned() + + +class SlurmHealthMetadata(Base): + """ + SlurmHealthMetadata + Metadata information about the health of a Slurm component on the controller node of a HyperPod cluster. + + Attributes + ---------------------- + component: The Slurm component that the health information describes. The valid value is Slurmdbd, the Slurm accounting daemon. + status: The health of the component. Valid values are Healthy and Unhealthy. + reason: The reason the component is unhealthy. Valid values: DaemonDown: The daemon is not running, so job accounting records are not being written. DaemonDisabled: The daemon is running and its accounting database is responding, but the daemon is not enabled to start automatically. Job accounting stops the next time the controller node restarts. DbUnreachable: The daemon is running, but its accounting database did not respond. Job accounting records might not be written. This field is omitted when the component is healthy. + """ + + component: StrPipeVar + status: StrPipeVar + reason: Optional[StrPipeVar] = Unassigned() + + class EventMetadata(Base): """ EventMetadata @@ -4411,12 +4677,16 @@ class EventMetadata(Base): instance_group: Metadata specific to instance group-level events. instance_group_scaling: Metadata related to instance group scaling events. instance: Metadata specific to instance-level events. + database_configuration: Metadata specific to events about the external Slurm accounting database of the cluster. + slurm_health: Metadata specific to events about the health of the Slurm components on the controller node of the cluster. """ cluster: Optional[ClusterMetadata] = Unassigned() instance_group: Optional[InstanceGroupMetadata] = Unassigned() instance_group_scaling: Optional[InstanceGroupScalingMetadata] = Unassigned() instance: Optional[InstanceMetadata] = Unassigned() + database_configuration: Optional[DatabaseConfigurationMetadata] = Unassigned() + slurm_health: Optional[SlurmHealthMetadata] = Unassigned() class EventDetails(Base): @@ -4590,38 +4860,6 @@ class ClusterInstanceStorageConfig(Base): fsx_open_zfs_config: Optional[ClusterFsxOpenZfsConfig] = Unassigned() -class RollingDeploymentPolicy(Base): - """ - RollingDeploymentPolicy - The configurations that SageMaker uses when updating the AMI versions. - - Attributes - ---------------------- - maximum_batch_size: The maximum amount of instances in the cluster that SageMaker can update at a time. - rollback_maximum_batch_size: The maximum amount of instances in the cluster that SageMaker can roll back at a time. - """ - - maximum_batch_size: CapacitySizeConfig - rollback_maximum_batch_size: Optional[CapacitySizeConfig] = Unassigned() - - -class DeploymentConfiguration(Base): - """ - DeploymentConfiguration - The configuration to use when updating the AMI versions. - - Attributes - ---------------------- - rolling_update_policy: The policy that SageMaker uses when updating the AMI versions of the cluster. - wait_interval_in_seconds: The duration in seconds that SageMaker waits before updating more instances in the cluster. - auto_rollback_configuration: An array that contains the alarms that SageMaker monitors to know whether to roll back the AMI update. - """ - - rolling_update_policy: Optional[RollingDeploymentPolicy] = Unassigned() - wait_interval_in_seconds: Optional[int] = Unassigned() - auto_rollback_configuration: Optional[List[AlarmDetails]] = Unassigned() - - class ScheduledUpdateConfig(Base): """ ScheduledUpdateConfig @@ -4725,8 +4963,11 @@ class ClusterInstanceGroupDetails(Base): training_plan_status: The current status of the training plan associated with this cluster instance group. override_vpc_config: The customized Amazon VPC configuration at the instance group level that overrides the default Amazon VPC configuration of the SageMaker HyperPod cluster. scheduled_update_config: The configuration object of the schedule that SageMaker follows when updating the AMI. + auto_patch_config: The auto-patching configuration for the instance group, including the current patching strategy and next scheduled patch date. current_image_id: The ID of the Amazon Machine Image (AMI) currently in use by the instance group. desired_image_id: The ID of the Amazon Machine Image (AMI) desired for the instance group. + current_image_release_version: The version of the HyperPod-managed AMI currently running on the instance group. + desired_image_release_version: The desired version of the HyperPod-managed AMI for the instance group. This may differ from the current version when an update is pending. image_version_status: The status of the image version for the instance group. Indicates whether the instance group is running the latest image version or if an update is available. active_operations: A map indicating active operations currently in progress for the instance group of a SageMaker HyperPod cluster. When there is a scaling operation in progress, this map contains a key Scaling with value 1. kubernetes_config: The Kubernetes configuration for the instance group that contains labels and taints to be applied for the nodes in this instance group. @@ -4755,8 +4996,11 @@ class ClusterInstanceGroupDetails(Base): training_plan_status: Optional[StrPipeVar] = Unassigned() override_vpc_config: Optional[VpcConfig] = Unassigned() scheduled_update_config: Optional[ScheduledUpdateConfig] = Unassigned() + auto_patch_config: Optional[ClusterAutoPatchConfigDetails] = Unassigned() current_image_id: Optional[StrPipeVar] = Unassigned() desired_image_id: Optional[StrPipeVar] = Unassigned() + current_image_release_version: Optional[StrPipeVar] = Unassigned() + desired_image_release_version: Optional[StrPipeVar] = Unassigned() image_version_status: Optional[StrPipeVar] = Unassigned() active_operations: Optional[Dict[StrPipeVar, int]] = Unassigned() kubernetes_config: Optional[ClusterKubernetesConfigDetails] = Unassigned() @@ -4844,7 +5088,9 @@ class ClusterInstanceGroupSpecification(Base): training_plan_arn: The Amazon Resource Name (ARN); of the training plan to use for this cluster instance group. For more information about how to reserve GPU capacity for your SageMaker HyperPod clusters using Amazon SageMaker Training Plan, see CreateTrainingPlan . override_vpc_config: To configure multi-AZ deployments, customize the Amazon VPC configuration at the instance group level. You can specify different subnets and security groups across different AZs in the instance group specification to override a SageMaker HyperPod cluster's default Amazon VPC configuration. For more information about deploying a cluster in multiple AZs, see Setting up SageMaker HyperPod clusters across multiple AZs. When your Amazon VPC and subnets support IPv6, network communications differ based on the cluster orchestration platform: Slurm-orchestrated clusters automatically configure nodes with dual IPv6 and IPv4 addresses, allowing immediate IPv6 network communications. In Amazon EKS-orchestrated clusters, nodes receive dual-stack addressing, but pods can only use IPv6 when the Amazon EKS cluster is explicitly IPv6-enabled. For information about deploying an IPv6 Amazon EKS cluster, see Amazon EKS IPv6 Cluster Deployment. Additional resources for IPv6 configuration: For information about adding IPv6 support to your VPC, see to IPv6 Support for VPC. For information about creating a new IPv6-compatible VPC, see Amazon VPC Creation Guide. To configure SageMaker HyperPod with a custom Amazon VPC, see Custom Amazon VPC Setup for SageMaker HyperPod. scheduled_update_config: The configuration object of the schedule that SageMaker uses to update the AMI. - image_id: When configuring your HyperPod cluster, you can specify an image ID using one of the following options: HyperPodPublicAmiId: Use a HyperPod public AMI CustomAmiId: Use your custom AMI default: Use the default latest system image If you choose to use a custom AMI (CustomAmiId), ensure it meets the following requirements: Encryption: The custom AMI must be unencrypted. Ownership: The custom AMI must be owned by the same Amazon Web Services account that is creating the HyperPod cluster. Volume support: Only the primary AMI snapshot volume is supported; additional AMI volumes are not supported. When updating the instance group's AMI through the UpdateClusterSoftware operation, if an instance group uses a custom AMI, you must provide an ImageId or use the default as input. Note that if you don't specify an instance group in your UpdateClusterSoftware request, then all of the instance groups are patched with the specified image. + image_id: When configuring your HyperPod cluster, you can specify an image ID using one of the following options: HyperPodPublicAmiId: Use a HyperPod public AMI CustomAmiId: Use your custom AMI default: Use the default latest system image. For clusters with continuous scaling node provisioning mode, new instance groups inherit the AMI from the earliest existing instance group If you choose to use a custom AMI (CustomAmiId), ensure it meets the following requirements: Encryption: The custom AMI must be unencrypted. Ownership: The custom AMI must be owned by the same Amazon Web Services account that is creating the HyperPod cluster. Volume support: Only the primary AMI snapshot volume is supported; additional AMI volumes are not supported. When updating the instance group's AMI through the UpdateClusterSoftware operation, if an instance group uses a custom AMI, you must provide an ImageId or use the default as input. Note that if you don't specify an instance group in your UpdateClusterSoftware request, then all of the instance groups are patched with the specified image. + auto_patch_config: The configuration for automatic OS security patching. If present, the system automatically applies PATCH AMI updates to this instance group. + image_release_version: The version of the HyperPod-managed AMI to use for the instance group. Uses semantic versioning in the format MAJOR.MINOR.PATCH (for example, 1.2.3). If omitted, the latest available version is used. kubernetes_config: Specifies the Kubernetes configuration for the instance group. You describe what you want the labels and taints to look like, and the cluster works to reconcile the actual state with the declared state for nodes in this instance group. slurm_config: Specifies the Slurm configuration for the instance group. capacity_requirements: Specifies the capacity requirements for the instance group. @@ -4865,6 +5111,8 @@ class ClusterInstanceGroupSpecification(Base): override_vpc_config: Optional[VpcConfig] = Unassigned() scheduled_update_config: Optional[ScheduledUpdateConfig] = Unassigned() image_id: Optional[StrPipeVar] = Unassigned() + auto_patch_config: Optional[ClusterAutoPatchConfig] = Unassigned() + image_release_version: Optional[StrPipeVar] = Unassigned() kubernetes_config: Optional[ClusterKubernetesConfig] = Unassigned() slurm_config: Optional[ClusterSlurmConfig] = Unassigned() capacity_requirements: Optional[ClusterCapacityRequirements] = Unassigned() @@ -4959,6 +5207,8 @@ class ClusterNodeDetails(Base): placement: The placement details of the SageMaker HyperPod cluster node. current_image_id: The ID of the Amazon Machine Image (AMI) currently in use by the node. desired_image_id: The ID of the Amazon Machine Image (AMI) desired for the node. + current_image_release_version: The version of the HyperPod-managed AMI currently running on the node. + desired_image_release_version: The desired version of the HyperPod-managed AMI for the node. This may differ from the current version when an update is pending. image_version_status: The status of the image version for the cluster node. ultra_server_info: Contains information about the UltraServer. kubernetes_config: The Kubernetes configuration applied to this node, showing both the current and desired state of labels and taints. The cluster works to reconcile the actual state with the declared state. @@ -4983,6 +5233,8 @@ class ClusterNodeDetails(Base): placement: Optional[ClusterInstancePlacement] = Unassigned() current_image_id: Optional[StrPipeVar] = Unassigned() desired_image_id: Optional[StrPipeVar] = Unassigned() + current_image_release_version: Optional[StrPipeVar] = Unassigned() + desired_image_release_version: Optional[StrPipeVar] = Unassigned() image_version_status: Optional[StrPipeVar] = Unassigned() ultra_server_info: Optional[UltraServerInfo] = Unassigned() kubernetes_config: Optional[ClusterKubernetesConfigNodeDetails] = Unassigned() @@ -5006,6 +5258,7 @@ class ClusterNodeSummary(Base): instance_status: The status of the instance. ultra_server_info: Contains information about the UltraServer. private_dns_hostname: The private DNS hostname of the SageMaker HyperPod cluster node. + current_image_release_version: The version of the HyperPod-managed AMI currently running on the node. image_version_status: The status of the image version for the cluster node. """ @@ -5018,6 +5271,7 @@ class ClusterNodeSummary(Base): last_software_update_time: Optional[datetime.datetime] = Unassigned() ultra_server_info: Optional[UltraServerInfo] = Unassigned() private_dns_hostname: Optional[StrPipeVar] = Unassigned() + current_image_release_version: Optional[StrPipeVar] = Unassigned() image_version_status: Optional[StrPipeVar] = Unassigned() @@ -5042,9 +5296,11 @@ class ClusterOrchestratorSlurmConfig(Base): Attributes ---------------------- slurm_config_strategy: The strategy for managing partitions for the Slurm configuration. Valid values are Managed, Overwrite, and Merge. + accounting_database: The external database that stores the Slurm accounting data for the cluster, such as job history, associations, and usage. When you omit this field, Slurm accounting uses a database on the cluster's controller node. This field is only supported for clusters using Continuous as the NodeProvisioningMode. """ slurm_config_strategy: Optional[StrPipeVar] = Unassigned() + accounting_database: Optional[ClusterAccountingDatabase] = Unassigned() class ClusterOrchestrator(Base): @@ -5276,6 +5532,7 @@ class ClusterSummary(Base): creation_time: The time when the SageMaker HyperPod cluster is created. cluster_status: The status of the SageMaker HyperPod cluster. training_plan_arns: A list of Amazon Resource Names (ARNs) of the training plans associated with this cluster. For more information about how to reserve GPU capacity for your SageMaker HyperPod clusters using Amazon SageMaker Training Plan, see CreateTrainingPlan . + image_version_status: The aggregate status of the image version across the cluster's instance groups. """ cluster_arn: StrPipeVar @@ -5283,6 +5540,7 @@ class ClusterSummary(Base): creation_time: datetime.datetime cluster_status: StrPipeVar training_plan_arns: Optional[List[StrPipeVar]] = Unassigned() + image_version_status: Optional[StrPipeVar] = Unassigned() class ClusterTieredStorageConfig(Base): @@ -5613,19 +5871,6 @@ class ConditionStepMetadata(Base): outcome: Optional[StrPipeVar] = Unassigned() -class ConflictException(Base): - """ - ConflictException - There was a conflict when you attempted to modify a SageMaker entity such as an Experiment or Artifact. - - Attributes - ---------------------- - message - """ - - message: Optional[StrPipeVar] = Unassigned() - - class RepositoryAuthConfig(Base): """ RepositoryAuthConfig @@ -5667,6 +5912,34 @@ class MultiModelConfig(Base): model_cache_setting: Optional[StrPipeVar] = Unassigned() +class MetricsEndpoint(Base): + """ + MetricsEndpoint + Specifies a metrics endpoint for a container, including the path where the container exposes Prometheus-formatted metrics and the frequency at which to publish them to Amazon CloudWatch. + + Attributes + ---------------------- + metrics_endpoint_path: The path to the metrics endpoint exposed by the container. For example, /metrics or /server/metrics. The path must start with / and can contain alphanumeric characters, forward slashes, underscores, hyphens, and periods. Maximum length is 256 characters. If not specified, defaults to /metrics. + metric_publish_frequency_in_seconds: The interval, in seconds, at which container metrics scraped from the endpoint are published to Amazon CloudWatch. Valid values: 10, 30, 60, 120, 180, 240, 300. Defaults to 60. + """ + + metrics_endpoint_path: StrPipeVar + metric_publish_frequency_in_seconds: Optional[int] = Unassigned() + + +class ContainerMetricsConfig(Base): + """ + ContainerMetricsConfig + The configuration for container-level metrics scraping. Use this configuration to specify a custom metrics endpoint path and publishing frequency for container metrics. When EnableDetailedObservability is set to True in MetricsConfig, metrics are scraped from the container's Prometheus endpoint. If this configuration is not provided, the default path /metrics on port 8080 is used with a default publishing frequency of 60 seconds. For first-party and Deep Learning Containers (DLC), the endpoint path is determined automatically and this configuration is optional. + + Attributes + ---------------------- + metrics_endpoints: A list of metrics endpoints to scrape from the container. Each endpoint specifies the path where the container exposes Prometheus-formatted metrics and the frequency at which to publish them. You can specify a maximum of 1 endpoint. + """ + + metrics_endpoints: Optional[List[MetricsEndpoint]] = Unassigned() + + class ContainerDefinition(Base): """ ContainerDefinition @@ -5685,6 +5958,7 @@ class ContainerDefinition(Base): model_package_name: The name or Amazon Resource Name (ARN) of the model package to use to create the model. inference_specification_name: The inference specification name in the model package version. multi_model_config: Specifies additional configuration for multi-model endpoints. + container_metrics_config: The configuration for container metrics scraping. Specifies the metrics endpoint path and publishing frequency. If not specified when EnableDetailedObservability is True, the default path /metrics on port 8080 is used. For first-party and Deep Learning Containers (DLC), the endpoint path is determined automatically and this configuration is optional. """ container_hostname: Optional[StrPipeVar] = Unassigned() @@ -5698,6 +5972,7 @@ class ContainerDefinition(Base): model_package_name: Optional[Union[StrPipeVar, object]] = Unassigned() inference_specification_name: Optional[StrPipeVar] = Unassigned() multi_model_config: Optional[MultiModelConfig] = Unassigned() + container_metrics_config: Optional[ContainerMetricsConfig] = Unassigned() class ContextSource(Base): @@ -6877,6 +7152,21 @@ class ProductionVariantManagedInstanceScaling(Base): scale_in_policy: Optional[ProductionVariantManagedInstanceScalingScaleInPolicy] = Unassigned() +class PrefixAwareRoutingConfig(Base): + """ + PrefixAwareRoutingConfig + The configuration for prefix-aware routing on a SageMaker real-time inference endpoint. Specify PrefixLength and ConcurrencyThreshold to control routing behavior. + + Attributes + ---------------------- + prefix_length: The maximum length of the prefix used for routing decisions. Required when RoutingStrategy is PREFIX_AWARE. For the SageMaker Runtime InvokeEndpoint and InvokeEndpointWithResponseStream APIs, this value specifies the number of bytes from the beginning of the request body. For OpenAI-compatible API, this value specifies the number of characters from the text content of the messages array. The endpoint routes requests that share the same prefix to the same instance. Set this value to cover shared content (such as system prompts) plus enough unique content to distribute workloads across instances. + concurrency_threshold: The maximum number of in-flight requests on the target instance before the endpoint routes to another instance. Required when RoutingStrategy is PREFIX_AWARE. When in-flight requests on the prefix-selected instance reach this threshold, the endpoint routes the request to an instance with more available capacity. + """ + + prefix_length: Optional[int] = Unassigned() + concurrency_threshold: Optional[int] = Unassigned() + + class ProductionVariantRoutingConfig(Base): """ ProductionVariantRoutingConfig @@ -6884,10 +7174,12 @@ class ProductionVariantRoutingConfig(Base): Attributes ---------------------- - routing_strategy: Sets how the endpoint routes incoming traffic: LEAST_OUTSTANDING_REQUESTS: The endpoint routes requests to the specific instances that have more capacity to process them. RANDOM: The endpoint routes each request to a randomly chosen instance. + routing_strategy: Sets how the endpoint routes incoming traffic: LEAST_OUTSTANDING_REQUESTS: The endpoint routes requests to the specific instances that have more capacity to process them. RANDOM: The endpoint routes each request to a randomly chosen instance. PREFIX_AWARE: The endpoint routes requests that share the same prompt prefix to the same instance. When the number of in-flight requests on the selected instance reaches the configured threshold, the endpoint routes the request to an instance with more available capacity. + prefix_aware_routing_config: The configuration for prefix-aware routing. Specify this parameter only when you set RoutingStrategy to PREFIX_AWARE. """ routing_strategy: StrPipeVar + prefix_aware_routing_config: Optional[PrefixAwareRoutingConfig] = Unassigned() class ProductionVariantCapacityReservationConfig(Base): @@ -6996,10 +7288,12 @@ class MetricsConfig(Base): Attributes ---------------------- enable_enhanced_metrics: Specifies whether to enable enhanced metrics for the endpoint. Enhanced metrics provide utilization and invocation data at instance and container granularity. Container granularity is supported for Inference Components. The default is False. - metric_publish_frequency_in_seconds: The interval, in seconds, at which metrics are published to Amazon CloudWatch. Defaults to 60. Valid values: 10, 30, 60, 120, 180, 240, 300. When EnableEnhancedMetrics is set to False, this interval applies to utilization metrics only; invocation metrics continue to be published at the default 60-second interval. When EnableEnhancedMetrics is set to True, this interval applies to both utilization and invocation metrics. + enable_detailed_observability: Indicates whether detailed observability is enabled for the endpoint. When set to True, the following metrics are published at the configured frequency: Container-level inference metrics scraped from the container's Prometheus endpoint (such as request latency, error counts, and throughput). Available metrics vary by framework. Per-GPU metrics (utilization, memory, and temperature) attributed to individual inference components. Per-instance host metrics (CPU, memory, and disk utilization). Inference component placement metrics (copy count per Availability Zone). For first-party and Deep Learning Containers (DLC), the Prometheus endpoint path is determined automatically. For Bring-Your-Own-Container (BYOC) cases, you can optionally set ContainerMetricsConfig to specify a custom endpoint path. If not specified, the default path /metrics on port 8080 is used. When set to False, these additional metrics are not published. Standard invocation and utilization metrics controlled by EnableEnhancedMetrics are unaffected. The default value for new endpoint configurations is True. For existing endpoint configurations created before this feature, the value is False unless explicitly set. + metric_publish_frequency_in_seconds: The interval, in seconds, at which metrics are published to Amazon CloudWatch. Defaults to 60. Valid values: 10, 30, 60, 120, 180, 240, 300. When EnableEnhancedMetrics is set to False, this interval applies to utilization metrics only. Invocation metrics continue to be published at the default 60-second interval. When EnableEnhancedMetrics is set to True, this interval applies to both utilization and invocation metrics. When EnableDetailedObservability is set to True, this interval applies to per-GPU metrics, per-instance host metrics, container metrics, and fleet-level inference component lifecycle and placement metrics. """ enable_enhanced_metrics: Optional[bool] = Unassigned() + enable_detailed_observability: Optional[bool] = Unassigned() metric_publish_frequency_in_seconds: Optional[int] = Unassigned() @@ -7081,7 +7375,7 @@ class OnlineStoreConfig(Base): security_config: Use to specify KMS Key ID (KMSKeyId) for at-rest encryption of your OnlineStore. enable_online_store: Turn OnlineStore off by specifying False for the EnableOnlineStore flag. Turn OnlineStore on by specifying True for the EnableOnlineStore flag. The default value is False. ttl_duration: Time to live duration, where the record is hard deleted after the expiration time is reached; ExpiresAt = EventTime + TtlDuration. For information on HardDelete, see the DeleteRecord API in the Amazon SageMaker API Reference guide. - storage_type: Option for different tiers of low latency storage for real-time data retrieval. Standard: A managed low latency data store for feature groups. InMemory: A managed data store for feature groups that supports very low latency retrieval. + storage_type: Option for different tiers of low latency storage for real-time data retrieval. Standard: A managed low latency data store for feature groups. Standard_V2: A managed low latency data store for feature groups that supports partial updates to individual features using the UpdateRecord operation. Choose this storage type at feature group creation time if your use case requires updating specific feature values without rewriting the entire record. InMemory: A managed data store for feature groups that supports very low latency retrieval. """ security_config: Optional[OnlineStoreSecurityConfig] = Unassigned() @@ -7600,11 +7894,13 @@ class InferenceComponentContainerSpecification(Base): image: The Amazon Elastic Container Registry (Amazon ECR) path where the Docker image for the model is stored. artifact_url: The Amazon S3 path where the model artifacts, which result from model training, are stored. This path must point to a single gzip compressed tar archive (.tar.gz suffix). environment: 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. + container_metrics_config: The configuration for container metrics scraping. Specifies the metrics endpoint path and publishing frequency for the inference component's container. If not specified when EnableDetailedObservability is True, the default path /metrics on port 8080 is used. For first-party and Deep Learning Containers (DLC), the endpoint path is determined automatically and this configuration is optional. """ image: Optional[StrPipeVar] = Unassigned() artifact_url: Optional[StrPipeVar] = Unassigned() environment: Optional[Dict[StrPipeVar, StrPipeVar]] = Unassigned() + container_metrics_config: Optional[ContainerMetricsConfig] = Unassigned() class InferenceComponentStartupParameters(Base): @@ -9156,6 +9452,19 @@ class PartnerAppConfig(Base): role_group_assignments: Optional[List[RoleGroupAssignment]] = Unassigned() +class IdcConfigInput(Base): + """ + IdcConfigInput + Specifies the Amazon Web Services IAM Identity Center configuration to use for a SageMaker Partner AI App that uses IDC authorization. + + Attributes + ---------------------- + instance_arn: The ARN of the Amazon Web Services IAM Identity Center instance that the SageMaker Partner AI App uses to authenticate users. + """ + + instance_arn: StrPipeVar + + class PipelineDefinitionS3Location(Base): """ PipelineDefinitionS3Location @@ -9345,12 +9654,12 @@ class ProcessingOutputConfig(Base): class ProcessingInstancePreference(Base): """ ProcessingInstancePreference - Defines a single candidate instance type in an ordered InstancePreferences list for a processing job. When a processing job specifies InstancePreferences, the platform tries each candidate type in list order and launches the job on the first type with available capacity. Per-type training plans are training-only and do not apply to processing. + A candidate instance type preference in a processing InstancePreferences list. Attributes ---------------------- - instance_type: The ML compute instance type for this candidate. - instance_count: The number of ML compute instances to use for this candidate. Optional; mutually exclusive with the uniform ProcessingClusterConfig.InstanceCount (either every preference sets its own count, or the uniform count is used for whichever type wins). + instance_type: The ML compute instance type. An instance type can appear only once in an InstancePreferences list. + instance_count: The number of instances to launch if this instance type is selected. Specify the instance count for the processing job in one of the following two ways: Per preference – Set InstanceCount on every preference in the InstancePreferences list and don't set ProcessingClusterConfig$InstanceCount. Use this when each instance type needs a different number of instances to deliver equivalent compute. One count for the job – Set ProcessingClusterConfig$InstanceCount and omit it from every preference. Amazon SageMaker applies this to all instance types in the list. For example, in a list of five preferences, either all five specify InstanceCount or none of them do. Amazon SageMaker rejects requests that set InstanceCount on only some preferences, that set it both per preference and in ProcessingClusterConfig, or that omit it in both places. """ instance_type: StrPipeVar @@ -9368,14 +9677,14 @@ class ProcessingClusterConfig(Base): instance_type: The ML compute instance type for the processing job. volume_size_in_gb: The size of the ML storage volume in gigabytes that you want to provision. You must specify sufficient ML storage for your scenario. Certain Nitro-based instances include local storage with a fixed total size, dependent on the instance type. When using these instances for processing, Amazon SageMaker mounts the local instance storage instead of Amazon EBS gp2 storage. You can't request a VolumeSizeInGB greater than the total size of the local instance storage. For a list of instance types that support local instance storage, including the total size per instance type, see Instance Store Volumes. volume_kms_key_id: The Amazon Web Services Key Management Service (Amazon Web Services KMS) key that Amazon SageMaker uses to encrypt data on the storage volume attached to the ML compute instance(s) that run the processing job. Certain Nitro-based instances include local storage, dependent on the instance type. Local storage volumes are encrypted using a hardware module on the instance. You can't request a VolumeKmsKeyId when using an instance type with local storage. For a list of instance types that support local instance storage, see Instance Store Volumes. For more information about local instance storage encryption, see SSD Instance Store Volumes. - instance_preferences: An ordered list of candidate instance types (max 5). When set, the platform tries each candidate in list order and launches the job on the first type with available capacity. Mutually exclusive with instance_type/instance_count. - selected_instance_type: The instance type the job was launched on when instance_preferences is used. Output-only (returned in DescribeProcessingJob); ignored on CreateProcessingJob. - selected_instance_count: The resolved number of instances the job was launched with when instance_preferences is used. Output-only (returned in DescribeProcessingJob); ignored on CreateProcessingJob. + instance_preferences: An ordered list of ML compute instance types for the processing job, in priority order. Amazon SageMaker launches the job on the first instance type in the list that has available capacity. If capacity is insufficient, Amazon SageMaker evaluates the next instance type in the list. Exactly one instance type is selected for the job. InstancePreferences is mutually exclusive with InstanceType. + selected_instance_type: The instance type that Amazon SageMaker selected for the job from InstancePreferences. Returned by DescribeProcessingJob after an instance type is selected. This field is read-only and isn't accepted in CreateProcessingJob requests. + selected_instance_count: The number of instances of SelectedInstanceType that the job launched with. The job is billed for this instance type and count. Returned by DescribeProcessingJob after an instance type is selected. This field is read-only and isn't accepted in CreateProcessingJob requests. """ + volume_size_in_gb: int instance_count: Optional[IntPipeVar] = Unassigned() instance_type: Optional[StrPipeVar] = Unassigned() - volume_size_in_gb: int volume_kms_key_id: Optional[StrPipeVar] = Unassigned() instance_preferences: Optional[List[ProcessingInstancePreference]] = Unassigned() selected_instance_type: Optional[StrPipeVar] = Unassigned() @@ -9825,7 +10134,7 @@ class ServerlessJobConfig(Base): peft: The parameter-efficient fine-tuning configuration. evaluation_type: The evaluation job type. Required when serverless job type is Evaluation. evaluator_arn: The evaluator Amazon Resource Name (ARN) used as reward function or reward prompt. - sequence_length: The sequence length for the training job. + sequence_length: The maximum sequence length, in tokens, that the customization job supports. SageMaker uses this value to select a training configuration for the base model that you specify. The parameter supports the following values: 1K 2K 4K 8K 16K 32K 64K 128K If you don't specify a value, SageMaker selects a training configuration based on the other values that you specify. The selection is not restricted to a particular sequence length. """ base_model_arn: StrPipeVar @@ -9870,6 +10179,64 @@ class ModelPackageConfig(Base): source_model_package_arn: Optional[StrPipeVar] = Unassigned() +class LoraConfig(Base): + """ + LoraConfig + The Low-Rank Adaptation (LoRA) configuration for a training session, including the rank and alpha parameters. + + Attributes + ---------------------- + rank: The rank of the Low-Rank Adaptation (LoRA) adapter matrices. + alpha: The Low-Rank Adaptation (LoRA) scaling factor. + """ + + rank: int + alpha: int + + +class TrainingSessionModelConfig(Base): + """ + TrainingSessionModelConfig + The configuration for the base model used in a training session. + + Attributes + ---------------------- + base_model_arn: The Amazon Resource Name (ARN) of the base foundation model from SageMaker Hub. + accept_eula: Specifies whether you accept the end-user license agreement (EULA) for gated models. + """ + + base_model_arn: StrPipeVar + accept_eula: Optional[bool] = Unassigned() + + +class TrainingSessionS3Location(Base): + """ + TrainingSessionS3Location + Specifies the Amazon S3 path and optional encryption settings for training session output data, including checkpoints, model artifacts, and invocation results. + + Attributes + ---------------------- + path: The Amazon S3 path where training session outputs are stored. + kms_key_arn: The Amazon Resource Name (ARN) of the KMS key used to encrypt output data. If not specified, the default Amazon S3 encryption is used. + """ + + path: StrPipeVar + kms_key_arn: Optional[StrPipeVar] = Unassigned() + + +class TrainingSessionOutputConfig(Base): + """ + TrainingSessionOutputConfig + The output configuration for a training session, including the Amazon S3 location for checkpoints and model artifacts, and optional encryption settings. + + Attributes + ---------------------- + s3_location: The Amazon S3 location where training session outputs, including checkpoints and model artifacts, are stored. + """ + + s3_location: TrainingSessionS3Location + + class ModelClientConfig(Base): """ ModelClientConfig @@ -10015,9 +10382,7 @@ class OidcMemberDefinition(Base): Attributes ---------------------- - groups: A list of comma-separated strings that identifies user groups in your OIDC IdP. Each user group is made up of a group of private workers. - group - member_definition_id + groups: A list of comma seperated strings that identifies user groups in your OIDC IdP. Each user group is made up of a group of private workers. """ groups: Optional[List[StrPipeVar]] = Unassigned() @@ -10772,11 +11137,13 @@ class InferenceComponentContainerSpecificationSummary(Base): deployed_image artifact_url: The Amazon S3 path where the model artifacts are stored. environment: The environment variables to set in the Docker container. + container_metrics_config: The container metrics scraping configuration for this inference component, including the metrics endpoint path and publishing frequency. """ deployed_image: Optional[DeployedImage] = Unassigned() artifact_url: Optional[StrPipeVar] = Unassigned() environment: Optional[Dict[StrPipeVar, StrPipeVar]] = Unassigned() + container_metrics_config: Optional[ContainerMetricsConfig] = Unassigned() class InferenceComponentDataCacheConfigSummary(Base): @@ -11232,6 +11599,21 @@ class ErrorInfo(Base): reason: Optional[StrPipeVar] = Unassigned() +class IdcConfigOutput(Base): + """ + IdcConfigOutput + Contains the Amazon Web Services IAM Identity Center configuration of a SageMaker Partner AI App that uses IDC authorization. + + Attributes + ---------------------- + instance_arn: The ARN of the Amazon Web Services IAM Identity Center instance that the SageMaker Partner AI App uses to authenticate users. + application_arn: The ARN of the Amazon Web Services IAM Identity Center application that SageMaker creates for the SageMaker Partner AI App. + """ + + instance_arn: StrPipeVar + application_arn: Optional[StrPipeVar] = Unassigned() + + class DescribePipelineDefinitionForExecutionResponse(Base): """ DescribePipelineDefinitionForExecutionResponse @@ -11552,6 +11934,49 @@ class ReservedCapacitySummary(Base): end_time: Optional[datetime.datetime] = Unassigned() +class TrainingSessionDetail(Base): + """ + TrainingSessionDetail + Contains detailed information about a training session. + + Attributes + ---------------------- + training_session_arn: The Amazon Resource Name (ARN) of the training session. + training_session_name: The name of the training session. + training_session_status: The current status of the training session. + model_package_group_arn: The Amazon Resource Name (ARN) of the model package group where checkpoints are published. + creation_time: The date and time that the training session was created. + last_modified_time: The date and time that the training session was last modified. + end_time: The date and time that the training session ended. + error_details: If the training session failed or is blocked, detailed error information. + last_received_sequence_number: The sequence number of the last training operation received by the session. + billable_token_usage: The billable token usage for the training session. + vpc_config: The Virtual Private Cloud (VPC) configuration for the training session. + role_arn: The Amazon Resource Name (ARN) of the IAM role associated with the training session. + lora_config: The Low-Rank Adaptation (LoRA) configuration for the training session. + model_config: The configuration for the base model. + output_config: The output configuration for the training session. + tags: The tags associated with the training session. + """ + + training_session_arn: StrPipeVar + training_session_name: Union[StrPipeVar, object] + training_session_status: StrPipeVar + creation_time: datetime.datetime + model_package_group_arn: Optional[StrPipeVar] = Unassigned() + last_modified_time: Optional[datetime.datetime] = Unassigned() + end_time: Optional[datetime.datetime] = Unassigned() + error_details: Optional[StrPipeVar] = Unassigned() + last_received_sequence_number: Optional[int] = Unassigned() + billable_token_usage: Optional[BillableTokenUsage] = Unassigned() + vpc_config: Optional[VpcConfig] = Unassigned() + role_arn: Optional[StrPipeVar] = Unassigned() + lora_config: Optional[LoraConfig] = Unassigned() + model_config: Optional[TrainingSessionModelConfig] = Unassigned() + output_config: Optional[TrainingSessionOutputConfig] = Unassigned() + tags: Optional[List[Tag]] = Unassigned() + + class TrialComponentSource(Base): """ TrialComponentSource @@ -12604,6 +13029,59 @@ class GitConfigForUpdate(Base): secret_arn: Optional[StrPipeVar] = Unassigned() +class HubContent(Base): + """ + HubContent + Contains information about a hub content resource, including its name, version, type, associated documents, dependencies, and status, as returned by a search result. + + Attributes + ---------------------- + hub_content_name: The name of the hub content. + hub_content_arn: The Amazon Resource Name (ARN) of the hub content. + hub_content_version: The version of the hub content. + hub_content_type: The type of hub content. + document_schema_version: The document schema version for the hub content. + hub_name: The name of the hub that contains the content. + hub_arn: The Amazon Resource Name (ARN) of the hub that contains the content. + hub_content_display_name: The display name of the hub content. + hub_content_description: A description of the hub content. + hub_content_markdown: A string that provides a description of the hub content. This string can include links, tables, and standard markdown formatting. + hub_content_document: The hub content document that describes information about the hub content such as type, associated containers, scripts, and more. + sage_maker_public_hub_content_arn: The Amazon Resource Name (ARN) of the public hub content. + reference_min_version: The minimum version of the hub content. + support_status: The support status of the hub content. + hub_content_search_keywords: The searchable keywords for the hub content. + hub_content_dependencies: The location of any dependencies that the hub content has, such as scripts, model artifacts, datasets, or notebooks. + hub_content_status: The status of the hub content. + failure_reason: The failure reason if importing hub content failed. + creation_time: The date and time that hub content was created. + last_modified_time: The last modified time of the hub content. + tags: Any tags associated with the hub content. + """ + + hub_content_name: Union[StrPipeVar, object] + hub_content_arn: StrPipeVar + hub_content_version: StrPipeVar + hub_content_type: StrPipeVar + document_schema_version: StrPipeVar + hub_name: Union[StrPipeVar, object] + hub_arn: StrPipeVar + hub_content_status: StrPipeVar + creation_time: datetime.datetime + hub_content_display_name: Optional[StrPipeVar] = Unassigned() + hub_content_description: Optional[StrPipeVar] = Unassigned() + hub_content_markdown: Optional[StrPipeVar] = Unassigned() + hub_content_document: Optional[StrPipeVar] = Unassigned() + sage_maker_public_hub_content_arn: Optional[StrPipeVar] = Unassigned() + reference_min_version: Optional[StrPipeVar] = Unassigned() + support_status: Optional[StrPipeVar] = Unassigned() + hub_content_search_keywords: Optional[List[StrPipeVar]] = Unassigned() + hub_content_dependencies: Optional[List[HubContentDependency]] = Unassigned() + failure_reason: Optional[StrPipeVar] = Unassigned() + last_modified_time: Optional[datetime.datetime] = Unassigned() + tags: Optional[List[Tag]] = Unassigned() + + class HubContentInfo(Base): """ HubContentInfo @@ -12984,6 +13462,45 @@ class InstanceGroupHealthCheckConfiguration(Base): instance_ids: Optional[List[StrPipeVar]] = Unassigned() +class Job(Base): + """ + Job + The properties of a job returned by the Search API. + + Attributes + ---------------------- + job_name: The name of the job. + job_arn: The Amazon Resource Name (ARN) of the job. + role_arn: The ARN of the IAM role associated with the job. + job_category: The category of the job. + job_config_schema_version: The schema version used for the job configuration document. + job_config_document: The JSON configuration document for the job. + creation_time: The date and time that the job was created. + last_modified_time: The date and time that the job was last modified. + end_time: The date and time that the job ended. + job_status: The current status of the job. + secondary_status: The detailed secondary status of the job, providing more granular information about the job's progress. + secondary_status_transitions: A list of secondary status transitions for the job, with timestamps and optional status messages. + failure_reason: If the job failed, the reason it failed. + tags: The tags associated with the job. + """ + + job_name: Optional[Union[StrPipeVar, object]] = Unassigned() + job_arn: Optional[StrPipeVar] = Unassigned() + role_arn: Optional[StrPipeVar] = Unassigned() + job_category: Optional[StrPipeVar] = Unassigned() + job_config_schema_version: Optional[StrPipeVar] = Unassigned() + job_config_document: Optional[StrPipeVar] = Unassigned() + creation_time: Optional[datetime.datetime] = Unassigned() + last_modified_time: Optional[datetime.datetime] = Unassigned() + end_time: Optional[datetime.datetime] = Unassigned() + job_status: Optional[StrPipeVar] = Unassigned() + secondary_status: Optional[StrPipeVar] = Unassigned() + secondary_status_transitions: Optional[List[JobSecondaryStatusTransition]] = Unassigned() + failure_reason: Optional[StrPipeVar] = Unassigned() + tags: Optional[List[Tag]] = Unassigned() + + class JobConfigSchemaVersionSummary(Base): """ JobConfigSchemaVersionSummary @@ -14173,6 +14690,25 @@ class TrainingPlanSummary(Base): reserved_capacity_summaries: Optional[List[ReservedCapacitySummary]] = Unassigned() +class TrainingSessionSummary(Base): + """ + TrainingSessionSummary + Contains summary information about a training session. + + Attributes + ---------------------- + training_session_arn: The Amazon Resource Name (ARN) of the training session. + training_session_status: The current status of the training session. + creation_time: The date and time that the training session was created. + last_modified_time: The date and time that the training session was last modified. + """ + + training_session_arn: StrPipeVar + training_session_status: StrPipeVar + creation_time: datetime.datetime + last_modified_time: Optional[datetime.datetime] = Unassigned() + + class TransformJobSummary(Base): """ TransformJobSummary @@ -15340,6 +15876,8 @@ class SearchRecord(Base): hyper_parameter_tuning_job: The properties of a hyperparameter tuning job. model_card: An Amazon SageMaker Model Card that documents details about a machine learning model. model + job: The properties of a job. + hub_content: The properties of a hub content resource. """ training_job: Optional[TrainingJob] = Unassigned() @@ -15358,6 +15896,8 @@ class SearchRecord(Base): hyper_parameter_tuning_job: Optional[HyperParameterTuningJobSearchEntity] = Unassigned() model_card: Optional[ModelCard] = Unassigned() model: Optional[ModelDashboardModel] = Unassigned() + job: Optional[Job] = Unassigned() + hub_content: Optional[HubContent] = Unassigned() class VisibilityConditions(Base): @@ -15484,9 +16024,11 @@ class UpdateClusterSoftwareInstanceGroupSpecification(Base): Attributes ---------------------- instance_group_name: The name of the instance group to update. + image_release_version: The version of the HyperPod-managed AMI to update to for the instance group. Uses semantic versioning in the format MAJOR.MINOR.PATCH. """ instance_group_name: StrPipeVar + image_release_version: Optional[StrPipeVar] = Unassigned() class VariantProperty(Base): diff --git a/sagemaker-core/src/sagemaker/core/tools/resources_codegen.py b/sagemaker-core/src/sagemaker/core/tools/resources_codegen.py index 27b5ccea8c..22428f3006 100644 --- a/sagemaker-core/src/sagemaker/core/tools/resources_codegen.py +++ b/sagemaker-core/src/sagemaker/core/tools/resources_codegen.py @@ -522,6 +522,14 @@ def _get_class_attributes(self, resource_name: str, class_methods: list) -> tupl if resource_name == "SubscribedWorkteam": class_attributes["workteam_arn"] = "StrPipeVar" class_attributes_string = "workteam_arn: StrPipeVar\n" + class_attributes_string + # TrainingSession differs slightly: its identifier IS in the describe + # response, but nested inside the single TrainingSessionDetail member, + # so it is not hoisted onto the class either. + if resource_name == "TrainingSession": + class_attributes["training_session_name"] = "StrPipeVar" + class_attributes_string = ( + "training_session_name: StrPipeVar\n" + class_attributes_string + ) if resource_name == "HubContent": class_attributes["hub_name"] = "Optional[str] = Unassigned()" diff --git a/sagemaker-core/src/sagemaker/core/utils/code_injection/shape_dag.py b/sagemaker-core/src/sagemaker/core/utils/code_injection/shape_dag.py index e25de8034f..331c3e5616 100644 --- a/sagemaker-core/src/sagemaker/core/utils/code_injection/shape_dag.py +++ b/sagemaker-core/src/sagemaker/core/utils/code_injection/shape_dag.py @@ -1,6 +1,37 @@ """Generated shape dependency graph used for serialization.""" SHAPE_DAG = { + "AIAdapterModelPackageEntry": { + "members": [ + {"name": "AdapterId", "shape": "AIAdapterId", "type": "string"}, + {"name": "ModelPackageArn", "shape": "ModelPackageArn", "type": "string"}, + ], + "type": "structure", + }, + "AIAdapterModelPackageEntryList": { + "member_shape": "AIAdapterModelPackageEntry", + "member_type": "structure", + "type": "list", + }, + "AIAdapterS3Entry": { + "members": [ + {"name": "AdapterId", "shape": "AIAdapterId", "type": "string"}, + {"name": "S3Uri", "shape": "S3Uri", "type": "string"}, + ], + "type": "structure", + }, + "AIAdapterS3EntryList": { + "member_shape": "AIAdapterS3Entry", + "member_type": "structure", + "type": "list", + }, + "AIAdapterSource": { + "members": [ + {"name": "ModelPackageArns", "shape": "AIAdapterModelPackageEntryList", "type": "list"}, + {"name": "S3Uris", "shape": "AIAdapterS3EntryList", "type": "list"}, + ], + "type": "structure", + }, "AIBenchmarkEndpoint": { "members": [ {"name": "Identifier", "shape": "AIResourceIdentifier", "type": "string"}, @@ -43,13 +74,17 @@ "type": "structure", }, "AIBenchmarkOutputConfig": { - "members": [{"name": "S3OutputLocation", "shape": "S3Uri", "type": "string"}], + "members": [ + {"name": "S3OutputLocation", "shape": "S3Uri", "type": "string"}, + {"name": "MlflowConfig", "shape": "AIMlflowConfig", "type": "structure"}, + ], "type": "structure", }, "AIBenchmarkOutputResult": { "members": [ {"name": "S3OutputLocation", "shape": "S3Uri", "type": "string"}, {"name": "CloudWatchLogs", "shape": "AICloudWatchLogsList", "type": "list"}, + {"name": "MlflowConfig", "shape": "AIMlflowConfig", "type": "structure"}, ], "type": "structure", }, @@ -91,6 +126,14 @@ "member_type": "string", "type": "list", }, + "AIMlflowConfig": { + "members": [ + {"name": "MlflowResourceArn", "shape": "AIMlflowResourceArn", "type": "string"}, + {"name": "MlflowExperimentName", "shape": "AIMlflowExperimentName", "type": "string"}, + {"name": "MlflowRunName", "shape": "AIMlflowRunName", "type": "string"}, + ], + "type": "structure", + }, "AIModelSource": { "members": [{"name": "S3", "shape": "AIModelSourceS3", "type": "structure"}], "type": "structure", @@ -115,6 +158,18 @@ }, {"name": "AIBenchmarkJobArn", "shape": "AIBenchmarkJobArn", "type": "string"}, {"name": "ExpectedPerformance", "shape": "ExpectedPerformanceList", "type": "list"}, + { + "name": "AdapterDetails", + "shape": "AIRecommendationAdapterDetails", + "type": "structure", + }, + ], + "type": "structure", + }, + "AIRecommendationAdapterDetails": { + "members": [ + {"name": "ModelPackageArns", "shape": "AIAdapterModelPackageEntryList", "type": "list"}, + {"name": "S3Uris", "shape": "AIAdapterS3EntryList", "type": "list"}, ], "type": "structure", }, @@ -150,6 +205,11 @@ "type": "integer", }, {"name": "EnvironmentVariables", "shape": "EnvironmentMap", "type": "map"}, + { + "name": "MinCpuMemoryRequiredInMb", + "shape": "AIRecommendationMinCpuMemoryRequiredInMb", + "type": "integer", + }, ], "type": "structure", }, @@ -268,6 +328,7 @@ "shape": "AIResourceIdentifier", "type": "string", }, + {"name": "MlflowConfig", "shape": "AIMlflowConfig", "type": "structure"}, ], "type": "structure", }, @@ -279,6 +340,7 @@ "shape": "AIResourceIdentifier", "type": "string", }, + {"name": "MlflowConfig", "shape": "AIMlflowConfig", "type": "structure"}, ], "type": "structure", }, @@ -808,6 +870,27 @@ ], "type": "structure", }, + "AttachClusterNodeNetworkInterfaceRequest": { + "members": [ + {"name": "ClusterName", "shape": "ClusterNameOrArn", "type": "string"}, + {"name": "NodeId", "shape": "ClusterNodeId", "type": "string"}, + {"name": "NetworkInterfaceId", "shape": "ClusterNetworkInterfaceId", "type": "string"}, + ], + "type": "structure", + }, + "AttachClusterNodeNetworkInterfaceResponse": { + "members": [ + {"name": "ClusterArn", "shape": "ClusterArn", "type": "string"}, + {"name": "NodeId", "shape": "ClusterNodeId", "type": "string"}, + {"name": "NetworkInterfaceId", "shape": "ClusterNetworkInterfaceId", "type": "string"}, + { + "name": "AttachmentId", + "shape": "ClusterNetworkInterfaceAttachmentId", + "type": "string", + }, + ], + "type": "structure", + }, "AttachClusterNodeVolumeRequest": { "members": [ {"name": "ClusterArn", "shape": "ClusterArn", "type": "string"}, @@ -1678,6 +1761,14 @@ ], "type": "structure", }, + "BillableTokenUsage": { + "members": [ + {"name": "PrefillTokenCount", "shape": "JavaLong", "type": "long"}, + {"name": "SampleTokenCount", "shape": "JavaLong", "type": "long"}, + {"name": "TrainingTokenCount", "shape": "JavaLong", "type": "long"}, + ], + "type": "structure", + }, "BlueGreenUpdatePolicy": { "members": [ { @@ -2041,6 +2132,40 @@ ], "type": "structure", }, + "ClusterAccountingDatabase": { + "members": [ + {"name": "Endpoint", "shape": "ClusterAccountingDatabaseEndpoint", "type": "string"}, + {"name": "Port", "shape": "ClusterAccountingDatabasePort", "type": "integer"}, + {"name": "Name", "shape": "ClusterAccountingDatabaseName", "type": "string"}, + {"name": "SecretArn", "shape": "ClusterAccountingDatabaseSecretArn", "type": "string"}, + ], + "type": "structure", + }, + "ClusterAutoPatchConfig": { + "members": [ + {"name": "PatchingStrategy", "shape": "ClusterPatchingStrategy", "type": "string"}, + {"name": "PatchSchedule", "shape": "ClusterPatchSchedule", "type": "structure"}, + {"name": "DeploymentConfig", "shape": "DeploymentConfiguration", "type": "structure"}, + ], + "type": "structure", + }, + "ClusterAutoPatchConfigDetails": { + "members": [ + {"name": "PatchingStrategy", "shape": "ClusterPatchingStrategy", "type": "string"}, + { + "name": "CurrentPatchSchedule", + "shape": "ClusterPatchScheduleDetails", + "type": "structure", + }, + { + "name": "DesiredPatchSchedule", + "shape": "ClusterPatchScheduleDetails", + "type": "structure", + }, + {"name": "DeploymentConfig", "shape": "DeploymentConfiguration", "type": "structure"}, + ], + "type": "structure", + }, "ClusterAutoScalingConfig": { "members": [ {"name": "Mode", "shape": "ClusterAutoScalingMode", "type": "string"}, @@ -2161,8 +2286,23 @@ "shape": "ScheduledUpdateConfig", "type": "structure", }, + { + "name": "AutoPatchConfig", + "shape": "ClusterAutoPatchConfigDetails", + "type": "structure", + }, {"name": "CurrentImageId", "shape": "ImageId", "type": "string"}, {"name": "DesiredImageId", "shape": "ImageId", "type": "string"}, + { + "name": "CurrentImageReleaseVersion", + "shape": "ImageReleaseVersion", + "type": "string", + }, + { + "name": "DesiredImageReleaseVersion", + "shape": "ImageReleaseVersion", + "type": "string", + }, {"name": "ImageVersionStatus", "shape": "ClusterImageVersionStatus", "type": "string"}, {"name": "ActiveOperations", "shape": "ActiveOperations", "type": "map"}, { @@ -2224,6 +2364,8 @@ "type": "structure", }, {"name": "ImageId", "shape": "ImageId", "type": "string"}, + {"name": "AutoPatchConfig", "shape": "ClusterAutoPatchConfig", "type": "structure"}, + {"name": "ImageReleaseVersion", "shape": "ImageReleaseVersion", "type": "string"}, {"name": "KubernetesConfig", "shape": "ClusterKubernetesConfig", "type": "structure"}, {"name": "SlurmConfig", "shape": "ClusterSlurmConfig", "type": "structure"}, { @@ -2397,6 +2539,16 @@ {"name": "Placement", "shape": "ClusterInstancePlacement", "type": "structure"}, {"name": "CurrentImageId", "shape": "ImageId", "type": "string"}, {"name": "DesiredImageId", "shape": "ImageId", "type": "string"}, + { + "name": "CurrentImageReleaseVersion", + "shape": "ImageReleaseVersion", + "type": "string", + }, + { + "name": "DesiredImageReleaseVersion", + "shape": "ImageReleaseVersion", + "type": "string", + }, {"name": "ImageVersionStatus", "shape": "ClusterImageVersionStatus", "type": "string"}, {"name": "UltraServerInfo", "shape": "UltraServerInfo", "type": "structure"}, { @@ -2439,6 +2591,11 @@ }, {"name": "UltraServerInfo", "shape": "UltraServerInfo", "type": "structure"}, {"name": "PrivateDnsHostname", "shape": "ClusterPrivateDnsHostname", "type": "string"}, + { + "name": "CurrentImageReleaseVersion", + "shape": "ImageReleaseVersion", + "type": "string", + }, {"name": "ImageVersionStatus", "shape": "ClusterImageVersionStatus", "type": "string"}, ], "type": "structure", @@ -2457,7 +2614,16 @@ }, "ClusterOrchestratorSlurmConfig": { "members": [ - {"name": "SlurmConfigStrategy", "shape": "ClusterSlurmConfigStrategy", "type": "string"} + { + "name": "SlurmConfigStrategy", + "shape": "ClusterSlurmConfigStrategy", + "type": "string", + }, + { + "name": "AccountingDatabase", + "shape": "ClusterAccountingDatabase", + "type": "structure", + }, ], "type": "structure", }, @@ -2466,6 +2632,14 @@ "member_type": "string", "type": "list", }, + "ClusterPatchSchedule": { + "members": [{"name": "NextPatchDate", "shape": "Timestamp", "type": "timestamp"}], + "type": "structure", + }, + "ClusterPatchScheduleDetails": { + "members": [{"name": "NextPatchDate", "shape": "Timestamp", "type": "timestamp"}], + "type": "structure", + }, "ClusterRestrictedInstanceGroupDetails": { "members": [ {"name": "CurrentCount", "shape": "ClusterNonNegativeInstanceCount", "type": "integer"}, @@ -2632,6 +2806,7 @@ {"name": "CreationTime", "shape": "Timestamp", "type": "timestamp"}, {"name": "ClusterStatus", "shape": "ClusterStatus", "type": "string"}, {"name": "TrainingPlanArns", "shape": "TrainingPlanArns", "type": "list"}, + {"name": "ImageVersionStatus", "shape": "ClusterImageVersionStatus", "type": "string"}, ], "type": "structure", }, @@ -2885,6 +3060,11 @@ "type": "string", }, {"name": "MultiModelConfig", "shape": "MultiModelConfig", "type": "structure"}, + { + "name": "ContainerMetricsConfig", + "shape": "ContainerMetricsConfig", + "type": "structure", + }, ], "type": "structure", }, @@ -2898,6 +3078,10 @@ "member_type": "string", "type": "list", }, + "ContainerMetricsConfig": { + "members": [{"name": "MetricsEndpoints", "shape": "MetricsEndpointList", "type": "list"}], + "type": "structure", + }, "ContentClassifiers": { "member_shape": "ContentClassifier", "member_type": "string", @@ -3002,6 +3186,7 @@ "type": "boolean", }, {"name": "ComputeSpec", "shape": "AIRecommendationComputeSpec", "type": "structure"}, + {"name": "AdapterSource", "shape": "AIAdapterSource", "type": "structure"}, {"name": "Tags", "shape": "TagList", "type": "list"}, ], "type": "structure", @@ -3786,6 +3971,7 @@ {"name": "Name", "shape": "MlflowAppName", "type": "string"}, {"name": "ArtifactStoreUri", "shape": "S3Uri", "type": "string"}, {"name": "RoleArn", "shape": "RoleArn", "type": "string"}, + {"name": "KmsKeyId", "shape": "KmsKeyId", "type": "string"}, {"name": "ModelRegistrationMode", "shape": "ModelRegistrationMode", "type": "string"}, { "name": "WeeklyMaintenanceWindowStart", @@ -4177,6 +4363,11 @@ {"name": "StoppingCondition", "shape": "StoppingCondition", "type": "structure"}, {"name": "Tags", "shape": "TagList", "type": "list"}, {"name": "VpcConfig", "shape": "OptimizationVpcConfig", "type": "structure"}, + { + "name": "TrainingPlanArns", + "shape": "OptimizationJobTrainingPlanArns", + "type": "list", + }, ], "type": "structure", }, @@ -4215,6 +4406,7 @@ }, {"name": "Tier", "shape": "NonEmptyString64", "type": "string"}, {"name": "ApplicationConfig", "shape": "PartnerAppConfig", "type": "structure"}, + {"name": "IdcConfig", "shape": "IdcConfigInput", "type": "structure"}, {"name": "AuthType", "shape": "PartnerAppAuthType", "type": "string"}, {"name": "EnableIamSessionBasedIdentity", "shape": "Boolean", "type": "boolean"}, {"name": "EnableAutoMinorVersionUpgrade", "shape": "Boolean", "type": "boolean"}, @@ -4504,6 +4696,25 @@ "members": [{"name": "TrainingPlanArn", "shape": "TrainingPlanArn", "type": "string"}], "type": "structure", }, + "CreateTrainingSessionRequest": { + "members": [ + {"name": "TrainingSessionName", "shape": "TrainingSessionName", "type": "string"}, + {"name": "ModelPackageGroupArn", "shape": "ModelPackageGroupArn", "type": "string"}, + {"name": "LoraConfig", "shape": "LoraConfig", "type": "structure"}, + {"name": "RoleArn", "shape": "RoleArn", "type": "string"}, + {"name": "VpcConfig", "shape": "VpcConfig", "type": "structure"}, + {"name": "ModelConfig", "shape": "TrainingSessionModelConfig", "type": "structure"}, + {"name": "OutputConfig", "shape": "TrainingSessionOutputConfig", "type": "structure"}, + {"name": "Tags", "shape": "TagList", "type": "list"}, + ], + "type": "structure", + }, + "CreateTrainingSessionResponse": { + "members": [ + {"name": "TrainingSessionArn", "shape": "TrainingSessionArn", "type": "string"} + ], + "type": "structure", + }, "CreateTransformJobRequest": { "members": [ {"name": "TransformJobName", "shape": "TransformJobName", "type": "string"}, @@ -4794,6 +5005,18 @@ ], "type": "structure", }, + "DatabaseConfigurationMetadata": { + "members": [ + { + "name": "RollbackStatus", + "shape": "DatabaseConfigurationRollbackStatus", + "type": "string", + }, + {"name": "Advisory", "shape": "String", "type": "string"}, + {"name": "FailureMessage", "shape": "String", "type": "string"}, + ], + "type": "structure", + }, "DatasetDefinition": { "members": [ { @@ -5331,6 +5554,13 @@ "members": [{"name": "TrainingJobName", "shape": "TrainingJobName", "type": "string"}], "type": "structure", }, + "DeleteTrainingSessionRequest": { + "members": [ + {"name": "TrainingSessionName", "shape": "TrainingSessionName", "type": "string"} + ], + "type": "structure", + }, + "DeleteTrainingSessionResponse": {"members": [], "type": "structure"}, "DeleteTrialComponentRequest": { "members": [ {"name": "TrialComponentName", "shape": "ExperimentEntityName", "type": "string"} @@ -5534,6 +5764,7 @@ {"name": "Recommendations", "shape": "AIRecommendationList", "type": "list"}, {"name": "RoleArn", "shape": "RoleArn", "type": "string"}, {"name": "ComputeSpec", "shape": "AIRecommendationComputeSpec", "type": "structure"}, + {"name": "AdapterSource", "shape": "AIAdapterSource", "type": "structure"}, {"name": "CreationTime", "shape": "Timestamp", "type": "timestamp"}, {"name": "StartTime", "shape": "Timestamp", "type": "timestamp"}, {"name": "EndTime", "shape": "Timestamp", "type": "timestamp"}, @@ -6755,6 +6986,7 @@ {"name": "ArtifactStoreUri", "shape": "S3Uri", "type": "string"}, {"name": "MlflowVersion", "shape": "MlflowVersion", "type": "string"}, {"name": "RoleArn", "shape": "RoleArn", "type": "string"}, + {"name": "KmsKeyId", "shape": "KmsKeyId", "type": "string"}, {"name": "Status", "shape": "MlflowAppStatus", "type": "string"}, {"name": "ModelRegistrationMode", "shape": "ModelRegistrationMode", "type": "string"}, {"name": "AccountDefaultStatus", "shape": "AccountDefaultStatus", "type": "string"}, @@ -6872,6 +7104,7 @@ "members": [ {"name": "ModelCardName", "shape": "ModelCardNameOrArn", "type": "string"}, {"name": "ModelCardVersion", "shape": "Integer", "type": "integer"}, + {"name": "IncludedData", "shape": "IncludedData", "type": "string"}, ], "type": "structure", }, @@ -6989,7 +7222,10 @@ "type": "structure", }, "DescribeModelPackageInput": { - "members": [{"name": "ModelPackageName", "shape": "VersionedArnOrName", "type": "string"}], + "members": [ + {"name": "ModelPackageName", "shape": "VersionedArnOrName", "type": "string"}, + {"name": "IncludedData", "shape": "IncludedData", "type": "string"}, + ], "type": "structure", }, "DescribeModelPackageOutput": { @@ -7239,6 +7475,11 @@ {"name": "RoleArn", "shape": "RoleArn", "type": "string"}, {"name": "StoppingCondition", "shape": "StoppingCondition", "type": "structure"}, {"name": "VpcConfig", "shape": "OptimizationVpcConfig", "type": "structure"}, + { + "name": "TrainingPlanArns", + "shape": "OptimizationJobTrainingPlanArns", + "type": "list", + }, ], "type": "structure", }, @@ -7274,6 +7515,7 @@ {"name": "EnableAutoMinorVersionUpgrade", "shape": "Boolean", "type": "boolean"}, {"name": "CurrentVersionEolDate", "shape": "Timestamp", "type": "timestamp"}, {"name": "AvailableUpgrade", "shape": "AvailableUpgrade", "type": "structure"}, + {"name": "IdcConfig", "shape": "IdcConfigOutput", "type": "structure"}, ], "type": "structure", }, @@ -7653,7 +7895,9 @@ "type": "structure", }, "DescribeTrainingPlanRequest": { - "members": [{"name": "TrainingPlanName", "shape": "TrainingPlanName", "type": "string"}], + "members": [ + {"name": "TrainingPlanName", "shape": "TrainingPlanNameOrArn", "type": "string"} + ], "type": "structure", }, "DescribeTrainingPlanResponse": { @@ -7695,6 +7939,18 @@ ], "type": "structure", }, + "DescribeTrainingSessionRequest": { + "members": [ + {"name": "TrainingSessionName", "shape": "TrainingSessionName", "type": "string"} + ], + "type": "structure", + }, + "DescribeTrainingSessionResponse": { + "members": [ + {"name": "TrainingSessionDetail", "shape": "TrainingSessionDetail", "type": "structure"} + ], + "type": "structure", + }, "DescribeTransformJobRequest": { "members": [{"name": "TransformJobName", "shape": "TransformJobName", "type": "string"}], "type": "structure", @@ -8494,6 +8750,12 @@ "type": "structure", }, {"name": "Instance", "shape": "InstanceMetadata", "type": "structure"}, + { + "name": "DatabaseConfiguration", + "shape": "DatabaseConfigurationMetadata", + "type": "structure", + }, + {"name": "SlurmHealth", "shape": "SlurmHealthMetadata", "type": "structure"}, ], "type": "structure", }, @@ -9003,6 +9265,40 @@ "members": [{"name": "HubContentArn", "shape": "HubContentArn", "type": "string"}], "type": "structure", }, + "HubContent": { + "members": [ + {"name": "HubContentName", "shape": "HubContentName", "type": "string"}, + {"name": "HubContentArn", "shape": "HubContentArn", "type": "string"}, + {"name": "HubContentVersion", "shape": "HubContentVersion", "type": "string"}, + {"name": "HubContentType", "shape": "HubContentType", "type": "string"}, + {"name": "DocumentSchemaVersion", "shape": "DocumentSchemaVersion", "type": "string"}, + {"name": "HubName", "shape": "HubName", "type": "string"}, + {"name": "HubArn", "shape": "HubArn", "type": "string"}, + {"name": "HubContentDisplayName", "shape": "HubContentDisplayName", "type": "string"}, + {"name": "HubContentDescription", "shape": "HubContentDescription", "type": "string"}, + {"name": "HubContentMarkdown", "shape": "HubContentMarkdown", "type": "string"}, + {"name": "HubContentDocument", "shape": "HubContentDocument", "type": "string"}, + { + "name": "SageMakerPublicHubContentArn", + "shape": "SageMakerPublicHubContentArn", + "type": "string", + }, + {"name": "ReferenceMinVersion", "shape": "ReferenceMinVersion", "type": "string"}, + {"name": "SupportStatus", "shape": "HubContentSupportStatus", "type": "string"}, + { + "name": "HubContentSearchKeywords", + "shape": "HubContentSearchKeywordList", + "type": "list", + }, + {"name": "HubContentDependencies", "shape": "HubContentDependencyList", "type": "list"}, + {"name": "HubContentStatus", "shape": "HubContentStatus", "type": "string"}, + {"name": "FailureReason", "shape": "FailureReason", "type": "string"}, + {"name": "CreationTime", "shape": "Timestamp", "type": "timestamp"}, + {"name": "LastModifiedTime", "shape": "Timestamp", "type": "timestamp"}, + {"name": "Tags", "shape": "TagList", "type": "list"}, + ], + "type": "structure", + }, "HubContentDependency": { "members": [ {"name": "DependencyOriginPath", "shape": "DependencyOriginPath", "type": "string"}, @@ -9556,6 +9852,17 @@ ], "type": "structure", }, + "IdcConfigInput": { + "members": [{"name": "InstanceArn", "shape": "InstanceArn", "type": "string"}], + "type": "structure", + }, + "IdcConfigOutput": { + "members": [ + {"name": "InstanceArn", "shape": "InstanceArn", "type": "string"}, + {"name": "ApplicationArn", "shape": "ApplicationArn", "type": "string"}, + ], + "type": "structure", + }, "IdentityProviderOAuthSetting": { "members": [ {"name": "DataSourceName", "shape": "DataSourceName", "type": "string"}, @@ -9695,6 +10002,11 @@ {"name": "Image", "shape": "ContainerImage", "type": "string"}, {"name": "ArtifactUrl", "shape": "Url", "type": "string"}, {"name": "Environment", "shape": "EnvironmentMap", "type": "map"}, + { + "name": "ContainerMetricsConfig", + "shape": "ContainerMetricsConfig", + "type": "structure", + }, ], "type": "structure", }, @@ -9703,6 +10015,11 @@ {"name": "DeployedImage", "shape": "DeployedImage", "type": "structure"}, {"name": "ArtifactUrl", "shape": "Url", "type": "string"}, {"name": "Environment", "shape": "EnvironmentMap", "type": "map"}, + { + "name": "ContainerMetricsConfig", + "shape": "ContainerMetricsConfig", + "type": "structure", + }, ], "type": "structure", }, @@ -10316,6 +10633,29 @@ ], "type": "structure", }, + "Job": { + "members": [ + {"name": "JobName", "shape": "JobName", "type": "string"}, + {"name": "JobArn", "shape": "JobArn", "type": "string"}, + {"name": "RoleArn", "shape": "RoleArn", "type": "string"}, + {"name": "JobCategory", "shape": "JobCategory", "type": "string"}, + {"name": "JobConfigSchemaVersion", "shape": "JobSchemaVersion", "type": "string"}, + {"name": "JobConfigDocument", "shape": "JobConfigDocument", "type": "string"}, + {"name": "CreationTime", "shape": "Timestamp", "type": "timestamp"}, + {"name": "LastModifiedTime", "shape": "Timestamp", "type": "timestamp"}, + {"name": "EndTime", "shape": "Timestamp", "type": "timestamp"}, + {"name": "JobStatus", "shape": "JobStatus", "type": "string"}, + {"name": "SecondaryStatus", "shape": "JobSecondaryStatus", "type": "string"}, + { + "name": "SecondaryStatusTransitions", + "shape": "JobSecondaryStatusTransitions", + "type": "list", + }, + {"name": "FailureReason", "shape": "FailureReason", "type": "string"}, + {"name": "Tags", "shape": "TagList", "type": "list"}, + ], + "type": "structure", + }, "JobConfigSchemaVersionSummary": { "members": [ {"name": "JobConfigSchemaVersion", "shape": "JobSchemaVersion", "type": "string"} @@ -12480,6 +12820,28 @@ ], "type": "structure", }, + "ListTrainingSessionsRequest": { + "members": [ + {"name": "NextToken", "shape": "NextToken", "type": "string"}, + {"name": "MaxResults", "shape": "MaxResults", "type": "integer"}, + {"name": "CreationTimeAfter", "shape": "Timestamp", "type": "timestamp"}, + {"name": "CreationTimeBefore", "shape": "Timestamp", "type": "timestamp"}, + {"name": "NameContains", "shape": "NameContains", "type": "string"}, + {"name": "StatusEquals", "shape": "TrainingSessionStatus", "type": "string"}, + ], + "type": "structure", + }, + "ListTrainingSessionsResponse": { + "members": [ + {"name": "NextToken", "shape": "NextToken", "type": "string"}, + { + "name": "TrainingSessionSummaries", + "shape": "TrainingSessionSummaries", + "type": "list", + }, + ], + "type": "structure", + }, "ListTransformJobsRequest": { "members": [ {"name": "CreationTimeAfter", "shape": "Timestamp", "type": "timestamp"}, @@ -12615,6 +12977,13 @@ ], "type": "structure", }, + "LoraConfig": { + "members": [ + {"name": "Rank", "shape": "Rank", "type": "integer"}, + {"name": "Alpha", "shape": "LoraAlpha", "type": "integer"}, + ], + "type": "structure", + }, "MLflowConfiguration": { "members": [ {"name": "MlflowResourceArn", "shape": "MLflowArn", "type": "string"}, @@ -12732,6 +13101,22 @@ "MetricsConfig": { "members": [ {"name": "EnableEnhancedMetrics", "shape": "EnableEnhancedMetrics", "type": "boolean"}, + { + "name": "EnableDetailedObservability", + "shape": "EnableDetailedObservability", + "type": "boolean", + }, + { + "name": "MetricPublishFrequencyInSeconds", + "shape": "MetricPublishFrequencyInSeconds", + "type": "integer", + }, + ], + "type": "structure", + }, + "MetricsEndpoint": { + "members": [ + {"name": "MetricsEndpointPath", "shape": "MetricsEndpointPath", "type": "string"}, { "name": "MetricPublishFrequencyInSeconds", "shape": "MetricPublishFrequencyInSeconds", @@ -12740,6 +13125,11 @@ ], "type": "structure", }, + "MetricsEndpointList": { + "member_shape": "MetricsEndpoint", + "member_type": "structure", + "type": "list", + }, "MetricsSource": { "members": [ {"name": "ContentType", "shape": "ContentType", "type": "string"}, @@ -14212,6 +14602,11 @@ ], "type": "structure", }, + "OptimizationJobTrainingPlanArns": { + "member_shape": "TrainingPlanArn", + "member_type": "string", + "type": "list", + }, "OptimizationModelAccessConfig": { "members": [ {"name": "AcceptEula", "shape": "OptimizationModelAcceptEula", "type": "boolean"} @@ -14780,6 +15175,17 @@ "members": [{"name": "PredefinedMetricType", "shape": "String", "type": "string"}], "type": "structure", }, + "PrefixAwareRoutingConfig": { + "members": [ + {"name": "PrefixLength", "shape": "PrefixAwareRoutingPrefixLength", "type": "integer"}, + { + "name": "ConcurrencyThreshold", + "shape": "PrefixAwareRoutingConcurrencyThreshold", + "type": "integer", + }, + ], + "type": "structure", + }, "PresignedUrlAccessConfig": { "members": [ {"name": "AcceptEula", "shape": "Boolean", "type": "boolean"}, @@ -15129,7 +15535,14 @@ "type": "structure", }, "ProductionVariantRoutingConfig": { - "members": [{"name": "RoutingStrategy", "shape": "RoutingStrategy", "type": "string"}], + "members": [ + {"name": "RoutingStrategy", "shape": "RoutingStrategy", "type": "string"}, + { + "name": "PrefixAwareRoutingConfig", + "shape": "PrefixAwareRoutingConfig", + "type": "structure", + }, + ], "type": "structure", }, "ProductionVariantServerlessConfig": { @@ -16172,6 +16585,8 @@ }, {"name": "ModelCard", "shape": "ModelCard", "type": "structure"}, {"name": "Model", "shape": "ModelDashboardModel", "type": "structure"}, + {"name": "Job", "shape": "Job", "type": "structure"}, + {"name": "HubContent", "shape": "HubContent", "type": "structure"}, ], "type": "structure", }, @@ -16396,6 +16811,14 @@ "members": [{"name": "Seed", "shape": "Seed", "type": "long"}], "type": "structure", }, + "SlurmHealthMetadata": { + "members": [ + {"name": "Component", "shape": "SlurmHealthComponent", "type": "string"}, + {"name": "Status", "shape": "SlurmHealthStatus", "type": "string"}, + {"name": "Reason", "shape": "SlurmHealthReason", "type": "string"}, + ], + "type": "structure", + }, "SourceAlgorithm": { "members": [ {"name": "ModelDataUrl", "shape": "Url", "type": "string"}, @@ -16779,6 +17202,13 @@ "members": [{"name": "TrainingJobName", "shape": "TrainingJobName", "type": "string"}], "type": "structure", }, + "StopTrainingSessionRequest": { + "members": [ + {"name": "TrainingSessionName", "shape": "TrainingSessionName", "type": "string"} + ], + "type": "structure", + }, + "StopTrainingSessionResponse": {"members": [], "type": "structure"}, "StopTransformJobRequest": { "members": [{"name": "TransformJobName", "shape": "TransformJobName", "type": "string"}], "type": "structure", @@ -17400,6 +17830,61 @@ ], "type": "structure", }, + "TrainingSessionDetail": { + "members": [ + {"name": "TrainingSessionArn", "shape": "TrainingSessionArn", "type": "string"}, + {"name": "TrainingSessionName", "shape": "TrainingSessionName", "type": "string"}, + {"name": "TrainingSessionStatus", "shape": "TrainingSessionStatus", "type": "string"}, + {"name": "ModelPackageGroupArn", "shape": "ModelPackageGroupArn", "type": "string"}, + {"name": "CreationTime", "shape": "Timestamp", "type": "timestamp"}, + {"name": "LastModifiedTime", "shape": "Timestamp", "type": "timestamp"}, + {"name": "EndTime", "shape": "Timestamp", "type": "timestamp"}, + {"name": "ErrorDetails", "shape": "FailureReason", "type": "string"}, + {"name": "LastReceivedSequenceNumber", "shape": "JavaInteger", "type": "integer"}, + {"name": "BillableTokenUsage", "shape": "BillableTokenUsage", "type": "structure"}, + {"name": "VpcConfig", "shape": "VpcConfig", "type": "structure"}, + {"name": "RoleArn", "shape": "RoleArn", "type": "string"}, + {"name": "LoraConfig", "shape": "LoraConfig", "type": "structure"}, + {"name": "ModelConfig", "shape": "TrainingSessionModelConfig", "type": "structure"}, + {"name": "OutputConfig", "shape": "TrainingSessionOutputConfig", "type": "structure"}, + {"name": "Tags", "shape": "TagList", "type": "list"}, + ], + "type": "structure", + }, + "TrainingSessionModelConfig": { + "members": [ + {"name": "BaseModelArn", "shape": "BaseModelArn", "type": "string"}, + {"name": "AcceptEula", "shape": "JavaBoolean", "type": "boolean"}, + ], + "type": "structure", + }, + "TrainingSessionOutputConfig": { + "members": [ + {"name": "S3Location", "shape": "TrainingSessionS3Location", "type": "structure"} + ], + "type": "structure", + }, + "TrainingSessionS3Location": { + "members": [ + {"name": "Path", "shape": "OutputS3Path", "type": "string"}, + {"name": "KmsKeyArn", "shape": "CustomerKmsKeyArn", "type": "string"}, + ], + "type": "structure", + }, + "TrainingSessionSummaries": { + "member_shape": "TrainingSessionSummary", + "member_type": "structure", + "type": "list", + }, + "TrainingSessionSummary": { + "members": [ + {"name": "TrainingSessionArn", "shape": "TrainingSessionArn", "type": "string"}, + {"name": "TrainingSessionStatus", "shape": "TrainingSessionStatus", "type": "string"}, + {"name": "CreationTime", "shape": "Timestamp", "type": "timestamp"}, + {"name": "LastModifiedTime", "shape": "Timestamp", "type": "timestamp"}, + ], + "type": "structure", + }, "TrainingSpecification": { "members": [ {"name": "TrainingImage", "shape": "ContainerImage", "type": "string"}, @@ -17999,7 +18484,8 @@ }, "UpdateClusterSoftwareInstanceGroupSpecification": { "members": [ - {"name": "InstanceGroupName", "shape": "ClusterInstanceGroupName", "type": "string"} + {"name": "InstanceGroupName", "shape": "ClusterInstanceGroupName", "type": "string"}, + {"name": "ImageReleaseVersion", "shape": "ImageReleaseVersion", "type": "string"}, ], "type": "structure", }, @@ -18554,6 +19040,8 @@ }, {"name": "Tier", "shape": "NonEmptyString64", "type": "string"}, {"name": "ApplicationConfig", "shape": "PartnerAppConfig", "type": "structure"}, + {"name": "IdcConfig", "shape": "IdcConfigInput", "type": "structure"}, + {"name": "AuthType", "shape": "PartnerAppAuthType", "type": "string"}, {"name": "EnableIamSessionBasedIdentity", "shape": "Boolean", "type": "boolean"}, {"name": "EnableAutoMinorVersionUpgrade", "shape": "Boolean", "type": "boolean"}, {"name": "AppVersion", "shape": "MajorMinorVersion", "type": "string"}, @@ -18666,6 +19154,16 @@ "members": [{"name": "ProjectArn", "shape": "ProjectArn", "type": "string"}], "type": "structure", }, + "UpdateRecordRequest": { + "members": [ + {"name": "FeatureGroupName", "shape": "FeatureGroupNameOrArn", "type": "string"}, + {"name": "RecordIdentifierValueAsString", "shape": "ValueAsString", "type": "string"}, + {"name": "Features", "shape": "Record", "type": "list"}, + {"name": "TargetStores", "shape": "TargetStores", "type": "list"}, + {"name": "TtlDuration", "shape": "TtlDuration", "type": "structure"}, + ], + "type": "structure", + }, "UpdateSpaceRequest": { "members": [ {"name": "DomainId", "shape": "DomainId", "type": "string"}, @@ -18736,16 +19234,6 @@ ], "type": "structure", }, - "UpdateRecordRequest": { - "members": [ - {"name": "FeatureGroupName", "shape": "FeatureGroupNameOrArn", "type": "string"}, - {"name": "RecordIdentifierValueAsString", "shape": "ValueAsString", "type": "string"}, - {"name": "Features", "shape": "Record", "type": "list"}, - {"name": "TargetStores", "shape": "TargetStores", "type": "list"}, - {"name": "TtlDuration", "shape": "TtlDuration", "type": "structure"}, - ], - "type": "structure", - }, "UpdateTrialComponentResponse": { "members": [{"name": "TrialComponentArn", "shape": "TrialComponentArn", "type": "string"}], "type": "structure",