CX Works

A single portal for curated, field-tested and SAP-verified expertise for your SAP C/4HANA suite. Whether it's a new implementation, adding new features, or getting additional value from an existing deployment, get it here, at CX Works.

Set Up and Operate Recommendations Within SAP Marketing Cloud

Overview

Set up and operate recommendations within SAP Marketing Cloud

This article explains how you should set up and operate recommendations within SAP Marketing Cloud. It depicts various practical examples and recommended practices to avoid common challenges during the set up and operations phase. 

If you want to learn about the capabilities of recommendations, we recommend you to take a look at our article Advanced Analytics for SAP Marketing Cloud first. 

Table of Contents

Set up 

General approach

Identically to other business scenarios and features, the same underlying principles should be applied when implementing and rolling out recommendations within SAP Marketing Cloud.

Based on our experience in various regions and industries, the "crawl, walk, run" approach leads to higher value realization, project success and adoption. 

We recommend to follow the progressive "crawl, walk, run" approach for implementing and rolling out recommendations in SAP Marketing Cloud.

This approach should be followed for all recommendation-related aspects, such as the selection of data and data sources, algorithms, consuming channels or geographical regions. 

Find more information in the following article: Master the Challenges of Digital Marketing.


Specify and document recommendation scenarios

The first step is the specification of the recommendation scenarios. Which recommendation scenarios fit best, highly depends on factors such as planned business scenarios, channels or on data available. 

The typical channels where recommendations are utilized are web/commerce, mobile app or email channels.

  • For the consumption within SAP Commerce Cloud or SAP Commerce, you can leverage the standard integration as described in the Integration Guide
  • When you need to consume recommendations within a third-party commerce solution, you can leverage the snippet available on GitHub which is described in more detail in this blog post.
  • You can consume recommendations in emails sent from SAP Marketing Cloud. Please notice that currently not all algorithms are available to be consumed in emails. Email campaigns can only use recommendation scenarios to which an optimized model type has been assigned. Find more information under in the application help under Algorithms.
  • You can build your custom integration via the PROD_RECO_RUNTIME_SRV (directly, not recommended) or the API_MKT_RECOMMENDATION_SRV (using the SAP Cloud Platform, recommended) APIs. 

Since recommendations should always be provided depending on the context, let's discuss which context types are typically available.

  • No context could be available if an unknown/anonymous user is on a web shop start/landing page. In this case, only generic scenarios are possible. 
  • Product context could refer to contacts which are currently looking at specific product pages or already have products in their cart. Such products are called "leading products" and "cart products" in SAP Marketing Cloud. Recommendations related to the leading/cart product(s) can be provided. 
  • Product category context could be available if contacts are looking at product category pages. Recommendations related to this product category can be also be provided. 
  • Contact context is available if contacts are known and recommendation based on their buying or browsing history, similarity and/or contact master data can be provided. 

To give you some ideas of which recommendation algorithms are available for which context, please refer to the following picture. 

For documenting the recommendation scenarios, the most important dimensions are: 

Area Dimension Description
Recommendation scenario Channel Defines on which channel the recommendations are consumed
Section Defines the section of the channel
Recommendation model Model Name of recommendation model
Context See above
Max. number of results Maximum number of recommendation results
Post-processing Post-processing of recommendation results
Recommendation algorithm Name Name of recommendation algorithm
Parameters Parameters per recommendation algorithm
Pre-Filter Pre-filters for recommendation algorithm
Weight Individual weight of algorithm

The following example can help you get an idea on how the recommendation scenarios can look like: 

Recommendation scenario Recommendation model Recommendation algorithm
Channel Section Model Context Max. number of results Post-processing Name Parameters Pre-filter Weight
Web shop Cart page Cross-selling on cart page

Products (in cart)

Contact


5 Remove products already in cart Often bought together

Minimum support = 0.5

Interaction type = SALES_ORDER

Interaction range = last 6 months

70%
Bought by similar contacts (collaborative filtering)

