InterviewAI / src /types /interview.ts
viraj-421's picture
Initial commit: AI-Powered Mock Interview Platform with Auth, Certificates, and Timer
a0da743
Raw History Blame Contribute Delete
1.65 kB
export interface InterviewRole {
id: string;
title: string;
icon: string;
description: string;
color: string;
gradient: string;
topics: string[];
}
export interface InterviewConfig {
role: InterviewRole;
difficulty: 'beginner' | 'intermediate' | 'advanced';
questionCount: number;
timeLimit: number; // in minutes, 0 = unlimited
}
export interface Question {
id: number;
text: string;
category: string;
difficulty: string;
}
export interface Answer {
questionId: number;
text: string;
timestamp: number;
}
export interface Evaluation {
questionId: number;
score: number; // 0-10
relevance: number; // 0-10
clarity: number; // 0-10
technicalAccuracy: number; // 0-10
confidence: number; // 0-10
strengths: string[];
weaknesses: string[];
suggestions: string[];
sampleAnswer: string;
}
export interface ChatMessage {
id: string;
role: 'ai' | 'user';
content: string;
timestamp: number;
questionId?: number;
evaluation?: Evaluation;
}
export interface SessionSummary {
totalScore: number;
averageScore: number;
totalQuestions: number;
answeredQuestions: number;
strengths: string[];
weaknesses: string[];
recommendations: string[];
categoryScores: { category: string; score: number }[];
overallFeedback: string;
}
export interface InterviewSession {
id: string;
config: InterviewConfig;
questions: Question[];
answers: Answer[];
evaluations: Evaluation[];
messages: ChatMessage[];
currentQuestionIndex: number;
status: 'setup' | 'in-progress' | 'evaluating' | 'completed';
startedAt: number;
completedAt?: number;
summary?: SessionSummary;
}