PluginBench
Skill
Review
Audit score 70

earnings-trade-analyzer

tradermonty/claude-trading-skills

Score post-earnings stocks on a 5-factor system to identify momentum trade candidates.

What is earnings-trade-analyzer?

Analyzes recent earnings announcements using Gap Size, Pre-Earnings Trend, Volume Trend, and moving-average positioning to assign composite scores (0–100) and letter grades (A/B/C/D). Use this when screening for post-earnings momentum trades, PEAD candidates, or evaluating earnings reactions.

  • Fetches recent earnings announcements via FMP API with configurable lookback window
  • Calculates 5-factor composite score: Gap Size, Pre-Earnings Trend, Volume Trend, MA200 Position, MA50 Position
  • Assigns letter grades A/B/C/D based on composite score thresholds (A: 85+, B: 70–84, C: 55–69, D: <55)
  • Generates JSON and Markdown reports with per-stock scoring breakdown and actionable guidance
  • Supports market-cap filtering, top-N ranking, and deterministic anchor dates for reproducible runs
  • Includes fallback enrichment via stable FMP endpoints when budget or rate limits are exhausted

How to install earnings-trade-analyzer

npx skills add https://github.com/tradermonty/claude-trading-skills --skill earnings-trade-analyzer
Prerequisites
  • FMP (Financial Modeling Prep) API key set as `FMP_API_KEY` environment variable or passed via `--api-key` flag
  • Free tier supports default screening (2-day lookback, top 20 results); paid tier recommended for larger windows or full universe screening
Claude Code
Cursor
Windsurf
Cline

How to use earnings-trade-analyzer

  1. 1.Set your FMP API key as an environment variable: `export FMP_API_KEY=your_key`
  2. 2.Run the analyzer with default settings: `python3 skills/earnings-trade-analyzer/scripts/analyze_earnings_trades.py --output-dir reports/`
  3. 3.Review the generated JSON and Markdown reports in the output directory
  4. 4.Read `references/scoring_methodology.md` to understand the 5-factor scoring system and grade thresholds
  5. 5.For each candidate, examine the composite score, letter grade, gap size, trend, volume ratio, and moving-average positions
  6. 6.Act on Grade A stocks (85+) as strong entry candidates; Grade B stocks (70–84) as pullback opportunities; avoid Grade C/D

Use cases

Good for
  • Screen for the strongest post-earnings gap reactions over the last 2–5 days to identify momentum entry candidates
  • Rank earnings announcements by institutional accumulation signals (volume, trend, moving-average position) to prioritize research
  • Evaluate post-earnings accumulation day (PEAD) setups with a standardized scoring methodology
  • Generate daily or weekly earnings reaction reports for a trading desk or portfolio review
  • Identify Grade A setups (85+ score) for immediate entry consideration or Grade B setups (70–84) for pullback entries
Who it's for
  • Momentum traders and swing traders analyzing post-earnings price action
  • Quantitative analysts building earnings-reaction screening workflows
  • Trading desks conducting daily earnings reviews and candidate prioritization
  • Retail traders seeking systematic scoring criteria for earnings trades

earnings-trade-analyzer FAQ

What does the 5-factor scoring system measure?

Gap Size (post-earnings price move), Pre-Earnings Trend (20-day momentum), Volume Trend (20-day vs 60-day average), MA200 Position (price relative to 200-day moving average), and MA50 Position (price relative to 50-day moving average). Each factor is weighted and combined into a 0–100 composite score.

How are letter grades assigned?

Grades are based on composite score: A (85+) = strong setup, B (70–84) = good setup, C (55–69) = mixed signals, D (<55) = weak setup.

What should I do if the analyzer reports zero candidates or exhausts its API budget?

First, retry with narrower parameters (e.g., `--lookback-days 2 --min-market-cap 5000000000 --top 20`). If that fails, use the fallback stable FMP endpoint to fetch ungraded earnings reactions and enrich them with quote data; label these as preliminary/ungraded since the 5-factor scorer did not run.

Can I run the analyzer on a specific date?

Yes, use `--as-of YYYY-MM-DD` to anchor the analysis to a specific ET calendar date. This is useful for reproducible runs and testing.

What does 'timing_unknown_count' mean in the output?

FMP does not always confirm whether an earnings announcement occurred before market open (bmo) or after market close (amc). Rows with unknown timing default to the amc window for gap calculation. The report surfaces this count so the assumption remains visible.

Full instructions (SKILL.md)

Source of truth, from tradermonty/claude-trading-skills.


name: earnings-trade-analyzer description: Analyze recent post-earnings stocks using a 5-factor scoring system (Gap Size, Pre-Earnings Trend, Volume Trend, MA200 Position, MA50 Position). Scores each stock 0-100 and assigns A/B/C/D grades. Use when user asks about earnings trade analysis, post-earnings momentum screening, earnings gap scoring, or finding best recent earnings reactions.

Earnings Trade Analyzer - Post-Earnings 5-Factor Scoring

Analyze recent post-earnings stocks using a 5-factor weighted scoring system to identify the strongest earnings reactions for potential momentum trades.

When to Use

  • User asks for post-earnings trade analysis or earnings gap screening
  • User wants to find the best recent earnings reactions
  • User requests earnings momentum scoring or grading
  • User asks about post-earnings accumulation day (PEAD) candidates

Prerequisites

  • FMP API key (set FMP_API_KEY environment variable or pass --api-key)
  • Free tier (250 calls/day) is sufficient for default screening (lookback 2 days, top 20)
  • Paid tier recommended for larger lookback windows or full screening

Workflow

Step 1: Run the Earnings Trade Analyzer

Execute the analyzer script:

# Default: last 2 days of earnings, top 20 results
python3 skills/earnings-trade-analyzer/scripts/analyze_earnings_trades.py --output-dir reports/

