If you have ever prepared for a software-engineering placement cycle, you know the ritual: open Blind 75 in one tab, NeetCode 150 in another, Striver's sheet in Notion, LeetCode in a third window, and manually tick boxes when you finally get an Accepted verdict. Nobody tells you which pattern you are weak in relative to Google or Amazon interviews. Nobody holds you accountable when you skip a week. And every AI chatbot gives the same generic two-pointer lecture whether you solved 200 mediums yesterday or zero.
I built **LeetRun** to close that gap — not as a side spreadsheet, but as a live SaaS product with Deep LeetCode Sync, pattern-weighted prep, adaptive quests, a savage AI mentor grounded in your actual data, leaderboards, and multiplayer coding rooms. It is live today at leetrun.vercel.app, with guest-preview routes so anyone can browse sheets, patterns, and analytics before signing up.
The problem: prep is scattered, unmotivating, and lonely
LeetCode itself is excellent for solving problems. It is terrible for orchestrating a multi-sheet, multi-company prep strategy. The pain points I kept hitting — and that every batchmate echoed — were predictable:
- Manual checkbox tracking across Blind 75, NeetCode 150, Striver SDE, Striver A2Z, Love Babbar 450, and company-specific lists.
- No single view of topic-level weakness versus real interview pattern weightage (DP, graphs, sliding window, etc.).
- Grinding alone with no leaderboard, streak, or social accountability.
- AI tools that do not know what you solved yesterday, what quest you are on, or when to push harder.
- Revision sets that require manual curation instead of adaptive generation from your gaps.
What LeetRun actually ships
LeetRun is not a clone of LeetCode. It is the command centre around LeetCode. The live product surface includes:
- Curated sheets: Blind 75, NeetCode 150, Striver SDE Sheet, Striver A2Z, Striver 79 (Last Moment), Love Babbar 450, Google Top 100, Amazon Top 100.
- Deep LeetCode Sync: one import of your full accepted history auto-checks every matched problem on every sheet.
- Interview patterns: DP, graphs, two pointers, sliding window, and more — ranked by weightage with C++ templates ready to copy.
- Build-your-own revision: random practice sets filtered by topic, difficulty, and solved state.
- Adaptive quests: daily, weekly, and revision quests generated from weakest topics and target company — auto-verified against real LeetCode solves.
- Savage AI mentor: context-aware coach with personality modes from supportive to savage (Pro unlocks full roast mode).
- Leaderboards: global and friends boards by XP, level, streak, solve count, or contest rating.
- Multiplayer rooms: private 6-char codes, live solve progress, mock contests with your batch.
- Public profiles: shareable analytics, levels, streaks, and badges for resumes and LinkedIn.
Guest-preview routes (`/sheets`, `/patterns`, `/analytics`) let prospects explore the full product depth before creating an account — a deliberate GTM choice for a student audience that is sceptical of yet another signup wall.
Deep Sync: one import, every sheet auto-checked
Basic LeetCode integrations show public profile stats. Deep Sync goes further. The user authenticates once with their LeetCode session token. LeetRun calls the LeetCode GraphQL API to fetch complete accepted submission history — not just recent activity.
That history is indexed against 1,500+ problems mapped across eight curated and company sheets. Every match is auto-marked simultaneously. Progress bars, difficulty breakdowns, and section completion update in real time. Quest verification, XP awards, and leaderboard rankings all derive from this single source of truth — no manual tick boxes, no drift between sheets.
- User completes one-time LeetCode session authentication during onboarding.
- Backend fetches full accepted submission graph via GraphQL.
- Submissions are normalised and matched against the internal problem corpus (slug, id, difficulty, pattern tags).
- Every sheet row updates atomically — Blind 75 row 12 and NeetCode row 47 both check off if the same underlying problem was solved.
- Client caches sheet state in localStorage SWR for instant repaint on reload; server revalidates on sync.
This was the feature that made LeetRun feel magical in user testing. The reaction was always the same: *"Wait, it already knows I solved all of these?"* Yes. That is the point.
Savage AI mentor: context snapshot plus RAG, not a chatbot wrapper
An AI mentor is only as good as its context window. When a user asks LeetRun a question, we do not pass a bare prompt to Gemini or Groq. We intercept the request and compile a context snapshot: LeetCode stats, current streak, active daily quests, sheet completion percentages, and weakest pattern families by weightage.
On top of that personal context, a RAG retrieval layer searches a corpus of 1,500+ indexed problems, 21 interview pattern families, and system-design notes. Lexical scoring selects citeable chunks before generation — reducing hallucinated constraints and invented problem variants. The model responds as a hyper-personalised technical coach, not a generic ChatGPT tab.
Why both Gemini and Groq
Gemini handles complex explanations, multi-step reasoning, and system-design grounding where a large context window matters. Groq serves low-latency coaching when the user is mid-session and waiting on a response feels like friction. The router sends queries to the optimal model based on complexity, expected response length, and whether the user is in savage mode (Pro) versus standard coaching (Free).
The defining feature of LeetRun is not the sync — it is the context engine. The AI needs to know exactly what you solved yesterday, which patterns you struggle with, and when to stop being nice and push you to execute.
Gamification that respects the grind
Interview prep is a marathon. Consistency beats intensity. LeetRun's gamification layer is designed to make daily practice feel like progress rather than punishment:
- XP system: Easy 15, Medium 40, Hard 120 — verified against real LeetCode accepts, not self-reported clicks.
- Streaks and levels: visible on public profiles and leaderboards.
- Adaptive quests: daily (Free), weekly and revision (Pro) — generated from weakest topics and optional target company.
- Leaderboards: global and friends, ranked by XP, level, streak, solve count, or contest rating. Pre-fetched server-side with 60-second revalidation.
- Multiplayer rooms: 6-character room codes, live member progress, mock contests and study sessions.
- Badges and coins: progression rewards tied to verified solves and quest completion.
Free tier includes daily quests, basic leaderboard, standard AI mentor, and one multiplayer room. Pro at ₹299/month unlocks weekly and revision quests, savage AI mentor mode, unlimited rooms, XP badges, and friend invites. Team is custom pricing for college cohorts up to 20 members with shared leaderboards and admin analytics.
| Tier | Price | Highlights |
|---|---|---|
| Free | ₹0 forever | Sync, daily quests, basic leaderboard, standard AI, 1 room, guest preview |
| Pro | ₹299/month | Weekly + revision quests, savage AI, unlimited rooms, badges, friend invites |
| Team | Custom | Up to 20 members, shared leaderboard, custom company tracks, admin analytics |
Founding offer: Pro free for the first 200 users, no credit card required. That is a deliberate early-adopter bet — students share products that respect their budget.
PostgreSQL and why spreadsheets were not enough
LeetRun's data model is deeply relational: users, problems, sheets, user-problem join tables, quest progress, XP events, leaderboard rankings, multiplayer room state, and friend graphs. PostgreSQL with Prisma ORM gives type-safe join queries and the performance headroom to serve leaderboard and analytics endpoints without denormalising everything into JSON blobs.
Firebase or a document store could work for a MVP checklist app. It would fight you once you need ranked leaderboards, quest verification against historical solves, and room state with live member progress. I chose Postgres early so the product could grow into Team cohorts and admin analytics without a schema rewrite.
Five caching layers for a product that must feel instant
Guest-preview traffic and returning users both expect sub-second page loads. LeetRun runs five distinct caching tiers in sequence:
- Next.js unstable_cache for leaderboard and profile data with 60-second revalidation.
- HTTP Cache-Control (`s-maxage` + `stale-while-revalidate`) on analytics API routes.
- In-memory memoization for the static 1,500+ problem corpus loaded at boot.
- localStorage SWR on the client for instant sheet and analytics repaints; wiped on logout.
- Vercel Edge CDN caching for guest-preview routes (`/sheets`, `/patterns`, `/analytics`).
The goal is not premature optimisation for millions of users on day one. It is predictable latency as concurrent rooms, leaderboard refreshes, and sync jobs compete for the same Postgres instance on a hobby-tier deployment.
Observability from day one
Solo SaaS products fail silently if you cannot see errors. LeetRun ships with Sentry across Node.js, Edge, and client runtimes (10% trace sampling), plus PostHog dual-track: client SPA pageviews and server-side capture for funnels that survive ad blockers. When Deep Sync fails on a malformed LeetCode token or an AI route times out on Groq, I know before a user posts in Discord.
Stack summary
| Layer | Choices |
|---|---|
| Frontend | Next.js 16, TypeScript, Tailwind CSS |
| Auth & data | Supabase Auth, PostgreSQL, Prisma ORM |
| AI | Gemini API, Groq API, RAG retrieval, lexical scoring |
| External | LeetCode GraphQL (authenticated Deep Sync) |
| Observability | Sentry, PostHog |
| Deploy | Vercel, Edge CDN, multi-layer SWR |
What I learned building a personal product as SaaS
LeetRun started as a tool I needed during my own prep cycle. Productising it forced decisions client work sometimes lets you defer: pricing in INR for Indian students, guest preview instead of hard paywalls, founding-member caps instead of fake urgency, and caching architecture before traffic justifies it.
The hardest engineering was not the UI — it was trust. Users hand over LeetCode session tokens and expect every sheet to stay in sync forever. Deep Sync, quest verification, and XP integrity had to be boringly correct. The fun parts (savage AI roasts, leaderboard climbs, room codes) only work if the data layer never lies.
For the full visual case study — architecture timeline, product screenshots, and outcome metrics — see the LeetRun case study. For the works-page overview and live links, see LeetRun on the portfolio. Try the product directly at leetrun.vercel.app.
If you are building retrieval-grounded AI over structured domain data, the RAG patterns in schema-aware NL2SQL share the same lexical-scoring philosophy. For deployment and Postgres choices on Vercel, Docker, GCP, and Supabase to scale covers the infrastructure mindset I apply across client and personal products alike.