Interview AI
An AI-powered interview preparation platform built on the MERN stack. Upload your resume (or describe your background), paste a job description, and get a personalized interview report — technical and behavioral questions with guidance on how to answer them, identified skill gaps, and a day-by-day preparation roadmap.
Features Secure authentication — register/login with JWT stored in HTTP-only cookies, plus token blacklisting on logout Resume parsing — upload a PDF resume, parsed server-side to extract text content AI-generated interview reports — powered by Google Gemini, structured with Zod schema validation, including: Match score against the job description Technical questions with interviewer intent and suggested answers Behavioral questions with interviewer intent and suggested answers Identified skill gaps with severity ratings A day-by-day preparation plan AI-generated tailored resume PDF — generates a job-tailored resume as HTML and converts it to a downloadable PDF via Puppeteer Protected routes — report pages only accessible to authenticated users Tech Stack
Frontend
React (Vite) React Router Axios SCSS
Backend
Node.js / Express MongoDB with Mongoose JSON Web Tokens (JWT) for auth Google Gemini API (@google/genai) for AI report/resume generation Zod for schema validation and structured AI output Puppeteer for HTML-to-PDF conversion pdf-parse for resume text extraction Project Structure Backend/ src/ controllers/ # Route handlers (auth, interview) models/ # Mongoose schemas (User, InterviewReport, Blacklist) routes/ # Express routers services/ # Business logic (ai.service.js — Gemini integration) middlewares/ # Auth middleware, file upload handling server.js
Frontend/ src/ features/ auth/ # Login, Register, auth context/hooks/API interview/ # Home (report generator), Interview (report viewer) app.routes.jsx Getting Started Prerequisites Node.js A MongoDB Atlas cluster (or local MongoDB instance) A Google Gemini API key Backend Setup bash cd Backend npm install
Create a .env file in Backend/:
MONGO_URI=your_mongodb_connection_string JWT_SECRET=your_jwt_secret GOOGLE_GENAI_API_KEY=your_gemini_api_key bash npm run dev Frontend Setup bash cd Frontend npm install npm run dev
The app will be available at http://localhost:5173, with the backend running on http://localhost:3000.
Architecture Notes
The frontend follows a layered pattern:
UI layer — presentational components (Home.jsx, Interview.jsx) Hook layer — custom hooks (useAuth, useInterview) that own state and orchestrate API calls State layer — React Context (AuthContext, InterviewContext) API layer — Axios service functions (auth.api.js, interview.api.js) License
This project was built for learning purposes as part of ongoing full-stack development practice.