Works / IQ30
Autonomous AI trading bot · personal product · 2025 → 2026
Solo — product direction, AI orchestration, QA & design 2025 — 2026 macOS desktop app ~231k lines of Python

IQ30 is a desktop app that trades binary options and Forex/CFD on IQ Option on its own — an AI decision layer (reinforcement learning, classical ML and local LLMs that read the chart), with risk and money management, a full backtesting research suite and a complete GUI. I built it solo by directing AI end-to-end: the product decisions, the agent and prompt design, and the testing discipline that keeps it honest are mine.

The problem worth solving

IQ Option has no official options API, so I designed the system to degrade gracefully across three interchangeable market-access modes:

WebSocket trading panel — shadow execution mode, practice account connected
Mode 01

WebSocket

Unofficial low-latency socket for fast, programmatic order placement when the channel is available.

Computer-vision calibration — the platform screen and the CALL/PUT buttons, balance and payout regions the OCR extracted from it
Mode 02

Computer vision

OpenCV + Tesseract OCR read balance, payout and trades off the screen; GUI automation clicks the buttons. No API required.

Observation mode — trade history of manual trades the bot learns from, in paper-trading simulation
Mode 03

Observation

The bot watches manual trading and learns from it without placing orders — a safe path to collect ground-truth.

My job wasn't to type the code — it was to make a real money-handling system actually work. I set the architecture and product direction, designed the decision agents and their prompts, and ran the testing: against live data, real trades and real notifications, not just on paper.

The AI decision layer

How it decides

Fully autonomous — it picks direction itself, no manual “press CALL”. An ensemble of independent subsystems votes on every candle; a tie means skip the trade. Three families of intelligence run side by side:

Global Q-state confidence distribution from the live RL dashboard
01 — Reinforcement learning

Learns from outcomes

  • Tabular Q-Learning v3.1 with per-asset Q-tables.
  • A TensorFlow Deep Q-Network trained on 370,000+ USD/JPY candles.
  • Reward shaped on real trade outcomes, not just price prediction.
ML model performance — accuracy, precision, recall, F1 and ROC AUC with an empirical confusion matrix
02 — Classical ML

Reads the structure

  • Random Forest, LSTM and neural-net models via scikit-learn + Keras.
  • Separate entry and expiration models, per account profile.
  • Consensus ensemble — independent models must agree to act.
Local LLM integration panel — LM Studio endpoint, sentiment analysis, pattern recognition and Vision AI chart reading
03 — Local vision LLMs

Looks at the chart

  • Gemma (multimodal) reads the chart straight from a screenshot.
  • Qwen2.5-Coder reasons over the decision in text.
  • Run locally via LM Studio — an OpenAI-compatible API, no cloud.
ML/RL intelligence dashboard — 2,285 scenarios logged, empirical confusion matrix, active model features
Q-table state coverage per asset — 953 unique market patterns
Backtesting research

Backtesting as research, not marketing

A dedicated engine computes win rate, edge, expected value, Kelly fraction, Sharpe, max drawdown, profit factor and consecutive win/loss streaks per asset and payout. Strategies run through a four-phase funnel — and every batch is ranked by the gap between training and validation, so overfit winners are caught, not celebrated.

Across batches, 2,370+ strategy/parameter combinations were tested. The goal was never a hero number — it was to find configurations that survive out-of-sample, and to write down the ones that didn’t.

Phase 01
Strategy screen
Every strategy run across assets to find a real, positive edge before anything else.
Phase 02
Timeframe & expiry
Survivors tuned over timeframes and expiration depth — e.g. RSI+Trend on USD/JPY 1H reaching +8.4% edge.
Phase 03
Money management
13 staking models stress-tested for profit vs drawdown — one config returned +$593 at a 24.8% drawdown.
Phase 04
Year stability
Replayed across years to check the edge holds — and to expose where it decays over time.
Validated configuration Asset Timeframe Win rate Edge Sharpe Profit factor
RSI — balancedUSD/JPY1H 69.9%+16.1%3.22.0
RSI — aggressiveUSD/JPY1H 70.1%+16.4%
RSI + TrendUSD/JPY1H 62.2%+8.4%1.41
RSI + TrendEUR/USD1H · 2023 66.0%+12.0%
Volatility BreakoutEUR/USDEurope session 60.5%+6.5%

