For Earth Day 2026, I built EcoSense AI — an app that analyzes your carbon footprint in 60 seconds using AI.
The Idea
Most carbon calculators are boring forms with static math. I wanted something that feels quick, uses AI for nuanced analysis, and gives actionable tips.
Architecture
User -> 4-Step Form -> /api/generate (Cloudflare Function)
|
Google Gemini 2.0 Flash
|
JSON: score, grade, tips, pledge
|
/api/memory (Backboard) -> saves results
Solana donation -> carbon offset
The Prompt Engineering
Gemini returns structured JSON reliably if you're specific. Temperature 0.7 gives the best balance of variety and accuracy.
Persistent Memory with Backboard
Each assessment gets saved to a Backboard thread. Returning users see their progress over time.
Carbon Offsets via Solana
Solana is Proof of Stake — 99.9% less energy than Bitcoin. Perfect for an eco app.
Try It
x-tahosin
/
ecosense-ai
AI Carbon Footprint Analyzer - Google Gemini + Backboard + Solana | Earth Day 2026
What It Does
Answer 4 quick questions about your daily habits and Google Gemini analyzes your carbon footprint in real-time:
- Eco Score (0-100) with letter grade and SVG donut chart
- Estimated annual CO2 compared to global average
- Impact breakdown by category (transport, diet, energy, shopping)
- 5 personalized tips to reduce your footprint
- Earth Day pledge — copy and share on social media
- Carbon offset — donate SOL via Solana to plant trees
- Progress tracking — Backboard memory saves your assessments
Architecture
Browser → Static HTML/JS (Cloudflare Pages)
↓
/api/generate → Cloudflare Function → Google Gemini API
/api/memory → Cloudflare Function → Backboard API
API keys NEVER reach the browser.
Tech Stack
| Technology | Purpose |
|---|---|
| Next.js 16 | Static export frontend |
| Google Gemini 2.0 Flash | AI analysis engine |
| Backboard | Persistent memory threads |
| Solana | Carbon offset donations |
| Cloudflare Pages | Hosting + serverless functions |
Happy Earth Day! What are you building for the planet?
Top comments (0)