Karthus WPA Analyzer PROTOTYPE
A Win Probability Added (WPA) analysis tool for the League of Legends champion Karthus. Collects ranked solo/duo games from the Riot API, stores per-minute timeline data locally, and trains a PyTorch neural network to estimate win probability at each minute of the game. WPA is then computed for Karthus-specific events — R kills, deaths, dragon and baron participation, and item purchases — to quantify how much each moment shifted the outcome.
Currently a command-line prototype built as a research project for a Mathematics and Computer Science major at Haverford College. The backend and model are complete; a public-facing web interface is planned for a future release so anyone can look up their Karthus stats without running it locally.
What it does
Data Collection
BFS crawl seeded from the master/GM/challenger ladder. Stores full per-minute timeline frames for every Karthus game across all five roles.
Win Probability Model
PyTorch feedforward network trained on ~385 features per frame — gold, CS, champion stats, objectives, and map positions for all 10 players.
WPA by Event
Computes the win probability swing for every R kill, death, dragon, and baron — showing which moments actually moved the needle.
Item Tier List
Aggregates WPA across thousands of games to rank first and second item purchases by how much they improve win probability per game.
Rune Win Rates
Breaks down win rate by keystone rune per role across all stored games — no model required. Shows which keystones actually win more.
Data Freshness
Built-in refresh system re-scans players last collected more than N days ago, fetching new games and updated ranks without any data loss.
Roadmap
- ✓ Async data collection pipeline (BFS crawl, timeline storage)
- ✓ Feature extraction (384-dim per-frame vectors)
- ✓ Win probability model training (PyTorch feedforward NN)
- ✓ WPA calculator
- ✓ Per-player WPA breakdown CLI
- ✓ Item WPA tier list
- ✓ Keystone rune win rate tier list
- ✓ Data refresh system (re-scan stale players, backfill missing ranks)
- ○ Challenger benchmark comparison
- ○ LSTM sequence model (v2)
- ○ Public web interface (anyone can look up their stats)
Tech Stack
Built with Python 3, aiohttp for async Riot API collection, SQLite for local storage, and PyTorch for the win probability model. CLI built with Rich. Inspired by Coachless.gg.