Strategies Page

The Strategies page shows strategy performance rankings, real-time ML signals, and model health monitoring.

Overview

This page helps you understand:

  1. Which strategies are performing well? — Composite score rankings
  2. What is the ML model recommending? — Live signal feed
  3. Is the ML model healthy? — Accuracy, drift, and version history

Strategy Rankings

Strategies are ranked by a composite score (0-100), a weighted average of five metrics:

  • Sharpe Ratio (30% weight) — Risk-adjusted return
  • Sortino Ratio (20% weight) — Downside risk-adjusted return
  • Max Drawdown (20% weight) — Largest peak-to-trough decline (inverted: lower is better)
  • Profit Factor (15% weight) — Gross profit / gross loss
  • Consistency (15% weight) — How stable returns are over time

Higher composite scores are better. A score of 70+ indicates a strong strategy.

Threshold Criteria

Strategies are flagged as “Meets Thresholds” (green) or “Below Thresholds” (red) based on:

  • Sharpe Ratio ≥ 1.0
  • Max Drawdown ≤ 20%
  • Profit Factor ≥ 1.5
  • Total Trades ≥ 100

Strategies that meet all thresholds are considered production-ready.

Strategy Card Layout

Each strategy displays:

Left: Composite Score

  • Large number (0-100)
  • Color-coded: green (≥70), amber (50-69), red (<50)
  • Trophy icon for top-ranked strategy

Center: Details

  • Strategy name (e.g., MLSignalStrategy, MeanReversionStrategy)
  • Description — Brief explanation of the strategy’s approach
  • “How it works” button — Detailed popup with parameters, best use cases, risks, and academic references
  • Metrics grid (6 tiles):
    • Sharpe Ratio (target: ≥1.0)
    • Sortino Ratio (higher is better)
    • Max Drawdown (target: ≤20%)
    • Profit Factor (target: ≥1.5)
    • Win Rate (percentage of winning trades)
    • Total Trades (target: ≥100 for statistical significance)

Right: Equity Curve

  • Mini chart showing backtest performance over time
  • Green line/fill for strategies meeting thresholds
  • Amber line/fill for strategies below thresholds

“How it Works” Popover

Click the “How it works” button to see:

  1. Tagline — One-sentence summary
  2. How It Works — Detailed explanation of entry/exit logic
  3. Parameters — Table of configurable settings (e.g., lookback periods, thresholds)
  4. Best For — Market conditions where this strategy excels
  5. Key Risks — What can go wrong (e.g., whipsaws, false signals)
  6. Academic References — Papers/studies supporting the strategy (clickable links)

Example: MeanReversionStrategy

Tagline: "Buy oversold stocks, sell overbought stocks"

How It Works:
Uses Bollinger Bands (20-day SMA ± 2 standard deviations) to identify
extreme price deviations. Buys when price touches lower band, sells when
price reaches upper band or middle band.

Parameters:
- Lookback: 20 days
- Std Dev: 2.0
- Min Hold Days: 2 (PDT compliance)

Best For:
Choppy, range-bound markets. Works well with high-volume, liquid stocks
that revert to their mean.

Key Risks:
Poor performance in strong trends (up or down). Can buy falling knives in
sustained downtrends. Requires tight stop-losses.

References:
- Bollinger, J. (2001). Bollinger on Bollinger Bands. McGraw-Hill.

ML Signal Intelligence

This section shows real-time ML model activity:

Signal Feed (left, 2/3 width)

A scrolling list of recent signals generated by the MLSignalStrategy:

Field Description
Timestamp When the signal was generated
Symbol Stock ticker
Action BUY or SELL
Confidence Model’s confidence (0-100%)
Price Current market price
Score Raw model output (probability)
Top Features Most influential features for this signal (e.g., “RSI: 28.3”, “Momentum: +2.4%”)

Color coding:

  • BUY signals: Green background, upward arrow (↗)
  • SELL signals: Red background, downward arrow (↘)
  • High confidence (>70%): Bright text, bold font
  • Low confidence (<50%): Dimmed text, small font

What to look for:

  • High-confidence signals (>70%) are more reliable
  • Check top features to understand why the model predicted this
  • Compare multiple signals: is the model consistently bullish/bearish?

Feature Importance (top right)

A horizontal bar chart showing the top 10 most influential features globally:

  • RSI (Relative Strength Index) — Overbought/oversold indicator
  • Momentum — Recent price trend
  • Volume Ratio — Trading volume vs. average
  • Moving Average Crossover — Short vs. long-term MA
  • Volatility — Price variance (ATR)
  • Insider Buying — Corporate insiders purchasing shares
  • Short Interest Ratio — Shares sold short / avg daily volume
  • P/E Ratio — Price-to-earnings (valuation)
  • ROE — Return on equity (profitability)
  • Debt-to-Equity — Leverage ratio

