# charan-2006/skyhigh_cil-imin architecture

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

- Interactive diagram: https://gitdiagram.com/charan-2006/skyhigh_cil-imin
- Repository: https://github.com/charan-2006/skyhigh_cil-imin

## Overview

CarbonCortex in this repository is a React dashboard MVP for coal-quality and mining decisions, with mock-integrated workflows rather than live prediction services. An operator enters through the routed UI, signs in for protected pages, and can review analytics or use prediction, blending, decision, and scenario screens. Reports and settings are also exposed. The README describes planned ML, trust-routing, lab-feedback, integrations, and automated reporting capabilities, but no backend or data-pipeline source appears in the tree; those capabilities are not represented as implemented components here.

Main entry points: [`src/App.tsx`](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/App.tsx) (Route App), [`src/data/mockData.ts`](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/data/mockData.ts) (Mock Metrics and Records), [`src/pages/DashboardPage.tsx`](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/DashboardPage.tsx) (Executive Dashboard), [`src/pages/CoalQualityPredictionPage.tsx`](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/CoalQualityPredictionPage.tsx) (Quality Prediction)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["App and Access"]
  node_entrypoint["UI Entry<br/>[main.tsx]"]
  node_router["Route App<br/>[App.tsx]"]
  node_login["Sign In<br/>[LoginPage.tsx]"]
  node_guard["Route Guard<br/>[ProtectedRoute.tsx]"]
end

subgraph group_operations["Mining Workflows"]
  node_landing["Landing Page<br/>[LandingPage.tsx]"]
  node_dashboard["Executive Dashboard<br/>[DashboardPage.tsx]"]
  node_prediction["Quality Prediction"]
  node_blend["Blend Optimization"]
  node_decisions["Decision Intelligence"]
  node_simulator["Scenario Simulation"]
  node_reports["Reports<br/>[ReportsPage.tsx]"]
  node_settings["Settings<br/>[SettingsPage.tsx]"]
end

subgraph group_presentation["Dashboard Presentation"]
  node_layout["App Layout<br/>[AppLayout.tsx]"]
  node_navigation["Sidebar and Topbar<br/>[Sidebar.tsx]"]
  node_charts["Charts and Confidence Views"]
  node_common["Page and Metric Components"]
  node_ui["UI Components"]
end

subgraph group_state["Mock Data and Auth"]
  node_auth["Session Auth<br/>[auth.ts]"]
  node_mockdata["Mock Metrics and Records<br/>[mockData.ts]"]
end

node_operator(("Operator"))

node_operator -->|"opens"| node_entrypoint
node_entrypoint -->|"renders"| node_router
node_router -->|"routes to"| node_landing
node_router -->|"routes to"| node_login
node_router -->|"protects routes"| node_guard
node_router -->|"mounts"| node_layout
node_router -->|"routes to"| node_dashboard
node_router -->|"routes to"| node_prediction
node_router -->|"routes to"| node_blend
node_router -->|"routes to"| node_decisions
node_router -->|"routes to"| node_simulator
node_router -->|"routes to"| node_reports
node_router -->|"routes to"| node_settings
node_guard -->|"checks session"| node_auth
node_login -->|"updates session"| node_auth
node_layout -->|"renders"| node_navigation
node_dashboard -->|"reads"| node_mockdata
node_prediction -->|"renders confidence"| node_charts
node_prediction -->|"reads"| node_mockdata
node_dashboard -->|"renders charts"| node_charts
node_blend -->|"renders charts"| node_charts
node_blend -->|"reads"| node_mockdata
node_decisions -->|"reads"| node_mockdata
node_simulator -->|"renders scenarios"| node_charts
node_reports -->|"reads"| node_mockdata
node_settings -->|"reads"| node_mockdata
node_dashboard -->|"uses"| node_common
node_prediction -->|"uses"| node_common
node_landing -->|"uses"| node_ui

