Courseiva

AWS Certified Machine Learning Engineer Associate MLA-C01 (MLA-C01) — Questions 226300

835 questions total · 12pages · All types, answers revealed

Page 3

Page 4 of 12

Page 5
226
MCQhard

A data scientist uses SageMaker Automatic Model Tuning (AMT) with Bayesian optimization to tune an XGBoost model. The objective metric is validation:auc, but the tuning job converges to a plateau early. Which action is MOST effective to improve exploration?

A.Increase the number of max parallel jobs
B.Decrease the number of hyperparameters being tuned
C.Increase the exploration_weight parameter in the tuning configuration
D.Switch the tuning strategy from Bayesian to Random Search
AnswerC

A higher exploration_weight (default 0.3) makes Bayesian optimization explore more before exploiting.

Why this answer

Increasing the exploration/exploitation weight (exploration_weight) in Bayesian optimization encourages the algorithm to try more diverse hyperparameter combinations, avoiding premature convergence.

227
MCQhard

A team uses SageMaker Pipelines with a Condition step to decide whether to register a model based on evaluation metrics. They want to also store the evaluation results for lineage tracking. Which step should they use to record the metrics?

A.Condition step
B.Training step
C.RegisterModel step
D.Processing step
AnswerC

RegisterModel step registers the model and can include evaluation metrics as metadata.

Why this answer

The RegisterModel step in SageMaker Pipelines is designed to create a model version in the SageMaker Model Registry, and it can accept metadata such as evaluation metrics via the `InferenceSpecification` or by passing a metrics dictionary. This allows the team to store evaluation results alongside the model for lineage tracking, fulfilling the requirement to record metrics after a Condition step approves registration.

Exam trap

The trap here is that candidates often assume the Condition step or Processing step can directly store metrics for lineage, but only the RegisterModel step can bind evaluation results to a model version in the Model Registry, which is the explicit requirement for lineage tracking.

How to eliminate wrong answers

Option A is wrong because the Condition step only evaluates a boolean expression (e.g., comparing metrics against a threshold) to control pipeline flow; it does not have the capability to store or persist metrics. Option B is wrong because the Training step outputs a model artifact and training metrics, but it does not record evaluation metrics from a separate evaluation job into the Model Registry for lineage tracking. Option D is wrong because a Processing step can compute evaluation metrics, but it does not inherently register them with the model in the Model Registry; it would need an additional step (like RegisterModel) to persist those metrics for lineage.

228
MCQhard

A company's ML pipeline runs in multiple AWS accounts (dev, test, prod). They want to enforce that only approved models from a central Model Registry can be deployed to the production account. Which combination of services is MOST appropriate to implement this governance?

A.AWS Config, Amazon GuardDuty, and AWS Security Hub.
B.Amazon API Gateway, AWS Step Functions, and Amazon DynamoDB.
C.AWS Service Catalog, AWS KMS, and AWS CloudTrail.
D.AWS Organizations with SCPs, AWS CodePipeline with cross-account actions, and SageMaker Model Registry with approval status.
E.AWS CloudFormation StackSets, Amazon EventBridge, and AWS Lambda.
AnswerD

Correct. SCPs enforce policies, CodePipeline orchestrates deployment, and Model Registry ensures only approved models are deployed.

Why this answer

It combines AWS Organizations with SCPs to enforce cross-account deployment policies, AWS CodePipeline with cross-account actions to orchestrate the pipeline across dev/test/prod accounts, and SageMaker Model Registry with approval status to gate deployments to only approved models. This ensures that only models with an 'Approved' status in the central registry can be deployed to the production account, meeting the governance requirement.

Exam trap

The trap here is that candidates may choose monitoring-focused options like A or C, mistakenly thinking that detecting non-approved deployments is sufficient, when the question explicitly requires enforcement (prevention), which demands a combination of policy-based controls (SCPs) and approval-gated pipelines (CodePipeline + Model Registry).

How to eliminate wrong answers

Option A is wrong because AWS Config, GuardDuty, and Security Hub are monitoring and security services that detect misconfigurations and threats but cannot enforce approval-based gating on model deployments. Option B is wrong because API Gateway, Step Functions, and DynamoDB are used for building serverless workflows and APIs, not for cross-account deployment governance or model approval enforcement. Option C is wrong because AWS Service Catalog manages approved IT service portfolios, KMS handles encryption keys, and CloudTrail logs API activity—none of these services directly enforce that only approved SageMaker models are deployed to production.

Option E is wrong because CloudFormation StackSets deploy infrastructure across accounts, EventBridge routes events, and Lambda runs code—they lack native integration with SageMaker Model Registry approval status to gate deployments.

229
Multi-Selecthard

A team is deploying a model using SageMaker real-time endpoint with an ml.m5.large instance. They notice high latency under peak load. They want to reduce latency without increasing instance size. Which THREE actions could help? (Select THREE.)

Select 3 answers
A.Quantize the model to reduce its size
B.Increase the number of instances in the endpoint
C.Compile the model with SageMaker Neo for the ml.m5 instance
D.Attach Amazon Elastic Inference to the endpoint
E.Change the instance type to ml.g4dn.xlarge
AnswersA, C, D

Why this answer

SageMaker Neo compiles the model for the target hardware, reducing latency. Elastic Inference attaches GPU acceleration to a CPU instance. Model quantization reduces model size and speeds up inference.

Increasing instance count does not reduce per-request latency (it increases throughput). Changing to a GPU instance increases instance size.

230
Multi-Selectmedium

A machine learning team is handling a text classification task with a dataset of 1 million documents. They need to convert text into numerical features. Which THREE techniques are commonly used for feature extraction from text? (Select THREE.)

Select 3 answers
A.One-hot encoding
B.Word embeddings (e.g., Word2Vec)
C.Bag-of-words
D.TF-IDF
E.Principal component analysis (PCA)
AnswersB, C, D

Dense vector representations capturing semantic meaning.

Why this answer

TF-IDF, word embeddings (e.g., Word2Vec, GloVe), and bag-of-words are standard text vectorization methods. One-hot encoding is for categorical features, not text. PCA is for dimensionality reduction after vectorization.

231
MCQeasy

A team wants to automatically retrain a model whenever data drift is detected on their SageMaker endpoint. Which AWS service should they use to invoke a retraining pipeline in response to a CloudWatch Alarm?

A.AWS Step Functions directly from CloudWatch Alarm
B.SageMaker Processing job scheduled via EventBridge
C.Amazon SQS queue polling by a custom application
D.Amazon SNS topic triggering an AWS Lambda function
AnswerD

This pattern is typical: CloudWatch Alarm -> SNS -> Lambda -> start retraining pipeline.

Why this answer

Amazon SNS can directly subscribe to a CloudWatch Alarm and, upon alarm state change, publish a message to an SNS topic. That topic can then trigger an AWS Lambda function, which invokes the retraining pipeline (e.g., SageMaker Processing or training job). This creates a fully managed, serverless event-driven workflow without needing custom polling or additional orchestration services.

Exam trap

The trap here is that candidates often assume CloudWatch Alarms can directly invoke Step Functions or Lambda without an intermediary like SNS, but CloudWatch Alarms only support SNS, SQS, and Auto Scaling actions as direct targets.

How to eliminate wrong answers

Option A is wrong because CloudWatch Alarms cannot directly invoke AWS Step Functions; they can only send notifications to SNS, SQS, or Auto Scaling, not invoke Step Functions directly. Option B is wrong because SageMaker Processing jobs cannot be scheduled directly via EventBridge; EventBridge can trigger a Lambda or Step Functions that starts a Processing job, but the job itself is not a direct target. Option C is wrong because using an SQS queue polled by a custom application introduces unnecessary complexity, latency, and operational overhead, and is not the simplest or most recommended pattern for reacting to a CloudWatch Alarm.

232
MCQmedium

A data scientist needs to ingest streaming customer clickstream data from a website into an S3 data lake for ML training. The data must be delivered within 1 minute of ingestion, and JSON records must be converted to Parquet. Which AWS service combination should be used?

A.Amazon S3 Transfer Acceleration with direct PUT requests by clients
B.Amazon Kinesis Data Streams (KDS) with a Lambda consumer that writes JSON to S3
C.AWS Glue ETL job triggered every minute to pull from Kinesis Data Streams and write Parquet to S3
D.Amazon Kinesis Data Firehose with a 60-second buffer and Parquet conversion enabled
AnswerD

Firehose buffers up to 60 seconds and can convert JSON to Parquet automatically before writing to S3.

Why this answer

Amazon Kinesis Data Firehose can buffer incoming data and deliver to S3 with a 60-second buffer window, and it supports converting JSON to Parquet. KDS alone does not convert to Parquet. Glue ETL can do the conversion but adds latency.

Lambda with S3 trigger is not streaming-oriented.

233
MCQeasy

A machine learning engineer wants to reduce training costs by using excess EC2 capacity. Which instance purchasing option should they choose for SageMaker training jobs?

A.Reserved Instances
B.On-Demand Instances
C.Dedicated Instances
D.Spot Instances
AnswerD
234
Multi-Selecthard

A company is deploying a SageMaker endpoint and must meet strict security requirements: no public internet access, all inter-container traffic must be encrypted, and all data at rest must be encrypted with a customer-managed KMS key. Which THREE configurations should they apply? (Choose THREE.)

Select 3 answers
A.Configure the endpoint to use VPC-only mode
B.Attach a security group that only allows inbound traffic from the VPC CIDR
C.Enable inter-container traffic encryption
D.Specify a KMS key in the endpoint configuration for data encryption
E.Enable network isolation mode on the endpoint
AnswersA, C, D

VPC-only mode ensures no public internet access.

235
MCQeasy

A data scientist needs to train a binary classification model on a large tabular dataset stored in Amazon S3. The team wants to minimize training time and cost while using a built-in SageMaker algorithm. Which algorithm should they use?

A.BlazingText
B.DeepAR
C.Linear Learner
D.XGBoost
AnswerC

Linear Learner is built for large-scale classification and regression, providing fast training and built-in distributed training support.

Why this answer

Linear Learner is a built-in SageMaker algorithm designed for binary classification and regression, and it scales efficiently on large datasets. XGBoost is better for structured data with non-linear relationships, DeepAR is for time series, and BlazingText is for text.

236
Multi-Selecthard

A data scientist is training a large transformer model using SageMaker's model parallelism library. The training job is failing with an out-of-memory (OOM) error. Which two actions can help resolve the OOM error? (Choose two.)

Select 2 answers
A.Reduce the sequence length
B.Enable activation checkpointing
C.Increase the batch size per GPU
D.Switch to a smaller instance type
E.Decrease the pipeline parallelism degree
AnswersA, B

Shorter sequences directly reduce memory usage for attention and hidden states.

Why this answer

Reducing the sequence length decreases the memory footprint of the attention mechanism, which scales quadratically with sequence length in transformer models. This directly reduces the peak memory usage per GPU, helping to avoid out-of-memory errors during training with SageMaker's model parallelism.

Exam trap

The trap here is that candidates may confuse pipeline parallelism with tensor parallelism, assuming decreasing pipeline degree reduces memory, when in fact it increases per-GPU memory load due to fewer stages.

237
MCQmedium

A data engineer is designing a feature engineering pipeline using Amazon SageMaker Feature Store. The team needs to support both real-time inference (millisecond latency) and batch training jobs that require access to historical feature values at specific points in time. Which configuration should the engineer choose?

