How to realise the potential of AI through Sitecore

Dan Vella
3 min readMar 17, 2018

--

A developer’s guide to AI-driven experiences through Sitecore

AI has gone mainstream — it’s the one area that marketers will grapple with most in 2018 (Econsultancy) — whilst voice continues to emerge as a popular interface with consumers — the Echo Dot was the best-selling product on all of Amazon for the festive season just gone (TechCrunch).

We are now at a stage where we need to have computers understand humans, rather than humans understanding computers.

AI applications like machine learning will mean that chatbots and virtual digital assistants will play a much more significant role in customer interactions, not just in 2018 but for the foreseeable future.

AI already plays a variety of roles throughout the user experience; at the simplest level, it curates content for people, like Spotify’s mobile app suggesting new music based on previous listening choices. In a more significant role, AI applies machine learning to guide actions toward the best outcome. It is harnessed across various channels, often behind the scenes, to accomplish tasks — learning from previous interactions to help suggest and complete new tasks.

During Sitecore Symposium 2017, Sitecore introduced Cortex — an intelligent marketing assistant built inside the Sitecore Experience Cloud for version 9. This will allow for all data on customer interactions to be continuously processed and optimised to help unveil new customer segments and revenue opportunities, giving marketeers a competitive advantage. Cortex will leverage CNTK (the open-source deep learning framework), Microsoft Cognitive Services, and its supporting suite of machine intelligence APIs including the Computer Vision API.

So while we wait for Cortex, here at Mando we found that Cognitive service can be an accelerator for UX and tech as it provides a new channel for customers to interact with and for us to gather insight from.

Within the Cognitive Services APIs, Microsoft have provided custom services which allow you to use the same capabilities, but train the models behind them using your own custom data. Microsoft have provided us with the ability to roll out our custom REST APIs as required to provide integrations with third party tools (such as Google Assistant).

Let’s take the QnA Maker for example, this allows you to build, train and publish Q&A Bots based on existing FAQs. First register a new bot on dev.botframework.com, provide a name and handle, and once created you will be provided with a Knowledge Base ID and Subscription ID.

Next, on portal.azure.com, create a Web App Bot and make sure you select the Question and Answer template through the wizard. This will create a bot ready to be used through the QnA Maker — in fact your next step is to open the bot in Azure Functions and set the previously mentioned IDs in the Application Settings. This way you now have the bot connected to Azure

Using Mando Technical Strategist and Microsoft AI MVP Gary Pretty’s QnAMaker Sync Library, Sitecore can now be connected to the bot and the QnA Knowledge Base can be populated and managed from the CMS. This fits in perfectly with Microsoft’s framework of build once, run everywhere and integrate with the different channels. The same functionality can be used by building an Alexa skill that is plugged in the same QnA Knowledge Base, and using LUIS (Language Understanding Intelligent Service) allows users to use voice commands to interact with your QnA.

This sounds all pretty straightforward, but make sure that when using items like LUIS and the QnA Maker test, you train them over and over again. Both have Test functionality through the portal that allows you to train the interactions. Also, don’t be scared to use multiple bot services together — use LUIS as a fall back to the QnA Maker!

Take a look at the links below to get started with your own bot.

If you have any questions, get in touch @danjelv

Bot samples, tutorials, case studies:

  • aka.ms/botresources

Bot Framework:

  • dev.botframework.com
  • github.com/microsoft/BotBuilder
  • github.com/microsoft/BotBuilder-samples

Cognitive Services:

  • aka.ms/cognitive

QnAMaker Sync Library

  • garypretty.co.uk/2018/02/10/qnamaker-sync-library-v1-and-qnamaker-dialog-v3/

--

--

Dan Vella

Senior Manager, Technical Consultancy UK @ Sitecore