Chatbot Using Kivy and Tensorflow
Manoj B E
Bengaluru, Karnataka
- 0 Collaborators
This is an AI enabled Chatbot that uses techniques using Python, Kivy, kivyMD, Natural Language Processing and Tensorflow. ...learn more
Project status: Concept
oneAPI, Artificial Intelligence, Cloud
Intel Technologies
oneAPI,
Intel Deep Link,
Intel Python
Overview / Usage
The chatbot will use natural language processing to understand users' requests and provide information on personal development and self-improvement. The chatbot will provide personalized responses to users’ enquiries and make the interaction more engaging and relevant. The chatbot will be trained for providing companionship and for users to provide emotional support. The chatbot will be able to connect with individuals and provide necessary solutions and support. This project seeks to leverage the power of technology to facilitate social change by making it easier for individuals to get support and make a positive impact on society
Methodology / Approach
The chatbot uses a neural network to classify user input and generate responses based on predefined intents stored in a JSON file.
The code first imports the required libraries and sets the window size for the app. It then loads the intents file and tokenizes the patterns in each intent, stemming the words and creating a bag of words for each pattern. It also creates output data for each pattern based on the intent tag. These bags of words and output data are used to train the neural network. The trained model is saved to disk using YAML and HDF5 formats.
The bag\_of\_words
function preprocess user input by tokenizing, stemming, and creating a bag of words that can be fed into the neural network for classification.
The chatWithBot
function takes the preprocessed user input, uses the neural network to classify the intent, and returns a randomly selected response from the JSON file associated with that intent.
The Command
and Response
classes define the appearance of the chat interface.
The ChatBot
class defines the chat interface and includes a chat
method that handles user input and output using the chatWithBot
function.
Technologies Used
Python: The programming language used for writing the code,
Kivy, KivyMD is a cross-platform application framework that works on any platform upon building once.
NLTK: A popular Python library for natural language processing
TensorFlow: A machine learning framework for building and training models. NumPy: A Python library used for numerical operations
Repository
https://github.com/MXNOJBE/Chatbot_IntelHackathon.git