Measure Brand Love and Customer Value in SAP Marketing Cloud Using a RFE-Based Score
11 min read
Scores can be used in SAP Marketing Cloud to quantify customer behavior. Apart from data-driven predictive / machine learning scores, it’s also possible to setup heuristic scores. Rule-based scores are usually defined by company policies or best practice and the score logic is built explicitly through calculations and rules.
This blog will outline the implementation of a complex heuristic score based on a variation of the industry-proven RFM (Recency, Frequency, Monetary) model.
Table of contents
- User Story and Business Question
- Heuristic Score Extensibility
- Variations of the RFE score
User Story and Business Question
In literature, the RFM analysis is a technique used to determine which customers are the most valuable customers. The most valuable customers are determined by examining how recently they purchased (Recency), how frequently they purchase (Frequency) and how much they spend (Monetary).
In our approach, we generalized and only took sales transactions (monetary) into account rather than use SAP Marketing interactions to calculate a score.
In a nutshell, every potential marketing-relevant event such as a website registration, a post on social media, or an opened email can be a created in SAP Marketing, as an interaction. The resulting three dimensions in our approach are:
- Recency: How recently did the customer interact?
- Frequency: How often does the customer interact?
- Engagement: How valuable are the customer’s interactions?
Using this broader RFE definition, you can quantify how loyal and engaged a customer is. Every customer receives a value between 1 (least loyal and engaged) and 5 (most loyal and engaged). As with every other heuristic score in SAP Marketing Cloud, they can be used in segmentation or displayed in the contact details / factsheet for individuals – here, the resulting score has been called “Brand Love Score”.
[A modified version of this score can be created, taking only monetary sales orders into account to model the traditional RFM score]
Heuristic Score Extensibility
With SAP Marketing Cloud, heuristic scores are created using the Score Builder app. Using multiple rules, several conditions can be checked. A rule is only valid if all conditions are met. The final score value is calculated as an aggregation of the outcomes from all valid rules.
Each condition can be based on the predefined vocabulary in the SAP HANA Rules Framework (HRF) or on fields that extend the HRF vocabulary. There are two approaches to extend the HRF vocabulary:
- Via custom fields which already extend the standard SAP Marketing business objects (interaction contact, interaction etc.) using the “custom fields and logic” app
- Via attributes from custom HANA views
When extending the vocabulary for example, while creating a new Rule Model using 1), these custom fields [e.g. the customer’s “shoe size”] can be used in a rule condition:
By using attributes from custom views, additional logic can be implemented in the underlying HANA view. Everything that’s possible in graphical calculation views (e.g. through filters, aggregations, calculated columns) can be provided by the custom view as an output and used later in a rule condition. In this example, the total number of public tweets in the last 6 months could be calculated dynamically, through an aggregation oninteraction data provided by the custom HANA view:
The illustration below shows the technical architecture of a score, with an HRF vocabulary that’s been extended by a custom graphical calculation view. Through the HRF vocabulary, you can use business data directly or via the custom graphical calculation views.
Implementation of Score-Specific Logic via Custom HANA Views
Implementation can be categorized into four steps:
- Step 1: Implementation of score-specific logic via custom HANA views
- Step 2: Parameterization of the score via Custom Business Objects
- Step 3: Extension of the HRF vocabulary
- Step 4: Setup of the score via Score Builder
Score implementation is done by implementing the RFE-specific logic in the underlying HANA views. The HANA view calculates the intermediate results and the score builder uses the data to send the final score value to SAP Marketing applications, such as the segmentation or the consumer profile.
An exemplary calculation done by our score is illustrated below. For a given customer, their behavior can be categorized into one of the three dimensions: recency (divided in five time buckets on the x-axis), frequency (divided in five frequency buckets on the y-axis) and engagement (illustrated by the value shown on the chip, representing single interactions). The most current time bucket is on the left-hand side of the x-axis and the bucket with the most interactions is on top.
The final score value is calculated in that way:
- The value of a filled cell is calculated by multiplying recency (5;2;1;1/3;1/12) by frequency (5;4;3;2;1) by the interaction values (based on the customer’s score parameters)
- All relevant (filled) cells are summed up in a second step
- In a last step, this result is classified into buckets of 1-5 (based on the customer’s score parameters)
In this example, four interaction types were identified by the business to be relevant for the RFE analysis: Website visits, product/service reviews, surveys and registrations. These interactions have a different impact on the engagement value (e.g. survey = 75, website visit = 15).
However, you can identify from this example that although the registration interaction (on the right side) has a quite high interaction value (100) the actual effect (0.25) on the score (67.25) is quite low. Intentionally, because the customer registered a while ago, it’s effect on the score gets lowered.
The generic HANA view which implements this calculation could look like the one below. The intermediate results per time bucket (R1-R5) are calculated individually and later summed up in the top aggregation node. This calculation is done for all relevant interaction types (e.g. visits, review, survey and registration). Another HANA view takes the results per relevant interaction type and calculates the final result.
Parameterization of the Score via Custom Business Objects
In SAP Marketing Cloud, you can bring in your own business objects which typically hold business data, with the help of Custom Business Objects (CBOs). Further CBOs can hold any type of data, such as score parameter data. We use this concept to:
- Manage the custom score parameters (such as the size of the time buckets) in a flat CBO [Recency_1 = 30 days, Recency_2 = 60 days, …] with exactly one intended entry
- Assign interaction values to interaction types (e.g. the registration = 100 assignment) in another CBO with n [interaction_type; interaction_value] key-value pairs
Using this concept, each customer can set up their own version of the score based on their business/industry. Fiori applications can be generated to maintain CBO (Custom Business Object) data and you can set up the parameters in SAP Marketing UI. It’s also possible to adapt the values later because heuristic scores are calculated in real time (in the default setting). The adapted parameters are then immediately taken into account.
In the HANA view, the configured parameter values can be used as input parameters for the underlying logic. In this screenshot, YY1_03F588E6A526 is the technical name of the data table that was generated for the CBO and the columns are used as input parameters
The illustration below shows the final technical architecture. The HRF vocabulary of the score is extended by a custom graphical calculation view. The view takes both business data and the score parameters for the final calculation. The maintenance of the score parameters can happen on the UI via a Fiori application which can be generated for the CBO.
Extension of the HRF Vocabulary
After the custom business objects for the score parameters and the custom graphical calculation views for the score logic have been setup, the standard procedure to extend the HRF vocabulary applies.
This procedure is well described in the Extensibility Guide for SAP Marketing Cloud.
Setup of the Heuristic Score via Score Builder
The very last step of the setup is the score itself which consumes the results from the HANA view.
As the HANA view already returns the score value directly in the format [Contact Key; BrandLoveScore], we don’t need any additional logic in the score builder. Of course, depending on the business requirement, the custom attribute can be used in a condition with standard fields as well.
The score can then be made available for the usage in segmentation and in other applications such as the consumer profile.
Variations of the RFE score
So far, the previous chapters described the concept to score engagement in general. Next to this approach, there are variations we built within customer projects for more specific scoring.
The interest score is a way to score contacts by their engagement specific to single interests or interest areas/groups (multiple items of interests grouped together). All other concepts (e.g. the recency, frequency, engagement) remain unchanged.
From an implementation point of view, the interest score simply applies a filter on the interactions by single interests or interest areas.
Example: Hiking Interest Score
- This score would only take interactions (e.g. reviews, product views, etc.) related to this interest into account.
- As the other concepts described earlier (e.g. the recency, frequency, engagement) remain unchanged, the output is still a numeric score value.
If you have a reasonable number of interests, you might want to create an interest score for each interest. If you have a high number of interests, you might want to group them by interest area (e.g. grouping the interests "Hiking", "Tennis" and "Running" into the interest group "Outdoor"). The grouping might be done by brand or product lines as well.
Main Interest Score
The main interest score is a variation of the interest score described above. Essentially it determines the main interest or the main interest group for the given contact. The main interest is determined as the interest which has the highest interest score. Again, the other concepts described earlier (e.g. the recency, frequency, engagement) remain unchanged.
From an implementation point of view, this score first applies filters on all interactions for each interest individually, to calculate interest scores as an intermediate result. On top of all interest scores, an aggregation is performed to determine the highest-scoring interest and return this interest. The output of this score is typically not a numeric score, but the main interest.
Example: Main Interest Score
- This score would consider all interactions and score the interests individually as described above. The highest-scoring interest is determined in a second step.
- The output could be "Indoor" since the Interest Score for "Indoor" was higher than all other interests.
This score can then be used to distribute or route contacts within the campaign automation process for the best corresponding follow-up activity.
Following that approach, we have built a parameterizable RFE score in SAP Marketing Cloud via
- Custom graphical calculation views (for the score logic)
- Custom business objects (for the score parameters)
- The standard score builder (for the score consumption)
Our algorithm comes with best practice parameters to calculate the score.
Please contact us, for more details on the score implementation.
The score has been implemented for several customers, mostly from the consumer products and retail industries. Every customer can adapt the parameters for their business/industry and markets.