This project is about training an AI chatbot with your own knowledge base using LangChain and ChatGPT API. You can use your own set of documents to train the AI chatbot, which will make the chatbot more relevant to your particular needs.
Before running the application, you need to install some libraries. Use the following commands to install the required libraries:
pip install openai
pip install gpt_index==0.4.24
pip install PyPDF2
pip install PyCryptodome
pip install gradio
Place the documents you want to use to train the AI chatbot inside the "docs" folder.
Follow these steps to run the application:
- Open CMD and navigate to the folder where you saved the app and the "docs" folder.
- Run the command "python app.py" in the Terminal window.
- The application will give you a local URL. Copy and paste this URL into your web browser to use the chatbot.
- To stop the custom-trained AI chatbot, press "Ctrl + C" in the Terminal window.
- To restart the AI chatbot, go to the folder location and run "python app.py" again.
Enjoy using your custom-trained AI chatbot!