Prep Buddy:用 Gemma 3 4B 在笔记本离线运行的 AI 面试教练
Prep Buddy: an AI interview coach for my classmate that runs on his laptop with the Wi-Fi off
开发者用 Gemma 3 4B 和 EmbeddingGemma 打造了离线面试教练 Prep Buddy,在 Apple M2、8 GB 内存笔记本上断网运行,无需 API key 和账号。
This is a submission for the Hacktoberfest Weekend Challenge: Build for a Friend
What I Built
Aman is my classmate. We're both in final-year B.Tech, and like everyone in our batch he's preparing for campus placements: SDE-1 roles, which means technical rounds on DSA, DBMS, Operating Systems, Networks and OOP, plus an HR round.
When I asked him how his prep was going, he wasn't sure. He was putting in the hours, but he couldn't tell which topics were actually weak. Nobody was asking him questions and telling him what he'd missed, so he kept revising the topics he was already comfortable with.
The usual answers didn't fit him either:
- He practises late, around 11 PM, when nobody is free to give him a mock interview.
- The hostel Wi-Fi is unreliable, and paid mock-interview platforms need a stable connection (and money).
- Interview answers are personal. A "tell me about yourself" answer shouldn't have to go to someone else's server.
So I built Prep Buddy: a mock-interview coach that runs entirely on his laptop. It asks him a placement question, grades his typed answer against the points a real interviewer listens for, tells him what he missed, and remembers his weak topics so the next question goes after them.
₹0 to run · no API keys · no account · works with Wi-Fi off · his answers never leave his laptop
A practice session works like this:
- Prep Buddy asks a question from a bank of 56 questions across 7 topics (DSA, CS fundamentals, DBMS, OS, CN, OOP, HR), reworded the way a friendly interviewer would ask it.
- Aman types an answer and gets a score out of 10, what went well, what was missing, an outline of a strong answer and the follow-up question an interviewer would likely ask next.
- If he missed something, the next question is picked to target that gap.
- At the end, he gets a summary with his strongest topic, the one to work on next and 3 concrete next steps.
After a few sessions, the dashboard answers the question he couldn't: where should I spend my next ten minutes?
What Aman Said
“What I liked about Prep Buddy was that after answering the questions, I was provided with instant feedback and it helped me to identify my weak areas. It helped me to know about my strengths and weaknesses prior to the interview.”
Demo
The Wi-Fi is off in this recording. Every question, grade and summary comes from Gemma running locally on my Apple M2 laptop with 8 GB of RAM.
There's no hosted link, on purpose. Hosting Prep Buddy on a server would break the one promise it makes: your answers stay on your laptop. The repo below runs on any 8 GB+ machine.
The badge in the top-right corner says AI ready only when the database is up, Ollama is running and both models are downloaded. If something is missing, it shows the exact command to fix it (for example ollama pull gemma3:4b) instead of an error page.
What I Measured
Machine: Apple M2, 8 GB
Chat model: Gemma 3 4B
Question bank: 56 questions across 7 topics
| Step | Cold | Warm average |
|---|---|---|
| Next question | 41.15 s | 20.37 s |
| Grade answer | 25.50 s | 14.81 s |
| Session summary | 23.81 s | 15.08 s |
For the golden-answer test, all 5 questions passed the required
Excellent > Average > Wrong ordering.
The prompt-injection test scored 2/10 and was classified as weak.
Code
Prep Buddy
An offline, private mock-interview coach for campus placements, powered by Google Gemma running on your own laptop.
Built for Aman for the DEV Hacktoberfest Weekend Challenge: Build for a Friend.
₹0 to run · no API keys · works with Wi-Fi off · your answers never leave your laptop
▶️ Demo video: youtu.be/TgRr7m_U_FE
What it does
- Asks you placement interview questions from a hand-written bank of 56 questions across 7 topics (DSA, CS fundamentals, DBMS, OS, CN, OOP, HR), in a friendly interviewer tone.
- Grades your typed answer: a score out of 10, strengths, gaps, an outline of a strong answer and a follow-up question.
- Remembers your weak topics and picks the next question to target them (EmbeddingGemma + pgvector).
- Ends each session with a short summary and 3 concrete next steps.
| Dashboard | Session summary |
|---|---|
![]() |
![]() |
Why local, open-source AI
Every model call goes to Ollama…
The setup is three steps: start Ollama and pull the two models, run docker compose up for the database, then npm run dev. The README has the full commands. The repo also has the PRD, the architecture, the API reference, the AI design notes and the test results in docs/. The code is MIT-licensed.
How I Built It
The open-source AI at the core:
| Piece | What it does in Prep Buddy |
|---|---|
| Gemma 3 4B (open-weight, 3.3 GB) via Ollama | Rewords questions, grades answers, writes the session summary |
| EmbeddingGemma (622 MB, 768-dim vectors) via Ollama | Turns questions and "what you missed" into vectors |
来源:Google AI:DEV 作者专属(RSS) · dev.to




