Databricks Generative AI Engineer Associate exam dumps

Databricks Generative AI Engineer Associate practice question 185 of 306

Databricks Certified Generative AI Engineer Associate. Free level, Databricks. Free question with the correct answer and a full explanation.

Databricks Generative AI Engineer Associate Question 185

Select 3

You are building a machine learning workflow in Databricks using a pyfunc model. The model requires input data to be scaled before inference and the prediction output to be converted into a human-readable format. Which of the following steps are necessary to implement this workflow using a pyfunc model with pre- and post-processing?

  1. A

    Define a custom Python function that handles both pre-processing and post-processing in the pyfunc model's predict method.

  2. B

    Use separate libraries for pre-processing and post-processing, and chain their outputs manually outside the pyfunc model.

  3. C

    Package the pre-processing and post-processing logic together with the core model using MLflow pyfunc's custom model class.

  4. D

    Use Databricks AutoML to automatically generate pre- and post-processing steps for the pyfunc model.

  5. E

    Test the pyfunc model locally with sample data to validate the pre- and post-processing logic before deployment.

Show answer and explanation

Correct answers: A, C, E

Explanation

To implement a workflow using a pyfunc model with pre- and post-processing, you need to define a custom Python function for the predict method, package all logic into the pyfunc model using MLflow's custom model class, and test the model locally to validate its functionality. This approach ensures an efficient and cohesive deployment of the entire machine learning workflow.

  • A. Correct.

    Correct: A custom Python function in the pyfunc model's predict method allows you to handle both pre-processing and post-processing within the same model workflow, ensuring end-to-end functionality.

  • B. Incorrect.

    Incorrect: While this approach might work, it is not specific to the pyfunc model and does not leverage the built-in flexibility of the pyfunc model to encapsulate the entire workflow.

  • C. Correct.

    Correct: Packaging the pre- and post-processing logic with the core model using MLflow pyfunc's custom model class ensures that all steps are combined and managed as a single package.

  • D. Incorrect.

    Incorrect: Databricks AutoML does not automatically generate pre- and post-processing logic for a pyfunc model. Manual implementation is required.

  • E. Correct.

    Correct: Testing the pyfunc model locally ensures that the pre- and post-processing logic works as intended before deploying to production.

Timed practice exam

Take a Databricks Generative AI Engineer Associate practice test under exam conditions

45 questions in 90 minutes, drawn from this bank, with a score report and a per-question review when you finish.

Start timed exam