Algorithm factory: the step-by-step
The exact order to mass-produce robust algorithms: generate cheap and wide, deep-validate only the best, and build a diversified portfolio. Without this order you end up with pretty backtests that lose live.
An algorithm factory doesn't chase «the» perfect strategy. It mass-produces diverse strategies and keeps only the ones that survive hard tests. The key is a cost funnel: the cheap part (generating) is done in bulk; the expensive part (validating) is reserved for the few candidates that already showed good trades. This article is the exact order of the steps and which tool to use in each.
The golden rule: cheap and wide first, expensive and deep later. Generate hundreds of candidates with a short sweep; only on the best ones do you spend compute on 3-4 year validation. And never keep just one: the factory produces a diversified portfolio, not a champion.
The funnel in 6 steps
- 1
1. Pick the asset and reserve the last stretch
In the Algorithm Creator pick an instrument and timeframe (start with Gold, Nasdaq or DAX — the most trending; currencies last). Leave the last stretch of data out: it's the «surprise exam» the system must not see while generating. Never build up to yesterday.
- 2
2. Cheap sweep: generate quantity
Use genetic generation with ATR-based SL and TP (never fixed pips: ATR gives a variety of ratios, the raw material of portfolios). Sort by Calmar (return over drawdown, the right fitness). Run a few months, no validation yet: in minutes you have hundreds of candidates. Lowering filters here is a speed tool, not permissiveness — the real filter comes later by sorting.
- 3
3. Deep funnel: automatic validation
On the best candidates, the exploration already runs the Deflated Sharpe Ratio (is the result real or luck from testing a lot?) and the Multiverse (does it hold across different markets?). This replaces and surpasses manual crosschecks. No need to re-validate each one by hand: keep the ones that rise to the top after these tests.
- 4
4. Analysis and culling
Open the detail of the survivors. Look for: an equity curve that rises steadily, max drawdown in past years (if it survived the worst year, better sign), fast recovery from drawdowns, and a ratio suited to the goal (low ratio → prop funding). Keep 1-2 per indicator family, not all 10: the rest are usually the same strategy in disguise.
- 5
5. Build the diversified portfolio
Combine your best decorrelated algorithms into a Portfolio (base: Gold + DAX + Nasdaq). Check the correlation matrix: two algorithms with high correlation (>0.7) are the same bet — drop one. Run the portfolio's Monte Carlo: if the worst case exposes ~double the drawdown, it's fine; if it exposes triple, remove the most aggressive strategy and repeat.
- 6
6. Paper first, then live
Test on a paper account (one per asset to spot the «winning horse»). When you trust it, activate the live session directly on your broker (MT5 / cTrader / TopstepX / NT8) — the algorithm runs on TradingNote, no code export to the platform (cTrader and TopstepX connect with nothing to install; MT5 uses our bridge EA and NT8 our AddOn, one-time install). Define each account's goal and risk (the R) before starting, and don't touch the sizing during a bad streak: that's the mistake that ruins most people.
The non-negotiable principles
- Fitness by Calmar (return over drawdown), never by raw net profit.
- ATR-based SL and TP: they adapt risk to each era's real volatility and generate a variety of ratios.
- Decorrelated multi-strategy, not «the best one». Diversification is the key.
- Robustness over perfection: a few algorithms that hold up are worth more than many that only shine in the past.
The biggest mistake isn't technical, it's human: touching risk management or swapping algorithms mid-drawdown. A system profitable over years will have bad streaks at the start; if you halve the risk mid-fall, you have to recover it with half the force. The sizing you set at launch is the one that runs for up to a year. Don't touch.
Where to start
| Asset | Difficulty | Why |
|---|---|---|
| Nasdaq / DAX | Easy | Strongly up-trending indices — many good candidates come out. |
| Gold | Medium | Trending commodity; pair it with a short side (BOS) for corrections. |
| Currencies | Hard | Leave them for last: if you're not profitable on indices and gold, you'll get frustrated here. |
Repeat the cycle per asset. The factory isn't an event, it's a process: you build at night, analyze by day, and over time you have several diversified portfolios that support each other. That's the goal — not one brilliant algorithm, but a system that mass-produces robustness.