Skip to main content

The Importance of Intents and Context in Chatbots

Humans are good in conversations, because they can understand the intent of any statement, also the context in which the statement is placed.

Today’s chatbots are equipped with intent recognition engine. Using machine learning, statements are mapped to intents, and the chabot can handle infinite variations of the same statement. Why is this technique useful? The following example cites this:

Consider you want to ask the contact details of a company. Now every person will ask it in a different way. Following are few of the variations that are possible:

  • Please share your contact details
  • Where do you reside
  • Where are you located
  • Can you share your location
  • Please provide your address
Now the intent of the above questions is “asking address”. So a answer can be mapped to the intent, rather than all the questions. This helps in managing the chatbot easy.

Before intent recognition came into existence, most popular being, recently acquired by Facebook, earlier chatbots were purely based on Artificial Intelligence Markup Language (AIML). AIML was purely a question-answering template. A lot of manual intervention was needed to make the chatbot sound intelligent. Based on pure pattern matching in the questions, it had a basic flaw - it was not able to handle the infinite variations in a question.

Context identification is still a difficult problem, and one of the core problems the AI community is working on. It is argued that, once this problem is solved, AI might have reached the Artificial General Intelligence level, which means the chatbot will be able to match up to human capabilities.

Intent recognition engines such as, Watson Conversation and Microsoft Bot Framework have changed the chatbot scene. Today it is very easy for anyone to develop a chatbot by training it on various intents. Context identification is handled by such engines using a manual process of creating stories or dialogues. A person who is training the chatbot has to write various dialogue flows to make the chatbot understand context.

We at Cere Labs, a Mumbai based startup in Artificial Intelligence, have developed successful chatbots that uses intent recognition. After training the chatbots on various intents, the chatbots have started sounding intelligent, and are able to answer most of the user’s questions. Look into this space as we elaborate on the process of intent recognition.

Let your users talk to your website by using chatbots. You can talk to our chatbot on Cere Lab’s facebook page -


  1. We can build your chatbot from scratch, instilling the best practices of a conversational user experience. From setting up a chatbot on your Facebook Page, to implementing analytics so you can understand how users are becoming customers. Malaysia chatbots


Post a Comment

Popular posts from this blog

Implement XOR in Tensorflow

XOR is considered as the 'Hello World' of Neural Networks. It seems like the best problem to try your first TensorFlow program.

Tensorflow makes it easy to build a neural network with few tweaks. All you have to do is make a graph and you have a neural network that learns the XOR function.

Why XOR? Well, XOR is the reason why backpropogation was invented in the first place. A single layer perceptron although quite successful in learning the AND and OR functions, can't learn XOR (Table 1) as it is just a linear classifier, and XOR is a linearly inseparable pattern (Figure 1). Thus the single layer perceptron goes into a panic mode while learning XOR – it can't just do that. 

Deep Propogation algorithm comes for the rescue. It learns an XOR by adding two lines L1 and L2 (Figure 2). This post assumes you know how the backpropogation algorithm works.

Following are the steps to implement the neural network in Figure 3 for XOR in Tensorflow:
1. Import necessary libraries

Understanding Generative Adversarial Networks - Part II

In "Understanding Generative Adversarial Networks - Part I" you gained a conceptual understanding of how GAN works. In this post let us get a mathematical understanding of GANs.
The loss functions can be designed most easily using the idea of zero-sum games. 
The sum of the costs of all players is 0. This is the Minimax algorithm for GANs
Let’s break it down.
Some terminology: V(D, G) : The value function for a minimax game E(X) : Expectation of a random variable X, also equal to its average value D(x) : The discriminator output for an input x from real data, represents probability G(z): The generator's output when its given z from the noise distribution D(G(z)): Combining the above, this represents the output of the discriminator when 
given a generated image G(z) as input
Now, as explained above, the discriminator is the maximizer and hence it tries to