A.Create a feature group with only an online store
B.Create separate feature groups — one for online and one for offline — and manage data synchronization manually
C.Create a feature group with both online and offline stores enabled
D.Store features only in the offline store and use a separate low-latency cache like ElastiCache
AnswerC

This provides low-latency serving for inference and historical storage for training, supporting point-in-time queries.

Why this answer

Feature Store supports dual storage: an online store (low-latency, key-value) for real-time inference and an offline store (S3-backed, queryable) for batch processing and point-in-time queries.

238
MCQmedium

A data scientist wants to train a model on SageMaker using a custom PyTorch script, then register the best model in the SageMaker Model Registry. The training job is part of a SageMaker Pipeline. Which pipeline step should be used to register the model?

A.RegisterModelStep
B.CreateModelStep
C.TrainingStep
D.TransformStep
AnswerA

RegisterModelStep registers a trained model into the Model Registry.

Why this answer

The `RegisterModelStep` is specifically designed to create a model resource and register it in the SageMaker Model Registry as part of a pipeline. It takes the training output (e.g., model artifacts from a `TrainingStep`) and packages it with the specified inference image and metadata, then creates a model package group version. This is the correct step for registering a model after training, as it directly integrates with the Model Registry for versioning and approval workflows.

Exam trap

The trap here is that candidates confuse `CreateModelStep` (which creates a deployable model resource) with `RegisterModelStep` (which creates a model package version in the registry), assuming both serve the same purpose of model registration.

How to eliminate wrong answers

Option B is wrong because `CreateModelStep` only creates a SageMaker model resource (for deployment or batch inference) but does not register it in the Model Registry; it lacks the versioning and metadata capabilities needed for registry management. Option C is wrong because `TrainingStep` is used to run a training job and produce model artifacts, but it has no built-in functionality to register the model into the Model Registry; registration requires a separate step. Option D is wrong because `TransformStep` is used for batch inference (transform jobs) on existing models, not for registering models into the registry.

239
Multi-Selecthard

A company wants to enable cross-account access to a SageMaker model endpoint. The model is in Account A, and Account B needs to invoke it. Which TWO steps are required? (Select TWO)

Select 2 answers
A.Attach a resource-based policy to the SageMaker model in Account A allowing access from Account B's IAM role
B.Export the model from Account A and re-deploy in Account B
C.Create an IAM role in Account B with permissions to invoke SageMaker endpoints
D.Configure VPC peering between the two accounts
E.Use a SageMaker notebook instance cross-account sharing
AnswersA, C

Resource policies grant cross-account permissions directly on the model.

Why this answer

SageMaker endpoints support resource-based policies that allow cross-account access. By attaching a resource-based policy to the model endpoint in Account A, you can grant the IAM role from Account B explicit permission to invoke the endpoint. This is the standard AWS mechanism for cross-account SageMaker endpoint invocation without needing to duplicate the model.

Exam trap

The trap here is that candidates often confuse network-level connectivity (VPC peering) with IAM-level authorization, or assume that cross-account access requires duplicating resources, when in fact SageMaker's resource-based policies provide a direct and secure solution.

240
MCQmedium

A team is building a recommendation system and wants to store and serve features for online and offline models. The features include user statistics (updated daily) and movie metadata (static). The team needs low-latency inference for real-time recommendations and wants to reuse features across multiple models. Which AWS service should the team use to store, manage, and serve these features?

A.Amazon DynamoDB with TTL.
B.AWS Glue Data Catalog.
C.SageMaker Feature Store.
D.Amazon S3 with AWS Lambda for serving.
AnswerC

Feature Store provides online and offline feature storage with low latency.

Why this answer

Amazon SageMaker Feature Store is purpose-built for storing, managing, and serving ML features with low-latency retrieval for online inference and batch serving for offline training. It supports feature reuse across multiple models by providing a centralized feature registry, consistent feature definitions, and both online (low-latency) and offline (S3-based) stores, which directly matches the team's requirements for real-time recommendations and cross-model reuse.

Exam trap

The trap here is that candidates often confuse a general-purpose database (DynamoDB) or a data catalog (Glue) with a purpose-built ML feature store, overlooking the need for feature-specific capabilities like online/offline consistency, feature versioning, and reuse across models.

How to eliminate wrong answers

Option A is wrong because Amazon DynamoDB with TTL is a key-value and document database that can store features but lacks built-in feature management capabilities such as feature versioning, point-in-time consistency across online/offline stores, and a feature registry; TTL only handles data expiration, not the orchestration needed for ML feature reuse. Option B is wrong because AWS Glue Data Catalog is a metadata repository for data assets (tables, schemas) and does not provide a low-latency online serving endpoint or feature-specific storage; it is used for data discovery and ETL, not for serving features in real-time inference. Option D is wrong because Amazon S3 with AWS Lambda for serving introduces high latency due to Lambda cold starts and S3 GET request overhead, making it unsuitable for low-latency real-time recommendations; additionally, it lacks feature store capabilities like consistent feature definitions, offline/online synchronization, and feature reuse across models.

241
MCQmedium

A machine learning engineer needs to split a time-series dataset for a forecasting model. The data spans 3 years of daily sales. Which splitting strategy should they use to avoid look-ahead bias?

A.k-fold cross-validation with shuffling
B.Random train-test split with 80/20 ratio
C.Stratified sampling based on sales volume
D.Walk-forward validation (time-series split)
AnswerD

Walk-forward validation uses expanding or sliding windows that respect time order.

Why this answer

Walk-forward validation (time-series split) is the correct strategy because it preserves the temporal order of the data, training on past observations and testing on future observations sequentially. This avoids look-ahead bias, where future information leaks into the training set, which would invalidate the forecasting model's performance metrics.

Exam trap

The trap here is that candidates often default to k-fold cross-validation or random splits because they are standard for non-temporal data, failing to recognize that time-series data requires strict temporal ordering to avoid look-ahead bias.

How to eliminate wrong answers

Option A is wrong because k-fold cross-validation with shuffling randomly reorders the data, breaking the temporal sequence and allowing future data to leak into training folds, introducing look-ahead bias. Option B is wrong because a random train-test split with an 80/20 ratio also shuffles the data, disregarding the time order and causing future sales data to appear in the training set. Option C is wrong because stratified sampling based on sales volume does not account for time dependency; it groups data by sales categories, which can mix past and future observations, leading to look-ahead bias.

242
Multi-Selecthard

You are preparing a time-series dataset for a forecasting model. Which three steps are critical to prevent data leakage during preprocessing? (Choose three.)

Select 3 answers
A.Impute missing values using the mean of the entire dataset
B.Standardize features using parameters computed only from the training set
C.Use a time-based train/test split
D.Use only past data for feature engineering (e.g., lag features)
E.Shuffle the data randomly before splitting
AnswersB, C, D

Computing mean and variance only on training data prevents leakage from test.

Why this answer

Standardizing features using parameters computed only from the training set is critical because it prevents information from the test set from influencing the training data. If you compute the mean and standard deviation from the entire dataset before splitting, the test set's distribution leaks into the training process, causing the model to see future data during training. This violates the temporal order and leads to overly optimistic performance estimates.

Exam trap

AWS often tests the misconception that standard preprocessing techniques like imputation or scaling can be applied globally to the entire dataset, when in time-series contexts they must be computed only from the training set to avoid leakage.

243
MCQhard

A dataset contains a numerical feature with extreme outliers. The outliers are genuine (not errors), and the ML model is a linear regression which is sensitive to outliers. Which data transformation should be applied to reduce the impact of outliers while preserving the data?

A.Min-max scaling
B.Log transformation
C.Robust scaling (median and IQR)
D.Standardization (z-score)
AnswerC

Robust scaling uses median and interquartile range, not affected by extreme values.

Why this answer

Robust scaling uses the median and interquartile range (IQR) to center and scale the data, making it resistant to extreme outliers. Since linear regression is sensitive to outliers, this transformation reduces their influence while preserving the original data distribution, unlike methods that rely on mean and variance.

Exam trap

AWS often tests the distinction between scaling methods that are robust to outliers versus those that are not, trapping candidates who assume all normalization techniques handle outliers equally.

How to eliminate wrong answers

Option A is wrong because min-max scaling is sensitive to outliers; extreme values can compress the rest of the data into a narrow range, distorting the feature's distribution. Option B is wrong because log transformation is only applicable to positive data and can handle skewed distributions but does not specifically reduce the impact of outliers in a way that preserves the data's structure for linear regression; it changes the relationship between features. Option D is wrong because standardization (z-score) uses the mean and standard deviation, both of which are heavily influenced by outliers, so it does not reduce their impact and can even amplify their effect on the scaled values.

244
MCQhard

A team is building a time-series forecasting model for daily sales data. They want to evaluate model performance using cross-validation while respecting the temporal order of the data. Which data splitting strategy should they use?

A.Walk-forward validation (time-series split)
B.Holdout with a random 80/20 split
C.Random k-fold cross-validation
D.Stratified sampling
AnswerA

Walk-forward validation trains on expanding or rolling windows of past data and validates on subsequent non-overlapping periods, respecting the temporal order.

Why this answer

Time-series data requires special splitting to avoid data leakage. Walk-forward validation (also called rolling-origin or time-series split) preserves temporal order by training on past data and validating on future data in sequential folds.

245
MCQhard

A team is using Amazon SageMaker Data Wrangler to prepare a large dataset. They need to detect potential bias in the data before training. Which capability of Data Wrangler should they use?

A.Integration with Amazon SageMaker Clarify for bias reports
B.Built-in transform for SMOTE oversampling
C.Use of Amazon Athena to query data for bias patterns
D.Export to Amazon SageMaker Feature Store
AnswerA

SageMaker Clarify provides bias detection and analysis within Data Wrangler.

Why this answer

Amazon SageMaker Data Wrangler integrates directly with Amazon SageMaker Clarify to detect bias in datasets. This integration allows you to run bias analysis on your data before training, generating reports that highlight potential imbalances or unfairness in features and target variables. It is the correct capability for the team's stated need.

Exam trap

The trap here is that candidates may confuse data preprocessing techniques (like SMOTE for oversampling) with bias detection, or assume that any AWS query service (like Athena) can perform bias analysis, when only SageMaker Clarify provides the dedicated bias detection and reporting capability integrated with Data Wrangler.

How to eliminate wrong answers

Option B is wrong because SMOTE (Synthetic Minority Over-sampling Technique) is a built-in transform for oversampling imbalanced data, not for detecting or reporting bias. Option C is wrong because Amazon Athena is a query service for analyzing data in S3 using SQL; it does not have built-in bias detection capabilities or integration with SageMaker Clarify for bias reports. Option D is wrong because exporting to Amazon SageMaker Feature Store is for storing and sharing features for reuse in training and inference, not for detecting bias in the data.

246
MCQhard

A machine learning engineer is using SageMaker Debugger to monitor training jobs. They want to capture tensors every 100 steps but only for the first 500 steps. Which configuration should they set in the Debugger hook?

A.collection_configs with save_interval=500 and end_step=100
B.collection_configs with start_step=100 and end_step=500
C.collection_configs with save_interval=100 and end_step=500
D.Use SageMaker Debugger rules to filter steps
AnswerC

This configures saving every 100 steps and stopping after step 500.

