Skip to content

Shriya-25/Prepwise

Repository files navigation

PrepWise — AI-Powered Interview Preparation Platform

PrepWise helps students and freshers practice mock interviews with AI-generated questions and receive structured, actionable feedback powered by Google Gemini.

Features

  • AI Question Generation — Gemini generates role-specific interview questions (HR, Technical Basics, Technical Advanced)
  • Timed Interview Sessions — Realistic interview experience with per-question timers (2:45 per question)
  • AI Evaluation — Detailed scoring and feedback on each answer with ideal answer suggestions
  • Dynamic Feedback — Personalized strengths and improvement areas based on actual performance
  • Performance Reports — Downloadable PDF reports with per-question breakdown, scores, and tips
  • Analytics Dashboard — Bento grid layout with performance charts, score analysis, category breakdowns, and insights
  • Session Persistence — Each interview session stored permanently in Firestore with unique IDs
  • Dashboard Stats — Real-time total interviews, average score, best score, and recent sessions
  • Authentication — Email/password + Google sign-in via Firebase Auth
  • Route Protection — Middleware-based auth guards on all protected pages
  • Mobile Responsive — Full mobile support with hamburger navigation

Tech Stack

Layer Technology
Framework Next.js 16 (App Router)
Language TypeScript
Styling Tailwind CSS 4
Auth Firebase Authentication
Database Cloud Firestore
AI Google Gemini 2.0 Flash
PDF jsPDF + html2canvas
Icons Lucide React
Deployment Vercel (free tier)

Getting Started

Prerequisites

  • Node.js 18+
  • Firebase project with Auth + Firestore enabled
  • Google AI Studio API key (free tier)

Setup

# Clone the repository
git clone https://github.com/Shriya-25/Prepwise.git
cd Prepwise

# Install dependencies
npm install

# Copy environment variables
cp .env.example .env.local
# Fill in your Firebase and Gemini API keys

# Run development server
npm run dev

Open http://localhost:3000 in your browser.

Environment Variables

See .env.example for all required variables. At minimum you need:

  • Firebase client config (6 NEXT_PUBLIC_FIREBASE_* vars)
  • GEMINI_API_KEY for AI features

Firestore Security Rules

Deploy these rules in Firebase Console → Firestore → Rules:

rules_version = '2';
service cloud.firestore {
  match /databases/{database}/documents {
    match /sessions/{sessionId} {
      allow read: if request.auth != null && resource.data.userId == request.auth.uid;
      allow create: if request.auth != null && request.resource.data.userId == request.auth.uid;
      allow update, delete: if false;
    }
  }
}

Project Structure

├── app/
│   ├── (protected)/       # Auth-required pages
│   │   ├── dashboard/     # Post-login home with stats
│   │   ├── setup/         # Interview configuration
│   │   ├── interview/     # Live interview session
│   │   ├── processing/    # AI evaluation + Firestore save
│   │   ├── feedback/      # Quick score summary
│   │   ├── report/        # Detailed per-question report
│   │   ├── analytics/     # Performance charts & history
│   │   ├── profile/       # User profile management
│   │   └── aptitude/      # Learning resources
│   ├── api/
│   │   ├── generate-questions/  # Gemini question generation
│   │   └── evaluate/            # Gemini answer evaluation
│   ├── components/
│   │   ├── site-navbar.tsx      # Global navigation
│   │   └── site-footer.tsx      # Global footer
│   ├── login/
│   ├── register/
│   └── page.tsx           # Landing page
├── lib/
│   ├── firebase.ts        # Client-side Firebase init
│   ├── firebase-admin.ts  # Server-side Firestore (optional)
│   ├── gemini.ts          # Gemini AI service
│   └── auth-session.ts    # Server-side auth helpers
├── utils/
│   └── interview-setup.ts # Shared role options
├── firestore.rules        # Firestore security rules
├── middleware.ts          # Route protection
└── .env.example

User Flow

Landing Page → Login/Register → Dashboard
  ↓
Setup Interview (choose role + company)
  ↓
AI Generates 10 Questions (HR + Technical)
  ↓
Answer Questions (timed, 2:45 each)
  ↓
Processing (AI evaluates + saves session to Firestore)
  ↓
Feedback Summary (score + badge)
  ↓
Detailed Report (per-question breakdown + PDF download)
  ↓
Dashboard & Analytics (all sessions tracked permanently)

Session Data Model

Each session stored in Firestore contains:

  • userId — Owner of the session
  • role — Target job role
  • company — Target company (optional)
  • overallScore — 0-100 score
  • scores — Per-category breakdown (HR, Technical Basics, Technical Advanced)
  • strengths — AI-generated key strengths
  • improvements — AI-generated areas to improve
  • summary — Overall performance summary
  • recommendedNextSteps — Actionable next steps
  • questions — Full Q&A with scores, feedback, and ideal answers
  • createdAt — Timestamp
  • questionsCount — Number of questions

Deployment

Deploy to Vercel with zero configuration:

npm run build  # Verify build passes
# Then connect your GitHub repo to Vercel

Set all .env.example variables in Vercel's Environment Variables settings.

License

MIT

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors