Skip to content

bonitoflakesorg/vazhikaatti

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

47 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Vazhikaatti 🌿

Navigate Smarter. Stay Safer.

(Please view in mobile view)

A community-driven safety map that helps you discover nearby hazards, report issues, and make informed travel decisions in real time.


πŸ—ΊοΈ Project Description

Vazhikaatti (Malayalam for "one who shows the way") is a community-powered public safety web platform that allows users to view real-time safety alerts around them, report local hazards, and plan safer routes based on crowd-sourced data. It acts as a live hyperlocal safety layer on top of city maps.

In cities, people face everyday risks β€” stray dogs, poor lighting, flooded roads, potholes β€” that are rarely reported officially in real time. Vazhikaatti bridges the gap between hazard occurrence and public awareness by turning every citizen into a safety contributor.

Think: Google Maps + Community Safety Alerts, focused purely on hyperlocal hazards and civic safety.


✨ Features

  • πŸ—ΊοΈ Live Hazard Map β€” Interactive map powered by Leaflet.js and OpenStreetMap showing community-reported hazard markers in real time
  • πŸ“ Report an Issue β€” Submit hazard reports with photo, description, category, severity, and GPS location
  • 🧭 Journey Mode β€” Plan routes from point A to B and see hazard markers along your path via OpenRouteService API
  • πŸ–ΌοΈ AI Image Validation β€” CLIP model (OpenAI) used for intelligent image validation of uploaded hazard photos
  • ✏️ My Reports β€” View, edit, and delete your own submitted reports with a swipeable card interface

πŸ› οΈ Tech Stack

Layer Technology
Frontend Next.js 14 (TypeScript)
Backend FastAPI (Python)
AI / ML CLIP Model (OpenAI)
Map Rendering Leaflet.js
Map Data OpenStreetMap
Routing OpenRouteService API
Auth Google OAuth
Deployment Vercel (frontend), Render (backend)

πŸ“Έ Screenshots

In SCREENSHOTS.md


πŸŽ₯ Demo Video

πŸ“Ή Watch Demo Video


πŸ—οΈ Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                   FRONTEND β€” Next.js 14 (TypeScript)             β”‚
β”‚                                                                  β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚
β”‚  β”‚  Map View   β”‚   β”‚ Report Form  β”‚   β”‚    Journey Mode       β”‚ β”‚
β”‚  β”‚ (Leaflet.js)β”‚   β”‚ (image +     β”‚   β”‚  (Route Planning UI)  β”‚ β”‚
β”‚  β”‚             β”‚   β”‚  metadata)   β”‚   β”‚                       β”‚ β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”˜   β””β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”˜   β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚
β”‚         β”‚                 β”‚                       β”‚              β”‚
β”‚         β–Ό                 β–Ό                       β–Ό              β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚
β”‚  β”‚OpenStreetMapβ”‚   β”‚   Supabase   β”‚   β”‚  OpenRouteService API β”‚ β”‚
β”‚  β”‚ (Map Tiles) β”‚   β”‚  JS Client   β”‚   β”‚  (Fetch 3 routes,     β”‚ β”‚
β”‚  β”‚             β”‚   β”‚              β”‚   β”‚   walking directions) β”‚ β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜   β””β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”˜   β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚
β”‚                           β”‚                                      β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                            β”‚  (Auth + DB reads + Image upload)
                            β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                           SUPABASE                               β”‚
β”‚                                                                  β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚
β”‚  β”‚  Auth        β”‚   β”‚  Database    β”‚   β”‚   Storage            β”‚ β”‚
β”‚  β”‚  (Google     β”‚   β”‚  (Reports    β”‚   β”‚   (Hazard images     β”‚ β”‚
β”‚  β”‚   OAuth)     β”‚   β”‚   + Users)   β”‚   β”‚    uploaded by users)β”‚ β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜   β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜   β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                            β”‚
          (Image URL sent to backend for validation)
                            β”‚
                            β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                    BACKEND β€” FastAPI (Python)                    β”‚
β”‚                                                                  β”‚
β”‚   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚
β”‚   β”‚                  CLIP Model (OpenAI)                       β”‚ β”‚
β”‚   β”‚                                                            β”‚ β”‚
β”‚   β”‚  β€’ Receives image URL from frontend                        β”‚ β”‚
β”‚   β”‚  β€’ Validates image matches reported category               β”‚ β”‚
β”‚   β”‚    e.g. "stray dog" photo <-> "Stray Dogs" category        β”‚ β”‚
β”‚   β”‚  β€’ Returns validation result -> frontend proceeds/rejects  β”‚ β”‚
β”‚   β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Data Flow β€” Submitting a Report

User submits report
      β”‚
      β”œβ”€ 1 ──▢ Image uploaded to Supabase Storage       (frontend)
      β”‚
      β”œβ”€ 2 ──▢ Image URL + category sent to FastAPI     (frontend β†’ backend)
      β”‚             └─▢ CLIP model validates image matches category
      β”‚             └─▢ Returns: { valid: true / false }
      β”‚
      β”œβ”€ 3 ──▢ If valid β†’ report saved to Supabase DB   (frontend)
      β”‚
      └─ 4 ──▢ Map refreshes with new hazard marker     (Leaflet.js)

πŸš€ Installation & Setup

Prerequisites

  • Node.js 18+
  • Python 3.10+
  • pip

Frontend (Next.js)

# Clone the repository
git clone https://github.com/bonitoflakesorg/vazhikaatti.git
cd vazhikaatti/client

# Install dependencies
npm install

# Set up environment variables
cp .env.example .env.local
# Add your keys to .env.local:
# NEXT_PUBLIC_API_URL=http://localhost:8000
# NEXT_PUBLIC_ORS_API_KEY=your_openrouteservice_key
# NEXT_PUBLIC_GOOGLE_CLIENT_ID=your_google_client_id

# Start the development server
npm run dev

Backend (FastAPI)

cd vazhikaatti/server

# Create and activate virtual environment
python -m venv venv
source venv/bin/activate        # macOS/Linux
venv\Scripts\activate           # Windows

# Install dependencies
pip install -r requirements.txt

# Set up environment variables
cp .env.example .env
# Add your keys to .env:
# DATABASE_URL=your_db_url
# GOOGLE_CLIENT_ID=your_google_client_id
# GOOGLE_CLIENT_SECRET=your_google_client_secret

# Start the backend server
uvicorn app.main:app --reload

▢️ Run Commands

# Frontend
cd client && npm run dev        # http://localhost:3000

# Backend
cd server && uvicorn app.main:app --reload   # http://localhost:8000

# API Docs (auto-generated by FastAPI)
# http://localhost:8000/docs

πŸ‘©β€πŸ’» Team Members

Name Role College
Mehrin Fathima Shamim Backend (FastAPI) + Auth Government Model Engineering College, Thrikkakara
Diya Jojo Frontend (Next.js) + Map Integration Government Model Engineering College, Thrikkakara

🎯 Target Audience

Daily commuters, students, women traveling alone, delivery drivers, elderly citizens, and urban residents who want safer, more informed travel.


🌍 Future Roadmap

  • AI-based hazard clustering and heatmaps
  • SMS alert system for high-severity zones
  • Government / NGO dashboard integration
  • Verified report badges
  • Predictive risk zones using historical data

πŸ“„ License

This project is licensed under the MIT License.


Made with ❀️ at TinkerHub β€” Tink-Her-Hack 4.0

Releases

Packages

Contributors

Languages