Skip to main content


         This documentation site is for previous versions. Visit our new documentation site for current releases.      
 

Artificial intelligence-based lead ranking

Updated on October 26, 2021

The Pega Sales Automation application uses decisioning capabilities to provide predictive lead scores for lead ranking. The lead score predicts how likely it is that a lead will turn into an opportunity.

Pega Sales Automation Implementation Guide Pega Sales Automation Implementation Guide Pega Sales Automation Implementation Guide Pega Sales Automation Implementation Guide Pega Sales Automation Implementation Guide

This helps to focus on the most promising leads to maximize sales.

Lead score overview

The lead score is displayed on the Leads list page. The lead score is dynamic and responds to changes in the lead properties.

For example, the lead score changes when you change the number of activities that are associated with the lead. The lead score can also change when you change the lead source.

Historical data and adaptive learning

The Pega Sales Automation application uses self-learning, adaptive models to generate the lead score.

This approach is based on core decision management capabilities. If needed, add or remove predictors. For more information, see Artificial intelligence-based opportunity insights.

Historical data

The adaptive model provides a set of key predictors that are based on the analysis of data from real production environments. For example, the system uses:

  • Production data to create weekly snapshots for each closed lead over one-year period
  • Records to define core predictors
  • Records to train the adaptive models

The following predictors are provided in the Pega Sales Automation adaptive model:

B2C model predictorsB2B model predictors
IndustryContactAge
LeadAgeLeadAge
LeadSourceLeadSource
LeadRatingLeadRating
NumberOfActivitiesNumberOfActivities
NumberOfActivitiesByPhoneNumberOfActivitiesByPhone
NoOfActivitiesByMeetingNoOfActivitiesByMeeting
NumberOfActivitiesByEmailNumberOfActivitiesByEmail
ValidEmailValidEmail
ValidWorkPhoneValidWorkPhone
ExistingCustomerExistingCustomer
LeadsContactActivitiesLeadsContactActivities
LeadsContactInEmailCount
LeadsContactOutEmailCount
NumberOfWonOpportunitiesNumberOfWonOpportunities
AvgTimeToConvertLeadsAvgTimeToConvertLeads
DownloadCount
WebsiteVisitCount
OrgSubscribeCount

Adaptive learning

A Job Scheduler DailySnapshotsForLead runs daily and executes a data flow that calls a decision strategy. A decision strategy contains the Lead Ranking adaptive model, which represents properties to capture the data that is required by the models. A decision strategy uses the standard Delayed Learning cache.

When a lead is converted to an opportunity or closed without being converted, the system uses crmUpdatePredictors declare trigger to execute a response strategy from a data flow to retrieve the data for relevant decisions and train the applicable models.

Lead ranking architecture

Lead ranking architecture is based on the following concepts:

  • A data set for storing predictor values and lead scores
  • Capturing of the predictors value and lead score using declare triggers
  • Daily snapshots of leads
  • Capture of adaptive model response
  • Data pages
  • Data flows
  • Strategies
  • Adaptive models

Data set for storing predictors value and lead score

The application pre-calculates predictors used in adaptive models and saves the predictors in a database using a data set at the time of creating the lead and whenever these values are changed using a declare trigger. The application also calculates and stores the lead score in the database.

With this approach, the lead score is not calculated on the fly which improves performance.

Data setLeadPredictorData
ClassPegaCRM-Data-SFA-LeadPredictors
DB tablelead_ranking_predictors_history

Declare trigger for capturing predictor values and lead scores

The triggers below are defined on different work objects to capture values in LeadPredictorData data set.

Activity casecrmUpdateLeadPredictors
Opportunity caseCrmOnOpportunityWon
Lead casecrmUpdatePredictors, crmUpdateLeadPredictorsOnChangeContact

Daily snapshot of leads

For delayed learning, the adaptive model captures the daily snapshot of leads. The job scheduler DailySnapshotsForLead runs every day to capture the daily snapshot of the lead. Job scheduler runs LeadSnapshots data flow for B2B leads and LeadIndSnapshots data flow for B2C leads.

Capture of adaptive model response

The adaptive model’s responses are captured using a declarative rule when leads are closed or converted.

The crmUpdatePredictors declare trigger runs EvaluateLeadRankAndCaptureResponse data flow to capture the responses.

Data pages

D_crmLeadsList
The lead score in the leads list runs in the context of the D_crmLeadsList data page. The D_crmLeadList data page has the crmLeadsListWithScore report definition data source, which retrieves all lead information from the database. The system uses the data and the crmLeadsListPostLoad rule in post-load processing.
D_LeadScore
D_LeadScore is used to fetch lead score from lead_ranking_predictors_history DB table for each individual lead.

