# sachinsulu/workflow-orchestration architecture

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

- Interactive diagram: https://gitdiagram.com/sachinsulu/workflow-orchestration
- Repository: https://github.com/sachinsulu/workflow-orchestration

## Overview

This Django task-management application lets staff request accounts, work on assigned tasks, and track progress; administrators approve users and managers oversee work. The core task workflow creates a task, queues ML-based assignment and priority scoring, then supports status updates and recalculation. Separate account and task views provide dashboards, profiles, task boards, comments, and administration. The excerpts establish key calls between views, Celery tasks, services, ML utilities, and models; README documentation is absent, so capabilities and links beyond the sampled source are limited to evidence in the source index and tree.

Main entry points: [`workflow/models.py`](https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/models.py) (Tasks & Comments), [`accounts/views.py`](https://github.com/sachinsulu/workflow-orchestration/blob/main/accounts/views.py) (Account Views), [`workflow/views.py`](https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/views.py) (Task Views), [`workflow/services.py`](https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/services.py) (Assignment Service)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_accounts["Accounts &amp; Roles"]
  node_account_views["Account Views<br/>[views.py]"]
  node_account_forms["Account Forms<br/>[forms.py]"]
  node_identity[("Users &amp; Requests<br/>[models.py]")]
end

subgraph group_tasks["Task Workflow"]
  node_task_views["Task Views<br/>[views.py]"]
  node_task_forms["Task Forms<br/>[forms.py]"]
  node_task_records[("Tasks &amp; Comments<br/>[models.py]")]
end

subgraph group_intelligence["Assignment &amp; Scoring"]
  node_task_service["Assignment Service<br/>[services.py]"]
  node_ml["ML Predictions<br/>[ml_utils.py]"]
  node_priority_model["Priority Model"]
  node_assignment_model["Assignment Model"]
end

subgraph group_async["Background Processing"]
  node_celery_app["Celery App<br/>[celery.py]"]
  node_worker_tasks["Async Task Jobs<br/>[tasks.py]"]
end

node_staff(("Staff"))

node_staff -->|"requests access"| node_account_views
node_account_views -->|"validates signup"| node_account_forms
node_account_views -->|"creates users"| node_identity
node_account_views -->|"counts pending"| node_task_records
node_staff -->|"manages tasks"| node_task_views
node_task_views -->|"validates task"| node_task_forms
node_task_views -->|"reads and updates"| node_task_records
node_task_views -->|"queues scoring"| node_worker_tasks
node_worker_tasks -->|"loads task"| node_task_records
node_worker_tasks -->|"runs service"| node_task_service
node_task_service -->|"selects candidates"| node_identity
node_task_service -->|"reads and saves"| node_task_records
node_task_service -->|"requests predictions"| node_ml
node_ml -->|"measures workload"| node_task_records
node_ml -->|"loads model"| node_priority_model
node_ml -->|"loads model"| node_assignment_model
node_celery_app -->|"discovers jobs"| node_worker_tasks

click node_account_views "https://github.com/sachinsulu/workflow-orchestration/blob/main/accounts/views.py"
click node_account_forms "https://github.com/sachinsulu/workflow-orchestration/blob/main/accounts/forms.py"
click node_identity "https://github.com/sachinsulu/workflow-orchestration/blob/main/accounts/models.py"
click node_task_views "https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/views.py"
click node_task_forms "https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/forms.py"
click node_task_records "https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/models.py"
click node_task_service "https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/services.py"
click node_ml "https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/ml_utils.py"
click node_priority_model "https://github.com/sachinsulu/workflow-orchestration/blob/main/ml_models/task_priority_model.joblib"
click node_assignment_model "https://github.com/sachinsulu/workflow-orchestration/blob/main/ml_models/assignment_model.joblib"
click node_celery_app "https://github.com/sachinsulu/workflow-orchestration/blob/main/myproject/celery.py"
click node_worker_tasks "https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/tasks.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_account_views,node_account_forms,node_identity toneBlue
class node_task_views,node_task_forms,node_task_records toneAmber
class node_task_service,node_ml,node_priority_model,node_assignment_model toneMint
class node_celery_app,node_worker_tasks toneRose
class node_staff toneIndigo
```

## Components

### Accounts & Roles

- [Account Views](https://github.com/sachinsulu/workflow-orchestration/blob/main/accounts/views.py): `accounts/views.py`
- [Account Forms](https://github.com/sachinsulu/workflow-orchestration/blob/main/accounts/forms.py): `accounts/forms.py`
- [Users & Requests](https://github.com/sachinsulu/workflow-orchestration/blob/main/accounts/models.py): `accounts/models.py`

### Task Workflow

- [Task Views](https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/views.py): `workflow/views.py`
- [Task Forms](https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/forms.py): `workflow/forms.py`
- [Tasks & Comments](https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/models.py): `workflow/models.py`

### Assignment & Scoring

- [Assignment Service](https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/services.py): `workflow/services.py`
- [ML Predictions](https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/ml_utils.py): `workflow/ml_utils.py`
- [Priority Model](https://github.com/sachinsulu/workflow-orchestration/blob/main/ml_models/task_priority_model.joblib): `ml_models/task_priority_model.joblib`
- [Assignment Model](https://github.com/sachinsulu/workflow-orchestration/blob/main/ml_models/assignment_model.joblib): `ml_models/assignment_model.joblib`

### Background Processing

- [Celery App](https://github.com/sachinsulu/workflow-orchestration/blob/main/myproject/celery.py): `myproject/celery.py`
- [Async Task Jobs](https://github.com/sachinsulu/workflow-orchestration/blob/main/workflow/tasks.py): `workflow/tasks.py`

### Other components

- **Staff**

## Connections

- Staff → Account Views: requests access
- Account Views → Account Forms: validates signup (evidence: `accounts/views.py`)
- Account Views → Users & Requests: creates users (evidence: `accounts/views.py`)
- Account Views → Tasks & Comments: counts pending (evidence: `accounts/views.py`)
- Staff → Task Views: manages tasks
- Task Views → Task Forms: validates task (evidence: `workflow/views.py`)
- Task Views → Tasks & Comments: reads and updates (evidence: `workflow/views.py`)
- Task Views → Async Task Jobs: queues scoring (evidence: `workflow/views.py`)
- Async Task Jobs → Tasks & Comments: loads task (evidence: `workflow/tasks.py`)
- Async Task Jobs → Assignment Service: runs service (evidence: `workflow/tasks.py`)
- Assignment Service → Users & Requests: selects candidates (evidence: `workflow/services.py`)
- Assignment Service → Tasks & Comments: reads and saves (evidence: `workflow/services.py`)
- Assignment Service → ML Predictions: requests predictions (evidence: `workflow/services.py`)
- ML Predictions → Tasks & Comments: measures workload (evidence: `workflow/ml_utils.py`)
- ML Predictions → Priority Model: loads model (evidence: `workflow/ml_utils.py`)
- ML Predictions → Assignment Model: loads model (evidence: `workflow/ml_utils.py`)
- Celery App → Async Task Jobs: discovers jobs (evidence: `myproject/celery.py`)
