Moon Dev
3 hr 33 min video
4 min read
AI Trading Bots Masterclass: Research, Backtest, Automate
You just saved 3 hr 29 min.
The big takeaway
Moon Dev teaches a complete system (RBI: Research, Backtest, Implement) for automating crypto trading using AI, Hyperliquid data, and Claude Code. He demonstrates live bot building, shares exclusive liquidation data APIs, explains AI workflows for 2026, and launches a comprehensive training program covering strategy discovery, backtesting, bot deployment, and market-neutral stat arbs.
The RBI System: Research, Backtest, Implement
Why Manual Trading Fails
Hand traders using leverage lose money through fees alone. A $25,000 account with 40x leverage trading 5 times daily loses all capital in 31 days from fees, while a bot with patient limit orders extends survival to 717 days. Manual trading also wastes time and emotions, making it impossible to compound knowledge or maintain relationships.
Hand trader (40x, 5 trades/day)
31 days to liquidation
Patient bot (limit orders)
717 days survival
Impact of fees and execution method on account longevity
The Three-Step RBI Framework
Research ideas from papers, books, podcasts, and data sources; Backtest those ideas using historical data to verify they worked in the past; Implement winners into live bots at tiny size. Most ideas fail, so expect 1 in 10 to work—this is normal and good. Jim Simons ran $31B using this iterative approach.
1
Research: Find ideas from papers, books, data, podcasts
2
Backtest: Test ideas on historical data using Python
3
Implement: Build bot at tiny size if backtest works
4
Iterate: Repeat daily to find more edges
The RBI system Moon Dev follows every single day
Where to Find Trading Ideas
Read academic papers on Google Scholar, books like Market Wizards, listen to Chat with Traders podcast (300+ trader interviews), watch YouTube, and use proprietary data sources. Keep an iPhone note of 10–30 ideas in your backlog. Most ideas are trash, so volume of research is critical.
Backtesting is Your X-Ray Vision
Use Python libraries like backtesting.py, BackTrader, or VectorBT to simulate strategies on past data. This reveals whether a strategy actually works before risking real money. Avoid Trading View for backtesting due to repainting (indicators changing historical values); use it only to grab indicator code.
Hyperliquid Data Layer: Your Competitive Edge
Exclusive On-Chain Data Nobody Else Has
Moon Dev built a Hyperliquid node and API exposing real-time liquidations, whale positions, order flow, smart money moves, and HLP (market maker) sentiment. This data is not available on YouTube or public exchanges. Hyperliquid liquidates at 50% loss vs. Binance at 100%, making it a leading indicator of cascade liquidations.
1
HLP3 liquidations (24h)
Real-time
2
Whale positions (19,000 active)
All addresses
3
Order flow & tick data
Complete history
4
Smart money performers
Top 10 tracked
5
Cross-exchange liquidations
Binance, OKX, Bybit, Hyperliquid
Exclusive data sources available via Hyperliquid API
HLP Market Maker: $1K to $183M
Hyperliquid's market maker (HLP) ran $1,000 to $183 million by trading seven different stat arb strategies. Their positions, sentiment, and fills are now visible through the data layer, allowing traders to study and replicate successful approaches.
$183M
HLP net worth from $1K starting capital
Market maker performance tracked via API
Liquidation Cascade Theory
Hyperliquid liquidates traders at 50% loss, while Binance and OKX liquidate at 100%. When Hyperliquid liquidations spike, they may trigger cascades on other exchanges. This creates a testable leading indicator: enter momentum trades when Hyperliquid liquidations appear, exit when Binance liquidations hit.
AI Workflow for 2026: Claude Code Mastery
Evolution of AI Tools: ChatGPT → Cursor → Claude Code
Started with ChatGPT web interface (2023), moved to Cursor (Visual Studio Code fork with AI) for beginners, now uses Claude Code in terminal for advanced multi-project workflows. Claude Code allows running multiple agents in parallel and integrates with the agentic framework.
2023
ChatGPT web interface (copy-paste workflow)
2024
Cursor (Visual Studio Code + AI, beginner-friendly)
2025-2026
Claude Code (terminal, multi-agent, agentic framework)
Moon Dev's AI tool progression
Whisper Flow: Voice-to-Code at 152 WPM
Whisper Flow allows dictating prompts instead of typing, doubling productivity from 70 WPM to 152 WPM. This enables rapid testing: more tests per day = more ideas validated = more edges found. Faster iteration is a direct edge.
Manual typing
70 WPM
Whisper Flow voice
152 WPM
Typing speed improvement via voice input
Plan Mode: Avoid the Slot Machine Loop
Hit Shift+Tab multiple times before sending a large prompt to trigger Plan Mode. Claude plans the entire project, asks clarifying questions, and prevents the 'near miss' loop where AI keeps iterating without direction. This saves hours on large projects.
Claude Dangerously Skip Permissions: Autonomous Execution
Run `claude -dangerously-skip-permissions` to execute code autonomously without yes/no prompts. Create a shortcut by typing just `C` to activate this. Enables hands-off backtesting and bot deployment.
Multi-Agent Swarm: 5+ Agents in Parallel
Tell Claude to launch 5 or 10 agents to test different backtest ideas simultaneously. Each agent works independently on variations (long vs. short, different indicators, different parameters). This parallelizes the research phase.
5-20
Agents running in parallel per project
Multi-agent swarm capability in Claude Code
Sub-Agents: Specialized AI Workers
Create sub-agents with specific knowledge (e.g., 'BackTest Architect' knows the backtesting template). Anytime you ask Claude to backtest, it routes to the specialist. This ensures consistency and speeds up iteration.
Building Live Trading Bots: The Checklist
Bot Implementation Checklist
Every bot must: (1) implement risk controls, (2) use limit orders not market orders, (3) check if already in position before entering new one, (4) adjust decimals per exchange, (5) run in a while loop 24/7, (6) start at tiny size. Forgetting step 3 (cancel prior orders) blows up accounts instantly.
1
Implement risk controls (stop-loss, take-profit)
2
Use limit orders (patient execution)
3
Check existing position, cancel old orders
4
Adjust decimals for exchange
5
Run in while loop (24/7 execution)
6
Start at tiny size (minimize losses)
Step-by-step bot deployment checklist
Tiny Size is Non-Negotiable
Always launch bots at tiny size (e.g., $10 position). If the bot fails, you lose $10, not your entire account. This is how you test in production without catastrophic risk.
Stat Arbs: Market-Neutral Strategies
Stat arbs go long and short simultaneously, making them market-neutral (profit regardless of price direction). Moon Dev's stat arbs include QQE crossover, liquidation momentum, and HLP sentiment. One of four live bots is profitable; this 25% win rate is acceptable and expected.
1 of 4
Live stat arbs currently profitable
Expected win rate for new bot strategies
Exchanges Supported: CCXT + Hyperliquid + Interactive Brokers
Use CCXT library to connect to Binance, Coinbase, Kraken, Bybit, and 100+ exchanges. Connect directly to Hyperliquid for crypto futures. Use Interactive Brokers for stocks, options, and traditional futures. All code templates provided.
Live Bots & Real Results
Four Stat Arb Bots Running Live
Moon Dev deployed four stat arb strategies (Regular, Copula, Gaussian, Forelle) with different liquidation momentum parameters. One is profitable (Regular), three are down but being optimized. Adjustments include tighter stop-losses (-6%) and time-based exits to reduce open-trade duration.
Regular (baseline)
90 starting balance
Copula
81 current
Gaussian
81 current
Forelle
88 current
Live stat arb bot performance snapshot
QQE Liquidation Momentum Winner
A new backtest combining QQE indicator (from Trading View) with liquidation momentum data returned 101% return with 1.66 Sharpe ratio. This demonstrates the power of combining technical indicators with on-chain liquidation data.
101%
Return on QQE + liquidation momentum backtest
Example of successful strategy combination
Cloud Deployment & Scaling
Run Bots 24/7 on Cloud Servers
Deploy bots on VPS servers (Cherry Servers, Hetzner, Vultr, Kamatera) for ~$50/month. SSH into the server and run Claude Code remotely. Bots run autonomously even if your computer is off or power goes out. Moon Dev uses this in Puerto Rico where power is unreliable.
The Algo Trade Camp Offer
Six-Week Comprehensive Training Program
Algo Trade Camp teaches step-by-step how to automate trading even with zero coding knowledge. First 15 days cover research, backtesting, and bot building. Days 15–60 expand into Solana bots, Poly Market trading, and advanced strategies. Includes AI master classes, unlimited Zoom calls, and access to 300+ backtests in Quantite.
Pricing & Payment Options
One-time payment of $1,500 for one year of access (96% off stated $48K value). Two payment plan: $797 × 2. Also accepts Klarna for smaller installments. 90-day money-back guarantee, no questions asked.
Stated value
48000 USD
One-time payment
1500 USD
Two payments
797 USD each
Algo Trade Camp pricing structure
What's Included
Algo Trade Camp (6 weeks), AI master classes, Solana CopyBot & Sniper course, Poly Market Trading Bot course, unlimited private Zoom calls, one year of Quantite (300+ bots), Moondev Vault (2TB archived streams), Moondev API key ($10K value), Trading Bot GitHub (100+ templates), exclusive AI Agents GitHub, and Quant App access.
1
Algo Trade Camp (6 weeks)
$3,000
2
AI Master Classes
$1,000
3
Solana & Poly Market courses
$5,000
4
Quantite (1 year, 300+ bots)
$3,600
5
API key + GitHubs + Vault
$10,000
6
Quant App access
$12,000
Breakdown of included value (~$48K total)
Mindset & Philosophy
You Are a Quant Now, Not a Gambler
Stop identifying as a 'trader' (which people perceive as a gambler). You are now a quant—someone who uses data and systems to trade. This shift removes emotion, enables backtesting, and earns respect. Hand trading is gambling; algorithmic trading is engineering.
Don't Follow the Pack
Jim Simons said: 'Don't follow the pack.' Everyone else trades by hand and loses. If you automate, you're already ahead. Most quants on Wall Street went to Stanford or Harvard; Moon Dev was held back in seventh grade. Education doesn't matter—execution does.
Time is Your Most Valuable Asset
Moon Dev lost his best friend KT because he was always staring at charts instead of spending time with him. Trading by hand wastes 8+ hours per day with no compounding benefit. Spend 4 hours building systems instead; let bots run 24/7 while you live your life.
Discipline Over Talent
Discipline is doing what you hate but doing it like you love it. Most people give up at the slightest struggle. Moon Dev was held back in seventh grade and told he wouldn't make it; he proved them wrong through discipline. Same applies to trading: discipline beats talent.
Worth quoting
"If you don't have discipline, you ain't nobody. Doing what you hate to do, but do it like you love it."
— Moon Dev (quoting mentor), at [7:42]
"Don't follow the pack. If everyone is trying to solve the same problem, you're going to get smoked."
— Jim Simons (quoted by Moon Dev), at [28:54]
"Code is a great equalizer. I didn't know how to code. I got held back in seventh grade. You got this, bro."
— Moon Dev, at [18:55]
Try this
Go to moondev.com/docs to access the Hyperliquid data layer API and review all available endpoints (liquidations, positions, order flow, smart money, etc.).
Set up a free API key for Hyperliquid data layer if you're in the private Zoom community.
Read at least three books from the provided book list (Market Wizards, Chat with Traders podcast, Google Scholar papers) to build your research backlog.
Create an iPhone notes file or spreadsheet with 10–30 trading ideas from papers, books, and podcasts.
Download and install Cursor (Visual Studio Code fork) or Claude Code to start backtesting with AI assistance.
Backtest your first idea using backtesting.py in Python; expect most ideas to fail (1 in 10 is good).
Build your first bot using the provided checklist: risk controls, limit orders, position checks, decimals, while loop, tiny size.
Deploy a bot to a cloud VPS (Cherry Servers, Hetzner, Vultr) for $50/month to run 24/7.
Join the Algo Trade Camp (mundave.com/go) if you want structured 6-week training, AI master classes, and access to 300+ backtests.
Use Whisper Flow (whisperflow.ai) to dictate prompts to Claude instead of typing to increase iteration speed.
Launch multiple agents in Claude Code (5–10) to backtest different strategy variations in parallel.
Use Plan Mode (Shift+Tab) before sending large prompts to Claude to avoid the 'slot machine loop' of endless iteration.
Made with Glimpse by Wozart
glimpse.wozart.com/v/dnjk3smh
Share this infographic
Read this infographic as text

AI Trading Bots Masterclass: Research, Backtest, Automate

Summary of the video “How To Use AI To build Trading Bots (2026 Masterclass) by Moon Dev.

Moon Dev teaches a complete system (RBI: Research, Backtest, Implement) for automating crypto trading using AI, Hyperliquid data, and Claude Code. He demonstrates live bot building, shares exclusive liquidation data APIs, explains AI workflows for 2026, and launches a comprehensive training program covering strategy discovery, backtesting, bot deployment, and market-neutral stat arbs.

The RBI System: Research, Backtest, Implement

Why Manual Trading Fails

Hand traders using leverage lose money through fees alone. A $25,000 account with 40x leverage trading 5 times daily loses all capital in 31 days from fees, while a bot with patient limit orders extends survival to 717 days. Manual trading also wastes time and emotions, making it impossible to compound knowledge or maintain relationships.

The Three-Step RBI Framework

Research ideas from papers, books, podcasts, and data sources; Backtest those ideas using historical data to verify they worked in the past; Implement winners into live bots at tiny size. Most ideas fail, so expect 1 in 10 to work—this is normal and good. Jim Simons ran $31B using this iterative approach.

Where to Find Trading Ideas

Read academic papers on Google Scholar, books like Market Wizards, listen to Chat with Traders podcast (300+ trader interviews), watch YouTube, and use proprietary data sources. Keep an iPhone note of 10–30 ideas in your backlog. Most ideas are trash, so volume of research is critical.

Backtesting is Your X-Ray Vision

Use Python libraries like backtesting.py, BackTrader, or VectorBT to simulate strategies on past data. This reveals whether a strategy actually works before risking real money. Avoid Trading View for backtesting due to repainting (indicators changing historical values); use it only to grab indicator code.

Hyperliquid Data Layer: Your Competitive Edge

Exclusive On-Chain Data Nobody Else Has

Moon Dev built a Hyperliquid node and API exposing real-time liquidations, whale positions, order flow, smart money moves, and HLP (market maker) sentiment. This data is not available on YouTube or public exchanges. Hyperliquid liquidates at 50% loss vs. Binance at 100%, making it a leading indicator of cascade liquidations.

HLP Market Maker: $1K to $183M

Hyperliquid's market maker (HLP) ran $1,000 to $183 million by trading seven different stat arb strategies. Their positions, sentiment, and fills are now visible through the data layer, allowing traders to study and replicate successful approaches.

Liquidation Cascade Theory

Hyperliquid liquidates traders at 50% loss, while Binance and OKX liquidate at 100%. When Hyperliquid liquidations spike, they may trigger cascades on other exchanges. This creates a testable leading indicator: enter momentum trades when Hyperliquid liquidations appear, exit when Binance liquidations hit.

AI Workflow for 2026: Claude Code Mastery

