Mac resource triage
Mac first aid for AI coding leftovers: user-invoked vibe-coding triage for memory, CPU, battery, orphan processes, polling configs, and this-session vetted PID kills.From its SKILL.md
npx -y skills add heyallensu/mac-resource-triageAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
SKILL.md
6.2 KB, ~1.5k tokens by cl100k_base, as published. Nobody here has run it
Mac Vibe Triage
Mac first aid for AI coding leftovers. Triage resource bloat left behind by vibe coding, local agents, MCP servers, dev tools, and leaked browser helpers. Find the evidence first, then kill only the vetted (user-greenlit) PIDs.
This skill is user-invocable only. Never auto-run.
Safety baseline (universal, never relax)
- Never kill a
root-owned process. - Never kill anything owned by another user.
- Never kill anything under
/System/Library/,/usr/libexec/, or matchingcom.apple.*. - Never kill
kernel_task,WindowServer,launchd,loginwindow,coreaudiod. - Never kill anything in the current agent PID chain (walk via
ps -o ppid= -p $$). - Never rewrite JSON, delete LaunchAgents, uninstall apps/packages, or run
launchctl bootoutwithout a separate explicit user confirmation for that exact action.
The safety baseline lives in this skill and is enforced again by scripts/kill-pid-list.sh. The persistent profile can add user preferences; it can never weaken these rules.
Workflow
- Read persistent profile at
$HOME/.config/mac-vibe-triage/profile.md. Usereferences/profile-template.mdas the schema. If the file is malformed or missing, use an empty profile and require explicit confirmation for every candidate. - Run diagnostics β see
references/diagnostics.md. Each step has a "Done iff" criterion; satisfy it before moving on. - Map playbooks β see
references/playbooks.md. If evidence matches a known incident shape, name the playbook and its evidence; if no playbook fits, say "unknown / general resource bloat" rather than guessing. - Vet candidates. Every gathered candidate gets one of:
- π’ matches an Always-green rule β surface as a low-risk candidate, still requiring this-run confirmation
- π΄ matches an Always-keep rule β drop from report entirely
- π‘ matches a Sit-down rule, or no rule β ask before placing in any kill batch
- Run a vetted kill. Once the user greenlights a PID (or
kill all greenafter seeing the exact PID list), execscripts/kill-pid-list.sh <PID β¦>. Each PID is vetted individually before being added; SIGTERM β verify β SIGKILL is the runtime half. - Emit Triage Report β see
references/triage-report.md. Include symptom, evidence, suspects, actions taken, decisions needed, and what remains unknown. - Emit post-run recommendations β see
references/post-run-recommendations.md. Pick 3β5 items grounded in what was just vetted. - Close. Ask the user which (if any) of this run's decisions to memorize (
kkeep /ssit-down /tthreshold /nno). Append to profile on confirmation, bumpupdated:.
Vetted-kill protocol (the leading concept)
A vetted kill = a SIGTERM/SIGKILL pair sent to a PID the user has explicitly greenlit in this session. Vetting is per-PID, per-run; a PID vetted last run is not automatically vetted this run.
A vet cycle is: candidate identified β surfaced to user β user says kill <PID> (or batched kill all green) β only then SIGTERM. If the user says no or stays silent for >1 turn, drop the candidate.
scripts/kill-pid-list.sh enforces the runtime half (refuses non-numeric, other-user/root, system paths, com.apple.*, protected process names, the current agent PID chain, claude-agent-sdk-darwin-arm64/bin/claude, and ssh-agent). The protocol above enforces the user-greenlit half.
Helper scripts
| Script | Behavior |
|---|---|
scripts/kill-pid-list.sh | Runtime half of a vetted kill β SIGTERM β verify β SIGKILL with per-PID verify loop |
scripts/inspect-pid-tree.sh | Diagnostic β walks ppid chain upward for a PID, read-only |
scripts/find-high-freq-configs.sh | Diagnostic β scans settings JSON for sub-threshold polling intervals, read-only |
Only the first writes (sends signals). The rest are read-only β even if the rest are run from the same shell as a vetted kill.
Persistent profile
Schema for $HOME/.config/mac-vibe-triage/profile.md:
- Always-green β patterns the user has confirmed as low-risk candidates; still require this-run confirmation.
- Always-keep β patterns never to surface (e.g.
cmux, current Claude Code PID chain). - Sit-down-and-ask β surface but require per-run user input (e.g.
Token Monitor). - Custom thresholds, Output preferences, Anti-rules (user-pinned) β user preferences and learned negations.
Failure mode: profile unreadable / malformed β use an empty profile and ask for every candidate. Never infer Always-green from an unknown or broken profile.
Anti-patterns (skill-side, not safety)
- β Concluding "Electron == θη΅ε€§ζ·" without TIME-based evidence.
- β Acting like a generic Mac cleanup tool. Stay in the vibe-coding/local-agent incident frame unless evidence proves otherwise.
- β Recommending
rebootas a first reaction for WindowServer drift. - β Trusting
pssnapshot alone for "is X installed?" β cross-check/Applications+ LaunchAgents per Step 5. - β Auto-rewriting
settings.jsonβ tell the user what to change; they edit unless they explicitly ask you to edit that exact file. - β Bundling this with
/neat-freak-style cleanup (that skill is for skills + memory + docs, not processes).
The profile is for preferences, not universal safety. A profile entry that conflicts with the safety baseline is ignored and reported as invalid.
Edge cases
psreturns zero user rows β "δ½ εδΈε½ε沑ζδ»»δ½η¨ζ·θΏη¨οΌθ·η©Ίγ" Done.- User pastes a 50-PID list β truncate to first 20 in the report table, offer to show the rest.
- Process respawns within 3 s with a new PID β flag
warn: PID <X> respawned as <Y>and ask before re-killing. - User asks to kill current Claude Code β refuse; suggest
/exit+clauderestart. - User says "nuke everything" β never comply silently; enumerate every category and require exact
kill <PID>commands orkill all greenafter showing the exact green PID list.
What ships with it: 11 files
39.9 KB alongside SKILL.md, 3 of them executable
references/
- diagnostics.md4.1 KB
- playbooks.md3.6 KB
- post-run-recommendations.md1.7 KB
- profile-template.md1.6 KB
- triage-report.md1.8 KB
scripts/
- find-high-freq-configs.shruns4.5 KB
- inspect-pid-tree.shruns2.1 KB
- kill-pid-list.shruns4.6 KB
- .gitignore50 B
- LICENSE1.0 KB
- README.md14.8 KB
Gives 0 of the 12 instructions most debug triage skills give in ~1.5k tokens
Counted across 839 of the 1,149 authors here whose files we hold, read 2026-08-07
- Investigate root cause before proposing any fixin 102 of 839, across 67 files
- Read error messages completelyin 89 of 839, across 49 files
- Create a failing test case before fixingin 84 of 839, across 46 files
- Reproduce the issue consistentlyin 82 of 839, across 41 files
- Change one variable at a timein 82 of 839, across 42 files
- Check recent changesin 74 of 839, across 36 files
- Write the regression test before fixingin 74 of 839, across 40 files
- Fix the root cause not the symptomin 60 of 839, across 45 files
- Implement a single fix at a timein 59 of 839, across 20 files
- Trace data flow backward to the sourcein 50 of 839, across 20 files
- Remove all debug instrumentationin 49 of 839, across 13 files
- Form a single hypothesisin 48 of 839, across 18 files
Said here and by no other author read
- Never auto-run this skill
- Never kill a root-owned process
- Never kill processes owned by another user
- Never kill protected system processes
- Read the persistent user profile
- Run diagnostics before mapping playbooks
Grouped from the skills themselves: near-identical wordings counted once, and counted by distinct author, so one author publishing three of these counts once. Length counted with cl100k_base; the agent that loads this file may tokenize it differently.