Related Documentation Download this Manual
PDF (US Ltr) - 1.6Mb
PDF (A4) - 1.6Mb

MySQL HeatWave User Guide  /  ...  /  Model Explanations

3.13.7 Model Explanations

In MySQL 8.0.30, a model explanation is generated when you train a machine learning model using the ML_TRAIN routine. As of MySQL 8.0.31, use the ML_EXPLAIN routine to train a model explainer for the model and produce a model explanation. The model explanation is stored in the model_explanation column in the MODEL_CATALOG table.

A model explanation helps you identify the features that are most important to the model overall. Feature importance is presented as a numerical value ranging from 0 to 1. Higher values signify higher feature importance, lower values signify lower feature importance, and a 0 value means that the feature does not influence the model.

The following example retrieves the model explanation for the census model:

mysql> SELECT model_explanation FROM ML_SCHEMA_user1.MODEL_CATALOG 
          WHERE model_handle=@census_model;


  • ML_SCHEMA_user1.MODEL_CATALOG is the fully qualified name of the MODEL_CATALOG table. The schema is named for the user that created the model.

  • @census_model is the session variable that contains the model handle.