Reveal the hidden carbon cost of your shopping. > Turn messy receipts into actionable climate data instantly using AI.
- About the Project
- Key Features
- How It Works (The Science)
- Tech Stack
- Getting Started
- Screenshots
- Roadmap
- License
EcoLens bridges the gap between economic activity and environmental impact. While most carbon calculators focus on transport (flights/cars), they often ignore a massive chunk of daily emissions: Retail Consumption (FMCG).
Manually inputting grocery items into a calculator is tedious. EcoLens solves this by using Google Gemini 1.5 Flash to visually scan receipts, decipher abbreviations, classify products into scientific economic sectors, and calculate their carbon footprint in seconds.
- 📸 AI Receipt Scanner: Snap a photo of any receipt (thermal, crumpled, or faded).
- 🧠 Multimodal Intelligence: Uses Gemini Vision to read text and understand context (e.g., mapping "Indomilk" to "Dairy Products").
- 📊 Scientific Accuracy: Maps consumer goods to specific EEIO (Environmentally Extended Input-Output) industrial sectors.
- 🌲 Impact Visualization: Translates abstract CO2kg numbers into tangible metrics:
- Trees required to offset.
- Deforestation area (m²) caused.
- ⚡ Real-time Calculation: Optimized for speed using the
google_generative_aiDart SDK. - 👤 Guest Mode: Frictionless entry with Firebase Anonymous Auth.
EcoLens operates on a 3-step AI-Scientific pipeline:
The app sends the raw image to Gemini with a system instruction to act as an Environmental Economist. It performs OCR and cleans noisy data from thermal paper.
Instead of simple keyword matching, the AI classifies items based on semantic meaning into a fixed list of industrial sectors defined in our database.
- Input: "POCARI SWT 500"
- AI Inference: "Manufacture of beverages"
We calculate the Product Carbon Footprint (PCF) using the standard Spend-Based emission factor formula, adjusted for currency (IDR to EUR) and inflation (2019 baseline to Present Day).
- Frontend: Flutter (Dart)
- AI Model: Google Gemini 1.5 Flash
- Backend/Auth: Firebase Authentication
- State Management: Provider / Riverpod (Adjust based on your actual code)
- Networking: HTTP & Dio
- Data: JSON-based Emission Factors (EEIO Standards)
Follow these steps to run EcoLens locally.
- Flutter SDK installed.
- A Google Cloud Project with Gemini API enabled.
- A Firebase Project setup for Authentication.
-
Clone the repository
git clone [https://github.com/devoidco/ecolens.git](https://github.com/devoidco/ecolens.git) cd ecolens -
Install Dependencies
flutter pub get
-
Configure API Keys
- Create a file named
api_constants.dartinlib/core/constants/. - Add your API keys (Do not commit this file to Git!):
// lib/core/constants/api_constants.dart class ApiConstants { static const String geminiApiKey = "YOUR_GEMINI_API_KEY_HERE"; // Add other keys if necessary }
- Create a file named
-
Run the App
flutter run
| Home Screen | Scanning | Analysis Result | Impact View |
|---|---|---|---|
![]() |
![]() |
![]() |
![]() |
(Note: Please upload screenshots to an assets/screenshots folder in your repo to make these visible)
- Receipt OCR & Parsing
- AI Classification Logic
- Basic Carbon Calculation
- User History & Monthly Tracking
- Gamification (Green Score)
- Product Alternatives Suggestion
- Export Report to PDF
Distributed under the MIT License. See LICENSE for more information.
Built with ❤️ for the Planet using Flutter & Gemini.



