This project utilizes the GeminiAI Generative Model by GOOGLE to extract information from images based on user input. The code is designed to take an image and a user prompt, then generate relevant information using the GeminiAI API.
Before running the code, ensure you have the required libraries installed. You can install them using:
pip install -r requirements.txt
Create a .env
file in the project directory and add your Google API key:
GOOGLE_API_KEY=your_api_key_here
Run the main.py file:
streamlit run app.py
- Enter a prompt in the provided text input.
- Upload an image (supported formats: jpg, jpeg, png).
- Click the "RUN" button to generate information based on the input and image.
The code uses the GeminiAI Generative Model named 'gemini-pro-vision' for image analysis.
- Python 3.10
- Streamlit
- Pillow (PIL)
- GeminiAI