Automated Trading Bot — Stocks & Forex
Overview of an automated trading bot that executes trades from technical signals, news, and group inputs.
Automated Trading Bot — Stocks & Forex
I built several automated trading systems for forex, stocks, and commodities to address two recurring problems I observed in a day-trading community: emotion-driven decisions and the time required to trade effectively.
Why I built this
- Pain points: Traders struggle with emotions (fear/greed) and lack time to monitor markets.
- Opportunity: Consistent rules and automation reduce emotional mistakes and can execute ideas 24/7 across time zones.
Forex / MetaTrader bot (MQL)
After learning the Fair Value Gap (FVG) candle strategy, I decided to implement an automated version in MetaQuotes Language (MQL). I built the bot from the ground up and iterated it with feedback from friends in the group.
Key capabilities:
- Implements Fair Value Gap and complementary candle/indicator filters
- Executes trades automatically (buy/sell), 24/7
- Automated take-profit and stop-loss management
- Automatic lot sizing based on risk rules, removing manual lot calculations
- Exports trade logs for comparison against expert day-trader decisions
Advanced features added later:
- Trend recognition (higher highs / higher lows) to filter trades against the trend
- Adaptive take-profit targets that reference recent swing highs/lows
- News-awareness database: the bot avoids opening and will close positions around high-impact events, just as a human would
Why these matter:
- Automatic lot sizing removes a frequent source of human error
- Trend filtering improves signal quality and reduces losing trades taken against momentum
- News-aware behavior prevents large slippage and unexpected volatility
Python bots for stocks & commodities + signal aggregator
I also developed multiple Python bots for equities and commodities using indicator and candle-based strategies. A community member suggested adding curated Telegram signal groups to our portfolio, which introduced a new challenge: extracting structured trade instructions from narrative text.
What I built:
- A Telegram signal scraper that follows 20+ public groups
- A ChatGPT-based parser (I used GPT-4 at the time) that converts narrative signals into discrete, machine-readable trade instructions
- A Discord relay and two Discord bots: one to post parsed signals to our group, and another to automatically place trades from those messages
Outcomes:
- The system takes >90% of trades signalled by the monitored groups automatically
- It captures opportunities while we sleep (we’re based in Europe/Asia) and avoids emotion-based hesitation
- Using public tools and models enabled rapid prototyping and a surprisingly high-value outcome
Results & learnings
- Automation substantially reduced missed trades and emotional mistakes.
- Combining signal sources (indicators + curated groups) improved diversification of ideas.
- Parsing narrative signals required an LLM layer to convert human language into precise instructions.
- Proper risk controls (auto-sizing, stop-loss, news filters) are essential for long-term robustness.
Why I enjoy this work
I love automating repetitive, error-prone tasks so we can focus on creative and strategic work. Building these bots satisfied that itch while delivering tangible value to a community of traders.
I would love to explain in detail!
If you’d like, we can talk more in detail at hi@nicmation.com. And if you have a trading idea and want to make it run by itself, contact me to talk about it!