This application is built with Streamlit and Google Gemini API to analyze images, search for food products, and provide food recommendations or recipes. It uses the Open Food Facts API for food product searches and allows users to share reviews for products.
- Upload or capture images to analyze food items.
- Search for food products using the Open Food Facts API.
- Receive food recommendations or recipes based on image analysis.
- Submit reviews for food products.
-
Clone the repository:
git clone https://github.com/yourusername/foodXense.git cd foodXense -
Create a virtual environment and activate it:
python -m venv venv source venv/bin/activate # On Windows use: venv\Scripts\activate
-
Install the required dependencies:
pip install -r requirements.txt
-
Set up your secret variables for the Google Gemini API:
- Create an
secrets.tomlfile in the .streamlit directory and add your Google Gemini API key:GOOGLE_API_KEY=your_google_gemini_api_key
- Create an
-
Run the app:
streamlit run app.py
.
├── __pycache__/ # Compiled Python files
├── .streamlit/ # Streamlit configuration files
├── secrets.toml # Secrets configuration file
├── app.py # Main application file
├── foodXense.py # Contains the Open Food Facts API search functionality
├── README.md # Project documentation
├── requirements.txt # List of Python dependencies
├── .gitignore # Files and directories to ignore in version control
# Environment variables (not tracked by git)