247
MCQmedium

A company is using SageMaker Pipelines to orchestrate their ML workflow. They have a Condition step that checks if a model's accuracy exceeds 0.9. If true, they want to register the model in the model registry; otherwise, they want to run a retraining step. Which step type should they use for the decision?

A.Condition step
B.Transform step
C.Processing step
D.Tuning step
AnswerA

Condition step allows branching in the pipeline based on a Boolean condition.

Why this answer

The Condition step in SageMaker Pipelines allows you to choose between two branches based on a condition. The other options are not designed for branching: Transform is for batch inference, Tuning is for hyperparameter optimization, and Processing is for data processing.

248
MCQmedium

A company wants to deploy 50 small models (each ~100 MB) for real-time inference. They need to minimize hosting costs while maintaining low latency. Which SageMaker hosting option is most cost-effective?

A.SageMaker Serverless Inference
B.SageMaker Asynchronous Inference
C.SageMaker Multi-Model Endpoint (MME)
D.SageMaker real-time endpoint with one instance per model
AnswerC

MME allows multiple models to share a single instance, reducing cost.

Why this answer

Multi-Model Endpoint (MME) allows hosting multiple models on the same instance, sharing resources. Since the models are small, MME is cost-effective. Real-time endpoints would require separate instances.

Serverless is for on-demand but may incur cold starts. Asynchronous is for batch-like workloads.

249
MCQmedium

An ML team uses Amazon SageMaker Data Wrangler to prepare a dataset for a binary classification model. They suspect the dataset might contain bias against a certain demographic group. They want to detect and visualize potential bias before training the model. Which feature of SageMaker should they use?

A.SageMaker Debugger
B.SageMaker Experiments
C.SageMaker Model Monitor
D.SageMaker Clarify
AnswerD

SageMaker Clarify provides bias detection and explainability, and can be used with Data Wrangler to analyze datasets for bias.

Why this answer

Amazon SageMaker Clarify provides bias detection capabilities, including pre-training bias metrics, and can be integrated with Data Wrangler to analyze datasets. Data Wrangler itself does not have built-in bias detection, but it can export to Clarify for analysis.

250
MCQmedium

A team is training a large language model using SageMaker with multiple GPUs. They need to reduce training time by splitting the model across devices due to memory constraints. Which distributed training strategy should they use?

A.SageMaker Distributed Data Parallel (SMDDP)
B.Data parallelism
C.SageMaker Distributed Model Parallel (SMDMP)
D.Model parallelism
AnswerD

Model parallelism splits the model across devices, reducing memory per device.

251
MCQeasy

An ML engineer needs to convert a raw dataset from CSV to Parquet format in a serverless manner for cost efficiency. Which AWS service can be used to perform this conversion without managing servers?

A.Amazon S3 Select
B.Amazon EMR
C.AWS Lambda
D.AWS Glue
AnswerD

Glue provides serverless Spark jobs for format conversion.

Why this answer

AWS Glue is correct because it provides a serverless ETL service that can automatically convert CSV to Parquet using its built-in transform capabilities, such as the `ChangeSchema` or `ConvertToParquet` transforms in a Glue ETL job. This eliminates the need to provision or manage any servers, aligning with the cost-efficiency requirement.

Exam trap

The trap here is that candidates often confuse AWS Glue's serverless ETL capability with Amazon EMR's managed clusters, assuming EMR is also serverless, but EMR requires explicit cluster management and is not truly serverless like Glue.

How to eliminate wrong answers

Option A is wrong because Amazon S3 Select is a query-in-place service that retrieves subsets of data from objects using SQL expressions, but it cannot convert or write data in a different format like Parquet. Option B is wrong because Amazon EMR requires managing EC2 instances or using managed scaling, which still involves provisioning and managing clusters, not a serverless approach. Option C is wrong because AWS Lambda has a maximum execution time of 15 minutes and limited memory (up to 10 GB), making it impractical for converting large datasets from CSV to Parquet, which often requires more time and resources than Lambda allows.

252
MCQeasy

A company has trained a custom model using PyTorch on Amazon SageMaker. The model achieves high accuracy, but the inference latency on a real-time endpoint is above the required 100ms SLA. The model is a large neural network with many layers. The company wants to reduce latency without significantly impacting accuracy. Which approach should the machine learning engineer take?

A.Reduce the batch size used during inference.
B.Use SageMaker Neo to compile the model for the target hardware.
C.Increase the instance size of the endpoint.
D.Implement a cache for frequent inference requests.
AnswerB

Neo applies hardware-specific optimizations that reduce latency without retraining.

Why this answer

SageMaker Neo compiles trained models into an optimized binary for the target hardware (e.g., CPU, GPU, or Inferentia). It applies graph-level optimizations, operator fusion, and quantization-aware tuning to reduce inference latency while preserving model accuracy. This directly addresses the need to lower latency below 100ms without retraining or sacrificing significant accuracy.

Exam trap

AWS often tests the misconception that simply scaling up hardware (Option C) or batching (Option A) is the primary solution for latency issues, when in fact model compilation (Option B) is the targeted optimization for inference speed without accuracy loss.

How to eliminate wrong answers

Option A is wrong because reducing batch size typically increases latency per request (due to lower hardware utilization) and does not address the fundamental computational bottleneck of a large neural network. Option C is wrong because increasing instance size may reduce latency but at higher cost and without optimizing the model itself; it does not guarantee meeting the 100ms SLA and can introduce unnecessary expense. Option D is wrong because caching only helps for repeated identical requests, not for unique or dynamic inference inputs, and does not reduce the per-inference computation time for the model.

253
MCQmedium

A company needs to give a data science team in another AWS account access to deploy a model from a shared model registry. Which approach should they use to grant cross-account access?

A.Create an IAM role in the other account with permissions to access the registry
B.Use AWS Organizations SCP to allow cross-account access
C.Share the model artifacts via Amazon S3 bucket policy and use an IAM role
D.Attach a resource-based policy to the model registry granting the other account access
AnswerD

Resource-based policies allow cross-account access to SageMaker resources like the model registry.

Why this answer

Resource-based policies (also called resource policies) can be attached to the model registry to allow cross-account access. IAM roles are used for intra-account access, not for granting access to resources in another account.

254
MCQeasy

A data scientist needs to convert categorical variables to numerical format for a linear regression model. The dataset contains a 'Country' column with 50 unique values. Which transformation should the engineer use to avoid introducing ordinal relationships?

A.Label encoding
B.Target encoding
C.One-hot encoding
D.Ordinal encoding
AnswerC

Correct because it creates binary columns without ordinality.

Why this answer

One-hot encoding is correct because it creates binary columns for each category, avoiding any implicit ordinal relationship between the 50 unique countries. This is essential for linear regression, which assumes numerical inputs have meaningful order; one-hot encoding ensures the model treats each country as an independent category without ranking.

Exam trap

AWS often tests the distinction between label encoding and one-hot encoding, trapping candidates who assume integer mapping is harmless for linear models without recognizing the ordinal bias it introduces.

How to eliminate wrong answers

Option A is wrong because label encoding assigns arbitrary integer values (e.g., 1 to 50) to countries, introducing an ordinal relationship that linear regression would misinterpret as meaningful order. Option B is wrong because target encoding replaces categories with the mean of the target variable, which can cause data leakage and overfitting, and still does not guarantee avoidance of ordinality in the encoded values. Option D is wrong because ordinal encoding explicitly assigns ordered integers, which is identical to label encoding in effect and introduces the same false ordinal assumption.

255
MCQmedium

A team is collaborating on a machine learning project and needs to ensure that data used for training is consistent across experiments. The team wants to version datasets, track data lineage, and be able to reproduce past experiments. The team uses SageMaker for model training. Which combination of services and features should the team use?

A.Use SageMaker Pipelines to automate training and store datasets in S3 with versioning enabled.
B.Store datasets in Amazon DynamoDB and use Amazon Athena to query specific versions.
C.Use SageMaker with AWS Lake Formation to manage data access, version datasets in S3, and use SageMaker Experiments to track training jobs.
D.Use S3 versioning to store all dataset versions and AWS Glue Data Catalog to track schema changes.
AnswerC

This combination provides data versioning, lineage, and experiment tracking.

Why this answer

It combines AWS Lake Formation for fine-grained data access control and governance, S3 versioning for dataset versioning, and SageMaker Experiments to track training jobs and lineage. This trio directly addresses the need for consistent data across experiments, versioning, lineage tracking, and reproducibility in SageMaker.

Exam trap

The trap here is that candidates often confuse S3 versioning alone with full data lineage and experiment tracking, overlooking the need for a governance layer like Lake Formation and a dedicated experiment tracking service like SageMaker Experiments to tie datasets to specific training runs.

How to eliminate wrong answers

Option A is wrong because SageMaker Pipelines automates training workflows but does not provide data lineage tracking or experiment reproducibility; S3 versioning alone lacks the governance and cataloging needed for data lineage. Option B is wrong because DynamoDB is a NoSQL database not designed for large-scale dataset storage or versioning, and Athena queries data in place but does not track lineage or versions. Option D is wrong because S3 versioning and AWS Glue Data Catalog track schema changes but do not provide experiment tracking or lineage tied to training jobs, which is essential for reproducing past experiments.

256
MCQhard

A company uses Amazon SageMaker Data Wrangler to prepare data for ML. The dataset contains a timestamp column and sensor readings from IoT devices. The data scientist needs to create features such as moving averages and rolling statistics over time windows. Which Data Wrangler transformation type should be selected?

A.Join
B.Custom Python script
C.Group by and aggregate
D.Window function
AnswerD

Window function is designed for rolling computations like moving averages.

Why this answer

Window functions in Amazon SageMaker Data Wrangler allow you to compute moving averages, rolling statistics, and other time-window-based aggregations over ordered partitions of data. This is the correct transformation type because it directly supports operations like `SUM() OVER (ORDER BY timestamp ROWS BETWEEN 2 PRECEDING AND CURRENT ROW)` without requiring custom code or losing row-level granularity.

Exam trap

The trap here is that candidates confuse 'Group by and aggregate' with 'Window function' because both involve aggregation, but Group by reduces rows while Window functions preserve row-level detail, which is essential for rolling statistics.

How to eliminate wrong answers

Option A is wrong because Join is used to combine datasets based on a common key, not to compute rolling statistics over a time window. Option B is wrong because while a Custom Python script could technically implement moving averages, Data Wrangler provides a native Window function transformation that is more efficient, easier to maintain, and avoids the overhead of writing and debugging custom code. Option C is wrong because Group by and aggregate collapses rows into summary statistics per group, which loses the individual row-level detail needed for rolling window calculations.

257
MCQhard

A data scientist is preparing text data for natural language processing (NLP). The corpus contains many rare words and typos. To reduce dimensionality and improve generalization, they decide to apply stemming and remove stop words. However, after training, the model performs poorly on domain-specific terms. What is the most likely cause?

A.The corpus should be lemmatized instead
B.Both stemming and stop word removal are inappropriate for the domain
C.Stemming is too aggressive for the domain
D.Stop word removal removed important context words
AnswerB

In specialized domains, stemming can distort meaning and stop words can carry essential context.

Why this answer

