CiboGenie is an AI-powered application designed to revolutionize food analysis. Whether you're a food enthusiast, health-conscious individual, or a professional in the food industry, CiboGenie provides interactive, actionable insights into food items. Using cutting-edge AI, CiboGenie analyzes food ingredients, recommends healthier substitutes, and helps you make informed decisions about what you eat.
With integrations to Wikipedia, Google Search, SERP API, Groq API, and advanced AI models, CiboGenie offers detailed insights on:
- 🥗 Food Ingredients: In-depth analysis of food components.
- ⚖️ Safe Consumption Guidelines: Ensures safe and healthy food consumption.
- 🍎 Healthier Alternatives: Recommends healthier substitutes to improve your diet.
- 🔍 Product Comparisons: Compares the food you're consuming with similar products in the market.
- 🏪 Nearby Shop Recommendations: Finds local stores where you can purchase the food item.
- 🥗 Food Analysis: Provides a comprehensive breakdown of food ingredients, health considerations, and consumption guidelines.
- 🤖 AI-Powered Recommendations: Suggests healthier substitutes and analyzes food items based on nutrition and quality.
- 🏪 Nearest Shops Finder: Allows users to input their location and find the nearest shops that sell the given food item.
- 🌐 Multi-Source Data Gathering: Utilizes data from Wikipedia, Google, and other credible sources to provide well-rounded insights.
- 🔄 Retrieval-Augmented Generation (RAG) Pipeline: Combines information retrieval with generative AI for improved and more accurate responses by leveraging external data sources such as Google Search, Wikipedia, and PDFs.
- 📖 PDF Parsing and Analysis: Extracts and analyzes content from PDF documents using PyPDF2 for richer insights.
- 🔍 Semantic Similarity Analysis: Employs Sentence Transformers to compute embeddings and find semantically similar content.
- 🗄️ Vector Storage Using FAISS: Stores and retrieves document embeddings for efficient search within PDFs and other data sources.
- 🔧 Customizable: Designed to adapt to specific food items, ensuring tailored recommendations.
- 🌎 Geolocation Services: Integrates with the Google Maps API to find nearby shops based on user location.
- 🛠️ Customizable Token Limit: Allows users to adjust the maximum token limit for responses to optimize performance based on specific use cases.
- Python: Core programming language for application logic.
- Streamlit: Interactive and user-friendly interface for the application.
- TensorFlow: Supports machine learning-based recommendations and food analysis.
- Groq API: Powers natural language processing for generating detailed insights.
- RAG Pipeline: Enhances response accuracy by combining retrieval with generative AI.
- SERP API: Fetches relevant data from Google Search for food analysis and nearby shop recommendations.
- Wikipedia API: Retrieves detailed summaries and credible information about food items.
- PyPDF2: Parses and extracts text from PDF documents to enhance analysis capabilities.
- FAISS: Efficient vector store for storing and retrieving document embeddings.
- Sentence Transformers: Computes embeddings to enable semantic similarity searches.
- Google Maps API: Finds nearby stores where the food item can be purchased.
- dotenv: Manages environment variables such as API keys securely.
Before running CiboGenie, ensure you have the following:
- Python 3.x
- An active API Key for accessing Google, Wikipedia, and other data sources
-
Clone the repository:
git clone https://github.com/your-username/CiboGenie.git cd CiboGenie
-
Create and activate a virtual environment:
python -m venv cibogenv source cibogenv/bin/activate # On Windows, use cibogenv\Scripts\activate
-
Install the required dependencies:
pip install -r requirements.txt
-
Set up the environment variables for API keys:
- Create a
.env
file in the project root and add your keys:GOOGLE_API_KEY=your_google_api_key GROQ_API_KEY=your_groq_api_key GOOGLE_MAPS_API_KEY=your_google_maps_api_key
- Create a
-
Run the application:
streamlit run app.py
-
Open the local URL (usually http://localhost:8501) in your browser to start using CiboGenie.
- Enter a Food Item: Type a food item (e.g., "Coke") into the input field.
- Get Detailed Insights: Receive a structured, actionable breakdown, including:
- Ingredients List
- Safe Consumption Guidelines
- Healthier Substitutes
- Comparison with Similar Products
- Special Health Considerations
- Add Your Location: Input your location (city or area) to find the nearest shops where you can purchase the food item.
- Explore Further: Browse through recommendations for better alternatives and dietary tips.
- The token limit for the RAG pipeline is set at 3000 tokens by default. This value can be adjusted by the user to optimize performance based on their specific use case or application.
- To adjust the token limit, you can modify the
max_tokens
parameter in the configuration file or directly in the pipeline settings in the application code.
- To adjust the token limit, you can modify the
Pizza
Pepsi Cold Drink
Pizza
We welcome contributions to make CiboGenie even better! Here’s how you can help:
- Fork the repository
- Create a feature branch
- Commit your changes
- Push to the branch
- Submit a pull request
This project is licensed under the GNU General Public License (GPL) Version 3, 29 June 2007. See the LICENSE file for details.
For any inquiries or feedback, feel free to reach out:
- Email: ranjeetkulkarni2505@gmail.com
- Email: iit2023064@iiita.ac.in
- GitHub: CiboGenie Repository
Thank you for using CiboGenie! We hope it makes your food analysis journey both insightful and exciting.