Agent skill

Regime Overlay

by Superior-Trade in Superior-Trade/superior-skills

A skill your agent uses when adding a regime filter to any directional strategy — regime gate, trend filter, directional confirmation, ADX gate, EMA-separation filter, trade-or-skip overlay.

MITAuto-check passedBusiness, Finance & HR

Install Regime Overlay

skills CLI
$ npx skills add Superior-Trade/superior-skills --skill regime-overlay -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install Superior-Trade/superior-skills regime-overlay --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/Superior-Trade/superior-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/regime-overlay .claude/skills/regime-overlay && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
regime-overlay
GitHub stars
215
Token cost
~1.3k tokens
SKILL.md length
555 words
Files
1
Skills in repo
31
Repo updated
First seen
Licence
MIT

At a glance

A skill your agent uses when adding a regime filter to any directional strategy — regime gate, trend filter, directional confirmation, ADX gate, EMA-separation filter, trade-or-skip overlay.

  • Adding a regime filter to any directional strategy — regime gate
  • SKILL.md covers Why a separate primitive, The three confirmations, Implementation and Expected behavior, plus 4 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md
  • Directional confirmation

What it does

Regime Overlay is an agent skill from Superior-Trade/superior-skills. Use when adding a regime filter to any directional strategy — regime gate, trend filter, directional confirmation, ADX gate, EMA-separation filter, trade-or-skip overlay. Provides three reusable gates (regimestrongbear, regimestrongbull, regimerange) that wrap entry signals with triple confirmation.

Its SKILL.md is about 1.3k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Business, Finance & HR, covering Trading and backtesting. The repository describes itself as: Open agent skills and tool schemas for Superior Trade — build, backtest, and deploy trading strategies on Hyperliquid. The licence is MIT.

When your agent uses it

  • Adding a regime filter to any directional strategy — regime gate
  • Directional confirmation
  • EMA-separation filter
  • Trade-or-skip overlay

Example prompts

  • “/regime-overlay”

Requirements

  • Python 3

What it can do on your machine

Read from SKILL.md and the folder at commit 9d41db5. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are python).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Regime Overlay loads about 1.3k tokens when it runs. Until then it costs about 80 tokens; SKILL.md has 555 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~80
When it runs · the whole SKILL.md, loaded when a task matches
~1.3k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from Superior-Trade/superior-skills at commit 9d41db5, republished under its MIT licence (© Superior-Trade). 555 words, ~1,323 tokens.

