← 返回
AI智能 Key 中文

Trading Tournament

Run autonomous multi-agent trading competitions on OKX. 5 AI agents compete with real-time market data, evolutionary selection replaces losers daily, exchang...
在OKX上运行自主多智能体交易竞赛。5个AI智能体使用实时市场数据竞争,通过进化选择每日替换表现不佳者,交易所集成...
peti0402
AI智能 clawhub v1.0.0 1 版本 99796.7 Key: 需要
★ 1
Stars
📥 962
下载
💾 42
安装
1
版本
#latest

概述

Trading Tournament 🏆

Run autonomous multi-agent trading competitions where AI strategies compete against each other with real market data.

What It Does

  • 5 agents compete simultaneously on OKX Demo (or Live)
  • Every 5 minutes: each agent analyzes candles, indicators, and decides to enter/exit
  • Daily evolution at 07:00: top 2 survive, bottom 2 get replaced by better strategies
  • Exchange-level stop-losses: positions are protected even if the bot crashes
  • 3-layer position sizing protection: unknown assets skipped, 50% equity cap, $500 hard max

Architecture

┌─────────────┐
│ Competition  │ ← runs every 5 minutes
│  Manager     │
└──────┬──────┘
       │
  ┌────┼────┬────┬────┐
  │    │    │    │    │
  v    v    v    v    v
Agent1 Agent2 Agent3 Agent4 Agent5
(S&D)  (RSI)  (S&D)  (RSI)  (RSI)
       │
       v
  ┌─────────┐
  │ OKX API │ ← real-time prices, order execution
  └─────────┘

Strategies Included

  1. Supply & Demand — Identifies accumulation/distribution zones, enters on retests
  2. RSI Mean Reversion — Overbought/oversold with EMA trend filter
  3. RSI Fast Confirm — 1-bar bounce confirmation with tight EMA alignment
  4. RSI Trend Filter — Long-period EMA filter with standard RSI levels

Safety Features

LayerProtectionWhat Happens
-------------------------------
1CT_VALS lookupUnknown asset → SKIP (never enter blind)
250% equity capMax position = half of agent's capital
3$500 hard capAbsolute maximum notional per trade
4Exchange SLStop-loss on OKX itself (survives bot crash)
5GuardianWindows Task checks every minute, restarts if dead

Setup

Prerequisites

  • OKX account (Demo or Live)
  • API Key + Secret + Passphrase
  • Node.js 18+

Quick Start

  1. Copy bybit-trading/ folder to your workspace
  2. Create .secrets/okx.env:
  3. OKX_API_KEY=your_key
    OKX_API_SECRET=your_secret
    OKX_PASSPHRASE=your_passphrase
    
  4. Edit agents_config.json with your preferred strategies and assets
  5. Run: node competition_manager_okx.js

Cron Setup (recommended)

Add a Guardian cron or Windows Task that checks competition_log_okx.txt freshness every minute. If log hasn't updated in 6 minutes → kill and restart.

Evolution Rules

Daily at 07:00:

  • 🥇 Rank 1 → Survives (strategy + assets)
  • 🥈 Rank 2 → Survives (strategy + assets)
  • 🥉 Rank 3 → Strategy stays, assets rotate to better performers
  • 4️⃣ Rank 4 → Fully replaced from best_strategies pool
  • 5️⃣ Rank 5 → Fully replaced from best_strategies pool

Criteria for new agents: PF > 1.5, DD < 25%, min 5 backtested trades.

Live Trading Checklist

Before going live with real money:

  • [ ] 7 days continuous run without crashes
  • [ ] P&L > 15% on demo
  • [ ] 30+ trades for top 3 agents
  • [ ] Max drawdown < 10%
  • [ ] 0 sizing bugs
  • [ ] Exchange-level SL verified on all new positions

Built With

  • Node.js + OKX REST API
  • Technical indicators (EMA, RSI, ATR, Supply/Demand zones)
  • Evolutionary selection algorithm
  • Real-time Telegram alerts

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-03-29 12:01 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

Auto-Watchdog

peti0402
为OpenClaw代理提供自动健康监控与自愈功能,监测定时任务、进程、磁盘使用率及API状态,自动重启崩溃服务...
★ 0 📥 325
ai-intelligence

Self-Improving + Proactive Agent

ivangdavila
自我反思+自我批评+自我学习+自组织记忆。智能体评估自身工作、发现错误并持续改进。
★ 1,350 📥 317,705
ai-intelligence

ontology

oswalpalash
类型化知识图谱,用于结构化智能体记忆与可组合技能。支持创建/查询实体(人员、项目、任务、事件、文档)及关联...
★ 709 📥 243,532