Out-of-sample backtest configurations, drawn from saved presets and the four-phase optimisation report — research artefacts, not a promise of live returns. Dashes mark metrics not stored for that preset.

What didn’t work — on the record

Order-Block / SMC strategies backtested mostly unprofitable and were never shipped. An early Random-Forest model was caught overfitting on a biased 2025 snapshot and retrained from a clean split. And the edge on RSI+Trend EUR/USD decays from +12% in 2023 toward break-even by 2025 — documented in the year-stability phase, not hidden.

That honesty is the point: a system that handles real money is only as trustworthy as the failures it’s willing to write down.

Dashboards & live operations

Everything is observable

A dashboard generator reads the trade database and the RL state and emits balance curves, P&L by day, and win rate broken down by strategy, by asset and by hour — the same hour-by-hour data that feeds a filter which skips historically losing hours.

In-app backtesting panel — Backtest, Optimizer, ML Center and Strategy Comparison tabs
Telegram bot on the phone — a WIN trade notification and the IQ30 control panel with start/stop, stats and AI Brain
Risk, safety & engineering discipline
Risk & money management

It knows when to stop

  • Limits: max stake, daily cap, max loss, drawdown, losing streak, cooldown.
  • Time filters + a win-rate-by-hour filter that skips historically losing hours (from the database, not hardcoded).
  • 13 money-management models — Kelly, Martingale, Anti-Martingale, D’Alembert, Fibonacci, Ilan and more.
Safety by design

No guessing on money

  • NO_FALLBACKS rule — no default values for critical data; stop trading rather than act on a wrong balance.
  • Per-profile isolation — each account gets its own database, models and settings.
  • Audit reports document the race-condition and event-loop fixes that got it stable.
Built & tested for real

Proven against live data

  • 4,800+ real trades logged across profiles in a SQLAlchemy/SQLite data layer.
  • 94 automated test files (last run: 348 passing) + regression protocols.
  • Real-time Telegram notifications on every trade and event.
The volume of work

Where the code lives

Nine src/ subsystems make up the core. With the backtest scripts, the test suite and tooling, the project runs to ~231k lines of Python — six months, 144 commits, built solo by directing AI, with the architecture, agent design and QA discipline mine.

44.8k
UI — PySide6 / Qt6
33.2k
Core — engine & orchestration
28.5k
Strategies — 66 classes
11.2k
Backtesting suite
10.3k
Data & persistence
7.8k
Broker adapters — WS / CV
6.8k
Trading — execution & sessions
3.1k
ML — DQN training pipeline
2.8k
Intelligence — local LLM layer
231k
Lines of Python
4,800+
Real trades logged
66
Strategy classes
2,370+
Backtest combinations
Language
Python 3.13
Desktop GUI
PySide6 (Qt6) — multi-tab app, backtesting panel, ML/RL dashboard
Machine learning
TensorFlow / Keras (DQN), scikit-learn (Random Forest, LSTM, NN), tabular Q-Learning v3.1
Vision & LLM
Local Gemma (multimodal) + Qwen2.5-Coder via LM Studio (OpenAI-compatible API)
Market access
Unofficial WebSocket adapter · OpenCV + Tesseract OCR screen-reading + GUI automation
Data layer
SQLAlchemy + SQLite, profile-isolated (trades, balances, risk & trade metrics, sessions, logs)
Reporting
Chart.js / ApexCharts HTML dashboards & investor-grade backtest reports

Status, honestly: the trading core (WebSocket + computer-vision), Q-Learning, money management, risk filters, backtesting and GUI all work. The five advanced TURBO strategies and Forex auto-trading are code-complete and in testing; the local-LLM layer (Gemma + Qwen) was recently integrated and is being validated on live charts. A real, running system — shown with its methodology and its failures, deliberately without performance promises.