How to interpret:

  • Longer bars = more important features
  • This is a global view (averaged across all predictions)
  • Individual signals may weight features differently (see Signal Feed)

Model Performance (bottom right)

Key model metrics:

  • Accuracy — Percentage of correct predictions (target: >55%)
  • Precision — Of all predicted BUYs, how many were correct?
  • Recall — Of all actual good BUYs, how many did we catch?
  • F1 Score — Harmonic mean of precision and recall

Good model performance:

  • Accuracy >55% (better than random guessing, accounting for fees)
  • Precision >60% (more than half of BUY signals are winners)
  • Recall >50% (catching at least half of good opportunities)

Model Health & Monitoring

This section tracks model degradation and versioning:

Accuracy Chart (left)

A time-series line chart showing rolling 30-day accuracy:

  • X-axis: Date
  • Y-axis: Accuracy percentage
  • Red dashed line: 50% threshold (random guessing)
  • Green zone: Above 55% (good performance)
  • Amber zone: 50-55% (marginal)
  • Red zone: Below 50% (worse than random)

What to watch:

  • Declining accuracy: Model may be overfitting or market regime has changed
  • Flat accuracy: Model is stable
  • Improving accuracy: Model is adapting well (possibly after retraining)

Drift Heatmap (right)

A heatmap showing PSI (Population Stability Index) for each feature over time:

  • X-axis: Date
  • Y-axis: Feature name
  • Color: Green (no drift, PSI <0.1), Amber (moderate drift, 0.1-0.2), Red (high drift, >0.2)

What is drift? Drift occurs when the distribution of a feature changes over time. For example, if RSI values were typically 30-70 during training but now range 10-50, the model’s learned patterns may not apply.

When to retrain:

  • Multiple features show amber/red (PSI >0.1)
  • Accuracy drops below 55%
  • Market regime changes (e.g., bull to bear market)

The system automatically retrains weekly (Sunday 4:00 AM) but can be manually triggered.

Model Version History

A table of all model versions with:

Column Description
Version Unique identifier (e.g., v1.0.3, v1.0.4)
Status Active, Promoted, Retired, Rolled Back
Trained Timestamp when model was trained
Accuracy Validation accuracy from walk-forward testing
Features Number of features used
Actions Promote, Rollback, Delete buttons

Version lifecycle:

  1. New model trained — Appears as “Candidate” status
  2. Validation passes — Can be promoted to “Active”
  3. Active model — Currently generating signals
  4. Poor performance — Can be rolled back to previous version
  5. Retired — Old versions kept for auditing

Best practices:

  • Keep 3-5 recent versions for rollback capability
  • Always validate new models on out-of-sample data before promoting
  • Monitor accuracy for 1-2 weeks after promotion before deleting old versions

When to Use This Page

Check the Strategies page:

  • Weekly: Review strategy rankings after backtest updates
  • After model retraining: Validate new model performance and feature importance
  • When considering trades: Check ML signal feed for high-confidence opportunities
  • If portfolio underperforms: Identify weak strategies and consider disabling them

Key Metrics to Watch

Composite Score

  • Top strategy should score 70+
  • Bottom strategies (<50) should be disabled or retrained

ML Signal Confidence

  • High confidence (>70%) signals are actionable
  • Low confidence (<50%) signals should be ignored or used only in combination with other strategies

Model Accuracy

  • Declining accuracy (<55%) is a red flag — retrain immediately
  • Stable accuracy (55-65%) is healthy
  • Improving accuracy (>65%) is excellent but watch for overfitting

Feature Drift (PSI)

  • No drift (green): Model is stable
  • Moderate drift (amber): Monitor closely, consider retraining
  • High drift (red): Retrain model urgently
  • Portfolio: See positions opened by each strategy
  • Risk: Check if strategy signals violate risk limits
  • Trades: Review trade history by strategy

Troubleshooting

Q: Strategy shows “—” for metrics A: Backtest may not have run. Check backend logs. Run seed script if in demo mode.

Q: No signals in ML feed A: Model may not have generated signals yet (only generates at bar close). Wait for market close or check logs for errors.

Q: Feature importance is empty A: Model hasn’t been trained yet. Run POST /api/system/scheduler/trigger/weekly_retrain to manually trigger training.

Q: Accuracy dropped below 50% A: Market regime may have changed. Retrain model immediately. Consider rolling back to previous version.

Best Practices

  1. Favor high composite scores — Top 3 strategies are usually your best performers
  2. Trust high-confidence signals — >70% confidence has proven reliability
  3. Monitor drift weekly — Catching degradation early prevents losses
  4. Retrain proactively — Don’t wait for accuracy to crash; retrain quarterly even if stable
  5. Document changes — Note market conditions when promoting new model versions

This site uses Just the Docs, a documentation theme for Jekyll.