Databricks Certified Machine Learning Associate

Question bank

Databricks logo

Databricks Certified Machine Learning Associate

databricks-certified-machine-learning-associate

41 Databricks Certified Machine Learning Associate questions with the correct answer and a written explanation, organised across 4 exam domains.

41 questions
4 domains
Foundation level

Question index

Jump straight to any question. Answers and explanations are inline.

Databricks Machine Learning

15 questions in this domain

  1. Question 1Single Choice

    What is the primary purpose of the Machine Learning persona in the Databricks workspace?

    • AA tailored UI that surfaces ML assetsCorrect answer
    • BA separate compute cluster for ML workloads
    • CAn automatic model deployment service
    • DA cloud storage account for datasets

    Why this is the answer

    The Machine Learning persona changes workspace navigation to highlight ML-specific assets; it does not provision compute or deployment resources.

  2. Question 2Multiple Select

    Which ML-specific assets appear in the left navigation sidebar when using the Databricks Machine Learning persona? (Select all that apply.)

    • AExperimentsCorrect answer
    • BModelsCorrect answer
    • CFeature StoreCorrect answer
    • DSQL warehouses

    Why this is the answer

    The Machine Learning persona surfaces Experiments, Models, and Feature Store in the left navigation; SQL warehouses are not part of this ML asset set.

  3. Question 3Interactive

    The code snippet in the code block sets a custom tracking URI inside a Databricks notebook. What is the recommended action?

    • ARemove it and use the managed tracking serverCorrect answer
    • BKeep it for all runs
    • CReplace localhost with a cloud database
    • DUse it only for model registry operations

    Why this is the answer

    Databricks provides a managed MLflow tracking server; hardcoding a tracking URI overrides the default and is not recommended.

  4. Question 4Single Choice

    What is the Databricks Runtime for Machine Learning?

    • AA cluster environment pre-loaded with ML librariesCorrect answer
    • BA standard runtime with no pre-installed packages
    • CA tool for manually managing CUDA drivers
    • DA cloud object storage service for models

    Why this is the answer

    DBR for ML is a preconfigured runtime with libraries such as TensorFlow, PyTorch, scikit-learn, and MLflow included.

  5. Question 5Multiple Select

    Which libraries are pre-installed in the Databricks Runtime for Machine Learning? (Select all that apply.)

    • ATensorFlowCorrect answer
    • BPyTorchCorrect answer
    • CXGBoostCorrect answer
    • DPostgreSQL JDBC driver

    Why this is the answer

    DBR for ML includes TensorFlow, PyTorch, scikit-learn, XGBoost, and MLflow out of the box.

  6. Question 6Interactive

    The code block shows a manual package installation step on a standard cluster. What is the recommended alternative for a machine learning workload?

    • AUse a Databricks Runtime for Machine Learning clusterCorrect answer
    • BKeep the install script
    • CRun the install on every node manually
    • DSwitch to CPU-only instances

    Why this is the answer

    The recommended best practice is to use DBR for ML, which already bundles the required ML libraries and avoids manual dependency management.

  7. Question 7Single Choice

    Which Databricks feature integrates Git version control directly into the workspace for notebooks and code?

    • ADatabricks ReposCorrect answer
    • BDBFS
    • CNotebook export
    • DCluster Policies

    Why this is the answer

    Databricks Repos provides native Git integration, allowing users to clone, branch, pull, push, and manage code inside the workspace.

  8. Question 8Multiple Select

    Which Git providers can be linked to Databricks Repos according to the documentation? (Select all that apply.)

    • AGitHubCorrect answer
    • BGitLabCorrect answer
    • CBitbucketCorrect answer
    • DMicrosoft Word

    Why this is the answer

    Databricks Repos supports Git providers such as GitHub, GitLab, and Bitbucket; Microsoft Word is not a Git provider.

  9. Question 9Interactive

    The code block shows a CLI command a user is considering for bringing a repository into Databricks. What is the correct approach?

    • AUse Databricks Repos to clone the repositoryCorrect answer
    • BUpload the repository as a notebook
    • CManually copy code into workspace folders
    • DUse DBFS CLI to sync the repository

    Why this is the answer

    Databricks Repos provides native Git cloning and synchronization, so users do not need to run external Git CLI commands.

  10. Question 10Single Choice

    What is an MLflow Experiment?

    • AA logical grouping of runsCorrect answer
    • BA single training execution
    • CA registered model version
    • DA deployment endpoint

    Why this is the answer

    An MLflow Experiment groups runs by use case or project, allowing users to compare parameters, metrics, and artifacts.

  11. Question 11Multiple Select

    Which capabilities are provided by the MLflow Model Registry? (Select all that apply.)

    • AModel versioningCorrect answer
    • BStage transitionsCorrect answer
    • CCI/CD webhooksCorrect answer
    • DEditing source datasets

    Why this is the answer

    The MLflow Model Registry supports versioning, stage transitions, webhooks, and governance, but it does not edit source datasets.

  12. Question 12Interactive

    The code block records several items for an MLflow run. Which item is stored as an artifact?

    • Aconfusion_matrix.pngCorrect answer
    • Blearning_rate
    • Caccuracy
    • Drun ID

    Why this is the answer

    mlflow.log_artifact() saves files such as plots and model binaries; parameters and metrics are logged separately.

  13. Question 13Single Choice

    What must happen before a model version can be managed in the MLflow Model Registry?

    • AIt must be explicitly registered with a nameCorrect answer
    • BIt is automatically registered on every run
    • COnly production models are registered
    • DIt requires manual deployment to a cluster

    Why this is the answer

    Logging a run does not automatically register a model. The model must be explicitly registered in the Model Registry.

  14. Question 14Multiple Select

    Which of the following are valid stages in the MLflow Model Registry? (Select all that apply.)

    • AStagingCorrect answer
    • BProductionCorrect answer
    • CArchivedCorrect answer
    • DDeployed

    Why this is the answer

    The valid MLflow Model Registry stages are None, Staging, Production, and Archived; Deployed is not a standard stage.

  15. Question 15Interactive

    The code block creates a training set using the Feature Store. What is the role of the timestamp_keys parameter?

    • APoint-in-time correctness to prevent leakageCorrect answer
    • BFaster model inference
    • CAutomatic model registry registration
    • DGPU memory allocation

    Why this is the answer

    timestamp_keys enable point-in-time joins, ensuring features are aligned with the exact event time and preventing data leakage.

