Databricks Generative AI Engineer Associate Question 87
Select 4You are developing a generative AI application on Databricks that uses a fine-tuned large language model (LLM) to generate personalized customer responses. To ensure efficient application development, you need to integrate the model with a REST API for real-time predictions. Which of the following steps are essential to deploy and integrate the model in Databricks?
- A
Save the fine-tuned model to a Databricks MLflow model registry.
- B
Deploy the model as a REST API endpoint using Databricks Model Serving.
- C
Train the model directly on the REST API server for better latency.
- D
Use Databricks Repos to version control the API development code.
- E
Implement request validation and error handling in the REST API.
Show answer and explanation
Correct answers: A, B, D, E
Explanation
To deploy and integrate a model for real-time predictions using a REST API in Databricks, it is essential to save the model in the MLflow model registry for tracking and versioning, deploy it using Databricks Model Serving for efficient inference, and use proper version control tools like Databricks Repos for collaborative development. Additionally, implementing request validation and error handling enhances the reliability of the REST API. Training the model directly on the REST API server is not recommended as it is inefficient and goes against best practices.
- A. Correct.
Correct: Saving the fine-tuned model to the Databricks MLflow model registry ensures proper versioning, tracking, and accessibility for deployment.
- B. Correct.
Correct: Deploying the model as a REST API endpoint using Databricks Model Serving allows real-time inference and seamless integration with applications.
- C. Incorrect.
Incorrect: Training directly on the REST API server is not a best practice as it compromises scalability and efficiency. Training should occur in the Databricks environment before deployment.
- D. Correct.
Correct: Using Databricks Repos for version control ensures collaborative development and proper management of API-related code.
- E. Correct.
Correct: Request validation and error handling are critical in REST API design to ensure reliability and robustness in handling real-time traffic.