Skip to content

akshaybannatti/Chatbot-in-Python-using-Natural-Language-Processing-Toolkit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Building a Simple Chatbot from Scratch in Python (using NLTK)

Alt text

History of chatbots dates back to 1966 when a computer program called ELIZA was invented by Weizenbaum. It imitated the language of a psychotherapist from only 200 lines of code. You can still converse with it here: Eliza.

On similar lines let's create a very basic chatbot utlising the Python's NLTK library.It's a very simple bot with hardly any cognitive skills,but still a good way to get into NLP and get to know about chatbots.

Chatbots play a crucial role in modern businesses as they possess the capability to efficiently address customer inquiries and provide information without causing delays. By automating various procedures, they significantly reduce the workload on customer support teams. Achieving this level of automation is made possible through the implementation of Machine Learning, Artificial Intelligence, and Data Science techniques. Chatbots operate by analyzing the input provided by customers and generating appropriate responses based on predefined mappings. To train a chatbot, Recurrent Neural Networks can be employed along with intention datasets in JSON format, while the implementation can be carried out using the Python programming language. The nature of the chatbot, whether it is specific to a particular domain or caters to a wide range of topics, depends on the desired objective.

Outline

Motivation for developing this project

The idea of this project was not to create some SOTA chatbot with exceptional cognitive skills but just to utilise and test my Python skills.

BlogPost

Underdevelopment currently

Installation of NLTK

pip install nltk

Installing required packages

After NLTK has been downloaded, install required packages

import nltk
from nltk.stem import WordNetLemmatizer
nltk.download('popular', quiet=True) # for downloading popular packages
nltk.download('punkt') 
nltk.download('wordnet') 

You can run the chatbot.ipynb which also includes step by step instructions.

  • Through Terminal
python chatbot.py

About

Developing a Chatbot in Python using Natural Language Processing Toolkit

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published