{"slug": "prepmate-practice-interviews-while-gemma-4-does-the-prep-work", "title": "PrepMate: Practice Interviews While Gemma 4 Does the Prep Work", "summary": "A student developer built PrepMate, a local mock-interview application that runs Gemma 4 through Ollama on the user's own laptop. The app extracts resume text client-side with pdf.js, generates tailored questions from a resume and job description, records spoken answers, and returns per-answer communication and technical or behavioral scores with written feedback, all stored in local SQLite. The developer reports that disabling the reasoning trace with think: false, setting num_ctx to 16384, and constraining output with a JSON schema cut latency, with questions taking roughly 20 to 60 seconds and feedback 10 to 30 seconds on gemma4:e2b.", "body_md": "*This is a submission for the [Hacktoberfest Open-Source AI Challenge Week 3: Slow and Steady](https://dev.to/challenges/hacktoberfest-week3-2026-10-19)*\n\n**PrepMate** is a mock interviewer that runs on your own laptop. You drop in your resume PDF, paste the job description, pick Technical, HR or Managerial, and then you just talk. Gemma 4 reads your background, asks you tailored questions out loud, listens to your spoken answers, and when you end the session it hands you a scorecard: a communication score and a technical (or behavioral) score for every answer, a written comment on each one, an overall score, and a short list of things to work on.\n\nInterview prep is the task everyone puts off. Doing it properly means hunting for question lists that match your role, rehearsing answers alone in your head with no idea whether they're any good, or convincing a friend to play interviewer for an hour and then give you honest feedback. PrepMate does all three jobs. The only effort left for you is showing up and speaking.\n\nThe lazy parts it handles for you:\n\nI'm a student heading into interview season, so I'm the first lazy person this was built for.\n\n*The home page. One button and you're in.*\n\n*Setting up a session: fill in the role, paste the job description, and upload your resume as a PDF. That's all the typing you'll do.*\n\nPractice interviews with a local AI interviewer, answer by voice, and get scored feedback on every session.\n\nPrepMate runs a full mock interview on your own machine. It reads your resume and the job description, asks tailored questions out loud, records your spoken answers, and then scores each answer with written feedback. The AI model (Gemma 4) runs locally through Ollama, and all data is stored in a local SQLite file.\n\n```\nBrowser (React + TypeScript + Vite)\n   │  /api/*\n   ▼\nExpress on 127.0.0.1:3001\n   ├── auth  → SQLite users + sessions\n   ├── data  → SQLite profiles, interviews, ratings\n   └── ai    → Ollama at 127.0.0.1:11434 (gemma4:e2b)\n```\n\nThe server only listens on `127.0.0.1`, and the resume PDF never leaves the browser: pdf.js extracts the text client-side, and only that text goes into the prompt.\n\nThe whole AI layer is one call to Ollama's chat API:\n\n``` js\nconst res = await fetch(`${url}/api/chat`, {\n  method: 'POST',\n  headers: { 'Content-Type': 'application/json' },\n  signal: controller.signal,\n  body: JSON.stringify({\n    model,                       // gemma4:e2b by default\n    messages: [{ role: 'user', content: prompt }],\n    stream: false,\n    think: false,                // skip the reasoning trace, it only adds latency here\n    ...(format ? { format } : {}), // JSON schema for feedback\n    options: { num_ctx: numCtx },  // 16384\n  }),\n});\n```\n\nThree settings did most of the work:\n\n`think: false`.` num_ctx: 16384`.` format`, and Gemma's output is constrained to that shape. HR and Behavioral interviews get a behavioral score; Technical and Managerial get a technical score:\n\n``` js\nconst perQuestion = softSkillsInterview\n  ? { question: str, answer: str, communicationScore: scoreInt, fluencyComment: str, behavioralComment: str }\n  : { question: str, answer: str, communicationScore: scoreInt, technicalScore: scoreInt, fluencyComment: str, techComment: str };\n```\n\n`gemma4:e2b` is small enough to run on an ordinary laptop, so the prompts are explicit about format: one question per line, no headings, no labels, nothing else. A tolerant parser then keeps lines that end in a question mark, so a stray intro sentence from the model doesn't end up as \"question 1\".\n\nBefore an interview starts, a system check calls `/api/health`, which asks Ollama whether it's running and whether the model is installed. If either is missing, the Start button stays locked and the page shows the exact command to fix it (`ollama serve` or `ollama pull gemma4:e2b`).\n\nLocal generation is slower than a cloud API. On `gemma4:e2b`, questions take roughly 20 to 60 seconds and feedback 10 to 30 seconds, depending on the machine. The app says so up front instead of pretending otherwise. For a week themed on sloths, a short wait in exchange for keeping everything on your own disk felt like a fair trade.\n\nA mock interview is personal data. Your resume carries your phone number, email, college and grades, and your answers include things like \"tell me about a time you failed.\" The resume text, questions, answers and scores live in one SQLite file on your disk, and the API isn't reachable from outside your machine.\n\nWhere the open approach worked better than the closed one:\n\n`ollama pull`, and nothing expires.` OLLAMA_MODEL=gemma4:e4b` gives better questions and feedback if your machine has the memory for it. Nothing else changes.\nOne honest caveat: speech-to-text still uses the browser's Web Speech API, and Chrome sends that audio to Google's speech service. So PrepMate isn't fully offline yet. The AI, the data and your resume are local, but live transcription needs a connection. Moving transcription to a local Whisper model is the next step to close that gap.\n\n`gemma4:e2b`) runs locally through Ollama and generates every interview question, the follow-up rounds, and all scored feedback, with schema-constrained JSON output for the scorecards.\n<!-- Only keep the line below if you embed or link a DevRelay agent session above -->\n<!-- - Thanks for reading. If you try it, I'd like to hear how it scored you.", "url": "https://wpnews.pro/news/prepmate-practice-interviews-while-gemma-4-does-the-prep-work", "canonical_source": "https://dev.to/rahultapase/prepmate-practice-interviews-while-gemma-4-does-the-prep-work-3icj", "published_at": "2026-10-25 19:09:41+00:00", "updated_at": "2026-10-25 19:13:40.749507+00:00", "lang": "en", "topics": ["artificial-intelligence", "large-language-models", "ai-tools", "ai-products"], "entities": ["PrepMate", "Gemma 4", "Ollama", "SQLite", "pdf.js", "React", "TypeScript", "Hacktoberfest"], "also_reported_by": [], "alternates": {"html": "https://wpnews.pro/news/prepmate-practice-interviews-while-gemma-4-does-the-prep-work", "markdown": "https://wpnews.pro/news/prepmate-practice-interviews-while-gemma-4-does-the-prep-work.md", "text": "https://wpnews.pro/news/prepmate-practice-interviews-while-gemma-4-does-the-prep-work.txt", "jsonld": "https://wpnews.pro/news/prepmate-practice-interviews-while-gemma-4-does-the-prep-work.jsonld"}}