To view details for each data page, perform the following steps:

  1. In the navigation pane of Dev Studio, click RecordsData ModelData Page.
  2. To open the data page record, click a data page name.

Data flows

StoreLeadSnapshots (B2B)
The StoreLeadSnapshots data flow uses the lead data from the production environment. The StoreLeadSnapshots data flow converts each record from the PegaCRM-Data-SFA-LeadTrainingPredictors class into lead objects. After that, the system routes converted records to the EvaluateLeadRanking B2B strategy. Use the Make decision and store data for later response capture mode for the EvaluateLeadRanking strategy.
StoreIndividualLeadSnapshots (B2C)
The StoreIndividualLeadSnapshots data flow uses the lead data from the production environment. The StoreIndividualLeadSnapshots data flow converts each record from the PegaCRM-Data-SFA-LeadTrainingPredictors class into lead objects. After that, the system routes converted records to the EvaluateLeadRanking B2C strategy. Use the Make decision and store data for later response capture mode for the EvaluateLeadRanking strategy.
CaptureLeadOutcomes (B2B)
The LeadRankingOutcomes report definition is the input for the CaptureLeadOutcomes data flow. The LeadRankingOutcomes report definition retrieves one record per lead from the historical predictors data table, sorted by the maximum snapshot date. The system then retrieves the outcome for each lead. The CaptureLeadOutcomes data flow calls the LeadRankingCloseProbation data flow.
CaptureIndividualLeadOutcomes (B2C)
The LeadRankingOutcomes report definition is the input for the CaptureIndividualLeadOutcomes data flow. The LeadRankingOutcomes report definition retrieves one record per lead from the historical predictors data table, sorted by the maximum snapshot date. The system then retrieves the outcome for each lead. The CaptureIndividualLeadOutcomes data flow calls the LeadRankingCloseProbation data flow.
RankLead
The RankLead data flow runs on a demand basis. The system invokes the RankLead data flow by using the CalculateLeadScore activity for each lead to calculate the lead score. The RankLead data flow collects predictor properties for each lead and the lead static data. After the system collects lead static and predictor properties data, it routes the data to the EvaluateLeadRanking strategy to calculate the lead score. Use the Make decision mode for the EvaluateLeadRanking strategy.

To view the data flow details, perform the following steps:

  1. In the navigation pane of Dev Studio, click RecordsData ModelData Flow.
  2. Select a data flow to open it and view the data flow record.

Strategies

The following are the lead ranking strategies:

  • EvaluateLeadRanking
  • CloseLead

To view details for each strategy, perform the following steps:

  1. In the navigation pane of Dev Studio, click RecordsDecisionStrategy.
  2. To open the strategy record, click a strategy name.

Adaptive models

The lead architecture includes the LeadRanking adaptive model that provides predictors based on the historical data. The input predictor range should be as complete as possible before training the adaptive models to predict outcome propensities based on your use cases, configure predictors, context, and outcomes for the adaptive model.

To view the adaptive models details, perform the following steps:

  1. In the navigation pane of Dev Studio, click RecordsDecisionAdaptive Model.
  2. Select an adaptive model to open it and view the adaptive model record.
    1. To set lead ranking outcomes, define positive or negative outcome values on the Outcomes tab.
    2. To view the advanced settings, such as performance monitoring or data analysis binning, open the Settings tab.

Extending lead ranking

You can extend lead ranking by adding predictors in the Lead ranking adaptive mode.

  1. In Dev Studio, search and open the Lead Ranking adaptive model. Use Save as to save it to the implementation layer Lead class.
  2. Use the existing property of Lead class or create a property in the implementation layer Lead class and add it to the Lead Ranking adaptive model as a predictor.
  3. Optional: Perform the steps below, if this property value is not captured directly in Lead case, for example NumberOfActivities or NumberOfActivitiesByPhone:
    1. Create a property with the same name in the PegaCRM-Data-SFA-LeadPredictors class and optimize it for reporting.
    2. Search for the SetPredictorsOnCreateLead_Ext and open it. Use Save as to save it to the implementation layer Lead class and set the newly created property value according to the calculation for which you created the property.
    3. Search for CopyPredictors_Ext and open it. Use Save as to save it to the implementation layer Lead class. Perform property set on the newly created property from .Predictors.<Newly created property>
    4. Save and update this property value in PegaCRM-Data-SFA-LeadPredictors whenever it is changed. Refer any of the declare triggers mentioned above in this document.

  • Previous topic Artificial intelligence-based sales coach
  • Next topic Activating and training adaptive models for artificial intelligence

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega.com is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us