# anushkaa2306/rainfallpredictionsih2026- architecture

> Architecture diagram of the GitHub repository anushkaa2306/rainfallpredictionsih2026-, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-29). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/anushkaa2306/rainfallpredictionsih2026-
- Repository: https://github.com/anushkaa2306/rainfallpredictionsih2026-

## Overview

FloodWatch AI is a flood and monsoon-risk dashboard for monitoring hazards and supporting response decisions. The visible product areas cover rainfall, flood probability, inundation, road conditions, safe routes, and emergency services. The sampled code confirms the home route renders the dashboard and shows how emergency-service and flood-risk data are obtained; other feature wiring is not established by the excerpts, so those links are omitted.

Main entry points: [`src/routes/index.tsx`](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/routes/index.tsx) (Home route), [`src/features/emergency-response/EmergencyServices.tsx`](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/features/emergency-response/EmergencyServices.tsx) (Emergency services), [`src/hooks/useRiskPrediction.ts`](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/hooks/useRiskPrediction.ts) (Risk selector), [`src/hooks/useFloodScenario.ts`](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/hooks/useFloodScenario.ts) (Scenario selector)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Application"]
  node_home["Home route<br/>[index.tsx]"]
  node_dashboard["Dashboard<br/>[Dashboard.tsx]"]
end

subgraph group_hazards["Hazard intelligence"]
  node_flood["Flood risk"]
  node_rainfall["Rainfall outlook"]
  node_inundation["Inundation forecast"]
  node_map["Flood risk map<br/>[FloodRiskMap.tsx]"]
end

subgraph group_response["Response planning"]
  node_roads["Road intelligence"]
  node_routes["Safe routes"]
  node_emergency["Emergency services"]
  node_authority["Authority view<br/>[Authority.tsx]"]
end

subgraph group_data["Data access"]
  node_risk_hook["Risk selector"]
  node_scenario_hook["Scenario selector"]
  node_emergency_api["Emergency directory<br/>[emergencyApi.ts]"]
  node_prediction_api["Prediction data<br/>[predictionApi.ts]"]
  node_inundation_utils["Scenario data"]
  node_weather_api["Weather service<br/>[weatherApi.ts]"]
  node_route_api["Route service<br/>[routeApi.ts]"]
  node_demo_data["Demo datasets"]
end

node_user(("Dashboard user"))

node_user -->|"opens"| node_home
node_home -->|"renders"| node_dashboard
node_risk_hook -->|"loads zones"| node_prediction_api
node_scenario_hook -->|"gets scenario"| node_inundation_utils
node_emergency -->|"loads services"| node_emergency_api

click node_home "https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/routes/index.tsx"
click node_dashboard "https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/pages/Dashboard.tsx"
click node_flood "https://github.com/anushkaa2306/rainfallpredictionsih2026-/tree/main/src/features/flood-risk"
click node_rainfall "https://github.com/anushkaa2306/rainfallpredictionsih2026-/tree/main/src/features/rainfall"
click node_inundation "https://github.com/anushkaa2306/rainfallpredictionsih2026-/tree/main/src/features/inundation"
click node_map "https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/components/map/FloodRiskMap.tsx"
click node_roads "https://github.com/anushkaa2306/rainfallpredictionsih2026-/tree/main/src/features/road-intelligence"
click node_routes "https://github.com/anushkaa2306/rainfallpredictionsih2026-/tree/main/src/features/safe-routes"
click node_emergency "https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/features/emergency-response/EmergencyServices.tsx"
click node_authority "https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/pages/Authority.tsx"
click node_risk_hook "https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/hooks/useRiskPrediction.ts"
click node_scenario_hook "https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/hooks/useFloodScenario.ts"
click node_emergency_api "https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/services/emergencyApi.ts"
click node_prediction_api "https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/services/predictionApi.ts"
click node_inundation_utils "https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/features/inundation/inundation.utils.ts"
click node_weather_api "https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/services/weatherApi.ts"
click node_route_api "https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/services/routeApi.ts"
click node_demo_data "https://github.com/anushkaa2306/rainfallpredictionsih2026-/tree/main/src/data/demo"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_home,node_dashboard,node_user toneBlue
class node_flood,node_rainfall,node_inundation,node_map toneAmber
class node_roads,node_routes,node_emergency,node_authority toneMint
class node_risk_hook,node_scenario_hook,node_emergency_api,node_prediction_api,node_inundation_utils,node_weather_api,node_route_api,node_demo_data toneRose
```

## Components

### Application

- [Home route](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/routes/index.tsx): `src/routes/index.tsx`
- [Dashboard](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/pages/Dashboard.tsx): `src/pages/Dashboard.tsx`

### Hazard intelligence

- [Flood risk](https://github.com/anushkaa2306/rainfallpredictionsih2026-/tree/main/src/features/flood-risk): `src/features/flood-risk`
- [Rainfall outlook](https://github.com/anushkaa2306/rainfallpredictionsih2026-/tree/main/src/features/rainfall): `src/features/rainfall`
- [Inundation forecast](https://github.com/anushkaa2306/rainfallpredictionsih2026-/tree/main/src/features/inundation): `src/features/inundation`
- [Flood risk map](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/components/map/FloodRiskMap.tsx): `src/components/map/FloodRiskMap.tsx`

### Response planning

- [Road intelligence](https://github.com/anushkaa2306/rainfallpredictionsih2026-/tree/main/src/features/road-intelligence): `src/features/road-intelligence`
- [Safe routes](https://github.com/anushkaa2306/rainfallpredictionsih2026-/tree/main/src/features/safe-routes): `src/features/safe-routes`
- [Emergency services](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/features/emergency-response/EmergencyServices.tsx): `src/features/emergency-response/EmergencyServices.tsx`
- [Authority view](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/pages/Authority.tsx): `src/pages/Authority.tsx`

### Data access

- [Risk selector](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/hooks/useRiskPrediction.ts): `src/hooks/useRiskPrediction.ts`
- [Scenario selector](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/hooks/useFloodScenario.ts): `src/hooks/useFloodScenario.ts`
- [Emergency directory](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/services/emergencyApi.ts): `src/services/emergencyApi.ts`
- [Prediction data](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/services/predictionApi.ts): `src/services/predictionApi.ts`
- [Scenario data](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/features/inundation/inundation.utils.ts): `src/features/inundation/inundation.utils.ts`
- [Weather service](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/services/weatherApi.ts): `src/services/weatherApi.ts`
- [Route service](https://github.com/anushkaa2306/rainfallpredictionsih2026-/blob/main/src/services/routeApi.ts): `src/services/routeApi.ts`
- [Demo datasets](https://github.com/anushkaa2306/rainfallpredictionsih2026-/tree/main/src/data/demo): `src/data/demo`

### Other components

- **Dashboard user**

## Connections

- Dashboard user → Home route: opens
- Home route → Dashboard: renders
- Risk selector → Prediction data: loads zones
- Scenario selector → Scenario data: gets scenario
- Emergency services → Emergency directory: loads services