ML Workflows

8 questions in this domain

  1. Question 16Single Choice

    What does an MLflow Project provide for packaging reusable machine learning code?

    • AA standard format for code, configuration files, and dependency definitionsCorrect answer
    • BA method for manually linking notebooks in sequence
    • CAn external scheduler for cloud infrastructure
    • DA storage format for large datasets

    Why this is the answer

    MLflow Projects package reusable data science code with configuration files and dependency definitions so that the same code can run consistently across environments.

  2. Question 17Multiple Select

    Which two Databricks components are essential for building reproducible multi-step ML pipelines?

    • AMLflow ProjectsCorrect answer
    • BDatabricks JobsCorrect answer
    • CInteractive notebooks only
    • DHardcoded workspace file paths

    Why this is the answer

    MLflow Projects define entry points and dependencies, while Databricks Jobs orchestrate tasks in production. Manual notebook linking and hardcoded paths are not reproducible pipeline best practices.

  3. Question 18Interactive

    Examine the provided code snippet. Which MLflow concept is being defined?

    • AAn MLflow Project entry pointCorrect answer
    • BA Databricks Job task DAG
    • CA Feature Store primary key definition
    • DA Model Registry stage transition

    Why this is the answer

    The code defines an MLproject file with a parameterized entry point, which is the standard format used by MLflow Projects.

  4. Question 19Single Choice

    What is the main purpose of point-in-time correctness in the Databricks Feature Store?

    • ATo prevent data leakage by joining features valid at the exact event timestampCorrect answer
    • BTo increase model training speed on large datasets
    • CTo automatically remove duplicate rows from feature tables
    • DTo manually configure cluster autoscaling

    Why this is the answer

    Point-in-time correctness performs time-travel joins between historical observations and feature values, preventing future feature data from leaking into training sets.

  5. Question 20Multiple Select

    Which two practices are recommended when managing feature tables in Databricks?

    • ASpecify primary keys when creating feature tablesCorrect answer
    • BUse the FeatureStoreClient to write and read feature tablesCorrect answer
    • CRead tables directly with spark.read.table for all operations
    • DSkip timestamp handling when joining features for training

    Why this is the answer

    Primary keys are mandatory for joins and online lookups, and the FeatureStoreClient preserves metadata for automated serving. Direct Spark reads and ignoring timestamps break feature store functionality.

  6. Question 21Interactive

    Look at the code snippet. What is the role of the primary_keys argument?

    • AIt enables point-in-time joins and online feature lookupsCorrect answer
    • BIt specifies the cluster size for the feature table
    • CIt determines the MLflow experiment name
    • DIt selects the model registry stage

    Why this is the answer

    Primary keys are required for point-in-time joins and automated online feature retrieval when serving models registered with Feature Store metadata.

  7. Question 22Single Choice

    What is the primary benefit of using task DAGs in Databricks Jobs?

    • ATasks run in the correct logical order based on dependenciesCorrect answer
    • BAll tasks must run simultaneously on the same cluster
    • CTasks are automatically written as SQL queries
    • DModel training is replaced by batch inference

    Why this is the answer

    Databricks Jobs supports directed acyclic graphs of tasks where dependencies determine the execution order, enabling reliable multi-step ML pipelines.

  8. Question 23Multiple Select

    Which two practices are considered common traps when orchestrating ML jobs?

    • AHardcoding hyperparameters across workflow tasksCorrect answer
    • BUsing internal notebook %run commands to manage dependenciesCorrect answer
    • CUsing MLflow autologging to capture model metrics
    • DConfiguring job alerts for failure notifications

    Why this is the answer

    Hardcoding parameters and chaining notebooks with %run create tight coupling and poor error handling. Native task dependencies and dynamic parameters are the recommended approaches.

