Google Gemini, formerly known as Bard, is an artificial intelligence (AI) chatbot platform that uses machine learning and natural language processing (NLP) to mimic human conversations.
Create a user-friendly chat interface using Streamlit that connects with Google's state-of-the-art large language model, Gemini. The goal is to provide an accessible platform for exploring and showcasing the capabilities of advanced language models. This project aims to serve as an educational and practical introduction to integrating large language models with intuitive interfaces.
- Task 1: 🌐 Enable Google Cloud
- Task 2: 🧬 Google Cloud Initialization
- Task 3: ☁️ Setting up Google Gemini
- Task 4: 📊 Streamlit Integration
- Task 5: 🗣️ Adding Initial System Messages
- Task 6: 📄 Preparing Submission
- Python version 3.11x or above Python
- Streamlit Streamlit Documentation
- Gcloud account
- Vertexai Vertexai Documentation
- Go to the Google Cloud Platform and Select "Get Started for free".
- Sign in using your Google Account and then provide the necessary details and complete the billing requirments.
- Accept the terms and conditions.
- Complete the payment process to initialize your Google Cloud Account.
- Create a new project (for instance "RadicalX - Gemini Explorer").
- Access the Google Cloud Console.
- Navigation -> Artificial Intelligence -> Vertex AI -> Enable All Recommended APIs
- Install the Google SDK using this Link.
- Run the following command to initialize the SDK:
gcloud init
- Sign in using your Google Account credentials.
- Select an existing project or Create a new project
- Set default compute region and zone (Optional Step)
- Install the streamlit framework
pip install streamlit
- Refer the Streamlit Documentation to see an Implementation using OpenAI's ChatGPT
- In the project, we are using Google's Gemini Pro LLM.
- Use the project ID instead of the project name, like this:
project = "project_id"
. This helps avoid encountering a 403 permission denied error.
- Implement the steps given in the mission.
- Run the python file
streamlit run filename.py
.
- A GitHub repository for the project containing all the project files.
- Loom Video representing the overall approach. Loom Link
⚠️ Issue 403: Permission Denied Error: Check if you have provided project_id rather than project name in your code or if the service account is activated.
Special thanks to Talha Sabri and Mikhail Ocampo for extending to me the opportunity to embark on and complete this AI Mission.