Inspiration

The idea struck while I was out on a walk and noticed several vehicles repeatedly hitting the same pothole. It made me think — what if our phones could automatically detect and report these hazards in real time? That’s when I decided to build a system that uses motion sensors, AI, and community data to make roads safer for everyone.

What it does

GPHS – Global Pot Hole System is a mobile app that detects potholes using a smartphone's motion sensors (accelerometer and gyroscope). It buffers and sends the data to an AI model (via Gemini API) to confirm whether it's an actual pothole. Once verified (or unverified), the location is uploaded to a Supabase backend and displayed on a real-time map for the entire community to see.

Markers are color-coded for clarity:

  • 🟠 Orange – Detection in progress
  • 🟡 Yellow – Unconfirmed
  • 🔴 Red – Confirmed pothole

The system helps cities, bikers, and daily commuters spot and avoid hazardous roads while crowdsourcing road safety data.

How we built it

-React Native (with Expo) – for building the cross-platform mobile app

  • Expo Sensors API– to access real-time accelerometer and gyroscope data
  • Gemini API – to analyze buffered motion data and confirm potholes
  • Supabase– to store and fetch community pothole reports
  • React Native Maps – to render the live map with dynamic markers

Challenges we ran into

-Buffering logic: Capturing the right motion window before, during, and after the spike took fine-tuning.

  • AI integration: Designing the payload and handling async verification from the Gemini API.
  • Map marker shifting: Some initial issues with marker locations during zoom interactions.

Accomplishments that we're proud of

  • Built a working AI-powered pothole detection pipeline in just 36 hours.
  • Created a smooth UI/UX for both detection and map-based reporting.
  • Successfully integrated Supabase for realtime, multi-user map syncing.
  • Kept the app lightweight, battery-friendly, and completely functional on mobile.
  • Solved a real-world problem using only accessible hardware (a smartphone!).

What we learned

  • Working with real-time sensors and motion data in React Native.
  • Fine-tuning thresholds and buffers to improve AI input quality.
  • Handling asynchronous AI verification workflows.
  • Structuring a full-stack mobile app with local AI + cloud backend.

What's next for GPHS - Global Pot Hole System

  • Improve AI model using real-world training data (via Gemini or Gemini Pro).
  • Add user voting/upvoting for community-confirmed potholes.
  • Partner with local civic bodies or smart city teams to pilot test.
  • Publish the app on Google Play & App Store.
  • 🔁Auto-refresh + clustering for heavy pothole areas on the map.

Built With

Share this project:

Updates