Friday, 8 January 2016

Introducing the SAP Automated Predictive Library

You may have already heard about the recent release of SAP Predictive Analytics 2.0, but may not be aware that this also includes the SAP Automated Predictive Library (APL) for SAP HANA.

The APL is effectively the SAP InfiniteInsight (formerly KXEN) predictive logic optimized and adapted to execute inside the SAP HANA database itself for maximum performance - just like the SAP HANA Predictive Analysis Library (PAL) and Business Function Library (BFL).

Obviously when you already have data in SAP HANA it makes sense to perform heavy-duty processing such as data mining as close as possible to where the data resides - and this is exactly what the APL provides.

By way of comparison, the PAL provides a suite of predictive algorithms that you can call at will - as long as you know which algorithm you need, whereas the APL focuses on automation of the predictive process and uses it's own in built intelligence to identify the most appropriate algorithm for a given scenario. So the two are very much complementary.
There are a couple to ways to take advantage of the APL. Of course, you can exploit the APL when using the SAP Predictive Analytics 2.0 desktop application - whenever accessing SAP HANA as a data source. In this case usage is implicit.

However it's also possible to access the APL independently of SAP Predictive Analytics 2.0. You can access the APL explicitly using SQLScript or from the Application Function Modeler (AFM) in SAP HANA Studio. And, of course, you can embed APL capabilities into your own custom SAP HANA applications.

We've put together a series of SAP HANA Academy hands-on video tutorials to explain how to access the APL from SAP HANA Studio using SQL Script:
1. Reference Guide & Download
In this video, part of the SAP Automated Predictive Library (APL) for SAP HANA series, we will introduce the SAP Automated Predictive Library (APL), download the APL reference guide, then download sample data & code and extract them for later use.


2.Import Sample Data & Check Installation
In this video, part of the SAP Automated Predictive Library (APL) for SAP HANA series, we will use SAP HANA studio to import the provided sample data into a SAP HANA schema, ensure the SAP HANA script server is running, and verify that the APL has been correctly installed.



3.Create APL User & Table Types
In this video, part of the SAP Automated Predictive Library (APL) for SAP HANA series, we will create and authorize a SAP HANA database user so that it can make use of the APL. We will also set up APL table types and test the APL using the "ping" function.



4. Predicting Auto Insurance Claim Fraud
In this video, part of the SAP Automated Predictive Library (APL) for SAP HANA series, we will use the APL to predict auto insurance claim fraud.

This example shows how an insurance company assesses past insurance frauds in order to create a category of client characteristics that may be susceptible to make fraudulent claims.

The first step of the analysis is to prepare the main input tables, one containing data that has already been analyzed, that contains some known fraud cases. This table is used to train the model. The results are used to indicate which variable(s) to use as the target and describe the claims data.

After considering past data and past fraudulent claims, the customer uses the data to train the APL model on that date produce an updated model that will be applied to the new data in order to detect potential fraud risks.

After training the model, the APL function returns summary information regarding the model as well as indicators like the Predicitve Power (KI) of the model, or the Prediction Confidence of the results (KR).

At the end of the data mining process, the “Apply Model” function produces scores in the form of a table that can be queried.



5. Recommendations
In this video, part of the SAP Automated Predictive Library (APL) for SAP HANA series, we will use the APL to generate buying recommendations.

The recommendations component can be used to generate product or service recommendations for customers by analyzing their behavior and other details and comparing these with the details and behavior of other customers.

The first step of the analysis is to prepare the main input tables, in particular, the customer transaction history table which is then used to train the model via the "Create Reco Model And Train" function. A number of advanced configuration options can be specified to define how the model should be built.

After training the model, the “Apply Reco Model” function produces recommendations for a given customer in the form of a table that can be queried.


Or for the YT playlist follow this link: http://bit.ly/hanaapl

Source: scn.sap.com

1 comment: