/sports-analytics-core:prediction-trackerfrom SportsDataHQ: analytics core
Logs and scores sports prediction models by recording forecasts before events and grading them after. Tracks Brier score, log loss, calibration, and closing-line comparison with sample sizes and intervals.
Ships in SportsDataHQ: analytics core. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
The honesty loop for a model: record what it predicted before the event, grade it after, and report how good it is with the uncertainty attached. This tracks predictions, not wagers. It has no money columns of any kind.
| Need | Tool |
|---|---|
Final results (hockey get_games, football get_games, basketball list_games, soccer list_games, tennis get_matches, golf get_leaderboard, UFC get_event) | the sport's results tool |
| Closing fair probability across books | get_game_probabilities (or get_odds and the margin removal in market-vs-model) |
| Open to close movement | get_line_movement |
Logging and metrics use a local CSV or SQLite file. There is no hosted prediction log; do not invent tools such as log_prediction or get_clv.
CSV for under 200 rows, SQLite beyond that.
date,event_id,sport,market,outcome,model_prob,model_version,open_fair_prob,close_fair_prob,result,brier,log_loss,notes
model_prob: probability for the stated outcome, 0 to 1, recorded before the eventmodel_version: so results are not mixed across retrainsopen_fair_prob, close_fair_prob: market fair probability for the same outcome (margin removed)result: 1 if the outcome happened, 0 if not, blank while openbrier: (model_prob - result)^2; log_loss: -ln(p) if result is 1, -ln(1-p) if 0Write the row with result blank before the event starts. Logging afterwards biases the record.
Pull outcomes with the sport's results tool, match by event id or teams and date, and fill result, brier, log_loss. Push or void events are excluded and counted separately.
After close, fill close_fair_prob from get_game_probabilities (or compute it). Compute the market's own Brier score and log loss for the same events.
skill = market_brier - model_brier # positive: model scored better than the closing market
moved_toward = abs(close - model_prob) < abs(open - model_prob)
Report the share of events where the market moved toward the model between open and close. Both are measures of model quality. Matching the closing market is a good result.
import numpy as np
n = len(resolved)
brier = resolved.brier.mean()
logloss = resolved.log_loss.mean()
accuracy = ((resolved.model_prob > 0.5) == resolved.result.astype(bool)).mean()
Add a calibration table: bin model_prob (for example 0.1 wide), show mean predicted, observed frequency and count per bin (see probability-calibration). Report a bootstrap or normal interval for Brier and log loss. Break results out per season and per model_version.
Compute rolling 50-event Brier and the closing market's rolling Brier. Flag drift when the model's rolling Brier is worse than its own full-history Brier by more than the interval, or worse than the market's for 3 consecutive windows. A flag means audit the data and features (backtesting, probability-calibration), not that something must be done to any wager.
For a Brier difference between model and market, report the paired difference with its interval. If the interval includes zero, say the data cannot tell them apart yet. As a guide, expect to need several hundred events to separate small differences, and report the actual interval rather than the guide. Do not call the model good from fewer than about 100 resolved events.
| Rationalization | Why it is wrong | Do this instead |
|---|---|---|
| "I'll log them later" | Memory favors the hits | Log before the event |
| "Accuracy is 58%, so it works" | Accuracy ignores probabilities and sample size | Report Brier, log loss, n and interval |
| "It backtested well" | Backtests overfit | Live record and closing-line comparison come first |
| "Mixing versions is fine" | It hides drift | Keep model_version and report per version |
| "Drop the bad week" | Selective reporting | Report all resolved events |
PREDICTION TRACKER: updated [date] (season convention: [..])
Predictions: N total | open X | resolved Y
Brier: 0.xxx (95% interval 0.xxx to 0.xxx) Market closing Brier: 0.xxx
Log loss: 0.xxx Accuracy: xx.x% (n = Y)
Model moved-toward-by-close share: xx% (n = Y)
By season: [table] By model_version: [table]
Calibration: [bin table]
Status: [IN LINE WITH MARKET / BEHIND MARKET / NOT ENOUGH DATA]
| Finding | Skill |
|---|---|
| Behind market for several windows | backtesting |
| Calibration bins off | probability-calibration |
| Need to retrain | model-building |
| Want a chart of rolling Brier or calibration | visualization |
| Compare with the market's probability | market-vs-model |
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
9 plugins ship this exact skill · first indexed Dec 3, 2026
Showing 6 of 9 plugins, one per repository first
Other plugins' skills for the same job
10 skills in this plugin
/backtestingUse when the user asks whether a sports model or system would have worked in the past, for any sport, in plain wording: 'does my model actually work', 'test it on the last three seasons', 'did it beat the closing line', 'is it still as accurate as it used to be', 'what is the confidence interval on my hit rate', 'how would this have done in 2023', 'run it against past odds', 'is this edge real or luck', 'how should I split seasons to test it'. Use this whenever historical performance, fold design, sample size or an interval is the question. Load this skill first, before calling any data tool; it says which tools to call. Walk-forward only; refuses k-fold and in-sample testing; reports sample size, an interval and a per-season breakdown. Not for logging live predictions as games finish (see prediction-tracker), tonight's gap to the market (see market-vs-model) or training (see model-building)./data-pipelineUse when the user wants anything sports-related to run on its own or keeps getting numbers that do not line up: 'run my model every morning', 'schedule a script to grab results daily', 'GitHub Action to refresh my ratings', 'automate the whole thing', 'email me when the model gets worse', 'where do I store predictions', 'I joined two tables and lost rows', 'duplicate rows in my data', 'does this date belong to last season'. Load this skill first, before calling any data tool; it says which tools to call. Covers cron jobs and GitHub Actions, storage, model versioning, retraining and drift alerts, plus the data checks other skills point to (ids, season convention per sport, one league, duplicates, sample-size floors). Not for one-off lookups (call your sport's tools directly), building the model (use model-building), historical testing (use backtesting) or grading logged predictions (use prediction-tracker).npx claudepluginhub sports-data-hq/sportsdatahq-skills --plugin sports-analytics-core