Give the user a fast, trustworthy picture of their computer's health and a short list
of actions worth taking — the way a good technician would: look first, explain plainly,
fix only with permission.
It runs entirely through Desktop Commander's local shell, gathers a batch of read-only
diagnostics, scores each area, prints a concise summary in the chat, and then offers
cleanup suggestions the user can approve one by one.
This is the part that makes users trust the skill, so honor it strictly:
It changes nothing.
sudo or elevation. DC blocks sudo, shutdown, reboot, dd, mount,mkfs, diskpart, etc. for good reason. Every check below is designed to work without
them. If something seems to need elevation, skip it and say so — don't try to work around
the block.
the user explicitly approves that specific action, and only show the exact command first.
a package-manager download cache, or emptying Trash are fine to offer. Deleting user
documents, uninstalling apps, or editing system files are not — suggest those, let the
user do them.
Determine the platform before doing anything else, because the commands differ.
get_config) and use thesystemInfo.isMacOS / isWindows / isLinux booleans (or platformName) to
pick the platform.
uname (macOS/Linux) — if it fails, assume Windows.Then open the matching reference file and use its command set:
references/macos.mdreferences/windows.mdreferences/linux.mdRead only the one that matches. Each file contains a single batched collection script
plus interpretation notes and cleanup commands.
Run the batched collection script from the reference file with start_process. Batching
everything into one call is much faster than many small calls and keeps the output tidy.
Guidance:
head, Select-Object -First, etc.) so a long process list orfile listing doesn't flood the response.
first pass unless the user asked about updates or network. Mention they're available.
Rate each category 🟢 Good / 🟡 Watch / 🔴 Act using the rubric below, then compute a simple
overall score. Start at 100 and subtract 8 per 🟡 and 18 per 🔴; floor at 0. Report the
number and a one-word verdict (90+ Excellent, 75–89 Good, 60–74 Fair, <60 Needs attention).
| Area | 🟢 Good | 🟡 Watch | 🔴 Act |
|---|---|---|---|
| Free disk space | >20% free | 10–20% | <10% |
| Disk health (SMART) | Verified / OK / PASSED | — | failing / not supported & errors present |
| Memory pressure | low swap, free pages healthy | noticeable swap/compression | heavy swapping, near-zero free |
| Battery (laptops) | ≥80% max capacity, Normal | 70–80% | <70% or "Service/Replace" |
| Maintenance | uptime <7d, no pending updates | uptime 7–30d or minor updates | uptime >30d or security updates pending |
| Startup load | few third-party login items | moderate | many heavy third-party agents |
| Live resource hogs | nothing >50% at idle | one sustained heavy process | multiple / runaway processes |
Battery is laptop-only — skip it on desktops/VMs. Reclaimable space is reported as an
informational figure, not scored.
Use this exact structure. Keep it tight and scannable — this is the deliverable.
🖥️ Health Check — <Model>, <OS version> Score: <N>/100 (<verdict>)
🟢/🟡/🔴 Storage — <free> free of <total> (<%>). Reclaimable: ~<X> GB
🟢/🟡/🔴 Memory — <one-line state>
🟢/🟡/🔴 Battery — <cycles> cycles, <max capacity>%, <condition>
🟢/🟡/🔴 Maintenance — up <days>d, <updates state>
🟢/🟡/🔴 Startup — <count> login items (<notable ones>)
🟢/🟡/🔴 Right now — top: <proc> <cpu%>, <proc> <cpu%>
Top recommendations
1. <highest-impact action> (<expected benefit, e.g. frees ~13 GB>)
2. <next>
3. <next>
List at most the 3–5 highest-impact recommendations, ordered by benefit. Don't dump every
finding — the goal is signal, not a wall of text.
For each recommendation that maps to a concrete command (see the reference file's "Cleanup"
section), offer it and show the exact command. Then:
(brew cleanup, npm cache clean), clearing a regenerating user cache folder. (On Linux,apt-get clean / dnf clean need root — suggest, don't auto-run.)
installing OS updates (requires restart), uninstalling apps, deleting files in Downloads.
When the user approves a safe action, run it, then report what changed (e.g., space freed).
Re-running Step 2's storage check afterward is a nice confirmation.
These are the high-value mappings; adapt the wording to the platform.
memory and applies pending updates." (Highest ROI, lowest effort.)
priority.
clear caches that regenerate.
upgrade + cache cleanup.affecting runtime.
doesn't recognize/need (point to System Settings / Task Manager — don't edit them directly).
fabricate sizes, cycle counts, or statuses.
per-folder disk scan of the whole home directory, crash-report trend analysis.
the public-IP check is optional and should be labeled.
report looks the same regardless of OS.