# dxn-xnt/entervene architecture

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

- Interactive diagram: https://gitdiagram.com/dxn-xnt/entervene
- Repository: https://github.com/dxn-xnt/entervene

## Overview

Entervene is an AI-enhanced learning management system for managing academic work and student risk. The main workflow is that staff record learning activity and assessment evidence; the system uses academic records to surface risk and explanations; teachers review cases and can coordinate interventions, including student-facing reviewers and notifications. The repository also supports class and curriculum administration, quizzes, attendance, analytics, and student records. The graph follows the documented backend route/service structure and the available tree; most route-to-service wiring and frontend request details were not sampled, so uncertain links are omitted.

Main entry points: [`backend/app/main.py`](https://github.com/dxn-xnt/entervene/blob/main/backend/app/main.py) (API application), [`backend/app/db/Session.py`](https://github.com/dxn-xnt/entervene/blob/main/backend/app/db/Session.py) (Application data), [`backend/app/api/v1/routes/Predictions.py`](https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Predictions.py) (Risk predictions), [`backend/app/models/academic`](https://github.com/dxn-xnt/entervene/tree/main/backend/app/models/academic) (Academic records)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_learning["Learning workflows"]
  node_classwork["Classwork and submissions<br/>[Classworks.py]"]
  node_submission_service["Submission handling"]
  node_lessons["Lessons and plans<br/>[Lessons.py]"]
  node_quizzes["Quizzes<br/>[Quizzes.py]"]
  node_attendance["Attendance<br/>[Attendance.py]"]
  node_student_records["Student records"]
  node_analytics["Analytics<br/>[Analytics.py]"]
end

subgraph group_risk["Risk and support"]
  node_predictions["Risk predictions<br/>[Predictions.py]"]
  node_feature_builder["Feature building"]
  node_risk_engine["Risk evaluation<br/>[RiskEngine.py]"]
  node_prediction_review["Teacher risk review"]
  node_interventions["Interventions"]
  node_reviewer_generation["Reviewer generation"]
  node_reviewer_delivery["Reviewer delivery"]
  node_notifications["Notifications"]
  node_ai_provider["AI provider<br/>[Provider.py]"]
  node_prediction_models["Prediction records"]
end

subgraph group_platform["Application platform"]
  node_frontend["Web application<br/>[App.tsx]"]
  node_api_client["API client<br/>[api.ts]"]
  node_app_entry["API application<br/>[main.py]"]
  node_auth["Authentication<br/>[Auth.py]"]
  node_database[("Application data<br/>[Session.py]")]
end

subgraph group_academic["Academic operations"]
  node_classes["Classes<br/>[Classes.py]"]
  node_subjects["Subjects and offerings"]
  node_grading["Grading templates"]
  node_pathways["Pathways<br/>[Pathways.py]"]
  node_academic_models["Academic records"]
end

node_staff(("Staff"))
node_students(("Students"))

node_staff -->|"uses"| node_frontend
node_students -->|"uses"| node_frontend
node_frontend -->|"requests data"| node_api_client
node_api_client -->|"sends requests"| node_app_entry
node_app_entry -->|"routes authentication"| node_auth
node_auth -->|"reads and writes"| node_database
node_app_entry -->|"routes requests"| node_classwork
node_classwork -->|"handles submissions"| node_submission_service
node_app_entry -->|"routes requests"| node_lessons
node_app_entry -->|"routes requests"| node_quizzes
node_app_entry -->|"routes requests"| node_attendance
node_app_entry -->|"routes requests"| node_student_records
node_app_entry -->|"routes requests"| node_analytics
node_app_entry -->|"routes requests"| node_predictions
node_predictions -->|"builds features"| node_feature_builder
node_predictions -->|"evaluates risk"| node_risk_engine
node_predictions -->|"reads and writes"| node_prediction_models
node_prediction_review -->|"records decisions"| node_prediction_models
node_app_entry -->|"routes requests"| node_interventions
node_reviewer_generation -.->|"generates content"| node_ai_provider
node_reviewer_delivery -->|"stages notification"| node_notifications
node_reviewer_delivery -->|"delivers reviewer"| node_students
node_app_entry -->|"routes requests"| node_classes
node_app_entry -->|"routes requests"| node_subjects
node_app_entry -->|"routes requests"| node_grading
node_app_entry -->|"routes requests"| node_pathways
node_classes -->|"reads academic data"| node_academic_models
node_subjects -->|"reads academic data"| node_academic_models
node_grading -->|"reads grading data"| node_academic_models
node_pathways -->|"reads pathway data"| node_academic_models
node_submission_service -->|"persists submissions"| node_database
node_student_records -->|"reads and writes"| node_database
node_feature_builder -->|"reads evidence"| node_database
node_risk_engine -->|"reads thresholds"| node_database

click node_frontend "https://github.com/dxn-xnt/entervene/blob/main/frontend/src/App.tsx"
click node_api_client "https://github.com/dxn-xnt/entervene/blob/main/frontend/src/lib/api.ts"
click node_app_entry "https://github.com/dxn-xnt/entervene/blob/main/backend/app/main.py"
click node_auth "https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Auth.py"
click node_database "https://github.com/dxn-xnt/entervene/blob/main/backend/app/db/Session.py"
click node_classwork "https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Classworks.py"
click node_submission_service "https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/submission/SubmissionService.py"
click node_lessons "https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Lessons.py"
click node_quizzes "https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Quizzes.py"
click node_attendance "https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Attendance.py"
click node_student_records "https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/student_record/StudentRecordService.py"
click node_analytics "https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Analytics.py"
click node_predictions "https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Predictions.py"
click node_feature_builder "https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/prediction/PredictionFeatureBuilderService.py"
click node_risk_engine "https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/prediction/RiskEngine.py"
click node_prediction_review "https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/prediction/TeacherRiskReviewService.py"
click node_interventions "https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/intervention/TeacherInterventionService.py"
click node_reviewer_generation "https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/intervention/InterventionReviewerGenerationService.py"
click node_reviewer_delivery "https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/intervention/InterventionReviewerDeliveryService.py"
click node_notifications "https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/NotificationService.py"
click node_ai_provider "https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/ai/Provider.py"
click node_classes "https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Classes.py"
click node_subjects "https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/SubjectOfferings.py"
click node_grading "https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/GradingTemplates.py"
click node_pathways "https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Pathways.py"
click node_academic_models "https://github.com/dxn-xnt/entervene/tree/main/backend/app/models/academic"
click node_prediction_models "https://github.com/dxn-xnt/entervene/tree/main/backend/app/models/ai"

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_classwork,node_submission_service,node_lessons,node_quizzes,node_attendance,node_student_records,node_analytics toneBlue
class node_predictions,node_feature_builder,node_risk_engine,node_prediction_review,node_interventions,node_reviewer_generation,node_reviewer_delivery,node_notifications,node_ai_provider,node_prediction_models toneAmber
class node_frontend,node_api_client,node_app_entry,node_auth,node_database toneMint
class node_classes,node_subjects,node_grading,node_pathways,node_academic_models toneRose
class node_staff,node_students toneIndigo
```

## Components

### Learning workflows

- [Classwork and submissions](https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Classworks.py): `backend/app/api/v1/routes/Classworks.py`
- [Submission handling](https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/submission/SubmissionService.py): `backend/app/services/submission/SubmissionService.py`
- [Lessons and plans](https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Lessons.py): `backend/app/api/v1/routes/Lessons.py`
- [Quizzes](https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Quizzes.py): `backend/app/api/v1/routes/Quizzes.py`
- [Attendance](https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Attendance.py): `backend/app/api/v1/routes/Attendance.py`
- [Student records](https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/student_record/StudentRecordService.py): `backend/app/services/student_record/StudentRecordService.py`
- [Analytics](https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Analytics.py): `backend/app/api/v1/routes/Analytics.py`

### Risk and support

- [Risk predictions](https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Predictions.py): `backend/app/api/v1/routes/Predictions.py`
- [Feature building](https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/prediction/PredictionFeatureBuilderService.py): `backend/app/services/prediction/PredictionFeatureBuilderService.py`
- [Risk evaluation](https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/prediction/RiskEngine.py): `backend/app/services/prediction/RiskEngine.py`
- [Teacher risk review](https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/prediction/TeacherRiskReviewService.py): `backend/app/services/prediction/TeacherRiskReviewService.py`
- [Interventions](https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/intervention/TeacherInterventionService.py): `backend/app/services/intervention/TeacherInterventionService.py`
- [Reviewer generation](https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/intervention/InterventionReviewerGenerationService.py): `backend/app/services/intervention/InterventionReviewerGenerationService.py`
- [Reviewer delivery](https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/intervention/InterventionReviewerDeliveryService.py): `backend/app/services/intervention/InterventionReviewerDeliveryService.py`
- [Notifications](https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/NotificationService.py): `backend/app/services/NotificationService.py`
- [AI provider](https://github.com/dxn-xnt/entervene/blob/main/backend/app/services/ai/Provider.py): `backend/app/services/ai/Provider.py`
- [Prediction records](https://github.com/dxn-xnt/entervene/tree/main/backend/app/models/ai): `backend/app/models/ai`

### Application platform

- [Web application](https://github.com/dxn-xnt/entervene/blob/main/frontend/src/App.tsx): `frontend/src/App.tsx`
- [API client](https://github.com/dxn-xnt/entervene/blob/main/frontend/src/lib/api.ts): `frontend/src/lib/api.ts`
- [API application](https://github.com/dxn-xnt/entervene/blob/main/backend/app/main.py): `backend/app/main.py`
- [Authentication](https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Auth.py): `backend/app/api/v1/routes/Auth.py`
- [Application data](https://github.com/dxn-xnt/entervene/blob/main/backend/app/db/Session.py): `backend/app/db/Session.py`

### Academic operations

- [Classes](https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Classes.py): `backend/app/api/v1/routes/Classes.py`
- [Subjects and offerings](https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/SubjectOfferings.py): `backend/app/api/v1/routes/SubjectOfferings.py`
- [Grading templates](https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/GradingTemplates.py): `backend/app/api/v1/routes/GradingTemplates.py`
- [Pathways](https://github.com/dxn-xnt/entervene/blob/main/backend/app/api/v1/routes/Pathways.py): `backend/app/api/v1/routes/Pathways.py`
- [Academic records](https://github.com/dxn-xnt/entervene/tree/main/backend/app/models/academic): `backend/app/models/academic`

### Other components

- **Staff**
- **Students**

## Connections

- Staff → Web application: uses
- Students → Web application: uses
- Web application → API client: requests data
- API client → API application: sends requests
- API application → Authentication: routes authentication
- Authentication → Application data: reads and writes
- API application → Classwork and submissions: routes requests
- Classwork and submissions → Submission handling: handles submissions
- API application → Lessons and plans: routes requests
- API application → Quizzes: routes requests
- API application → Attendance: routes requests
- API application → Student records: routes requests
- API application → Analytics: routes requests
- API application → Risk predictions: routes requests
- Risk predictions → Feature building: builds features
- Risk predictions → Risk evaluation: evaluates risk
- Risk predictions → Prediction records: reads and writes
- Teacher risk review → Prediction records: records decisions
- API application → Interventions: routes requests
- Reviewer generation → AI provider: generates content
- Reviewer delivery → Notifications: stages notification
- Reviewer delivery → Students: delivers reviewer
- API application → Classes: routes requests
- API application → Subjects and offerings: routes requests
- API application → Grading templates: routes requests
- API application → Pathways: routes requests
- Classes → Academic records: reads academic data
- Subjects and offerings → Academic records: reads academic data
- Grading templates → Academic records: reads grading data
- Pathways → Academic records: reads pathway data
- Submission handling → Application data: persists submissions
- Student records → Application data: reads and writes
- Feature building → Application data: reads evidence
- Risk evaluation → Application data: reads thresholds