Both stemming and stop word removal are inappropriate for this domain. Stemming aggressively reduces words to their root forms, which can conflate distinct domain-specific terms (e.g., 'therapy' and 'therapist' both stem to 'therap'), losing critical semantic nuance. Stop word removal can discard words that carry domain-specific meaning (e.g., 'not' in medical negation or 'up' in 'tune-up' for maintenance), leading to poor generalization on specialized vocabulary.

Exam trap

AWS often tests the misconception that lemmatization is always superior to stemming, but the trap here is that the root cause is the inappropriate application of both preprocessing techniques to domain-specific text, not the choice between stemming and lemmatization.

How to eliminate wrong answers

Option A is wrong because lemmatization, while more accurate than stemming, still does not address the core issue: removing stop words and aggressive normalization are fundamentally inappropriate for domain-specific text where rare terms and typos require preservation of original forms or specialized handling. Option C is wrong because while stemming can be aggressive, the primary problem is not the aggressiveness alone but the combination of stemming and stop word removal that strips domain-relevant context; even a less aggressive stemmer would fail if stop words containing domain meaning are removed. Option D is wrong because stop word removal can indeed remove important context words, but this is only part of the issue; the question states the model performs poorly on domain-specific terms, which is primarily caused by stemming distorting those terms, not just by stop word removal.

258
Multi-Selectmedium

A data scientist is building a text classification model using a pre-trained BERT model from the Hugging Face library on SageMaker. The scientist wants to fine-tune the model on a custom dataset. Which TWO steps are necessary to set up the fine-tuning job? (Select TWO.)

Select 2 answers
A.Use the HuggingFace estimator provided by SageMaker
B.Enable SageMaker Clarify for explainability during training
C.Build a custom Docker container with PyTorch and Transformers
D.Specify the PyTorch framework version and Transformers version in the estimator
E.Use SageMaker Processing to preprocess the data in parallel
AnswersA, D

The HuggingFace estimator simplifies fine-tuning with pre-built containers.

Why this answer

The SageMaker HuggingFace estimator is specifically designed to simplify fine-tuning of pre-trained Hugging Face models like BERT. It automatically handles the underlying infrastructure, including the correct PyTorch/TensorFlow and Transformers versions, without requiring custom Docker containers. This is the recommended approach for Hugging Face model fine-tuning on SageMaker.

Exam trap

AWS often tests the misconception that custom Docker containers are required for any non-standard framework, but the HuggingFace estimator eliminates that need by providing a managed environment with version control.

259
MCQhard

A company is using a SageMaker notebook instance to develop models. The security team requires that all data in the notebook be encrypted at rest and in transit, and that internet access be restricted. Which configuration meets these requirements?

A.Use a notebook with internet access enabled but attach a security group that blocks all outbound traffic.
B.Use a notebook with a public subnet and a network ACL that denies all inbound traffic.
C.Use a VPC-only notebook with default AWS managed key for EBS encryption.
D.Use a VPC-only notebook instance with a customer-managed KMS key and disable direct internet access.
AnswerD

VPC-only blocks internet, KMS encrypts at rest, HTTPS encrypts in transit.

Why this answer

A VPC-only SageMaker notebook instance ensures that all network traffic stays within the customer's VPC, and disabling direct internet access prevents any outbound internet connectivity. Using a customer-managed KMS key for EBS encryption meets the encryption-at-rest requirement, while SageMaker automatically encrypts data in transit using TLS 1.2 within the VPC, satisfying both security mandates.

Exam trap

The trap here is that candidates often assume that blocking inbound traffic (Option A or B) is sufficient to restrict internet access, but they overlook that outbound internet access must also be explicitly disabled, and that encryption-at-rest requires a customer-managed KMS key, not just any encryption key.

How to eliminate wrong answers

Option A is wrong because enabling internet access on the notebook, even with a security group blocking outbound traffic, still allows the instance to be reachable from the internet (e.g., via the SageMaker console or API), and the security group does not prevent the instance from initiating outbound connections to AWS services outside the VPC. Option B is wrong because placing the notebook in a public subnet with a network ACL denying all inbound traffic does not restrict internet access; the instance can still initiate outbound connections to the internet, and network ACLs are stateless, so inbound deny rules do not block outbound traffic. Option C is wrong because using a default AWS managed key for EBS encryption does not meet the encryption-at-rest requirement with a customer-controlled key, and the option does not specify disabling direct internet access, leaving the notebook potentially exposed to the internet.

260
MCQeasy

A data science team has trained a PyTorch model for real-time inference and needs to deploy it on AWS with GPU acceleration while minimizing cold-start latency. Which SageMaker inference option should they choose?

A.Serverless inference
B.Batch transform
C.Asynchronous inference endpoint
D.Real-time endpoint with ml.g4dn instance
AnswerD

GPU-instance-backed real-time endpoints offer low latency and GPU compute, ideal for real-time inference with minimal cold-start.

Why this answer

Real-time endpoints with GPU instances (e.g., ml.g4dn) provide low latency and support GPU acceleration, suitable for interactive inference. Serverless inference does not support GPU instances, asynchronous inference is for non-real-time, and batch transform is for offline predictions.

261
MCQmedium

A team wants to use a custom PyTorch training script in SageMaker. They need to install additional Python packages not included in the base PyTorch container. Which approach should they take?

A.Use SageMaker Script Mode with a custom Dockerfile
B.Build a custom container with Docker
C.Install packages using a lifecycle configuration
D.Use the SageMaker PyTorch estimator with a requirements.txt file
AnswerD

The PyTorch estimator automatically installs packages from requirements.txt.

262
MCQeasy

A data scientist is working with a dataset that contains missing values in several numeric features. The data scientist wants to impute the missing values with the median of each feature. Which Amazon SageMaker Data Wrangler transformation should be used?

A.Replace missing with constant
B.Custom transform with Python
C.Drop missing rows
D.Handle missing values (with median strategy)
AnswerD

This transform allows imputation with median.

Why this answer

Amazon SageMaker Data Wrangler includes a built-in 'Handle missing values' transformation that supports imputation with the median strategy. This directly matches the requirement to replace missing numeric values with the median of each feature without writing custom code.

Exam trap

The trap here is that candidates may confuse the 'Replace missing with constant' option (which uses a fixed value) with the median strategy, or they may overcomplicate the solution by choosing a custom Python transform when a built-in option exists.

How to eliminate wrong answers

Option A is wrong because 'Replace missing with constant' imputes a user-specified constant value (e.g., 0 or a fixed number), not the median of the feature. Option B is wrong because 'Custom transform with Python' would require writing custom Python code to compute and apply the median, which is unnecessary when a built-in transformation exists. Option C is wrong because 'Drop missing rows' removes entire rows with missing values, discarding potentially valuable data instead of imputing the missing values.

263
MCQhard

Refer to the exhibit. A data engineer runs an AWS Glue ETL job with the following script portion. The job fails with an error: 'An error occurred while calling o113.pyWriteDynamicFrame. No such file or directory'. What is the most likely cause?

A.The output format 'parquet' is not supported by Glue
B.The input partition path is incorrect because it includes the partition key
C.The output S3 path is missing a trailing slash
D.The schema contains a column with a reserved name
AnswerC

Glue DynamicFrame write expects a directory path ending with '/'.

Why this answer

The error 'No such file or directory' when calling `pyWriteDynamicFrame` typically occurs because AWS Glue expects the output S3 path to end with a trailing slash to denote a directory. Without it, Glue may interpret the path as a file name rather than a directory, leading to a failure when attempting to write the Parquet files. Adding a trailing slash (e.g., `s3://bucket/output/`) resolves the issue.

Exam trap

The trap here is that candidates often focus on data format or schema issues, overlooking the subtle file system requirement for a trailing slash in the output path, which is a common source of runtime errors in Spark-based ETL jobs.

How to eliminate wrong answers

Option A is wrong because Parquet is a fully supported output format in AWS Glue, including compression and partitioning. Option B is wrong because including the partition key in the input path is standard practice for reading partitioned data; Glue's DynamicFrame can handle partition keys in the path. Option D is wrong because while reserved column names can cause issues, they typically result in a schema mismatch or validation error, not a 'No such file or directory' file system error.

264
MCQmedium

A machine learning engineer is deploying a model using a SageMaker endpoint and needs to ensure that the model artifacts are encrypted at rest using a customer-managed KMS key. Which configuration should they set?

A.Set the KMS key in the endpoint configuration's ProductionVariant
B.Enable default encryption on the S3 bucket containing the model artifacts
C.Use SageMaker Studio's KMS integration
D.Set the KMS key when creating the model using the CreateModel API
AnswerD

The CreateModel API accepts a KMS key parameter to encrypt the model artifacts in S3 and at rest.

Why this answer

The `CreateModel` API in SageMaker accepts a `ModelKmsKeyId` parameter that specifies a customer-managed KMS key for encrypting the model artifacts at rest. This key is used when SageMaker copies the artifacts from S3 to the inference instance's Amazon EBS volume, ensuring encryption at rest. The other options either apply to different resources or do not control the encryption of the model artifacts themselves.

Exam trap

The trap here is that candidates confuse S3 bucket encryption (Option B) with model artifact encryption at rest on the endpoint, or they mistakenly think the endpoint configuration's `ProductionVariant` (Option A) can set a KMS key, when in fact the key is set at the model resource level.

How to eliminate wrong answers

Option A is wrong because the `ProductionVariant` in an endpoint configuration only controls instance type, count, and variant weight—it does not have a KMS key setting; encryption for the endpoint's EBS volume is set at the endpoint configuration level via the `KmsKeyId` parameter, not per variant. Option B is wrong because enabling default encryption on the S3 bucket only encrypts objects at rest in S3, but does not control the encryption of model artifacts when they are copied to the SageMaker endpoint's EBS volume; SageMaker uses the key specified in the model resource for that step. Option C is wrong because SageMaker Studio's KMS integration applies to Studio's own storage (e.g., home directories, notebooks) and does not affect the encryption of model artifacts used by a deployed endpoint.

265
MCQhard

A team is deploying a TensorFlow model on a SageMaker real-time endpoint with automatic scaling. They set the scaling policy to target an average CPU utilization of 50%. However, during traffic spikes, the endpoint experiences high latency and 503 errors. The instance type is ml.c5.large. What should the team do to resolve this while minimizing cost?

A.Pre-warm the endpoint by keeping a fixed number of additional instances
B.Increase the scale-in cooldown period to avoid frequent downsizing
C.Change the instance type to a larger one like ml.c5.xlarge to handle the spikes
D.Add a scaling policy based on the number of concurrent requests per instance
AnswerD

Concurrent requests metric often provides faster and more accurate scaling for ML endpoints.

Why this answer

Scaling based on CPU utilization alone is often insufficient for inference workloads where latency is the primary concern. By adding a scaling policy based on the number of concurrent requests per instance, the team can proactively scale out before CPU saturation occurs, reducing latency and eliminating 503 errors. SageMaker's automatic scaling supports multiple target tracking metrics, and using concurrent requests per instance aligns more closely with the actual demand on the model serving container.

Exam trap

The trap here is that candidates assume larger instances (Option C) are the only way to handle spikes, but the exam tests understanding that scaling policies based on the right metric (concurrent requests) can be more cost-effective and responsive than simply scaling up instance size.

How to eliminate wrong answers

