← 返回 Skills 市场
spyderjr

8004 Skill

作者 SpyderJR · GitHub ↗ · v1.0.1
cross-platform ⚠ suspicious
624
总下载
0
收藏
0
当前安装
2
版本数
在 OpenClaw 中安装
/install 8004-skill
功能描述
ERC-8004 Trustless Agents - Register and manage AI agent identities on TRON and BSC blockchains with on-chain reputation tracking
使用说明 (SKILL.md)

ERC-8004: Trustless Agents on TRON & BSC

On-chain identity, reputation, and validation for autonomous agents on TRON. Now live on TRON Mainnet + BSC Mainnet!

Overview

ERC-8004 provides three registries on TRON and BSC blockchains:

  • Identity Registry - TRC-721 agent identities with registration metadata
  • Reputation Registry - Signed feedback scores between agents/clients
  • Validation Registry - Independent verification (zkML, TEE, stakers)

Multi-Chain: Same protocol works on TRON and BSC (BNB Smart Chain) - both fully deployed!

Quick Reference

Register Agent

# TRON Mainnet
node scripts/register.js --uri "ipfs://..." --chain tron --network mainnet

# TRON Testnet
node scripts/register.js --uri "ipfs://..." --chain tron --network nile

# BSC Mainnet
node scripts/register.js --uri "ipfs://..." --chain bsc --network mainnet

# BSC Testnet
node scripts/register.js --uri "ipfs://..." --chain bsc --network testnet

# Register without URI (set later)
node scripts/register.js --chain tron --network nile

Private Key Setup

# Set once, works for both TRON and BSC
export TRON_PRIVATE_KEY="your_64_character_hex_private_key"

Networks

TRON Networks

Network Status Identity Registry Reputation Registry Validation Registry
Mainnet Live TFLvivMdKsk6v2GrwyD2apEr9dU1w7p7Fy TFbvfLDa4eFqNR5vy24nTrhgZ74HmQ6yat TLCWcW8Qmo7QMNoAKfBhGYfGpHkw1krUEm
Nile Live TDDk4vc69nzBCbsY4kfu7gw2jmvbinirj5 TBVaGd6mBuGuN5ebcvPvRaJo4rtEWqsW6Y TGGkHDHhBzhFcLNcEogAWJkvfFYy4jyrSw
Shasta Live TH775ZzfJ5V25EZkFuX6SkbAP53ykXTcma TTkds2ZZKBTChZHho4wcWAa7eWQTxh5TUT TQBFHtKRiaQjc1xp4LtmmXKYdA7JLN89w3

Note: TRON deployments implement TRC-8004 (TRON version of ERC-8004). Query scripts use compatibility mode:

  • ✅ Always available: ownerOf, tokenURI (ERC-721 standard)
  • ⚠️ May vary: agentURI, getAgentWallet, agentExists (ERC-8004 extensions)

BSC Networks

Network Status Identity Registry Reputation Registry Validation Registry
BSC Mainnet Live 0x8004A169FB4a3325136EB29fA0ceB6D2e539a432 0x8004BAa17C55a88189AE136b182e5fdA19dE9b63 0x8004Cc8439f36fd5F9F049D9fF86523Df6dAAB58
BSC Testnet Live 0x8004A818BFB912233c491871b3d84c89A494BD9e 0x8004B663056A597Dffe9eCcC1965A193B7388713 0x8004Cb1BF31DAf7788923b405b754f57acEB4272

Note: BSC deployments use full ERC-8004 specification with all standard methods.

Multi-Chain Usage:

# TRON
node scripts/register.js --uri "ipfs://..." --chain tron --network mainnet

# BSC
node scripts/register.js --uri "ipfs://..." --chain bsc --network mainnet

Contract addresses and ABIs in lib/contracts.json.

Registration File Format

{
  "type": "https://eips.ethereum.org/EIPS/eip-8004#registration-v1",
  "name": "your-agent-name",
  "description": "Agent description...",
  "image": "ipfs://...",
  "services": [
    { "name": "A2A", "endpoint": "https://agent.example/.well-known/agent-card.json", "version": "0.3.0" },
    { "name": "MCP", "endpoint": "https://mcp.agent.tron/", "version": "2025-06-18" }
  ],
  "registrations": [
    { "agentRegistry": "tron:728126428:TFLvivMdKsk6v2GrwyD2apEr9dU1w7p7Fy", "agentId": "1" }
  ],
  "supportedTrust": ["reputation", "crypto-economic", "tee-attestation"]
}

Template at templates/registration.json.

Reputation Scores

The reputation system uses signed fixed-point numbers (value + valueDecimals):

Tag Meaning Example value decimals
quality Quality (0-100) 87/100 87 0
uptime Uptime % 99.77% 9977 2
yield Yield % -3.2% -32 1
latency Latency ms 560ms 560 0

Trust Models

ERC-8004 supports three pluggable trust models:

  • Reputation-based - Client feedback with scores, tags, and metadata
  • Crypto-economic - Stake-secured validation with economic incentives
  • Crypto-verification - TEE attestations and zkML proofs

Dependencies

  • node & npm - JavaScript runtime and package manager
  • tronweb - TRON JavaScript SDK (npm install tronweb)
  • Private key configuration (choose one):
    • Environment variable: TRON_PRIVATE_KEY or PRIVATE_KEY
    • File: ~/.clawdbot/wallets/.deployer_pk
  • IPFS: Set PINATA_JWT for uploads, or upload manually

TRON-Specific Features

Address Format

  • TRON uses Base58 addresses starting with 'T' (e.g., TFLvivMdKsk6v2GrwyD2apEr9dU1w7p7Fy)
  • Scripts automatically handle address conversion

Network Identifiers

  • Mainnet: tron:728126428 (TRON chain ID)
  • Use in registration files: tron:728126428:TFLvivMdKsk6v2GrwyD2apEr9dU1w7p7Fy

Energy & Bandwidth

  • TRON uses Energy and Bandwidth instead of gas
  • Scripts set feeLimit: 1000000000 (1000 TRX max)
  • Actual costs are typically much lower

Resources

Official

TRON Resources

Ecosystem

Script Reference

All scripts support multi-chain (TRON + BSC):

  • register.js - Register new agent on-chain
  • query.js - Query agent info and reputation
  • feedback.js - Submit feedback/reputation scores
  • set-uri.js - Update agent metadata URI

Run any script without arguments to see detailed usage information.

Examples

Complete Agent Workflow

# 1. Set private key (works for both TRON and BSC)
export TRON_PRIVATE_KEY="your_private_key"

# 2. Register agent on TRON testnet
node scripts/register.js --uri "ipfs://QmYourHash" --chain tron --network nile

# 3. Query agent info (use ID from step 2)
node scripts/query.js agent 1 --chain tron --network nile

# 4. Submit feedback
node scripts/feedback.js --agent-id 1 --score 95 --tag1 "quality" --chain tron --network nile

# 5. Query reputation
node scripts/query.js reputation 1 --chain tron --network nile

# 6. Update URI if needed
node scripts/set-uri.js --agent-id 1 --uri "ipfs://QmNewHash" --chain tron --network nile

Multi-Chain Examples

# Register on BSC testnet
node scripts/register.js --uri "ipfs://..." --chain bsc --network testnet

# Query agent on BSC mainnet
node scripts/query.js agent 1 --chain bsc --network mainnet

# Submit feedback on TRON mainnet
node scripts/feedback.js --agent-id 1 --score 98 --tag1 "quality" --chain tron --network mainnet

Troubleshooting

"TRON_PRIVATE_KEY not set"

# Option 1: Environment variable (recommended)
export TRON_PRIVATE_KEY="your_64_character_hex_private_key"

# Option 2: File storage
mkdir -p ~/.clawdbot/wallets
echo "your_private_key" > ~/.clawdbot/wallets/.deployer_pk
chmod 600 ~/.clawdbot/wallets/.deployer_pk

"Insufficient balance"

  • Ensure your wallet has TRX for transaction fees
  • Get testnet TRX from Nile Faucet

"Not the owner"

  • Only the agent owner can update URI or metadata
  • Check ownership with query.js agent \x3Cid>

Security Notes

  • Never commit private keys to version control
  • Use environment variables for sensitive data
  • Test on Nile testnet before mainnet deployment
  • Verify contract addresses in lib/contracts.json

Compatible with ERC-8004 specification. TRON implementation is TRC-8004.

