# shreyash-sp80/crms-appwrite architecture

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

- Interactive diagram: https://gitdiagram.com/shreyash-sp80/crms-appwrite
- Repository: https://github.com/shreyash-sp80/crms-appwrite

## Overview

CRMS-Appwrite is a Streamlit results-management and analysis application backed by Appwrite. The principal workflow is administrator PDF upload, extraction and storage of student results, followed by filtered dashboards, analyses, search and report generation; users also reach login and registration through the app. The README provides little product detail, and several page implementations were not sampled, so unsampled pages are represented as capabilities from their filenames rather than detailed internal flows.

Main entry points: [`app.py`](https://github.com/shreyash-sp80/crms-appwrite/blob/main/app.py) (App entry and navigation), [`backend/appwrite_db.py`](https://github.com/shreyash-sp80/crms-appwrite/blob/main/backend/appwrite_db.py) (Database access), [`pages/upload_pdf.py`](https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/upload_pdf.py) (PDF upload and extraction), [`pages/dashboard.py`](https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/dashboard.py) (Performance dashboard)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_ui["Streamlit application"]
  node_app["App entry and navigation<br/>[app.py]"]
  node_auth["Login and registration<br/>[app.py]"]
end

subgraph group_ingest["Result ingestion"]
  node_upload["PDF upload and extraction<br/>[upload_pdf.py]"]
end

subgraph group_analysis["Results and reporting"]
  node_dashboard["Performance dashboard<br/>[dashboard.py]"]
  node_top["Top students<br/>[top_students.py]"]
  node_division["Division analysis"]
  node_passfail["Pass/fail analysis"]
  node_subject["Subject analysis"]
  node_search["Student search<br/>[student_search.py]"]
  node_excel["Excel report<br/>[excel_report.py]"]
  node_myresults["My results<br/>[my_results.py]"]
  node_update["Update results<br/>[update_results.py]"]
end

subgraph group_data["Persistence"]
  node_storelayer["Database access<br/>[appwrite_db.py]"]
end

node_user(("User"))
node_appwrite[("Appwrite database")]
node_email["Email OTP service"]

node_user -->|"opens"| node_app
node_app -->|"shows"| node_auth
node_app -->|"routes"| node_dashboard
node_app -->|"routes"| node_upload
node_app -->|"routes"| node_top
node_app -->|"routes"| node_division
node_app -->|"routes"| node_passfail
node_app -->|"routes"| node_subject
node_app -->|"routes"| node_search
node_app -->|"routes"| node_excel
node_app -->|"routes"| node_myresults
node_app -->|"routes"| node_update
node_auth -.->|"sends OTP"| node_email
node_upload -->|"saves results"| node_storelayer
node_dashboard -->|"loads results"| node_storelayer
node_top -->|"loads results"| node_storelayer
node_division -->|"loads results"| node_storelayer
node_passfail -->|"loads results"| node_storelayer
node_subject -->|"loads results"| node_storelayer
node_search -->|"loads details"| node_storelayer
node_excel -->|"loads results"| node_storelayer
node_myresults -->|"accesses results"| node_storelayer
node_update -->|"accesses results"| node_storelayer
node_storelayer -->|"reads and writes"| node_appwrite

click node_app "https://github.com/shreyash-sp80/crms-appwrite/blob/main/app.py"
click node_auth "https://github.com/shreyash-sp80/crms-appwrite/blob/main/app.py"
click node_upload "https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/upload_pdf.py"
click node_dashboard "https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/dashboard.py"
click node_top "https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/top_students.py"
click node_division "https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/division_analysis.py"
click node_passfail "https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/pass_fail_analysis.py"
click node_subject "https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/subject_analysis.py"
click node_search "https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/student_search.py"
click node_excel "https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/excel_report.py"
click node_myresults "https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/my_results.py"
click node_update "https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/update_results.py"
click node_storelayer "https://github.com/shreyash-sp80/crms-appwrite/blob/main/backend/appwrite_db.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_app,node_auth,node_user toneBlue
class node_upload,node_appwrite toneAmber
class node_dashboard,node_top,node_division,node_passfail,node_subject,node_search,node_excel,node_myresults,node_update toneMint
class node_storelayer toneRose
class node_email toneIndigo
```

## Components

### Streamlit application

- [App entry and navigation](https://github.com/shreyash-sp80/crms-appwrite/blob/main/app.py): `app.py`
- [Login and registration](https://github.com/shreyash-sp80/crms-appwrite/blob/main/app.py): `app.py`

### Result ingestion

- [PDF upload and extraction](https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/upload_pdf.py): `pages/upload_pdf.py`

### Results and reporting

- [Performance dashboard](https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/dashboard.py): `pages/dashboard.py`
- [Top students](https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/top_students.py): `pages/top_students.py`
- [Division analysis](https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/division_analysis.py): `pages/division_analysis.py`
- [Pass/fail analysis](https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/pass_fail_analysis.py): `pages/pass_fail_analysis.py`
- [Subject analysis](https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/subject_analysis.py): `pages/subject_analysis.py`
- [Student search](https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/student_search.py): `pages/student_search.py`
- [Excel report](https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/excel_report.py): `pages/excel_report.py`
- [My results](https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/my_results.py): `pages/my_results.py`
- [Update results](https://github.com/shreyash-sp80/crms-appwrite/blob/main/pages/update_results.py): `pages/update_results.py`

### Persistence

- [Database access](https://github.com/shreyash-sp80/crms-appwrite/blob/main/backend/appwrite_db.py): `backend/appwrite_db.py`

### Other components

- **User**
- **Appwrite database**
- **Email OTP service**

## Connections

- User → App entry and navigation: opens
- App entry and navigation → Login and registration: shows
- App entry and navigation → Performance dashboard: routes
- App entry and navigation → PDF upload and extraction: routes
- App entry and navigation → Top students: routes
- App entry and navigation → Division analysis: routes
- App entry and navigation → Pass/fail analysis: routes
- App entry and navigation → Subject analysis: routes
- App entry and navigation → Student search: routes
- App entry and navigation → Excel report: routes
- App entry and navigation → My results: routes
- App entry and navigation → Update results: routes
- Login and registration → Email OTP service: sends OTP
- PDF upload and extraction → Database access: saves results
- Performance dashboard → Database access: loads results
- Top students → Database access: loads results
- Division analysis → Database access: loads results
- Pass/fail analysis → Database access: loads results
- Subject analysis → Database access: loads results
- Student search → Database access: loads details
- Excel report → Database access: loads results
- My results → Database access: accesses results
- Update results → Database access: accesses results
- Database access → Appwrite database: reads and writes
