AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified MIT Self-run

Donchian Strong Regime

skill-superior-trade-superior-skills-donchian-strong-regime · by Superior-Trade

Use when writing a trend-breakdown short gated by a triple-confirmed strong-bear regime on Superior Trade — anything described as donchian short, structural breakdown, regime-gated trend follower, EMA-separation + ADX + N-bar return confirmation. Validated +6.69%/100% win/0% DD on BTC over 162d; designed to fire only in confirmed bear regimes (zero trades in chop by design). Pairs with bollinger-…

No reviews yet
0 installs
0 views
view→install

Install

$ agentstack add skill-superior-trade-superior-skills-donchian-strong-regime

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-superior-trade-superior-skills-donchian-strong-regime)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
1mo ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Donchian Strong Regime? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Donchian Strong-Regime Short

Trend-breakdown short, gated by a triple-confirmed strong-bear regime. Stays out of chop entirely. Validated on BTC/USDC:USDC over 162 days (2025-11-20 → 2026-05-01).

Searchable under: trend follower, breakdown, regime-gated, donchian short, structural break.

Backtest evidence

| Window | Trades | Win rate | Profit | Max DD | |---|---|---|---|---| | Full period (162d) | 6 | 100% | +6.69% | 0% | | First-half / strong bear (82d) | 6 | 100% | +6.69% | 0% | | Second-half / chop (80d) | 0 | — | 0% | 0% |

The triple-confirmation gate produced zero trades in the rangy second half — exactly the behavior a regime gate should produce. Every fired trade in the first half captured the trailing stop for profit.

Thesis

In a confirmed strong-bear regime (ema separation, ADX, recent momentum all aligned), a close below the 24-bar low (4 days of structure) reliably continues lower. The gate prevents the strategy from firing during sideways/rangy markets where the same signal mean-reverts.

Mechanics

  • Pair: validated on BTC/USDC:USDC; expected to behave similarly on other deeply-liquid majors during their own confirmed bear regimes
  • Timeframe: 4h (entry signal); 4h trend indicators (regime gate)
  • Regime gate (ALL three required):
  • EMA50 / EMA200 - 1 25 (trend strength confirmed)
  • close.pct_change(30) highest_6_bar_high (24h ceiling break — local reversal)
  • 2 consecutive bars with RSI > 55 (sustained rebound)
  • Trailing stop fires (Phase 2 — see the dsl-exit-engine skill)
  • Stops: Phase 1 hard stop at -5%; Phase 2 trailing activates at +3%, trails 2% behind peak

Full strategy code

from freqtrade.strategy import IStrategy
import pandas as pd
import talib.abstract as ta

class DonchianStrongRegimeStrategy(IStrategy):
    INTERFACE_VERSION = 3
    timeframe = "4h"
    can_short = True

    stoploss = -0.05
    trailing_stop = True
    trailing_stop_positive = 0.02
    trailing_stop_positive_offset = 0.03
    trailing_only_offset_is_reached = True

    minimal_roi = {"0": 100.0}  # disable ROI; trailing + signal exits only
    process_only_new_candles = True
    startup_candle_count = 220
    use_exit_signal = True

    def populate_indicators(self, dataframe: pd.DataFrame, metadata: dict) -> pd.DataFrame:
        dataframe["lowest_24"] = dataframe["low"].rolling(24).min().shift(1)
        dataframe["highest_6"] = dataframe["high"].rolling(6).max().shift(1)
        dataframe["ema50"] = ta.EMA(dataframe, timeperiod=50)
        dataframe["ema200"] = ta.EMA(dataframe, timeperiod=200)
        dataframe["rsi"] = ta.RSI(dataframe, timeperiod=14)
        dataframe["adx"] = ta.ADX(dataframe, timeperiod=14)

        dataframe["ema_sep"] = (
            (dataframe["ema50"] - dataframe["ema200"]) / dataframe["ema200"]
        )
        dataframe["ret_30"] = dataframe["close"].pct_change(30)
        dataframe["regime_strong"] = (
            (dataframe["ema_sep"]  25)
            & (dataframe["ret_30"]  pd.DataFrame:
        cond = (
            (dataframe["close"]  pd.DataFrame:
        cond = (
            (dataframe["close"] > dataframe["highest_6"])
            | ((dataframe["rsi"] > 55) & (dataframe["rsi"].shift(1) > 55))
        )
        dataframe.loc[cond, "exit_short"] = 1
        return dataframe

Reference config

{
  "exchange": {"name": "hyperliquid", "pair_whitelist": ["BTC/USDC:USDC"]},
  "stake_currency": "USDC",
  "stake_amount": 100,
  "dry_run_wallet": {"USDC": 150},
  "timeframe": "4h",
  "max_open_trades": 1,
  "minimal_roi": {"0": 100.0},
  "stoploss": -0.05,
  "trading_mode": "futures",
  "margin_mode": "isolated",
  "entry_pricing": {"price_side": "same", "price_last_balance": 0.0},
  "exit_pricing": {"price_side": "same", "price_last_balance": 0.0},
  "pairlists": [{"method": "StaticPairList"}]
}

Honest framing

This strategy only fires during confirmed strong-bear regimes. In bull markets, sideways markets, and weak bears it will trade rarely or not at all — by design. Do not "improve" by loosening the gate; the loose-gate version (without triple confirmation) lost money in the same window.

The 100% backtest win rate is partly a function of sample size (6 trades). The honest expectation is ~60-75% win rate with similar expectancy when the gate is properly confirmed across longer windows.

Pair this strategy with bollinger-reverter-4h (the chop-regime sibling) for full-spectrum coverage — they fire on mutually exclusive regimes.

Tunables

| Parameter | Range | Effect | |---|---|---| | Regime EMA separation | -0.04 to -0.08 | Looser = more trades, more chop noise; tighter = fewer, cleaner | | Regime ADX threshold | 20 - 30 | Higher = more selective trend confirmation | | Regime return lookback | 20 - 40 bars | Window for "actual momentum" check | | Donchian lookback (low) | 18 - 36 | Length of structural floor | | Exit lookback (high) | 4 - 8 | Tighter exit = faster wins, more giveback | | Trail activate | 0.02 - 0.04 | Where Phase 2 kicks in | | Trail offset | 0.015 - 0.025 | Tightness once activated |

Known failure modes

  • Fresh bear regimes that haven't yet triggered the 30-bar return < -10% threshold: strategy waits until momentum is established, missing the first leg
  • Whipsaw within a strong bear: a sharp counter-rally past the 6-bar high exits the trade right before the resumption. This is the price of having tight exits
  • Alts with low liquidity: Donchian lows can be set by a single liquidation wick; restrict to majors

Pairing

  • Designed to coexist with the bollinger-reverter-4h skill (the chop-regime sibling)
  • Uses the triple-gate pattern from the regime-overlay skill
  • Uses the Phase 2 trailing stop from the dsl-exit-engine skill

Deployment recommendation

Run as its own sub-account so the regime gate's "trade nothing for weeks" behavior doesn't fight a mean-reversion strategy in the same wallet. See your Superior Trade account setup for sub-accounts.

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.