1 of 14

Chatbots

What, Why and How?

Dorai Thodla @dorait

Bhavani Ravi @geeky_bhavani

Ashish Cherian @Ashcherian

2 of 14

Learning

Goals?

  • A Conceptual Understanding
  • How to build a few simple bots

3 of 14

Agenda

Introductory Session - Dorai Thodla (30 mts)

  • Chatbots what why and how
  • Demo of a chatbot
  • Code walkthrough of smbot ( a simple minded bot built using NLTK)
  • Lab 1 practice (30 mins)

Advanced Session - Bhavani Ravi (30 mts)

  • Session-2: An API.ai based TechBot (an improved bot) - Bhavani
  • Revisiting architecture and flow
  • Training api.ai with intents/entities
  • Mapping intents to actions
  • Lab 2 practice (60 mins)

4 of 14

Topics

  • What is a Chatbot?
  • Why do we need chatbots?
  • How does a chatbot work?
  • How can we build one?
  • Current chatbot ecosystem

5 of 14

What is a Chatbot?

  • A conversational agent with Intelligence
  • Normally lives in a messaging app
  • Interacts with users using speech or text messaging
  • Uses rules or Machine Learning to learn and improve interactions

6 of 14

Why Do We Need Chatbots?

  • There are several theories - one is that it is the future of interaction
  • A single chatbot may replace several apps (especially in mobile)
  • Take care of boring repetitive tasks
  • The story of WeChat

7 of 14

Some Examples of Chatbots

  • Customer Service Bots
  • A SiteBot - Helps navigate a website
  • A teacher bot
  • An Interview Bot
  • Service Bots - Pizza ordering, travel booking
  • More...

8 of 14

A Taste of a Bot Conversation

Hello. Welcome to techbot. My name is Sandy.

Hi Sandy?

Hi How can I help you

Can you give me some python events?

Here are the events you were looking for

Webinar: Three-Dimensional Time

- Working with Alternative DataIoT Systems Design Program ( Advanced Concepts)

Thanks :) Bye...

Utterances and intents

Entity�Python, articles

Action/Response

9 of 14

A Simplified Architecture

AI Engine aka Agent

NLU,

NLG and

ML

Bot Server App

Access KB and interact with AI Engine

Knowledge Base

Chat Clients

  • Webapp
  • Facebook
  • Slack etc.

Extracts intents

Extracts entities

Map intents to actions

Executes Actions

Uses KB or other web services

Contains all the knowledge bot needs

10 of 14

Seven Steps to Building a Chatbot

  • Decides on an application area
  • Design conversations (aka interactions)
  • List intents, entities, actions, responses, contexts
  • Train AI Engine
  • Write Code for Actions
  • Create and update Knowledge Base
  • Test scenarios and incrementally improve

11 of 14

12 of 14

Questions?

Join our Slack Channel

buildingchatbots@gmail.com

13 of 14

Entity

What is an Entity?

An entity is a concept we want our personal assistant to understand when it is mentioned by the user in conversation. There are three types of entities in Api.ai:

System – entity types defined by Api.ai such as date, color, email, number and so on which Api.ai already understands. You can find a full list of these entities in Api.ai’s documentation on System Entities.

  • Developer – Entities which we create for our individual needs — these are what we will be focused on in this article.
  • User – These are created for individual users while they use the assistant and can be generated by the Api.ai API to be used within a single session. We won’t be covering these in this article but if there’s enough reader interest, we might explore this in future!

14 of 14

Api.ai Terms and Concepts