# Custom lookback and market cap filter
python3 skills/earnings-trade-analyzer/scripts/analyze_earnings_trades.py \
  --lookback-days 5 \
  --min-market-cap 1000000000 \
  --top 30 \
  --output-dir reports/

# Deterministic anchor date (America/New_York); the window is anchored on the
# ET calendar date, not the runner's local clock. For reproducible runs/tests.
python3 skills/earnings-trade-analyzer/scripts/analyze_earnings_trades.py \
  --as-of 2026-09-15 \
  --output-dir reports/

# With entry quality filter
python3 skills/earnings-trade-analyzer/scripts/analyze_earnings_trades.py \
  --apply-entry-filter \
  --output-dir reports/

Degraded endpoint / budget fallback for scheduled reviews

If the analyzer reports a 404, an implausible empty earnings calendar, or exhausts its API-call budget before producing scored candidates during a scheduled after-close/pre-market run, do not report "no earnings reactions" immediately. A clean empty response over a date window containing at least one XNYS session exits 1 with ZERO_RESULT_REASON=earnings_calendar_empty_with_market_sessions. If the shared XNYS calendar cannot classify the window, it exits 1 with ZERO_RESULT_REASON=market_calendar_unavailable. Budget or daily rate-limit exhaustion during profile fetching exits 1 with ZERO_RESULT_REASON=profiles_budget_exhausted. Treat each as a failed run to retry or fall back on, not a quiet day. Only a clean empty response over a zero-session window exits 0 as ZERO_RESULT_REASON=no_earnings_rows.

  1. First retry once with a narrower liquid-universe configuration so the full 5-factor scorer has a chance to complete, for example:
python3 skills/earnings-trade-analyzer/scripts/analyze_earnings_trades.py \
  --lookback-days 2 \
  --min-market-cap 5000000000 \
  --top 20 \
  --max-api-calls 600 \
  --output-dir reports/<routine-date>
  1. If the scored run still returns no candidates or cannot complete, verify the same range through the stable endpoint used by the compatibility shim and clearly label the result as an ungraded fallback:
curl "https://financialmodelingprep.com/stable/earnings-calendar?from=YYYY-MM-DD&to=YYYY-MM-DD&apikey=$FMP_API_KEY"

Then optionally enrich returned US tickers through the analyzer's stable-first FMP client or per-symbol /stable/quote?symbol=<ticker> calls to rank by same-day changesPercentage, market cap, and liquidity. Use legacy /api/v3 quote calls only as a legacy-key fallback after stable has failed. Present these as preliminary / ungraded reactions because the 5-factor scorer did not run; do not assign A/B/C/D grades from the fallback alone.

No-candidate output pitfall: The analyzer may print Candidates after filtering: 0 / No candidates found matching criteria. and exit successfully without writing an earnings_trade_analyzer_*.json file. In that case, do not try to run PEAD Mode B from a nonexistent candidate file. Say explicitly that no scored analyzer JSON was produced, run the endpoint/quote enrichment fallback above if the routine needs an earnings section, and label any names as manual-review only. This success-exit path does not cover budget exhaustion during profile fetching: that case exits 1 (ZERO_RESULT_REASON=profiles_budget_exhausted) instead.

Empty windows and today-only runs

The earnings calendar window is inclusive and uses the America/New_York calendar date from --as-of (or the current ET date). A clean provider [] is a benign quiet-window result only when the shared XNYS calendar successfully counts zero exchange sessions in that exact window, such as a weekend or holiday. If the window contains an XNYS session, the same clean [] exits 1 with ZERO_RESULT_REASON=earnings_calendar_empty_with_market_sessions so a provider drop is not reported as a quiet day. If the XNYS calendar cannot be queried, the run also exits 1 with ZERO_RESULT_REASON=market_calendar_unavailable.

--lookback-days 0 is valid and queries exactly the single ET as-of date. Use it after the relevant announcements have been published (normally after the session close); an empty response on an XNYS session remains intentionally fail-closed. A non-empty response whose rows do not carry a symbol retains the separate ZERO_RESULT_REASON=no_earnings_rows behavior; that case is not the literal-empty-list session check above.

Step 2: Review Results

  1. Read the generated JSON and Markdown reports
  2. Load references/scoring_methodology.md for scoring interpretation context
  3. Focus on Grade A and B stocks for actionable setups

Step 3: Present Analysis

For each top candidate, present:

  • Composite score and letter grade (A/B/C/D)
  • Earnings gap size and direction
  • Pre-earnings 20-day trend
  • Volume ratio (20-day vs 60-day average)
  • Position relative to 200-day and 50-day moving averages
  • Weakest and strongest scoring components

Step 4: Provide Actionable Guidance

Based on grades:

  • Grade A (85+): Strong earnings reaction with institutional accumulation - consider entry
  • Grade B (70-84): Good earnings reaction worth monitoring - wait for pullback or confirmation
  • Grade C (55-69): Mixed signals - use caution, additional analysis needed
  • Grade D (<55): Weak setup - avoid or wait for better conditions

Output

  • earnings_trade_analyzer_YYYY-MM-DD_HHMMSS.json - Structured results with schema_version "1.0"
  • earnings_trade_analyzer_YYYY-MM-DD_HHMMSS.md - Human-readable report with tables

Unknown earnings timing

FMP does not confirm a bmo/amc session for every earnings row; unconfirmed rows report earnings_timing: "unknown" and the gap calculation assumes the AMC window as a fallback. Both reports surface timing_unknown_count out of timing_candidates_total so this assumption stays visible rather than blending unnoticed into the scores.

Resources

  • references/scoring_methodology.md - 5-factor scoring system, grade thresholds, and entry quality filter rules