Option A is wrong because pre-warming with a fixed number of additional instances increases cost without adapting to variable traffic patterns, and it does not address the root cause of scaling delays during spikes. Option B is wrong because increasing the scale-in cooldown period only delays instance termination, which does not help during rapid traffic increases; it may even worsen resource waste. Option C is wrong because moving to a larger instance type (ml.c5.xlarge) increases cost per instance and still relies on CPU-based scaling, which may still lag behind sudden spikes; it does not solve the fundamental issue of scaling responsiveness.

266
MCQhard

A company deploys a machine learning model as a SageMaker real-time endpoint. They need to implement a mechanism to automatically roll back to the previous model version if performance degrades after a deployment. Which approach should they use?

A.Manually update the endpoint to point to the previous model version
B.Configure the SageMaker endpoint deployment with traffic shifting and set up CloudWatch alarms to trigger automatic rollback
C.Create multiple endpoints and use Amazon Route 53 weighted routing to shift traffic
D.Use AWS CodeDeploy with Amazon EC2 instances behind an Elastic Load Balancer
AnswerB

SageMaker supports canary or linear traffic shifting with automatic rollback based on CloudWatch alarms.

Why this answer

SageMaker endpoints support deployment with traffic shifting (e.g., canary or linear patterns) via the 'DeploymentConfig' parameter, and you can attach CloudWatch alarms to the endpoint's variant metrics. If the alarm triggers (e.g., due to increased error rate or latency), SageMaker automatically rolls back the traffic to the previous model version, ensuring minimal manual intervention and fast recovery.

Exam trap

The trap here is that candidates often confuse manual rollback (Option A) as acceptable automation, or they overcomplicate the solution with external services like Route 53 (Option C) or CodeDeploy (Option D), missing that SageMaker's native deployment configuration with CloudWatch alarms provides a fully automated, integrated rollback mechanism.

How to eliminate wrong answers

Option A is wrong because manual rollback is not automated and introduces human delay and error risk, failing the requirement for an automatic mechanism. Option C is wrong because using multiple endpoints with Route 53 weighted routing does not provide native integration with SageMaker's deployment monitoring or automatic rollback; it requires custom health check logic and does not leverage SageMaker's built-in traffic shifting and alarm-based rollback. Option D is wrong because AWS CodeDeploy with EC2 instances behind an ELB is designed for traditional application deployments, not for SageMaker endpoints; SageMaker endpoints are managed services that do not use EC2 instances or ELBs directly, and this approach would bypass SageMaker's native deployment capabilities.

267
MCQhard

A machine learning team uses SageMaker Pipelines and wants to automatically retrain a model when data drift is detected. They have set up Model Monitor to publish drift violations to CloudWatch. Which approach provides a COMPLETE serverless retraining pipeline triggered by drift detection?

A.Use SageMaker Model Monitor to directly invoke a SageMaker Pipeline when drift is detected
B.Use EventBridge to schedule retraining daily regardless of drift
C.Configure a CloudWatch Alarm on drift metric → SNS topic → Lambda function that starts the SageMaker Pipeline execution
D.Create an EventBridge rule that triggers on Model Monitor drift events to start the pipeline
AnswerC

This chain fully automates retraining on drift detection without manual intervention.

Why this answer

The recommended pattern: CloudWatch Alarm triggers on drift metric → SNS message → Lambda function (receives SNS) → starts SageMaker Pipeline execution. EventBridge could also trigger on SNS events, but Lambda is simplest. EventBridge can schedule retraining but does not directly react to specific drift alarms.

Step Functions would add unnecessary complexity.

268
MCQmedium

After deploying a model to a SageMaker endpoint, the operations team notices high inference latency. They suspect it is due to insufficient instance capacity. Which first step should they take to diagnose the issue?

A.Check AWS CloudTrail logs for API errors.
B.Use Amazon SageMaker Debugger to analyze inference performance.
C.Review Amazon CloudWatch metrics for the endpoint, such as CPUUtilization and Invocations.
D.Retrain the model with more training data.
AnswerC

CloudWatch metrics can indicate resource saturation and latency.

Why this answer

Amazon CloudWatch metrics for a SageMaker endpoint, such as `CPUUtilization`, `MemoryUtilization`, and `Invocations`, directly indicate whether the instance is overloaded. High `CPUUtilization` combined with a high `Invocations` count and increased latency strongly suggests insufficient instance capacity. This is the standard first diagnostic step for capacity-related performance issues.

Exam trap

The trap here is that candidates confuse SageMaker Debugger (for training debugging) with inference monitoring tools, or they assume CloudTrail can provide performance metrics, when in fact CloudWatch is the correct service for real-time endpoint health and capacity diagnostics.

How to eliminate wrong answers

Option A is wrong because AWS CloudTrail logs record API calls (e.g., CreateEndpoint, InvokeEndpoint) and are used for auditing and security, not for real-time performance metrics like latency or CPU load. Option B is wrong because Amazon SageMaker Debugger is designed for monitoring training jobs (e.g., gradient norms, loss convergence) and does not provide inference-time performance metrics for deployed endpoints. Option D is wrong because retraining the model with more data addresses model accuracy, not inference latency caused by insufficient instance capacity; it would not reduce the time taken to process each request on an already overloaded instance.

269
MCQhard

A machine learning engineer is using SageMaker to train a model with the built-in LightGBM algorithm. The engineer wants to use early stopping to prevent overfitting. The training job is configured with a validation dataset. Which hyperparameter should be set to enable early stopping?

A.early_stopping_rounds
B.num_iterations
C.early_stopping
D.num_boost_round
AnswerA

early_stopping_rounds triggers early stopping after a specified number of rounds without validation improvement.

Why this answer

In SageMaker's built-in LightGBM algorithm, the hyperparameter `early_stopping_rounds` controls early stopping. When a validation dataset is provided, training will stop if the evaluation metric does not improve for the specified number of consecutive rounds, preventing overfitting.

Exam trap

The trap here is that candidates confuse the generic concept of early stopping with the exact hyperparameter name used by SageMaker's built-in LightGBM, often selecting `early_stopping` (which is not a valid parameter) instead of the precise `early_stopping_rounds`.

How to eliminate wrong answers

Option B is wrong because `num_iterations` sets the total number of boosting iterations, not the early stopping behavior; it defines the maximum number of rounds, not a stopping criterion. Option C is wrong because `early_stopping` is not a valid hyperparameter in SageMaker's LightGBM implementation; the correct parameter name is `early_stopping_rounds`. Option D is wrong because `num_boost_round` is an alias for `num_iterations` in some frameworks but is not the hyperparameter used for early stopping in SageMaker's LightGBM.

270
MCQeasy

A company wants to automate its machine learning pipeline using AWS CodePipeline and Amazon SageMaker. The pipeline should train a model, evaluate it, and if the evaluation passes, register the model in the SageMaker Model Registry. Which service should the company use to orchestrate the training and evaluation steps?

A.AWS CodePipeline
B.AWS Glue Workflows
C.AWS Step Functions
D.Amazon SageMaker Pipelines
AnswerD

SageMaker Pipelines natively supports ML steps like training, evaluation, and model registration.

Why this answer

Amazon SageMaker Pipelines is the correct choice because it is a purpose-built, fully managed service for creating end-to-end machine learning workflows directly within the SageMaker ecosystem. It natively integrates with SageMaker training jobs, processing jobs for evaluation, and the Model Registry for conditional registration, allowing the entire pipeline—train, evaluate, and conditionally register—to be defined as a directed acyclic graph (DAG) of steps without needing to stitch together separate services.

Exam trap

The trap here is that candidates may confuse AWS Step Functions (a general-purpose orchestrator) with SageMaker Pipelines (a specialized ML orchestrator), overlooking that SageMaker Pipelines provides built-in SageMaker step types and native Model Registry integration, which Step Functions lacks without custom Lambda functions.

How to eliminate wrong answers

Option A is wrong because AWS CodePipeline is a CI/CD service designed for software delivery pipelines (e.g., building, testing, deploying applications), not for orchestrating ML training and evaluation steps that require direct integration with SageMaker resources like training jobs or the Model Registry. Option B is wrong because AWS Glue Workflows are used for orchestrating ETL (extract, transform, load) jobs and data preparation tasks within AWS Glue, not for managing ML training or model evaluation workflows. Option C is wrong because while AWS Step Functions can orchestrate SageMaker API calls, it requires custom integration code and does not provide native, declarative support for SageMaker-specific steps like training, tuning, or model registration, making it less efficient and more error-prone than SageMaker Pipelines for this use case.

271
MCQhard

A financial services company must deploy a SageMaker endpoint that only accepts traffic from within a VPC and encrypts all data at rest and in transit using customer-managed KMS keys. They also need to prevent inter-container traffic from being visible to other users. Which combination of settings fulfills these requirements?

A.Deploy the endpoint in a private subnet and use SageMaker Model Monitor to detect unauthorized access
B.Attach a security group that only allows inbound traffic from the VPC CIDR and enable data encryption using a KMS key
C.Enable network isolation mode and use a VPC configuration with no public internet access
D.Configure the endpoint with VPC-only mode, enable inter-container traffic encryption, and specify a KMS key for endpoint data encryption
AnswerD

VPC-only mode restricts traffic to the VPC, inter-container encryption secures container-to-container traffic, and KMS key encrypts data at rest.

Why this answer

VPC-only mode restricts traffic to the VPC. Inter-container traffic encryption ensures data in transit between containers is encrypted. KMS key specified in the endpoint configuration encrypts data at rest.

272
MCQmedium

A team receives alerts that their SageMaker endpoint latency has increased significantly. They check CloudWatch metrics and see Invocations rising, but ModelLatency remains stable. Which metric should they investigate to find the source of the increased latency?

A.OverheadLatency
B.ModelLatency
C.5XXError
D.4XXError
AnswerA

OverheadLatency captures infrastructure overhead; an increase here explains the total latency rise when ModelLatency is unchanged.

Why this answer

OverheadLatency measures the time taken by the SageMaker infrastructure to handle requests before and after model inference, including request routing, authentication, and response processing. Since ModelLatency is stable but total endpoint latency has increased, the extra time must be in the overhead component, making OverheadLatency the correct metric to investigate.

Exam trap

The trap here is that candidates assume increased Invocations directly cause higher ModelLatency, but the exam tests the distinction between inference time and infrastructure overhead, leading them to incorrectly select ModelLatency instead of OverheadLatency.

How to eliminate wrong answers

Option B is wrong because ModelLatency is explicitly stated as stable, so it cannot be the source of increased latency. Option C is wrong because 5XXError indicates server-side errors, not latency; while errors can correlate with latency, the question asks for the metric directly measuring the latency increase. Option D is wrong because 4XXError indicates client-side errors (e.g., invalid requests), which do not directly cause increased endpoint latency.

273
MCQmedium

A company uses AWS Glue ETL jobs to process data from multiple sources and store it in a centralized S3 data lake for ML. They want to ensure that schema changes in source tables are automatically updated in the Glue Data Catalog without manual intervention. Which feature should they enable?

A.Use AWS Lambda to manually update the Data Catalog
B.Enable Amazon S3 event notifications for schema changes
C.Enable AWS Glue Data Catalog schema auto-update
D.Use AWS Glue crawlers to update the Data Catalog
AnswerD

Crawlers automatically discover schemas and update the Data Catalog.

Why this answer