Model Deployment

5 questions in this domain

  1. Question 24Single Choice

    Which Databricks capability is designed for automated, scheduled execution of machine learning models to score large datasets and store predictions in Delta Lake?

    • ABatch inference pipelinesCorrect answer
    • BReal-time model serving endpoints
    • CUnity Catalog
    • DMLflow experiment tracking

    Why this is the answer

    Batch inference pipelines score large data volumes on a schedule and store predictions in Delta Lake, unlike real-time endpoints.

  2. Question 25Multiple Select

    Which two statements accurately describe how Databricks Lakehouse Monitoring helps track production models? Choose two.

    • AAutomatically profiles data and logs metrics to DeltaCorrect answer
    • BDetects data drift and concept driftCorrect answer
    • CRequires an external monitoring tool
    • DStores prediction logs in MLflow Model Registry

    Why this is the answer

    Lakehouse Monitoring automatically profiles data, detects drift against a baseline, and writes metrics to Delta tables natively.

  3. Question 26Interactive

    The code block below is used to perform which primary task in a Databricks batch inference workflow?

    • ABatch scoring with a Spark UDFCorrect answer
    • BReal-time REST API serving
    • CModel registry registration
    • DTraining a new model

    Why this is the answer

    The code loads an MLflow model as a Spark UDF and writes scored predictions to a Delta Lake table.

  4. Question 27Single Choice

    In MLflow, what happens automatically each time a model is registered under an existing registered model name?

    • AThe model version number is incrementedCorrect answer
    • BThe model is promoted to Production
    • CThe previous model version is deleted
    • DA serving endpoint is created

    Why this is the answer

    Registering under an existing model name increments the version number, preserving earlier versions for auditability and rollback.

  5. Question 28Multiple Select

    Which two characteristics apply to Databricks Model Serving endpoints for real-time inference workloads? Choose two.

    • AAutomatic scaling of compute resourcesCorrect answer
    • BREST API for real-time inferenceCorrect answer
    • CManual Kubernetes cluster management
    • DBatch processing of terabytes with Spark

    Why this is the answer

    Model Serving endpoints expose a REST API and automatically scale infrastructure based on request load.

Model Development

