Creating the Credit Offers Decision Strategy
6 Tasks
45 mins
Scenario
A financial institution wants to send cash loan credit offers to customers who request credit by using the company's Credit Risk Application service. As a Credit Risk Manager, you are tasked with designing a Credit Risk Decision Strategy that outputs Credit Offers, Credit Score, and Credit Eligibility. In the first phase of this task, you create a new Decision Strategy that outputs Credit Offers.
Offers are for customers over a certain age and are only available in some regions. To populate the Age property, you use the DateOfBirth property provided in the data model. To check the regional availability, you use a Decision Table.
The business wants to offer an alternative credit offer if the product requested by the customer is not approved. Also, the business has standard eligibility criteria that you need to apply.
The following table provides the credentials you need to complete the challenge:
Role | User name | Password |
---|---|---|
Credit Risk Manager | CreditRiskManager | rules |
Your assignment consists of the following tasks:
Task 1: Import the Cash Loan propositions
As a Credit Risk Manager, create a new Decision Strategy, and then add the three propositions in the Origination business issue Cash Loans group.
Task 2: Set properties
Use the DateOfBirth property to set the Age property, use the pyName property to set the IsAlternativeOffer and IsRequestedOffer properties to true or false, and then set the IsEligible property equal to the pxSegment property.
Task 3: Use a Data Transform to test the Decision Strategy
Use the TestCustomer Data Transform to test the Decision Strategy.
Task 4: Add a Region Code check
Availability of the credit offers depends on the region of the customer. Use a decision table to apply a Region Code check. CustomerLoanSpecialOffer is not available in Region Code 001, CustomerLoan is not available in Region Code 002, and the StudentLoan is not available in Region Code 001A.
Task 5: Use Default Criteria to select the eligible propositions
Use a Proposition Filter to select the eligible proposition by Default Criteria.
Task 6: Sort the propositions by offer amount
Sort the propositions to prioritize the proposition with the lowest MinAmount value.
Challenge Walkthrough
Detailed Tasks
1 Import the Cash Loan propositions
- On the exercise system landing page, click Launch Pega Infinity™ to log in to the Decision Management portal.
- Log in as a Credit Risk Manager:
- In the User name field, enter CreditRiskManager.
- In the Password field, enter rules.
- In the My Worklist section, click Credit risk strategy to open the change request.
- In the Scope of changes section, click Create > Decision > Strategy.
- On the Create Strategy landing page, in the Strategy Record Configuration section, in the Describe the purpose for this new record field, enter Credit Offers.
- In the Strategy Results class section, in the first field, select Origination.
- In the Context section, in the Apply to field, enter Data-CreditRiskCustomer.
- In the upper-right corner, click Create and open to open the strategy canvas.
- Right-click on the canvas, and then select Import > Proposition data to add the component to the canvas.
- Right-click the Proposition data component, and then select Properties to configure the component properties:
- In the Proposition data properties dialog box, in the Group list, select Cash Loans.
- Click Submit to close the Proposition data properties dialog box.
- In the Proposition data properties dialog box, in the Group list, select Cash Loans.
2 Set properties
- Right-click on the canvas, and then select Enrichment > Set property to add the component to the canvas.
- Hover over the Proposition Data component, and then click and drag the grey arrow to connect it to the Set Property component.
- Right-click the Set Property component, and then select Properties to configure the component properties.
- In the Set property properties dialog box, in the Name field, enter Set Offer Properties.
- On the Target tab, in the Define action, target, and source section, click Add item to configure the Age property:
- In the Target field, enter or select .Age.
- In the Source field, click the Gear icon to open the Expression builder.
- In the Expression builder, enter
@DateTimeDifference(@dateValue(Primary.DateOfBirth),@today(),"Y"), and then click Test. - In the DateOfBirth field, enter 01/01/2000.
- Click outside the input field, and then verify that the Result section shows the correct age.
- Click Submit to save changes to the expression.
- Click Add item to configure the IsAlternativeOffer property:
- In the Target field, enter or select .IsAlternativeOffer.
- In the Source field, click the Gear icon to open the Expression builder.
- In the Expression builder, enter @if(.pyName==Primary.RequestedProduct,false,true), and then click Test.
- Confirm the results of the following tests:
pyName
IsAlternativeOffer
Result
StudentLoan
StudentLoan
false
ConsumerLoan
StudentLoan
true
- Click Submit to save changes to the expression.
- Click Add item to configure the IsRequestedOffer property:
- In the Target field, enter or select .IsRequestedOffer.
- In the Source field, click the Gear icon to open the Expression builder.
- In the Expression builder, enter
.pyName==Primary.RequestedProduct, and then click Test. - Confirm the results of the following tests:
pyName
IsAlternativeOffer
Result
StudentLoan
StudentLoan
true
ConsumerLoan
StudentLoan
false
- Click Submit to save changes to the expression.
- Click Add item to configure the IsEligible property:
- In the Target field, enter or select .IsEligible.
- In the Source field, click the Gear icon to open the Expression builder.
- In the Expression builder, enter .pxSegment.
- Click Submit to save changes to the expression.
- Click Submit to save changes to the Set Property component.
- In the upper-right corner, click Save to save your changes.
3 Use a Data Transform to test the Decision Strategy
- On the right, expand the Test run pane.
- On the canvas, double-click to adjust the view.
- In the Test run pane, on the Single case tab, expand the Settings section.
- In the Settings section, ensure that the Data transform option is active.
- In the Data Transform field, enter or select TestCustomer.
- To the right of the Data Transform field, click the Open icon to open the TestCustomer Data Transform and observe the values.
- Confirm that the DateOfBirth property is displayed.
- Close the Data Transform to return to the strategy.
- On the Test run pane, click Save & Run.
- On the canvas, click the Cash Loans Proposition data component, and then in the Test run pane, confirm that the Age property has no value.
- On the canvas, click the Set Offer Properties Proposition data component, and confirm that the values for the Age, IsAlternativeOffer, IsEligible, and IsRequestedOffer properties are now present in the Test run pane.
- Open the Data Transform, change the DateOfBirth property, and then re-run the strategy to confirm that the Age value changes.
4 Add a Region Code check
- Right-click the canvas, and then select Business Rules > Decision Table to add the component to the canvas.
- Connect the Proposition Data, Decision Table, and Set Property components as shown in the following figure:
Right-click the Decision Table component, and then select Properties to configure the properties of the decision table. - In the Decision Table properties dialog box, in the Name field, enter Check Product Eligibility.
- In the Decision table field, enter RegionalProductCheck, and then click the Open icon to open the Create Decision Table page.
Note: Notice that the value of the Apply to class is Data-CreditRiskCustomer.
- In the upper-right corner, click Create and open to configure the decision table:
- In the Conditions column, in the first row, click the empty cell to open the Select a Property window.
- In the Property field, enter or select .RegionCode.
- In the Label enter RegionCode.
- Click Save.
- In the Conditions column, in the first row, click the empty cell to open the Select a Property window.
- Click the Parameters tab of the decision table:
- In the Name field, enter Product.
- In the Description field, enter Product name from Decision Data.
- Click the Table tab:
- In the Region Code column, click the empty cell to enable the decision table menu options.
- Click Insert Column After to add a column after Region Code.
- In the newly created column, in the first row, click the empty cell to specify a condition.
- In the Property field, enter param.Product.
- In the Label field, enter Product.
- Click Save.
- In the if row, click an empty cell, and then click Insert Row After twice to add two else if rows.
- Edit the decision table:
- In the if row, configure a Condition that specifies if the region code is 001 and the product is ConsumerLoanSpeciaOfferl, it returns a value of false.
- In the first else if row, configure a Condition that specifies if the region code is 002 and the product is ConsumerLoan, it returns a value of false.
- In the second else if row, configure a Condition that specifies if the region code is 001A and the product is StudentLoan, it returns a value of false.
- In the otherwise row, in the Return column, select true.
The following figure shows the completed decision table: - Click Save, and then close the decision table.
- In the Decision table properties window, in the Decision table field, re-select RegionalProductCheck by pressing the down arrow key.
- Expand the Supply data via section, and then in the Product field, enter or select .pyName.
- Click Submit.
- In the Test run pane, click Save & Run to test the Decision strategy with the TestCustomer Data Transform.
- Click the Set property component, and then in the Test run pane, confirm that there are multiple pages, one for each offer:
- Confirm that the system calculates the Age, IsAlternativeOffer, IsEligible, and IsRequestedOffer properties.
- Click the Next arrow to cycle through the offers and view the results.
5 Use Default Criteria to select the eligible propositions
- Right-click on the canvas, and then select Arbitration > Filter to add the component to the canvas.
- Hover over the Set Property component, and then click and drag the grey arrow to connect it to the Filter component.
- Right-click the Filter component, and then select Properties to configure the Filter condition:
- In the Filter properties dialog box, in the Name field, enter Only Allowed Products.
- In the Type section, select Proposition Filter.
- In the Proposition filter field, enter or select ProductEligibilityCheck, and then click the Open icon to open the inspect the Proposition Filter configuration.
- In the Group list, select Cash Loans, and then click Open decision data to view the decision data for the Cash Loans Group.
- Click StudentLoan to view the proposition properties.
Note: The MaxAge and MinAge properties determine the age range the customer must fall within to receive the StudentLoan credit offer.
- Click Cancel to return to the Edit Decision Data form.
- Repeat steps 3e-g for the ConsumerLoanSpecialOffer and ConsumerLoan propositions.
- Close the Edit Decision Data form to return to the Proposition Filter configuration page.
- In the Proposition section, click the StudentLoan proposition.
- In the Inherited from section, inspect the inherited eligibility criteria for the proposition.
The value of the IsEligible Boolean property must be set to true. The value of the Age property must greater than or equal to .MinAge and less than or equal to .MaxAge. - Inspect the inherited eligibility criteria for the ConsumerLoanSpecialOffer and ConsumerLoan propositions.
- Click the Default Criteria tab, and in the Business issue level criteria section, note that Using custom criteria is selected.
Note: The StrategyResult property contains the properties that define the strategy output, including IsEligibile and Age. The Age criteria check if the customer's age is within the age range of the proposition.
- Close the Proposition Filter, and then click Submit to save the filter component configuration.
- Test the strategy by using the TestCustomer Data Transform, and then see which products, if any, are filtered out.
6 Sort the propositions by offer amount
- Right-click the canvas, and then select Arbitration > Prioritize to add a Prioritize component to the canvas.
- Hover over the Filter component, and then click and drag the gray arrow to connect it to the Prioritize component.
- Right-click the Prioritize component, and then select Properties to configure the component properties:
- In the Prioritize properties dialog box, in the Name field, enter Prioritized Credit Offers.
- In the Expression field, enter .MinAmount.
- In the Order by section, confirm that Highest first is selected.
- In the Output section, select All.
- Click Submit to close the Prioritize properties dialog box.
- On the canvas, hover over the Prioritize component, and then click and drag the gray arrow to connect it to the Results component.
- Click Save.
Confirm your work
- In the navigation pane, click Predictions to open Prediction Studio.
- In the navigation pane of Prediction Studio, click Data > Data Sets.
- Click SimulationSetDDS to open the Data Set.
- In the upper-right corner, click Actions > Run to inspect the Data Set:
- In the Operation list, select the Browse option, and then click Run.
- In the Data Set Preview window, inspect the results.
Tip: Notice the CustomerID, DateOfBirth, and RegionCode values.
- Close the Data Set Preview window and the Run Data Set window.
- In the lower-left corner of Prediction Studio, click Back to Decision Manager Portal.
- In the Decision Manager Portal, return to the Credit Offers Decision Strategy.
- In the Test run panel, select Data set, and then select the SimulationSetDDS Data Set.
- In the Customer ID field, enter or select Customer70, and click Run to test the strategy.
Tip: Click the strategy components to view the results for the selected component.
- In the Test run pane, click the Batch tab, and then click Settings to configure the simulation:
- In the Test this strategy section, ensure that the A new simulation selection is active.
- In the Input data list, select SimulationSetDDS.
- Click Run to run the Batch simulation using the Data Set.
- When the progress bar reaches 100%, view the Funnel results for Credit Offers Decision.
Note: In this Data Set, most customers meet the criteria for the ConsumerLoanSpecialOffer product.
This Challenge is to practice what you learned in the following Module:
Available in the following mission:
Want to help us improve this content?