/ 目录 / 演练场 / aelf-skills
● 社区 AElfProject ⚡ 即开即用

aelf-skills

作者 AElfProject · AElfProject/aelf-skills

Unified aelf blockchain skills hub — discovery, routing, bootstrap, and health checks across Claude Code, Cursor, Codex, and OpenClaw.

aelf-skills is the official aelf (a Chinese-origin blockchain platform) skills hub. Acts as a router: discovers which sub-skill matches a task (smart contract dev, dApp scaffolding, testnet interactions), bootstraps environments, and runs health checks. Good for devs building on aelf who want a consistent cross-agent experience.

为什么要用

核心特性

实时演示

实际使用效果

aelf-skill.replay ▶ 就绪
0/0

安装

选择你的客户端

~/Library/Application Support/Claude/claude_desktop_config.json  · Windows: %APPDATA%\Claude\claude_desktop_config.json
{
  "mcpServers": {
    "aelf-skill": {
      "command": "git",
      "args": [
        "clone",
        "https://github.com/AElfProject/aelf-skills",
        "~/.claude/skills/aelf-skills"
      ],
      "_inferred": true
    }
  }
}

打开 Claude Desktop → Settings → Developer → Edit Config。保存后重启应用。

~/.cursor/mcp.json · .cursor/mcp.json
{
  "mcpServers": {
    "aelf-skill": {
      "command": "git",
      "args": [
        "clone",
        "https://github.com/AElfProject/aelf-skills",
        "~/.claude/skills/aelf-skills"
      ],
      "_inferred": true
    }
  }
}

Cursor 使用与 Claude Desktop 相同的 mcpServers 格式。项目级配置优先于全局。

VS Code → Cline → MCP Servers → Edit
{
  "mcpServers": {
    "aelf-skill": {
      "command": "git",
      "args": [
        "clone",
        "https://github.com/AElfProject/aelf-skills",
        "~/.claude/skills/aelf-skills"
      ],
      "_inferred": true
    }
  }
}

点击 Cline 侧栏中的 MCP Servers 图标,然后选 "Edit Configuration"。

~/.codeium/windsurf/mcp_config.json
{
  "mcpServers": {
    "aelf-skill": {
      "command": "git",
      "args": [
        "clone",
        "https://github.com/AElfProject/aelf-skills",
        "~/.claude/skills/aelf-skills"
      ],
      "_inferred": true
    }
  }
}

格式与 Claude Desktop 相同。重启 Windsurf 生效。

~/.continue/config.json
{
  "mcpServers": [
    {
      "name": "aelf-skill",
      "command": "git",
      "args": [
        "clone",
        "https://github.com/AElfProject/aelf-skills",
        "~/.claude/skills/aelf-skills"
      ]
    }
  ]
}

Continue 使用服务器对象数组,而非映射。

~/.config/zed/settings.json
{
  "context_servers": {
    "aelf-skill": {
      "command": {
        "path": "git",
        "args": [
          "clone",
          "https://github.com/AElfProject/aelf-skills",
          "~/.claude/skills/aelf-skills"
        ]
      }
    }
  }
}

加入 context_servers。Zed 保存后热重载。

claude mcp add aelf-skill -- git clone https://github.com/AElfProject/aelf-skills ~/.claude/skills/aelf-skills

一行命令搞定。用 claude mcp list 验证,claude mcp remove 卸载。

使用场景

实战用法: aelf-skills

How to bootstrap a local aelf dev environment

👤 Developers new to aelf wanting a working local chain ⏱ ~30 min intermediate

何时使用: You just decided to build on aelf and have nothing set up.

前置条件
  • Skill installed — git clone https://github.com/AElfProject/aelf-skills ~/.claude/skills/aelf-skills
  • .NET 6+ — Required for aelf SDK
步骤
  1. Bootstrap
    Use aelf-skills bootstrap. Set up aelf CLI, local node, and a test wallet.✓ 已复制
    → Chain running, wallet created, addresses echoed
  2. Health check
    Run aelf-skills health. Confirm node, wallet balance, and RPC.✓ 已复制
    → Green checks on each component

结果: A local aelf dev environment ready for contract work.

注意事项
  • Port collisions if you've run other chains — Skill surfaces the port map and proposes free ports

Scaffold a C# aelf smart contract

👤 Developers writing their first aelf contract ⏱ ~90 min advanced

何时使用: You've done Ethereum/Solidity and want the aelf equivalent.

步骤
  1. Scaffold
    Scaffold a token contract in C# for aelf: transfer, balanceOf, approve, transferFrom.✓ 已复制
    → Project with proto + contract class
  2. Deploy to local
    Deploy to local dev chain, return the contract address.✓ 已复制
    → Address + first transaction hash
  3. Test
    Write and run a minimal test that calls transfer and asserts balances.✓ 已复制
    → Test passes

结果: A deployed and tested contract on your local aelf chain.

Discover which aelf sub-skill handles your task

👤 Anyone unsure which aelf skill to invoke ⏱ ~5 min beginner

何时使用: You know what you want to do; you don't know which skill does it.

步骤
  1. Ask the hub
    I want to send an aelf transaction from a dApp frontend. Which aelf sub-skill?✓ 已复制
    → Sub-skill name + why

结果: Right skill loaded for the task.

组合

与其他 MCP 搭配,撬动十倍杠杆

aelf-skill + github

Search aelf SDK examples on GitHub then use aelf-skills to scaffold a contract based on found patterns

Search AElfProject org on GitHub for token contract examples, then use aelf-skills to scaffold a similar contract locally.✓ 已复制
aelf-skill + filesystem

Read existing C# contract code locally and use aelf-skills to add tests and deploy

Read my contract in ~/projects/aelf-token/src/, then use aelf-skills to write tests and deploy to local dev chain.✓ 已复制

工具

此 MCP 暴露的能力

工具输入参数何时调用成本
bootstrap - First-time setup 0
health - Troubleshooting 0
route task description Task discovery Claude tokens
Contract scaffolding - New contract dev Claude tokens

成本与限制

运行它的成本

API 配额
None at skill level
每次调用 Token 数
5-20k per task
费用
Free skill; testnet interactions are free
提示
Run health checks before any real operation to avoid debugging token-wasted sessions.

安全

权限、密钥、影响范围

凭据存储: aelf wallet private key in local config. Never paste into prompts.
数据出站: RPC calls to local node or configured aelf endpoint

故障排查

常见错误与修复

aelf CLI install fails

Check .NET version; aelf SDK targets specific .NET releases

验证: dotnet --version
Local node not responding

Run health check; common causes: port conflict or not enough disk for chaindata

Contract deployment fails with protobuf error

Ensure your .proto files match the aelf SDK version; regenerate stubs with the correct protoc plugin

验证: dotnet build — check for protobuf warnings

替代方案

aelf-skills 对比其他方案

替代方案何时用它替代权衡
aelf docs + CLI directlyYou prefer reading docs and scripting yourselfSlower ramp-up

更多

资源

📖 阅读 GitHub 上的官方 README

🐙 查看未解决的 issue

🔍 浏览全部 400+ MCP 服务器和 Skills