Generative AI Engineer Associate · 22% of the exam

Assembling and deploying applications: free practice questions

5 sample questions from our 55-question bank for this domain — answers and explanations included. These are the same scenario-based style as the real Databricks exam.

1. An ML engineer enables an inference table on a Model Serving endpoint serving a RAG chatbot. After generating several requests, they query the inference table in Unity Catalog but notice the table has not yet been populated. Which of the following is the MOST likely reason?

  • A. Inference tables only capture requests when the endpoint workload_size is set to 'Large'.
  • B. Inference logging writes data asynchronously and there may be a delay of a few minutes before records appear in the table.✓ Correct
  • C. Inference tables require an additional paid add-on license that has not been enabled on the workspace.
  • D. The chain model must be logged with mlflow.set_tag('inference_table', 'true') before inference logging will activate.
Explanation

Inference tables on Databricks Model Serving are populated asynchronously. There is a typical delay (often a few minutes) before request and response records appear in the Unity Catalog Delta table. This is expected behavior and does not indicate a configuration problem. Inference table availability is not gated by workload_size; it works across all sizes. There is no separate add-on license specifically for inference tables — it is a feature of the Model Serving product. No MLflow tag is required on the model artifact to enable inference logging; it is configured at the endpoint level.

2. A team wants to roll back their production RAG chain endpoint from Version 3 back to Version 2 as quickly as possible after detecting a regression. They have both versions registered in Unity Catalog. Which approach achieves the FASTEST rollback with the LEAST risk?

  • A. Delete the endpoint and recreate it pointing to Version 2, then update the client application's endpoint URL.
  • B. Update the served entity configuration of the existing endpoint to point to Version 2 at 100% traffic, which modifies the existing endpoint in place without changing the endpoint URL.✓ Correct
  • C. Unregister Version 3 from Unity Catalog, which automatically causes the endpoint to fall back to the last available version.
  • D. Reassign the 'production' alias in Unity Catalog from Version 3 to Version 2; the endpoint will automatically stop serving Version 3 immediately.
Explanation

The fastest and least-risk rollback is to update the existing endpoint's traffic configuration to route 100% of traffic to Version 2. This is an in-place update that does not change the endpoint URL (no client reconfiguration needed) and Databricks handles the transition gracefully. Deleting and recreating the endpoint causes downtime during recreation and requires updating any clients that reference the endpoint URL. Unregistering a model version from Unity Catalog does not automatically cause a serving endpoint to fall back to a previous version — the endpoint will enter an error state. While updating a Unity Catalog alias is useful for endpoint configurations that reference aliases, if the endpoint was configured with an explicit version number (Version 3), changing the alias alone has no immediate effect on the endpoint's traffic.

3. A team has deployed a RAG chain to a Model Serving endpoint. They enable an inference table so that all requests and responses are logged. After sending several queries, they check the Delta table but find it is empty. Which of the following is the MOST likely cause?

  • A. Inference table data is written with a delay; the table may not be populated immediately after requests are sent✓ Correct
  • B. Inference tables only capture requests when the endpoint is running on GPU workload types
  • C. The inference table must be manually flushed by calling a Databricks REST API endpoint before data appears
  • D. Inference tables require the chain to explicitly call `mlflow.log_metric()` inside the `predict()` method to trigger logging
Explanation

Option A is correct: inference table writes are asynchronous and batched, so there is an inherent delay (often several minutes) between when requests are served and when data appears in the Delta table. Engineers should wait before concluding the table is empty. Option B is wrong: inference tables work for all workload types including CPU. Option C is wrong: there is no manual flush API required; data is written automatically in the background. Option D is wrong: inference table logging is automatic at the serving infrastructure level and does not require any changes to the model's `predict()` code.

4. A Generative AI engineer logs a chain with the following code: ```python with mlflow.start_run() as run: mlflow.langchain.log_model( lc_model=chain, artifact_path="rag_chain", input_example={"messages": [{"role": "user", "content": "What is RAG?"}]} ) ``` Later, they load the model for local testing using `mlflow.pyfunc.load_model()`. Which URI format should they use to load this specific run's model artifact?

  • A. `runs:/<run_id>/rag_chain`✓ Correct
  • B. `models:/<model_name>/latest`
  • C. `dbfs:/mlflow/artifacts/<run_id>/rag_chain`
  • D. `mlflow:/<experiment_id>/<run_id>/rag_chain`
Explanation

Option A is correct: the `runs:/<run_id>/<artifact_path>` URI scheme is the standard MLflow format for referencing an artifact logged within a specific run, and it works with `mlflow.pyfunc.load_model()`. Option B is wrong: `models:/` URIs reference registered model versions, not raw run artifacts, and `latest` is not a valid stage/version designator in Unity Catalog. Option C is wrong: the raw DBFS path can technically work in some configurations but is not the idiomatic or recommended MLflow URI scheme and is fragile across workspaces. Option D is wrong: there is no `mlflow:/` URI scheme in the MLflow Python client.

5. A team has deployed a RAG chain to a Databricks Model Serving endpoint. The chain requires an API key for an external embedding service. The engineer stores the key as a Databricks secret with scope 'genai_secrets' and key 'embed_api_key'. How should this secret be surfaced inside the serving endpoint's environment so the chain code can read it via os.environ.get('EMBED_API_KEY')?

  • A. Pass the secret value directly in the endpoint configuration's environment_vars field as plain text.
  • B. In the endpoint configuration, set environment_vars to {'EMBED_API_KEY': '{{secrets/genai_secrets/embed_api_key}}'} so Databricks resolves the reference at runtime.✓ Correct
  • C. Mount the secret as a volume inside the serving container and read it from the file system instead of environment variables.
  • D. Store the secret in a Delta table and have the chain code query the table at startup to retrieve the key.
Explanation

Databricks Model Serving supports a secret reference syntax in environment_vars: '{{secrets/<scope>/<key>}}'. At endpoint startup, Databricks resolves this reference and injects the actual secret value as an environment variable, keeping the key out of plaintext configuration. Passing the key as plain text in the configuration is a security anti-pattern and exposes the secret in API responses and logs. Mounting volumes is not a supported pattern for secrets in Databricks Model Serving. Reading from a Delta table at startup requires granting the endpoint additional data access permissions and is an unnecessarily complex approach compared to the native secret reference mechanism.

50 more questions in this domain

Practice the full bank with instant grading, flashcards, and a timed mock exam.

Start practicing free