# devgupta0910/disasterguard architecture

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

- Interactive diagram: https://gitdiagram.com/devgupta0910/disasterguard
- Repository: https://github.com/devgupta0910/disasterguard

## Overview

1. This repository is a React + TypeScript + Vite single-page application for emergency/disaster assistance. The app is designed to work in a mobile-style, field-use flow: capture evidence, run analysis, show guidance, and persist results for later review.

2. The UI is organized around a shared app shell in `src/components/layout` (`Header`, `BottomNav`, `AppShell`) and route-like pages in `src/pages` (`HomePage`, `OnboardingPage`, `HistoryPage`, `SettingsPage`). This suggests a tabbed/mobile navigation model rather than a multi-page server-rendered app.

3. The core product logic is split into feature domains:
   - `firstaid` for first-aid scanning and results,
   - `hazard` for safe-passage / hazard assessment,
   - `structure` for structure scan and result review,
   - `water` for water safety checks,
   - `family` for matching and mesh-based family coordination.
   Each domain has its own scan/check component plus a result component, which makes the architecture highly workflow-oriented.

4. Shared UI primitives in `src/components/shared` handle common interactions and presentation: camera capture, voice input, loading states, checklist items, guidance cards, and severity badges. These components are reused across the analysis workflows to keep the feature modules thin and consistent.

5. The input layer is browser/device driven. Hooks in `src/hooks` wrap camera access, geolocation, offline detection, and voice support (`useCamera`, `useGeolocation`, `useOffline`, `useVoice`). These hooks feed the feature workflows with sensor data and ambient context, especially for scan-based assessment and location-aware guidance.

6. Analysis appears to be AI-assisted and prompt-driven. `src/lib/prompts/*` contains task-specific prompts for each domain, while `src/lib/model-router.ts` and `src/lib/gemma.ts` suggest a routing layer that selects or invokes a model backend. Supporting utilities like `imageUtils.ts` and `geo.ts` likely preprocess visual and location inputs before analysis.

7. The app is built to function offline or in poor connectivity conditions. `src/lib/db.ts` provides local persistence, and `src/lib/offline-queue.ts` indicates queued work when network/model access is unavailable. The `HistoryPage` likely reads from this local store to show past assessments and outcomes.

8. There is a separate mesh/family coordination subsystem. `src/context/MeshContext.tsx`, `src/lib/mesh.ts`, `src/lib/mesh-relay.ts`, `src/lib/family-matching.ts`, and `src/components/family/*` indicate peer/device coordination for locating or matching family members, with `server/relay.ts` acting as the only explicit backend service in the tree.

9. Global app state is split between `AppContext` for general application state and `MeshContext` for mesh/network state. This keeps standard UI/navigation state separate from cross-device coordination and makes the architecture easier to diagram as two state domains.

10. The project is intentionally frontend-heavy and lightweight on infrastructure: Vite, React, TypeScript, ESLint, and a small TS relay server. Static assets live under `public/`, while `server/relay.ts` is the main non-browser component, likely supporting real-time or relay-based messaging for the mesh feature.

