OPEN-SOURCE SCRIPT

Abyss Protocol One

119
Abyss Protocol One — Momentum Exhaustion Trading System

Overview

Abyss Protocol One is a momentum exhaustion indicator designed to identify high-probability reversal points by detecting when price momentum has reached extreme levels. It combines Chande Momentum Oscillator (CMO) threshold signals with dynamic volatility-adjusted bands and multiple protective filters to generate buy and sell signals.

Core Concept

The indicator operates on the principle that extreme momentum readings (CMO reaching ±80) often precede mean reversion. Rather than chasing trends, Abyss Protocol waits for momentum exhaustion before signaling entries and exits.

Key Components

1. Dynamic Bands (Money Line ± ATR)

Center line uses linear regression (Money Line) for smooth trend representation
Bands expand and contract based on Bollinger Band Width Percentile (BBWP)
Low volatility (BBWP < 30): Tighter bands using lower multiplier
High volatility (BBWP > 70): Wider bands using higher multiplier
Bands visually adapt to current market conditions

2. CMO Exhaustion Signals

BUY Signal: CMO drops below -80 (oversold/momentum exhaustion to downside)
SELL Signal: CMO rises above +80 (overbought/momentum exhaustion to upside)
Thresholds are configurable for different assets and timeframes

3. ADX Filter

Signals only fire when ADX exceeds minimum threshold (default: 22)
Ensures there's enough directional movement to trade
Prevents signals during choppy, directionless markets

4. Band Contraction Filter

Calculates band width percentile rank over configurable lookback
When bands are contracted (below 18th percentile), ALL signals are blocked
Prevents trading during low-volatility squeeze periods where breakout direction is uncertain

5. Consecutive Buy Limit

Maximum of 3 consecutive buys allowed before a sell is required
Prevents overexposure during extended downtrends
Counter resets when a sell signal fires

6. Underwater Protection

Tracks rolling average of recent entry prices (last 10 entries within 7 days)
Blocks sell signals if current price is below average entry price
Prevents locking in losses during drawdowns

7. Signal Cooldown

Minimum 5-bar cooldown between signals
Prevents rapid-fire signals during volatile swings

8. Extreme Move Detection

Detects when price penetrates beyond bands by more than 0.6 × ATR
Extreme signals can bypass normal cooldown period
Fire intra-bar for faster response to capitulation/blow-off moves
Still respects max consecutive buys and underwater protection


Visual Features

Trend State Detection

The indicator classifies market conditions into six states based on EMA stack, price position, and directional indicators:

STRONG UP: Full bullish alignment (EMA stack + price above trend + bullish DI + ADX > threshold)
UP: Moderate bullish conditions
NEUTRAL: No clear directional bias
DOWN: Moderate bearish conditions
STRONG DOWN: Full bearish alignment
CONTRACTED: Bands squeezed, volatility low

ADX Trend Bar

Colored dots at chart bottom provide instant trend state visibility:

Lime = Strong Uptrend
Blue = Uptrend
Orange = Neutral
Red = Downtrend
Maroon = Strong Downtrend
White = Contracted

Volume Spike Highlighting

Purple background highlights candles where volume exceeds 2x the 20-bar average, helping identify institutional activity or significant market events.

Signal Labels

Buy labels show consecutive buy count (e.g., "BUY 2/3"), price, and CMO value
Sell labels show consecutive sell count, price, and CMO value
Extreme signals display in distinct colors (cyan for buys, fuchsia for sells)
Signal candles turn bright blue for easy identification


Info Panel

Real-time dashboard displaying:

Current trend state
CMO value with threshold status
CMO thresholds (buy/sell levels)
ADX with directional indicator (▲/▼) and signal eligibility
BBWP percentage
Buy/Sell counters
Average entry price (with underwater shield indicator 🛡 when protected)
Price position relative to Money Line
Band width percentile rank
Extreme move status
Signals status (OPEN/BLOCKED)


Recommended Use

Timeframe: 5-15 minute charts (parameters tuned for this range)
Best suited for: Assets with regular oscillations between overbought/oversold extremes
Trading style: Mean reversion, momentum exhaustion, scaled entries

Parameters Summary

Money Line Length: 12 — Smoothing for center line
ATR Length: 10 — Volatility measurement
Band Multiplier (Low/High Vol): 1.5 / 2.5 — Dynamic band width
CMO Length: 9 — Momentum calculation period
CMO Buy/Sell Threshold: -80 / +80 — Signal trigger levels
ADX Min for Signals: 22 — Minimum trend strength
Signal Cooldown: 5 bars — Minimum bars between signals
Max Consecutive Buys: 3 — Position scaling limit
Band Contraction Threshold: 18th %ile — Low volatility filter
Band Contraction Lookback: 188 bars — Percentile calculation period
Extreme Penetration: 0.6 × ATR — Threshold for extreme signals

כתב ויתור

המידע והפרסומים אינם מיועדים להיות, ואינם מהווים, ייעוץ או המלצה פיננסית, השקעתית, מסחרית או מכל סוג אחר המסופקת או מאושרת על ידי TradingView. קרא עוד ב־תנאי השימוש.