brackt/drizzle
Chris Parsons d7ba20d9ea
Add tennis Grand Slam simulator with surface Elo ratings, fixes #116 (#216)
Implements a Monte Carlo simulator for men's/women's tennis seasons scored
on the qualifying_points pattern. Simulates all 4 Grand Slam majors
(Australian Open, French Open, Wimbledon, US Open) using surface-specific
Elo ratings and ATP/WTA world rankings for seeding.

New table: participant_surface_elos — one row per (participant, season)
storing worldRanking, eloHard, eloClay, eloGrass.

Key design decisions:
- Seeding uses ATP/WTA world ranking (not Elo), matching real draw procedure
- Top 32 seeded with standard slot placement (1→0, 2→64, 3-4→quarters, etc.)
- QP per round with tie-splitting pre-applied: W=20, F=14, SF=9, QF=4, R16=1.5
- Completed majors read actual qualifyingPointsAwarded from eventResults
- 10,000 Monte Carlo simulations; column sums naturally 1.0 (no normalization)

Admin UI at /admin/sports-seasons/:id/surface-elo:
- 5-column grid (Player | Rank | Hard | Clay | Grass)
- Bulk import: "Name, ranking, hardElo, clayElo, grassElo" one per line
- Fuzzy name matching (bigram Dice coefficient) with "Did you mean?" suggestions
- Inline participant creation for unmatched names via useFetcher
- Saves Elos and auto-runs simulation on submit

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-23 23:59:35 -07:00
..
meta Add tennis Grand Slam simulator with surface Elo ratings, fixes #116 (#216) 2026-03-23 23:59:35 -07:00
0000_short_donald_blake.sql Initial commit from create-react-router 2025-10-10 23:04:50 -07:00
0001_serious_la_nuit.sql feat: add fantasy league schema and new league routes 2025-10-11 00:07:39 -07:00
0002_tired_iron_man.sql feat: add commissioner model and league management features 2025-10-11 00:29:04 -07:00
0003_public_shadowcat.sql feat: add user model, routes, and Clerk webhook integration 2025-10-11 00:53:39 -07:00
0004_spicy_zarda.sql feat: add user model, routes, and Clerk webhook integration 2025-10-11 00:53:39 -07:00
0005_abnormal_thunderbird.sql refactor: remove guest book feature and update league settings success flow 2025-10-11 01:03:31 -07:00
0006_needy_junta.sql feat: add current season tracking and active league listing by user 2025-10-11 21:10:01 -07:00
0007_pink_nebula.sql feat: add sports and participant models with admin user functionality 2025-10-12 21:16:00 -07:00
0008_salty_trauma.sql feat: add icon support for sports with file upload and active seasons display 2025-10-13 10:30:47 -07:00
0009_fuzzy_korvac.sql refactor: remove isRequired field from season sports and templates 2025-10-13 15:00:59 -07:00
0010_complex_the_stranger.sql feat: add invite code system for league seasons with member access control 2025-10-14 12:20:36 -07:00
0011_gifted_mystique.sql feat: add username field to users and display in league views 2025-10-14 21:20:58 -07:00
0012_yielding_phil_sheldon.sql feat: add team settings route and logo URL field to teams table 2025-10-14 22:04:37 -07:00
0013_pink_the_order.sql feat: add draft order management with UI for manual and random ordering 2025-10-15 08:58:35 -07:00
0014_lowly_gateway.sql feat: add bulk participant creation and expected value field 2025-10-15 21:21:33 -07:00
0015_exotic_loners.sql feat: add draft rounds configuration to league settings 2025-10-15 21:50:02 -07:00
0016_majestic_roulette.sql feat: add draft date/time selection to league creation and settings 2025-10-15 22:02:21 -07:00
0017_calm_zarda.sql feat: add draft pick, queue, and timer models with database schema updates 2025-10-16 00:32:48 -07:00
0018_numerous_stardust.sql feat: add public draft board and simplify draft speed settings 2025-10-20 15:03:11 -07:00
0019_acoustic_ben_grimm.sql feat: add autodraft status and team connection indicators to draft grid 2025-10-21 23:22:17 -07:00
0020_slim_spacker_dave.sql feat: Add comprehensive scoring system database schema 2025-10-28 23:40:11 -07:00
0021_fair_ser_duncan.sql feat: Implement bracket expansion plan to support various tournament structures 2025-11-03 09:36:16 -08:00
0022_shiny_mother_askani.sql feat: Implement bracket expansion plan to support various tournament structures 2025-11-03 09:36:16 -08:00
0023_cynical_jack_power.sql Refactor code structure for improved readability and maintainability 2025-11-03 13:16:37 -08:00
0024_faithful_mesmero.sql feat: implement Expected Value System with ICM probability calculator 2025-11-17 22:19:46 -08:00
0025_rename_participant_ev_season_to_sports_season.sql feat: implement Expected Value System with ICM probability calculator 2025-11-17 22:19:46 -08:00
0026_add_source_odds_to_participant_ev.sql feat: implement Expected Value System with ICM probability calculator 2025-11-17 22:19:46 -08:00
0027_add_projected_points_to_team_standings.sql feat: add FIFA World Cup 48-team bracket template with group stage and projected scoring 2026-02-14 22:30:12 -08:00
0028_add_tournament_groups.sql feat: add FIFA World Cup 48-team bracket template with group stage and projected scoring 2026-02-14 22:30:12 -08:00
0029_change_participant_ev_to_decimal.sql Change participant expectedValue from integer to decimal (#1) 2026-02-19 11:26:40 -08:00
0030_add_draft_picks_unique_slot.sql fix: harden draft timer system with race-condition safety and DRY refactor (#34) 2026-02-23 23:23:24 -08:00
0031_add_autodraft_queue_only.sql Claude/redesign autodraft queue c4 kp r (#40) 2026-02-27 22:16:26 -08:00
0032_consolidate_playoff_pattern.sql User/chris/ev f1 framework (#93) 2026-03-09 15:34:31 -07:00
0033_add_schedule_event_type.sql fix: add statement-breakpoint to schedule_event enum migration (#86) 2026-03-07 22:45:59 -08:00
0034_add_ev_snapshots.sql User/chris/ev f1 framework (#93) 2026-03-09 15:34:31 -07:00
0035_increase_prob_precision.sql User/chris/ev f1 framework (#93) 2026-03-09 15:34:31 -07:00
0036_increase_ev_precision.sql User/chris/ev f1 framework (#93) 2026-03-09 15:34:31 -07:00
0037_add_simulator_type_to_sports.sql User/chris/ev f1 framework (#93) 2026-03-09 15:34:31 -07:00
0038_sad_wilson_fisk.sql feat: progressive floor scoring for playoff brackets (#100) 2026-03-10 10:27:58 -07:00
0039_add_ucl_bracket_simulator_type.sql Fix bad migration. 2026-03-11 14:38:45 -07:00
0040_fat_puma.sql Found it in a second spot. 2026-03-11 14:47:19 -07:00
0041_great_magma.sql Add event_starts_at timestamp to scoring events for sub-day ordering (#146) 2026-03-15 10:22:42 -07:00
0042_migrate_event_date_to_starts_at.sql Add event_starts_at timestamp to scoring events for sub-day ordering (#146) 2026-03-15 10:22:42 -07:00
0043_demonic_vanisher.sql Add per-event configurable region config for NCAA-style brackets (#149) (#149) 2026-03-15 21:52:47 -07:00
0044_add_ncaam_bracket_simulator_type.sql Add NCAAM and NCAAW bracket Monte Carlo simulators (#150) 2026-03-15 23:31:47 -07:00
0045_add_ncaaw_bracket_simulator_type.sql Add NCAAM and NCAAW bracket Monte Carlo simulators (#150) 2026-03-15 23:31:47 -07:00
0046_add_nba_bracket_simulator_type.sql Add NBA playoff bracket Monte Carlo simulator (#154) 2026-03-16 21:43:39 -07:00
0047_fix_nba_bracket_simulator_type.sql Fix NBA simulator missing from dropdown and enum not applied to prod DB 2026-03-16 22:18:50 -07:00
0048_eager_songbird.sql Add Discord webhook notifications for standings updates (#157) 2026-03-17 11:16:36 -07:00
0048_mean_enchantress.sql Partial bracket scoring, code review fixes, and double-chance logic (#156) 2026-03-17 10:50:30 -07:00
0049_add_admin_picked_by_type.sql Grant sitewide admins commissioner-level access in leagues (#162) 2026-03-18 00:41:56 -07:00
0050_chief_peter_quill.sql Add NHL playoff simulator and fix simulator dropdown (#166) 2026-03-18 01:23:53 -07:00
0051_add_standings_snapshot_unique_index.sql Fix standings snapshot upsert: atomic writes, correct date, and event-driven updates (#177) 2026-03-18 22:15:28 -07:00
0052_new_warbird.sql Fix migration 2026-03-18 22:54:01 -07:00
0053_smooth_kingpin.sql Add standard draft clock mode (#67) (#189) 2026-03-20 21:36:39 -07:00
0054_massive_vulcan.sql Add regular season standings for NBA/NHL (fixes #89) (#192) 2026-03-21 00:12:01 -07:00
0055_special_vampiro.sql Add regular season standings for NBA/NHL (fixes #89) (#192) 2026-03-21 00:12:01 -07:00
0056_jittery_the_fallen.sql Add AFL season + finals simulator (closes #126) (#204) 2026-03-22 01:57:39 -07:00
0057_cultured_doctor_doom.sql Add snooker bracket simulator and Elo ratings admin UI, fixes #119 2026-03-23 08:24:28 -07:00
0058_add_unique_participant_ev.sql Add snooker bracket simulator and Elo ratings admin UI, fixes #119 2026-03-23 08:24:28 -07:00
0059_mysterious_jack_murdock.sql Add tennis Grand Slam simulator with surface Elo ratings, fixes #116 (#216) 2026-03-23 23:59:35 -07:00
0060_omniscient_outlaw_kid.sql Add tennis Grand Slam simulator with surface Elo ratings, fixes #116 (#216) 2026-03-23 23:59:35 -07:00