workspace-health-monitor
/install jpeng-workspace-health-monitor
Workspace Health Monitor
Performs comprehensive workspace health checks and generates actionable recommendations.
Usage
const monitor = require('./skills/workspace-health-monitor');
// Perform health check
const report = monitor.check('/path/to/workspace');
// Generate markdown report
console.log(monitor.generateReport(report));
API
check(workspacePath, options)
Performs comprehensive workspace health check.
Options:
largeFileThresholdMB(number): Size threshold for large files. Default:10includeEmptyDirs(boolean): Check for empty directories. Default:trueincludeLargeFiles(boolean): Check for large files. Default:true
Returns:
{
healthScore: number, // 0-100
status: 'healthy' | 'warning' | 'critical',
metrics: {
timestamp: string,
workspace: string,
diskUsage: {
totalSize: number,
totalSizeMB: number,
totalSizeFormatted: string
},
files: {
total: number,
directories: number
},
skills: {
total: number,
healthy: number,
broken: number,
missingIndex: string[],
missingSkillMd: string[],
missingPackage: string[]
},
largeFiles: [{ path, size, sizeFormatted }],
emptyDirs: string[],
fileTypes: { [extension]: count }
},
recommendations: [{
severity: 'high' | 'medium' | 'low' | 'info',
category: string,
message: string,
details?: string,
action: string
}]
}
checkSkillHealth(skillsDir)
Checks health of all skills in a directory.
findLargeFiles(workspacePath, thresholdMB)
Finds files larger than the threshold.
findEmptyDirectories(workspacePath)
Finds empty directories in the workspace.
generateReport(report)
Generates a markdown-formatted health report.
formatBytes(bytes)
Formats bytes to human-readable size.
Example Output
# Workspace Health Report
**Status:** ✅ HEALTHY (Score: 92/100)
**Timestamp:** 2026-03-27T04:30:00.000Z
## Disk Usage
- **Total Size:** 256.78 MB
- **Files:** 3,456
- **Directories:** 234
## Skills Health
- **Total Skills:** 150
- **Healthy:** 145
- **Broken:** 5
- **Missing index.js:** skill-a, skill-b, skill-c
## Large Files (>10MB)
- `logs/evolution.log` (45.23 MB)
- `data/cache.json` (23.45 MB)
## Recommendations
🔴 **skills**: 5 broken skill(s) found
- Missing index.js: skill-a, skill-b, skill-c
- Action: Fix or remove broken skills
🟡 **storage**: 2 large file(s) found (>10MB)
- logs/evolution.log (45.23 MB), data/cache.json (23.45 MB)
- Action: Consider archiving or removing large files
Health Score Calculation
The health score (0-100) is calculated based on:
- Broken skills: -30 points max for broken skill ratio
- Large files: -10 points for >10 large files
- Empty directories: -10 points for >20 empty directories
- Workspace size: -10 points for >1GB total size
Status Levels
- Healthy (80-100): Workspace is in good condition
- Warning (60-79): Some issues need attention
- Critical (0-59): Immediate action required
- 确保已安装 OpenClaw(本地或 Docker 部署)
- 在对话框中输入安装命令:
/install jpeng-workspace-health-monitor - 安装完成后,直接呼叫该 Skill 的名称或使用
/jpeng-workspace-health-monitor触发 - 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
workspace-health-monitor 是什么?
Performs comprehensive workspace health checks including disk usage, file counts, skill health, large files, and empty directories with actionable recommenda... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 111 次。
如何安装 workspace-health-monitor?
在 OpenClaw 或 Claude Code 对话框中运行命令「/install jpeng-workspace-health-monitor」即可一键安装,无需额外配置。
workspace-health-monitor 是免费的吗?
是的,workspace-health-monitor 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。
workspace-health-monitor 支持哪些平台?
workspace-health-monitor 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。
谁开发了 workspace-health-monitor?
由 jpengcheng523-netizen(@jpengcheng523-netizen)开发并维护,当前版本 v1.0.0。