Skip to main content

Using a scorecard in a decision strategy

Introduction

Learn how to use the segmentation result and the score value from a scorecard in a decision strategy. Learn how suitability rules can be defined to reflect the bank's requirements using a decision strategy. Also, learn the basics of strategy optimization.

Transcript

Currently, U+ Bank is cross-selling on the web by showing various credit cards to its customers.

The bank wants to implement a new requirement: All credit cards are suitable only for customers with a credit score greater than or equal to 600.

To implement this requirement, use an engagement policy that includes a decision strategy.

Strategy canvas with two shapes for an external input and the results

 

U+ Bank created a Scorecard that computes the credit score of the customer. To use the scorecard in the decision strategy, add a Scorecard component to the canvas and configure it.

Select the DetermineCreditScore scorecard model, which U+ Bank has already created.

If you open this scorecard, you can see how the system computes the credit score. Note that the three customer properties are in use, and a score is assigned to the value or range of values that the property can have.

You can also see the segment results. The scorecard returns Not Suitable result if the credit score is less than 600. Otherwise, it outputs a Suitable result.

To implement the new requirement, use a Filter component to express the condition under which the Actions are suitable.

You want this strategy to output something only if the result of the scorecard is "Suitable". The system stores the result of the scorecard in the pxSegment property. Therefore, set the filter condition to DetermineCreditScore.pxSegment=="Suitable".

If the result of the scorecard is Not Suitable, this strategy has no results.

Note that to reference a property from a component that is not connected to the Filter component, use the <ComponentName>.<PropertyName> construct.

The initial strategy

 

By using the External Inputs component, you can also create more complex conditions, where Action attributes are also in use.

Save the configurations.

Now, test the strategy by using Data Transform for Troy and Robert.

For external inputs, consider all credit cards available.

The result of the scorecard is Not Suitable. Therefore, the strategy did not output any results for Troy.

The result of the decision for the Troy customer profile

 

Now, repeat the test to verify the results for the Robert Data Transform. The strategy is also not producing any results for Robert, as the segment value is Not Suitable.

Now, assume the credit score value for customers is already computed and available in the Customer Data Model. However, this value is not set for certain customers, so you want to use the credit score determined by the scorecard itself. To implement this requirement, you must have both scores available and use a switch component to select the right credit score.

To make these adjustments, open the Scorecard component and then map the score computed by the scorecard to the CreditScore property. This component now outputs the scorecard calculation in the CreditScore property.

Score mapping.

Then, add a Set Property component, given that the credit score is already available for certain customers.

Use Add item to set the same CreditScore property to the available credit score value from the Customer Data Model.

Define the expression as Customer.CreditScore.

If set, this expression results in the credit score from the Customer Data Model.

The Set property properties dialog box

To select between the two credit scores, add a Switch component.

The decision strategy with the unconfigured Switch component

 

Set the name of the Switch component to Final Credit Score and configure the condition. To build the condition, use the Expression Builder. The condition reads:

Select Data Model Credit Score if @PropertyHasValue(Customer.CreditScore). Otherwise select Scorecard Credit Score.

@PropertyHasValue is a function that checks if a property has a value. In this case, it checks whether the CreditScore property of a customer has a value in the Customer Data Model.

The Switch properties dialog box

 

With this configuration, the Switch component selects the CreditScore Data Model only if the CreditScore property of a customer has a value. If the CreditScore property is empty or does not have a value, the Switch component continues to run the scorecard to calculate the CreditScore.

This configuration ensures that the Switch component optimizes the strategy by running the scorecard only for customers without a credit score in the external customer data. It effectively avoids redundant calculations and improves the efficiency of the decision strategy.

The arrows from Set Property and Scorecard Model components point to the Switch component. The system adds them automatically to ensure that the CreditScore values determined by these components are copied to the Switch component.

After you configure the Switch component, open the Filter component properties to modify the Filter condition. In this scenario, the bank decides to present various credit cards to suitable customers who have credit scores greater than or equal to 600.

So, open the Expression Builder to modify the condition as FinalCreditScore.CreditScore>=600.

Notice that the Filter component now references data from the Switch component.

The decision strategy with the configured Switch component

Save the configurations.

Re-test the strategy for the Troy and Robert data transforms.

Note that the strategy outputs results for Troy because his credit score, 625, is greater than 600.

If you open the Troy Data Transform, note that the CreditScore in the Data Model is 625.

The Switch component picks up the credit score value available in the Data Model (that is, CreditScore = 625) and prevents unnecessary calculation by the scorecard.

The strategy also outputs results for Robert because his credit score is 675. The Switch component also picks up the credit score value available in the Data Model for Robert.

Because you configured the strategy, check it in so that the strategy becomes available on the U+ Bank website.

Now, mark the strategy as a relevant record and associate it with the Suitability category to make it available in the Next-Best-Action Designer engagement policy configuration.

You can now configure this strategy in the Next-Best-Action Designer engagement policy as a suitability condition for the group-level Suitability Rules.

The Suitability condition

Select the strategy. The condition is Credit Score has results for the Credit Score >=600.

Save to complete all the required configurations.

On the U+ Bank website, if you log in as Troy, notice that a credit card offer is displayed. The offer is shown because credit cards are suitable for Troy.

Now, if you log in as Robert, notice that the credit card offer is also displayed.

You have reached the end of this video. What did it show you?

  • How to use the segmentation result and the score value of a scorecard in a decision strategy.
  • How to use the PropertyHasValue function to check whether a Customer property contains a value.
  • How to optimize the decision strategy by using a Switch component.

This Topic is available in the following Module:

If you are having problems with your training, please review the Pega Academy Support FAQs.

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 Academy has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice