This project requires several API keys and accounts to be set up as a pre-requisite. In the following, we will guide you through the installation and give necessary steps to get the chatbot online.
- go to https://openai.com/
- locate "API Login"
- create new account to create a new OPENAI project API key
- go to https://app.tavily.com/
- create an account to obtain an API key
- go to https://app.pinecone.io/
- create an account to obtain an API key
- create a new index name
- go to https://console.firebase.google.com/
- create a new project
- create a new Firestore Database
- create a new collection
- head to "Project settings > Service accounts > Firebase Admin SDK > Generate new private key" and download "firebase_keys.json"
- Clone the repository to your desired location (i.e. C:/path/to/folder/Verchat-Chatbot)
-
Open up the project folder using a code editor
-
Locate the "env.text" file in "C:/path/to/folder/Verchat-Chatbot/chatbot_back-end"
-
Fill in the required API keys for OPEN AI, TAVILY, PINECONE.
-
Place "firebase_keys.json" into this directory
- In query_PDF.py and query_internet.py, insert your Pinecone index name.
- Namespace can be changed to desired name
- Open Command Prompt
- To create the virtual environment:
python -m venv <NameOfVirtualEnvironment>
- To activate the virtual environment:
path/to/venv/<NameOfVirtualEnvironment>\Scripts\activate.bat
- In your command prompt, activate the previously-made virtual environment. This window is the "backend server"
- Navigate to the "C:/path/to/folder/Verchat-Chatbot/chatbot_back-end"
- Install python requirements found in /depedencies:
pip install -r dependencies/requirements.txt
- Open a new window of command prompt and activate the same virtual environment. This window is the "frontend server"
- Navigate to the "C:/path/to/folder/Verchat-Chatbot/chatbot_front-end"
- Install node.js packages:
npm install
-
In the "backend server" run:
uvicorn app.main:app --host 127.1.1.1 --port 4000 --reload
-
Once both servers have fully and successfully initiated, open up any internet browser to "http://localhost:3000" to view the chatbot