# malik-zain-555/mudabbir-fyp architecture

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

- Interactive diagram: https://gitdiagram.com/malik-zain-555/mudabbir-fyp
- Repository: https://github.com/malik-zain-555/mudabbir-fyp

## Overview

Mudabbir is a Quran-reading web application. A reader opens the frontend, which requests the Quran dataset from the FastAPI backend; the backend queries Oracle and returns surah names and Arabic ayat, and the reader selects a surah to display its verses. Separate scripts load Quran and translation data from CSVs into Oracle. The sampled UI displays Arabic text; the repository also contains translation data, but its use in the interface is not established by the available excerpts. Backend internals beyond the sampled entry point are not shown.

Main entry points: [`frontend/src/App.jsx`](https://github.com/malik-zain-555/mudabbir-fyp/blob/main/frontend/src/App.jsx) (Surah reader), [`database/load_quran.py`](https://github.com/malik-zain-555/mudabbir-fyp/blob/main/database/load_quran.py) (Local data loader), [`database/load_quran_cloud.py`](https://github.com/malik-zain-555/mudabbir-fyp/blob/main/database/load_quran_cloud.py) (Cloud data loader), [`backend/main.py`](https://github.com/malik-zain-555/mudabbir-fyp/blob/main/backend/main.py) (Quran API)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_web["Reader interface"]
  node_app_entry["React entry<br/>[main.jsx]"]
  node_reader_ui["Surah reader<br/>[App.jsx]"]
end

subgraph group_service["Quran API"]
  node_api["Quran API<br/>[main.py]"]
  node_backend_init["Backend package<br/>[__init__.py]"]
end

subgraph group_data["Quran data"]
  node_oracle[("Oracle database")]
  node_local_loader["Local data loader<br/>[load_quran.py]"]
  node_cloud_loader["Cloud data loader"]
  node_csv_data["Quran CSV data"]
end

node_reader(("Reader"))

node_app_entry -->|"renders"| node_reader_ui
node_reader -->|"selects surah"| node_reader_ui
node_reader_ui -->|"requests Quran"| node_api
node_api -->|"queries"| node_oracle
node_local_loader -->|"reads"| node_csv_data
node_local_loader -->|"loads rows"| node_oracle
node_cloud_loader -->|"reads"| node_csv_data
node_cloud_loader -->|"loads rows"| node_oracle

click node_app_entry "https://github.com/malik-zain-555/mudabbir-fyp/blob/main/frontend/src/main.jsx"
click node_reader_ui "https://github.com/malik-zain-555/mudabbir-fyp/blob/main/frontend/src/App.jsx"
click node_api "https://github.com/malik-zain-555/mudabbir-fyp/blob/main/backend/main.py"
click node_backend_init "https://github.com/malik-zain-555/mudabbir-fyp/blob/main/backend/src/backend/__init__.py"
click node_local_loader "https://github.com/malik-zain-555/mudabbir-fyp/blob/main/database/load_quran.py"
click node_cloud_loader "https://github.com/malik-zain-555/mudabbir-fyp/blob/main/database/load_quran_cloud.py"
click node_csv_data "https://github.com/malik-zain-555/mudabbir-fyp/tree/main/database/data"

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_app_entry,node_reader_ui toneBlue
class node_api,node_backend_init toneAmber
class node_oracle,node_local_loader,node_cloud_loader,node_csv_data toneMint
class node_reader toneIndigo
```

## Components

### Reader interface

- [React entry](https://github.com/malik-zain-555/mudabbir-fyp/blob/main/frontend/src/main.jsx): `frontend/src/main.jsx`
- [Surah reader](https://github.com/malik-zain-555/mudabbir-fyp/blob/main/frontend/src/App.jsx): `frontend/src/App.jsx`

### Quran API

- [Quran API](https://github.com/malik-zain-555/mudabbir-fyp/blob/main/backend/main.py): `backend/main.py`
- [Backend package](https://github.com/malik-zain-555/mudabbir-fyp/blob/main/backend/src/backend/__init__.py): `backend/src/backend/__init__.py`

### Quran data

- **Oracle database**
- [Local data loader](https://github.com/malik-zain-555/mudabbir-fyp/blob/main/database/load_quran.py): `database/load_quran.py`
- [Cloud data loader](https://github.com/malik-zain-555/mudabbir-fyp/blob/main/database/load_quran_cloud.py): `database/load_quran_cloud.py`
- [Quran CSV data](https://github.com/malik-zain-555/mudabbir-fyp/tree/main/database/data): `database/data`

### Other components

- **Reader**

## Connections

- React entry → Surah reader: renders (evidence: `frontend/src/main.jsx`)
- Reader → Surah reader: selects surah (evidence: `frontend/src/App.jsx`)
- Surah reader → Quran API: requests Quran (evidence: `frontend/src/App.jsx`)
- Quran API → Oracle database: queries (evidence: `backend/main.py`)
- Local data loader → Quran CSV data: reads (evidence: `database/load_quran.py`)
- Local data loader → Oracle database: loads rows (evidence: `database/load_quran.py`)
- Cloud data loader → Quran CSV data: reads (evidence: `database/load_quran_cloud.py`)
- Cloud data loader → Oracle database: loads rows (evidence: `database/load_quran_cloud.py`)
