BILAHUJAN VHack2026
BILAHUJAN — AI-powered flood detection | V Hack 2026 @ USM
Install / Use
/learn @HowardWoon/BILAHUJAN VHack2026Quality Score
Category
Development & EngineeringSupported Platforms
README
Decentralised Swarm Intelligence for Flood First Response
<br>"Every citizen a sensor. Every report a node. Every second counts."
<br>🔴 TEST THE LIVE PLATFORM → bilahujan-vhack.web.app
Built for V Hack 2026 · Universiti Sains Malaysia · Case Study 3: First Responder of the Future
Powered by Google Gemini 2.5 Flash · Firebase Realtime Database · MCP Architecture · Google Maps Platform · Manus Agentic AI · GitHub Copilot
<br>📊 Platform At A Glance
| Metric | Value | |:---|:---| | 🗺️ Pre-seeded Flood Zones | 37 zones across all 16 states | | 🤖 MCP Tools in Agent Registry | 7 standardised tools | | 🧠 AI Pipeline Passes per Image | 12 sequential passes | | 🌐 Malaysian States Covered | All 16 + 3 Federal Territories (KL, Putrajaya, Labuan) | | 🏙️ Towns Pre-seeded for Monitoring | 150+ towns across all states | | 🐝 Swarm Node Status | Live citizen nodes — active / idle / offline | | ☁️ Firebase Plan | Spark (Free Tier) — RM 0/month at MVP | | 🤝 Agentic AI Partner | Manus (from Meta) — Pro Credits powering the Command Agent | | 💻 AI-Assisted Development | GitHub Copilot — via GitHub Student Developer Pack |
<br> </div>1) Repository Overview & Team Introduction
BILAHUJAN is a deployed civic intelligence platform built for V Hack 2026 under Case Study 3: First Responder of the Future — Decentralised Swarm Intelligence. It directly addresses the core challenge of the case study: building a self-healing, autonomous response system that operates as a collective brain at the edge — functioning even when centralised infrastructure fails.
Rather than relying on a single data source or central server, BILAHUJAN reframes the entire civilian population as a distributed sensor fleet. Every flood report submitted by a citizen automatically becomes an active intelligence node in the swarm. The Autonomous Command Agent — powered by Google Gemini and a standardised Model Context Protocol (MCP) tool layer, with agentic workflow augmentation via Manus (from Meta) — orchestrates this fleet autonomously, planning missions, executing tool calls, and dispatching alerts to Malaysian authorities (JPS, NADMA, APM) with zero human intervention.
This project is designed not as a hackathon demo, but as a deployable civic infrastructure prototype — built to the standards of a production system.
👥 Meet the Team
| Name | Role | |:---|:---| | Howard Woon Hao Zhe | Lead Software Engineer & AI Integrator — full technical build, Gemini multi-pass pipeline, MCP tool registry, Command Agent, Firebase architecture, Google Maps integration | | Sanjay Mukojima Ravindran | Front-End Engineer & UX Architect — UI design execution, mobile-first layout, human-centred design for high-stress use conditions | | Wong En Sheng | Marketing Lead & Pitching Strategist — pitching materials, public-facing narrative, SDG impact framing | | Ng Tze Fhung | Technical Documentation Lead & Presentation Designer — system documentation, judge-facing slides, written and visual deliverables |
2) Problem Statement
| Statistic | Figure | |:---|:---| | 💸 Annual economic loss from flooding | RM 1–5 billion/year | | 👥 Malaysians displaced annually | 200,000+ | | 🌊 Dec 2021 Klang Valley megaflood | 70,000+ displaced · RM 6.1B damage | | ⏱️ Response gap from poor data | 30–120 minutes | | 📡 National flood warning system | Still relies on manual water gauge monitoring |
The December 2021 Klang Valley flood was Malaysia's most devastating in a generation — yet coordinated digital reporting and real-time AI triage were largely absent. BILAHUJAN is built to close that gap.
During rapid-onset flash floods, emergency response systems suffer from four structural failures:
| Failure | Description | |:---|:---| | Communication Blackout | Cell towers and internet fail in the critical first 72 hours | | Centralised Single Points of Failure | Standard platforms collapse when infrastructure collapses | | Subjective Severity Reporting | Civilians misjudge danger levels due to panic or shock | | Fragmented Data Sources | JPS, MetMalaysia, NADMA, and social media are never unified |
The BILAHUJAN Approach:
CASE STUDY 3 REQUIREMENT BILAHUJAN IMPLEMENTATION
────────────────────── ────────────────────────
Fleet of rescue drones → Citizen sensor nodes (smartphones)
Disaster zone mapping → 37 Malaysian flood zones + live reports
Thermal signature scan → Gemini 2.5 Flash 12-pass image analysis
MCP tool calls → 7 standardised tools in mcpTools.ts
Command Agent orchestrator → runMission() autonomous agent loop
Chain-of-Thought reasoning → Live terminal in GOV dashboard
Edge operation (offline-ready) → Firebase RTDB + hardcoded 16-state fallback
3) Tech Stack Proof — Firebase Live Data
The following screenshots prove real Firebase Realtime Database usage — not mocked data.
Firebase Console — Realtime Database (liveZones)
Live liveZones/ with real citizen-uploaded severity scores
Firebase Console — liveReports
Real citizen flood reports with reportId, state, locationName, severity
Firebase Console — missionLogs
Autonomous agent mission logs with chain-of-thought steps
Firebase Console — agentAlerts
Authority alerts dispatched by Command Agent to JPS/NADMA/APM
Firebase Console — systemHeartbeat
24/7 system health monitoring — 60-second intervals
Firebase Hosting — Live Deployment
bilahujan-vhack.web.app — active deployment on Firebase Spark plan
4) System Architecture
┌─────────────────────────────────────────────────────────────────────────┐
│ BILAHUJAN Swarm Architecture │
│ │
│ ┌──────────────────────────────────────────────────────────────────┐ │
│ │ Autonomous Command Agent (Gemini 2.0 Flash) │ │
│ │ Phase 1: Mission Planning (Chain-of-Thought) │ │
│ │ Phase 2: MCP Tool Execution (7 tools · 800ms inter-step) │ │
│ │ Phase 3: Mission Summary + Firebase Persistence │ │
│ └──────────────────┬───────────────────────────────────────────────┘ │
│ │ Model Context Protocol (MCP) │
│ ┌──────────────┼──────────────────────┐ │
│ │ │ │ │
│ scan_flood_zone get_zone_status update_zone_severity │
│ get_active_nodes dispatch_alert get_system_health │
│ thermal_scan (Haversine geo) │
│ │
│ ┌──────────────────────────────────────────────────────────────────┐ │
│ │ Decentralised Citizen Swarm Network │ │
│ │ NODE-001 ◉ NODE-002 ◉ NODE-003 ◎ NODE-004 ○ NODE-N ◉ │ │
│ │ (Every flood report = an active intelligence node) │ │
│ └──────────────────────────────────────────────────────────────────┘ │
│ │
│ ┌─────────────────┐ ┌──────────────────────┐ ┌──────────────────┐ │
│ │ Firebase RTDB │ │ Gemini 2.5 Flash │ │ Google Maps API │ │
│ │ (live state) │ │ (12-pass pipeline) │ │ (37 zones) │ │
│ └─────────────────┘ └──────────────────────┘ └──────────────────┘ │
└─────────────────────────────────────────────────────────────────────────┘
5) Full Data Pipeline — Citizen to Authority
| Step | What Happens |
|:---:|:---|
| 1 | Citizen opens BILAHUJAN → searches location or uses GPS on MapScreen |
| 2 | SelectedLocation object created — passed through MapScreen → CameraScreen → ResultScreen |
| 3 | CameraScreen / ReportScreen captures photo → analyzeFloodImage() triggers 12-pass Gemini pipeline |
| 4 | ResultScreen displays: severity score, depth, passability per vehicle type, AI directive |
| 5 | "Upload to Alert Zone" → writes to liveZones/ with real Gemini score (never hardcoded) |
| 6 | Location normalized to "Town, State" via normalizeToTownState() before Firebase write |
| 7 | AlertsScreen auto-updates via Firebase onValue() listener — no polling, no setInterval |
| 8 | Command Agent detects new node via get_active_nodes MCP tool |
| 9 | Agent: scan_flood_zone → update_zone_severity → dispatch_alert |
| 10 | agentAlerts/{zoneId} written → JPS / NADMA / APM not
