Sentinel X Gold EA with AI Analysis MT5
- Experts
- Rabi Oudani
- Versione: 1.5
- Aggiornato: 9 aprile 2026
- Attivazioni: 5
Sentinel X AI - Gold Expert Advisor with AI-Powered Analysis
Sentinel-X AI is an automated Expert Advisor for MetaTrader 5 designed for Gold (XAUUSD) and other instruments. It combines a breakout trading strategy with an external GPT-based analysis module to assist with trade decisions.
This EA operates in dual-mode: a rule-based breakout system and an external signal analysis module that work together to identify potential trading opportunities.
PRICING INFORMATION
Current Price: $499
Note: The price may be raised to $1699 in the future.
Rental: 1 Month ($120) | 3 Months ($199)
Important:
This EA requires WebRequest connection to https://api.openai.com for the AI analysis feature. Please add this URL in Tools → Options → Expert Advisors → Allow WebRequest. If the external service is unavailable, the EA continues operating with the breakout strategy only.
This EA requires WebRequest connection to https://api.openai.com for the AI analysis feature. Please add this URL in Tools → Options → Expert Advisors → Allow WebRequest. If the external service is unavailable, the EA continues operating with the breakout strategy only.
How It Works
The Expert Advisor analyzes price action using pivot points and ATR-based calculations to detect potential breakout zones. When enabled, the analysis module sends market data to an external GPT-based service that returns signals with confidence levels.
Key components:
- Breakout Detection using pivot length and ATR calculations
- External Signal Analysis from GPT-based service
- Dual Order Management with separate magic numbers
- Dynamic Position Sizing with multiple methods
Dual Order Management System
The EA implements a dual-system order management architecture with complete separation between rule-based and AI-powered trading operations.
Order Identification:
- Sentinel-X Magic (Default: 888888): Orders from breakout strategy
- Sentinel-AI Magic (Default: 999999): Orders from signal analysis
- Order comments: "SENTINEL-AI LO" (Live), "SENTINEL-AI PO" (Pending)
This separation provides:
- Clear distinction in trade history
- Independent position limits per system
- Separate profit tracking
- Non-interference between strategies
AI Pending Order Management
Supported pending order types:
- BUY_STOP: Entry above price for breakout
- SELL_STOP: Entry below price for breakdown
- BUY_LIMIT: Entry below price for discount
- SELL_LIMIT: Entry above price for premium
Pending order features:
- Maximum 4 pending orders (configurable)
- Auto-expiry after configurable hours
- Smart cleanup preserves orders near trigger
- Signal can KEEP, CANCEL, MODIFY, or ACTIVATE orders
- Auto-correction of invalid entry prices against current market
AI Live Position Management
Live position controls:
- Maximum 1 live position (configurable)
- Signal can HOLD, CLOSE, MODIFY_SL, MODIFY_TP
- Real-time profit and pip tracking
- Independent from pending order limits
Execution Strategy Framework
Multi-Timeframe Analysis:
- H4: Long-term trend (EMA200)
- H1: Primary trading (Price Action, ATR)
- M15: Momentum confirmation (EMA9, RSI)
Market Structure Detection:
- UPTREND_HH_HL / DOWNTREND_LH_LL
- BULLISH_BREAKOUT / BEARISH_BREAKDOWN
- CONSOLIDATION patterns
Strategy Detection:
- Liquidity Sweep
- FVG Displacement
- Order Block
- Trend Following
- Breakout
- Momentum Scan
Confluence Indicators:
- RSI, MACD, Stochastic, ADX
- Bollinger Bands, Ichimoku
- Vortex, Volume Analysis
Key Levels:
- Weekly/Monthly pivots
- Previous day high/low
- Psychological levels
- London Fix timing
Risk Control Architecture
Pre-Trade Validation:
- Confidence vs threshold check
- Spread vs maximum allowed
- Margin availability
- Order count limits
- Duplicate trade protection
- Market regime filter
Position Sizing:
- LOT_FIXED: Static lot size
- LOT_RISK_PERCENT: Account percentage
- LOT_BALANCE_MULTIPLIER: Balance scaling
TP/SL Modes:
- TPSL_FIXED: User values
- TPSL_AI: ATR-based
- TPSL_HYBRID: Signal-based with caps
Features
Trading Logic:
- Breakout strategy with pivot length
- ATR-based stop loss and take profit
- Manual TP/SL override options
- Spread filter protection
Risk Management:
- Daily loss limit with auto pause
- Maximum trades control
- Consecutive loss pause
- Partial close at half TP
AI Integration:
- Four confidence levels
- Watchdog validation against 7 local indicators
- Market regime filter
- Pending order expiry
- Volume threshold filter
- HTTP 429 exponential backoff for API stability
News Filter:
- High/medium impact detection
- Configurable stop periods
- Close before news option
- Currency filtering
Additional:
- ATR-based trailing stop
- Step-based trailing option
- Real-time panel display
- Adaptive chart watermark
- Session awareness
Parameters
- Trading Mode: EA only, AI only, both
- Magic Numbers: EA (888888), AI (999999)
- Risk Settings: Spread, slippage limits
- Lot Sizing: Fixed, percent, balance
- AI Limits: Max pending (4), Max live (1)
- TP/SL: Fixed, AI, hybrid modes
- Trailing: ATR or step-based
- News: Impact levels, timing
- Protection: Daily limits, loss pause
Panel Display
- Broker information and spread
- Session status
- Signal direction and confidence
- Account balance, equity, P/L
- Order counts (P: pending | L: live)
- Signal status and detected strategy
Recommended Use
- Symbol: Gold (XAUUSD)
- Timeframe: H1
- Account: Hedge type recommended
- Testing: Use strategy tester before live trading
Requirements
- MetaTrader 5
- Demo or live account
- WebRequest enabled for https://api.openai.com
Risk Disclaimer
Past performance does not guarantee future results. This EA does not guarantee profits. Trading involves substantial risk of loss and is not suitable for all investors. Always test on a demo account first. Optimize settings for your broker conditions. Use at your own risk.
Support
Use the Comments section or MQL5 messaging for assistance.
A detailed user guide is available in my MQL5 Blog : https://www.mql5.com/en/blogs/post/767898
Version History
v1.04 - Stability & Safety Update
- AI Trade Mode selector — new input InpAITradeMode: choose between Live+Pending, Pending Only, or Live Only
- Same-zone pending order protection (FIX #6) — blocks new pending orders within 0.5× ATR of an existing one (prevents stacking at same price)
- Selective news close — pre-news cleanup now respects InpNewsStop: closes EA-only, AI-only, or both (v1.03 always closed everything)
- CloseTradesByMagic() and CancelAllPendingOrders() — new utility functions for per-magic order management

Rabi has been very supportive! I have been running Sentinel X for a week, and the new update has improved the EA performance much more. Strategy is safe and unique. Looking forward to the incoming results!