Evolution of AI Tools: ChatGPT → Cursor → Claude Code

Started with ChatGPT web interface (2023), moved to Cursor (Visual Studio Code fork with AI) for beginners, now uses Claude Code in terminal for advanced multi-project workflows. Claude Code allows running multiple agents in parallel and integrates with the agentic framework.

Whisper Flow: Voice-to-Code at 152 WPM

Whisper Flow allows dictating prompts instead of typing, doubling productivity from 70 WPM to 152 WPM. This enables rapid testing: more tests per day = more ideas validated = more edges found. Faster iteration is a direct edge.

Plan Mode: Avoid the Slot Machine Loop

Hit Shift+Tab multiple times before sending a large prompt to trigger Plan Mode. Claude plans the entire project, asks clarifying questions, and prevents the 'near miss' loop where AI keeps iterating without direction. This saves hours on large projects.

Claude Dangerously Skip Permissions: Autonomous Execution

Run `claude -dangerously-skip-permissions` to execute code autonomously without yes/no prompts. Create a shortcut by typing just `C` to activate this. Enables hands-off backtesting and bot deployment.

Multi-Agent Swarm: 5+ Agents in Parallel

Tell Claude to launch 5 or 10 agents to test different backtest ideas simultaneously. Each agent works independently on variations (long vs. short, different indicators, different parameters). This parallelizes the research phase.

Sub-Agents: Specialized AI Workers

Create sub-agents with specific knowledge (e.g., 'BackTest Architect' knows the backtesting template). Anytime you ask Claude to backtest, it routes to the specialist. This ensures consistency and speeds up iteration.

Building Live Trading Bots: The Checklist

Bot Implementation Checklist

Every bot must: (1) implement risk controls, (2) use limit orders not market orders, (3) check if already in position before entering new one, (4) adjust decimals per exchange, (5) run in a while loop 24/7, (6) start at tiny size. Forgetting step 3 (cancel prior orders) blows up accounts instantly.

Tiny Size is Non-Negotiable

Always launch bots at tiny size (e.g., $10 position). If the bot fails, you lose $10, not your entire account. This is how you test in production without catastrophic risk.

Stat Arbs: Market-Neutral Strategies

Stat arbs go long and short simultaneously, making them market-neutral (profit regardless of price direction). Moon Dev's stat arbs include QQE crossover, liquidation momentum, and HLP sentiment. One of four live bots is profitable; this 25% win rate is acceptable and expected.

Exchanges Supported: CCXT + Hyperliquid + Interactive Brokers

Use CCXT library to connect to Binance, Coinbase, Kraken, Bybit, and 100+ exchanges. Connect directly to Hyperliquid for crypto futures. Use Interactive Brokers for stocks, options, and traditional futures. All code templates provided.

Live Bots & Real Results

Four Stat Arb Bots Running Live