AWS Glue crawlers can be configured to automatically detect and apply schema changes from source data stores to the Glue Data Catalog. When a crawler runs, it infers the schema of the data and updates the catalog tables accordingly, enabling schema evolution without manual intervention. This directly addresses the requirement for automatic updates when source table schemas change.

Exam trap

The trap here is that candidates may confuse the Glue Data Catalog's 'schema auto-update' with a non-existent feature, or assume that S3 event notifications can directly trigger catalog updates, when in fact only Glue crawlers provide the automated schema detection and update capability required for this use case.

How to eliminate wrong answers

Option A is wrong because using AWS Lambda to manually update the Data Catalog introduces unnecessary complexity and still requires custom code to detect schema changes, defeating the purpose of automatic updates. Option B is wrong because Amazon S3 event notifications only trigger on object-level events (e.g., PUT, DELETE) in S3, not on schema changes in source tables, and they cannot directly update the Glue Data Catalog schema. Option C is wrong because there is no native 'schema auto-update' feature in the Glue Data Catalog; the correct mechanism for automatic schema detection and update is through Glue crawlers, not a standalone toggle.

274
MCQhard

A team is fine-tuning a foundation model using LoRA in SageMaker. They want to reduce memory usage during training. Which instance type is optimized for cost-effective fine-tuning with LoRA?

A.ml.g5.2xlarge
B.ml.p3.2xlarge
C.ml.c5.2xlarge
D.ml.trn1.2xlarge
AnswerA

g5 instances offer a good balance of performance and cost for fine-tuning with LoRA.

275
MCQhard

A data scientist is preprocessing time series data for a fraud detection model. The data includes transaction timestamps, amounts, and merchant IDs. The model should predict fraud within seconds of a transaction. The data scientist wants to avoid data leakage by not using future information to predict past events. Which data preparation practice should be implemented?

A.Compute features like lagged transaction amounts and rolling statistics based only on each transaction's past data up to that point.
B.Randomly shuffle the dataset before splitting into training and validation sets.
C.Generate features such as rolling averages and lag features using a sliding window of all available data.
D.Normalize the features using MinMaxScaler on the entire dataset before splitting into training and testing.
AnswerA

This ensures no future information is used.

Why this answer

It ensures that features are computed using only historical data available up to each transaction's timestamp, preventing any future information from leaking into the model. In time series fraud detection, using only past data for lagged amounts and rolling statistics respects the temporal order and avoids the model learning patterns that would not be available at prediction time.

Exam trap

AWS often tests the concept of temporal data leakage by presenting options that seem statistically sound (like shuffling or global normalization) but violate the time series assumption, leading candidates to overlook the need for chronological feature engineering.

How to eliminate wrong answers

Option B is wrong because randomly shuffling the dataset breaks the temporal order of time series data, causing future transactions to appear in the training set and past transactions in the validation set, which introduces data leakage and invalidates the model's ability to predict in real time. Option C is wrong because generating rolling averages and lag features using a sliding window of all available data includes future values relative to each transaction, which leaks information from the future into the feature set. Option D is wrong because normalizing features using MinMaxScaler on the entire dataset before splitting uses global statistics (min and max) computed from the full dataset, including future data, which leaks information and biases the scaling.

276
MCQmedium

A company uses SageMaker Clarify to detect bias in their training data. They find that the model has a high disparate impact for a protected attribute. What should they do to mitigate this bias during training?

A.Use SageMaker Clarify’s built-in bias mitigation algorithm during training
B.Remove the protected attribute from the dataset
C.Increase the model complexity to capture more patterns
D.Preprocess the data using techniques like reweighing or resampling to reduce bias
AnswerD

Bias mitigation often involves preprocessing steps such as reweighing or resampling.

Why this answer

SageMaker Clarify can generate bias reports, but mitigation techniques like reweighing or using bias-aware algorithms are applied separately. Adjusting the threshold does not address training bias. Removing the attribute may not eliminate indirect bias.

Using a different algorithm may help but is not the direct mitigation step from Clarify.

277
MCQhard

A company's SageMaker real-time endpoint is experiencing high latency under load. The CloudWatch metrics show that the ModelLatency is acceptable, but the OverheadLatency is spiking. What is the most likely cause?

A.The request payload size is too large.
B.The SageMaker endpoint is not in the same VPC as the client.
C.The endpoint is under-provisioned with insufficient instance count.
D.The model inference code is inefficient.
AnswerC

When the endpoint is under-provisioned, SageMaker overhead increases due to queuing and container startup, spiking OverheadLatency.

Why this answer

OverheadLatency measures the time spent on infrastructure overhead (e.g., request routing, network I/O, and container startup) rather than model inference. When the endpoint is under-provisioned with too few instances, requests queue up, causing the SageMaker front-end to wait for a free worker, which directly inflates OverheadLatency while ModelLatency (pure inference time) remains unaffected.

Exam trap

The trap here is that candidates confuse OverheadLatency with network latency or client-side delays, and assume VPC misconfiguration (Option B) is the cause, when in fact OverheadLatency is a server-side metric that spikes due to insufficient instance count causing request queuing.

How to eliminate wrong answers

Option A is wrong because large request payloads primarily increase ModelLatency (due to longer deserialization and inference time) and total latency, but they do not specifically spike OverheadLatency, which is the time spent in the SageMaker infrastructure layer. Option B is wrong because VPC placement affects network latency and connectivity, but OverheadLatency is measured server-side within the SageMaker endpoint service, not the client-to-endpoint network round trip; a VPC mismatch would cause connection failures or increased network latency, not a spike in the server-side overhead metric. Option D is wrong because inefficient inference code directly increases ModelLatency, not OverheadLatency; the question explicitly states ModelLatency is acceptable, ruling out code inefficiency as the cause.

278
MCQmedium

A data scientist has trained a binary classification model for fraud detection. The dataset is highly imbalanced (99% non-fraud, 1% fraud). After evaluation, the model shows an accuracy of 99%, but the recall for fraud cases is only 10%. Which metric should the data scientist prioritize to improve the model's performance for fraud detection?

A.Log loss
B.F1-score
C.Precision
D.Area under the ROC curve (AUC-ROC)
AnswerB

F1-score is the harmonic mean of precision and recall, making it a balanced metric for imbalanced classification.

Why this answer

F1-score balances precision and recall, making it more informative than accuracy for imbalanced datasets. AUC-ROC is also used but F1 directly addresses the trade-off between false positives and false negatives. Precision alone does not capture recall, and Log loss does not directly indicate recall improvement.

279
MCQmedium

A team uses SageMaker Clarify to monitor bias drift on a deployed model. They have defined a baseline with training data and set up a monitoring schedule. After one month, they receive a violation report indicating that the post-training metrics have deviated from the baseline. What does this violation indicate?

A.The model's predictions relative to sensitive attributes have shifted compared to the training baseline
B.The SHAP values for features have changed
C.The model's predictions are becoming less accurate
D.The distribution of input features has changed
AnswerA

Bias drift monitoring tracks predefined fairness metrics over time, and a violation indicates a significant change in those metrics.

Why this answer

SageMaker Clarify bias drift monitoring compares predicted outcomes (post-training) against the baseline to detect changes in fairness metrics like disparate impact. It does not measure prediction accuracy or data quality.

280
MCQmedium

A team is using Amazon SageMaker Processing for data preprocessing. They have a Parquet dataset in Amazon S3. Which configuration will provide the most efficient reading of the dataset during processing?

A.Read the Parquet files as text using SparkContext.textFile
B.Split the dataset into many small Parquet files (e.g., 1 MB each)
C.Convert the Parquet files to CSV before processing
D.Read the Parquet files directly using SparkSession.read.parquet
AnswerD

Leverages Parquet's efficiency and schema.

Why this answer

SageMaker Processing natively integrates with Apache Spark, and reading Parquet files directly via `SparkSession.read.parquet` leverages columnar storage, predicate pushdown, and compression (e.g., Snappy) to minimize I/O and deserialization overhead. This approach is far more efficient than text-based or format-conversion methods, as Parquet is optimized for analytical workloads and preserves schema information.

Exam trap

AWS often tests the misconception that many small files improve parallelism, but in distributed systems like Spark on SageMaker, small files increase S3 API call overhead and scheduler latency, making larger Parquet files (e.g., 128 MB–1 GB) far more efficient for reading.

How to eliminate wrong answers

Option A is wrong because `SparkContext.textFile` reads data as plain text lines, which is incompatible with binary Parquet format and would result in corrupted data or require manual parsing, losing all columnar optimization. Option B is wrong because splitting the dataset into many small 1 MB Parquet files increases S3 LIST and GET request overhead, causing task scheduling delays and poor I/O throughput due to excessive file metadata operations. Option C is wrong because converting Parquet to CSV before processing introduces unnecessary serialization/deserialization costs, increases data size (CSV lacks compression and columnar storage), and discards schema and type information, leading to slower read performance.

281
MCQhard

A financial services company is deploying a real-time fraud detection model using Amazon SageMaker. The model is a gradient boosting model (XGBoost) trained on historical transaction data. The inference endpoint uses an ml.m5.2xlarge instance with a single variant. Recently, the company has experienced a 3x increase in transaction volume during peak hours, causing inference latency to exceed the 200ms SLA. The data science team has already optimized the model by reducing the number of trees and feature set, but the latency remains high during spikes. The team considers using SageMaker's built-in scaling policies. They currently have a single endpoint with one production variant. The team wants to maintain low latency without over-provisioning resources. They have ruled out model changes. Which approach should the team take?

A.Configure an Application Auto Scaling target tracking scaling policy for the variant based on the 'SageMakerVariantInvocationsPerInstance' metric, with a target value that keeps the inference latency within the SLA.
B.Deploy the model on multiple endpoints behind an Application Load Balancer.
C.Use scheduled scaling to increase the instance count during known peak hours.
D.Manually increase the instance count during peak hours.
AnswerA

This auto-scales based on load.

Why this answer

SageMaker's built-in target tracking scaling policy using the 'SageMakerVariantInvocationsPerInstance' metric allows the endpoint to automatically adjust the instance count based on real-time invocation load. By setting a target value that correlates with the 200ms SLA, the policy dynamically scales out during traffic spikes and scales in during lulls, preventing over-provisioning while maintaining low latency. This approach directly addresses the 3x peak-hour volume increase without requiring manual intervention or model changes.

Exam trap

The trap here is that candidates may confuse scheduled scaling (Option C) as a valid solution for predictable peaks, but the question's emphasis on 'real-time' and 'without over-provisioning' points to dynamic scaling, which target tracking provides; scheduled scaling cannot adapt to unexpected volume variations within the peak window.

How to eliminate wrong answers

Option B is wrong because deploying multiple endpoints behind an Application Load Balancer adds unnecessary complexity and does not leverage SageMaker's native auto-scaling capabilities; it also introduces additional latency from the load balancer and requires manual management of endpoint distribution. Option C is wrong because scheduled scaling assumes predictable peak hours, but the question states the volume increase occurs 'during peak hours' which may vary day-to-day; scheduled scaling cannot react to real-time spikes and may over-provision or under-provision if the timing shifts. Option D is wrong because manually increasing the instance count during peak hours is reactive, error-prone, and violates the requirement to avoid over-provisioning; it also requires constant human monitoring and cannot scale down automatically when traffic subsides.

282
MCQeasy

A machine learning engineer wants to automatically track hyperparameters, metrics, and artifacts for multiple training runs. Which SageMaker feature should they use?