Main entry points: [`src/components/layout/AppShell.tsx`](https://github.com/devgupta0910/disasterguard/blob/main/src/components/layout/AppShell.tsx) (App shell), [`src/lib/model-router.ts`](https://github.com/devgupta0910/disasterguard/blob/main/src/lib/model-router.ts) (Model router), [`src/pages/HomePage.tsx`](https://github.com/devgupta0910/disasterguard/blob/main/src/pages/HomePage.tsx) (Home), [`src/components/family/FamilyMesh.tsx`](https://github.com/devgupta0910/disasterguard/blob/main/src/components/family/FamilyMesh.tsx) (Family mesh)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_group_ui["UI shell"]
  node_node_app["App<br/>spa entry<br/>[App.tsx]"]
  node_node_shell["App shell<br/>layout<br/>[AppShell.tsx]"]
  node_node_header["Header<br/>layout<br/>[Header.tsx]"]
  node_node_nav["Bottom nav<br/>layout<br/>[BottomNav.tsx]"]
  node_node_home["Home<br/>page<br/>[HomePage.tsx]"]
  node_node_onboarding["Onboarding<br/>page<br/>[OnboardingPage.tsx]"]
  node_node_history["History<br/>page<br/>[HistoryPage.tsx]"]
  node_node_settings["Settings<br/>page<br/>[SettingsPage.tsx]"]
end

subgraph group_group_features["Assessment flows"]
  node_node_firstaid["First aid<br/>workflow<br/>[FirstAidScan.tsx]"]
  node_node_firstaid_result["Aid result<br/>result view<br/>[FirstAidResult.tsx]"]
  node_node_hazard["Hazard check<br/>workflow<br/>[SafePassage.tsx]"]
  node_node_hazard_result["Hazard result<br/>result view<br/>[HazardResult.tsx]"]
  node_node_structure["Structure scan<br/>workflow<br/>[StructureScan.tsx]"]
  node_node_structure_result["Structure result<br/>result view"]
  node_node_water["Water check<br/>workflow<br/>[WaterCheck.tsx]"]
  node_node_water_result["Water result<br/>result view<br/>[WaterResult.tsx]"]
end

subgraph group_group_shared["Shared UI"]
  node_node_shared_ui["Shared UI<br/>primitives<br/>[CameraCapture.tsx]"]
end

subgraph group_group_state["State and hooks"]
  node_node_app_context["App context<br/>state<br/>[AppContext.tsx]"]
  node_node_mesh_context["Mesh context<br/>state<br/>[MeshContext.tsx]"]
  node_node_hooks["Device hooks<br/>browser adapters<br/>[useCamera.ts]"]
end

subgraph group_group_logic["Core logic"]
  node_node_db[("Local DB<br/>persistence<br/>[db.ts]")]
  node_node_offline_queue["Offline queue<br/>[offline-queue.ts]"]
  node_node_model_router["Model router<br/>ai routing<br/>[model-router.ts]"]
  node_node_gemma["Gemma<br/>model backend<br/>[gemma.ts]"]
  node_node_prompts["Prompts<br/>prompt set<br/>[firstaid-prompt.ts]"]
  node_node_preprocess["Preprocess<br/>media+geo utils<br/>[imageUtils.ts]"]
end

subgraph group_group_mesh["Mesh coordination"]
  node_node_family_mesh["Family mesh<br/>coordination ui<br/>[FamilyMesh.tsx]"]
  node_node_match_alert["Match alert<br/>coordination ui<br/>[MatchAlert.tsx]"]
  node_node_person_card["Person card<br/>coordination ui<br/>[PersonCard.tsx]"]
  node_node_mesh_lib["Mesh lib<br/>coordination logic<br/>[mesh.ts]"]
  node_node_mesh_relay["Relay client<br/>transport<br/>[mesh-relay.ts]"]
  node_node_family_match["Family match<br/>matching logic<br/>[family-matching.ts]"]
  node_node_relay_server["Relay server<br/>ts server<br/>[relay.ts]"]
end

node_node_app -->|"renders"| node_node_shell
node_node_shell -->|"includes"| node_node_header
node_node_shell -->|"includes"| node_node_nav
node_node_shell -->|"hosts"| node_node_home
node_node_shell -->|"hosts"| node_node_onboarding
node_node_shell -->|"hosts"| node_node_history
node_node_shell -->|"hosts"| node_node_settings
node_node_home -->|"launches"| node_node_firstaid
node_node_home -->|"launches"| node_node_hazard
node_node_home -->|"launches"| node_node_structure
node_node_home -->|"launches"| node_node_water
node_node_home -->|"launches"| node_node_family_mesh
node_node_firstaid -->|"outputs"| node_node_firstaid_result
node_node_hazard -->|"outputs"| node_node_hazard_result
node_node_structure -->|"outputs"| node_node_structure_result
node_node_water -->|"outputs"| node_node_water_result
node_node_firstaid -->|"uses"| node_node_shared_ui
node_node_hazard -->|"uses"| node_node_shared_ui
node_node_structure -->|"uses"| node_node_shared_ui
node_node_water -->|"uses"| node_node_shared_ui
node_node_family_mesh -->|"uses"| node_node_match_alert
node_node_family_mesh -->|"uses"| node_node_person_card
node_node_app_context -->|"supports"| node_node_shell
node_node_mesh_context -->|"supports"| node_node_family_mesh
node_node_hooks -->|"feeds"| node_node_firstaid
node_node_hooks -->|"feeds"| node_node_hazard
node_node_hooks -->|"feeds"| node_node_structure
node_node_hooks -->|"feeds"| node_node_water
node_node_hooks -->|"feeds"| node_node_family_mesh
node_node_firstaid -->|"analyzes via"| node_node_model_router
node_node_hazard -->|"analyzes via"| node_node_model_router
node_node_structure -->|"analyzes via"| node_node_model_router
node_node_water -->|"analyzes via"| node_node_model_router
node_node_model_router -->|"dispatches"| node_node_gemma
node_node_model_router -->|"uses"| node_node_prompts
node_node_model_router -->|"uses"| node_node_preprocess
node_node_model_router -->|"falls back to"| node_node_offline_queue
node_node_firstaid_result -->|"persists"| node_node_db
node_node_hazard_result -->|"persists"| node_node_db
node_node_structure_result -->|"persists"| node_node_db
node_node_water_result -->|"persists"| node_node_db
node_node_history -->|"reads"| node_node_db
node_node_offline_queue -->|"stores"| node_node_db
node_node_family_mesh -->|"coordinates via"| node_node_mesh_lib
node_node_mesh_lib -->|"transports via"| node_node_mesh_relay
node_node_mesh_lib -->|"matches via"| node_node_family_match
node_node_mesh_relay -->|"connects to"| node_node_relay_server

click node_node_app "https://github.com/devgupta0910/disasterguard/blob/main/src/App.tsx"
click node_node_shell "https://github.com/devgupta0910/disasterguard/blob/main/src/components/layout/AppShell.tsx"
click node_node_header "https://github.com/devgupta0910/disasterguard/blob/main/src/components/layout/Header.tsx"
click node_node_nav "https://github.com/devgupta0910/disasterguard/blob/main/src/components/layout/BottomNav.tsx"
click node_node_home "https://github.com/devgupta0910/disasterguard/blob/main/src/pages/HomePage.tsx"
click node_node_onboarding "https://github.com/devgupta0910/disasterguard/blob/main/src/pages/OnboardingPage.tsx"
click node_node_history "https://github.com/devgupta0910/disasterguard/blob/main/src/pages/HistoryPage.tsx"
click node_node_settings "https://github.com/devgupta0910/disasterguard/blob/main/src/pages/SettingsPage.tsx"
click node_node_firstaid "https://github.com/devgupta0910/disasterguard/blob/main/src/components/firstaid/FirstAidScan.tsx"
click node_node_firstaid_result "https://github.com/devgupta0910/disasterguard/blob/main/src/components/firstaid/FirstAidResult.tsx"
click node_node_hazard "https://github.com/devgupta0910/disasterguard/blob/main/src/components/hazard/SafePassage.tsx"
click node_node_hazard_result "https://github.com/devgupta0910/disasterguard/blob/main/src/components/hazard/HazardResult.tsx"
click node_node_structure "https://github.com/devgupta0910/disasterguard/blob/main/src/components/structure/StructureScan.tsx"
click node_node_structure_result "https://github.com/devgupta0910/disasterguard/blob/main/src/components/structure/StructureResult.tsx"
click node_node_water "https://github.com/devgupta0910/disasterguard/blob/main/src/components/water/WaterCheck.tsx"
click node_node_water_result "https://github.com/devgupta0910/disasterguard/blob/main/src/components/water/WaterResult.tsx"
click node_node_family_mesh "https://github.com/devgupta0910/disasterguard/blob/main/src/components/family/FamilyMesh.tsx"
click node_node_match_alert "https://github.com/devgupta0910/disasterguard/blob/main/src/components/family/MatchAlert.tsx"
click node_node_person_card "https://github.com/devgupta0910/disasterguard/blob/main/src/components/family/PersonCard.tsx"
click node_node_shared_ui "https://github.com/devgupta0910/disasterguard/blob/main/src/components/shared/CameraCapture.tsx"
click node_node_app_context "https://github.com/devgupta0910/disasterguard/blob/main/src/context/AppContext.tsx"
click node_node_mesh_context "https://github.com/devgupta0910/disasterguard/blob/main/src/context/MeshContext.tsx"
click node_node_hooks "https://github.com/devgupta0910/disasterguard/blob/main/src/hooks/useCamera.ts"
click node_node_db "https://github.com/devgupta0910/disasterguard/blob/main/src/lib/db.ts"
click node_node_offline_queue "https://github.com/devgupta0910/disasterguard/blob/main/src/lib/offline-queue.ts"
click node_node_model_router "https://github.com/devgupta0910/disasterguard/blob/main/src/lib/model-router.ts"
click node_node_gemma "https://github.com/devgupta0910/disasterguard/blob/main/src/lib/gemma.ts"
click node_node_prompts "https://github.com/devgupta0910/disasterguard/blob/main/src/lib/prompts/firstaid-prompt.ts"
click node_node_preprocess "https://github.com/devgupta0910/disasterguard/blob/main/src/lib/imageUtils.ts"
click node_node_mesh_lib "https://github.com/devgupta0910/disasterguard/blob/main/src/lib/mesh.ts"
click node_node_mesh_relay "https://github.com/devgupta0910/disasterguard/blob/main/src/lib/mesh-relay.ts"
click node_node_family_match "https://github.com/devgupta0910/disasterguard/blob/main/src/lib/family-matching.ts"
click node_node_relay_server "https://github.com/devgupta0910/disasterguard/blob/main/server/relay.ts"

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_node_app,node_node_shell,node_node_header,node_node_nav,node_node_home,node_node_onboarding,node_node_history,node_node_settings toneBlue
class node_node_firstaid,node_node_firstaid_result,node_node_hazard,node_node_hazard_result,node_node_structure,node_node_structure_result,node_node_water,node_node_water_result toneAmber
class node_node_shared_ui toneMint
class node_node_app_context,node_node_mesh_context,node_node_hooks toneRose
class node_node_db,node_node_offline_queue,node_node_model_router,node_node_gemma,node_node_prompts,node_node_preprocess toneIndigo
class node_node_family_mesh,node_node_match_alert,node_node_person_card,node_node_mesh_lib,node_node_mesh_relay,node_node_family_match,node_node_relay_server toneTeal
```

## Components

### UI shell

Navigation and page framing

- [App](https://github.com/devgupta0910/disasterguard/blob/main/src/App.tsx): spa entry · Bootstraps the React app and routes into the shell · `src/App.tsx`
- [App shell](https://github.com/devgupta0910/disasterguard/blob/main/src/components/layout/AppShell.tsx): layout · Shared frame with header and bottom navigation · `src/components/layout/AppShell.tsx`
- [Header](https://github.com/devgupta0910/disasterguard/blob/main/src/components/layout/Header.tsx): layout · Top-level app chrome · `src/components/layout/Header.tsx`
- [Bottom nav](https://github.com/devgupta0910/disasterguard/blob/main/src/components/layout/BottomNav.tsx): layout · Mobile-style primary navigation · `src/components/layout/BottomNav.tsx`
- [Home](https://github.com/devgupta0910/disasterguard/blob/main/src/pages/HomePage.tsx): page · Main dashboard entry for field workflows · `src/pages/HomePage.tsx`
- [Onboarding](https://github.com/devgupta0910/disasterguard/blob/main/src/pages/OnboardingPage.tsx): page · Initial setup and guidance flow · `src/pages/OnboardingPage.tsx`
- [History](https://github.com/devgupta0910/disasterguard/blob/main/src/pages/HistoryPage.tsx): page · Past assessments and saved results · `src/pages/HistoryPage.tsx`
- [Settings](https://github.com/devgupta0910/disasterguard/blob/main/src/pages/SettingsPage.tsx): page · App preferences and configuration · `src/pages/SettingsPage.tsx`

### Assessment flows

Domain workflows for scans, checks, and results

- [First aid](https://github.com/devgupta0910/disasterguard/blob/main/src/components/firstaid/FirstAidScan.tsx): workflow · Scan-based first aid assessment and guidance · `src/components/firstaid/FirstAidScan.tsx`
- [Aid result](https://github.com/devgupta0910/disasterguard/blob/main/src/components/firstaid/FirstAidResult.tsx): result view · Rendered outcome for first aid analysis · `src/components/firstaid/FirstAidResult.tsx`
- [Hazard check](https://github.com/devgupta0910/disasterguard/blob/main/src/components/hazard/SafePassage.tsx): workflow · Safe-passage and hazard assessment flow · `src/components/hazard/SafePassage.tsx`
- [Hazard result](https://github.com/devgupta0910/disasterguard/blob/main/src/components/hazard/HazardResult.tsx): result view · Rendered outcome for hazard analysis · `src/components/hazard/HazardResult.tsx`
- [Structure scan](https://github.com/devgupta0910/disasterguard/blob/main/src/components/structure/StructureScan.tsx): workflow · Structural assessment workflow · `src/components/structure/StructureScan.tsx`
- [Structure result](https://github.com/devgupta0910/disasterguard/blob/main/src/components/structure/StructureResult.tsx): result view · Rendered outcome for structure analysis · `src/components/structure/StructureResult.tsx`
- [Water check](https://github.com/devgupta0910/disasterguard/blob/main/src/components/water/WaterCheck.tsx): workflow · Water safety evaluation flow · `src/components/water/WaterCheck.tsx`
- [Water result](https://github.com/devgupta0910/disasterguard/blob/main/src/components/water/WaterResult.tsx): result view · Rendered outcome for water analysis · `src/components/water/WaterResult.tsx`

### Shared UI

Reusable primitives used across workflows

- [Shared UI](https://github.com/devgupta0910/disasterguard/blob/main/src/components/shared/CameraCapture.tsx): primitives · Common capture, guidance, and status components · `src/components/shared/CameraCapture.tsx`

### State and hooks

Global state and device/browser integrations

- [App context](https://github.com/devgupta0910/disasterguard/blob/main/src/context/AppContext.tsx): state · General application state and coordination · `src/context/AppContext.tsx`
- [Mesh context](https://github.com/devgupta0910/disasterguard/blob/main/src/context/MeshContext.tsx): state · Mesh/network state for cross-device coordination · `src/context/MeshContext.tsx`
- [Device hooks](https://github.com/devgupta0910/disasterguard/blob/main/src/hooks/useCamera.ts): browser adapters · Camera, geolocation, offline, and voice integrations · `src/hooks/useCamera.ts`

### Core logic

Persistence, routing, prompts, and preprocessing

- [Local DB](https://github.com/devgupta0910/disasterguard/blob/main/src/lib/db.ts): persistence · Local storage for saved assessments and history · `src/lib/db.ts`
- [Offline queue](https://github.com/devgupta0910/disasterguard/blob/main/src/lib/offline-queue.ts): queue · Queued work when connectivity or backend access is unavailable · `src/lib/offline-queue.ts`
- [Model router](https://github.com/devgupta0910/disasterguard/blob/main/src/lib/model-router.ts): ai routing · Selects or dispatches requests to the model backend · `src/lib/model-router.ts`
- [Gemma](https://github.com/devgupta0910/disasterguard/blob/main/src/lib/gemma.ts): model backend · Model integration used by the analysis pipeline · `src/lib/gemma.ts`
- [Prompts](https://github.com/devgupta0910/disasterguard/blob/main/src/lib/prompts/firstaid-prompt.ts): prompt set · Task-specific prompts for each assessment domain · `src/lib/prompts/firstaid-prompt.ts`
- [Preprocess](https://github.com/devgupta0910/disasterguard/blob/main/src/lib/imageUtils.ts): media+geo utils · Image and location preprocessing helpers · `src/lib/imageUtils.ts`

### Mesh coordination

Peer matching and relay-based family coordination

- [Family mesh](https://github.com/devgupta0910/disasterguard/blob/main/src/components/family/FamilyMesh.tsx): coordination ui · Peer coordination and family location flow · `src/components/family/FamilyMesh.tsx`
- [Match alert](https://github.com/devgupta0910/disasterguard/blob/main/src/components/family/MatchAlert.tsx): coordination ui · Alerts when a family match is found · `src/components/family/MatchAlert.tsx`
- [Person card](https://github.com/devgupta0910/disasterguard/blob/main/src/components/family/PersonCard.tsx): coordination ui · Profile card for a family member or match · `src/components/family/PersonCard.tsx`
- [Mesh lib](https://github.com/devgupta0910/disasterguard/blob/main/src/lib/mesh.ts): coordination logic · Peer relay and family matching logic · `src/lib/mesh.ts`
- [Relay client](https://github.com/devgupta0910/disasterguard/blob/main/src/lib/mesh-relay.ts): transport · Client-side relay plumbing for mesh messaging · `src/lib/mesh-relay.ts`
- [Family match](https://github.com/devgupta0910/disasterguard/blob/main/src/lib/family-matching.ts): matching logic · Matching and coordination rules for family search · `src/lib/family-matching.ts`
- [Relay server](https://github.com/devgupta0910/disasterguard/blob/main/server/relay.ts): ts server · Lightweight backend relay supporting mesh coordination · `server/relay.ts`

## Connections

- App → App shell: renders · App mounts the shared shell
- App shell → Header: includes · Shell composes the header
- App shell → Bottom nav: includes · Shell composes bottom navigation
- App shell → Home: hosts · Shell frames the main dashboard
- App shell → Onboarding: hosts · Shell frames onboarding
- App shell → History: hosts · Shell frames history
- App shell → Settings: hosts · Shell frames settings
- Home → First aid: launches · Home surfaces first-aid workflow
- Home → Hazard check: launches · Home surfaces hazard workflow
- Home → Structure scan: launches · Home surfaces structure workflow
- Home → Water check: launches · Home surfaces water workflow
- Home → Family mesh: launches · Home surfaces family coordination
- First aid → Aid result: outputs · Scan flow produces a result view
- Hazard check → Hazard result: outputs · Hazard flow produces a result view
- Structure scan → Structure result: outputs · Structure flow produces a result view
- Water check → Water result: outputs · Water flow produces a result view
- First aid → Shared UI: uses · Assessment UI reuses common primitives
- Hazard check → Shared UI: uses · Assessment UI reuses common primitives
- Structure scan → Shared UI: uses · Assessment UI reuses common primitives
- Water check → Shared UI: uses · Assessment UI reuses common primitives
- Family mesh → Match alert: uses · Mesh UI shows match notifications
- Family mesh → Person card: uses · Mesh UI renders people and matches
- App context → App shell: supports · General app state feeds the shell and pages
- Mesh context → Family mesh: supports · Mesh state drives coordination UI
- Device hooks → First aid: feeds · Camera and voice input support scans
- Device hooks → Hazard check: feeds · Location and offline state support checks
- Device hooks → Structure scan: feeds · Device context supports structure scans
- Device hooks → Water check: feeds · Device context supports water checks
- Device hooks → Family mesh: feeds · Geolocation and device capabilities support mesh use
- First aid → Model router: analyzes via · Assessment requests are routed to AI backends
- Hazard check → Model router: analyzes via · Assessment requests are routed to AI backends
- Structure scan → Model router: analyzes via · Assessment requests are routed to AI backends
- Water check → Model router: analyzes via · Assessment requests are routed to AI backends
- Model router → Gemma: dispatches · Router can invoke the Gemma integration
- Model router → Prompts: uses · Router applies domain prompts
- Model router → Preprocess: uses · Inputs are preprocessed before analysis
- Model router → Offline queue: falls back to · Work can be queued when offline or unavailable
- Aid result → Local DB: persists · Results are stored for later review
- Hazard result → Local DB: persists · Results are stored for later review
- Structure result → Local DB: persists · Results are stored for later review
- Water result → Local DB: persists · Results are stored for later review
- History → Local DB: reads · History page reads saved assessments
- Offline queue → Local DB: stores · Queued work can be retained locally
- Family mesh → Mesh lib: coordinates via · Coordination UI uses mesh logic
- Mesh lib → Relay client: transports via · Mesh logic uses relay transport
- Mesh lib → Family match: matches via · Family search uses matching rules
- Relay client → Relay server: connects to · Client relay talks to the server relay
