Skip to content

Relatively simple AI-based chatbot that simulates human conversation through text chats.

License

Notifications You must be signed in to change notification settings

nedeljkovignjevic/chatbot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

chatbot

Relatively simple AI-based chatbot that simulates human conversation through text chats.
Most common use case for this type of chatbot is answering frequently asked questions. Also it can be used for fun.

Chat example

moze

Neural network architecture

Neural network model is fairly standard feed-forward neural network model with 2 hidden layers per 4 neurons.

  • Inputs to the network are one hot encoded values of "bag of words" - bag of words because the order in
    which the words appear in the sentence is lost, we only know the presence of words in the models vocabulary.
    Each sentence is represented with a list the length of the amount of words in models vocabulary.
    Each position in the list will represent a word from the vocabulary.
    If the position in the list is a 1 then that will mean that the word exists in input sentence, if it is a 0 then the word does not exist.

  • Similarly to a bag of words, on output of neural network are lists which are the length of the amount
    of labels in dataset.
    Each position in the list will represent one distinct label, a 1 in any of those positions
    will show which label is represented.
    Labels: greeting, goodbye, basic, thanks, meme

Requirements

You can use pip to install the following:

1. python 3
2. tensorflow
3. numpy
4. nltk

License

chatbot is released under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0

About

Relatively simple AI-based chatbot that simulates human conversation through text chats.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages