PC Assistant - Healthcheck Skill
Overview
This skill runs a comprehensive PC healthcheck that provides detailed system information along with actionable recommendations to fix any issues found. Supports Windows, macOS, and Linux.
When to Use
- - User asks for a "PC healthcheck", "system check", or "diagnostics"
- User wants to check storage, CPU, memory, GPU, or network
- User asks "how is my PC doing?" or "is everything ok?"
- User needs specific recommendations to fix issues (like low disk space)
Requirements
- - Platform: Windows, macOS, or Linux (including WSL)
- Permissions: Read-only for most checks
- Tools used: Platform-specific system utilities
Execute Healthcheck
The skill automatically detects your OS and runs the appropriate script:
CODEBLOCK0
Or use the convenience wrapper (auto-detects OS):
CODEBLOCK1
The script outputs:
- -
healthcheck_YYYYMMDD_HHMMSS.txt - Full human-readable report with recommendations - INLINECODE1 - JSON summary
Platform-Specific Features
Linux/WSL
- - System overview (OS, kernel, uptime)
- Storage & disk (df, partitions, SMART)
- Network (interfaces, routes, DNS, ports)
- Processes & services (systemctl)
- Users & security (SSH keys, failed logins)
- Package management (apt, npm, pip)
- Containers (Docker, Podman)
- GPU info (nvidia-smi)
- Hardware (USB, PCI, temperature)
Windows (PowerShell)
- - System overview (Win32OperatingSystem)
- CPU & memory (Win32Processor, Win32OperatingSystem)
- Storage (Win32LogicalDisk)
- Network adapters
- Processes (Get-Process)
- Services (Get-Service)
- Installed software (registry)
- Security (Firewall, Windows Defender)
- Event logs
macOS
- - System overview (swvers, systemprofiler)
- CPU & memory (vm_stat, sysctl)
- Storage (diskutil)
- Network (ifconfig, airport)
- Processes (ps)
- Launch agents & daemons
- Security (Firewall, Gatekeeper, FileVault)
- Homebrew packages
- Battery status
What the Healthcheck Captures
| Section | Information |
|---|
| System Overview | OS, kernel, uptime, user, shell |
| CPU |
Model, cores, speed, usage |
|
Memory | Total, free, used, percentage |
|
Storage | Disk usage, partitions, SMART status |
|
Network | Interfaces, IP addresses, DNS |
|
Processes | Top CPU/memory consumers |
|
Services | Running/stopped services |
|
Security | Firewall, antivirus status |
|
Software | Installed packages & apps |
|
Hardware | GPU, USB, temperature |
|
Summary | Health score + recommendations |
Recommendations Included
The report automatically includes specific recommendations when issues are detected:
Storage Issues (High disk usage)
- - Specific folders to check
- Platform-specific cleanup instructions
- Docker/container cleanup commands
Memory Issues
- - How to free up RAM
- Which apps to close
General Maintenance
- - System update commands
- Security best practices
Scheduling (Cron Jobs)
The skill includes a scheduler script for automated periodic healthchecks:
Quick Start
CODEBLOCK2
Configuration Options
Create a config file at ~/.config/pc-assistant.conf:
CODEBLOCK3
Environment Variables
| Variable | Default | Description |
|---|
| INLINECODE3 | INLINECODE4 | Where to save reports |
| INLINECODE5 |
HealthCheck | Filename prefix |
|
PC_ASSISTANT_KEEP_DAYS |
30 | Days to keep reports |
|
PC_ASSISTANT_CLEANUP |
false | Auto-delete old reports |
|
PC_ASSISTANT_CONFIG |
~/.config/pc-assistant.conf | Config file path |
Cron Job Example
CODEBLOCK4
Output
Reports are saved to:
- - Linux/WSL:
/tmp/pc-healthcheck/ (or custom via config) - Windows:
$env:TEMP\pc-healthcheck\ (usually C:\Users\...\AppData\Local\Temp\pc-healthcheck\) - macOS: INLINECODE16
When using scheduler: HealthCheck_YYYYMMDD_HHMMSS.txt and INLINECODE18
Tips
- - The script is read-only and safe to run multiple times
- Reports are timestamped for historical tracking
- Use JSON output for integration with monitoring
- Set
PC_ASSISTANT_CLEANUP=true to auto-remove old reports
PC助手 - 健康检查技能
概述
该技能运行全面的PC健康检查,提供详细的系统信息以及可操作的建议来修复发现的问题。支持Windows、macOS和Linux。
使用场景
- - 用户要求进行PC健康检查、系统检查或诊断
- 用户想要检查存储、CPU、内存、GPU或网络
- 用户询问我的PC状态如何?或一切正常吗?
- 用户需要针对问题(如磁盘空间不足)的具体建议
要求
- - 平台:Windows、macOS或Linux(包括WSL)
- 权限:大多数检查为只读权限
- 使用的工具:平台特定的系统工具
执行健康检查
该技能会自动检测您的操作系统并运行相应的脚本:
bash
~/.npm-global/lib/node_modules/openclaw/skills/pc-assistant/scripts/healthcheck.sh # Linux/WSL
~/.npm-global/lib/node_modules/openclaw/skills/pc-assistant/scripts/healthcheck.ps1 # Windows
~/.npm-global/lib/node_modules/openclaw/skills/pc-assistant/scripts/healthcheck.command # macOS
或使用便捷包装器(自动检测操作系统):
bash
~/.npm-global/lib/node_modules/openclaw/skills/pc-assistant/scripts/run.sh
脚本输出:
- - healthcheckYYYYMMDDHHMMSS.txt - 包含建议的完整可读报告
- healthcheckYYYYMMDDHHMMSS.json - JSON摘要
平台特定功能
Linux/WSL
- - 系统概览(操作系统、内核、运行时间)
- 存储与磁盘(df、分区、SMART)
- 网络(接口、路由、DNS、端口)
- 进程与服务(systemctl)
- 用户与安全(SSH密钥、登录失败记录)
- 包管理(apt、npm、pip)
- 容器(Docker、Podman)
- GPU信息(nvidia-smi)
- 硬件(USB、PCI、温度)
Windows(PowerShell)
- - 系统概览(Win32OperatingSystem)
- CPU与内存(Win32Processor、Win32OperatingSystem)
- 存储(Win32LogicalDisk)
- 网络适配器
- 进程(Get-Process)
- 服务(Get-Service)
- 已安装软件(注册表)
- 安全(防火墙、Windows Defender)
- 事件日志
macOS
- - 系统概览(swvers、systemprofiler)
- CPU与内存(vm_stat、sysctl)
- 存储(diskutil)
- 网络(ifconfig、airport)
- 进程(ps)
- 启动代理与守护进程
- 安全(防火墙、Gatekeeper、FileVault)
- Homebrew包
- 电池状态
健康检查捕获内容
| 部分 | 信息 |
|---|
| 系统概览 | 操作系统、内核、运行时间、用户、Shell |
| CPU |
型号、核心数、速度、使用率 |
|
内存 | 总量、空闲、已用、百分比 |
|
存储 | 磁盘使用情况、分区、SMART状态 |
|
网络 | 接口、IP地址、DNS |
|
进程 | CPU/内存消耗最高的进程 |
|
服务 | 运行/停止的服务 |
|
安全 | 防火墙、防病毒状态 |
|
软件 | 已安装的包和应用程序 |
|
硬件 | GPU、USB、温度 |
|
摘要 | 健康评分 + 建议 |
包含的建议
报告在检测到问题时自动包含具体建议:
存储问题(磁盘使用率高)
- - 需要检查的具体文件夹
- 平台特定的清理说明
- Docker/容器清理命令
内存问题
常规维护
计划任务(Cron作业)
该技能包含一个调度器脚本,用于自动定期健康检查:
快速开始
bash
使用默认设置运行(保存到 /tmp/pc-healthcheck-reports)
~/.npm-global/lib/node_modules/openclaw/skills/pc-assistant/scripts/schedule.sh
自定义输出文件夹
PC
ASSISTANTOUTPUT_DIR=$HOME/Downloads/pc-assistant reports \
~/.npm-global/lib/node_modules/openclaw/skills/pc-assistant/scripts/schedule.sh
配置选项
在 ~/.config/pc-assistant.conf 创建配置文件:
bash
报告输出目录
PC
ASSISTANTOUTPUT_DIR=$HOME/Downloads/pc-assistant reports
报告文件名前缀
PC
ASSISTANTREPORT_PREFIX=HealthCheck
保留旧报告的天数(默认:30)
PC
ASSISTANTKEEP_DAYS=30
启用自动清理旧报告
PC
ASSISTANTCLEANUP=true
环境变量
| 变量 | 默认值 | 描述 |
|---|
| PCASSISTANTOUTPUTDIR | /tmp/pc-healthcheck-reports | 报告保存位置 |
| PCASSISTANTREPORTPREFIX |
HealthCheck | 文件名前缀 |
| PC
ASSISTANTKEEP_DAYS | 30 | 保留报告的天数 |
| PC
ASSISTANTCLEANUP | false | 自动删除旧报告 |
| PC
ASSISTANTCONFIG | ~/.config/pc-assistant.conf | 配置文件路径 |
Cron作业示例
bash
添加到crontab(每天午夜运行)
0 0
* PC
ASSISTANTOUTPUT_DIR=$HOME/Downloads/pc-assistant reports \
~/.npm-global/lib/node_modules/openclaw/skills/pc-assistant/scripts/schedule.sh
输出
报告保存到:
- - Linux/WSL:/tmp/pc-healthcheck/(或通过配置自定义)
- Windows:$env:TEMP\pc-healthcheck\(通常为 C:\Users\...\AppData\Local\Temp\pc-healthcheck\)
- macOS:/tmp/pc-healthcheck/
使用调度器时:HealthCheckYYYYMMDDHHMMSS.txt 和 .json
提示
- - 脚本为只读,可安全多次运行
- 报告带有时间戳,便于历史追踪
- 使用JSON输出与监控系统集成
- 设置 PCASSISTANTCLEANUP=true 以自动删除旧报告