Importing a predictive model
Import predictive models from third-party tools to predict customer actions. You can import PMML and H2O models.
You can import models from both H2O-3 and H2O Driverless AI platforms. For a list of supported PMML and H2O models, see Supported models for import.
- For PMML models, download the model in
- For H2O-3 models, download the model in
- For H2O Driverless AI models, download and extract the MOJO Scoring Pipeline file as a
If you want to import a model from the H2O Driverless AI platform, specify the Driverless AI license key and import the H2O implementation library. For more information, see Specifying the H2O Driverless AI license key and Importing the H2O implementation library.
- In the navigation pane of Prediction Studio, click Models.
- In the header of the Models work area, click .
- In the New predictive model dialog box, enter a Name for your model.
- In the Create model section, click Import model.
- Click Choose file, and then select a model file to import.For Driverless AI models, in the
mojo-pipelinefolder, select the
- In the Context section, specify the model context:
Choices Actions Save your model in the default application context Select the Use default context check box.
For more information, see Configuring the default rule context.
Save your model in a custom context
- Click the Apply to class field, press the Down arrow key, and then select the class in which you want to save the model.
- Define the class context by selecting appropriate values from the Development branch, Add to ruleset, and Ruleset version lists.
- Verify the settings, and then click Next.
- Optional: To change the default label for the model objective, in the Outcome
definition section, click Set labels, and then enter a
meaningful name in the associated field.
Note: To capture responses for the model, the model objective label that you specify should match the value of the .pyPrediction parameter in the response strategy (applies to all model types).
- In the Outcome definition section, specify what the model
Scenarios Actions You are importing a binary outcome model
- In the Monitor the probability of field, select the outcome that you want to predict.
- In the Advanced section, enter the expected score range.
- In the Classification output field, select one of the model outputs to classify the model.
You are importing a continuous outcome model
- In the Predicting list, select A continuous value.
- In the Predicting values between fields, enter values for the range of outcomes that you want to predict.
You are importing a categorical outcome model In the Predicting section, verify the categories to predict.
- Optional: To compare actual model performance against expected model performance, in the
Expected performance field, enter a value that represents the
expected predictive performance of the model.The performance measurement metrics are different for each model type. For more information, see Metrics for measuring predictive performance.
- Confirm the model settings by clicking Import.
- On the Mapping tab, associate the model predictors with Pega Platform properties.For more information, see Editing an imported model.
- Specifying the H2O Driverless AI license key
Import predictive models from the H2O Driverless AI platform by first providing your license key.
- Importing the H2O implementation library
Enable the import of predictive models from the H2O Driverless AI platform, by importing the H2O implementation library to Pega Platform.
- Editing an imported model
After importing a predictive model from a PMML file or an H2O MOJO file, map the model predictors to Pega Platform properties. You can also update the outcome definition settings.
- Configuring custom functions of a PMML model
PMML functions transform data in PMML models. These models include several predefined functions that are defined as Java code in the Pega PMML execution engine. Additionally, PMML producers sometimes use proprietary expressions (functions) with the PMML models that are not part of the models themselves. These functions are used for various reasons (such as performance increase or enhancements). In such cases, the PMML model contains custom functions (the model contains only references to the functions and their parameters).
- XSD validation and PMML error messages
When you upload a PMML file in the Predictive Model rule and want to save it, the file is parsed and checked for any syntactic errors. The contents of the PMML file is validated against the respective version of the XSD schema that is specified in the file. The following table lists the error that might occur.
- Supported models for import
Learn more about the PMML and H2O models that you can import to Prediction Studio.
Previous topic Template categories for creating predictive models Next topic Specifying the H2O Driverless AI license key