Inspiration

Every winter, Punjab, Pakistan becomes the most air-polluted region on Earth. Air Quality Index (AQI) readings climb past 1,900 — the highest ever recorded anywhere. We watched the same broken cycle repeat year after year: schools close hours after children have already breathed toxic air, hospitals overflow without warning, and over 200,000 gig-delivery riders work outdoors all day with zero exposure guidance. A single generic alert gets sent to a healthy 25-year-old and a 65-year-old with COPD alike.

The most frustrating part? The data already exists. Live sensors, satellite fire detection, and wind data are all out there — they're just never fused, predicted, or turned into a decision in time. We built AuraVa to close that gap: not another AQI dashboard, but a system that tells you what to do, before you need to ask.

What it does

AuraVa is a real-time, AI-powered smog crisis companion that turns raw air-quality data into clear, personalized decisions:

  • Live AQI Dashboard — current AQI, a 6-hour AI forecast, real weather, and live source breakdown for any city, with every value tagged "Live" or "Estimate" so users always know what they're seeing.
  • Real Interactive World Map — a live Leaflet map with real monitoring-station markers worldwide, zoom/pan, and search for any city on Earth (not a fixed list).
  • AI Predictions (6 / 12 / 24h) — forecasts the next AQI trajectory from fire data, wind, and live sensors, with a confidence score and source transparency.
  • AI Health Advisory (bilingual) — situation-specific guidance generated live from the actual AQI and pollutant level, personalized to six health profiles (asthma, COPD, pregnant, elderly, child, healthy adult), in English and Urdu.
  • School Safety Meter — answers the question every parent asks each morning with one glance: 🟢 safe, 🟡 caution, or 🔴 unsafe to send children to school.
  • Safe Routes for Riders — computes a real route between two points and measures air quality along the entire path, so delivery riders breathe less.
  • November 2024 Crisis Replay — replays the real Lahore crisis (AQI 350 → 1,900) so every feature can be demonstrated even on a clean-air day.

How we built it

AuraVa is a full-stack application:

  • Frontend: Next.js 16 (App Router) + React 19 + TypeScript, styled with Tailwind CSS, a real Leaflet map, and Recharts for forecasts.
  • Backend: Node.js + Express 5, with a signal-fusion engine that combines AQI, upwind fire counts, wind vectors, and news into one bundle.
  • AI: Google Gemini 2.5 Flash generates forecasts, health advisories, and school-safety decisions; Groq (Llama 3.3 70B) handles fast English→Urdu translation.
  • Database: PostgreSQL stores users, readings, and forecasts.
  • Auth: real email/password authentication with bcrypt + JWT, fully isolated per-user data.
  • Data sources: WAQI (live AQI + global station search), OpenAQ, NASA FIRMS (fires), Open-Meteo (wind/weather), OpenStreetMap (geocoding), NewsAPI, and OpenRouteService (routing).
  • Deployment: Dockerized (Postgres + backend + frontend via Docker Compose).

A core design principle is real-first, honest fallback: AuraVa always tries the real API first, and if an upstream is rate-limited or down, it falls back to a clearly-labeled estimate with an "Estimate" badge — it never shows fake data as if it were live.

What we learned

  • Pakistan's smog is a data-delivery problem, not a data problem. The hardest part wasn't getting data — it was fusing it and turning it into a decision a parent or rider can act on instantly.
  • AI advisories for regional languages need explicit domain context. Passing the live AQI, the pollutant load, and the specific health condition into the prompt produced dramatically safer, more specific advice than a generic prompt.
  • Honesty beats faking it. Labeling data as "Live" vs "Estimate" made the product more trustworthy, not less — and forced cleaner architecture.
  • Building for one specific crisis produced a far more compelling product than a generic air-quality app.

Challenges we ran into

  • No free API returns "AQI along a route." We had to compute it ourselves by sampling air quality at multiple points along the real routing polyline and averaging them.
  • Free AI quotas (Gemini's 20 requests/day) get exhausted fast. Instead of letting pages break, we built the labeled-fallback system so the app stays usable while staying honest.
  • It's May — Lahore's air is currently clean. A live demo would look boring, so we built the November 2024 crisis replay to show the system responding to the worst air event ever recorded.
  • Removing every mock and faking nothing meant a real auth system, real per-user isolation, a real interactive map, and global city search — all of which we verified end-to-end.

What's next for AuraVa

  • WhatsApp alerts — opt-in morning smog briefings on the platform everyone in Pakistan actually uses.
  • Multi-city + cross-border — Multan, Faisalabad, Karachi, and Delhi/Dhaka, since it's a shared South Asian crisis.
  • B2B portals — automated daily briefings for school districts and respiratory-bed planning for hospitals.
  • Historical predictions — as the database accumulates readings, forecasts will be trained on real local history.

Built With

Share this project:

Updates