13 questions in this domain

  1. Question 29Single Choice

    Which technology is used for distributed feature engineering at scale on Databricks?

    • AApache SparkCorrect answer
    • BPandas
    • CScikit-learn
    • DExcel

    Why this is the answer

    Apache Spark processes data across worker nodes, enabling scalable feature engineering. Single-node tools like Pandas are unsuitable for massive datasets.

  2. Question 30Multiple Select

    Which actions are common traps during large-scale data preparation in Databricks?

    • ACalling .toPandas() on a huge distributed DataFrameCorrect answer
    • BFitting scalers before splitting into training and validation setsCorrect answer
    • CUsing Delta Lake schema enforcement
    • DUsing Spark MLlib transformers

    Why this is the answer

    Collecting Spark data to the driver and fitting global transformations before splitting are common causes of OOM and data leakage.

  3. Question 31Interactive

    What issue is likely when executing the displayed code on a 500 GB Delta table?

    • ADriver out-of-memoryCorrect answer
    • BData leakage
    • CModel underfitting
    • DNetwork latency

    Why this is the answer

    Calling .toPandas() moves all data to the driver, which easily exhausts driver memory on multi-terabyte tables.

  4. Question 32Single Choice

    For a tabular dataset that fits in one node's memory, which library is most appropriate?

    • AScikit-learnCorrect answer
    • BSpark MLlib
    • CHorovod
    • DDelta Lake

    Why this is the answer

    Scikit-learn is ideal for in-memory tabular data. Spark MLlib is only necessary when data exceeds single-node memory.

  5. Question 33Multiple Select

    Which frameworks are described as distributed training options in the Databricks ecosystem?

    • AHorovodCorrect answer
    • BPyTorch LightningCorrect answer
    • CSpark MLlibCorrect answer
    • DSingle-node XGBoost

    Why this is the answer

    Horovod, PyTorch Lightning, and Spark MLlib support distributed training. Single-node XGBoost runs locally unless integrated with distributed backends.

  6. Question 34Interactive

    Why is the displayed Hyperopt configuration inappropriate for a multi-node Databricks cluster?

    • AUses Trials instead of SparkTrialsCorrect answer
    • BUses too many evaluations
    • CSpecifies an invalid search space
    • DForgets to log to MLflow

    Why this is the answer

    Hyperopt requires SparkTrials as the backend to distribute trials across cluster workers; standard Trials stays on the driver.

  7. Question 35Single Choice

    What does MLflow automatically record for each Hyperopt trial?

    • AParameters, metrics, and artifactsCorrect answer
    • BOnly model predictions
    • COnly the model weights
    • DNo run information

    Why this is the answer

    MLflow logs parameters, metrics, and artifacts for every trial, enabling comparison, reproduction, and best-model selection.

  8. Question 36Multiple Select

    Which metrics are recommended for evaluating an imbalanced classification model?

    • APrecisionCorrect answer
    • BRecallCorrect answer
    • CF1-scoreCorrect answer
    • DAccuracy

    Why this is the answer

    Precision, recall, and F1-score account for minority-class performance; accuracy is misleading when classes are imbalanced.

  9. Question 37Interactive

    What is the effect of executing the displayed code in a Databricks notebook?

    • ALogs the F1 metric to the current MLflow runCorrect answer
    • BTrains a classifier
    • CRegisters a model to Unity Catalog
    • DDeletes the current run

    Why this is the answer

    The snippet starts an MLflow run and logs a metric named f1 with value 0.87 to that run.

  10. Question 38Single Choice

    Which option is NOT one of the three Databricks AutoML task types?

    • AFeature StoreCorrect answer
    • BRegression
    • CClassification
    • DForecasting

    Why this is the answer

    AutoML supports regression, classification, and forecasting. Feature Store is a separate component, not an AutoML task type.

  11. Question 39Multiple Select

    Which advantages are provided by Databricks AutoML?

    • AGenerates fully commented Python notebooksCorrect answer
    • BUses Hyperopt for hyperparameter tuningCorrect answer
    • CLogs runs to MLflowCorrect answer
    • DHides all source code from users

    Why this is the answer

    AutoML generates editable notebooks, uses Hyperopt with MLflow tracking, and does not hide its code; it is white-box.

  12. Question 40Interactive

    What is the main problem with the preprocessing order shown in the code?

    • AData leakageCorrect answer
    • BDriver out-of-memory
    • CUnderfitting
    • DMissing value errors

    Why this is the answer

    Fitting scalers on the full dataset before splitting lets test-set statistics influence training, causing data leakage.

  13. Question 41Single Choice

    Which validation technique preserves the target class ratio in every fold?

    • AStratified K-foldCorrect answer
    • BStandard K-fold
    • CRandom train-test split
    • DTime-series split

    Why this is the answer

    Stratified K-fold partitions data while preserving class proportions across all folds, which is important for imbalanced targets.

Frequently asked questions

Everything about the Databricks Certified Machine Learning Associate question bank and how to use it.