Skip to content
All strategies

Strategies

FengkieJ Jesse SMACrossover: LTC Hyperliquid 4H, Fixed SMA50/200 Long–Short

Outcome: Abandoned

FengkieJLtcHyperliquidSmaRelationship

Outcome Summary

After four iterations, the faithful SMA50/200 long–short port reached backtest review with corrected sizing drift and reconciled accounting. Its 41 closed positions produced a -89.68% return, -0.966 Sharpe, and 93.39% maximum drawdown. Review abandoned the run because losses persisted before commissions and modeled impact, while the fixed source contract offered no parameters to optimize. Optimization and later review stages were not reached.

Hypothesis

Faithful port of FengkieJ's MIT-licensed Jesse SMACrossover: https://github.com/jesse-ai/example-strategies/blob/7c91e0a37bf62165790120d730442e4f6eb00364/SMACrossover/__init__.py. Preserve the exact 50-bar and 200-bar close-price simple moving averages and strict inequality rules. Despite the crossover terminology, the code tests the current SMA relationship, not a crossing event. The source specifies neither an instrument nor a timeframe; this platform experiment selects LTCUSD.HYPERLIQUID on completed 4-HOUR bars. Translate source entries at self.price into market orders at the signal bar's close. Preserve full-balance, fee-adjusted sizing at 1x exposure and exits only on the opposite SMA relationship. Add no stop-loss, target, trailing stop, funding filter or time stop. All performance expectations below are unverified predictions.

The submitted code is a concrete strategy and warrants faithful testing despite the saturated generic trend family. Hyperliquid is underrepresented at 10.3% versus its 20% target, and the long–short rule addresses the portfolio's 80.8% long-only concentration. LTC avoids another BTC experiment; the supplied corpus_concentration is empty, so its individual historical share cannot be established. Four-hour bars offer substantially more Hyperliquid history than sub-hourly bars. Single-instrument scope is retained because adding a basket or hedge would change the source.

Measured negative expectancy in this fixed SMA50/200 long–short port on LTC Hyperliquid 4H. Reject optimization because losses persist before commission and impact, not because of drawdown alone or predicted statistical failure. This verdict covers the platform-selected instrument/timeframe, not every application of FengkieJ's source strategy.

Implementation

Faithful SMA50/200 relationship strategy on completed LTC Hyperliquid 4-hour bars: long when SMA50 exceeds SMA200, short when it is below, and exit only on the opposite relationship. Uses full available fee-adjusted balance at 1x exposure without stops or targets.

The smallest correction to previous_code accumulates last_qty.as_decimal() using Decimal arithmetic, stores the exact quantity as a restart-persisted string scalar, and reconciles against exact cached quantities on position-close events, resetting fully closed exposure exactly to zero. This prevents partial-fill rounding residuals from blocking future entries or accruing phantom funding. SMA computation, strict inequalities, order sequence and sizing economics remain unchanged. One losing sandbox trade is insufficient evidence to abandon the mechanism. Verification remains the pipeline's responsibility. The requested outbox file could not be written because this session has read-only filesystem access; the complete bound JSON is returned directly.

Verification Results

The sandbox reports 41 closed trades, -4.91% average net trade return and 93.39% drawdown. These warrant full-history economic review but do not establish a correctness defect. Hyperliquid round-trip taker commission is 0.09%, before impact and funding.

Backtest Review

Sharpe
-0.97
Total return
-89.68%
Max drawdown
93.39%
Trades
41
Win rate
19.5%
Profit factor
0.21

41 closed positions alternate long and short around SMA relationship changes; sampled reversals match the supplied forecasts.

Reported entry leverage is 0.90–1.00, supporting correction of the previously observed sizing drift; accounting reconciles.

Average net trade return is -4.906% versus the supplied Hyperliquid review floor of +0.15%; PF is 0.208 and total return is -89.68%. QA's economic concern is borne out.

Summed price PnL is -$77,863 and funding contributes another -$11,812 loss. Removing commission and modeled impact would not recover positive expectancy.

Both directions and every reported calendar year lose money. Drawdown is 93.39%; buy-and-hold returned -25.05% with 62.72% drawdown.

The faithful source contract fixes SMA50/200 and exposes no tunable parameters, so optimization has nothing to search.

Analysis

Reconcile entry notional against cost-adjusted available equity at every reversal. Include commissions, accrued funding and modeled impact in the sizing ledger, and prevent entries after capital exhaustion. Investigate why the framework equity helper permits the observed exposure drift; the exact cause is not independently verified. Preserve SMA50/200, strict inequalities and opposite-relationship exits. Rerun the corrected frozen baseline before optimization.

Iteration History

Verification failed (Layer 1.5 — hypothesis/config consistency) [class=hypothesis_mismatch]: - optimization_plan fixes bar_interval at 4-HOUR

Verification failed (Layer 4 — QA review) [class=code_defect]: - [edge_concern] The sandbox has only one closed trade, returning -1.276% of notional. This is insufficient to assess profitability and is not the reason for failure. - [critical] The fill ledger accumulates signed quantities as floats at lines 103–106, but position_size requires an exactly zero ledger before allowing another entry. Partial fills can leave a nonzero rounding residual after the actual position closes: BUY 0.1, BUY 0.2, SELL 0.3 leaves 5.551115123125783e-17. Every subsequent entry then returns zero size despite the cache showing no position. Funding also continues accruing against this phantom quantity. This defect is demonstrated arithmetically; the supplied sandbox metrics do not establish whether it caused the single-trade result. (line 156) — fix: Accumulate fill quantities using Decimal from last_qty.as_decimal(), preserving exact instrument precision. Reconcile the ledger to the actual position on position-close events and reset it exactly to zero when fully closed.

Accumulate fill quantities using Decimal from last_qty.as_decimal(), preserving exact instrument precision. Reconcile the ledger to the actual position on position-close events and reset it exactly to zero when fully closed.

The fill ledger accumulates signed quantities as floats at lines 103–106, but position_size requires an exactly zero ledger before allowing another entry. Partial fills can leave a nonzero rounding residual after the actual position closes: BUY 0.1, BUY 0.2, SELL 0.3 leaves 5.551115123125783e-17. Every subsequent entry then returns zero size despite the cache showing no position. Funding also continues accruing against this phantom quantity. This defect is demonstrated arithmetically; the supplied sandbox metrics do not establish whether it caused the single-trade result.

Outcome Summary

The negative result applies to the selected LTC Hyperliquid 4-hour implementation, rather than every application of the source strategy.

Backtest review chose abandon because negative expectancy persisted even before commissions and modeled impact. The faithful port had no tunable parameters, so optimization and later review stages were not reached.

Port FengkieJ’s fixed SMA50/200 relationship rules to LTC Hyperliquid 4-hour bars, trading long and short at 1x exposure and exiting only on the opposite SMA relationship.

The backtest returned -89.68% with a Sharpe ratio of -0.966 across 41 closed positions. Maximum drawdown was 93.39%, profit factor was 0.208, and average net trade return was -4.906%.

Analysis

SMACrossover

Backtest and paper results are hypothetical. Trading involves risk of loss.