Databricks Generative AI Engineer Associate · Section 4 · 22% of the exam
Develop an appropriate interactive user facing interface for an agent usage scenario (Apps, Slack, Teams, etc.)
One of the objectives of the Databricks Certified Generative AI Engineer Associate exam, in the section “Assembling and Deploying Applications”. Here is what it covers, the points to remember and a question to try.
What it covers
An LLM application calls Foundation Model API endpoints, runs on its own serving endpoint or app, authenticates to the Databricks resources it uses, and reaches users through an interface. This lesson covers the serving options, the three authentication methods for serving endpoints, when to use ai_query() for batch inference instead of a real-time endpoint, and how to pick a user interface such as Databricks Apps, Slack or Microsoft Teams.
Points to remember
- Foundation Model APIs: pay-per-token (prototype and moderate traffic), provisioned throughput (guaranteed throughput, fine-tuned models, compliance), AI Functions for batch.
- Serve the application separately: log, register in Unity Catalog, deploy (
agents.deploy()for agents). It then calls the Foundation Model API endpoint. agents.deploy()sets up the endpoint, short-lived credentials, the Review App, tracing and inference tables. A new version of the same UC model updates the same endpoint.- Automatic passthrough: declare
resourceswhen logging. A system service principal per model version gets short-lived OAuth credentials, and the deployer's access is verified. - On-behalf-of-user (Public Preview):
UserAuthPolicy(api_scopes=...),ModelServingUserCredentials, create the client insidepredict. Needs MLflow 2.22.1+ and admin enablement.
Try a question
A sales agent answers questions from a Unity Catalog table with row filters, so each sales rep may see only their own territory. The agent is served on Model Serving. Which authentication approach enforces the row filters for each caller?
- AOn-behalf-of-user auth with a
UserAuthPolicy, building the user client inpredict - BAutomatic authentication passthrough with a
DatabricksTableresource declared at logging time - CManual authentication with one service principal whose OAuth secret is stored in a secret scope
- DGranting the endpoint's CAN QUERY permission only to members of the sales team
Show the answer
A. On-behalf-of-user authentication (Public Preview, MLflow 2.22.1 or later, enabled by a workspace admin) runs downstream calls as the end user with the API scopes you declare in UserAuthPolicy. Because the user is known only at request time, the client is built with ModelServingUserCredentials inside predict.
Written for practice in the style of the exam: never a question from the real exam.
In the course
The lesson Serving, securing and exposing LLM applications teaches this objective (about 55 minutes), and 15 practice questions test it. The course has lessons, exam-style questions, timed practice exams and an AI tutor for every objective, and a pass prediction that tells you when you're ready to book.
More in this section
- Code a chain using a pyfunc model with pre- and post-processing
- Control access to resources from model serving endpoints
- Code a simple chain according to requirements
- Choose the basic elements needed to create a RAG application: model flavor, embedding model, retriever, dependencies, input examples, model signature
- Register the model to Unity Catalog using MLflow
- Create and query a Vector Search index
- Identify how to serve an LLM application that leverages Foundation Model APIs
- Explain the key concepts and components of Mosaic AI Vector Search
- Identify batch inference workloads and apply ai_query() appropriately
- Configure vector search for a particular solution based on number of embeddings, update frequency, latency, and cost requirements
- Configure a persistent datastore to store and retrieve intermediate memory or structured information
- Apply CI/CD best practices such as updating a Vector Search index, promoting prompts across environments, and testing individual components of an agent