# nguyen-trung-tien/wincarepro architecture

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

- Interactive diagram: https://gitdiagram.com/nguyen-trung-tien/wincarepro
- Repository: https://github.com/nguyen-trung-tien/wincarepro

## Overview

WinCare Pro is a Windows desktop maintenance suite. Users enter through the main window or a feature page, inspect system health or select a maintenance task, then review results and apply fixes. The main workflow spans UI commands, view-model coordination, diagnostic/optimization/repair engines, guarded Windows operations, and audit or settings persistence. README capabilities include networking, security, startup, disk, uninstall, updates, scheduling, and the desktop HUD; unsampled feature wiring is represented only where the documented module and exact path support it. Source excerpts are partial, so uncertain call relationships are omitted.

Main entry points: [`Modules`](https://github.com/nguyen-trung-tien/wincarepro/tree/main/Modules) (Feature VMs), [`Modules/Dashboard/DashboardViewModel.cs`](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Modules/Dashboard/DashboardViewModel.cs) (Dashboard VM), [`Engines/Optimization/JunkCleanerEngine.cs`](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Optimization/JunkCleanerEngine.cs) (Junk cleanup), [`Engines/Monitoring/NetworkEngine.cs`](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Monitoring/NetworkEngine.cs) (Network center)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_presentation["Presentation"]
  node_shell["Main window<br/>[MainWindow.xaml.cs]"]
  node_dashboard["Dashboard"]
  node_hud["Desktop HUD"]
  node_featureui["Feature pages"]
  node_dashvm["Dashboard VM"]
  node_featurevm["Feature VMs"]
  node_aiassistant["AI assistant"]
end

subgraph group_analysis["Analysis &amp; monitoring"]
  node_health["Health diagnostics"]
  node_systemscan["System diagnostics<br/>[SystemEngine.cs]"]
  node_network["Network center<br/>[NetworkEngine.cs]"]
end

subgraph group_maintenance["Maintenance engines"]
  node_junk["Junk cleanup"]
  node_startup["Startup manager<br/>[StartupEngine.cs]"]
  node_optimizer["System optimizer"]
  node_security["Security controls"]
  node_contextmenu["Context menu"]
  node_disk["Disk tools<br/>[DiskEngine.cs]"]
  node_uninstall["App uninstall<br/>[UninstallEngine.cs]"]
  node_updater["Software updater"]
end

subgraph group_platform["Platform &amp; persistence"]
  node_safety["Safety guards<br/>[SafePathGuard.cs]"]
  node_runner["Process runner<br/>[ProcessRunner.cs]"]
  node_database[("SQLite store<br/>[DbManager.cs]")]
  node_settings["Settings service<br/>[SettingsService.cs]"]
  node_scheduler["Maintenance scheduler"]
end

node_user(("Windows user"))
node_windows{{"Windows system"}}
node_winget{{"winget"}}

node_user -->|"opens"| node_shell
node_shell -->|"shows"| node_dashboard
node_user -->|"selects feature"| node_featureui
node_dashboard -->|"binds commands"| node_dashvm
node_featureui -->|"binds commands"| node_featurevm
node_aiassistant -->|"requests diagnosis"| node_health
node_dashvm -->|"requests evaluation"| node_health
node_dashvm -->|"requests monitoring"| node_network
node_dashvm -->|"requests cleanup"| node_junk
node_featurevm -->|"requests repair"| node_systemscan
node_featurevm -->|"requests network tasks"| node_network
node_featurevm -->|"requests cleanup"| node_junk
node_featurevm -->|"manages startup"| node_startup
node_featurevm -->|"applies tweaks"| node_optimizer
node_featurevm -->|"manages security"| node_security
node_featurevm -->|"manages entries"| node_contextmenu
node_featurevm -->|"inspects storage"| node_disk
node_featurevm -->|"removes apps"| node_uninstall
node_featurevm -->|"updates apps"| node_updater
node_hud -.->|"displays metrics"| node_network
node_health -->|"returns findings"| node_dashvm
node_systemscan -->|"executes commands"| node_runner
node_systemscan -->|"records actions"| node_database
node_junk -->|"checks deletion paths"| node_safety
node_junk -->|"scans and cleans"| node_windows
node_startup -->|"reads and changes"| node_windows
node_startup -->|"records actions"| node_database
node_optimizer -->|"applies system tweaks"| node_windows
node_security -->|"reads and changes"| node_windows
node_security -->|"records actions"| node_database
node_contextmenu -->|"changes registry"| node_windows
node_network -->|"measures connectivity"| node_windows
node_disk -->|"inspects drives"| node_windows
node_uninstall -->|"removes applications"| node_windows
node_updater -->|"invokes package manager"| node_winget
node_settings -.->|"persists settings"| node_database
node_scheduler -.->|"runs scheduled care"| node_windows
node_shell -.->|"loads preferences"| node_settings

click node_shell "https://github.com/nguyen-trung-tien/wincarepro/blob/main/MainWindow.xaml.cs"
click node_dashboard "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Modules/Dashboard/DashboardPage.xaml.cs"
click node_hud "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Modules/DesktopWidget/DesktopWidgetWindow.xaml.cs"
click node_featureui "https://github.com/nguyen-trung-tien/wincarepro/tree/main/Modules"
click node_dashvm "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Modules/Dashboard/DashboardViewModel.cs"
click node_featurevm "https://github.com/nguyen-trung-tien/wincarepro/tree/main/Modules"
click node_aiassistant "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Modules/AiAssistant/AiWinCareEnginePage.xaml.cs"
click node_health "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Diagnostics/AiDiagnosticsEngine.cs"
click node_systemscan "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Diagnostics/SystemEngine.cs"
click node_network "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Monitoring/NetworkEngine.cs"
click node_junk "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Optimization/JunkCleanerEngine.cs"
click node_startup "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Optimization/StartupEngine.cs"
click node_optimizer "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Optimization/SystemOptimizerEngine.cs"
click node_security "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Repair/SecurityPrivacyEngine.cs"
click node_contextmenu "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Repair/ContextMenuEngine.cs"
click node_disk "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Optimization/DiskEngine.cs"
click node_uninstall "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Repair/UninstallEngine.cs"
click node_updater "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Repair/SoftwareUpdaterEngine.cs"
click node_safety "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Core/Helpers/SafePathGuard.cs"
click node_runner "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Core/Helpers/ProcessRunner.cs"
click node_database "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Infrastructure/Database/DbManager.cs"
click node_settings "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Services/SettingsService/SettingsService.cs"
click node_scheduler "https://github.com/nguyen-trung-tien/wincarepro/blob/main/Services/MaintenanceSchedulerService/MaintenanceSchedulerService.cs"

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_shell,node_dashboard,node_hud,node_featureui,node_dashvm,node_featurevm,node_aiassistant,node_user toneBlue
class node_health,node_systemscan,node_network toneAmber
class node_junk,node_startup,node_optimizer,node_security,node_contextmenu,node_disk,node_uninstall,node_updater toneMint
class node_safety,node_runner,node_database,node_settings,node_scheduler toneRose
class node_windows,node_winget toneIndigo
```

## Components

### Presentation

- [Main window](https://github.com/nguyen-trung-tien/wincarepro/blob/main/MainWindow.xaml.cs): `MainWindow.xaml.cs`
- [Dashboard](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Modules/Dashboard/DashboardPage.xaml.cs): `Modules/Dashboard/DashboardPage.xaml.cs`
- [Desktop HUD](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Modules/DesktopWidget/DesktopWidgetWindow.xaml.cs): `Modules/DesktopWidget/DesktopWidgetWindow.xaml.cs`
- [Feature pages](https://github.com/nguyen-trung-tien/wincarepro/tree/main/Modules): `Modules`
- [Dashboard VM](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Modules/Dashboard/DashboardViewModel.cs): `Modules/Dashboard/DashboardViewModel.cs`
- [Feature VMs](https://github.com/nguyen-trung-tien/wincarepro/tree/main/Modules): `Modules`
- [AI assistant](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Modules/AiAssistant/AiWinCareEnginePage.xaml.cs): `Modules/AiAssistant/AiWinCareEnginePage.xaml.cs`

### Analysis & monitoring

- [Health diagnostics](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Diagnostics/AiDiagnosticsEngine.cs): `Engines/Diagnostics/AiDiagnosticsEngine.cs`
- [System diagnostics](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Diagnostics/SystemEngine.cs): `Engines/Diagnostics/SystemEngine.cs`
- [Network center](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Monitoring/NetworkEngine.cs): `Engines/Monitoring/NetworkEngine.cs`

### Maintenance engines

- [Junk cleanup](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Optimization/JunkCleanerEngine.cs): `Engines/Optimization/JunkCleanerEngine.cs`
- [Startup manager](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Optimization/StartupEngine.cs): `Engines/Optimization/StartupEngine.cs`
- [System optimizer](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Optimization/SystemOptimizerEngine.cs): `Engines/Optimization/SystemOptimizerEngine.cs`
- [Security controls](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Repair/SecurityPrivacyEngine.cs): `Engines/Repair/SecurityPrivacyEngine.cs`
- [Context menu](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Repair/ContextMenuEngine.cs): `Engines/Repair/ContextMenuEngine.cs`
- [Disk tools](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Optimization/DiskEngine.cs): `Engines/Optimization/DiskEngine.cs`
- [App uninstall](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Repair/UninstallEngine.cs): `Engines/Repair/UninstallEngine.cs`
- [Software updater](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Engines/Repair/SoftwareUpdaterEngine.cs): `Engines/Repair/SoftwareUpdaterEngine.cs`

### Platform & persistence

- [Safety guards](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Core/Helpers/SafePathGuard.cs): `Core/Helpers/SafePathGuard.cs`
- [Process runner](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Core/Helpers/ProcessRunner.cs): `Core/Helpers/ProcessRunner.cs`
- [SQLite store](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Infrastructure/Database/DbManager.cs): `Infrastructure/Database/DbManager.cs`
- [Settings service](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Services/SettingsService/SettingsService.cs): `Services/SettingsService/SettingsService.cs`
- [Maintenance scheduler](https://github.com/nguyen-trung-tien/wincarepro/blob/main/Services/MaintenanceSchedulerService/MaintenanceSchedulerService.cs): `Services/MaintenanceSchedulerService/MaintenanceSchedulerService.cs`

### Other components

- **Windows user**
- **Windows system**
- **winget**

## Connections

- Windows user → Main window: opens
- Main window → Dashboard: shows
- Windows user → Feature pages: selects feature
- Dashboard → Dashboard VM: binds commands
- Feature pages → Feature VMs: binds commands
- AI assistant → Health diagnostics: requests diagnosis
- Dashboard VM → Health diagnostics: requests evaluation
- Dashboard VM → Network center: requests monitoring
- Dashboard VM → Junk cleanup: requests cleanup
- Feature VMs → System diagnostics: requests repair
- Feature VMs → Network center: requests network tasks
- Feature VMs → Junk cleanup: requests cleanup
- Feature VMs → Startup manager: manages startup
- Feature VMs → System optimizer: applies tweaks
- Feature VMs → Security controls: manages security
- Feature VMs → Context menu: manages entries
- Feature VMs → Disk tools: inspects storage
- Feature VMs → App uninstall: removes apps
- Feature VMs → Software updater: updates apps
- Desktop HUD → Network center: displays metrics
- Health diagnostics → Dashboard VM: returns findings
- System diagnostics → Process runner: executes commands
- System diagnostics → SQLite store: records actions
- Junk cleanup → Safety guards: checks deletion paths
- Junk cleanup → Windows system: scans and cleans
- Startup manager → Windows system: reads and changes
- Startup manager → SQLite store: records actions
- System optimizer → Windows system: applies system tweaks
- Security controls → Windows system: reads and changes
- Security controls → SQLite store: records actions
- Context menu → Windows system: changes registry
- Network center → Windows system: measures connectivity
- Disk tools → Windows system: inspects drives
- App uninstall → Windows system: removes applications
- Software updater → winget: invokes package manager
- Settings service → SQLite store: persists settings
- Maintenance scheduler → Windows system: runs scheduled care
- Main window → Settings service: loads preferences