安全使用建议
This skill implements on-chain registration and reputation and legitimately needs a signing key to submit transactions — but the registry metadata incorrectly lists no required credentials while the scripts and SKILL.md require TRON_PRIVATE_KEY/PRIVATE_KEY or a private-key file (~/.clawdbot/wallets/.deployer_pk) and optionally a PINATA_JWT. Before installing or running: 1) Do not use your mainnet production private key — use a throwaway/test key or hardware wallet; 2) Prefer using temporary or testnet keys and funds for initial testing; 3) Inspect utils.js (getPrivateKeyOrExit) to see exactly how keys are read and whether they are stored or logged; 4) Confirm contract addresses independently (e.g., via tronscan / bscscan) before sending transactions; 5) If you need IPFS pinning, create a dedicated pinning token, not one shared with other services; 6) Run npm install and consider doing commands in an isolated environment (container or VM) and run npm audit; 7) If you cannot review the code or do not trust entering a raw private key, do not install — instead interact with contracts via a hardware wallet or a custody service. The main red flag is the metadata omission of required secrets and the hard-coded local key file path — treat this as a configuration/information coherence issue and proceed cautiously.
功能分析
Type: OpenClaw Skill Name: 8004-skill Version: 1.0.1 The skill bundle provides scripts and documentation for managing ERC-8004 agent identities, reputation, and validation on TRON and BSC blockchains. The code primarily involves interacting with smart contracts using `tronweb` and `ethers.js` libraries. Private keys are handled through environment variables (`TRON_PRIVATE_KEY`, `PRIVATE_KEY`) or a designated file (`~/.clawdbot/wallets/.deployer_pk`), with explicit security warnings in the documentation. There is no evidence of intentional harmful behavior such as data exfiltration, malicious execution of remote payloads, persistence mechanisms, or prompt injection attempts against the AI agent. All operations are clearly aligned with the stated purpose of blockchain interaction.
能力评估
Purpose & Capability
Name/description (ERC-8004 identity/reputation on TRON+BSC) align with the included JS scripts, ABIs, and contract addresses. However, the skill registry metadata declares no required env vars or credentials while the SKILL.md and scripts clearly require a signing private key (TRON_PRIVATE_KEY or PRIVATE_KEY) or a file at ~/.clawdbot/wallets/.deployer_pk and optionally PINATA_JWT — this mismatch is incoherent.
Instruction Scope
SKILL.md and scripts instruct the agent/user to load a private key (env var or file) and run node scripts that will sign and send transactions and may upload metadata to IPFS (Pinata). The runtime instructions therefore access sensitive secrets and a specific home-directory path; the skill also directs interactions with external RPC endpoints (TronGrid, BSC RPC). There are no instructions that read unrelated system files, but the explicit private-key file path and optional PINATA_JWT are outside what the registry metadata declared.
Install Mechanism
This is instruction-only from the registry perspective (no install spec), but the package includes code and a package.json that depends on tronweb and ethers. Users must run npm install themselves. No remote binary downloads or obscure URLs are used; dependencies are standard npm libs. This is moderate-risk (running arbitrary JS) but not anomalous for the stated purpose.
Credentials
The skill requires a wallet private key for signing transactions (TRON_PRIVATE_KEY / PRIVATE_KEY) or a local key file and optionally a PINATA_JWT for IPFS pinning. Those credentials are directly relevant to blockchain registration and thus proportionate to the feature — however they are not declared in the registry metadata (required env vars: none, primary credential: none), creating a dangerous gap: users may grant sensitive keys unintentionally. Requesting a plaintext private key or a file under ~/.clawdbot/wallets increases risk if users reuse production keys.
Persistence & Privilege
The skill does not request always:true and does not modify other skills or system-wide settings. It runs as scripts when invoked. There is no evidence it persists beyond its own files or tries to enable itself automatically.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install 8004-skill
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /8004-skill 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.1
- Added new file: `_meta.json` for metadata management. - No other changes to functionality or documentation.
v1.0.0
Initial release of ERC-8004 Trustless Agents with multi-chain support: - Launches agent registration and on-chain reputation for AI agents on TRON and BSC mainnets. - Provides three registries: Identity, Reputation, and Validation, deployed on both TRON and BSC networks. - Includes command line scripts for registering agents, querying info and reputation, submitting feedback, and updating metadata URI. - Supports three pluggable trust models: reputation-based, crypto-economic, and crypto-verification. - Offers detailed documentation on agent file format, reputation scoring, network specifics, and multi-chain workflows. - TRON and BSC compatibility with standard and custom methods; full contract addresses and example workflows provided.
元数据
Slug 8004-skill
版本 1.0.1
许可证
累计安装 2
当前安装数 0
历史版本数 2
常见问题

8004 Skill 是什么?

ERC-8004 Trustless Agents - Register and manage AI agent identities on TRON and BSC blockchains with on-chain reputation tracking. 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 624 次。

如何安装 8004 Skill?

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

8004 Skill 是免费的吗?

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

8004 Skill 支持哪些平台?

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

谁开发了 8004 Skill?

由 SpyderJR(@spyderjr)开发并维护,当前版本 v1.0.1。

💬 留言讨论