FloodGuard (accepted for Coding Fest)
FloodGuard is a reliability-aware flood-awareness and decision-support prototype for the Parramatta pilot area set: Parramatta, North Parramatta, and Toongabbie. The system eliminates data fragmentation by translating rainfall, river, weather, warning-context, and public-signal evidence into an explainable local concern summary. Rather than leaving residents to compare multiple technical feeds manually, it empowers communities to react swiftly to emergent situations by clearly communicating what is happening, why it matters, and what next steps to take.
FloodGuard is not an official emergency-warning system. Official warnings are shown separately from FloodGuard-generated local concern, the live rule engine remains the active authority inside the prototype, and ML remains shadow mode only.
FloodGuard was accepted for showcase at Coding Fest 2026, a competition opened to all university students. FloodGuard's poster was selected for final judging and showcase presentation.
Its main technical contribution is the reliability layer. FloodGuard does not treat every source as equally trustworthy: it tracks freshness, provenance, fallback/cache state, official-warning separation, and degraded evidence before those signals are allowed to shape the visible concern summary or notification candidates.
| Area | What FloodGuard implements |
|---|---|
| Ingestion | Rainfall, river, weather, warning-context, and resident/public-signal ingestion |
| Reliability | Freshness checks, provenance, fallback/cache labelling, stale/missing/unavailable states |
| Risk logic | Explainable rule-based concern scoring with decision audit output |
| Notifications | Conservative suppression when degraded core evidence makes stronger advice unsafe |
| History | Queryable JSONL snapshots, replay summaries, decision-audit storage, and ML-ready feature export |
| ML | Python shadow pipeline, baseline models, scenario stress-test data, label audit, and model-card reporting |
| Testing | Backend regression tests, ingestion honesty checks, API contracts, replay coverage, and Playwright smoke flows |
- Multi-area dashboard for Parramatta, North Parramatta, and Toongabbie
- Live or fallback ingestion paths for rainfall, river, and weather context
- Layered ingestion health with
coreFloodStatus,contextStatus,warningStatus, andoverallStatus - Source provenance and freshness reporting
- Explainable rule-based risk scoring with decision audit output
- Public community-signal intake with validation, rate limiting, duplicate checks, and review-safe image-link handling
- Image-assisted evidence review queue for linked community-report media
- Historical snapshot storage and tabular feature export
- Replay summaries, compact
decisionSummaryoutputs, and queryable review windows - Notification decision logic with suppression and degraded-data safeguards
- Python ML prototype pipeline for offline training, evaluation, metrics, and model-card reporting
- Shadow-mode ML comparison surfaced in the backend and dashboard without overriding the live rule engine
- Scenario stress-test mode that demonstrates stronger synthetic flood pressure without pretending it is live
- Deterministic Playwright dashboard smoke tests plus replay and failure-injection regression coverage
FloodGuard is not just a visual flood dashboard. It is a reliability-aware decision layer that checks whether evidence is live, stale, cached, fallback-based, missing, or unavailable before allowing it to influence user-facing concern levels or notification decisions.
That matters because high-stakes software should not only produce a status label; it should also make the quality, limits, and trustworthiness of its evidence visible before people act on it.
- floodguard-frontend: React dashboard and Node ingestion/API layer
- floodguard-ml: Python ML experimentation workspace
- docs: public screenshots and diagram assets used to present FloodGuard
- explanation.md: beginner-friendly guide to FloodGuard's framework, logic, reliability model, and ML boundaries
- Public source adapters fetch rainfall, river, weather, and warning context when available.
- Source metadata records freshness, mode, strength, and fallback/degraded state.
- Area mapping and lightweight spatial relevance select the best local context for each pilot suburb.
- The rule engine combines rainfall, river, wetness, confidence, and public-signal pressure into an explainable concern score.
- The dashboard presents current concern, trust state, why the concern was assigned, and recommended next steps.
- Historical snapshots are exported into feature rows for offline Python ML experiments.
- A scenario stress-test mode can demonstrate stronger synthetic flood pressure without confusing it with the live area state.
- ML results are shown in shadow mode only and do not control live alerts.
FloodGuard is designed to avoid a common prototype failure mode: looking โliveโ even when sources are stale, missing, or fallback-only.
The app checks:
- whether rainfall and river gauges are current enough for a live claim
- whether supporting context is stale or partial
- whether official warnings are live, stale, unavailable, or still missing
- whether recent cache is being reused because a live refresh failed
This means the dashboard can say โblockedโ, โpartialโ, or โfallbackโ instead of silently pretending the data is current.
FloodGuard includes a Python-based prototype ML pipeline that:
- loads exported FloodGuard feature rows
- runs baseline models such as majority baseline, logistic regression, and random forest
- produces metrics and model-card reporting
- compares ML outputs against rule-derived labels in shadow mode
Current ML limitations:
- current historical labels are rule-derived rather than independent flood outcomes
- the real export is severely imbalanced
- there are no real
Highexamples in the current dataset - thresholds remain prototype-calibration pending and still need reviewed event evidence plus domain review
- ML is implemented for plumbing, safeguards, and comparison, not validated operational prediction
FloodGuard does not replace NSW SES, Bureau of Meteorology, council, or emergency-service advice. The project currently provides local flood-awareness support by combining public signals with reliability checks and explainable risk logic.
Because flood-risk guidance is high stakes, future versions require expert review of:
- rainfall thresholds and river-signal calibration
- next-step wording and notification safety
- when degraded evidence should suppress stronger guidance
- ML labels, validation strategy, and operational boundaries
FloodGuard therefore keeps:
- official warnings separate from FloodGuard-generated concern
- stale and cached data labelled explicitly
- strong app-generated alerts suppressed when core evidence is degraded
- ML in shadow mode rather than operational use
FloodGuard includes checks for:
- backend ingestion behaviour and source-health contracts
- stale/cache/fallback honesty under degraded-source conditions
- frontend production build correctness
- dashboard smoke testing across core views and area switching
- ML report and API contract stability
- replay summary and event-window review contract stability
- strict live-source readiness when genuinely current data is available
- Official NSW SES / HazardWatch integration is now connected through a default public HazardWatch adapter, but it is not yet mature enough to count as a stable live operational warning feed in every run.
- Core live-gauge ingestion can degrade to stale cache or fallback depending on source availability.
- Historical storage is currently JSONL-based prototype storage, not production-grade event storage.
- Risk thresholds are heuristic and not yet calibrated against validated flood outcomes.
- The ML layer remains shadow mode until stronger labels and broader validation exist.
- Future deployment requires hydrologist, council, and emergency-management review before any operational safety use.
- Node.js 20.19+ or 22.12+
- npm
- Python 3.11+ for the
floodguard-mlworkspace
cd floodguard-frontend
npm install
npm run demoThen open http://127.0.0.1:4173/.
npm run demo is the easiest end-to-end command for manual review because it refreshes one ingestion snapshot, starts the Node API, and starts the frontend with the correct local API wiring. The commands below remain available if you want to run components manually.
cd floodguard-frontend
npm install
npm run devcd floodguard-frontend
npm run apicd floodguard-frontend
npm run test
npm run build
npm run check:ingestionFor the current prototype, npm run check:ingestion is the camera-ready honesty gate. It passes when degraded, stale, cached, unavailable, or partially connected sources are labelled safely rather than misrepresented as live. npm run check:ingestion:live is stricter and should only pass when rainfall, river, and supporting live context are genuinely current.
cd floodguard-frontend
npm run ingestcd floodguard-frontend
npm run collect:sourcescd floodguard-frontend
npm run check:ingestioncd floodguard-frontend
npm run testcd floodguard-frontend
npm run test:e2ecd floodguard-frontend
npm run build- Select a pilot area.
- Inspect the current concern level and key concern drivers.
- Check source-health and evidence reliability to see whether the signals are live, stale, cached, fallback, or unavailable.
- Review the decision audit and rainfall/river context to understand why the concern level was assigned.
- Inspect notifications and public signals to see how FloodGuard behaves under stronger or degraded evidence.
- Review the ML shadow output, noting that it is comparison-only and does not control live alerts.
GET /api/healthGET /api/areasGET /api/signals?area=parramattaGET /api/source-registry?area=parramattaGET /api/source-health?area=parramattaGET /api/ingestion-readinessGET /api/decision-audit?area=parramattaGET /api/community-reports?area=parramattaPOST /api/community-reportsGET /api/evidence-review?area=parramattaGET /api/history?area=parramattaGET /api/features?area=parramattaGET /api/dataset-quality?area=parramattaGET /api/baseline-prediction?area=parramattaGET /api/model-experiment?area=parramattaGET /api/model-card?area=parramattaGET /api/ml/reportGET /api/notifications?area=parramattaGET /api/spatial-relevance?area=parramatta
FloodGuard's internal submission-writing notes, poster drafts, verification logs, and planning documents are kept as private working material and are not part of the public repo surface.
The public repo keeps the implementation, screenshots, diagrams, roadmap, and beginner-facing explanation that are most useful for reviewers, judges, and future collaborators.
FloodGuard now separates:
- submission readiness, where degraded external sources are acceptable if they are labelled honestly
- strict live-source readiness, where rainfall and river must be genuinely fresh live readings
This is why a stale-source run can still demonstrate a successful trust layer even when strict live operation is not currently available.
- Breiman, L. (2001). Random forests. Machine Learning, 45(1), 5-32. https://doi.org/10.1023/A:1010933404324
- Bureau of Meteorology. (n.d.). New South Wales rain and river data. Retrieved July 7, 2026, from https://www.bom.gov.au/nsw/flood/rain_river.shtml
- City of Parramatta. (n.d.). Check your river and rain gauge levels. Retrieved July 7, 2026, from https://www.cityofparramatta.nsw.gov.au/environment/flooding-and-emergencies/floodsmart-parramatta/check-your-river-and-rain-gauge-levels
- City of Parramatta FloodSmart. (n.d.). Lizard measuring stations API [Data set]. Retrieved July 7, 2026, from https://parramatta.lizard.net/api/v4/measuringstations/
- Cox, D. R. (1958). The regression analysis of binary sequences. Journal of the Royal Statistical Society: Series B (Methodological), 20(2), 215-242.
- Data.NSW. (n.d.). Hazard Watch [Data set]. Retrieved July 7, 2026, from https://data.nsw.gov.au/data/dataset/hazard-watch
- Geurts, P., Ernst, D., & Wehenkel, L. (2006). Extremely randomized trees. Machine Learning, 63(1), 3-42. https://doi.org/10.1007/s10994-006-6226-1
- HazardWatch. (n.d.). HazardWatch. Retrieved July 7, 2026, from https://www.hazardwatch.gov.au/
- NSW Flood Data Portal. (n.d.). NSW Flood Data Portal. Retrieved July 7, 2026, from https://flooddata.ses.nsw.gov.au/
- NSW State Emergency Service. (n.d.). Understand warning levels. Retrieved July 7, 2026, from https://www.ses.nsw.gov.au/understand-warnings
