Skip to content

mp0549/ClaudeHacks-interview-prep-platform

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Interview Preparation Platform

An AI-powered interview preparation platform that generates personalized interview questions based on your resume and job description, then provides detailed feedback on your performance.

Features

  • Personalized Question Generation: Uses Claude AI to generate relevant interview questions based on your resume and the target job description
  • Interactive Interview Interface: Clean, user-friendly interface to practice answering questions
  • Comprehensive Grading: Receive detailed feedback on each answer including:
    • Overall score (0-100)
    • Question-by-question analysis
    • Identified strengths
    • Areas for improvement
  • Data Persistence: All interview sessions and answers are saved to a database

Tech Stack

  • Frontend: Vanilla HTML, CSS, JavaScript
  • Backend: Python Flask
  • Database: SQLite (via SQLAlchemy)
  • AI: Claude API (Anthropic)

Project Structure

claude_hacks/
├── backend/
│   ├── app.py              # Flask application and API endpoints
│   ├── models.py           # Database models
│   └── claude_service.py   # Claude API integration
├── frontend/
│   ├── index.html          # Main HTML file
│   ├── styles.css          # Styling
│   └── app.js              # Frontend logic
├── requirements.txt        # Python dependencies
├── .env.example           # Environment variables template
├── .gitignore            # Git ignore rules
└── README.md             # This file

Setup Instructions

Prerequisites

  • Python 3.8 or higher
  • Claude API key from Anthropic

1. Clone or Navigate to the Project

cd /Users/akhilivaturi/dev/claude_hacks

2. Set Up Environment Variables

Create a .env file in the root directory:

cp .env.example .env

Edit .env and add your API key:

ANTHROPIC_API_KEY=your_actual_api_key_here
FLASK_SECRET_KEY=your_random_secret_key
DATABASE_URL=sqlite:///interview_prep.db

3. Create Virtual Environment (Recommended)

python -m venv venv

# On macOS/Linux:
source venv/bin/activate

# On Windows:
venv\Scripts\activate

4. Install Python Dependencies

pip install -r requirements.txt

5. Run the Backend Server

cd backend
python app.py

The backend will start on http://localhost:5000

6. Open the Frontend

In a new terminal, serve the frontend (you can use Python's built-in HTTP server):

cd frontend
python -m http.server 8000

Then open your browser and navigate to:

http://localhost:8000

Usage Guide

Step 1: Enter Your Information

  1. Paste your resume in the "Your Resume" field
  2. Paste the target job description in the "Job Description" field
  3. Select the number of questions you want (3, 5, 7, or 10)
  4. Click "Generate Interview Questions"

The AI will analyze your resume and the job description to create personalized questions.

Step 2: Answer Questions

  1. Read each question carefully
  2. Type your answer in the text area
  3. Click "Save & Next" to move to the next question
  4. Use "Previous" if you want to review or edit earlier answers
  5. Click "Submit Interview" after answering all questions

Step 3: Review Results

You'll receive:

  • An overall score out of 100
  • Detailed feedback on each answer
  • Your identified strengths
  • Specific areas for improvement

Click "Start New Interview" to practice again!

API Endpoints

GET /api/health

Health check endpoint

POST /api/start-interview

Create a new interview session and generate questions

Request Body:

{
  "resume": "Your resume text...",
  "job_description": "Job description text...",
  "num_questions": 5
}

GET /api/interview/<session_id>

Get interview session details

POST /api/answer

Submit an answer for a question

Request Body:

{
  "session_id": 1,
  "question_index": 0,
  "question": "Question text",
  "answer": "Your answer"
}

POST /api/complete-interview

Complete the interview and get grading

Request Body:

{
  "session_id": 1
}

Database Schema

InterviewSession

  • id: Primary key
  • resume: User's resume text
  • job_description: Target job description
  • questions_json: Generated questions (stored as JSON)
  • status: Session status (active/completed)
  • grade: Overall score
  • feedback: Detailed feedback (stored as JSON)
  • created_at: Timestamp

Answer

  • id: Primary key
  • session_id: Foreign key to InterviewSession
  • question_index: Question number
  • question: Question text
  • answer: User's answer
  • created_at: Timestamp

Troubleshooting

Backend Won't Start

  • Make sure you've installed all dependencies: pip install -r requirements.txt
  • Check that your .env file exists and has a valid ANTHROPIC_API_KEY
  • Ensure port 5000 is not already in use

Frontend Can't Connect to Backend

  • Verify the backend is running on http://localhost:5000
  • Check browser console for CORS errors
  • Ensure flask-cors is installed

Questions Not Generating

  • Verify your Claude API key is valid
  • Check backend logs for error messages
  • Ensure you have sufficient API credits

Database Errors

  • The database is created automatically on first run
  • If you encounter issues, delete interview_prep.db and restart the backend

Future Enhancements

  • User authentication and profile management
  • Interview history and progress tracking
  • Mock video interviews with speech recognition
  • Company-specific interview prep
  • Practice with common algorithms and coding problems
  • Export results as PDF

License

MIT License

Support

For issues or questions, please create an issue in the repository.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors