1. QUANTITATIVE COMPOSURE & THE DOCTRINE OF RESTRAINT
Sovereign represents a fundamental rejection of over-trading and retail market noise. Built natively in modular MQL5 for the MetaTrader 5 terminal, the system is governed by a singular, uncompromising directive: mathematical restraint. Rather than chasing every minor market tick to simulate value, the architecture operates as an elite gatekeeper. It is engineered to maintain absolute capital composure, actively filtering out marginal setups and entering the market only when multiple dimensions of mathematical confluence align.
The system understands that capital preservation is an active mathematical discipline, not a passive hope. By executing under a strict "gatekeeper" model, Sovereign suppresses decision fatigue and protects the portfolio from the emotional and cognitive load that compromises retail accounts.
2. SYNCHRONIZED MULTI-TIERED TREND ENGINE
To establish absolute directional alignment, Sovereign employs a synchronized multi-tiered trend detection engine that operates across several temporal hierarchies:
* Macro-Structural Filter (MN1 | W1 | D1): The system continuously monitors the deep structural bias of the market, evaluating moving average slope velocity and candlestick close relative to long-term valuation baselines. A unified trend bias is aggregated to ensure that intermediate execution only occurs in the direction of dominant, institutional capital flows.
* Intermediate Confirmation Filter (H4 | H1): The algorithm maps value areas and tracks structural pullback depth, confirming that intermediate price velocity is fully aligned with the macro trend before any micro-entry execution is triggered.
* Temporal Flexibility (Scalping | Intraday | Swing): The operator can configure Sovereign’s operational horizon to target specific duration profiles:
* SCALPING: Evaluates micro-liquidity pool entries on structural wicks, utilizing tight volatility-adjusted limits for rapid compounding.
* INTRADAY: Capitalizes on daily volume cycles, terminating active exposure within designated session boundaries to prevent overnight risk.
* SWING: Anchors entries to long-term macro pivots, utilizing structural boundaries to capture multi-day and multi-week expansion paths.
3. ADVANCED FIBONACCI REVERSAL ENGINE & LIQUIDITY ABSORPTION
Sovereign’s entry mechanism is built on the mathematics of market displacement and institutional liquidity capture:
* Discount Expansion Architecture (BUY Operations): Following a corrective displacement, the system targets key structural exhaustion extremes [1043]. By calculating the range of major swing pivots, Sovereign triggers execution at the precise 12.7% discount expansion boundary—capturing price when selling pressure has reached complete mathematical exhaustion.
* Premium Retracement and Trap Neutralization (SELL Operations): In a macro bearish environment, the system monitors price pullbacks into the deep harmonic 88.6% to 88.7% premium retracement zone. This is a critical liquidity pool where retail breakout buyers are historically absorbed by institutional market makers. Sovereign executes when the buyer trapping sequence is mathematically confirmed.
4. ASYMMETRIC CONFIRMATION GATING
The system strictly rejects blind limit placements or predictive guessing. To enforce absolute precision, entries are locked behind a dual-axis confirmation gate:
* Structural Exhaustion Filtering: The algorithm analyzes the precise anatomical rejection profile of the trigger candlestick. The bar must display significant wick expansion, confirming that liquidity has been swept and that the opposing force has successfully absorbed the move.
* Market Structure Shift (MSS) Validation: On the execution timeframe, Sovereign requires an instantaneous structural confirmation (such as a Break of Structure closing beyond local pivot points) to verify that momentum has officially shifted in the intended trade direction before capital is deployed.
5. AUTOMATED ECONOMIC BLACKOUT SHIELDS
Sovereign contains an integrated economic event calendar monitor. High-impact news releases (NFP, CPI, FOMC, and interest rate decisions) frequently cause severe slippage, spread blowouts, and artificial retail traps. Sovereign neutralizes this volatility through a configurable news blackout gateway, automatically halting entry execution N minutes prior to major releases and resuming trading M minutes post-event once market liquidity has stabilized.
6. INTEGRATED DEEP LEARNING INFERENCE MODULE
To elevate execution confidence, the system features a cutting-edge Machine Learning verification engine. Rather than relying solely on technical geometry, the system normalizes live features—including slope differentials, ATR volatility profiles, and Fibonacci proximity scores—into an optimized multidimensional tensor.
Directly inside the MT5 terminal’s core, a Deep Learning model performs rapid, hardware-accelerated forward-pass inference. Sovereign evaluates the resulting probabilistic distribution [P_Sell | P_Hold | P_Buy], requiring the neural model to confirm the technical trade with high-confluence confidence before the execution wrapper permits order dispatch.
7. INSTITUTIONAL RISK PRESERVATION & PROP-FIRM CIRCUIT BREAKERS
Sovereign’s risk architecture is engineered specifically for institutional capital preservation and strict prop-firm compliance (compliant with FTMO, Funded Next, and other major funding gates):
* Dynamic Risk-to-Equity Scaling: Transaction volume is computed dynamically per trade based on live account equity, symbol tick value, and volatility distance to the stop loss, ensuring that risk remains perfectly scaled and consistent.
* Continuous Drawdown Gateways: The risk engine continuously monitors intra-day equity fluctuation. If the day's floating and realized losses approach the pre-defined Daily Drawdown or Trailing Maximum Drawdown thresholds, Sovereign triggers an immediate, emergency portfolio liquidation, shutting down all active modules to protect the account’s funding status.
* Consecutive Losses Cooldown: To prevent trading through unpredictable, highly volatile market phases, Sovereign enforces a mandatory cooldown period if a sequence of consecutive losses is encountered, allowing market conditions to normalize before resuming operations.
* Weekend Gap Protection: The system neutralizes weekend black-swan events by executing automated pre-weekend liquidations on Friday evening, canceling all pending orders and securing existing gains.
8. MULTI-STAGE TRADE LIFECYCLE MANAGEMENT
Once an execution gate is passed, the position is monitored by an active, multi-stage trade management wrapper:
* Asymmetric Exit Modeling: Every position is entered with a pre-configured, volatility-buffered Stop Loss based on ATR coefficients and structural swing boundaries, paired with opposing Fibonacci projection targets.
* Dynamic Breakeven Migration: Upon reaching a key volatility expansion milestone, Sovereign automatically migrates the Stop Loss to the exact entry price plus a commission/spread buffer, locking in risk-free execution.
* Dynamic Trailing Stop: Sovereign provides a flexible, trailing protocol that can trail positions behind dynamic ATR volatility envelopes, local structural swing pivots, or fixed mathematical increments.
* Partial Volume Harvesting: At predetermined risk-to-reward targets, the system secures capital by closing a percentage of the volume (e.g., 50%), allowing the remainder to run risk-free under trailing protection.
9. ON-CHART HUD TELEMETRY DASHBOARD
A responsive, high-definition graphical interface is rendered directly on the chart window using native object terminal controls, displaying real-time system performance:
* Equity & Risk Telemetry: Displays current account balance, live equity, daily floating drawdowns, and compliance status.
* Hierarchical Timeframe Matrix: Visualizes the real-time structural trend bias across five separate timeframes simultaneously.
* AI Status HUD: Displays the ONNX deep learning readiness, model prediction scores, and real-time neural confidence.
* Execution Reason Telemetry: Sovereign displays an active logic message, informing the operator exactly what the algorithm is observing or why it is waiting (e.g., "WAITING: Multi-Timeframe Alignment", "ECONOMIC BLACKOUT ACTIVE", "AI CONFIDENCE BELOW THRESHOLD")
E________________________________________________________________________________________________________________________________E
Hereby I attach the definition of each input parameter:
1. Operational Mode & Execution Timeframe
- Trading Horizon: Preset style of trading: Scalping (M1/M5 execution), Intraday (M15/H1), or Swing (H4/D1). It sets which timeframes the EA executes and reads trend on.
- Execution Timeframe: The chart timeframe used for entries. “current” follows whatever chart the EA is attached to (or the tester’s timeframe).
2. Multi-Timeframe Trend Analysis (EMA 10/23)
- Fast EMA Period (10): Short exponential moving average that reacts quickly to price.
- Slow EMA Period (23): Longer EMA. The fast EMA being above or below it defines trend direction, and the EA only looks for reversals/pullbacks in line with that trend.
3. Fibonacci Reversal Geometry
- Structural Pivot Lookback Bars (100): How many bars back to search for the swing high/low that the Fibonacci levels are drawn from.
- Minimum Rejection Wick % of Total Bar (30): A candle must have a wick at least this percent of its full range to count as a rejection (price pushed into a zone and was turned back).
- Zone Touch Tolerance in Points (25): How close price must come to a Fibonacci level to count as touching it.
4. Risk-Based Lot Sizing & Prop-Firm Protection
- Lot Sizing Mode: Fixed lot, or dynamic lot based on a risk percentage of equity.
- Risk % of Equity per Trade (1.0): With dynamic mode, lot size is calculated so that hitting the stop loss loses about 1% of equity.
- Fixed Lot Size (0.01): Used only when the mode is Fixed.
- Maximum Concurrent Open Positions (1): Cap on simultaneously open trades.
- Maximum Allowed Spread (30 points): No new trades if the spread is wider than this.
- Max Daily Loss % (2.0): Circuit breaker. If the day’s loss reaches 2%, trading stops until the next day.
- Max Account Peak Drawdown % (5.0): Kill-switch. If equity falls 5% from its peak, the EA stops trading.
- Kill-Switch Stays Locked After Breach: If true, the EA stays disabled after the kill-switch fires. False is meant for testing only, so it can resume.
- Minimum Closed Trades Before Stats Are Considered Reliable (20): Number of trades needed before the EA trusts its own performance statistics.
- Consecutive Loss Streak for Cooldown (3): After 3 losses in a row, the EA pauses.
- Mandatory Cooldown Period (60 min): How long that pause lasts.
- Enable Weekend Gap Protection: Closes or stops trading before the weekend to avoid gap risk.
- Friday Close Hour (21) / Friday Close Minute (30): Server time at which that Friday shutdown happens (21:30).
5. Advanced Trade Management & Dynamic Exits
- ATR Volatility Buffer for SL (1.5): Stop loss is placed beyond the structure level by 1.5 × ATR (average true range), so it adapts to volatility.
- Take Profit Mode: Fixed risk-to-reward ratio, Fibonacci extension targets (127.2% / 161.8%), or a fixed points target.
- Risk-to-Reward Ratio (2.0): With TP = RR, the target is 2× the distance to the stop.
- Enable Breakeven Migration: Moves the stop to breakeven once the trade is in profit enough.
- Profit to Trigger Breakeven (500 points): Profit level that activates the move.
- Breakeven Profit Lock Offset (50 points): The stop goes to entry plus 50 points rather than exactly entry, locking in a small gain.
- Dynamic Trailing Stop Mode: Disabled, fixed distance, ATR volatility trailing, or structural swing high/low trailing.
- Trailing Start Profit (600 points): Profit needed before trailing begins.
- Fixed Trailing Distance (400 points): Gap between price and stop in fixed mode.
- Trailing Step Increment (50 points): The stop only moves in steps of at least this size, to avoid constant tiny modifications.
- ATR Multiplier for Trailing (1.5): Trailing distance in ATR mode.
- Enable Partial Profit Harvesting: Closes part of the position at an intermediate target.
- Risk:Reward to Harvest Partial Profit (1.5): The reward multiple at which the partial close happens.
- Partial Volume to Close % (50): Share of the position closed at that point.
6. Macroeconomic News Filter
- Enable News Blackout Window: Pauses trading around high-impact news events.
- Blackout Minutes Before / After Event (15 / 15): The no-trade window around each event.
- Use Manual Scheduled Time Window: Lets you define your own blackout time instead of using the calendar.
- Scheduled News Hour / Minute (14 / 30): The time of that manual blackout (14:30).
Notes
- Points vs pips: A point is the smallest price increment of the symbol, so on most 5-digit forex pairs 10 points = 1 pip, and on gold it depends on the broker’s digits. Check this before judging values like 500 or 600 points.
- Start/Step/Stop/Steps columns: Only used for optimization. For example, “Steps 91” just means how many values the optimizer would test between Start and Stop.