← 返回 Skills 市场
larry-at

Healthcheck Local

作者 Larry-at · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ suspicious
125
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install healthcheck-local
功能描述
Track water and sleep with JSON file storage
使用说明 (SKILL.md)

Health Tracker

Simple tracking for water intake and sleep using JSON file.

Data Format

File: {baseDir}/health-data.json

{
  "water": [{"time": "ISO8601", "cups": 2}],
  "sleep": [{"time": "ISO8601", "action": "sleep|wake"}]
}

Add Water Record

When user says "uống X cốc" or "uống nước X cốc":

node -e "const fs=require('fs');const f='{baseDir}/health-data.json';let d={water:[],sleep:[]};try{d=JSON.parse(fs.readFileSync(f))}catch(e){}d.water.push({time:new Date().toISOString(),cups:CUPS});fs.writeFileSync(f,JSON.stringify(d));console.log('Da ghi: '+CUPS+' coc')"

Replace CUPS with number from user input.

Add Sleep Record

When user says "đi ngủ":

node -e "const fs=require('fs');const f='{baseDir}/health-data.json';let d={water:[],sleep:[]};try{d=JSON.parse(fs.readFileSync(f))}catch(e){}d.sleep.push({time:new Date().toISOString(),action:'sleep'});fs.writeFileSync(f,JSON.stringify(d));console.log('Da ghi: di ngu')"

Add Wake Record

When user says "thức dậy" or "dậy rồi":

node -e "const fs=require('fs');const f='{baseDir}/health-data.json';let d={water:[],sleep:[]};try{d=JSON.parse(fs.readFileSync(f))}catch(e){}const last=d.sleep.filter(s=>s.action==='sleep').pop();d.sleep.push({time:new Date().toISOString(),action:'wake'});fs.writeFileSync(f,JSON.stringify(d));if(last){const h=((new Date()-new Date(last.time))/3600000).toFixed(1);console.log('Da ngu: '+h+' gio')}else{console.log('Da ghi: thuc day')}"

View Stats

When user says "thống kê" or "xem thống kê":

node -e "const fs=require('fs');const f='{baseDir}/health-data.json';let d={water:[],sleep:[]};try{d=JSON.parse(fs.readFileSync(f))}catch(e){}console.log('Water:',d.water.length,'records');console.log('Sleep:',d.sleep.length,'records');const today=d.water.filter(w=>new Date(w.time).toDateString()===new Date().toDateString());console.log('Today:',today.reduce((s,w)=>s+w.cups,0),'cups')"

Update Record

To update last water entry:

node -e "const fs=require('fs');const f='{baseDir}/health-data.json';let d=JSON.parse(fs.readFileSync(f));d.water[d.water.length-1].cups=NEW_CUPS;fs.writeFileSync(f,JSON.stringify(d));console.log('Updated')"

Delete Record

To delete last water entry:

node -e "const fs=require('fs');const f='{baseDir}/health-data.json';let d=JSON.parse(fs.readFileSync(f));d.water.pop();fs.writeFileSync(f,JSON.stringify(d));console.log('Deleted')"

Notes

  • Uses Node.js built-in modules only
  • File auto-created if missing
  • All timestamps in ISO8601 format
安全使用建议
This skill appears to be a simple local health tracker, but check these issues before installing: - Node requirement: SKILL.md runs node -e commands but the manifest does not declare Node as a required binary. Ensure your agent environment provides a trusted node binary or update the skill to declare it. - Metadata mismatch: ownerId/version in _meta.json differs from the registry metadata — verify the source/author before trusting the skill. - File writes: the skill will create/modify {baseDir}/health-data.json. Confirm what {baseDir} maps to and whether the agent should have write access there. - Code-injection risk: the instructions interpolate user input (CUPS, NEW_CUPS) directly into node -e strings. If those values are not strictly validated/escaped, a malicious value can execute arbitrary JS on the host. Prefer safer patterns: a small on-disk Node script that reads numeric args (parseInt) and validates them, or use an API that avoids inline code evaluation. - If you still want to use it: (1) confirm Node is trusted, (2) replace node -e one-liners with a safe script that validates inputs, (3) restrict file permissions and directory location for health-data.json, and (4) verify the skill author identity given the metadata inconsistencies.
功能分析
Type: OpenClaw Skill Name: healthcheck-local Version: 1.0.0 The skill implements health tracking by executing inline Node.js scripts via shell commands (`node -e`) to manage a local JSON file. While the logic in `SKILL.md` is aligned with the stated purpose, the instructions rely on direct string replacement of user-provided values (e.g., `CUPS`, `NEW_CUPS`) into the shell command, creating a high risk of command injection if the agent does not properly sanitize the input.
能力评估
Purpose & Capability
The skill claims to track water and sleep using a JSON file, which is coherent with the instructions. However, SKILL.md commands require Node.js on PATH (they use node -e) and read/write {baseDir}/health-data.json, yet the declared requirements list no required binaries or config paths. Also _meta.json ownerId/version differ from the registry metadata (owner/version mismatch), which is an inconsistency in package metadata.
Instruction Scope
Instructions instruct the agent to run inline NodeJS one-liners that read and write a file under {baseDir}. User-supplied values (CUPS, NEW_CUPS) are interpolated directly into code passed to node -e without escaping or validation, creating a code-injection / arbitrary-execution risk. The skill will also create and modify files in the agent's filesystem ({baseDir}/health-data.json), which is not declared elsewhere in the manifest.
Install Mechanism
Instruction-only skill with no install spec and no external downloads; this is low install risk. Nothing is written to disk by an installer step. The runtime commands themselves write to a JSON file, but that's part of the skill behavior rather than an install step.
Credentials
The skill requests no environment variables or credentials and the SKILL.md does not reference any env vars. That is proportionate to a local, file-based tracker. Note: it implicitly requires filesystem write permission for {baseDir} and the presence of node, which are not declared.
Persistence & Privilege
The skill is not force-enabled (always:false) and uses default autonomous invocation. It writes a local JSON file and modifies it over time; this local persistence is expected for a tracker but does require filesystem access. Autonomous invocation combined with the code-injection risk increases potential impact.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install healthcheck-local
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /healthcheck-local 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
- Initial release of healthcheck skill for tracking water intake and sleep. - Stores data in a local JSON file using Node.js only. - Supports adding, updating, and deleting water records. - Records sleep and wake events and calculates sleep duration. - Provides simple statistics on water and sleep records.
元数据
Slug healthcheck-local
版本 1.0.0
许可证 MIT-0
累计安装 1
当前安装数 0
历史版本数 1
常见问题

Healthcheck Local 是什么?

Track water and sleep with JSON file storage. 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 125 次。

如何安装 Healthcheck Local?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install healthcheck-local」即可一键安装,无需额外配置。

Healthcheck Local 是免费的吗?

是的,Healthcheck Local 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

Healthcheck Local 支持哪些平台?

Healthcheck Local 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 Healthcheck Local?

由 Larry-at(@larry-at)开发并维护,当前版本 v1.0.0。

💬 留言讨论