Neighborhood size = 3

Interaction type = SALES_ORDER

Interaction range = last 6 months

30%
Product details page Similar products on product details page Product 10 Remove leading products Often viewed together - Product valid = TRUE 100%
Email Birthday email Top sellers in birthday email - 5 - Top sellers -

Interaction type = SALES_ORDER

Interaction range = last 3 months

100%

This template provides structure and examples about which dimensions you should consider (e.g. context, channel & section, data, algorithms etc.)

As explained in a later chapter, setting up and operating recommendations should always be an iterative process. The template above is typically filled out progressively.

Data Validation

Before you continue, you should get an overview about the available business objects per data source. The most important data objects are: 

  • The main recommendation objects are products and product categories for product recommendation and offer content and offers for offer recommendation. Having these entities is essential for implementing recommendations. 
  • The main interactions relevant for recommendations are sales orders and clickstream interactions (website visits, clicks, etc.). Sometimes other product-related interactions might be relevant for recommendations as well. 
  • In many scenarios, interaction contacts (all natural persons [contacts, consumers, or suspects], companies and “unknowns”), are also necessary for recommendations. 

Obtain an overview about the available business objects per data source. The following list indicates the most common objects:

  • Products and product categories for product recommendation
  • Offer content and offers for offer recommendation
  • Interactions such as sales orders, clickstream interactions (website visits, clicks, etc.)
  • Interaction contacts

Several recommendation scenarios require certain specific business objects from the list above. 

One example is the "top sellers of leading product category" algorithm. For this algorithm, products, product categories and sales orders are mandatory. If the majority of products does not have a product category assigned to it, they will not show up as recommendations. 

Another example are recommendation in emails. Since marketers want to send visually appealing recommendations, they may want to include dynamic product recommendation blocks. For this, the product master data has to contain the product image URL, the navigation URL and product names and descriptions, sometimes in multiple languages.  

Check the data availability and quality of the business objects required for your recommendation scenarios.

This may include but is not limited to:

  • Product master data
    • ID
    • Name, description (in multiple languages)
    • Image URL
    • Navigation URL
  • Product variant ↔ Base product relationship
  • Product categories and product category hierarchy
  • Product ↔ Product category assignments
  • Interaction data (sales orders, clickstream interactions)
  • Interaction ↔ product assignment

Latency, throughput and redundancy

For all scenarios in which recommendations are consumed from other systems (SAP / third party Commerce, mobile apps...), latency, throughput and redundancy are essential factors. 

Latency describes the time interval between request and response. In context of recommendation it describes the speed in which recommendations are returned to other systems. The rate at which recommendations are processed is called throughput. Redundancy refers to the availability of providing recommendations even if SAP Marketing Cloud is unavailable (e.g. during upgrades).

Especially when recommendations are used in high-volume scenarios, there are specific considerations. The following hints can help to improve latency and throughput for high-volume scenarios: 

Use recommendation caching whenever possible.

For the standard integration with SAP Commerce and SAP Commerce Cloud, there is the standard sapymktrecommendationbuffer extension which keeps recommendations in the cache until their expiry date. This reduces the latency and provides redundancy.

For custom-build integrations, the SAP Cloud Platform-based recommendation cache can be used to achieve the same advantages - latency improvements, built-in redundancy and even enriched recommendation results (e.g. added product images and descriptions from SAP Marketing Cloud). This approach is described in the following blog post and in the corresponding section of the Integration Guide.

Try to reduce traffic as much as possible.

A reduction of traffic between the consuming system and SAP Marketing Cloud can be achieved by using caching as described above.

Another factor is the implementation of post-processing logic. Post-processing logic refers to modifying the recommendation results, e.g. by removing products which are already in the shopping cart.

This kind of post-processing logic can sometimes be leveraged or built in SAP Marketing Cloud but ideally should be handled by the consuming system directly to reduce traffic.

For SAP Commerce, the post-processing (removing out-of-stock products and products already in the cart) is described in the Integrations and Data Management section of the application help.

