rishumehrotra / Context-Based-LLMChatbot

Use vector search or embedding technique to feed addtional knowledge base to LLM like GPT-3, BLOOMZ

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

πŸ’ Document-Based/Context-Based Chatbot with Langchain, LLM (GPT-3), and Chroma πŸ“

build LinkedIn  Medium Articles

πŸ€– This is a chatbot that uses a combination of Langchain, LLM (GPT-3), and Chroma to generate responses based on a user's input and a provided document or context. Features

  1. Generates responses based on a user's input and a provided document or context
  2. Uses Langchain to preprocess the user's input and document/context
  3. Uses LLM (GPT-3) to generate responses based on the preprocessed input and document/context
  4. Uses Chroma to highlight important words and phrases in the document/context
  5. Built with Python and Streamlit, making it easy to run and demo

🎯 Demo:

ChatScreen 1 ChatScreen 2
ChatScreen 3

Technical Architecture

Documentation

Read the article to learn more.

Requirements

Python 3.7 or later
Streamlit 0.80.0 or later
OpenAI API key with access to LLM (GPT-3)

Installation

Clone the repository:

git clone https://github.com/your-username/your-repository.git

Install the required Python packages:

pip install -r requirements.txt

Set up your OpenAI API key by creating a .env file in the root directory of the project with the following contents:

OPENAI_API_KEY=<your-api-key-here>

Run the Streamlit app:

streamlit run app.py

Cutomize the Document

If you would like to test with any personalized document please replace the docs directory.

Usage

  1. Enter a message or question in the imput prompt panel. This is what you want the chatbot to respond to.
  2. Click the "Send" button or press Enter to generate a response from the chatbot.
  3. πŸŽ‰ The response will appear in the right-hand panel

Contributions

πŸ™Œ Contributions are welcome! If you have any suggestions for improving this chatbot, please submit a pull request. License


If you like this do star to this repo ⭐ and contributes...πŸ’πŸ’πŸ’


Thanks for reading...πŸ™πŸ™πŸ™


πŸ“ This project is licensed under the MIT License. See the LICENSE file for details.

About

Use vector search or embedding technique to feed addtional knowledge base to LLM like GPT-3, BLOOMZ

License:MIT License


Languages

Language:Jupyter Notebook 75.5%Language:Python 24.5%