How coding-parrot/pothole-reporter works
Pothole Reporter is an Android road-damage reporting app backed by a privacy-minimised central service. A person captures a photo or imports footage, reviews a detected sighting and its location/authority/possible contract details, then opens an editable email draft; Drive Mode can sample road frames in the background. The service also accepts sightings, deduplicates them into canonical locations, and supports shared-map metrics. The excerpts establish selected Android and service wiring; other documented features are included with README evidence, without inferring unsampled call chains.
Main entry points: core.mjs Service logic · handler.mjs Service handler · DriveForegroundService.kt Drive session · MainActivity.kt Android app
Components 21
Android capture
- Android app
android-app/android/app/src/main/java/com/gauravsen/potholereporter/MainActivity.kt - Drive session
android-app/android/app/src/main/java/dev/aiengg/potholereporter/drive/DriveForegroundService.kt - Drive service
android-app/android/app/src/main/java/com/gauravsen/potholereporter/drivemode/DriveModeService.kt - Video import
android-app/android/app/src/main/java/com/gauravsen/potholereporter/bridge/VideoImportPlugin.kt - Central client
android-app/android/app/src/main/java/com/gauravsen/potholereporter/drivemode/CentralServiceClient.kt
Detection and evidence
- Frame quality
android-app/android/app/src/main/java/dev/aiengg/potholereporter/drive/FrameQualityEvaluator.kt - Inference engine
android-app/android/app/src/main/java/dev/aiengg/potholereporter/drive/NativeInferenceEngine.kt - Observation dedupe
android-app/android/app/src/main/java/dev/aiengg/potholereporter/drive/NativeDeduplicationEngine.kt - Evidence storage
android-app/android/app/src/main/java/dev/aiengg/potholereporter/drive/NativeReportEvidenceStorage.kt
Central service
- Service handler
infra/aws-central/service/handler.mjs - Service logic
infra/aws-central/service/core.mjs - Detector routing
infra/aws-central/service/detectors.mjs - Location lookup
infra/aws-central/service/geolocation.mjs - Tender matching
infra/aws-central/service/ward-tenders.mjs - Canonical map
infra/aws-central/service/core.mjs
Local and central data
- Local reports
android-app/android/app/src/main/java/dev/aiengg/potholereporter/db/PotholeDatabase.kt - Report records
android-app/android/app/src/main/java/com/gauravsen/potholereporter/db/entities/ReportEntity.kt - Central repository
infra/aws-central/service/dynamo-repository.mjs
Other components
- Road reporter
- Email app
- Vision provider
Connections 19
- Road reporter → Android app: captures or reviews
- Road reporter → Video import: imports clips
- Android app → Email app: opens draft
- Drive session → Frame quality: evaluates frames
android-app/android/app/src/main/java/dev/aiengg/potholereporter/drive/DriveForegroundService.kt - Drive session → Inference engine: requests analysis
android-app/android/app/src/main/java/dev/aiengg/potholereporter/drive/DriveForegroundService.kt - Drive service → Android app: reports status
android-app/android/app/src/main/java/com/gauravsen/potholereporter/drivemode/NotificationController.kt - Inference engine → Evidence storage: saves evidence
android-app/android/app/src/main/java/dev/aiengg/potholereporter/drive/NativeInferenceEngine.kt - Drive session → Observation dedupe: deduplicates sightings
android-app/android/app/src/main/java/dev/aiengg/potholereporter/drive/DriveForegroundService.kt - Observation dedupe → Local reports: writes reports
android-app/android/app/src/main/java/dev/aiengg/potholereporter/drive/NativeDeduplicationEngine.kt - Local reports → Report records: stores records
- Central client → Service handler: sends sightings
- Service handler → Service logic: configures service
infra/aws-central/service/handler.mjs - Service handler → Detector routing: configures detector
infra/aws-central/service/handler.mjs - Service handler → Location lookup: configures lookup
infra/aws-central/service/handler.mjs - Service logic → Central repository: uses persistence
- Service logic → Tender matching: matches contracts
- Service logic → Canonical map: serves map data
- Service logic → Vision provider: requests detection
- Road reporter → Canonical map: views locations