You are not using a modern browser version. As a result, the website may not be displayed correctly. You can find more information here.

How artificial intelligence can support end-2-end sales planning in the SAP Analytics Cloud


Powerhouse SAP Analytics Cloud

SAP Analytics Cloud is one of the central tools for planning and reporting in the context of SAP S/4HANA. In addition to the two application areas, “Reporting” and “Planning”, there are also the cross-functional areas of “Application Design” and “Predictive Intelligence”. The latter two can each be used for planning and reporting, and do not require an additional license or extra systems. The smallest SAC (user) license already contains everything necessary to use most of the artificial intelligence (AI) functions, as well as in-house development via application design in SAC. If predictive methods are to be used in planning, planning licenses are then required. These planning licenses, in turn, automatically include a “reporting license”, which subsequently also includes “Predictive”.

Predictive Intelligence in the SAP Analytics Cloud

When understanding the area of “Predictive Intelligence” as a module, this module can be further differentiated into various application functions. “Automated Insights” (also “Smart Insights”) provide insight into a selected object and its scope – all at the push of a button. The following image demonstrates the function. The chart shows the gross margin ratio broken down into three years and three product groups. When a Smart Insight is added to the graph, SAC analyzes the underlying metrics (gross margin) and dimensions involved (years, product group) and shares the results through a text below the graph. By clicking on “View more…”, we get additional graphics that try to explain the result.

The results of this form of automated information retrieval vary greatly in terms of quality. Since nothing else can be configured here either, the quality essentially depends on the structure of the data model and the scope of the available data.

Smart Discovery

To obtain a more comprehensive (automatic) analysis of the data, the “Smart Discovery” function can be used. Here, the user can already create more settings, and also set filters. After that, a preset analysis process runs again. This time, however, extensive pages and reports are created to show the interrelationships of the selected data. It is not obvious as to which technologies are used behind the scenes. Here, too, the quality of the results varies.

Automated Forecast

Reporting and planning often include “projections” or “forecasts.” As to how these numbers are generated varies widely. With the “Automated Forecast” function, a preview of the development of a time series can be created with just a few clicks. You can choose between “linear regression” and “triple exponential smoothing”. Both procedures allow a selection of the periods to be considered, and can be set accordingly. The confidence interval and information on how “good” the prediction is are also displayed.

A small icon below the title labeled “Forecast” allows access to the setting of how many periods into the future to look. The beauty of this type of prediction is that the function adapts to the state of the graph. If the “drill state” of the date is changed to “quarters” instead of “months”, a new preview is automatically created at this level. The same would be true if drilled from a product group to individual products.

This function can also be used in tables. Since planning usually requires entering values into a table, the function can write the results there directly into the cells, taking over the tedious role of typing of many numbers. Again, the prediction can be created and written back at different levels.

Forecast scenario

This is where it gets interesting. This is because now, we leave the realm of the end user and can create and configure a real system object with a “forecast scenario”. The features presented above can all be deployed by an end user with a few clicks, and do not require a deeper understanding of the underlying functionality. Forecasting scenarios belong – from a thematic standpoint – to the area of “Data Science”, and require some know-how to set up these functions correctly and to interpret the results.

Forecast scenarios can perform three basic predictive tasks:

  • Classification
  • Regression
  • Time series prediction

Below, I describe how time series forecasting can be integrated as part of an end-2-end planning process. For an overview of all three use cases, I recommend taking a look at my colleague Khalil Ben-Khalifa’s post:

Smart Predict Environment of the SAP Analytics Cloud

A time series prediction analyzes the course of a time series (e.g. historical sales of an article over the last 15 years), and tries to find patterns and trends automatically. This information can be used to generate predictions about the future course of a time series. In addition to the actual “signal” (here are the sales), other “secondary signals” can also be included in the analysis. The AI then examines whether these secondary signals have an influence on the primary signal. For example, forecasts of weather developments (secondary signal) can have an impact on crop yield forecasts (primary signal), as they can significantly influence it.

Before any use of Data Science, the goal should be clear. In the following project example, these are 2 goals:

  1. Increase the level of automation of product forecasting
  2. Increase the accuracy of sales planning in terms of time and quantity by automatically taking into account long-term trends and patterns

Overview of a sales planning process

The following diagram shows how the sales planning was done (roughly) before the project was implemented. Initially, data is extracted manually from a source system and imported into Excel. Excel offers standard evaluations developed over time. This includes three forecasts using a mathematical average. An average is calculated for the last 3, 6 and 12 months for each product. Corrections to the historical data are made by hand directly in the months. Then, product by product, it is decided as to which quantity will be planned for the future. This planning is carried out by the production department. Parallel to this process, there are also other departments, such as Marketing and Sales, which require additional sales volumes (for example, promotions or samples). Planning takes place monthly and is carried out for the following 18 months. The production of the first 6 months is frozen as “Frozen Horizon”, and can be modified only in justified (exceptional) cases.

