← 返回 Skills 市场
stevojarvisai-star

Agent Trading Bot

作者 stevojarvisai-star · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ suspicious
153
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install agent-trading-bot
功能描述
AI-powered trading bot framework for OpenClaw. Connects to crypto exchanges (Binance, Hyperliquid, Bluefin) and prediction markets (Polymarket, Kalshi) via A...
使用说明 (SKILL.md)

Agent Trading Bot

AI-powered trading framework for OpenClaw. Connect to exchanges, manage risk, execute strategies.

Quick Start

# Check exchange connectivity (no trades)
python3 scripts/agent-trading-bot.py status

# Paper trade (simulated) with a strategy
python3 scripts/agent-trading-bot.py paper --strategy dca --pair BTC/USDT

# Live trade (requires API keys configured)
python3 scripts/agent-trading-bot.py trade --strategy dca --pair BTC/USDT --amount 100

# Risk dashboard — current positions, exposure, P&L
python3 scripts/agent-trading-bot.py risk

# Kill switch — close all positions immediately
python3 scripts/agent-trading-bot.py kill

⚠️ Safety First

This skill includes multiple safety layers:

  1. Paper trading mode by default — no real money until explicitly enabled
  2. Maximum position size limits (configurable)
  3. Stop-loss on every position (default: 5%)
  4. Maximum drawdown circuit breaker (default: 10% of portfolio)
  5. Kill switch to close all positions instantly
  6. API keys never stored in skill files — environment variables only

The agent never trades without explicit user approval for live mode.

Commands

status — Exchange Connectivity Check

Tests API connections without trading:

  • Verifies API key validity
  • Checks account balances
  • Reports exchange status (maintenance, rate limits)
  • Shows available trading pairs

paper — Paper Trading (Simulated)

Runs strategy with fake money to test before going live:

  • Simulates order execution at market prices
  • Tracks P&L, win rate, Sharpe ratio
  • Logs every trade decision with reasoning
  • Options: --strategy, --pair, --duration, --capital

trade — Live Trading

Executes strategy with real funds:

  • Requires explicit --live flag (double confirmation)
  • All safety limits enforced
  • Every trade logged with timestamp, reasoning, and fills
  • Options: --strategy, --pair, --amount, --live

risk — Risk Dashboard

Real-time risk overview:

  • Open positions with unrealized P&L
  • Portfolio exposure by asset
  • Current drawdown vs maximum allowed
  • Margin utilization (for futures)
  • Daily/weekly/monthly P&L

kill — Emergency Kill Switch

Immediately closes all open positions:

  • Market sells all spot positions
  • Closes all futures positions
  • Cancels all pending orders
  • Logs everything
  • Requires confirmation unless --force flag

backtest — Strategy Backtesting

Test a strategy against historical data:

  • Options: --strategy, --pair, --start, --end
  • Reports: total return, max drawdown, Sharpe ratio, win rate

Strategies

Built-in Strategies

Strategy Description Risk Level
dca Dollar-Cost Average — buy fixed amount at intervals Low
grid Grid trading — buy low, sell high in a price range Medium
momentum Trend following with moving average crossovers Medium
funding Funding rate arbitrage (perpetual futures) Medium
mean-revert Buy oversold, sell overbought (RSI-based) High

See references/strategies.md for detailed strategy documentation.

Custom Strategies

Create a strategy file at strategies/\x3Cname>.json:

{
  "name": "my-strategy",
  "entry": { "indicator": "rsi", "condition": "below", "value": 30 },
  "exit": { "indicator": "rsi", "condition": "above", "value": 70 },
  "risk": { "stop_loss_pct": 3, "take_profit_pct": 9, "max_position_pct": 5 }
}

Configuration

Set exchange API keys via environment variables:

export BINANCE_API_KEY="your-key"
export BINANCE_API_SECRET="your-secret"
export HYPERLIQUID_API_KEY="your-key"
export HYPERLIQUID_API_SECRET="your-secret"

Risk limits in ~/.openclaw/trading-config.json:

