Tarea técnica
I want to build a diversified portfolio of algorithmic trading EAs for MT5, designed specifically for long-term use with prop firms.
The objective is not to find one extremely profitable EA. The objective is to build multiple independent strategies that produce a smoother combined equity curve, low portfolio drawdown, and consistent returns across different market conditions.
Primary Portfolio Objectives
Design approximately 8–15 genuinely different EAs.
The portfolio should target:
- 5–10% average monthly portfolio return as an aspirational target, not a guaranteed requirement
- Low and controlled drawdown
- Maximum portfolio drawdown preferably below 5–8%
- Consistent performance rather than aggressive growth
- Profit Factor preferably above 1.30 per strategy
- Positive out-of-sample performance
- Robust performance across multiple years
- Survival through different volatility and market regimes
- Prop-firm rule compliance
Do not optimize purely for maximum historical profit.
Prioritize robustness, diversification, stability and capital preservation.
Portfolio Diversification
I do not want 10 variations of essentially the same strategy.
Build strategies from genuinely different trading concepts.
The portfolio should include a mixture such as:
Trend Following
Examples:
- EMA trend/pullback
- ADX trend
- SuperTrend
- Moving-average continuation
Breakout
Examples:
- London session breakout
- Asian range breakout
- ATR volatility breakout
- Donchian/channel breakout
Mean Reversion
Examples:
- Bollinger Band reversal
- RSI exhaustion
- Keltner/channel reversion
- VWAP reversion
Momentum
Examples:
- MACD momentum
- ATR momentum
- Candle/range expansion
- Momentum continuation
Reversal
Examples:
- Liquidity sweep
- False breakout
- Support/resistance rejection
- Exhaustion reversal
Swing
Include slower H1/H4 strategies capable of holding positions for several hours or days.
The final portfolio should therefore contain systems that can potentially perform during:
- Strong trends
- Ranging markets
- Breakouts
- High volatility
- Lower volatility
- Different trading sessions
Instrument Diversification
Research combinations across instruments such as:
- EURUSD
- GBPUSD
- AUDUSD
- USDJPY
- USDCHF
- XAUUSD
Do not automatically use every instrument.
Only retain symbol/strategy combinations that demonstrate robust results.
Avoid excessive USD exposure and highly correlated strategies.
Timeframe Diversification
Primarily investigate:
- M15
- M30
- H1
- H4
M5 can be considered where appropriate, but avoid creating a portfolio dominated by short-term systems.
Prop-Firm Risk Requirements
Every EA must:
- Use a hard Stop Loss
- Have the Stop Loss present immediately after entry
- Never use martingale
- Never use recovery trading
- Never use unlimited grids
- Never increase position size because previous trades lost
- Never average into losing trades as a recovery mechanism
- Avoid HFT behaviour
- Avoid excessive order frequency
- Use unique Magic Numbers
- Have configurable trading sessions
- Have configurable spread protection
- Support a high-impact-news filter or allow an external portfolio risk manager to block entries
- Support Friday/weekend restrictions
Default risk should be approximately:
0.10–0.25% per trade.
Maximum risk should remain configurable but conservative.
Portfolio-Level Risk
Assume a separate Portfolio Risk Core will supervise all EAs.
Design the individual EAs so they can work with portfolio controls including:
- Maximum daily loss
- Maximum total drawdown
- Maximum open portfolio risk
- Maximum simultaneous positions
- Maximum correlated exposure
- Daily trade limits
- News protection
- Friday/weekend protection
- Emergency equity lock
No individual EA should be capable of threatening the account by itself.
Strategy Development
For every strategy:
- Define the underlying market hypothesis.
- Explain why the edge could logically exist.
- Define the market regime in which it should perform.
- Define conditions where it should NOT trade.
- Build entry rules.
- Build exit rules.
- Implement ATR or structure-based Stop Loss.
- Implement appropriate Take Profit/trailing logic.
- Add spread and session protection.
- Add conservative position sizing.
Avoid adding unnecessary indicators merely to improve historical results.
Prefer simple strategies with understandable market logic.
Backtesting
Every EA must undergo:
Development Backtest
Use sufficient historical data covering different market regimes.
Out-of-Sample Testing
Reserve data that was not used for optimization.
Walk-Forward Analysis
The strategy should remain profitable across multiple optimization/test windows rather than relying on one historical parameter set.
Monte Carlo Testing
Test variations including:
- Trade order
- Entry timing
- Spread
- Slippage
- Strategy parameters
- Historical data variation where available
Parameter Stability
Look for broad stable parameter regions.
Reject strategies where profitability exists only around one exact parameter combination.
Cross-Market Testing
Where logically appropriate, test the strategy on additional related instruments.
The strategy does not necessarily need to be profitable everywhere, but its behaviour should help determine whether the underlying edge is genuine or overfit.
StrategyQuant Workflow
Where StrategyQuant X is being used, create reusable templates for:
Generation → Initial filtering → OOS → Monte Carlo → Trade manipulation → Randomized data → Parameter stability → Walk-forward → Tick retest → Final robustness → Correlation analysis.
Automatically reject weak strategies at early stages so computational resources are concentrated on stronger candidates.
Portfolio Selection
Do NOT simply select the EAs with the highest individual net profit.
Rank candidates using:
- Profit Factor
- Return/Drawdown ratio
- Maximum drawdown
- OOS performance
- Walk-forward performance
- Monte Carlo survival
- Parameter stability
- Trade count
- Average trade
- Monthly consistency
- Strategy type
- Symbol
- Timeframe
- Trading session
- Correlation with existing portfolio strategies
Portfolio correlation is extremely important.
Two excellent EAs with nearly identical return streams may be less valuable than two slightly weaker but genuinely uncorrelated strategies.
Final Portfolio Construction
Build the portfolio incrementally.
For every proposed EA, answer:
What does this EA add that the existing portfolio does not already have?
Reject redundant strategies.
The desired final portfolio might resemble:
- 2 Trend systems
- 2 Breakout systems
- 2 Mean-Reversion systems
- 1–2 Momentum systems
- 1 Reversal/Liquidity system
- 1 Swing system
The exact composition should be determined by testing rather than forcing these numbers.
Forward Testing
No strategy should immediately go onto a funded account.
Pipeline:
Strategy generation
→ Backtest
→ Robustness testing
→ Portfolio correlation analysis
→ Demo forward testing
→ Approximately 100–200 forward trades where practical
→ Compare expected vs actual behaviour
→ Approve or reject
→ Prop-firm deployment
During forward testing compare:
- Profit Factor
- Win rate
- Average win/loss
- Drawdown
- Trade frequency
- Holding time
- Slippage
- Monthly return
- Backtest vs forward-test divergence
Final Goal
Build a portfolio, not a collection of EAs.
I want each strategy to have a different job.
One strategy may perform during trends while another struggles. A range strategy may then perform when the trend strategy is flat. Breakout and swing strategies should add further independent sources of return.
The final measure of success is therefore not:
"Which EA made the most money?"
It is:
"Which combination of robust, independent strategies produces the most consistent return for the least portfolio-level risk and remains compliant with prop-firm rules?"
When developing or recommending strategies, always optimize toward that objective.