click node_entrypoint "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/main.tsx"
click node_router "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/App.tsx"
click node_login "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/LoginPage.tsx"
click node_guard "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/components/auth/ProtectedRoute.tsx"
click node_auth "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/lib/auth.ts"
click node_layout "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/components/layout/AppLayout.tsx"
click node_navigation "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/components/layout/Sidebar.tsx"
click node_landing "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/LandingPage.tsx"
click node_dashboard "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/DashboardPage.tsx"
click node_prediction "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/CoalQualityPredictionPage.tsx"
click node_blend "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/BlendOptimizationPage.tsx"
click node_decisions "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/DecisionIntelligencePage.tsx"
click node_simulator "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/ScenarioSimulatorPage.tsx"
click node_reports "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/ReportsPage.tsx"
click node_settings "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/SettingsPage.tsx"
click node_mockdata "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/data/mockData.ts"
click node_charts "https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/components/charts/ChartComponents.tsx"
click node_common "https://github.com/charan-2006/skyhigh_cil-imin/tree/main/src/components/common"
click node_ui "https://github.com/charan-2006/skyhigh_cil-imin/tree/main/src/components/ui"

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_entrypoint,node_router,node_login,node_guard toneBlue
class node_landing,node_dashboard,node_prediction,node_blend,node_decisions,node_simulator,node_reports,node_settings toneAmber
class node_layout,node_navigation,node_charts,node_common,node_ui toneMint
class node_auth,node_mockdata toneRose
class node_operator toneIndigo
```

## Components

### App and Access

- [UI Entry](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/main.tsx): `src/main.tsx`
- [Route App](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/App.tsx): `src/App.tsx`
- [Sign In](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/LoginPage.tsx): `src/pages/LoginPage.tsx`
- [Route Guard](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/components/auth/ProtectedRoute.tsx): `src/components/auth/ProtectedRoute.tsx`

### Mining Workflows

- [Landing Page](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/LandingPage.tsx): `src/pages/LandingPage.tsx`
- [Executive Dashboard](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/DashboardPage.tsx): `src/pages/DashboardPage.tsx`
- [Quality Prediction](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/CoalQualityPredictionPage.tsx): `src/pages/CoalQualityPredictionPage.tsx`
- [Blend Optimization](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/BlendOptimizationPage.tsx): `src/pages/BlendOptimizationPage.tsx`
- [Decision Intelligence](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/DecisionIntelligencePage.tsx): `src/pages/DecisionIntelligencePage.tsx`
- [Scenario Simulation](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/ScenarioSimulatorPage.tsx): `src/pages/ScenarioSimulatorPage.tsx`
- [Reports](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/ReportsPage.tsx): `src/pages/ReportsPage.tsx`
- [Settings](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/pages/SettingsPage.tsx): `src/pages/SettingsPage.tsx`

### Dashboard Presentation

- [App Layout](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/components/layout/AppLayout.tsx): `src/components/layout/AppLayout.tsx`
- [Sidebar and Topbar](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/components/layout/Sidebar.tsx): `src/components/layout/Sidebar.tsx`
- [Charts and Confidence Views](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/components/charts/ChartComponents.tsx): `src/components/charts/ChartComponents.tsx`
- [Page and Metric Components](https://github.com/charan-2006/skyhigh_cil-imin/tree/main/src/components/common): `src/components/common`
- [UI Components](https://github.com/charan-2006/skyhigh_cil-imin/tree/main/src/components/ui): `src/components/ui`

### Mock Data and Auth

- [Session Auth](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/lib/auth.ts): `src/lib/auth.ts`
- [Mock Metrics and Records](https://github.com/charan-2006/skyhigh_cil-imin/blob/main/src/data/mockData.ts): `src/data/mockData.ts`

### Other components

- **Operator**

## Connections

- Operator → UI Entry: opens (evidence: `src/main.tsx`)
- UI Entry → Route App: renders (evidence: `src/main.tsx`)
- Route App → Landing Page: routes to (evidence: `src/App.tsx`)
- Route App → Sign In: routes to (evidence: `src/App.tsx`)
- Route App → Route Guard: protects routes (evidence: `src/App.tsx`)
- Route App → App Layout: mounts (evidence: `src/App.tsx`)
- Route App → Executive Dashboard: routes to (evidence: `src/App.tsx`)
- Route App → Quality Prediction: routes to (evidence: `src/App.tsx`)
- Route App → Blend Optimization: routes to (evidence: `src/App.tsx`)
- Route App → Decision Intelligence: routes to (evidence: `src/App.tsx`)
- Route App → Scenario Simulation: routes to (evidence: `src/App.tsx`)
- Route App → Reports: routes to (evidence: `src/App.tsx`)
- Route App → Settings: routes to (evidence: `src/App.tsx`)
- Route Guard → Session Auth: checks session (evidence: `src/components/auth/ProtectedRoute.tsx`)
- Sign In → Session Auth: updates session (evidence: `src/pages/LoginPage.tsx`)
- App Layout → Sidebar and Topbar: renders (evidence: `src/components/layout/AppLayout.tsx`)
- Executive Dashboard → Mock Metrics and Records: reads (evidence: `src/pages/DashboardPage.tsx`)
- Quality Prediction → Charts and Confidence Views: renders confidence (evidence: `src/pages/CoalQualityPredictionPage.tsx`)
- Quality Prediction → Mock Metrics and Records: reads (evidence: `src/pages/CoalQualityPredictionPage.tsx`)
- Executive Dashboard → Charts and Confidence Views: renders charts (evidence: `src/pages/DashboardPage.tsx`)
- Blend Optimization → Charts and Confidence Views: renders charts (evidence: `src/pages/BlendOptimizationPage.tsx`)
- Blend Optimization → Mock Metrics and Records: reads (evidence: `src/pages/BlendOptimizationPage.tsx`)
- Decision Intelligence → Mock Metrics and Records: reads (evidence: `src/pages/DecisionIntelligencePage.tsx`)
- Scenario Simulation → Charts and Confidence Views: renders scenarios (evidence: `src/pages/ScenarioSimulatorPage.tsx`)
- Reports → Mock Metrics and Records: reads (evidence: `src/pages/ReportsPage.tsx`)
- Settings → Mock Metrics and Records: reads (evidence: `src/pages/SettingsPage.tsx`)
- Executive Dashboard → Page and Metric Components: uses (evidence: `src/pages/DashboardPage.tsx`)
- Quality Prediction → Page and Metric Components: uses (evidence: `src/pages/CoalQualityPredictionPage.tsx`)
- Landing Page → UI Components: uses (evidence: `src/pages/LandingPage.tsx`)
