Manages WorkloadsSessionHost memory consumption on Windows 11 Copilot+ PCs.
Microsoft's Copilot+ architecture pre-loads AI models into RAM via WorkloadsSessionHost.exe — often spawning 5–9 instances that collectively consume 2–8GB of memory, even when no AI features are in use. On systems where every megabyte counts, this is unacceptable.
WinslopFix provides intelligent, memory-threshold-based process management, granular Copilot AI feature controls, and silent RMM-ready deployment — all packaged as a proper PowerShell module.
Originally inspired by WorkloadManager by Dante/SafeAutentic. Refactored from scratch with proper module architecture, structured output, comprehensive help, and PSGallery compliance.
Install-Module -Name WinslopFix -Scope CurrentUser# Clone or download to a PSModulePath directory
git clone https://github.com/DailenG/WinslopFix.git "$env:USERPROFILE\Documents\PowerShell\Modules\WinslopFix"
Import-Module WinslopFix# Import the module
Import-Module WinslopFix
# See what's running and how much memory it's consuming
Get-WorkloadSessionStatus
# Preview what would be killed (dry run)
Stop-WorkloadSession -WhatIf
# Kill processes exceeding 512MB (default threshold)
Stop-WorkloadSession -Confirm:$false
# Install as a persistent, silent background monitor (SYSTEM, no UAC prompts)
Install-WinslopFix
# Install AND disable all Copilot AI features
Install-WinslopFix -DisableAIFeatures| Function | Description |
|---|---|
Get-WorkloadSessionStatus |
Returns structured metrics for all WorkloadsSessionHost instances |
Stop-WorkloadSession |
Terminates processes using configurable strategy (MemoryThreshold, Timer, All) |
Start-WinslopFix |
Starts the persistent monitoring loop (called by the Scheduled Task) |
Install-WinslopFix |
Deploys the module and creates a SYSTEM-level Scheduled Task |
Uninstall-WinslopFix |
Removes the Scheduled Task, deployed files, and Event Log source |
Get-WinslopFixLog |
Queries Windows Event Log entries with category filtering |
Disable-CopilotAIFeature |
Disables Recall, Click to Do, and/or Windows AI Fabric Service |
Enable-CopilotAIFeature |
Re-enables previously disabled AI features |
Kills processes exceeding a per-process threshold (default: 512MB) or when aggregate memory across all instances exceeds an aggregate threshold (default: 2GB).
Note on Accuracy: WinslopFix evaluates PrivateMemorySize64 (Private Bytes) instead of WorkingSet64. This ensures we only kill instances that are truly hoarding exclusive memory, ignoring large AI models that are safely mapped into shared memory. This is the intelligent approach — processes that aren't consuming problematic exclusive memory are left alone.
Stop-WorkloadSession -Strategy MemoryThreshold -PerProcessThresholdMB 256 -AggregateThresholdMB 1024Kills processes that have been running longer than a specified duration. This mirrors the original SafeAutentic behavior for environments that prefer time-based management.
Stop-WorkloadSession -Strategy Timer -TimerSeconds 120Immediately terminates every WorkloadsSessionHost instance. Use sparingly.
Stop-WorkloadSession -Strategy All -Confirm:$falseGranular control over Windows AI features without touching the monitor:
# Disable just Recall
Disable-CopilotAIFeature -Feature Recall
# Disable everything
Disable-CopilotAIFeature -Feature All
# Re-enable Click to Do only
Enable-CopilotAIFeature -Feature ClickToDo
# Preview what would change
Disable-CopilotAIFeature -Feature All -WhatIf| Feature | What It Controls |
|---|---|
Recall |
Registry policies, ScreenshotIndexerService, Recall/Snapshot scheduled tasks |
ClickToDo |
DisableClickToDo registry policy |
WindowsAI |
WSAIFabricSvc service, all Windows AI scheduled tasks |
All |
All of the above |
Install-Module WinslopFix -Force -Scope AllUsers
Import-Module WinslopFix
Install-WinslopFix -DisableAIFeatures -ForceImport-Module WinslopFix
Start-WinslopFix -RunOnceImport-Module WinslopFix
Get-WorkloadSessionStatus | ConvertTo-JsonThe monitor loads configuration from a JSON file. Resolution order:
- Explicit
-ConfigPathparameter $env:ProgramData\WinslopFix\config.json(deployed config)- Bundled
Config\DefaultConfig.json - Hardcoded safe defaults
{
"Strategy": "MemoryThreshold",
"PerProcessThresholdMB": 512,
"AggregateThresholdMB": 2048,
"TimerSeconds": 60,
"ScanIntervalSeconds": 10,
"ProcessName": "WorkloadsSessionHost",
"EventLogSource": "WinslopFix",
"EventLogName": "Application"
}To customize, copy this to C:\ProgramData\WinslopFix\config.json and edit as needed. The monitor will pick up changes on next restart.
All operations are logged to the Windows Application Event Log under the WinslopFix source.
# View recent activity
Get-WinslopFixLog -Newest 20
# View only kills
Get-WinslopFixLog -Category Kills
# View errors from the last hour
Get-WinslopFixLog -Category Errors -After (Get-Date).AddHours(-1)| Range | Category | Description |
|---|---|---|
| 1000-1999 | Lifecycle | Monitor start/stop, config loaded |
| 2000-2999 | Detection | New process detected, natural exit |
| 3000-3999 | Action | Process terminated (by strategy) |
| 4000-4999 | Policy | AI feature enabled/disabled |
| 9000-9999 | Error | Failures and exceptions |
| Aspect | Original | WinslopFix Module |
|---|---|---|
| Kill strategy | Blind 60-second timer | Memory-threshold (configurable) |
| Auto-start | HKCU:\Run (UAC prompt every boot) |
SYSTEM Scheduled Task (silent) |
| Error handling | Empty catch {} blocks |
Structured errors, Event Log, warnings |
| Structure | 3 loose .ps1 files |
Proper .psd1 + .psm1 module |
| Output | Write-Host only |
Structured PSCustomObject pipeline output |
| AI controls | All-or-nothing (baked into installer) | Granular per-feature targeting |
| Safety | No WhatIf/Confirm | Full SupportsShouldProcess |
| Uninstall | Kills ALL PowerShell processes | Targeted Scheduled Task removal |
| Language | Spanish only | English with full comment-based help |
| Tests | None | Pester + PSScriptAnalyzer |
- Windows 11 (24H2 / 25H2) on Copilot+ PC hardware
- PowerShell 5.1 or PowerShell 7+
- Administrator privileges for install/uninstall and AI feature management
- No external module dependencies
Originally inspired by WorkloadManager by Dante/SafeAutentic. This module is a complete rewrite maintaining the same objective: keep WorkloadsSessionHost.exe from consuming unreasonable system resources on Copilot+ PCs.