# tspratham09-hue/omnitrust architecture

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

- Interactive diagram: https://gitdiagram.com/tspratham09-hue/omnitrust
- Repository: https://github.com/tspratham09-hue/omnitrust

## Overview

OmniTrust combines geospatial hazard verification with a public-safety navigation interface. The user-facing workflow presents a map and route, evaluates telemetry and reports for trustworthiness, then communicates verified hazards and safer travel options. The sampled FastAPI stream computes trust metrics and audit hashes; a separate evaluation API uses the reliability framework. README-described routing, map layers, and voice features are retained, though dashboard implementation details were not sampled, so those links rely on documented capabilities.

Main entry points: [`dashboard.html`](https://github.com/tspratham09-hue/omnitrust/blob/main/dashboard.html) (Interactive dashboard), [`geo_reliability_framework.py`](https://github.com/tspratham09-hue/omnitrust/blob/main/geo_reliability_framework.py) (Insight evaluator), [`engine.py`](https://github.com/tspratham09-hue/omnitrust/blob/main/engine.py) (Trust and audit engine), [`main.py`](https://github.com/tspratham09-hue/omnitrust/blob/main/main.py) (Telemetry WebSocket)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_interface["Navigation interface"]
  node_streamlit["Streamlit shell<br/>[app.py]"]
  node_dashboard["Interactive dashboard<br/>[dashboard.html]"]
  node_map_layers["Map layers<br/>[dashboard.html]"]
  node_voice["Voice copilot<br/>[dashboard.html]"]
end

subgraph group_routing["Routing and hazards"]
  node_route_planner["Route planning<br/>[dashboard.html]"]
  node_hazard_detours["Hazard detours<br/>[dashboard.html]"]
  node_osrm["OSRM routing"]
end

subgraph group_verification["Verification core"]
  node_weather["Weather telemetry"]
  node_crowd_reports["Crowdsourced reports"]
  node_satellite["Satellite feeds"]
  node_trust_engine["Trust and audit engine<br/>[engine.py]"]
  node_source_profiler["Source profiling"]
  node_consistency["Evidence consistency"]
  node_confidence["Confidence fusion"]
  node_insight_evaluator["Insight evaluator"]
end

subgraph group_services["API services"]
  node_stream_api["Telemetry WebSocket<br/>[main.py]"]
  node_evaluation_api["Insight API<br/>[api.py]"]
end

node_user(("Driver"))

node_user -->|"uses"| node_dashboard
node_streamlit -->|"renders"| node_dashboard
node_dashboard -->|"displays"| node_map_layers
node_dashboard -->|"offers"| node_voice
node_dashboard -->|"requests routes"| node_route_planner
node_route_planner -->|"requests geometry"| node_osrm
node_dashboard -->|"shows overlays"| node_weather
node_dashboard -->|"submits reports"| node_crowd_reports
node_dashboard -->|"uses feeds"| node_satellite
node_dashboard -->|"streams telemetry"| node_stream_api
node_stream_api -->|"computes trust"| node_trust_engine
node_trust_engine -.->|"returns metrics"| node_dashboard
node_dashboard -->|"renders detours"| node_hazard_detours
node_hazard_detours -->|"requests alternate"| node_route_planner
node_evaluation_api -->|"evaluates insight"| node_insight_evaluator
node_insight_evaluator -->|"aligns and scores"| node_consistency
node_insight_evaluator -->|"fuses report"| node_confidence
node_confidence -->|"scores sources"| node_source_profiler

click node_streamlit "https://github.com/tspratham09-hue/omnitrust/blob/main/app.py"
click node_dashboard "https://github.com/tspratham09-hue/omnitrust/blob/main/dashboard.html"
click node_map_layers "https://github.com/tspratham09-hue/omnitrust/blob/main/dashboard.html"
click node_voice "https://github.com/tspratham09-hue/omnitrust/blob/main/dashboard.html"
click node_route_planner "https://github.com/tspratham09-hue/omnitrust/blob/main/dashboard.html"
click node_hazard_detours "https://github.com/tspratham09-hue/omnitrust/blob/main/dashboard.html"
click node_trust_engine "https://github.com/tspratham09-hue/omnitrust/blob/main/engine.py"
click node_source_profiler "https://github.com/tspratham09-hue/omnitrust/blob/main/geo_reliability_framework.py"
click node_consistency "https://github.com/tspratham09-hue/omnitrust/blob/main/geo_reliability_framework.py"
click node_confidence "https://github.com/tspratham09-hue/omnitrust/blob/main/geo_reliability_framework.py"
click node_insight_evaluator "https://github.com/tspratham09-hue/omnitrust/blob/main/geo_reliability_framework.py"
click node_stream_api "https://github.com/tspratham09-hue/omnitrust/blob/main/main.py"
click node_evaluation_api "https://github.com/tspratham09-hue/omnitrust/blob/main/api.py"

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_streamlit,node_dashboard,node_map_layers,node_voice toneBlue
class node_route_planner,node_hazard_detours,node_osrm toneAmber
class node_weather,node_crowd_reports,node_satellite,node_trust_engine,node_source_profiler,node_consistency,node_confidence,node_insight_evaluator toneMint
class node_stream_api,node_evaluation_api toneRose
class node_user toneIndigo
```

## Components

### Navigation interface

- [Streamlit shell](https://github.com/tspratham09-hue/omnitrust/blob/main/app.py): `app.py`
- [Interactive dashboard](https://github.com/tspratham09-hue/omnitrust/blob/main/dashboard.html): `dashboard.html`
- [Map layers](https://github.com/tspratham09-hue/omnitrust/blob/main/dashboard.html): `dashboard.html`
- [Voice copilot](https://github.com/tspratham09-hue/omnitrust/blob/main/dashboard.html): `dashboard.html`

### Routing and hazards

- [Route planning](https://github.com/tspratham09-hue/omnitrust/blob/main/dashboard.html): `dashboard.html`
- [Hazard detours](https://github.com/tspratham09-hue/omnitrust/blob/main/dashboard.html): `dashboard.html`
- **OSRM routing**

### Verification core

- **Weather telemetry**
- **Crowdsourced reports**
- **Satellite feeds**
- [Trust and audit engine](https://github.com/tspratham09-hue/omnitrust/blob/main/engine.py): `engine.py`
- [Source profiling](https://github.com/tspratham09-hue/omnitrust/blob/main/geo_reliability_framework.py): `geo_reliability_framework.py`
- [Evidence consistency](https://github.com/tspratham09-hue/omnitrust/blob/main/geo_reliability_framework.py): `geo_reliability_framework.py`
- [Confidence fusion](https://github.com/tspratham09-hue/omnitrust/blob/main/geo_reliability_framework.py): `geo_reliability_framework.py`
- [Insight evaluator](https://github.com/tspratham09-hue/omnitrust/blob/main/geo_reliability_framework.py): `geo_reliability_framework.py`

### API services

- [Telemetry WebSocket](https://github.com/tspratham09-hue/omnitrust/blob/main/main.py): `main.py`
- [Insight API](https://github.com/tspratham09-hue/omnitrust/blob/main/api.py): `api.py`

### Other components

- **Driver**

## Connections

- Driver → Interactive dashboard: uses (evidence: `README.md`)
- Streamlit shell → Interactive dashboard: renders (evidence: `app.py`)
- Interactive dashboard → Map layers: displays (evidence: `README.md`)
- Interactive dashboard → Voice copilot: offers (evidence: `README.md`)
- Interactive dashboard → Route planning: requests routes (evidence: `README.md`)
- Route planning → OSRM routing: requests geometry (evidence: `README.md`)
- Interactive dashboard → Weather telemetry: shows overlays (evidence: `README.md`)
- Interactive dashboard → Crowdsourced reports: submits reports (evidence: `README.md`)
- Interactive dashboard → Satellite feeds: uses feeds (evidence: `README.md`)
- Interactive dashboard → Telemetry WebSocket: streams telemetry (evidence: `README.md`)
- Telemetry WebSocket → Trust and audit engine: computes trust (evidence: `main.py`)
- Trust and audit engine → Interactive dashboard: returns metrics
- Interactive dashboard → Hazard detours: renders detours (evidence: `README.md`)
- Hazard detours → Route planning: requests alternate (evidence: `README.md`)
- Insight API → Insight evaluator: evaluates insight (evidence: `api.py`)
- Insight evaluator → Evidence consistency: aligns and scores (evidence: `geo_reliability_framework.py`)
- Insight evaluator → Confidence fusion: fuses report (evidence: `geo_reliability_framework.py`)
- Confidence fusion → Source profiling: scores sources (evidence: `geo_reliability_framework.py`)
