feat(scripts): rewrite parser as modular Python CLI
Replace monolithic scraping scripts with sportstime_parser package: - Multi-source scrapers with automatic fallback for 7 sports - Canonical ID generation for games, teams, and stadiums - Fuzzy matching with configurable thresholds for name resolution - CloudKit Web Services uploader with JWT auth, diff-based updates - Resumable uploads with checkpoint state persistence - Validation reports with manual review items and suggested matches - Comprehensive test suite (249 tests) CLI: sportstime-parser scrape|validate|upload|status|retry|clear Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
227
Scripts/league_structure.json
Normal file
227
Scripts/league_structure.json
Normal file
@@ -0,0 +1,227 @@
|
||||
[
|
||||
{
|
||||
"id": "mlb_league",
|
||||
"sport": "MLB",
|
||||
"type": "league",
|
||||
"name": "Major League Baseball",
|
||||
"abbreviation": "MLB",
|
||||
"parent_id": null,
|
||||
"display_order": 0
|
||||
},
|
||||
{
|
||||
"id": "mlb_al",
|
||||
"sport": "MLB",
|
||||
"type": "conference",
|
||||
"name": "American League",
|
||||
"abbreviation": "AL",
|
||||
"parent_id": "mlb_league",
|
||||
"display_order": 1
|
||||
},
|
||||
{
|
||||
"id": "mlb_nl",
|
||||
"sport": "MLB",
|
||||
"type": "conference",
|
||||
"name": "National League",
|
||||
"abbreviation": "NL",
|
||||
"parent_id": "mlb_league",
|
||||
"display_order": 2
|
||||
},
|
||||
{
|
||||
"id": "mlb_al_east",
|
||||
"sport": "MLB",
|
||||
"type": "division",
|
||||
"name": "AL East",
|
||||
"abbreviation": null,
|
||||
"parent_id": "mlb_al",
|
||||
"display_order": 3
|
||||
},
|
||||
{
|
||||
"id": "mlb_al_central",
|
||||
"sport": "MLB",
|
||||
"type": "division",
|
||||
"name": "AL Central",
|
||||
"abbreviation": null,
|
||||
"parent_id": "mlb_al",
|
||||
"display_order": 4
|
||||
},
|
||||
{
|
||||
"id": "mlb_al_west",
|
||||
"sport": "MLB",
|
||||
"type": "division",
|
||||
"name": "AL West",
|
||||
"abbreviation": null,
|
||||
"parent_id": "mlb_al",
|
||||
"display_order": 5
|
||||
},
|
||||
{
|
||||
"id": "mlb_nl_east",
|
||||
"sport": "MLB",
|
||||
"type": "division",
|
||||
"name": "NL East",
|
||||
"abbreviation": null,
|
||||
"parent_id": "mlb_nl",
|
||||
"display_order": 6
|
||||
},
|
||||
{
|
||||
"id": "mlb_nl_central",
|
||||
"sport": "MLB",
|
||||
"type": "division",
|
||||
"name": "NL Central",
|
||||
"abbreviation": null,
|
||||
"parent_id": "mlb_nl",
|
||||
"display_order": 7
|
||||
},
|
||||
{
|
||||
"id": "mlb_nl_west",
|
||||
"sport": "MLB",
|
||||
"type": "division",
|
||||
"name": "NL West",
|
||||
"abbreviation": null,
|
||||
"parent_id": "mlb_nl",
|
||||
"display_order": 8
|
||||
},
|
||||
{
|
||||
"id": "nba_league",
|
||||
"sport": "NBA",
|
||||
"type": "league",
|
||||
"name": "National Basketball Association",
|
||||
"abbreviation": "NBA",
|
||||
"parent_id": null,
|
||||
"display_order": 9
|
||||
},
|
||||
{
|
||||
"id": "nba_eastern",
|
||||
"sport": "NBA",
|
||||
"type": "conference",
|
||||
"name": "Eastern Conference",
|
||||
"abbreviation": "East",
|
||||
"parent_id": "nba_league",
|
||||
"display_order": 10
|
||||
},
|
||||
{
|
||||
"id": "nba_western",
|
||||
"sport": "NBA",
|
||||
"type": "conference",
|
||||
"name": "Western Conference",
|
||||
"abbreviation": "West",
|
||||
"parent_id": "nba_league",
|
||||
"display_order": 11
|
||||
},
|
||||
{
|
||||
"id": "nba_atlantic",
|
||||
"sport": "NBA",
|
||||
"type": "division",
|
||||
"name": "Atlantic",
|
||||
"abbreviation": null,
|
||||
"parent_id": "nba_eastern",
|
||||
"display_order": 12
|
||||
},
|
||||
{
|
||||
"id": "nba_central",
|
||||
"sport": "NBA",
|
||||
"type": "division",
|
||||
"name": "Central",
|
||||
"abbreviation": null,
|
||||
"parent_id": "nba_eastern",
|
||||
"display_order": 13
|
||||
},
|
||||
{
|
||||
"id": "nba_southeast",
|
||||
"sport": "NBA",
|
||||
"type": "division",
|
||||
"name": "Southeast",
|
||||
"abbreviation": null,
|
||||
"parent_id": "nba_eastern",
|
||||
"display_order": 14
|
||||
},
|
||||
{
|
||||
"id": "nba_northwest",
|
||||
"sport": "NBA",
|
||||
"type": "division",
|
||||
"name": "Northwest",
|
||||
"abbreviation": null,
|
||||
"parent_id": "nba_western",
|
||||
"display_order": 15
|
||||
},
|
||||
{
|
||||
"id": "nba_pacific",
|
||||
"sport": "NBA",
|
||||
"type": "division",
|
||||
"name": "Pacific",
|
||||
"abbreviation": null,
|
||||
"parent_id": "nba_western",
|
||||
"display_order": 16
|
||||
},
|
||||
{
|
||||
"id": "nba_southwest",
|
||||
"sport": "NBA",
|
||||
"type": "division",
|
||||
"name": "Southwest",
|
||||
"abbreviation": null,
|
||||
"parent_id": "nba_western",
|
||||
"display_order": 17
|
||||
},
|
||||
{
|
||||
"id": "nhl_league",
|
||||
"sport": "NHL",
|
||||
"type": "league",
|
||||
"name": "National Hockey League",
|
||||
"abbreviation": "NHL",
|
||||
"parent_id": null,
|
||||
"display_order": 18
|
||||
},
|
||||
{
|
||||
"id": "nhl_eastern",
|
||||
"sport": "NHL",
|
||||
"type": "conference",
|
||||
"name": "Eastern Conference",
|
||||
"abbreviation": "East",
|
||||
"parent_id": "nhl_league",
|
||||
"display_order": 19
|
||||
},
|
||||
{
|
||||
"id": "nhl_western",
|
||||
"sport": "NHL",
|
||||
"type": "conference",
|
||||
"name": "Western Conference",
|
||||
"abbreviation": "West",
|
||||
"parent_id": "nhl_league",
|
||||
"display_order": 20
|
||||
},
|
||||
{
|
||||
"id": "nhl_atlantic",
|
||||
"sport": "NHL",
|
||||
"type": "division",
|
||||
"name": "Atlantic",
|
||||
"abbreviation": null,
|
||||
"parent_id": "nhl_eastern",
|
||||
"display_order": 21
|
||||
},
|
||||
{
|
||||
"id": "nhl_metropolitan",
|
||||
"sport": "NHL",
|
||||
"type": "division",
|
||||
"name": "Metropolitan",
|
||||
"abbreviation": null,
|
||||
"parent_id": "nhl_eastern",
|
||||
"display_order": 22
|
||||
},
|
||||
{
|
||||
"id": "nhl_central",
|
||||
"sport": "NHL",
|
||||
"type": "division",
|
||||
"name": "Central",
|
||||
"abbreviation": null,
|
||||
"parent_id": "nhl_western",
|
||||
"display_order": 23
|
||||
},
|
||||
{
|
||||
"id": "nhl_pacific",
|
||||
"sport": "NHL",
|
||||
"type": "division",
|
||||
"name": "Pacific",
|
||||
"abbreviation": null,
|
||||
"parent_id": "nhl_western",
|
||||
"display_order": 24
|
||||
}
|
||||
]
|
||||
Reference in New Issue
Block a user