Building Powerful Digital Assistants with SAP Conversational AI
Artificial Intelligence: It is the talk of the town that perhaps each and every emerging technology wants to embed. We have all heard of Alexa, Siri etc.; the interactive robots that assist customers and these have emerged as stepping stones in AI.
Thus, moving hand in hand with technology, SAP has already introduced Conversational Artificial Intelligence which is a powerful digital assistant designed for organizations.
Artificial Intelligence: A Concept
As you can see in the topic itself it is a powerful bot building platform that helps you build and deploy conversational agents in your application. These agents are programmatically designed to provide a powerful end user interaction. It provides a web user interface that serves as a platform to create, build and test chat bots. It is indeed automation.
Though SAP has successfully created brilliant and user friendly user interfaces with robust FIORI applications; embedding them with conversational interfaces proved to be cherry on the cake. This has streamlined to provide a far better and smoother user experience. Smart chat bots allow user to get immediate and directional responses to their queries about particular applications. They can also greet customers as if a real life agent would be attending them.
What are Chat Bots?
A chat bot is an automated window or an interface designed to interact with the end user. They are designed to simulate human conversation with the end user. A Chat bot automates the business process and improves customer support. There are some basic elements attached to the chat bot as mentioned below:
- Skill: A skill is the purpose for which a chat bot is designed to achieve a result. For example, plain greetings, checking weather report, executing a small task etc.
- Training Data Set: It is composed of the likely intelligent sentences that the user would be using in his basic conversation with a bot. It also stores the mutated sentences that contain a similar meaning.
- Expressions: The sentences that user can ask to connect with a chat bot is known as expressions. It can be a simple ‘Hi’, or a sentence asking for some assistance.
- Intent: The set of expressions that are constructed differently but means the same thing is said to be intent. Based on any expression, Intent is determined and is correspondingly responded.
- Entity: An Entity is the occurrence of the keyword that probably determines which intent needs to be triggered.
- Trigger: A bot consist of many skills clubbed together and a Trigger is a condition that determines which intent the bot will execute.
- Requirements: The information that a skill collects to perform an action.
- Action: Action is finally the step the chat bot will perform or execute based upon a user’s request.
The above points might sound tricky but they are very easy to implement!
AN OVERALL MODEL OF A BOT
An Example of a BOT – A Simple digital Assistance!
Training a Chat Bot:
We will quickly see how to create a simple chat bot as above.
Purpose: This chat bot will tell the user the different landscapes of SAP systems.
We go to https://cai.tools.sap/ and register here.
We click in New Bot. As soon as we click here, we select that our chat bot will perform actions and select a given skill. We select greetings and small talk. Greetings and small talk are the standard skills having its own intents and triggers.
We give a name to the chat bot, its purpose.
We provide the data policy as per security reasons. It shows that the chat bots are secured too.
Select the visibility of the bot and create the bot.
We land on a page where we have to give intent to the chat bot. As we have selected skills as Greetings and small talk, so our first intent would be expressions related to greetings.
SAP has already provided some pre build skills in which @greetings is one of them.
If we select build, we are given two skills that we have selected for our chat bots. These are:
We can add more skills over here too.
If we talk about greetings, all the concepts that we read earlier are clearly visible:
Triggers : When user greets the chat bot that will be the trigger point.
Requirements : There is no requirement as such here.
Actions : Once the trigger is executed, the actions are performed which in this case is greeting the user back. We can also edit these messages.
ADDING A NEW SKILL TO THE BOT
Similarly, if we want to add a new skill, we go to Build and add a new skill.
Just adding skill won’t make the bot intelligent. We will have to train it. We would have to add triggers and actions to it and create intent as all those expressions that have a similar meaning that the user would probably ask for in this particular skill.
Conversation that can be asked from the user:
- May I know the systems available
- Can I get the information of the available SAP systems
- I want system Information
And all such cases.
ADDING AN INTENT TO THE BOT
Let us create intent for the above skill.
ADDING EXPRESSIONS TO THE INTENT:
Once we create intent, we have to add expressions into it which will contain similar meaning.
Here we have added three expressions to the intent.
ADDING ENTITIES FOR EXPRESSIONS:
For training the bot, we need to create Entities: As already discussed earlier, an Entity is a keyword that is chosen from the expression and extracted to predict the intent available.
Thus, we create an entity named System.
Once the entity is created, we go to the intents and we select or extract the keyword from the expressions. Below we have marked systems as the keyword.
Now, as we are done with creating the skill and training it, we also should determine when it should trigger. For that, we need to create the trigger point.
BUILD THE BOT: ADD TRIGGERS:
So, we go to the Trigger and select the requirements for the skill.
BUILD THE BOT: ADD REQUIREMENTS:
We go to requirement of this skill, and add that if an entity system is present as a request, that means if a user requests this skill, what all can be the replies. So, we create replies in the requirements.
Click on new replies, choose the message type.
Once the user requests a particular requirement, we would choose a message to reply back to the user. SAP has provided a lot of available message types. We choose text as of now.
Our bot will ask the user which system Information he really needs and we shall provide him options as HANA, ECC and FIORI. Along with each option, we write the text as predictions as to what the user would answer. These set of predictions make another INTENT user_system with its associated expressions and entities.
ADDING ANOTHER INTENT AND ENTITY TO THE SKILL:
In order to predict user response, I have created @user_system as a new Intent with the below possible expressions.
And a new entity HANA, with each of the above expression mapped with an Entity which would help determine the INTENT from user’s answer.
After making a new intent and entity for the user’s reply, we map the same in the requirements while building the BOT and if these questions asked have the user reply matched with the intent, the BOT would answer with the exact Systems.
BUILD THE BOT: MODIFY THE REQUIREMENTS:
BUILD THE BOT: DEFINE AN ACTION:
Action: When the above requirement will be met, we will provide an action that would answer the available system user has selected.
TESTING THE BOT:
After training the BOT well, let us test the BOT.
Cool! After training my BOT with the required skill, my BOT is intelligent and so user friendly!
ADVANTAGES OF CONVERSATIONAL AI:
- Powerful digital assistance
- Robust Architecture and Infrastructure
- Can easily be embedded to SAP applications
- Can be integrated to SAP Systems
- Postures a powerful user interface to FIORI Applications
- Can be multilingual and adjusted to any device
- Personalized human like conversation anytime and anywhere!
With such an advent of technology, SAP Conversational AI is building a significant mark in the markets and among SAP Users across the globe!