Skip to content

ashish25-bit/chatbot-node-nlp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Chatbot Implementation on websites

This is a simple chatbot with a frontend interface.
Programming languages used: python, nodejs, html, css and javascript.

Modules, packages and dependencies


Python:

  1. Install PyTorch (click here). Select your peferences carefully. I have used used pip for installation. Option for installing with conda is also available.

My Options

  1. Natural Language Toolkit or NLTK.
    You will also need punkt.
    pip3 install ntlk
    
    $ python3
    >>> import ntlk
    >>> nltk.download('punkt')

Nodejs:

  1. Express for creating server.
    npm install express
  2. Python-shell. Is is used for connecting python script with nodejs.
    npm install python-shell
  3. Nodemon a dev dependency.
    npm install --save-dev nodemon
  4. Simply run npm install in the terminal to install all the packages.

Running the application

The model is already trained.
Change the intents.json file according to your choices and retrain the model. This will create a new data.pth file.
In the root of the folder run the command npm start to start the server. Go to http://localhost:5000 after the connection is established.

Chatbot Interface.