• Sridhar Rajendran

Introduction to the Microsoft Bot Framework

Updated: Aug 23, 2018

Learn the basics of bot design and build a QnA bot in minutes

In my earlier post, I mentioned that I will be trying out the different frameworks for developing and deploying chatbots. While frameworks are aplenty, my guideline for evaluation is how easy it is for a designer to design a bot. By designer, I mean a person who does not have a programming background. I will take a rain check on the question whether designers should code for now. The tradeoff is that bots can perform tasks that range in complexity from simple to medium. For those interested to learn more, I will provide the links.

This is an excellent starting point. It covers the basics — designing a chatbot, guiding the user conversation, good practises, etc. Most of the documentation is platform agnostic but there are some references to the Microsoft Bot Framework along with code snippets.Despair not — skim through the technical stuff and you should be able to get the gist.

The below sections in the documentation page should be enough for a beginner. The rest are related to technical specifications.

So can I design and deploy a bot after reading these?

By definition of a framework, these are the basics needed for beginning bot design. Microsoft does not provide any drag and drop tools to deploy bots. Developers will have to use one of these technologies to develop bots — Node.js, Azure bot service, .NET, REST.

Top 3 Bot Tutorials

So it is all just theory?

The QnA Maker is a browser-based free tool that Microsoft has released to build a bot that can answer user queries related to FAQs listed on a company website. It is quite simple and fun to use. The user needs to enter the URL of the FAQ page or upload a text file or enter the data. The framework then parses the data and builds a knowledge base.

We can review the answers and make changes if necessary. For this example, I used the FAQ page of Basecamp site.

Apart from existing questions, we can also add new QnA pairs. I added a question “How long is the trial period” and provided an appropriate answer for it.

Once the changes are done, click on Save and retrain. And then click on the Test tab on the left side.

Here we can chat with the bot and see how it responds. I asked the question “How much does it cost” and got the pricing details.

This reply was provided for the question — “How much does Basecamp cost? Is there a free plan, or are there any special rates?”

The AI framework did a good job of mapping the user’s question to an appropriate QnA pair. Different variations like “pricing details” also returned the correct reply.

There are options to train the bot by providing alternate phrases and answers and few more customisation options.

There you go, you created your first chatbot.

To integrate the bot on your website, it is going to take some technical chops and help of a developer. There is plenty of documentation provided to help with that.

As I mentioned earlier, the objective of this post is to get the hands dirty and not delve too deep into the technical details.

As a beginner myself, I found the QnA Maker quite easy to use and got an idea how to get started with building bots. Go and have fun playing with the bot.