Machine-learning powered NLP is becoming an essential element in many software tools, both customer facing and internal. A concept of an intelligent virtual assistant is becoming relevant for almost any context - customer service, technical support, marketing, internal company services, etc.
We got inspired by the recent updates in Pega 8.5 which opened up a possiblity to use external machine-learning services, such as Google AutoML, to further enhance the already impressive arsenal of tools made available in Pega prediction studio.
What it does
It's a chatbot which can act as an "assistant" for KE employees, providing information, links and contacts on a variety of HR-related topics such as timesheets, expenses, time off, etc. This chatbot will be embedded as a mashup in our internal KE confluence page, so it's easily accessible to everyone.
How we built it
The core idea is simple - a web chatbot in a dedicated Pega application (built on top of Pega Customer Service). We have prepared our own data file with records for model training, using as a baseline some of the models already available in Pega Prediction Studio such the "Small Talk" model. We defined some simple case types and process flows to support our intended dialogue scenarios, making active use of the "question" smart shape for interacting with the user. We used a docker container to spin up a simple web app where we embedded the chatbot as a mashup, so it is easily available for demo use.
Challenges we ran into
The biggest challenge was to create and train a specialised topic detection model that suits the context of KE, as we had to build our training data sets for it. Another challenge was related to our attempt using the Google AutoML API in order to extend the machine learning capabilities of Pega. We followed the available guidelines both in Pega and Google Cloud side, and discovered a mismatch in regard to the supported authentication models (OAuth 2.0 recommeded by Pega while this authentication mode is not compatible with AutoML services in Google). An incident was raised with Pega to report the issue.
Accomplishments that we're proud of
We are proud to have built, in just a couple of days, a really intelligent virtual assistant that can already be helpful for our colleagues. It makes active use of our own custom topic detection models and is able to analyse free form text input and guides user with needful resources. There was also yet another challenge, which we have managed to overcome succesfully: it was related to embedding the web mashup with the chatbot into a separate web page - we encountered an issue related to modern browsers blocking third party cookies. We were successful in overcoming this challenge by building a stand alone "wrapper" web app.
What we learned
We learnt a lot about defining and training topic detection models in Pega and using their outputs to guide the responses of a chatbot.
What's next for KE Chatbot
We want to further enhance this solution, explore other options - intent and sentiment detection models, external NLP models, etc. in order to make a fully functional KE Chatbot which can act as a reliable assistant for anyone in KE for any queries - administrative, organisational and technical. The next step is to take it outside KE, making a KE AI so that anyone who is interested in our company - be it potential customers, partners or job seekers - can interact with it as the initial point of contact both on our own website and also on our facebook page.