How murad24-cuper/trading-bot- works
XM MT5 Trading Bot is a single-owner, locally run trading system. Its main workflow is to connect to the MT5 terminal, scan broker symbols, evaluate short-horizon opportunities, apply risk controls, and manage orders; SQLite records decisions and trades. A localhost panel displays status and queues bot commands, while research and simulation provide separate analysis capabilities. Evidence is limited to the README and sampled/indexed files; links without direct evidence are omitted.
Main entry points: app.py Web panel · engine.py Backtest engine · hakim.py Research assistant · bot.py Trading runtime
Components 21
Live trading
- Trading runtime
src/bot.py - Terminal client
src/mt5_client.py - Risk controls
src/risk.py - Order execution
src/executor.py - Trade database
src/db.py
Market analysis
- Symbol scanner
src/scanner.py - Market data
src/market_data.py - Technical indicators
src/indicators.py - Trade strategies
src/strategies
Local dashboard
- Web panel
src/panel/app.py - Dashboard queries
src/dashboard/queries.py - Queued commands
src/commands.py - Panel authentication
src/dashboard/auth.py - Panel simulation
src/panel/sim.py
Research and simulation
- Backtest engine
src/backtest/engine.py - Historical analogs
src/research/time_machine.py - News impact study
src/research/news_study.py - External history
src/external_history.py - Research assistant
src/hakim.py
Other components
- Bot owner
- MetaTrader 5
Connections 16
- Bot owner → Trading runtime: runs
README.md - Trading runtime → MetaTrader 5: connects
README.md - Trading runtime → Trade database: records trades
README.md - Web panel → Trade database: reads status
- Web panel → Panel authentication: authenticates
src/panel/app.py - Web panel → Dashboard queries: uses queries
src/panel/app.py - Web panel → Queued commands: queues commands
src/panel/app.py - Web panel → Panel simulation: uses simulation
src/panel/app.py - Backtest engine → Risk controls: applies checks
src/backtest/engine.py - Backtest engine → Market data: uses data
src/backtest/engine.py - Backtest engine → Symbol scanner: uses scanner
src/backtest/engine.py - Backtest engine → Technical indicators: computes indicators
src/backtest/engine.py - Panel simulation → Historical analogs: runs simulation
src/panel/sim.py - Research assistant → News impact study: uses study
src/hakim.py - Research assistant → Historical analogs: uses analogs
src/hakim.py - Research assistant → External history: uses history
src/hakim.py