Recommenders

Recommenders

This guide walks you through configuring both rules-based and objective-based recommenders in Salesforce Personalization. You will learn to build engagement signals and metrics, then train recommenders using Data 360 data graphs to deliver personalized product and content recommendations.

[ACTION REQUIRED: Review Note] - NOTE: Before starting the hands-on exercises in this workshop, watch the video to learn more about recommenders and the differences between objective-based and rules-based recommenders. Enter the password LearnSPtoday to play the video.

Create a Rules-Based Recommender

In this exercise, you will create a rules-based Top Sellers recommender and use it in a personalization point to deliver cross-channel personalized decisions based on product popularity.

  1. Search and select Personalization from the App Launcher.
  2. Click on the Recommenders tab.
  3. Click New.
  4. Complete the Recommender Properties fields with the following values:
    • Data Space: default
    • Profile Data Graph: Profile
    • Item Data Graph: Products
    • Recommender Name: Top Sellers
    • Recommender API Name: Top_Sellers
  5. Click Next.
  6. Select the Rule-Based Recommendations tile and click Next.
  7. Select Calculated Insights > Top Sellers Calculated Insight > TotalSoldUnits from the Data Graph Resource menu.

[ACTION REQUIRED: Update Image Here] - Original Context/URL: Select Data Graph Resource in rule-based recommender configuration

  1. Set the Sort Order to Descending.
  2. Click Next.
  3. Click Add Condition in the Filters dialog.
  4. Select Direct Attributes > Price from the Item Data Graph Resource menu.
  5. Select Static from the Filter Type menu.
  6. Select Is Greater Than from the Operator menu.
  7. Enter the value 10 in the Value field.

[ACTION REQUIRED: Update Image Here] - Original Context/URL: Configure filter in rule-based recommender

  1. Click Save & Exit to save the recommender and start training.

Engagement Signals

Before creating an objective-based recommender, you will first create engagement signals. These signals act as the input for model training and the foundation for the metrics a recommender can optimize.

[ACTION REQUIRED: Review Note] - NOTE: Watch the video below to learn about engagement signals, engagement signal metrics, and compound engagement signal metrics. Enter the password LearnSPtoday to play the video.

Create a Product View Engagement Signal

  1. Search and select Engagement Signals from the App Launcher.
  2. Click New.
  3. Leave the Exclude related objects… checkbox deselected.
  4. Select Product Browse Engagement from the Engagement DMO menu.
  5. Click Next.
  6. Select the following identifiers from the Product Browse Engagement DMO in each respective field:
Field Identifier Field Purpose
User Identifier Individual Who did the event
Timestamp Identifier Engagement Date Time When the event happened
Item Identifier Product What item the event was against
Event Identifier Product Browse Engagement Id Understand multiple occurrences of the same event
  1. Click Next.
  2. Leave the Count each event as a discrete engagement signal tile selected and click Next.
  3. No optional filters are required, so click Next.
  4. Enter Product View in the engagement signal Name field.
  5. Click Save.

Create an Add to Cart Engagement Signal

  1. Click New from the Engagement Signals page.
  2. Leave the Exclude related objects… checkbox deselected.
  3. Select Shopping Cart Product Engagement from the Engagement DMO menu.
  4. Click Next.
  5. Select the following identifiers from the Shopping Cart Product Engagement DMO in each respective field:
Field Identifier Field Purpose
User Identifier Individual Who did the event
Timestamp Identifier Engagement Date Time When the event happened
Item Identifier Product What item the event was against
Event Identifier Shopping Cart Product EngagementId Understand multiple occurrences of the same event
  1. Click Next.
  2. Leave the Count each event as a discrete engagement signal tile selected and click Next.
  3. No optional filters are required, so click Next.
  4. Enter Add to Cart in the engagement signal Name field.
  5. Click Save.

Create a Purchase Engagement Signal

  1. Click New from the Engagement Signals page.
  2. Leave the Exclude related objects… checkbox deselected.
  3. Select Sales Order Product Engagement from the Engagement DMO menu.
  4. Click Next.
  5. Select the following identifiers from the Sales Order Product Engagement DMO in each respective field:
Field Identifier Field Purpose
User Identifier Individual Who did the event
Timestamp Identifier Engagement Date Time When the event happened
Item Identifier Product What item the event was against
Event Identifier Sales Order Product Engagement Id Understand multiple occurrences of the same event
  1. Click Next.
  2. Leave the Count each event as a discrete engagement signal tile selected and click Next.
  3. No optional filters are required, so click Next.
  4. Enter Purchase in the engagement signal Name field.
  5. Click Save.

Create an Engagement Signal Metric

For each engagement signal created, a simple count metric is automatically generated. Instead of optimizing for the number of purchases alone, you will create a custom metric that optimizes for the revenue value associated with orders, enabling the recommender to prioritize higher-value outcomes.

  1. Open the Purchase Engagement Signal created by the data kit.
  2. Click on the Related tab.
  3. Click New in the Engagement Signal Metrics section.
  4. Enter Revenue in the Engagement Signal Metric Name field.
  5. Choose SELECT from the Aggregate menu.
  6. Select Sales Order Product Engagement > Total Line Amount from the Field menu.

[ACTION REQUIRED: Update Image Here] - Original Context/URL: Select Engagement Signal Metric

  1. Click Save.

[ACTION REQUIRED: Review Note] - NOTE: Supported Metric Types for Recommender Objectives. Metrics created using either the COUNT or SELECT aggregate functions can be used as objectives in recommenders.

Create an Objective-Based Recommender

With the engagement signals and metrics configured, you will now create a custom objective-based recommender to optimize recommendations for revenue maximization.

  1. Click on the Recommenders tab in the Personalization app.
  2. Click New.
  3. Complete the Recommender Properties fields with the following values:
    • Data Space: default
    • Profile Data Graph: Profile
    • Item Data Graph: Products
    • Recommender Name: Max Rev
    • Recommender API Name: Max_Rev
  4. Click Next.
  5. Select the Objective-Based Recommendations tile and click Next.
  6. Select the New objective radio button.
  7. Complete the Objective Properties fields with the following values:
    • Objective Name: Max Rev
    • Objective API Name: Max_Rev
    • Recommender Purpose: Maximize
    • Engagement Signal Metric: [Purchase] Revenue
  8. Click Next.
  9. Add all engagement signals from the Engagement Signals menu.

[ACTION REQUIRED: Update Image Here] - Original Context/URL: Add Engagement Signals to Objective-Based Recommender Configuration

  1. Click Next.
  2. Click Add Condition in the Filters dialog.
  3. Select Direct Attributes > Goods Product Id from the Item Data Graph Resource menu.
  4. Select Decision Context from the Filter Type menu.
  5. Select Match Any from the Operator menu.
  6. Select Direct Attributes > Goods Product Id from the Decision Context Resource menu.

[ACTION REQUIRED: Update Image Here] - Original Context/URL: Configure filter in objective-based recommender

  1. Click Save & Exit to save the recommender and start training.

Summary

You have successfully configured both rules-based and objective-based recommenders. By defining engagement signals such as views, cart additions, and purchases, and creating custom revenue metrics, you have provided the model with the rich behavioral context required to deliver highly personalized cross-channel decisions.