You are here:
Configure a Use Case for Churn Prediction
Select the machine learning models and feature extractors that you want to use for predicting real-time churn. You can save computed features and prediction results in records.
- From Setup, in the Quick Find box, enter AI Accelerator, and then select AI Accelerator.
-
On the ChurnPredictionRealTime row, click Edit.
For information about configuring use cases, see Configure Your Use Case.
-
If you want to save the computed features, the prediction score, insights about the prediction score, and suggestions to improve the prediction score, select Customer Interaction as the primary response object.
After you map all the required fields of the object, the computed features and prediction results are stored in the Customer Interaction object as per specified field mappings.
-
If you want to configure a real-time feature extractor, select Minimize_Subscription_Churn_Customer_Interaction as the model and select RealtimeCaseFeatureExtractor as the Apex class.
To see the sample code of the RealtimeCaseFeatureExtractor Apex class, from Setup, in the Quick Find box, enter Apex, and then select Apex Classes. Open the RealtimeCaseFeatureExtractor class.The RealtimeCaseFeatureExtractor Apex class computes case-related features based on the latest case records.
The churn score that’s used to get recommendations is generated by the AI Accelerator Predictions API. The call to the AI Accelerator Predict API is made by using the Get Churn Score Apex action. The Get Churn Score Apex action uses the class SampleGetChurnScore in the SFI-NBARecommendationFlow. You can replace or extend the SampleGetChurnScore class. To see the sample code of this class, from Setup, in the Quick Find box, enter Apex, and then select Apex Classes. Open the SampleGetChurnScore class.