A.SageMaker Debugger
B.SageMaker Model Monitor
C.SageMaker Experiments
D.SageMaker Clarify
AnswerC

Experiments track hyperparameters, metrics, and artifacts for each training run.

Why this answer

SageMaker Experiments is purpose-built for tracking and comparing training runs, capturing parameters, metrics, and artifacts.

283
MCQhard

A financial services company deploys a fraud detection model on a SageMaker real-time endpoint. The inference logic includes a pre-processing step that requires access to a DynamoDB table for user metadata. The model container is a custom Docker image. How should the team grant the endpoint access to DynamoDB?

A.Store IAM credentials in the container image as environment variables
B.Attach an IAM instance profile to the underlying EC2 instance
C.Create an IAM role with DynamoDB read access and assign it to the SageMaker endpoint as the execution role
D.Retrieve temporary credentials from AWS Secrets Manager within the container code
AnswerC

SageMaker assumes the execution role to access other AWS services.

Why this answer

SageMaker endpoints require an IAM execution role to be assigned at creation time. This role defines the permissions the endpoint's container has when making AWS API calls, such as reading from DynamoDB. By attaching a policy with DynamoDB read access to this execution role, the endpoint securely obtains temporary credentials via the AWS STS service, eliminating the need to hardcode or manage long-term credentials.

Exam trap

The trap here is that candidates confuse SageMaker endpoints with EC2-based deployments and incorrectly think they need to manage instance profiles or embed credentials, when in fact SageMaker abstracts the underlying compute and uses an execution role for all API access.

How to eliminate wrong answers

Option A is wrong because storing IAM credentials as environment variables in a container image is a security anti-pattern; credentials would be baked into the image, exposed in the container's environment, and not automatically rotated. Option B is wrong because SageMaker endpoints do not run on EC2 instances that you manage; they run on SageMaker-managed infrastructure, so attaching an instance profile to an underlying EC2 instance is not applicable. Option D is wrong because while Secrets Manager can store credentials, the container code would still need permissions to access Secrets Manager itself, and the standard, simpler approach is to use the endpoint's execution role rather than managing temporary credentials manually.

284
MCQmedium

A data scientist is performing text preprocessing for a sentiment analysis model. The dataset contains many stop words and rare words. Which combination of preprocessing steps will reduce dimensionality and improve model performance?

A.Remove all words shorter than 3 characters and apply label encoding
B.Only tokenization without any removal
C.Tokenization, stop-word removal, and TF-IDF
D.Tokenization and one-hot encoding of words
AnswerC

These steps reduce dimensionality by removing common words and weighting terms by importance.

Why this answer

Tokenization, stop-word removal, and TF-IDF vectorization reduce dimensionality by filtering common words and weighting important terms. Lemmatization can further reduce sparsity.

285
MCQhard

An organization uses SageMaker Studio and needs to restrict Studio's internet access while allowing users to install custom packages from a private PyPI mirror hosted in a VPC. Which networking configuration should they use?

A.Use a NAT gateway to allow outbound traffic to the private PyPI mirror
B.Disable internet access for Studio and rely on SageMaker's default VPC configuration
C.Disable internet access for Studio and configure VPC-only mode, then use a VPC endpoint to the private PyPI mirror
D.Enable internet access for Studio and use a VPC endpoint to the private PyPI mirror
AnswerC

VPC-only mode blocks internet; VPC endpoint to the private mirror allows package installation from the VPC.

Why this answer

SageMaker Studio in VPC-only mode (no internet access) combined with VPC-only mode for the domain and VPC endpoints to private PyPI mirror enables package installation from the private mirror. NAT gateway or internet gateway would allow internet access, which is not desired.

286
MCQeasy

An organization needs to ensure that all data used for inference on a SageMaker endpoint is encrypted at rest. The endpoint uses a SageMaker-provided container. Which configuration should be applied?

A.Use a custom container with built-in encryption
B.Specify a KMS key in the endpoint configuration
C.Enable network isolation mode
D.Enable inter-container traffic encryption
AnswerB

A KMS key encrypts the ML storage volume attached to the endpoint, ensuring data at rest is encrypted.

Why this answer

SageMaker endpoints use AWS KMS for encryption at rest. By specifying a KMS key in the endpoint configuration, the data in the attached ML storage volume is encrypted. Inter-container traffic encryption is for encryption in transit.

287
MCQeasy

A data engineer is setting up a Glue ETL job to process a large dataset stored in Amazon S3. The job needs to read data in Parquet format, apply a filter, and write the results back to S3 in Parquet. The engineer wants to minimize the cost and runtime. Which optimization technique is MOST effective?

A.Increase the number of DPUs to the maximum allowed.
B.Use column pruning to read only the columns needed in the transformation.
C.Convert the data to JSON format for faster read performance.
D.Use a single large file instead of partitioning.
AnswerB

Column pruning reduces I/O by reading only relevant columns, minimizing data scanned and speeding up the job.

Why this answer

Using column pruning (reading only necessary columns) reduces the amount of data scanned, which directly reduces I/O and cost, especially in Parquet format. Other options are also optimizations but column pruning typically has the biggest impact for wide datasets.

288
Multi-Selecthard

A company is running a SageMaker endpoint serving multiple models. They need to monitor for data drift and model quality. Which THREE actions are necessary? (Choose three.)

Select 3 answers
A.Deploy a shadow endpoint for comparison
B.Enable data capture on the endpoint
C.Use SageMaker Debugger for monitoring
D.Create a SageMaker Model Monitor schedule
E.Configure baseline constraints from training data
AnswersB, D, E

Data capture logs inference requests for monitoring.

Why this answer

Enabling data capture on the SageMaker endpoint is a prerequisite for monitoring data drift and model quality. Data capture automatically records input requests and output responses from the endpoint, which SageMaker Model Monitor later analyzes against a baseline to detect drift. Without data capture, there is no data to compare against the baseline constraints.

Exam trap

The trap here is that candidates confuse SageMaker Debugger (for training) with SageMaker Model Monitor (for inference), leading them to select Debugger instead of the correct monitoring schedule and baseline configuration.

289
MCQmedium

A financial services company trains multiple models on SageMaker and needs to track hyperparameters, metrics, and artifacts for each experiment. Which SageMaker feature should they use to organize and compare experiments?

A.SageMaker Model Registry
B.SageMaker Pipelines
C.SageMaker Experiments
D.SageMaker Debugger
AnswerC

SageMaker Experiments is designed to track and compare training runs, including hyperparameters and metrics.

Why this answer

SageMaker Experiments provides experiment management, allowing users to track parameters, metrics, and artifacts, and compare runs. SageMaker Studio offers an interface but the core feature is Experiments.

290
MCQhard

A company operates an e-commerce platform that uses a machine learning model to recommend products to users. The model is deployed on an Amazon SageMaker endpoint with automatic scaling enabled based on average CPU utilization. The model was trained on historical data and is updated weekly. Recently, the platform experienced a flash sale event that caused a sudden spike in traffic. During the event, the endpoint's latency increased dramatically, and many requests timed out. After the event, the team reviews the CloudWatch metrics and notices that the CPU utilization never exceeded 70%, and the scaling policy was triggered but instances took several minutes to become available. The team wants to prevent similar issues in future flash sales. Which course of action would be MOST effective?

A.Use predictive scaling based on historical traffic patterns.
B.Lower the CPU utilization threshold for the scaling policy to 40%.
C.Switch to larger instance types to handle higher CPU loads.
D.Implement scheduled scaling to add capacity ahead of known flash sales.
AnswerD

Scheduled scaling pre-warms instances, avoiding cold start delays.

Why this answer

Scheduled scaling allows you to proactively add capacity ahead of known traffic events like flash sales, eliminating the cold-start delay that occurs when reactive scaling policies (like those based on CPU utilization) must launch new instances. During the flash sale, the scaling policy was triggered but instances took minutes to become available, causing timeouts; scheduled scaling pre-warms the endpoint by adjusting the desired instance count before the traffic spike hits.

Exam trap

The trap here is that candidates assume reactive scaling (lowering thresholds or using predictive scaling) can handle sudden spikes, but the exam tests your understanding that provisioning latency is the bottleneck, and only proactive scheduled scaling can eliminate that delay for known events.

How to eliminate wrong answers

Option A is wrong because predictive scaling relies on historical traffic patterns to forecast future demand, but a flash sale is an irregular, planned event that may not follow those patterns, and predictive scaling still involves a delay in provisioning instances. Option B is wrong because lowering the CPU threshold to 40% would cause the scaling policy to trigger earlier, but it does not address the fundamental issue that new instances take several minutes to become available (cold-start latency), so requests would still time out during that provisioning window. Option C is wrong because switching to larger instance types increases the per-instance capacity but does not eliminate the cold-start delay when scaling out; during a sudden spike, even larger instances would eventually be overwhelmed if the scaling action itself is too slow.

291
MCQeasy

A SageMaker Processing job fails with 'Access Denied' when listing objects in an S3 bucket, despite the IAM policy shown in the exhibit. What is the most likely cause?

A.The policy lacks `s3:ListBucket` permission.
B.The role does not have a trust relationship with SageMaker.
C.The bucket policy denies the access.
D.The bucket is in a different region.
AnswerA

ListBucket is required to list objects; GetObject alone is insufficient.

Why this answer

The error 'Access Denied' when listing objects in an S3 bucket indicates that the IAM role used by the SageMaker Processing job lacks the `s3:ListBucket` permission. This permission is required for the `ListObjectsV2` API call, which is necessary to enumerate objects in the bucket. Even if the role has `s3:GetObject` and `s3:PutObject` permissions, without `s3:ListBucket`, the job cannot list the bucket contents and will fail with an access denied error.

Exam trap

AWS often tests the distinction between `s3:ListBucket` (required for listing objects) and `s3:GetObject` (required for reading objects), leading candidates to incorrectly assume that having `s3:GetObject` alone is sufficient for all S3 read operations.

How to eliminate wrong answers

Option B is wrong because a missing trust relationship between the IAM role and SageMaker would cause the job to fail at the role assumption stage, not during S3 operations; the error would be 'AssumeRole' related, not 'Access Denied' for S3. Option C is wrong because while a bucket policy could deny access, the question states the IAM policy shown in the exhibit is the only policy under consideration, and bucket policies are evaluated separately; if a bucket policy denied access, the error would still be 'Access Denied', but the most likely cause given the exhibit is the missing `s3:ListBucket` permission in the IAM policy. Option D is wrong because S3 buckets in different regions are accessible via cross-region requests; the error 'Access Denied' is an authorization issue, not a regional routing issue, and SageMaker Processing jobs can access buckets in any region as long as permissions are correctly configured.

292
MCQeasy

An ML team wants to deploy a model that was trained using XGBoost in SageMaker. They want to use the built-in XGBoost algorithm container for inference. Which inference option requires the least custom code?

A.Create a custom Docker container with XGBoost and deploy to an endpoint
B.Deploy to a real-time endpoint using the built-in XGBoost container
C.Attach Elastic Inference to a generic container
D.Use SageMaker Python SDK to download the model and run local inference
AnswerB

The built-in container handles inference automatically.

Why this answer

