100%
of AI-written numbers checked against the database
2
report formats players can download: PDF and Excel
3
roles: player and coach, with an invitation flow
The client
ScoreSmart.ai is a golf performance and coaching platform. Players log rounds and practice; coaches follow their players; both get analysis of where strokes are being lost, handicap tracking, and reports they can download as PDF or Excel.
The brief
Use AI to turn a golfer's data into plain-language coaching insight, without the one failure that would end trust in the product: an AI that states a number the player never achieved.
What we built
A multi-role web platform on Next.js and Supabase, with separate player, coach and admin experiences and an invitation flow between them:
- Round and practice entry, handicap tracking and shot-category analysis (driving, approach, putting and scoring), built on a versioned database schema.
- "Scoring leaks" analysis that shows where a player loses strokes.
- AI insights and weekly reports written with the Vercel AI SDK.
- Background jobs with Inngest, transactional email with Resend, and PDF and Excel report generation.
- A real test suite from early on: Vitest unit tests and Playwright end-to-end tests.
The part we're proudest of: grounded AI
The interesting engineering isn't calling a model. It's refusing to let one invent a number.
Every number the model writes is checked on the server against the values the database computed and handed to it, before the text is shown or stored. A number passes only if it matches a value the database supplied, allowing for ordinary rounding. If a number doesn't match, the text never reaches the player.
The safest AI output is the one that can be checked. Every figure a player sees traces back to a value the database calculated.
Sookshum Labs engineering
Two details make it hold up in practice:
- Untracked metrics can never be cited. If a player didn't record something, the product can't quote a number for it, so "we didn't measure your fairways" never turns into an invented fairway percentage.
- We test the refusal, not just the happy path. The acceptance test seeds an insight containing a deliberately wrong number and proves the product blocks it.
What we'd carry into the next AI product
- Ground first, polish second. We now design the checking layer before writing prompts, because it decides what the model is allowed to say.
- Add a quality review loop. Automated tests prove the guard fires. Alongside them, we schedule regular human review of grounded output so the writing improves, not just the accuracy.
Gallery
