# asad-aziz-001/sentellect-learning-through-emotions architecture

> Architecture diagram of the GitHub repository asad-aziz-001/sentellect-learning-through-emotions, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-07). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/asad-aziz-001/sentellect-learning-through-emotions
- Repository: https://github.com/asad-aziz-001/sentellect-learning-through-emotions

## Overview

Sentellect is a Flask-based adaptive mathematics learning platform. Students authenticate, complete a DASS-21 assessment, receive a mental-state classification, and are served difficulty-tiered chapter content; quizzes and progress tracking support continued learning. The README documents dashboard analytics and SHAP explanations, plus an emotion-aware Gemini chatbot. The excerpts show authentication, chatbot-to-Gemini calls, and persistence-related code, but omit much route logic, so several workflow links rely on the README’s documented architecture rather than inspected implementations.

Main entry points: [`app.py`](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py) (Progress tracking), [`templates/dashboard.html`](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/templates/dashboard.html) (Learning dashboard), [`templates/questionnaire.html`](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/templates/questionnaire.html) (DASS-21 assessment), [`templates`](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/tree/main/templates) (Adaptive chapters)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_learning["Learning workflow"]
  node_assessment["DASS-21 assessment<br/>[questionnaire.html]"]
  node_classifier["Mental-state model<br/>[app.py]"]
  node_adaptation["Difficulty adaptation<br/>[app.py]"]
  node_chapters["Adaptive chapters"]
  node_dashboard["Learning dashboard<br/>[dashboard.html]"]
  node_quizzes["Chapter quizzes"]
  node_progress["Progress tracking<br/>[app.py]"]
  node_explanations["SHAP explanations<br/>[app.py]"]
end

subgraph group_account["Accounts and state"]
  node_auth["Authentication<br/>[app.py]"]
  node_store[("Application data<br/>[app.py]")]
  node_email["Email recovery<br/>[app.py]"]
end

subgraph group_support["Student support"]
  node_chat["AI chatbot<br/>[app.py]"]
  node_gemini["Gemini service"]
end

subgraph group_interface["Student interface"]
  node_webui["Web interface"]
end

node_student(("Student"))

node_student -->|"signs in"| node_auth
node_auth -->|"checks credentials"| node_store
node_auth -->|"routes new users"| node_assessment
node_assessment -->|"submits answers"| node_classifier
node_classifier -->|"classifies state"| node_adaptation
node_adaptation -->|"selects difficulty"| node_chapters
node_chapters -->|"informs learning"| node_dashboard
node_dashboard -->|"offers quizzes"| node_quizzes
node_quizzes -->|"records performance"| node_progress
node_dashboard -->|"shows progress"| node_progress
node_progress -->|"persists completion"| node_store
node_progress -->|"supports insights"| node_explanations
node_student -->|"sends messages"| node_chat
node_chat -->|"generates replies"| node_gemini
node_student -->|"requests recovery"| node_email
node_email -->|"looks up account"| node_store
node_student -->|"uses platform"| node_webui

click node_auth "https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py"
click node_assessment "https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/templates/questionnaire.html"
click node_classifier "https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py"
click node_adaptation "https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py"
click node_chapters "https://github.com/asad-aziz-001/sentellect-learning-through-emotions/tree/main/templates"
click node_dashboard "https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/templates/dashboard.html"
click node_quizzes "https://github.com/asad-aziz-001/sentellect-learning-through-emotions/tree/main/templates"
click node_progress "https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py"
click node_explanations "https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py"
click node_store "https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py"
click node_email "https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py"
click node_chat "https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py"
click node_webui "https://github.com/asad-aziz-001/sentellect-learning-through-emotions/tree/main/templates"

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_assessment,node_classifier,node_adaptation,node_chapters,node_dashboard,node_quizzes,node_progress,node_explanations toneBlue
class node_auth,node_store,node_email toneAmber
class node_chat,node_gemini toneMint
class node_webui toneRose
class node_student toneIndigo
```

## Components

### Learning workflow

- [DASS-21 assessment](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/templates/questionnaire.html): `templates/questionnaire.html`
- [Mental-state model](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py): `app.py`
- [Difficulty adaptation](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py): `app.py`
- [Adaptive chapters](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/tree/main/templates): `templates`
- [Learning dashboard](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/templates/dashboard.html): `templates/dashboard.html`
- [Chapter quizzes](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/tree/main/templates): `templates`
- [Progress tracking](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py): `app.py`
- [SHAP explanations](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py): `app.py`

### Accounts and state

- [Authentication](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py): `app.py`
- [Application data](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py): `app.py`
- [Email recovery](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py): `app.py`

### Student support

- [AI chatbot](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/blob/main/app.py): `app.py`
- **Gemini service**

### Student interface

- [Web interface](https://github.com/asad-aziz-001/sentellect-learning-through-emotions/tree/main/templates): `templates`

### Other components

- **Student**

## Connections

- Student → Authentication: signs in (evidence: `README.md`)
- Authentication → Application data: checks credentials (evidence: `app.py`)
- Authentication → DASS-21 assessment: routes new users (evidence: `README.md`)
- DASS-21 assessment → Mental-state model: submits answers (evidence: `README.md`)
- Mental-state model → Difficulty adaptation: classifies state (evidence: `README.md`)
- Difficulty adaptation → Adaptive chapters: selects difficulty (evidence: `README.md`)
- Adaptive chapters → Learning dashboard: informs learning (evidence: `README.md`)
- Learning dashboard → Chapter quizzes: offers quizzes (evidence: `README.md`)
- Chapter quizzes → Progress tracking: records performance (evidence: `README.md`)
- Learning dashboard → Progress tracking: shows progress (evidence: `README.md`)
- Progress tracking → Application data: persists completion (evidence: `app.py`)
- Progress tracking → SHAP explanations: supports insights (evidence: `README.md`)
- Student → AI chatbot: sends messages (evidence: `README.md`)
- AI chatbot → Gemini service: generates replies (evidence: `app.py`)
- Student → Email recovery: requests recovery (evidence: `README.md`)
- Email recovery → Application data: looks up account (evidence: `app.py`)
- Student → Web interface: uses platform (evidence: `README.md`)