The built-in XGBoost container in SageMaker is pre-configured with the XGBoost serving stack, including the necessary inference code and dependencies. Deploying a model trained with XGBoost to a real-time endpoint using this container requires no custom inference script or Docker image, only the model artifact and endpoint configuration. This minimizes custom code to just the SageMaker SDK calls for creating the model and endpoint.

Exam trap

AWS often tests the misconception that Elastic Inference can accelerate any ML model, but it is specifically designed for deep learning models and does not apply to tree-based algorithms like XGBoost.

How to eliminate wrong answers

Option A is wrong because creating a custom Docker container with XGBoost introduces unnecessary custom code and maintenance overhead, whereas the built-in container already provides the same functionality. Option C is wrong because Elastic Inference is an acceleration technology for deep learning models (e.g., TensorFlow, PyTorch) and is not compatible with XGBoost, which is a gradient boosting framework; attaching it to a generic container would not reduce custom code and would be architecturally incorrect. Option D is wrong because using the SageMaker Python SDK to download the model and run local inference moves the inference workload outside of SageMaker's managed infrastructure, requiring custom orchestration code and defeating the purpose of a managed deployment.

293
MCQhard

A machine learning engineer is using Amazon SageMaker Data Wrangler to prepare a dataset for a regression model. After applying a StandardScaler to numeric features, the target variable has a mean of 50 and standard deviation of 20. Which additional step should the engineer take to reduce model bias?

A.Apply MinMaxScaler to the target variable
B.Use SageMaker Clarify to evaluate bias in the dataset
C.Apply one-hot encoding to all categorical features
D.Remove all features with a correlation above 0.8
AnswerB

Clarify can detect bias in data and models, which is the correct approach.

Why this answer

SageMaker Clarify is specifically designed to detect various types of bias in datasets and models, including regression bias. Even after standard scaling, the target variable's distribution (mean=50, std=20) may still contain systemic biases related to sensitive attributes (e.g., race, gender). SageMaker Clarify computes bias metrics such as Conditional Demographic Disparity in Labels (CDDL) and can identify whether the model's predictions are unfairly skewed across demographic groups, which is the direct step needed to reduce model bias.

Exam trap

The trap here is that candidates confuse data preprocessing steps (scaling, encoding, feature selection) with bias detection and mitigation, assuming any transformation that changes the data distribution will reduce bias, whereas only dedicated bias evaluation tools like SageMaker Clarify can identify and quantify bias in the dataset or model.

How to eliminate wrong answers

Option A is wrong because applying MinMaxScaler to the target variable is a normalization technique that changes the scale but does not address or reduce model bias; it only transforms the range to [0,1] without evaluating or mitigating unfairness across groups. Option C is wrong because one-hot encoding categorical features is a data preprocessing step for handling categorical variables, not a bias detection or mitigation technique; it does not identify or reduce bias in the target variable or model predictions. Option D is wrong because removing features with high correlation (>0.8) is a feature selection method to reduce multicollinearity, which can improve model stability but does not directly address bias related to sensitive attributes or target variable distribution.

294
MCQhard

A financial services company is deploying a credit risk model using SageMaker. They require that the model always uses the latest approved version from the Model Registry. They also need to maintain a detailed audit trail of all model version transitions (e.g., from PendingApproval to Approved). The deployment should be fully automated and must roll back immediately if the new model's error rate exceeds the old model's error rate by more than 2% during a canary deployment. Which solution meets these requirements with the least custom code?

A.Use AWS CodePipeline with a deployment action that uses AWS CloudFormation to update the endpoint. Add a manual approval step for rollback.
B.Use SageMaker Pipelines with a conditional step to deploy the model after approval, and include a canary deployment using a weight endpoint variant. Use CloudWatch alarms to trigger automatic rollback.
C.Create an AWS Lambda function that is triggered by Model Registry events, deploys the model to a staging endpoint, runs a canary test, and if successful, updates the production endpoint.
D.Use an Amazon EKS cluster with a custom inference container and use ArgoCD for automated deployments.
AnswerB

Pipelines natively integrate with Model Registry, conditional logic, and CloudWatch for automated canary and rollback.

Why this answer

SageMaker Pipelines natively supports conditional execution and canary deployments using endpoint weight variants, which together enable automated rollback triggered by CloudWatch alarms when the error rate exceeds the 2% threshold. This approach requires minimal custom code by leveraging built-in SageMaker capabilities for model registry integration, deployment, and monitoring.

Exam trap

The trap here is that candidates may overcomplicate the solution by choosing custom Lambda or Kubernetes options, missing that SageMaker Pipelines provides a fully managed, code-minimal way to orchestrate canary deployments with automated rollback via CloudWatch alarms.

How to eliminate wrong answers

Option A is wrong because it relies on a manual approval step for rollback, which violates the requirement for fully automated rollback; CloudFormation alone does not provide canary deployment or automatic error-rate comparison. Option C is wrong because it requires custom Lambda code to handle model registry events, canary testing, and endpoint updates, which contradicts the 'least custom code' requirement; SageMaker Pipelines already provides these capabilities natively. Option D is wrong because using Amazon EKS with ArgoCD introduces unnecessary complexity and custom infrastructure, and does not integrate directly with SageMaker Model Registry or provide built-in canary deployment with error-rate-based rollback.

295
MCQhard

A company wants to serve a large ensemble of models using NVIDIA Triton Inference Server on SageMaker for high throughput GPU inference. Which SageMaker inference option supports this?

A.Asynchronous Inference
B.Multi-model endpoint
C.Serverless Inference
D.Real-time endpoint with a custom container running Triton
AnswerD

Customers can bring their own Triton container to SageMaker real-time endpoints for optimal GPU inference.

Why this answer

SageMaker supports Triton Inference Server through a custom real-time endpoint container, as Triton is optimized for GPU serving on NVIDIA hardware.

296
MCQhard

A data engineer is using Amazon SageMaker Data Wrangler to create a data preparation flow for a dataset with 500 columns, many of which are highly correlated. The goal is to reduce dimensionality while preserving interpretability. Which built-in transform in Data Wrangler should be applied?

A.Imputation
B.Principal Component Analysis (PCA)
C.StandardScaler
D.Feature Selection (correlation-based)
AnswerD

Data Wrangler's feature selection transform can remove highly correlated features, preserving interpretability.

Why this answer

The goal is to reduce dimensionality while preserving interpretability. SageMaker Data Wrangler's built-in Feature Selection (correlation-based) transform identifies and removes highly correlated columns, directly reducing the number of features without transforming the original variables into new, uninterpretable components. This preserves the meaning of each selected column, which is essential when interpretability is a priority.

Exam trap

The trap here is that candidates often confuse dimensionality reduction with PCA, assuming it is always the best choice, but the question explicitly requires preserving interpretability, which PCA inherently sacrifices.

How to eliminate wrong answers

Option A is wrong because imputation is used to fill missing values, not to reduce dimensionality or handle correlated columns. Option B is wrong because Principal Component Analysis (PCA) creates new orthogonal components that are linear combinations of original features, which reduces dimensionality but destroys interpretability since the components are not directly tied to the original columns. Option C is wrong because StandardScaler only standardizes features by removing the mean and scaling to unit variance; it does not reduce the number of columns or address correlation.

297
MCQhard

A machine learning engineer is using SageMaker Automatic Model Tuning (AMT) to optimize hyperparameters for a random forest model. The engineer notices that the tuning job is taking too long and many hyperparameter combinations are being evaluated but not improving the objective metric. Which action should the engineer take to make the tuning more efficient?

A.Switch the strategy from Bayesian to random search
B.Use a smaller instance type for each training job
C.Increase the maximum number of training jobs
D.Enable early stopping for the tuning job
AnswerD

Early stops poorly performing trials, reducing wasted computation.

Why this answer

Enabling early stopping in SageMaker Automatic Model Tuning (AMT) terminates poorly performing training jobs before they complete, which reduces wasted compute time and speeds up the tuning process. This is especially effective when using Bayesian optimization, as it allows the algorithm to focus on promising hyperparameter regions and avoid evaluating combinations that are unlikely to improve the objective metric.

Exam trap

The trap here is that candidates may confuse early stopping with reducing instance size or changing search strategies, not realizing that early stopping directly addresses wasted computation on poor trials without sacrificing search quality.

How to eliminate wrong answers

Option A is wrong because switching from Bayesian to random search would likely make the tuning less efficient, as random search does not use past results to guide future evaluations and often requires more trials to find optimal hyperparameters. Option B is wrong because using a smaller instance type for each training job reduces per-job compute capacity, which can slow down individual training runs and may not address the core issue of evaluating many unproductive combinations. Option C is wrong because increasing the maximum number of training jobs would evaluate even more hyperparameter combinations, prolonging the tuning job and potentially increasing wasted resources without improving efficiency.

298
MCQhard

A team uses SageMaker Pipelines to train and register a model. They want to conditionally run a hyperparameter tuning step only if the data quality check passes. Which pipeline step type should they use to branch the execution?

A.TuningStep
B.TrainingStep
C.ConditionStep
D.TransformStep
AnswerC

Why this answer

The ConditionStep allows comparing values and branching to different steps. If data quality passes, the tuning step runs; otherwise, the pipeline stops or runs an alternative step. Other steps do not provide conditional branching.

299
MCQmedium

A company uses SageMaker Model Monitor to track feature attribution drift with SHAP. They notice that the SHAP values have changed significantly for a feature, while the model performance remains stable. What is the MOST likely interpretation?

A.The ground truth labels are incorrect, causing the drift
B.Data drift has occurred for that feature
C.The model is learning equally from all features, so no action is needed
D.The model's behavior has changed, which may lead to future performance degradation and warrants investigation
AnswerD

Feature attribution drift often precedes concept drift; it should be investigated.

Why this answer

A significant change in SHAP values indicates that the model's internal feature importance has shifted, even if overall performance metrics like accuracy or loss remain stable. This is a classic sign of concept drift or model behavior drift, where the model's decision boundary has changed for that feature, which can lead to future performance degradation as the drift accumulates. SageMaker Model Monitor tracks feature attribution drift separately from data drift, and a change in SHAP values without data drift suggests the model is relying on the feature differently, warranting investigation.

Exam trap

The trap here is that candidates confuse feature attribution drift (SHAP drift) with data drift, assuming a change in SHAP values must be caused by a change in the input data distribution, when in fact it indicates a change in the model's learned behavior that can occur independently of data drift.

How to eliminate wrong answers

Option A is wrong because incorrect ground truth labels would typically cause a drop in model performance metrics (e.g., accuracy, precision) when evaluated, but the scenario states model performance remains stable, so label errors are not the primary cause. Option B is wrong because data drift refers to changes in the distribution of input features themselves, not changes in the model's attribution of importance to those features; SHAP drift is a separate concept from data drift. Option C is wrong because the model learning equally from all features is not indicated by SHAP value changes; significant SHAP drift for a single feature suggests the model's behavior has changed, and ignoring it could lead to future issues, so action is needed.

300
MCQeasy

Which SageMaker built-in algorithm is specifically designed for time series forecasting?

A.Image Classification
B.BlazingText
C.DeepAR
D.XGBoost
AnswerC

DeepAR is designed for time series forecasting.

Why this answer

DeepAR is a supervised learning algorithm for forecasting scalar time series using recurrent neural networks. The other algorithms are for different tasks: XGBoost for classification/regression, BlazingText for NLP, and Image Classification for computer vision.

Page 3

Page 4 of 12

Page 5