Extract historical customer responses from adaptive models in your application
for offline analysis. You can also build a model in a machine learning service of your
choice, based on the historical responses
that
you extract.
When you enable the recording of historical data for a selected adaptive model, Pega Platform extracts historical customer responses from the model, and
then stores the responses as a JSON file in a repository of your choice for 30 days. You
can store the JSON file for a longer or shorter period of time by configuring the
corresponding dynamic system setting.
By default, Pega Platform extracts historical responses only from
adaptive models in production environments. You can enable the extraction of historical
responses in non-production environments, for example, to test your workflow.
Before you begin:
- Determine where you want to save the historical data JSON files by specifying a
repository for adaptive models data.
For more information, see Specifying a repository for Prediction Studio models.
- If you want to extract historical data in non-production level environments too,
change the value of the
decision/adm/archiving/captureProductionLevel dynamic
system setting to All.
You can also extract historical
data only in a selected production level environment by setting the
decision/adm/archiving/captureProductionLevel
dynamic system setting to a corresponding level number, for example,
5 for development environments. For a list of
production level numbers, see Specifying the production level.
Enable recording historical data for a selected adaptive
model.
-
In the navigation pane of Prediction Studio, click Models.
-
In the Models workspace, open the adaptive model for which
you want to record historical data.
-
In the Settings tab, in the Recording
historical data section, select the Record historical
data check box.
-
In the Sample percentage sections, specify what percentage
of all positive and negative customer responses you want to sample for the
historical data JSON file:
-
In the Positive outcome field, enter a
percentage for positive outcomes.
-
In the Negative outcome field, enter a
percentage for negative outcomes.
Note: The higher the sample percentage, the more space you need for storing the
data
set.
To
sample all historical customer responses, enter
100.0 in both fields.
For example: A
web banner typically has a significantly lower number of
positive responses (banner clicks), than negative responses (banner
impressions). In such cases, you can specify the sample percentage as
follows:
- Positive outcome
100.0 %
- Negative outcome
1.0 %
-
Confirm your settings by clicking Save.
-
To change how much time elapses between saving a
historical data JSON file and deleting the file from your repository, change the
value of the decision/adm/archiving/daysToKeepData dynamic
system setting.
Important: By default, Pega Platform deletes JSON
files with a time stamp older than 30 days.
- Optional:
To
access a list of all adaptive models along with the path of the historical data
repository, in the navigation pane
of Prediction Studio, click .
On the Historical data screen, you can also access
information about the percentage of positive and negative responses that
Pega Platform includes for each adaptive model.
What to do next: Learn more about the structure of the JSON file in which
Pega Platform saves the historical data. For more information,
see JSON file structure for historical data.