Strategy Logic

Conditions and ranking rules for each screener.

ReTell Decision Engine — Alpha Score & Recommendation

Final intelligence layer that runs AFTER every screener/engine and produces one actionable recommendation per qualified stock.

  • Alpha ReTell Score = weighted average (0–100). Weights: Trend 25 · Chart 20 · Momentum 20 · Fundamental 20 · Regime 10 · Sector 5 (missing contributors drop out, remaining weights re-normalised).
  • Decision is NOT based on Alpha alone — a multi-signal matrix combines Alpha with Trend, Momentum, Price Location, Regime and Fundamental thresholds.
  • Star rating: ★★★★★ Strong Buy · ★★★★☆ Buy · ★★★☆☆ Hold · ★★☆☆☆ Reduce · ★☆☆☆☆ Exit.
  • One-sentence reason is rule-generated from the dominant signal (trend/volume/momentum/fundamentals/breakdown).
  • Pluggable contributor registry — News Sentiment, Options, OI, Sector Rotation, FII/DII, Macro can register weights without touching the engine.

Ranking: Sort: Alpha desc → ReTell (legacy) desc → # strategies desc → Momentum desc.

Trend Intelligence Engine — Price & Volume across timeframes

Understand the market's PRICE and VOLUME trend across 5 successive timeframes rather than a single lookback.

  • Comparisons: Today↔Yesterday · Yesterday↔Week · Week↔Month · Month↔Quarter · Quarter↔Year.
  • Each step returns direction (UP · DOWN · FLAT) and strength (Strong · Moderate · Weak) with the % change.
  • Price bands: ±0.5% = FLAT · ≥3% = Strong. Volume bands: ±10% = FLAT · ≥50% = Strong (volume is noisier).
  • Score = average of available steps × direction × strength multiplier. Missing bars drop out — never punished.

Ranking: Feeds ReTell Decision Engine (Trend 25% weight).

Smart Price Location Engine

Combine 8 location signals into ONE score instead of scoring indicators individually.

  • Components: Above POC (15) · Above VWAP (10) · Above EMA20 (10) · Above EMA50 (15) · Above EMA200 (20) · 52W-High proximity (15) · Breakout margin (10) · Range position (5).
  • 52W-High: full credit within 5%, linear decay to 0 at 25% below.
  • Breakout: linear credit for % above prev day high, full at ≥1%.
  • Missing signals removed from denominator — score is (awarded / presentWeight × 100).

Ranking: Consumed by ReTell Decision Engine as a decision guardrail.

Market Regime Engine — Breadth Proxy

Classify the overall market as Bearish · Neutral · Bullish · Strong Bull using screener breadth as a proxy.

  • Uses the Master Screener's qualifiedCount across all 4 strategies.
  • ≥60 qualified AND ≥3 strategies active → Strong Bull (score 90).
  • ≥25 qualified → Bullish (70). ≥8 → Neutral (50). Otherwise Bearish (25).
  • Pluggable — can be swapped for A/D line or index momentum without changing callers.

Ranking: 10% weight into Alpha ReTell Score.

Master Screener — Composite Ranking

Fuse every per-strategy signal into a single ReTell Score for institutional-grade ranking.

  • Universe: union of stocks qualified by EPB, VCP, ESB, or ORB (deduped by symbol).
  • Momentum Score = average of the per-strategy scores the stock passed (0–100).
  • Chart Score = Chart Intelligence engine (trend structure, base quality, volume, RS).
  • Fundamental Score = Fundamental Engine (tiered, coverage-normalised); N/A when insufficient data.
  • Contributor registry is pluggable — missing contributors are excluded from the normaliser, so partial data is never penalised.

Ranking: ReTell Score = weighted avg → Momentum 0.35 · Chart 0.35 · Fundamental 0.30 (weights re-normalised over available contributors). Sort: ReTell desc → Momentum desc → R:R desc.

Data Architecture — Price vs Fundamentals

Two independent engines so a fundamentals outage never breaks price/technical scoring.

  • Price Engine: Yahoo Finance (OHLCV / quotes) — sole source for price, EMAs, RS, volume, ORB.
  • Fundamental Engine: provider-agnostic with failover — Screener.in → Trendlyne → NSE → BSE.
  • First provider returning usable data wins; per-field 'Source' + 'Last Updated' is surfaced in Admin › Fundamentals Debug.
  • Yahoo is NEVER used for fundamentals (quoteSummary 401 / Invalid Crumb on Indian equities).
  • Provider total failure → Fundamental Score = N/A. No default. No score of 5. No fabricated values.
  • New providers can be plugged in without touching scoring logic.

Ranking: N/A — infrastructure layer feeding the scoring engines above.

Fundamental Engine — Tiered Scoring

Score quality of fundamentals fairly even when a provider omits fields.

  • Tier 1 (Critical, 10 pts each): ROE, ROCE, Revenue Growth, Profit Growth, Debt/Equity, Market Cap.
  • Tier 2 (Important, 5 pts each): Operating Margin, EPS Growth, PE, PB.
  • Tier 3 (Optional, 4 pts each): Promoter Holding, Promoter Pledge, Institutional Holding, PEG, Free Cash Flow.
  • Each field graded pass / partial / fail / missing against band thresholds; missing fields drop out of the denominator.
  • Score = round(rawAchieved / availableWeight × 100).
  • Confidence: ≥85% coverage → High · 60–84% → Medium · <60% → Low.

Ranking: UI shows Fundamental Score + Confidence only. Admin › Fundamentals Debug shows provider used, coverage %, per-field outcome, missing fields, and normalisation math.

EPB — EMA Pullback

Buy strong uptrends pulling back toward EMA20.

  • Price > EMA50 > EMA200 (long-term uptrend)
  • Price within 2% of EMA20 (the pullback)
  • RS percentile ≥ 70 vs scanned universe
  • Volume ratio ≥ 1.0× (no distribution)
  • 52W-high distance ≤ 25%

Ranking: Total Score = 60% Technical + 40% Fundamental.

VCP — Volatility Contraction

Minervini-style base breakout candidates.

  • Stage-2 trend: Price > EMA50 > EMA150 > EMA200, EMA200 rising
  • Two+ progressively tighter contractions
  • Within 15% of 52w high, ≥ 30% off 52w low
  • Volume dry-up inside base; pivot volume expansion

Ranking: Total Score (technical breakout quality + fundamentals).

ESB — Early Stage Breakout

Catch leaders early as they reclaim trend.

  • Price > EMA20 > EMA50 > EMA200
  • Within 10% of 52w high
  • Volume ratio ≥ 1.5×
  • RS percentile ≥ 80
  • D/E ≤ 1.0

Ranking: 12-month return desc (RS percentile is informational).

ORB — Opening Range Breakout

Intraday momentum off the day's open.

  • Price > Day Open AND ≥ Previous Day High
  • Price ≥ VWAP, ≥ EMA20, EMA20 > EMA50
  • Volume ratio ≥ 2.0×
  • Price in top 10% of day's range

Ranking: Vol Ratio desc → Day-High distance asc → Intraday return desc.