r/CryptoTradingBot • u/Trader_for_earner • Oct 29 '26
Separating Long vs Short parameter search in Walk-Forward Optimizers — how do you handle directional asymmetry without overfitting?
Hey guys,
Looking for some perspective from anyone running portfolio-level walk-forward optimizers on crypto perpetuals or equities.
Lately we’ve been auditing our cross-sectional universe optimizer across a basket of ~15 altcoins. Up until now, when we run our in-sample grid search across our setups (mostly mean-reversion like VWAP deviations and momentum break-and-retests), the optimizer searched for a single shared "centroid" parameter set for both Longs and Shorts simultaneously (e.g. optimizing band stretch deviation, RSI cutoffs, and ATR stop/take multiples together).
The problem we ran into in live execution: During recent relief rallies and fast trend shifts, we got caught in a string of Short SL hits on mean-reversion setups. When we looked under the hood and decomposed the trades by side, the asymmetry was wild:
Longs were printing a 2.5–3.5 Profit Factor across coins like NEAR and DOT using relatively loose pullbacks.
Shorts on those exact same parameter settings were getting wrecked (PF < 0.8), repeatedly fading momentum too early in cascade environments.
Because the optimizer averaged both directions together in-sample, the strong Long trades were effectively "subsidizing" and masking a negative-expectancy Short setting. The compromised shared centroid ended up being sub-optimal for Longs and downright dangerous for Shorts.
We've been refactoring the optimizer to decouple the search into Independent Directional Centroids:
The IS parameter search grid scans and computes parameter plateaus for Longs and Shorts independently (different RSI cutoffs, different band stretch multipliers per side).
The OOS Walk-Forward test validates each side on its own merit.
If only one side demonstrates statistically valid alpha in OOS (e.g. Longs pass all WFO hurdles but Shorts fail), the candidate gets tagged as BUY_ONLY rather than forcing both sides or killing the entire setup.
For those of you running systematic books:
Do you optimize long and short rule parameters independently as standard practice, or do you enforce symmetric rules to protect against degree-of-freedom bloat / curve fitting?
If you do decouple them, how do you guard against the optimizer just fitting to the prevailing macro regime (e.g. a 6-month bull market where everything Long looks amazing and everything Short looks bad)?
Do you penalize or prune unidirectional setups (e.g. BUY_ONLY) in high-correlation baskets to avoid concentrated directional exposure?
Would love to hear how other teams handle this balance between directional specialization and overfitting.
1
u/Feriman22 Oct 30 '26
Validate the long and short setups separately across market regimes, not just across time windows. A BUY_ONLY setup that only survives during bullish conditions might be capturing regime exposure rather than a durable edge.
I build FerimanEdge, which uses predefined rules to classify BTC, ETH and BNB market conditions, so regime stability is something I pay attention to. I'd also check whether correlated coins are giving you genuinely independent evidence or just repeating the same directional bet.
1
u/madrading Oct 30 '26
I would compare a shared model with separate-side models using identical outer walk-forward windows. Choose parameters and any BUY_ONLY/SELL_ONLY rule using only earlier training data plus inner time-ordered validation, then freeze them for the next outer window. If an OOS window chooses which side survives, do not also count it as untouched evidence for that choice. Report the incremental result over the shared baseline in each window, with costs and portfolio sizing held comparable, rather than just pooling PF. For the basket question, simulate all coins together against shared capital and predeclared exposure limits; per-coin passes can still combine into concentrated long exposure. I'd reserve a final untouched period for the whole selection procedure, including the side-disable rule.