Structure Decision Engine [AlgoPoint]Structure Decision Engine uses a dual-layer market structure framework
to detect Break of Structure (BOS), Change of Character (CHoCH),
and liquidity sweeps — then evaluates every signal through a
multi-factor quality engine that assigns a Trade Permission (ON/OFF).
Unlike basic structure indicators that only draw lines, this engine
thinks like a trader: is the structure aligned? Is the HTF bias
confirming? Are we in premium or discount? Was there a recent
liquidity sweep? Each factor contributes to a 0-100 Quality Score,
and only setups above the threshold get trade permission.
🔹 THREE VISUAL MODES
Decision — Clean view showing only active trade signals, Decision
Card dashboard, and structure zones. Minimal noise.
Analysis — Full structure view with BOS/CHoCH markers, liquidity
sweep labels (BSL/SSL), external levels, and Premium/Discount cloud.
Debug — Every internal and external swing labeled. All levels visible.
Use this to tune the lookback and filter parameters to your asset.
🔹 DUAL-LAYER STRUCTURE
Internal Structure — Short-term swing highs/lows with configurable
lookback. Detects BOS and CHoCH for entry timing.
External Structure — Longer-term swing points defining the macro
trend. Provides bias context and Premium/Discount range.
🔹 QUALITY ENGINE (0-100)
Each signal is scored on 7 dimensions:
• Body Ratio — how decisive is the breakout candle
• Displacement — how far did price close beyond the structure level
• Volume Confirmation — was volume elevated at the break
• Sweep Recency — was there a liquidity sweep before the break
• Structure Alignment — does the signal agree with external trend
• HTF Bias — does the higher timeframe EMA confirm direction
• Zone Position — is price in Premium (sell) or Discount (buy) zone
Grade scale: 85+ = A+, 75+ = A, 65+ = B, 50+ = C, below = D.
🔹 TRADE PERMISSION
Signals receive ON (take the trade) or OFF (stand aside) based on
quality threshold, structure alignment, HTF bias, and chop filter.
Each OFF signal shows the specific reason: "Quality below threshold,"
"Against external structure," "Against HTF bias," or "Choppy."
🔹 ACTIVE PLAN TRACKER
After a valid signal, the engine projects:
• Retest Zone — the area where price should retest the broken level
• Invalidation Level — where the setup is void
• Target — nearest opposing structure level
• Status — Waiting Retest → Retest Hit → Target Hit / Invalidated
All projected as visual boxes and lines extending forward.
🔹 LIQUIDITY SWEEPS
Detects Buy-Side Liquidity (BSL) sweeps and Sell-Side Liquidity
(SSL) sweeps on internal structure levels. Sweeps within the
validity window boost the Quality Score by 20 points.
🔹 MARKET MODE CLASSIFICATION
Combines internal and external structure states to determine the
current market mode: Bullish Trend, Bearish Trend, Bullish Pullback,
Bearish Pullback, Neutral, or No-Trade (choppy/compressed).
🔹 DECISION CARD DASHBOARD
Real-time panel showing: External Bias, Market Mode, Last Setup,
Quality Score/Grade, Trade Permission, Zone (Premium/Discount),
Recent Sweep, and Plan Status.
🔹 FEATURES
• 1100+ lines of professional Pine Script
• Dual-layer swing detection (Internal + External)
• BOS, CHoCH, BSL/SSL sweep detection
• 7-factor Quality Score with letter grade
• Trade Permission engine with reason codes
• Active Plan projection (Retest / Invalidation / Target)
• Premium/Discount cloud based on external range
• HTF bias filter (multi-timeframe EMA)
• Chop / no-trade zone detection
• Three visual modes for different workflows
• Dynamic alerts with full signal context
• 20+ customizable parameters
• No repainting
The Structure Decision Engine is an analysis framework — it does
not predict price or guarantee outcomes.
Pine Script® 인디케이터






















