Court Vision

An NBA analytics app that forecasts how each player will perform, refreshed every day, next to live games, box scores and season stats.

When
2025 to now
Built with
React, Vite, Flask, PostgreSQL, XGBoost, GitHub Actions
Live
courtvision.works
Code
CosmicVeil/Court-Vision

Overview

Court Vision trains an XGBoost model on six seasons of player data (2020 to 2026) and predicts each player's next-season numbers. The app surfaces those predictions as a breakout radar and leaderboards, and puts them next to the things fans already check: live scores, box scores, season averages and career history.

Court Vision breakout radar listing players the model expects to improve most
The breakout radar: players the model expects to improve most.

How it works

  1. A scraper collects multi-season player data from Basketball Reference and NBA.com.
  2. The XGBoost model is trained on past seasons and checked with a walk-forward error report.
  3. Predictions are computed ahead of time and cached, so the API only reads them.
  4. A GitHub Action runs daily to refresh season stats and regenerate predictions, and finished games are archived to PostgreSQL.
  5. The Flask API serves stats and live games to everyone, and a preview of the predictions. The full predictions, recommendations and saved players need an account.
Court Vision leaderboard of predicted player statistics
Leaderboard of predicted statistics.