This repository contains the source code and resources for a railway's chatbot built using a Large Language Model. The chatbot is designed to assist railway passengers by providing information on train schedules, platform details, delays, and other related inquiries. It leverages a state-of-the-art large language model to understand natural language queries and deliver accurate responses.
-
Natural Language Understanding: Utilizes advanced language processing to understand user queries conversationally.
-
Multilingual Support: Supports various languages to cater to diverse passenger needs.
-
Real-time Information: Provides up-to-date information on train schedules, delays, and platform changes.
-
Interactive Interface: Engages users in a chat-like interface for a seamless and user-friendly experience.
- Clone the Repository:
git clone https://github.com/kunal9922/Multilingual_Railways_Chatbot.git
- Make an alias for Windows PowerShell
New-Alias -Name python310 -value "yourPython3.10.exe path"
- Create a Python Virtual Environment
python310 -m venv venvChatbotRailways
- Activate the virtual environment
venvChatbotRailways\Scripts\activate
-
Chocolatey a Windows package manager to install https://chocolatey.org/install
choco install ffmpeg
-
Homebrew a MacOS package manager to install https://brew.sh/
brew install ffmpeg
-
For Linux OS
sudo apt update && sudo apt install ffmpeg
-
Install Dependencies:
pip install -r requirements.txt
-
Shift to the Django Server Directory
cd chatbotWebServer\
-
Download the LLAMA-2-7B Model from https://huggingface.co/meta-llama Save the LLM model into this directory "\chatRailways\chatbotModule\models"
-
Run the Django Server for the Chatbot:
python manage.py runserver
-
Interact with the Chatbot:
- Open a web browser and go to
http://localhost:8000
to interact with the chatbot through a simple web interface.
- Open a web browser and go to
We welcome contributions! If you would like to contribute to the development of the Railways Chatbot (This project is continuously evolving).
This project is licensed under the MIT License.
Feel free to reach out with any questions or feedback!
Happy chatting! ππ€
englishChat.mp4
ItalianChat.mp4
A web-based chatbot for train queries using Django. This UML Activity Diagram shows the steps and messages between a passenger, a chatbot, and a railway database. For example, the passenger asks "query about trains" and the chatbot replies with the answer.
This diagram shows how to build a chatbot that can interact with CSV files. The chatbot extracts data content from a CSV file and converts it into embeddings using a vector store. Then, it builds a semantic index based on FAISS to perform semantic search on the data. The chatbot can answer user queries by converting them into query embeddings and searching for the most relevant answers in the knowledge base.