Define business success

Since business success should be the key criteria measuring recommendations, the definition of business success metrics should happen as soon as possible during the set up process.

During later operations phases, you should also evaluate the effectiveness of your scenarios and fine-tune the models with respect to these metrics.

Define business success metrics for recommendations.

Examples of business success metrics that are tracked in SAP Marketing Cloud are:

  • Click-Through Rate
    • The proportion of recommended products that are clicked by consumers.
  • Conversion Rate
    • The proportion of recommended products that are purchased by consumers.
  • (Impressions)
    • The number of times a scenario has provided product recommendations to a consuming application.
    • Please notice that this metric typically does not represent business success with regards to recommendations since the metric only depends on where and how recommendations are presented in the consuming application.

Based on your scenarios, there might be other, externally tracked metrics which might be of interest.

Operate

After finishing the set up phase, you are transitioning into the operations phase. The following chapters guide you through the most important considerations for operating recommendations within SAP Marketing Cloud. 

Validate recommendations

A crucial point after initially setting up recommendations is to validate them.

Machines and algorithms are not the best judges to decide on their recommendation results' quality and if they are ready to be shown to customers already. For this task, cross-validation by expert judgement by business users and business analysts is required. 

If we want business users and analysts to help validate the results generated by recommendation algorithms, it's important to be able to explain the recommendation logic to a certain degree. If they agree with the recommendation results, they will not challenge the underlying logic. However, if they disagree, one might need to explain how the algorithms work under the hood. 

The actual validation then should happen in an iterative approach. If the recommendation algorithms work with parameters and pre-filters, start with the default values and present the recommendation results for the given product/contact context (see above) to the business users and analysts. Explain the results using the underlying algorithms, parameters, pre-filters and the context presented to the algorithm. With this information, the business users and analysts can judge if the recommendations make sense or not. If the experts disagree, parameters, filters or the underlying algorithms need to be changed or replaced, followed by another iteration until the desired level of quality is reached. 

Validate the recommendations in an iterative approach.

For this, expert judgement by business users and business analysts is required. Explain the recommendations to the experts. Adapt the setup until the desired quality level is reached.

Track business success and fine-tune recommendations

After the go-live of the recommendations, one should track the business success metrics defined earlier on a continuous basis. SAP Marketing Cloud tracks the number of impressions, the click-through rate and the conversion rate as described above within the Manage Recommendations app

Like the approach for initial validation, the fine-tuning of the recommendations should happen in an iterative mode. Based on the desired business goals, one might need to fine tune parameters, filters or algorithms accordingly. However, business success is also influenced by other factors, such as at which section or how visually appealing the recommendations are presented to the consumers. 

Track business success and fine-tune the recommendation end to end process accordingly.

The complete end to end process from data selection via algorithm setup to result visualization should be considered. 

Test and safe-guard the integrated environment

Apart from business validation, there are also technical considerations during the operations phase. 

Since recommendations might be used in high volume commerce scenarios, you should first set up a production-like test environment. Depending on your setup, this could be a SAP Commerce system with production-like setup integrated with your SAP Marketing Cloud test tenant.

The next step is to identify typical and exceptional peak times (e.g. Christmas season, black friday). These peak times then are used as the basis for load and volume test scenarios to safe-guard the whole environment.

The load and volume test scenarios can then be built using applications such as the open source software Apache JMeter. In past projects, we successfully tested and safe-guarded the systems using JMeter test scripts before setting the environment live. 

Test and safe-guard the integrated environment

Again, the approach should follow the principle of "measure, improve, re-run" to identify and set the baseline for the productive usage.

Conclusion

This article explained how you should set up and operate recommendations within SAP Marketing Cloud. Various practical examples and recommended practices to avoid common challenges during the set up and operations phase have been presented.

If you're interested in learning more about capabilities and best practices around recommendations and further Advanced Analytics topics, we offer the Advanced Analytics Guidance service.