An AI-powered, personalized interview trainer that uses Google Gemini, RAG, and LangGraph to deliver adaptive interview experiences.
InterviewAI is a full-stack web application that helps candidates prepare for technical and behavioral interviews.
The application:
- Extracts candidate information from uploaded resumes
- Builds a personalized candidate profile
- Generates role- and skill-specific interview questions
- Uses Google Gemini for AI-powered profile extraction, question generation, and answer evaluation
- Uses a RAG (Retrieval-Augmented Generation) pipeline to provide role-specific knowledge and context
- Uses LangGraph to orchestrate the adaptive interview workflow
- Adjusts interview difficulty based on the candidate's performance
- Generates a final interview report with scores, feedback, and skill-gap insights
- Provides a dashboard for viewing interview statistics
User
โ
Upload Resume / Enter Profile
โ
Profile Extraction
โ
Interview Configuration
โ
RAG Context Retrieval
โ
Gemini Question Generation
โ
Candidate Answer
โ
Gemini Answer Evaluation
โ
Adaptive Next Question
โ
Final Report + Skill Gap Analysis
graph TD
subgraph Frontend["Frontend - Next.js"]
LP[Landing Page]
UP[Upload / Profile]
CP[Configure Interview]
IP[Interview Page]
RP[Report Page]
DB[Dashboard]
end
subgraph Backend["Backend - FastAPI"]
API[API Routes]
RS[Resume Service]
GS[Gemini Service]
RAG[RAG Service]
ES[Evaluation Service]
AG[LangGraph Agent]
DB2[(SQLite / PostgreSQL)]
KB[Knowledge Base]
end
subgraph External["External AI Service"]
GEM[Google Gemini API]
end
LP --> UP
UP --> CP
CP --> IP
IP --> RP
DB --> API
IP --> API
API --> RS
API --> AG
AG --> GS
AG --> RAG
AG --> ES
GS --> GEM
RAG --> KB
ES --> GS
AG --> DB2
- Frontend: Next.js application with TypeScript and Tailwind CSS
- Backend: FastAPI REST API
- AI: Google Gemini through the
google-genaiSDK - Agent orchestration: LangGraph
- RAG: Knowledge-base retrieval from the project's curated interview material
- Resume processing: PyMuPDF
- Database: SQLite locally, PostgreSQL supported for production
- Deployment: Vercel
| Layer | Technology |
|---|---|
| Frontend | Next.js 14, React 18, TypeScript, Tailwind CSS |
| Backend | Python, FastAPI |
| AI / LLM | Google Gemini (gemini-2.5-flash) |
| AI SDK | Google Gen AI SDK (google-genai) |
| Agent | LangGraph (StateGraph) |
| RAG | LangChain text splitters + project knowledge base |
| Resume Parser | PyMuPDF (fitz) |
| Database | SQLite + SQLAlchemy ORM / PostgreSQL |
| Charts | Recharts |
| Deployment | Vercel |
Google Gemini is the current AI provider used by InterviewAI.
Gemini powers the main AI capabilities:
- Profile Extraction โ Converts resume text into a structured candidate profile
- Question Generation โ Generates role-specific and difficulty-aware interview questions
- Answer Evaluation โ Evaluates candidate answers and provides structured feedback
- Interview Intelligence โ Supports the adaptive interview flow and final performance analysis
The application supports:
| Mode | AI_PROVIDER |
Description |
|---|---|---|
| Gemini | gemini |
AI-powered mode using Google Gemini |
| Mock | mock |
Offline/development mode without an external AI API |
Create a .env file in the project root:
AI_PROVIDER=gemini
GEMINI_API_KEY=your_gemini_api_key_here
GEMINI_MODEL=gemini-2.5-flash
DATABASE_URL=sqlite:///./interview_ai.db
CHROMA_PERSIST_DIR=./chroma_db
FRONTEND_URL=http://localhost:3000
BACKEND_URL=http://localhost:8000Security: Never commit your real
GEMINI_API_KEYto GitHub. Keep it in.envlocally and configure it as an environment variable in Vercel for deployment.
InterviewAI uses Retrieval-Augmented Generation to ground interview generation and evaluation with relevant interview knowledge.
The knowledge base is stored under:
backend/data/
It contains curated material related to areas such as:
- Python
- Machine Learning
- Data Science
- Software Engineering
- OOP
- DSA
- SQL
- Deep Learning
- NLP
- Generative AI
- RAG
- System Design
- DevOps
- HR and Behavioral Interviews
- STAR-based interview preparation
Knowledge Base Documents
โ
Text Splitting
โ
Relevant Context Retrieval
โ
Interview Context
โ
Gemini
โ
Question / Evaluation / Feedback
The current implementation is intentionally lightweight so that the application can be deployed without the large ML/vector-database dependencies that caused oversized serverless bundles.
The interview agent uses LangGraph to coordinate the adaptive interview process.
graph LR
A[Load Candidate Profile]
--> B[Retrieve Relevant Context]
B --> C[Generate Interview Question]
C --> D[Candidate Answers]
D --> E[Evaluate Answer]
E --> F{Interview Complete?}
F -->|No| G[Update Interview State]
G --> B
F -->|Yes| H[Generate Final Report]
The interview can adapt its difficulty based on the candidate's evaluation score:
- Score โฅ 8/10 โ Increase difficulty
- Score 5โ7/10 โ Maintain difficulty
- Score โค 4/10 โ Decrease difficulty
The agent also keeps track of previous questions and interview state to reduce unnecessary repetition.
Candidates can upload a PDF resume.
The backend uses PyMuPDF to:
- Read the uploaded PDF
- Extract text
- Send relevant text to the AI profile extraction pipeline
- Build a structured candidate profile
- Use the profile for personalized interview generation
The application also supports manual profile creation.
Install:
- Python 3.10+
- Node.js 18+
- npm
- Git
If the repository contains run_app.bat, you can start the application using:
run_app.batThis starts the backend and frontend development servers.
The application is available at:
http://localhost:3000
Backend API:
http://localhost:8000
Backend health check:
http://localhost:8000/api/health
git clone <your-repository-url>
cd interview-aiCopy the example environment file:
cp .env.example .envThen add your Gemini API key:
AI_PROVIDER=gemini
GEMINI_API_KEY=your_gemini_api_key_here
GEMINI_MODEL=gemini-2.5-flash
DATABASE_URL=sqlite:///./interview_ai.db
FRONTEND_URL=http://localhost:3000
BACKEND_URL=http://localhost:8000From the project root:
cd backend
python -m venv venvvenv\Scripts\activatesource venv/bin/activateInstall dependencies:
pip install -r requirements.txtcd backend
python -m uvicorn main:app --host 127.0.0.1 --port 8000The API will run at:
http://localhost:8000
Open another terminal:
cd frontend
npm install
npm run devThe frontend will run at:
http://localhost:3000
Before starting an interview, verify that the backend is running:
curl http://127.0.0.1:8000/api/healthExpected response:
{
"status": "ok"
}If the frontend displays:
Failed to start interview
check that the FastAPI backend is running on port 8000 and inspect the backend terminal for the actual error.
InterviewAI is structured as a full-stack monorepo for Vercel deployment.
- Frontend: Next.js application under
frontend/ - Backend: FastAPI application under
backend/ - Routing: Root
vercel.jsonroutes/api/*requests to the backend service and other requests to the frontend
- Push the project to GitHub.
- Import the repository into Vercel.
- Keep the repository root as the project root.
- Vercel uses the root
vercel.jsonconfiguration. - Add the required environment variables.
- Deploy.
Configure:
AI_PROVIDER=gemini
GEMINI_API_KEY=<your Gemini API key>
GEMINI_MODEL=gemini-2.5-flash
DATABASE_URL=<production PostgreSQL connection string>
FRONTEND_URL=<your Vercel frontend URL>
BACKEND_URL=<your Vercel backend URL>
Do not commit real API keys.
SQLite is suitable for local development.
For production/serverless deployment, use a managed PostgreSQL database because the Vercel serverless filesystem is not persistent.
Examples include:
- Neon
- Supabase
- Other managed PostgreSQL providers
The backend has been kept lightweight to reduce Vercel function bundle size.
Avoid committing or bundling generated runtime data such as:
backend/chroma_db/
*.db
*.sqlite
__pycache__/
venv/
venv2/
node_modules/
.next/
| Variable | Required | Description |
|---|---|---|
AI_PROVIDER |
Yes | gemini or mock |
GEMINI_API_KEY |
For Gemini | Google Gemini API key |
GEMINI_MODEL |
No | Gemini model, default: gemini-2.5-flash |
DATABASE_URL |
No | SQLite or PostgreSQL connection string |
CHROMA_PERSIST_DIR |
No | Local Chroma/runtime storage path if used by the environment |
FRONTEND_URL |
No | Frontend URL used by the backend |
BACKEND_URL |
No | Backend URL |
| Endpoint | Method | Description |
|---|---|---|
/api/health |
GET | Backend and AI provider health check |
/api/resume/upload |
POST | Upload a PDF resume |
/api/profile/extract |
POST | Extract candidate profile from resume text |
/api/profile/manual |
POST | Create a profile manually |
/api/interview/create |
POST | Start a new interview |
/api/interview/answer |
POST | Submit and evaluate an answer |
/api/interview/next |
POST | Get the next interview question |
/api/interview/finish |
POST | Complete the interview and generate the report |
/api/interview/{id} |
GET | Get interview status |
/api/report/{id} |
GET | Get interview report |
/api/dashboard/stats |
GET | Get dashboard statistics |
The landing page includes a Try Demo flow for quickly demonstrating the application.
The demo can start with a pre-configured candidate profile instead of requiring an immediate resume upload.
Example profile:
Name: Alex Sharma
Role: ML Engineer
Skills: Python, Machine Learning, Deep Learning, RAG, NLP
Experience: Fresher
This makes it possible to demonstrate the complete interview workflow quickly.
Introduces InterviewAI and provides the option to start an interview or try the demo.
The candidate can:
- Upload a resume
- Extract a profile automatically
- Enter profile information manually
The candidate configures the interview, including the desired interview mode and difficulty.
The AI:
- Generates questions
- Evaluates answers
- Provides feedback
- Adapts subsequent questions based on performance
After completion, the application provides an interview performance summary.
The dashboard provides an overview of interview activity and performance statistics.
interview-ai/
โ
โโโ frontend/
โ โโโ app/
โ โ โโโ page.tsx # Landing page
โ โ โโโ upload/ # Resume upload
โ โ โโโ configure/ # Interview configuration
โ โ โโโ interview/[id]/ # Interview UI
โ โ โโโ report/[id]/ # Report page
โ โ โโโ dashboard/ # Dashboard
โ โ
โ โโโ components/ # Reusable UI components
โ โโโ lib/
โ โ โโโ api.ts # API client
โ โโโ types/
โ โ โโโ index.ts # TypeScript types
โ โโโ package.json
โ
โโโ backend/
โ โโโ main.py # FastAPI entry point
โ โโโ config.py # Application configuration
โ โโโ api/ # API route handlers
โ โโโ agents/ # LangGraph interview agent
โ โโโ services/
โ โ โโโ gemini_service.py # Google Gemini integration
โ โ โโโ rag_service.py # RAG pipeline
โ โ โโโ resume_service.py # Resume parsing
โ โ โโโ evaluation_service.py # Answer evaluation
โ โโโ models/ # SQLAlchemy models
โ โโโ schemas/ # Pydantic schemas
โ โโโ database/ # Database configuration
โ โโโ data/ # Interview knowledge base
โ โโโ scripts/ # Utility scripts
โ โโโ tests/ # Backend tests
โ โโโ requirements.txt
โ
โโโ sample_resumes/ # Sample PDF resumes
โโโ scripts/ # Project utility scripts
โโโ .env.example # Environment variable template
โโโ .gitignore
โโโ docker-compose.yml
โโโ run_app.bat
โโโ vercel.json
โโโ README.md
- Never commit API keys or other secrets.
- Store local secrets in
.env. - Add production secrets through Vercel Environment Variables.
- Keep
.envexcluded through.gitignore. - Do not place secrets directly inside Python or TypeScript source files.
- Voice-based interview mode
- Advanced analytics and trend visualization
- Multi-language support
- Company-specific question databases
- Interview recording and playback
- Peer comparison metrics
- Integration with job portals
- Mobile-responsive PWA
- Collaborative interview practice
- Custom knowledge base uploads
- More advanced personalized RAG retrieval
- Interview history and long-term candidate progress tracking
A recommended 3โ5 minute demonstration:
- Open the landing page
- Click "Try Demo"
- Configure the interview
- Answer the first question with a strong answer
- Show the AI evaluation and feedback
- Give a weaker answer to demonstrate adaptive behavior
- Show the next question and changed difficulty
- Complete the interview
- Show the final report
- Show the dashboard and interview statistics
- Personalized interview generation
- Google Gemini AI integration
- RAG-based contextual interview questions
- LangGraph agentic workflow
- Adaptive interview difficulty
- Resume-based candidate profiling
- Real-time answer evaluation
- Final performance report
- Full-stack deployment architecture
Built for the AICTE 2026 Innovation Challenge.
Educational and demonstration use.