Moon Dev deployed four stat arb strategies (Regular, Copula, Gaussian, Forelle) with different liquidation momentum parameters. One is profitable (Regular), three are down but being optimized. Adjustments include tighter stop-losses (-6%) and time-based exits to reduce open-trade duration.

QQE Liquidation Momentum Winner

A new backtest combining QQE indicator (from Trading View) with liquidation momentum data returned 101% return with 1.66 Sharpe ratio. This demonstrates the power of combining technical indicators with on-chain liquidation data.

Cloud Deployment & Scaling

Run Bots 24/7 on Cloud Servers

Deploy bots on VPS servers (Cherry Servers, Hetzner, Vultr, Kamatera) for ~$50/month. SSH into the server and run Claude Code remotely. Bots run autonomously even if your computer is off or power goes out. Moon Dev uses this in Puerto Rico where power is unreliable.

The Algo Trade Camp Offer

Six-Week Comprehensive Training Program

Algo Trade Camp teaches step-by-step how to automate trading even with zero coding knowledge. First 15 days cover research, backtesting, and bot building. Days 15–60 expand into Solana bots, Poly Market trading, and advanced strategies. Includes AI master classes, unlimited Zoom calls, and access to 300+ backtests in Quantite.

Pricing & Payment Options

One-time payment of $1,500 for one year of access (96% off stated $48K value). Two payment plan: $797 × 2. Also accepts Klarna for smaller installments. 90-day money-back guarantee, no questions asked.

What's Included

Algo Trade Camp (6 weeks), AI master classes, Solana CopyBot & Sniper course, Poly Market Trading Bot course, unlimited private Zoom calls, one year of Quantite (300+ bots), Moondev Vault (2TB archived streams), Moondev API key ($10K value), Trading Bot GitHub (100+ templates), exclusive AI Agents GitHub, and Quant App access.

Mindset & Philosophy

You Are a Quant Now, Not a Gambler

Stop identifying as a 'trader' (which people perceive as a gambler). You are now a quant—someone who uses data and systems to trade. This shift removes emotion, enables backtesting, and earns respect. Hand trading is gambling; algorithmic trading is engineering.

Don't Follow the Pack

Jim Simons said: 'Don't follow the pack.' Everyone else trades by hand and loses. If you automate, you're already ahead. Most quants on Wall Street went to Stanford or Harvard; Moon Dev was held back in seventh grade. Education doesn't matter—execution does.

Time is Your Most Valuable Asset

Moon Dev lost his best friend KT because he was always staring at charts instead of spending time with him. Trading by hand wastes 8+ hours per day with no compounding benefit. Spend 4 hours building systems instead; let bots run 24/7 while you live your life.

Discipline Over Talent

Discipline is doing what you hate but doing it like you love it. Most people give up at the slightest struggle. Moon Dev was held back in seventh grade and told he wouldn't make it; he proved them wrong through discipline. Same applies to trading: discipline beats talent.

Notable quotes

If you don't have discipline, you ain't nobody. Doing what you hate to do, but do it like you love it. — Moon Dev (quoting mentor)
Don't follow the pack. If everyone is trying to solve the same problem, you're going to get smoked. — Jim Simons (quoted by Moon Dev)
Code is a great equalizer. I didn't know how to code. I got held back in seventh grade. You got this, bro. — Moon Dev

Action items

  • Go to moondev.com/docs to access the Hyperliquid data layer API and review all available endpoints (liquidations, positions, order flow, smart money, etc.).
  • Set up a free API key for Hyperliquid data layer if you're in the private Zoom community.
  • Read at least three books from the provided book list (Market Wizards, Chat with Traders podcast, Google Scholar papers) to build your research backlog.
  • Create an iPhone notes file or spreadsheet with 10–30 trading ideas from papers, books, and podcasts.
  • Download and install Cursor (Visual Studio Code fork) or Claude Code to start backtesting with AI assistance.
  • Backtest your first idea using backtesting.py in Python; expect most ideas to fail (1 in 10 is good).
  • Build your first bot using the provided checklist: risk controls, limit orders, position checks, decimals, while loop, tiny size.
  • Deploy a bot to a cloud VPS (Cherry Servers, Hetzner, Vultr) for $50/month to run 24/7.
  • Join the Algo Trade Camp (mundave.com/go) if you want structured 6-week training, AI master classes, and access to 300+ backtests.
  • Use Whisper Flow (whisperflow.ai) to dictate prompts to Claude instead of typing to increase iteration speed.
  • Launch multiple agents in Claude Code (5–10) to backtest different strategy variations in parallel.
  • Use Plan Mode (Shift+Tab) before sending large prompts to Claude to avoid the 'slot machine loop' of endless iteration.

More like this