Case Study
Athlix AI
Risk terminal for athlete finances, now backed by live NBA data (BALLDONTLIE) and a k-NN comparables engine. An honest backtest shows the collapse heuristic beats base rate ~2x but doesn't clearly outperform a simple age-31 rule — reported as-is. 63 tests.
Executive Summary
Athlix AI is a risk terminal for athlete finances, started at the Cursor Boston × AIC × Hult sports hackathon and since rebuilt on real data. It pulls live NBA stats from the BALLDONTLIE API, overlays a real bundled salary/cap snapshot, finds statistical comparables with a k-NN engine, and backtests its collapse heuristic against real careers — reporting the result as it fell, not as marketing.
Problem & Constraints
Pro athletes face compressed earning windows, volatile income, and complex contracts. Most tools in this space demo well on fabricated numbers; the constraint here was that every number shown is either real, derived from real data, or explicitly labeled as a scenario assumption.
Architecture
Landing → /dashboard/[slug] terminal → live BALLDONTLIE feed + bundled salary CSV → risk-tier engine (single-source thresholds) → k-NN comparables → scenario simulator → /backtest results page → OpenRouter/DeepSeek analyst chat.
Methodology
- Live NBA data (teams, seasons, recent games) from BALLDONTLIE, with a labeled offline fallback — verified with real server-rendered fetches
- Real contract/cap overlay from a bundled salary snapshot; the fabricated financials the hackathon build shipped were deleted
- k-NN comparable-players engine on bundled season stats
- Projection band rendered around the wealth curve instead of a single false-precision line
- Backtest of the collapse heuristic against real careers, including a trivial "flag everyone over 31" baseline for context
- Risk-tier thresholds and colors consolidated into one module; rate limiting, zod validation, and fetch timeouts on all API routes
Results & Metrics
| Metric | Result |
|---|---|
| Backtest signal | Precision beats base rate at every threshold (~2× lift) |
| Honest ceiling | Does not clearly beat a trivial age-31 rule — stated in the UI |
| Live data | BALLDONTLIE NBA API, server-side key |
| Tests | 63 (vitest), all passing |
| CI | lint → test → build, builds with empty keys |
The backtest page says the quiet part out loud: the signal is real but modest, and injury is proxied from games played. That is the honest ceiling of hand-tuned weights.
Tech Stack
Next.js 16, TypeScript, Tailwind CSS v4, Framer Motion, Recharts, Vercel AI SDK, OpenRouter/DeepSeek, BALLDONTLIE API
Future Work
Learned model to replace the hand-tuned heuristic, real injury data, agent/advisor matching.