Skill Level: Any Skill Level

In this article we’re going to learn what does it take to save time to our customer support team. To do this we’ll build a chatbot to automate answers to frequently asked questions, eventually saving precious time to your customer support operators so the


Deliver lightening fast customer support at scale requires a lot of resources and this is why you want your end users or employee to be able to self serve as much as possible.

Bots have been around for a long time, but recent advances in natural language processing drove huge adoption over the last year. They are now being used to enhance a broad set of experiences with customer service being one of the most relevant.

In this article we’re going to learn what does it take to save time to our customer support team. To do this we’ll build a chatbot to automate answers to frequently asked questions, eventually saving precious time to your customer support operators so they can focus on more complex requests. 

The picture below shows how the interaction flow between the user and the chatbot will look like.


  1. Key for success: focus and clear target

    Pick one use case and focus on that. It’s better to have a virtual agent that is good at one thing than one who is not bad at many. You can always work on extending its abilities later.

    This is crucial for setting realistic expectations on the ROI of developing custom support chatbot. It’s unrealistic to fully automate customer support, while aiming to deflect 20–40% of the most recurring questions makes much more sense and is totally achievable. 

    If your team is handling 10000 conversation a month you can easily do the math and figure out the time (and money) saved.

    It’s important to guide users and explain what the bot is capable of doing. That way they will know what they can ask, and will be less disappointed if the bot can’t handle random topics.

  2. Questions drive the answers

    IBM Watson analyzes the user’s input with the objective to determine her intent, or what she is trying to achieve. In our case, the intent corresponds to the topic of the question.

    In Watson Conversation, you define an intent by providing a number of examples which have the same meaning (i.e. the same ‘intent’). So, for example, if you want Watson to understand when someone is asking how to get a credit card, you might provide some examples such as:

    • how do I get a credit card?
    • Where do I get a credit card?
    • I want to get a credit card, how do I go about it?
    • When can I have a credit card?

    It is important to understand that questions drive the answers/intents and not the other way around. Collecting the questions first allows you to see what your users will be asking and focus on actions your intents take.

  3. Intents architecture

    What we found useful in our project is to divide intents in two macro-categories: knowledge base and small talk. The former is intended to manage the actual answers we want to deflect for our customer sup port, the latter aims to cover the basic interaction to make the bot feel a bit more human.

    This is important to define the way answers will be organized and stored, knowledge bases can be quite large so we prefer to manage them in a separate database rather than inside Watson’s conversation dialog model. 

  4. Training the Knowledge base

    You will probably kick-off the knowledge base using the FAQs that you already published on the website. So, you will have a question and a corresponding answer. 

    Any answer is an intent. You have to figure out all the possible ways the users will ask that question to provide enough examples to IBM Watson to allow the pairing of questions with the right intent.

    Avoid domain specific terms, because most users will refer to your products with common language. If you have a log of requests, you already know that many requests can be ambiguous and difficult to classify.
    Remember that the knowledge base will need constant maintenance and fine tuning, because there will always be new questions and new ways to express the same question.

    A practical way to kickoff a knowledge base is a two columns spreadsheet, this makes also very easy to import this data into IBM Watson Conversation later.

    A sample of the spreadsheet is availablehere, make a copy and edit it with your content. The sheet Questions is where you provide as many examples of question as you can for each intent. Each intent is mapped to an answer in the Answer sheet.

    The text contained in the class column is the identifier of the intent, all questions intents have a prefix that starts with kb_.

    IMPORTANT: For a properly trained cluster you will need a minimum of 5 questions, 10 is much better. 

    Once you’re done with the questions export them as CSV, so we can import them into Watson with a simple file upload. To export the content of the a sheet on Google Spreadsheet go to File -> Download as -> Comma-separated values.

    Let’s now open Watson and create the second set of intents that our chatbot will be able to handle, the small talk.


  5. Getting started with Watson

    To get started with IBM Watson Conversation, you’ll need a Bluemix account. If you don’t have one already, you can sign up here. Once you have signed in, navigate to the catalog, scroll down to the Watson services, and select the Conversation tile.

    This will bring up a window with some links and information. Click on the Launch tool button to get started

    At this point you can create a workspace. In this step you can give it a name, write a description, and choose from one of the languages supported.


  6. Adding the Small Talk

    The small talk intents can be defined directly on Watson because the answers to these questions will be inside the dialog model.

    1. In the IBM Watson Conversation tool, open your workspace and then select the Intents tab in the navigation bar. 
    2. Select Create new.
    3. In the Intent name field, type a descriptive name for the intent. Make sure they all have the smalltalk_ prefix so later we need to lookup for the answer in the knowledge base database or not
    4. In the User example field, type the text of a user example for the intent. 

    After creating a few intents for the small talk, select the Dialog tab in the navigation bar and add one node for each smalltalk_ intent. For each node make sure you type at least one response.

    When you have all the nodes created you can test the responses on the small talk by clicking on the chat bubble icon in the upper right corner.

    Adding “smalltalk_” Intents in the Dialog model and testing it

    The intents we really don’t want to forget here are: 

    • greetings: reply to all kind of greetings
    • generic_help: reply to questions like “how can you help” “what can you do” and explain what the bot is capable of doing.
    • handoff_operator: recognize if the user wants to escalate the conversation to a human agent
  7. Importing the Knowledge base intents

    The last step is to import the kb_ intents to Watson by uploading the CSV file that we previously saved from the Google Spreadsheet.

    Select the Intents tab in the navigation bar, then click on import and select your CSV file. All the intents will be uploaded and you can improve the training by adding more example of questions to the kb_ intents from the Watson interface. If you prefer to work with the spreadsheet you can export the intents anytime and re-upload them here.

  8. Integrate all the things

    The conversation part of our customer support chatbot is done but it now needs to be integrated with the apps used by our organization. 

    Maybe we want to notify on Slack when the conversation is escalated to a human operator and what that happens we also want to open a case on Salesforce. 

    Maybe you want to publish across different channels such as Intercom and Facebook Messenger.

    Maybe we want to collect all interaction data and feed it into an analytics tool like Mixpanel or log all the interactions on a G Suite Spreadsheet or a Smartsheet.

    Regardless of the amount of apps you need to connect with, you have to make sure you are able to support them as soon as they’re requested.

    An orchestration tool is the only way to be able to connect so many different apps together as if they were Lego blocks and no code.

    In this example we showed how to setup our chatbot on IBM Watson, from here pick the part 2 that fits your needs.

    We’ve built a set of ready to go templates to publish your chatbot across different platforms, make sure to check this blogpost or signup to Stamplay to stay up to date with them.

  9. Pick the Part 2 that suits your needs

    • Connecting the FAQ bot to Intercom (Blogpost)
    • Connecting the FAQ bot to Facebook Messenger (coming soon)
    • Connecting the FAQ bot to Cisco Spark (Youtube,Slideshare)
    • Connecting the FAQ bot to Kik (coming soon)
    • Connecting the FAQ bot to Telegram (coming soon)
    • Connecting the FAQ bot to HipChat (coming soon)
    • Connecting the FAQ bot to Slack (coming soon)
    • Connecting the FAQ bot to SMS using Twilio (coming soon)
    • Connecting the FAQ bot to Twitter (coming soon)
  10. Conclusions

    AtStamplay we make it easy for people to automate workflows and processes by tying together the apps you use with AI. 

    If you’re aiming to improve your business processes and operations with the use of AI don’t hesitate to drop us a line at hello@stamplay.com.

Join The Discussion