By introducing planning with SAP Analytics Cloud, as many steps of the process as possible should be automated. A new S/4HANA system (On Prem) will be used, which from now on, will deliver the current sales to the SAC on a daily basis. This is done via a standard interface of the new Universal Journal to the ACDOCA table.

In the SAC, there are now different stories for each step of the planning process. A separate key figure is used for data cleansing so that the original data is retained. The standard SAC function of the cell comments also stores why a number was adjusted. If, for example, a customer could not be supplied due to stock-outs, the sales volume in the AI would be assumed to be smaller than the demand actually was. If additional quantities were delivered, e.g. as part of a promotion, the AI would assume too much demand. Data cleansing thus prevents the AI from learning anything wrong.

The next step is the classification of the products. Each product can be assigned to a forecast class. In the process, the planner decides how the product will be planned in the future. By selecting “AI Forecast”, the product is completely planned by the AI. This means that the result of the time series forecast is taken 1 to 1 as the planned value. If one of the statistical ratios is selected, it is taken as the basis for planning. If “manual” is selected, the product must be planned manually by the sales planner. This is often the case with new products for which no reference values are available.

Once the classification is complete, the AI training is triggered, and the result of the new forecast is ready for review a few minutes later. To enable the planner to easily analyze the results, a cockpit is available, which can be seen in the following figure.

A material can be selected on the left side. The graph shows the adjusted sales (lilac), the 3 statistical averages (light blue, orange, green), the result of the AI forecast (red) and the current sales plan (dark blue) of the selected product.

The peak at the beginning of 2020 can be nicely seen with a quantity of 1,798 units, which was not corrected in the forecast adjustment. Nevertheless, the AI forecast is robust enough to independently detect this spike as an outlier and ignore it in the forecast. Another easy-to-see aspect is the mapping of the cyclical pattern from the historical data. AI has recognized that this product is sold more in the winter. In fact, this is a cold remedy, which could explain the cyclic course with a peak in winter time.

If the planner thinks that another forecast class is more suitable, he can change it directly for this product. For this purpose, a simple dropdown box is available at the bottom center of the image. In this case, “SYS Forecast” is selected, which corresponds to automatic planning by the AI.

Once the system-supported forecast is complete, the actual planning begins. The planner can now decide whether to adjust the planned quantities (by increasing or decreasing them). For this purpose, an input table is available to him, as the following picture shows.

All key figures are once again available to the planner. A breakdown of sales into the various distribution channels can also be seen. By making an entry in the key figure “Sales – Adjustment”, the sales quantity can be manipulated. No changes are allowed within the Frozen Horizon. These must be executed via a special function, which requires increased system rights.

Since the planner only has to plan the products that are not planned by the AI, a large part of the work is eliminated. Once planning is complete, the SAC system automatically consolidates the sales. Consolidation provides a database that is then exported from the system and manually imported into S/4HANA production planning. There, the data is used to generate the planned independent requirements that are used to plan the production orders.

Conclusion and lessons-to-remember

After the project’s implementation, many manual tasks have been automated through system integration. Historical sales data is exported daily from S/4HANA to SAC. The consolidation of planned quantities and the generation of the forecast is also automated. Finally, about 60% of all products were able to be classified as “SYS Forecast”. These are now planned completely autonomously by the AI. This blog post did not cover the hindsight of forecast errors. These are also calculated for the 4 forecast metrics and presented in an analysis dashboard. This allows a comparison of the methods, regardless of which one was actually used for planning. Almost all of the products that are planned by the AI have been planned more accurately in hindsight than in the past, leading to a reduction in excessively-planned sales quantities (and thus a reduction in inventory) in the future.

The automation of manual work has freed up working time. But a redesign of the process has added manual steps, such as classification. However, since the nature of the time series does not usually change spontaneously, but rather in the long term, the amount of effort required is manageable. Further automation, e.g. advanced outlier detection or the integration of the error level of the forecasts into the classification, are possible, but also costly. The benefit would not have been commensurate with the effort in this use case, so these optimizations were dispensed with.

The project has also demonstrated effectively that AI does not mean letting go of the controls entirely. Rather, the AI is a welcome co-driver in this regard, reading the map and helping us navigate while we drive. But AI also needs the appropriate care. Whether ensuring data quality in data pre-processing or regularly reviewing results relative to other (simple) methods, the interaction between humans and AI makes the planning process well-rounded.

Finally, the use case must also be suitable for such a scenario. This should be checked as far as possible in a preliminary phase. If significantly more products are planned, a different strategy will be necessary. For example, planning at the product group level with the subsequent distribution. The use of AI must be examined on a case-by-case basis.

Likewise, the company must be prepared to rethink and adapt its processes if this proves useful. Simply replacing one piece of software with another will rarely lead to an improvement.

Nehmen Sie Kontakt zu uns auf!

    I hereby consent to my personal data being collected, processed, and used for the purpose of processing my inquiry. I may revoke my consent anytime without stating my reasons for doing so. More information can be found in our privacy statement.