How costasgk/scorecast works
ScoreCast turns football and basketball history plus upcoming fixtures into match predictions, then serves those predictions and analysis through a Flask application. The principal football workflow is data refresh, calendar enrichment, Dixon–Coles fitting and prediction, with separate season simulation and walk-forward market benchmarking. Basketball has its own data and rating-model path, plus player statistics. The README documents several web features whose route-level implementation was not sampled; those capabilities are included without inferring internal call chains.
Main entry points: app.py Flask application · ScorelineModel.py Dixon-Coles model · refresh.py Refresh orchestrator · pipeline.py Legacy pipeline
Components 22
Football data
- League registry
Scripts/leagues.py - Football results
Scripts/FootballData.py - Fixture calendars
Scripts/fixtures.py - FBref scraper
Scripts/Scrapping.py - Match cleaning
Scripts/Cleaning.py
Football models
- Dixon-Coles model
Scripts/ScorelineModel.py - Season projection
Scripts/simulate_season.py
Basketball
- Basketball data
Scripts/Euroleague_scripts/EuroleagueData.py - Opponent ratings
Scripts/Euroleague_scripts/EuroleagueModel.py - Player statistics
Scripts/Euroleague_scripts/players.py - Basketball backtest
Scripts/Euroleague_scripts/backtest.py
Web product
- Flask application
Scripts/WebApp/app.py - Prediction and analysis pages
Scripts/WebApp/templates
Refresh and evaluation
- Refresh orchestrator
Scripts/refresh.py - Legacy pipeline
Scripts/pipeline.py - Market benchmark
Scripts/benchmark.py - Model calibration
Scripts/calibrate.py - Decay tuning
Scripts/tune_decay.py
Other components
- Visitor
- football-data.co.uk
- ESPN and FBref
- EuroLeague API
Connections 27
- Visitor → Flask application: views
README.md - Refresh orchestrator → Football results: fetches results
README.md - Refresh orchestrator → Fixture calendars: fetches calendars
README.md - Refresh orchestrator → Dixon-Coles model: refits and predicts
README.md - Refresh orchestrator → Season projection: projects seasons
README.md - Football results → football-data.co.uk: downloads CSVs
Scripts/FootballData.py - Football results → League registry: uses league list
Scripts/FootballData.py - Fixture calendars → ESPN and FBref: fetches calendars
README.md - Fixture calendars → League registry: uses league list
Scripts/fixtures.py - FBref scraper → Legacy pipeline: is orchestrated by
Scripts/pipeline.py - Legacy pipeline → Match cleaning: cleans matches
Scripts/pipeline.py - Legacy pipeline → Football results: fetches results
Scripts/pipeline.py - Legacy pipeline → Dixon-Coles model: runs predictions
Scripts/pipeline.py - Dixon-Coles model → Season projection: supplies model
Scripts/simulate_season.py - Market benchmark → Dixon-Coles model: evaluates predictions
Scripts/calibrate.py - Model calibration → Dixon-Coles model: calibrates
Scripts/calibrate.py - Decay tuning → Dixon-Coles model: tunes decay
Scripts/tune_decay.py - Basketball data → EuroLeague API: fetches live games
Scripts/Euroleague_scripts/EuroleagueData.py - Opponent ratings → Basketball data: fits game data
Scripts/Euroleague_scripts/run.py - Player statistics → Basketball data: loads box scores
Scripts/Euroleague_scripts/players.py - Basketball backtest → Opponent ratings: validates ratings
Scripts/Euroleague_scripts/backtest.py - Flask application → Prediction and analysis pages: renders pages
README.md - Flask application → Dixon-Coles model: serves predictions
README.md - Flask application → Season projection: serves projections
README.md - Flask application → Market benchmark: shows benchmark
README.md - Flask application → Player statistics: shows leaders
README.md - Flask application → Opponent ratings: serves basketball