A gentle introduction on Building an intelligent Chatbot in Python by Paulus Shituna

7b0645f018c0bddc8ce3900ccc3ba70c?s=47 Pycon ZA
October 11, 2019

A gentle introduction on Building an intelligent Chatbot in Python by Paulus Shituna

Chatbots have the potential to save any individual’s time, hassle, and tedium by automating mundane tasks. Today almost every company has a chatbot deployed to engage with the users. Some of the ways in which companies are using chatbots are: Information distribution & customers support. So In this talk, I am going to take you through step-by-step on how to develop a chatbot in python; by exploring some of the its attributes, Classes, Reflections, Instances, API integrations, database, Dictionaries and interfaces. Since this will be purely introduction talk, I expect the audiences to be intermediate and beginners.

7b0645f018c0bddc8ce3900ccc3ba70c?s=128

Pycon ZA

October 11, 2019
Tweet

Transcript

  1. Paulus Shituna PyCon Namibia University of Namibia Adviser: Prof Rodriguez

    Puente A gentle introduction on Building an intelligent Chatbot in Python
  2. Content Chabbot Chatbot Usages Types of Chatbots Artificial Intelligence Markup

    Language(Rule-Based Chatbots) Demo..
  3. Chabbot (chatterbot) Is a computer program that attempts to simulate

    the conversation or “chatter” of a human being via text or voice interactions. Basically, it receives the command from the user and responds back in a satisfactory way to the user. 24-hour a day availability at reduced costs Compatibility with all devices, including mobile, social networks, and even SMS
  4. Chatbot Usages Many sectors like E-commerce, Education, Finances, HR, Healthcare

    each and every place where there is a need for certain information to be responded back or certain action to be taken based on simple text or voice query by the user. Chatbots Market worth 3,172.0 Million USD by 2021 which will only increase based on the NLP improvements and the AI improvements. Chatbots expected to cut business costs by $8 billion by 2022.
  5. Disadvantages of chatbots Zero decision-making Time-Consuming Inability to Understand

  6. Types of Chatbots There are to types of bots 1.

    Rule-Based Chatbots 2. AI-Based Chatbots
  7. Rule-Based Chatbots provided with a list of set answers for

    a set of queries a user might use the chatbot for. The bots can handle simple queries but fail to manage complex ones.
  8. AI-Based Chatbots uses some heuristic to select a response from

    a library of predefined responses. This makes them more intelligent as they take word by word from the query and generates the answers.
  9. AIML (Artificial Intelligence Markup Language)

  10. AIML-(Rule-Based Chatbots) A.L.I.C.E., or Artificial Linguistic Internet Computer Entity, was

    the first example of a bot created using AIML. AIML is an XML based markup language meant to create artificial intelligent applications. AIML makes it possible to create human interfaces while keeping the implementation simple to program, easy to understand and highly maintainable.
  11. Basic Tags: There are around 14 tags that we normally

    use in AIML. 1. <aiml>: Defines the beginning and end of an AIML document 2. <category>: Defines the knowledge in a knowledge base. 3. <pattern>: Defines the pattern to match what a user may input. 4. <template>: Defines the response of an to user’s input.
  12. Inputs...

  13. Results..

  14. More Tags: 1. <star>: Used to match wildcard * character(s)

    in the <pattern> Tag. 2. <srai>: Multipurpose tag, used to call/match the other categories. 3. <random>: Used <random> to get random responses. 4. <li>: Used to represent multiple responses. 5. <set>: Used to set value in an AIML variable. 6. <get>: Used to get value stored in an AIML variable. 7. <that>: Used to respond based on the context. 8. <topic>: Used to store a context so that later conversation can be done based on that context. 9. <think>: Used to store a variable without notifying the user. 10. <condition>: Similar to switch statements in a programming language. It helps bot to respond to match the input.
  15. Random responses in AIML file: Responds randomly when it receives

    a message that starts with “One time I “. The * is a wildcard that matches anything.
  16. Demo...

  17. Conclusion Questions Suggestions pshituna@unam.edu.na