How graceliao77/interview-coach works
Interview Coach lets engineers create job-description-based mock interviews, answer by typing or voice, review transcripts, and receive separate content and ESL-focused language feedback. The primary flow runs from session creation through question generation, answer capture, optional transcription, scoring, and saved results. Authentication, API access, and persistence support that flow; the evaluation harness checks scoring behavior against labelled cases. The graph uses README and source-index evidence; some client pages and route internals were not sampled, so those connections are documented or conservatively omitted.
Main entry points: questions.ts Question and answer routes · sessions.ts Session routes · scoringService.ts Answer scoring · client.ts API client
Components 30
Interview experience
- Sign-in UI
client/src/pages/AuthForm.tsx - Auth state
client/src/context/AuthContext.tsx - Sessions
client/src/pages/Sessions.tsx - Interview workspace
client/src/pages/Interview.tsx - Question cards
client/src/pages/QuestionCard.tsx - Job description view
client/src/pages/JobDescription.tsx - Audio recorder
client/src/pages/Recorder.tsx - Recording hook
client/src/hook/useAudioRecorder.ts - API client
client/src/api/client.ts
API and access
- Auth routes
server/src/routes/auth.ts - Session routes
server/src/routes/sessions.ts - Question and answer routes
server/src/routes/questions.ts - JWT authorization
server/src/middleware/requireAuth.ts - Allowed-account guard
server/src/middleware/requireAllowed.ts - Rate limits
server/src/middleware/rateLimits.ts - Application database
server/src/lib/prisma.ts - Response mapping
server/src/lib/dto.ts
AI and scoring
- Question generation
server/src/services/questionService.ts - Answer persistence
server/src/services/answerService.ts - Audio transcription
server/src/services/transcriptionService.ts - Answer scoring
server/src/services/scoringService.ts - Score validation
server/src/schemas/scoring.ts - ESL error patterns
shared/errorPatterns.ts
Scoring evaluation
- Evaluation runner
server/eval/runEval.ts - Case grading
server/eval/grade.ts - Run aggregation
server/eval/aggregate.ts - Evaluation reports
server/eval/report.ts
Other components
- Candidate
- Anthropic Claude
- Groq Whisper
Connections 39
- Candidate → Sign-in UI: signs in
- Sign-in UI → Auth state: submits credentials
client/src/context/AuthContext.tsx - Auth state → API client: calls API
client/src/context/AuthContext.tsx - Sessions → API client: loads sessions
client/src/pages/Sessions.tsx - Candidate → Sessions: creates session
client/src/pages/Sessions.tsx - Sessions → Interview workspace: opens practice
client/src/pages/Sessions.tsx - Interview workspace → Question cards: renders questions
client/src/pages/Interview.tsx - Interview workspace → Job description view: shows job details
client/src/pages/Interview.tsx - Candidate → Audio recorder: records answer
README.md - Audio recorder → Recording hook: uses recorder
- Interview workspace → API client: sends answers
client/src/pages/Interview.tsx - API client → Question and answer routes: HTTP requests
README.md - API client → Session routes: HTTP requests
README.md - Auth routes → Application database: reads and writes
server/src/routes/auth.ts - Session routes → JWT authorization: requires JWT
server/src/routes/sessions.ts - Question and answer routes → JWT authorization: requires JWT
server/src/routes/questions.ts - Session routes → Allowed-account guard: guards generation
server/src/routes/sessions.ts - Question and answer routes → Allowed-account guard: guards AI actions
server/src/routes/questions.ts - Session routes → Rate limits: limits generation
server/src/routes/sessions.ts - Question and answer routes → Rate limits: limits AI actions
server/src/routes/questions.ts - Session routes → Application database: reads and writes
server/src/routes/sessions.ts - Session routes → Response mapping: maps responses
server/src/routes/sessions.ts - Session routes → Question generation: requests questions
server/src/routes/sessions.ts - Question and answer routes → Question generation: dispatches generation
server/src/routes/questions.ts - Question and answer routes → Audio transcription: dispatches transcription
server/src/routes/questions.ts - Question and answer routes → Answer scoring: dispatches scoring
server/src/routes/questions.ts - Question and answer routes → Answer persistence: persists answer
server/src/routes/questions.ts - Question generation → Anthropic Claude: generates questions
server/src/services/questionService.ts - Audio transcription → Groq Whisper: transcribes audio
server/src/services/transcriptionService.ts - Answer scoring → Anthropic Claude: scores transcript
server/src/services/scoringService.ts - Answer scoring → Score validation: normalizes output
server/src/services/scoringService.ts - Answer scoring → ESL error patterns: uses pattern catalog
server/src/services/scoringService.ts - Answer persistence → Application database: stores attempt
server/src/services/answerService.ts - Evaluation runner → Answer scoring: scores cases
server/eval/runEval.ts - Evaluation runner → Case grading: grades results
server/eval/runEval.ts - Evaluation runner → Run aggregation: aggregates runs
server/eval/runEval.ts - Evaluation runner → Evaluation reports: formats summaries
server/eval/runEval.ts - Case grading → Score validation: checks score report
server/eval/grade.ts - Run aggregation → Evaluation reports: summarizes runs
server/eval/aggregate.ts