{
  "max_position_pct": 10,
  "max_drawdown_pct": 10,
  "default_stop_loss_pct": 5,
  "max_daily_trades": 20,
  "allowed_pairs": ["BTC/USDT", "ETH/USDT", "SOL/USDT"]
}
安全使用建议
This package largely behaves like a trading bot, but it has important metadata mismatches you should not ignore: the registry declares no required env vars while the SKILL.md and code clearly expect exchange API keys and write config/log files under ~/.openclaw. Before using with real funds: 1) Review the full script (including the truncated parts) to confirm there are no hidden endpoints or surprising behavior. 2) Use API keys with the minimum permissions required (disable withdrawals, restrict IPs if possible), or use exchange testnet keys first. 3) Test thoroughly in paper mode only and validate the kill-switch works. 4) Inspect/backup or sandbox the ~/.openclaw directory the skill will create. 5) Ask the publisher to update registry metadata to declare required env vars and config paths — the current omission is a red flag. If you cannot audit the remaining code, avoid giving it live-trading credentials.
功能分析
Type: OpenClaw Skill Name: agent-trading-bot Version: 1.0.0 The skill is a well-structured trading bot framework that aligns with its stated purpose. It includes safety features such as paper trading by default, risk management limits (max drawdown, position sizing), and an emergency kill switch. The code in `scripts/agent-trading-bot.py` handles API keys via environment variables and communicates only with legitimate exchange endpoints (Binance/Hyperliquid) using standard HMAC-SHA256 signing. No evidence of data exfiltration, unauthorized network calls, or malicious prompt injection was found.
能力标签
crypto
能力评估
Purpose & Capability
The skill's name/description match the code and SKILL.md: it is a trading bot that talks to exchanges and provides strategies and risk controls. However, the registry metadata declares no required environment variables or config paths while SKILL.md and the code explicitly require exchange API keys (e.g., BINANCE_API_KEY/BINANCE_API_SECRET) and read/write risk/config and log files under ~/.openclaw. That mismatch is incoherent and should have been declared.
Instruction Scope
SKILL.md and the script keep scope to trading-related actions: fetching prices/klines, computing indicators, paper/live trade execution, backtests, and managing a kill-switch. The instructions and code read/write files in ~/.openclaw (trading-config.json, workspace/memory logs and paper portfolio) and make network calls to exchange APIs — all expected for a trading bot. No evidence in the visible files of unrelated data collection or external exfiltration, but the skill logs decisions and persists trade/log data locally which users should be aware of.
Install Mechanism
There is no install specification (instruction-only with included script files). No downloads or archive extraction are requested, so nothing extra is written to disk beyond the script's normal runtime behavior (it will create ~/.openclaw paths).
Credentials
The code and SKILL.md require exchange API credentials (BINANCE_API_KEY/BINANCE_API_SECRET and mentions Hyperliquid keys) but the registry lists no required env vars or primary credential — an inconsistency. The requested secrets themselves are proportional for a trading bot, but registry metadata omission is misleading. Also the skill will need API keys with trading permissions to perform live trades; users should limit key scopes (disable withdrawals) and prefer testnet keys for testing.
Persistence & Privilege
The skill does not request 'always' or other broad platform privileges. It will persist configuration, logs, and a paper-portfolio under the user's home (~/.openclaw), which is reasonable for a bot but means state and logs are stored locally. The skill does not appear to modify other skills or global agent settings.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install agent-trading-bot
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /agent-trading-bot 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
Initial release — AI-powered trading bot framework for crypto exchanges and prediction markets
元数据
Slug agent-trading-bot
版本 1.0.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 1
常见问题

Agent Trading Bot 是什么?

AI-powered trading bot framework for OpenClaw. Connects to crypto exchanges (Binance, Hyperliquid, Bluefin) and prediction markets (Polymarket, Kalshi) via A... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 153 次。

如何安装 Agent Trading Bot?

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

Agent Trading Bot 是免费的吗?

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

Agent Trading Bot 支持哪些平台?

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

谁开发了 Agent Trading Bot?

由 stevojarvisai-star(@stevojarvisai-star)开发并维护,当前版本 v1.0.0。

💬 留言讨论