databricks Generative AI Engineer Associate · Practice questions

Section 4: Assembling and Deploying Applications Practice Questions

Review 10 sample questions with their correct answers and explanations. Sign up free to continue with the full topic quiz.

Sign up free for the full quiz

Question 1

A team wants to enforce rate limits, log every request and response to a table, and track token usage for an LLM endpoint used by several applications. Which capability provides this?

  1. A cluster policy on the notebooks that call the endpoint
  2. A Lakeflow job that polls the endpoint every minute
  3. A Delta Sharing share for each application
  4. Mosaic AI Gateway configured on the serving endpoint — Correct

Correct answer

Mosaic AI Gateway configured on the serving endpoint

Explanation

AI Gateway adds rate limiting, usage tracking, payload logging (inference tables), guardrails and traffic routing to endpoints.

Question 2

A team wants to use a model from an external provider such as OpenAI or Anthropic, while centrally managing credentials and access in Databricks. What should be configured?

  1. A notebook that stores the provider's API key in plain text
  2. A Delta Sharing recipient for the provider
  3. A Lakehouse Federation connection to the provider's API
  4. An external model endpoint in Model Serving — Correct

Correct answer

An external model endpoint in Model Serving

Explanation

External models are served through Databricks endpoints, with credentials stored securely and access governed centrally.

Question 3

Which statement about the Foundation Model APIs on Databricks is correct?

  1. They cannot be called from SQL
  2. They require downloading model weights to a notebook
  3. They only support embedding models
  4. Hosted models behind OpenAI-compatible endpoints — Correct

Correct answer

Hosted models behind OpenAI-compatible endpoints

Explanation

Foundation Model APIs host chat, completion and embedding models accessible via REST, SDKs and ai_query.

Question 4

Which two items should be versioned to reproduce a RAG application's behavior? (Choose TWO.)

  1. The color of the UI theme
  2. The browser used for testing
  3. The prompt and agent code — Correct
  4. The chunk table version and index configuration — Correct
  5. The names of the developers' laptops

Correct answer

The prompt and agent code; The chunk table version and index configuration

Explanation

Behavior depends on code, prompts, models and data; all should be versioned.

Question 5

Which approach reduces cost for an LLM application that repeatedly answers identical frequent questions?

  1. Response caching — Correct
  2. Disable rate limits
  3. Use more chunks per request
  4. Increase max_tokens

Correct answer

Response caching

Explanation

Caching avoids recomputing identical responses.

Question 6

Which approach supports a safe rollout of a new agent version?

  1. Replace the old version for all users at once and delete it so rollback is impossible
  2. Route a small share of traffic to the new version and monitor before expanding — Correct
  3. Deploy it to a separate workspace that users cannot reach
  4. Release it to all users without evaluation, since production traffic is the best test

Correct answer

Route a small share of traffic to the new version and monitor before expanding

Explanation

Gradual rollout with monitoring limits impact if issues occur.

Question 7

A model serving endpoint should automatically scale down when unused to save cost for an internal pilot with sporadic use. Which setting fits?

  1. Disabling autoscaling with a fixed large size
  2. Adding fallbacks
  3. Provisioned throughput at maximum size
  4. Scale to zero — Correct

Correct answer

Scale to zero

Explanation

Scale to zero reduces cost for idle endpoints, at the price of cold starts.

Question 8

What does validating an agent before deployment typically include?

  1. Only checking that the notebook has no syntax errors in its cells
  2. Running VACUUM on the chunk table
  3. Loading it and running sample predictions — Correct
  4. Only checking the model's file size on disk

Correct answer

Loading it and running sample predictions

Explanation

Pre-deployment validation loads the logged model and checks it on representative inputs.

Question 9

Which SQL function sends a prompt to a model serving endpoint from a query, for example to summarize each row's text?

  1. vector_search
  2. http_request with format => 'llm'
  3. ai_similarity
  4. ai_query — Correct

Correct answer

ai_query

Explanation

ai_query calls a serving endpoint (foundation, external or custom) for each row.

Question 10

Which interface should a custom Python agent implement so that it can be logged with MLflow and deployed with Databricks agent tooling?

  1. A Spark ML Transformer with a transform method
  2. A SQL UDF registered in Unity Catalog
  3. An MLflow interface such as ResponsesAgent — Correct
  4. A Flask app with a /predict route

Correct answer

An MLflow interface such as ResponsesAgent

Explanation

MLflow agent interfaces define standard request and response schemas compatible with serving, evaluation and the Review App.

Ready for the full quiz?

Create a free QuizAnalyst account to practice the complete question set and save your progress.

Sign up free for the full quiz