Declaration

This project has a previous foundation. I originally built it as a personal XAUUSD scalping bot, and for this submission I iterated on that base to make it a multi-pair trading system with multi-user support, subscription billing, and a more scalable cloud architecture. The current version includes significant new work beyond the original bot: I built a mobile app for easy user access, multi-account orchestration, broader market scanning (12 instruments), and a redesigned backend for shared use.

Inspiration

I started trading gold with a small account — no stop-loss, no take-profit, just me and the chart for hours. I'd watch every tick, convinced I could exit at the perfect moment. But it only took looking away for a few minutes. One retracement, and the account was gone. Over and over. I realized I needed something I could never be: always watching, never emotional, never distracted. So I built it — an automated system that sits on the chart 24/7, harvests profit at the peak, and never blows up from a retracement I wasn't there to see.

What it does

An always-on algorithmic trading bot that trades 12 instruments — gold, US indices (US100, US500, US30), Asian/European indices (JP225, DE40), energy (WTI, BRENT, GAS) and metals (XAGUSD, XPT, COPPER). It runs on Render cloud infrastructure, executes via Capital.com, and manages risk through equity-scaled position sizing with zero hard stop-losses — instead using ATR-based cut, trail, and peak-harvest lock exits inside the current H1 candle (the "Wave Scalper"). An XGBoost model acts as a chop filter, sitting out low-quality candles. It supports multiple users, subscription billing, a mobile app, and a leader-lease failover architecture so trading survives crashes.

How we built it

Python FastAPI backend with a thread-pool bot architecture — each user account gets its own async bot instance. The strategy is an intra-candle M1 wave scalper: it anchors to the H1 open, enters on ATR-scaled pullbacks (0.5× ATR), cuts fast on adverse moves, and lets winners breathe with a peak-lock + rider trail — exits are priced from actual fills so live == backtest. Risk is managed per-event and per-day with configurable loss caps. Historical data from Dukascopy (~23 years of XAUUSD M1, plus full M1 history for 12 pairs). Paystack and MaxelPay handle subscription payments; a Flutter mobile app gives users live control and monitoring.

Challenges we ran into

Building a stop-loss-free system that doesn't blow accounts required extensive backtesting to tune the ATR cut/trail parameters. Capital.com rate limits and session timeouts demanded a robust reconnection layer with exponential backoff. Synchronizing multiple bots sharing a single broker account while keeping state consistent across restarts was harder than expected — so was proving the live engine behaved identically to the backtest (we built a replay harness that matches trade-for-trade across 7,316 trades).

Accomplishments that we're proud of

The peak-harvest exit logic that lets winning runs breathe without giving back everything — backtests show it captures significantly more upside than fixed-TP models on trending days. A proven live == backtest pipeline: the live engine reproduces the validated sweep exactly. Twelve-pair validation where every instrument is profitable (2024: 38,271 trades, profit factor 4.92, +8,106R, max drawdown ≤ ~3R per pair). A committed XGBoost chop-gate model per pair that skips choppy candles. ~23 years of M1 data for gold, systematically archived and queriable for any date range.

What we learned

That sophisticated exits matter more than entries — a mediocre entry with a smart exit consistently outperforms a perfect entry with a dumb stop. Equity-scaled sizing is critical for small accounts; fixed lot sizes are a fast path to ruin. Cloud deployment of trading systems is viable if you handle broker disconnections gracefully. And that a validation harness that proves the live engine matches the backtest is worth more than a faster model.

What's next for Forex Gold scalping AI

Deepening the ML layer (order-flow features and confidence-gated entries on top of the chop filter), live PnL streaming to the mobile/web dashboard via WebSocket, correlated-pair coordination (reusing the US100/US500 combined-loss logic across more instruments), and a community marketplace for sharing and subscribing to strategy configurations.

The business model

  • Product: An automated trading bot that trades for you across gold, indices, energy, and metals.
  • Free trial for demo accounts (play money) — no limits, always free.
  • 30-day free trial for live accounts (real money) — full access, no payment needed.
  • After the trial: the bot tracks your profit in 30-day periods. If you made profit, you owe 15% of that profit as a fee. If you lost money, you owe nothing.
  • If you don't pay, the bot stops working until you settle — the startup only makes money when users make money. This aligns incentives — the bot needs to be profitable for both the user and the company.
  • Demo is free forever — acts as a marketing funnel to get users hooked, then convert them to live accounts.
Share this project:

Updates

posted an update

Just Deviced a new strategy for my AI bot called ASP Strategy (Adaptive Swing Probability) What It Does Predicts high-probability swing turning points in gold (XAUUSD) on M5 timeframe. Enters at swing lows (BUY) and swing highs (SELL) using 54 ML features across 7 analysis systems. Entry Logic

  1. M1 data → resample to M5 + H1
  2. Compute 54 features (swing structure, fractals, volatility, geometry, liquidity, candle behavior, HTF context)
  3. XGBoost model predicts: BUY / SELL / NEUTRAL
  4. If BUY/SELL → enter at market price
  5. No bias engine filter — ASP is self-contained Exit Logic (Fixed) Exit Condition TP Price reaches 1x ATR from entry SL Price reaches 2x ATR from entry Timeout 6 bars (30 min) — closes at market price Position Sizing
  6. 1 position at a time
  7. Lot = 0.01 × (balance / $20)
  8. DD > 10% → lot halved
  9. No cap (scales infinitely with equity) Why It Works
  10. SMC-based: 98.3% of entries are reversals after liquidity sweeps/fakeouts
  11. Choppy-immune: 88% of time predicts NEUTRAL (no setup = no trade)
  12. High win rate: 88-90% (TP is 1x ATR, SL is 2x ATR — TP is closer)
  13. Fast timeout: Cuts losers in 30 min, doesn't hold stale trades Risk:Reward
  14. Risk per trade: 2x ATR
  15. Reward per trade: 1x ATR
  16. R:R = 1:0.5 (losing more per trade than gaining)
  17. Compensated by 88-90% win rate → still highly profitable Trade Frequency
  18. ~2,500 trades/year (~10/day)
  19. ~6% signal rate (enters on ~6% of M5 bars)

Log in or sign up for Devpost to join the conversation.

posted an update

Adding a feature called meta strategy, this feature detect market changes by tracking the consecutive loss, it then automatically device another strategy to fit in the current market condition. This feature would make the AI bot survive Gold crash and other conditions in the Financial market.

Log in or sign up for Devpost to join the conversation.

posted an update

I am trying to integrate sentiment trading by making request from Gemini API directly, Gemini would scrap the entire public Web and look for Trading sentiment to feed my AI bot, I think that would make my AI bot more wise and take smarter decisions out of it analysis and signal engine.

Log in or sign up for Devpost to join the conversation.