← 返回 Skills 市场
nancyuahon

AI Mine

作者 nancyuahon · GitHub ↗ · v1.0.2
cross-platform ⚠ suspicious
1369
总下载
0
收藏
1
当前安装
3
版本数
在 OpenClaw 中安装
/install aimine
功能描述
Mine AIT (Proof of AI Work) on BNB Chain. Install, configure, start/stop mining entirely from OpenClaw. No terminal or manual file edits required.
使用说明 (SKILL.md)

AI Mine (PoAIW) — OpenClaw Skill

This skill lets users install, configure, and start/stop AIT mining entirely from OpenClaw. All actions are performed by the agent via Exec; the user never needs to open a terminal or edit files manually.

Supported user intents (English trigger phrases):

  • Install — e.g. "install AIT mining", "set up AIT miner", "install the miner"
  • Configure — e.g. "configure AIT mining", "configure mining", "set up my keys"
  • Start mining — e.g. "start mining", "start AIT mining", "begin mining"
  • Stop mining — e.g. "stop mining", "stop AIT mining"
  • Mining status — e.g. "mining status", "status", "how is mining doing"
  • Balance — e.g. "AIT balance", "check balance", "my AIT balance"

Conventions:

  • AIMINE_DIR: base directory for the repo; default ~/PoAIW. Miner directory is $AIMINE_DIR/miner.
  • Port for the miner web API: 3000 (localhost only).
  • Keys: user can set PRIVATE_KEY and either OPENAI_KEY or OPENAI_API_KEY in OpenClaw skill config (env injection), or provide them once in chat. The miner accepts both env var names for the OpenAI key. Then the agent runs init with those values.

When the user wants to INSTALL the miner

Run (use AIMINE_DIR if set, else default to $HOME/PoAIW):

AIMINE_DIR=${AIMINE_DIR:-$HOME/PoAIW}
[ -d "$AIMINE_DIR/.git" ] || git clone https://github.com/AIMineRes/PoAIW.git "$AIMINE_DIR"
cd "$AIMINE_DIR/miner" && npm install

Do not ask the user to open a terminal or run these manually.


When the user wants to CONFIGURE mining

The user must have provided wallet private key and OpenAI API key (either in OpenClaw skill config as PRIVATE_KEY and OPENAI_KEY or OPENAI_API_KEY, or in the conversation). If users get "invalid API key", have them check: no leading/trailing spaces, key starts with sk-, and if using OpenClaw config try setting OPENAI_API_KEY (some UIs use that name).

  • If keys are in environment (e.g. injected by OpenClaw skill config): run
    cd "$AIMINE_DIR/miner" && npx ts-node src/index.ts init --from-env
    (ensure AIMINE_DIR is set or use $HOME/PoAIW/miner).

  • If the user provided keys in the message: run
    cd "$AIMINE_DIR/miner" && npx ts-node src/index.ts init --private-key \x3Ckey> --openai-key \x3Ckey>
    using the keys they provided. Do not echo the keys back in full.

Do not ask the user to manually edit .env or openclaw.json.


When the user wants to START mining

Run the one-shot script so that the web server is started in the background if needed, then the API is called. Do not tell the user to "run npm run web first".

cd "${AIMINE_DIR:-$HOME/PoAIW}/miner" && node scripts/start-mining.js

If AIMINE_DIR is not set, use $HOME/PoAIW (or equivalent on the host). The script will start the web server on port 3000 if it is not already listening, wait a few seconds, then POST to http://127.0.0.1:3000/api/start.


When the user wants to STOP mining

Run:

curl -s -X POST http://127.0.0.1:3000/api/stop

When the user wants MINING STATUS

Run:

curl -s http://127.0.0.1:3000/api/status

Then summarize the JSON (miningActive, blocksMined, tokenBalance, bnbBalance, hashRate) in a short reply.


When the user wants AIT BALANCE (wallet / mining stats)

Run:

cd "${AIMINE_DIR:-$HOME/PoAIW}/miner" && npx ts-node src/index.ts balance

Summarize the output for the user.


Summary

  • Install: clone repo into AIMINE_DIR (default ~/PoAIW), then cd miner && npm install.
  • Configure: ai-mine init --from-env (if keys in env) or ai-mine init --private-key ... --openai-key ... (if user gave keys in chat).
  • Start: node scripts/start-mining.js in the miner directory (no need for user to run npm run web).
  • Stop: curl -s -X POST http://127.0.0.1:3000/api/stop.
  • Status: curl -s http://127.0.0.1:3000/api/status.
  • Balance: npx ts-node src/index.ts balance in the miner directory.

Always use the miner directory as $AIMINE_DIR/miner with AIMINE_DIR defaulting to ~/PoAIW when not set.

安全使用建议
This skill could do exactly what it says, but it also has clear risk factors. Before installing: (1) Do NOT paste your main wallet private key into chat — use a throwaway wallet with minimal funds if you want to test. (2) Prefer injecting secrets via the platform's secure config (not inline messages or CLI args); avoid passing keys as command-line arguments. (3) Review and pin the GitHub repository and commit/tag you will install, or audit the repo code for network exfiltration and key-handling behavior. (4) If you must run it, do so in an isolated environment (VM or container) and monitor outbound network traffic. (5) Use a restricted OpenAI key (or billing-limited project) rather than a high-privilege key. (6) If you are not able to audit the repository and accept these risks, do not install it.
功能分析
Type: OpenClaw Skill Name: aimine Version: 1.0.2 The skill is classified as suspicious due to its handling of highly sensitive credentials (PRIVATE_KEY, OPENAI_KEY) and its reliance on `git clone` and `npm install` from a remote GitHub repository (github.com/AIMineRes/PoAIW.git) in SKILL.md. This introduces significant supply chain risk, as the agent downloads and executes arbitrary code from an external source, which could be compromised. While the stated purpose is cryptocurrency mining, the mechanisms used present a high-risk attack surface, even though there are no explicit instructions within SKILL.md for intentional malicious actions like data exfiltration to external endpoints or persistence.
能力评估
Purpose & Capability
Requiring node, npm, and git matches a Node.js miner installer. Requesting a wallet PRIVATE_KEY is consistent with mining payouts. However, the SKILL.md also requires an OpenAI API key (OPENAI_KEY / OPENAI_API_KEY) which is not declared in the skill's top-level required envs, creating an inconsistency between metadata and instructions.
Instruction Scope
Instructions direct the agent to git clone a remote repo, run npm install, execute scripts, and run CLI commands that accept sensitive keys (including passing the private key and OpenAI key on the command line). There is no step to verify or pin the repository contents. Running those commands gives the cloned code broad freedom (filesystem, network, process execution) and the instructions permit accepting secrets via chat, which risks exfiltration.
Install Mechanism
No formal install spec is provided; the agent will git-clone https://github.com/AIMineRes/PoAIW.git and run npm install. While GitHub is a standard host, the repo is unpinned (no commit/tag/release verification) and the agent will execute its code on the user's machine. That is a high-risk pattern unless the repo is audited or pinned.
Credentials
The skill declares PRIMARY_ENV PRIVATE_KEY (appropriate), but it also requires an OpenAI API key (OPENAI_KEY/OPENAI_API_KEY) in practice while not listing it in required envs. Asking for a wallet private key and an OpenAI API key is proportionate to a PoAIW miner only if the code is trusted; passing these secrets via CLI arguments or chat is risky because arguments can be visible to other processes and chat transcripts may be stored.
Persistence & Privilege
Although always:false, the skill instructs the agent to create a directory under the user's home, install node modules, and run a background web server — persistent changes to disk and long‑running processes. Combined with the sensitive keys above and unverified code, this increases the potential blast radius.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install aimine
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /aimine 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.2
- Added support for both OPENAI_KEY and OPENAI_API_KEY environment variable names for the OpenAI API key. - Updated configuration instructions and troubleshooting tips regarding invalid OpenAI API keys. - No changes to functional logic or code; documentation clarifications only.
v1.0.1
- Updated supported user intents to only include English trigger phrases (removed Chinese). - Clarified intent examples to be English-only throughout the documentation. - No changes to the core logic or command instructions. - Improved intent phrase guidance for user queries.
v1.0.0
- Initial release of the aimine skill for OpenClaw. - Install, configure, start, and stop AIT mining entirely through OpenClaw with no manual terminal or file editing required. - Supports user intents for installing, configuring, starting/stopping mining, checking status, and viewing AIT balance in both English and Chinese. - Manages all miner commands using Exec, handling repo setup, environment variables, and script execution automatically. - Ensures secure handling of private keys and API keys via OpenClaw config or user input without exposing sensitive data.
元数据
Slug aimine
版本 1.0.2
许可证
累计安装 1
当前安装数 1
历史版本数 3
常见问题

AI Mine 是什么?

Mine AIT (Proof of AI Work) on BNB Chain. Install, configure, start/stop mining entirely from OpenClaw. No terminal or manual file edits required. 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 1369 次。

如何安装 AI Mine?

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

AI Mine 是免费的吗?

是的,AI Mine 完全免费(开源免费),可自由下载、安装和使用。

AI Mine 支持哪些平台?

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

谁开发了 AI Mine?

由 nancyuahon(@nancyuahon)开发并维护,当前版本 v1.0.2。

💬 留言讨论