Chatbot Development

Creating a Chatbot using Deep Learning and NLP

This project focuses on creating a smart chatbot using deep learning and Natural Language Processing (NLP). The primary goal is to build an intent-based conversational virtual assistant capable of understanding and responding to user inputs in a human-like manner.

Project components

  • This project is made up of four essential components, and they all work together to make a full and effective chatbot.
    • 1. Development of an intent-based chatbot:

    • A feed-forward neural network was used to train the intent-classification model
    • Utilizing NLTK techniques such as tokenization, stemming and bag of words to pre-process the training data and as well as user-inputs.
    • TechniqueDescriptionUsage
      TokenizationProcess of breaking text into words or phrases (tokens).allowing the chatbot to understand and process individual components of user input.
      StemmingReducing words to their base or root form.Improves text analysis by grouping similar words.
      Bag of WordsRepresents text as an unordered set of words.transforming text into numerical representations that serve as feature vectors for training models to recognize user intents.
    • • Before training the FNN model, it is required to prepare the training data in a json format.
    • • The intents.json is a file used to train intent-based chatbots. It defines user intents with names and associated training examples, teaching the chatbot how to recognize and respond to different user inputs.
    • • This file is crucial for natural language understanding, contributing to the chatbot's accuracy and effectiveness in understanding user intent.
    • Below is a snippet example of the training data:

      json

      2. Integrating the Chatbot with APIs:

    • • The chatbot was integrated with 2 external APIs (themoviedb ,openweather)
    • themoviedb API allows the chatbot to extract movie details.
    • openweather API allows the chatbot to extract weather details.
    • • Additionally, I also integrated the chatbot with thewikipedialibrary to parse data wikipedia.

    3. Establishment of an API endpoint:

    • Creating an API endpoint using flask for front-end applications.

    • By creating an endpoint, the chatbot now can be integrated with a front-end application

    c2

    4. Designing a user interface for the chatbot using JavaScript, HTML, CSS via the ReactJS framework, ensuring a seamless and interactive user experience:

  • For this project, I have also designed a Chatbot UI using front-end tools like HTML, CSS and javascript
  • You can find the source code for the UI design within my github repository if interested. NOTE: I'm using reactJS framework
  • bot

    • The chatbot created for this project is deployed to a cloud and it is integrated with my personal portfolio, feel free to interact with my chatbot.

    Check out my Github Repository if you want to learn how to train your own custom-chatbot:

    View on Github

    Chat Assistant

    Hi! How can I help you today?