Cricket (ODI/T20) & Tour de France stats from a Custom GPT connected to 3 live databases.
Published: September 17, 2025
Ask it a natural-language question. It queries the right DB and gives you the answer. It's a live connection to three separately hosted Postgres databases - Supabase, Neon & Aiven.
The GPT dynamically shifts connections to analyze 340 MB of data spanning 2.5 million rows in six tables across the 3 databases - 122-year history for Tour de France, and 22 years for Cricket across 7,596 matches.
The Databases (Live Data)
- supabase_postgres → ODI ball-by-ball (2003→2025) / 1.5M rows
- neon_postgres → T20 ball-by-ball (2005→2025) / 1M rows
- aiven_postgres → Tour de France riders + stages (men 1903→2025; women 2022→2025)
What it Does
- Computes player stats (runs, strike rate, averages)
- Builds rankings (top scorers, best bowlers, most wins)
- Summarizes Tour history (winners, distance, avg speed)
- Produces charts & run statistical analysis with python
Try it yourself - sample questions
The GPT has starter prompts. Ask things like:
- Cricket: "Top 10 ODI strikers by total runs off the bat, with matches, overs, and run rates per match/over. Add two charts for run rates."
- Tour de France: "Show Tour de France winners from 2015–2025 with distance, time, and average speed. Also, chart the riders with 3+ wins in history."
Custom GPT = practical analytics tool
- UI + agent + Python sandbox out of the box. Efficient + cost effective
- Use for automations, report generators, and database applications
- Live examples: app.tigzig.com → GPT section (top menu)
Customize & Deploy
- FastAPI backend powers any custom front end, BI tool, or internal app.
- Open-source - repo and docs include architecture, action schema, and deployment steps.
- Auth: Bearer API key in this GPT. OAuth supported for role-based access and RLS (row level security)
Links
- SQL AI Apps: app.tigzig.com → Database AI & SQL Apps
- Database providers: neon.com, aiven.io, supabase.com
🔗
Blog Migration Notice: Some links or images in earlier posts may be broken.
View the original post on the old blog site.