This project implements a chatbot using Streamlit, OpenAI, and Langchain. It allows users to interact with an AI assistant powered by OpenAI's language model.
To run this project, ensure you have Python installed, then follow these steps:
-
Install the required dependencies:
pip install -r requirements.txt
-
Set up your Streamlit secrets:
- Obtain your OpenAI API key and your assistant ID.
- Create a
.streamlit
folder in your project directory if it doesn't exist. - Inside
.streamlit
, create a file namedsecrets.toml
and add the following:[secrets] OPENAI_API_KEY = "<your_openai_api_key>" ASSISTANT_ID = "<your_assistant_id>"
-
Run the Streamlit app:
streamlit run app.py
- Once the Streamlit app is running, you'll see the interface for the Datawise Bot.
- Type your message in the chat input and press Enter to send it.
- The bot will respond with relevant information generated by OpenAI's language model.
- You can continue the conversation by entering more messages in the chat input.
- streamlit>=1.26
- langchain>=0.1.0
- openai>=1.6.1
- duckduckgo-search
- eb2
Note: Make sure to check for the latest versions of these dependencies.