brackt/plans
Chris Parsons 79ec477a98 feat: implement Expected Value System with ICM probability calculator
Implements Phase 5.2 of the EV system with Harville-Malmuth Independent Chip Model
for calculating participant placement probabilities from futures odds.

## Key Features

### ICM Probability Calculator
- Implements Harville-Malmuth method for distributing probabilities
- Converts American odds to championship probabilities
- Generates P(1st) through P(8th) for all participants
- Column-normalized: each placement sums to 100% across all teams
- Works with any number of participants (not limited to 8)

### Admin UI - Futures Odds Entry
- Enter American odds (e.g., +550, -200) for championship futures
- Live preview of ICM-calculated probability distributions
- Displays all 8 placement probabilities
- Persists odds for editing on subsequent visits
- Automatic probability normalization (removes bookmaker vig)

### Database Schema Updates
- Renamed participant_expected_values.season_id → sports_season_id
- Updated foreign key to reference sports_seasons instead of seasons
- Added source_odds field to store original futures odds
- Migration 0025: Column rename and FK update
- Migration 0026: Add source_odds field

### Model Layer
- participant-expected-value: CRUD operations for probability distributions
- Supports multiple probability sources (manual, futures_odds, elo_simulation)
- Automatic EV calculation based on league scoring rules
- Probability validation and normalization

### Service Layer
- icm-calculator: Harville-Malmuth probability distribution
- probability-engine: Odds conversion and Elo utilities (for future use)
- bracket-simulator: Monte Carlo simulation (for future hybrid approach)
- ev-calculator: Expected value computation from probabilities

## Technical Details

- Uses exponential decay favoring top positions for strong teams
- Preserves championship probability ordering in final distributions
- Row sums vary (strong teams ~100%, weak teams lower)
- All probabilities between 0-1, mathematically valid
- Comprehensive test suite: 97 tests passing

## Future Enhancements

- Hybrid approach: ICM pre-playoffs, bracket simulation during playoffs
- Integration with league-specific scoring rules
- Historical probability tracking for accuracy analysis

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-17 22:19:46 -08:00
..
bracket-expansion.md feat: Implement bracket expansion plan to support various tournament structures 2025-11-03 09:36:16 -08:00
draft-room-implementation.md feat: add draft API routes and implement draft room pick controls 2025-10-18 14:55:26 -07:00
draft-room-redesign.md feat: Implement draft room redesign with collapsible sidebar and tabbed content 2025-10-25 03:23:41 -07:00
e2e-testing-setup.md docs: add E2E testing setup plan with Cypress authentication and test database configuration 2025-10-21 12:49:17 -07:00
omni-league-draft-rules-IMPLEMENTATION-SUMMARY.md Implement Omni League Draft Eligibility Rules 2025-10-24 21:12:07 -07:00
omni-league-draft-rules.md Implement Omni League Draft Eligibility Rules 2025-10-24 21:12:07 -07:00
phase-2.7-testing-instructions.md Add bracket seeding tests and implement tournament-style seeding for 16 and 32-team brackets 2025-11-04 22:09:44 -08:00
phase-3-server-js-changes.md feat: plan Socket.IO server setup and client hook for real-time draft updates 2025-10-16 17:19:32 -07:00
phase-3-socket-implementation-plan.md feat: plan Socket.IO server setup and client hook for real-time draft updates 2025-10-16 17:19:32 -07:00
phase-3-socket-implementation-summary.md feat: plan Socket.IO server setup and client hook for real-time draft updates 2025-10-16 17:19:32 -07:00
phase-3-verification.md feat: integrate Socket.IO server with HTTP server and draft room functionality 2025-10-16 18:15:04 -07:00
phase-4-socket-test-instructions.md feat: add socket test route and echo event handler for debugging 2025-10-17 12:15:07 -07:00
phase-5-detailed-implementation-plan.md feat: implement Expected Value System with ICM probability calculator 2025-11-17 22:19:46 -08:00
phase-5-expected-value-planning.md Implement detailed Phase 5 implementation plan for Expected Value System 2025-11-15 22:54:59 -08:00
phase2-bugs-review.md feat: Implement bracket expansion plan to support various tournament structures 2025-11-03 09:36:16 -08:00
scoring-system.md feat: add recharts library and implement PointProgressionChart component for historical views 2025-11-14 21:18:34 -08:00
server-typescript-conversion-compiled.md refactor: migrate server code from JavaScript to TypeScript with build pipeline 2025-10-18 22:16:04 -07:00
server-typescript-conversion.md refactor: migrate server code from JavaScript to TypeScript with build pipeline 2025-10-18 22:16:04 -07:00
testing-implementation.md ci: add test job to GitHub workflow and setup testing dependencies 2025-10-21 12:47:11 -07:00