Download SKILL.mdSave it as .claude/skills/regime-overlay/SKILL.md (or your agent's skills folder).
name
regime-overlay
description
Use when adding a regime filter to any directional strategy — regime gate, trend filter, directional confirmation, ADX gate, EMA-separation filter, trade-or-skip overlay. Provides three reusable gates (regime_strong_bear, regime_strong_bull, regime_range) that wrap entry signals with triple confirmation.
metadata.version
0.1.0
metadata.updated
2026-05-18

Regime Overlay — Triple-Confirmation Gate

A reusable filter that wraps any directional strategy and only allows entries when three independent regime confirmations align. Validated as the difference between a fragile and a robust trend strategy.

Searchable under: regime filter, trend gate, trade-or-skip filter, directional confirmation, ADX gate.

Why a separate primitive

After 21 backtests, the single biggest performance lever was not entry logic, stop sizing, or trailing config. It was whether the strategy traded at all during specific market structure.

The proof:

  • Same Donchian-breakdown short on BTC 4h, no regime gate → +12.85% over 162d (looks great)
  • Same strategy, on a different window (the rangy second half) → -4.32% (edge gone)
  • Same strategy with triple-confirmed regime gate → +6.69% with 0% drawdown, fires zero trades in the chop window

The first version captured a real edge mixed with random noise. The third version captured only the real edge. Smaller absolute return; cleaner equity curve; no losing periods.

The three confirmations

A signal is "in regime" when ALL three of these hold simultaneously:

IndicatorThresholdWhat it confirms
(EMA50 - EMA200) / EMA200< -0.06 (for bear)Structural trend direction — not a fresh cross, real separation
ADX(14)> 25Strength of the current trend
close.pct_change(30)< -0.10 (for bear)Recent momentum is actually moving

Three independent angles — structure, strength, recency. A market can satisfy any one or two by accident; satisfying all three is genuinely rare and genuinely informative.

For long-side strategies, invert the signs:

  • (EMA50 - EMA200) / EMA200 > +0.06
  • ADX(14) > 25 (same — ADX is direction-agnostic)
  • close.pct_change(30) > +0.10

Implementation

python
def regime_strong_bear(df: pd.DataFrame) -> pd.Series:
    ema50 = ta.EMA(df, timeperiod=50)
    ema200 = ta.EMA(df, timeperiod=200)
    adx = ta.ADX(df, timeperiod=14)
    ema_sep = (ema50 - ema200) / ema200
    ret_30 = df["close"].pct_change(30)
    return (ema_sep < -0.06) & (adx > 25) & (ret_30 < -0.10)


def regime_strong_bull(df: pd.DataFrame) -> pd.Series:
    ema50 = ta.EMA(df, timeperiod=50)
    ema200 = ta.EMA(df, timeperiod=200)
    adx = ta.ADX(df, timeperiod=14)
    ema_sep = (ema50 - ema200) / ema200
    ret_30 = df["close"].pct_change(30)
    return (ema_sep > 0.06) & (adx > 25) & (ret_30 > 0.10)


def regime_range(df: pd.DataFrame) -> pd.Series:
    adx = ta.ADX(df, timeperiod=14)
    return adx < 25

The range-regime check is the opposite end of the spectrum — useful for gating mean-reversion strategies (see bollinger-reverter-4h).

Expected behavior

Apply this overlay to any signal-driven entry. The cost is fewer trades; the benefit is the trades you do take fire in the right environment.

StrategyWithout overlayWith overlay
Donchian breakdown BTC23 trades, 56.5% win, +12.85%, 3.69% DD6 trades, 100% win, +6.69%, 0% DD
(Same, second-half only)8 trades, 25% win, -4.32%0 trades, no PnL

The overlay traded the second column's win rate and drawdown for the first column's absolute return. Most production strategies should prefer the second column.

Show full SKILL.md (205 more words)Show less

Tunables

ParameterConservativeAggressiveNotes
EMA separation threshold0.080.04Tighter = wait for deeper structural moves
ADX threshold3020Higher = stricter trend-strength requirement
Return lookback bars4020Window for "actual momentum" check
Return threshold0.150.06How much momentum needed

Start conservative (0.06 / 25 / -0.10). Loosen only if the gate eliminates so many trades that the strategy's edge can't compound.

What this is NOT

  • Not a signal in itself. The overlay only says "regime is right"; it doesn't tell you when to enter
  • Not magic. In an environment where the historical regime gate would never fire (e.g., a yearlong sideways grind), the strategy simply stays out. That's the feature
  • Not a replacement for stops or take-profit. Even regime-confirmed signals fail individually

When NOT to use a regime gate

  • Mean-reversion strategies (bollinger-reverter-4h) work IN range regimes — use regime_range (ADX < 25) instead of bear/bull strong gates
  • Funding-carry strategies that earn rebates rather than directional moves
  • Pair-arbitrage or basis-arb strategies where the edge is structural, not regime-conditional

Pairing patterns

Most directional strategies in this repo benefit from this overlay:

  • donchian-strong-regime — uses bear overlay (validated)
  • Any custom trend-follow strategy

The overlay file itself is regime-agnostic — it provides functions for both bear and bull, and a range complement.

© Superior-Trade, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in skills/regime-overlay of Superior-Trade/superior-skills.

Open the folder on GitHubat commit 9d41db5

Compare with similar skills

Regime Overlay next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Regime Overlay compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Regime Overlay this skillSuperior-Trade/superior-skills215—~1.3kAutomated safety check: PassMIT
Tushare Datazillionare/zillionare3222 repos~2.3kAutomated safety check: PassNone
Tradingview MCPatilaahmettaner/tradingview-mcp5k—~1.3kAutomated safety check: PassMIT
Digital Oraclekomako-workshop/digital-oracle878—~5.9kAutomated safety check: PassMIT
Polyclawchainstacklabs/polyclaw3591 repos~2kAutomated safety check: PassApache-2.0
Markdownfacioquo/stock-indicators-dotnet1.2k—~812Automated safety check: PassApache-2.0

Similar skills

  • Tushare Data

    zillionare/zillionare

    面向中文自然语言的 Tushare 数据研究技能。用于把“看看这只股票最近怎么样”“帮我查财报趋势”“最近哪个板块最强”“北向资金在买什么”“给我导出一份行情数据”这类请求,转成可执行的数据获取、清洗、对比、筛选、导出与简要分析流程。适用于 A 股、指数、ETF/基金、财务、估值、资金流、公告新闻、板块概念与宏观数据等研究场景。

    322 GitHub starsUsed in 2 repos~2.3k tokens
    Business, Finance & HRAuto-check passed
  • Tradingview MCP

    atilaahmettaner/tradingview-mcp

    AI Trading Intelligence — live prices, 30+ technical indicators, backtesting (6 strategies), walk-forward overfitting detection, trade logs, equity curves, licensed news sentiment (Marketaux), and…

    5k GitHub stars~1.3k tokensUpdated yesterday
    Business, Finance & HRAuto-check passed
  • Digital Oracle

    komako-workshop/digital-oracle

    Answer prediction questions using market trading data, not opinions.

    878 GitHub stars~5.9k tokensUpdated 2 mo ago
    Business, Finance & HRAuto-check passed
  • Polyclaw

    chainstacklabs/polyclaw

    Trade on Polymarket via split + CLOB execution. An agent skill from chainstacklabs/polyclaw.

    359 GitHub starsUsed in 1 repo~2k tokens
    Business, Finance & HRAuto-check passed
  • Markdown

    facioquo/stock-indicators-dotnet

    Format and lint Markdown in this repository against GitHub Flavored Markdown and its markdownlint-cli2 configuration — headers, lists, code fences, callouts (VitePress containers on docs-site pages…

    1.2k GitHub stars~812 tokensUpdated yesterday
    Business, Finance & HRAuto-check passed
  • Openmobius Skill

    MobiusQuant/OpenMobius-skill

    Provides multi-school trading Q&A, chart/OHLCV analysis, annotation, and fresh-market workflows covering ICT/SMC, ChanLun, Wyckoff, Price Action, Order Flow, VSA, and Elliott Wave.

    697 GitHub stars~7.2k tokensUpdated 1 mo ago
    Business, Finance & HRAuto-check passed

More from Superior-Trade/superior-skills

All 31 skills in this repo
  • Superior Trade Auth

    Superior-Trade/superior-skills

    A skill your agent uses when an agent needs to register a Superior Trade account, verify an email OTP, configure x-api-key authentication, or recover from missing or invalid credentials before using…

    215 GitHub stars~950 tokensUpdated 1 mo ago
    Auto-check passed
  • Deposit Qr

    Superior-Trade/superior-skills

    A skill your agent uses when a user needs a QR code or wallet payment URI to fund a Superior-managed EVM wallet on a specific chain before using Lighter, Polymarket, Hyperliquid, or other Superior…

    215 GitHub stars~1.1k tokensUpdated 1 mo ago
    Auto-check passed
  • External Deposit

    Superior-Trade/superior-skills

    A skill your agent uses when a user wants to fund or bridge from an external wallet through a third-party UI such as Relay, especially when asking for MetaMask Mobile QR codes, bridge links…

    215 GitHub stars~1.7k tokensUpdated 1 mo ago
    Auto-check passed
  • Aerodrome

    Superior-Trade/superior-skills

    A skill your agent uses when creating, validating, backtesting, deploying, sizing, or troubleshooting Aerodrome/Base spot trading strategies through the Superior Trade API, especially Freqtrade…

    215 GitHub stars~2.3k tokensUpdated 1 mo ago
    Auto-check passed
  • Polymarket

    Superior-Trade/superior-skills

    A skill your agent uses when the user wants to trade, research, or backtest Polymarket prediction markets through Superior Trade — finding markets by slug or event URL, placing a single immediate…

    215 GitHub stars~4.2k tokensUpdated 1 mo ago
    Auto-check passed
  • Backtesting

    Superior-Trade/superior-skills

    A skill your agent uses when running, interpreting, or designing backtests on Superior Trade — anything about backtest windows, trade-count thresholds, exit-reason mix, parameter sweeps…

    215 GitHub stars~2.9k tokensUpdated 1 mo ago
    Auto-check passed

Questions about Regime Overlay

What does Regime Overlay do?

A skill your agent uses when adding a regime filter to any directional strategy — regime gate, trend filter, directional confirmation, ADX gate, EMA-separation filter, trade-or-skip overlay. Regime Overlay is an agent skill from Superior-Trade/superior-skills. Use when adding a regime filter to any directional strategy — regime gate, trend filter, directional confirmation, ADX gate, EMA-separation filter, trade-or-skip overlay.

When should I use Regime Overlay?

Regime Overlay fits situations like: adding a regime filter to any directional strategy — regime gate; directional confirmation; EMA-separation filter; trade-or-skip overlay.

How do I install Regime Overlay in Claude Code?

Run `npx skills add Superior-Trade/superior-skills --skill regime-overlay -a claude-code`. Or copy the skill folder (skills/regime-overlay in Superior-Trade/superior-skills) into .claude/skills/regime-overlay in your project. Claude Code loads it when a task matches its description.

How do I install Regime Overlay in Codex?

Run `npx skills add Superior-Trade/superior-skills --skill regime-overlay -a codex`. Or copy the skill folder (skills/regime-overlay in Superior-Trade/superior-skills) into .agents/skills/regime-overlay in your project. Codex loads it when a task matches its description.

Can I use Regime Overlay in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add Superior-Trade/superior-skills --skill regime-overlay -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/regime-overlay, .gemini/skills/regime-overlay, .github/skills/regime-overlay and .opencode/skills/regime-overlay in your project.

What does Regime Overlay need to run?

SKILL.md names no scripts, command-line tools or credentials: Regime Overlay is instructions for the agent only. Our summary lists: Python 3.

Does Regime Overlay access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Regime Overlay safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Regime Overlay use?

Regime Overlay is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Regime Overlay use?

About 1.3k tokens (SKILL.md is roughly 5.3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Regime Overlay?

Skills that share tags, products or a category with Regime Overlay: Tushare Data (zillionare/zillionare, 322 stars), Tradingview MCP (atilaahmettaner/tradingview-mcp, 5k stars), Digital Oracle (komako-workshop/digital-oracle, 878 stars) and Polyclaw (chainstacklabs/polyclaw, 359 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Regime Overlay?

Superior-Trade (a GitHub organization) maintains it in Superior-Trade/superior-skills, which has 215 GitHub stars. The repository holds 31 skills in this directory. The repository was last updated on September 10, 2026.

Source: Superior-Trade/superior-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.