# sandeepgarikapati/ai-interview-coach architecture

> Architecture diagram of the GitHub repository sandeepgarikapati/ai-interview-coach, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-06). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/sandeepgarikapati/ai-interview-coach
- Repository: https://github.com/sandeepgarikapati/ai-interview-coach

## Overview

IPSUM is a mock-interview practice app. Users enter a target role, tech stack, and experience; the app generates and saves questions, presents the interview, records answers for AI evaluation, and displays feedback. The graph also preserves the documented practice-question, plan, and progress-tracking capabilities. Source excerpts show question generation and feedback reads; several interview, answer, and practice details are supported only by README statements or the source index, so uncertain links are omitted or marked unverified.

Main entry points: [`app/dashboard/_components/AddNewInterview.jsx`](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/_components/AddNewInterview.jsx) (Interview creation), [`utils/db.js`](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/utils/db.js) (Database client), [`app/dashboard/page.jsx`](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/page.jsx) (Interview dashboard), [`app/dashboard/_components/InterviewList.jsx`](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/_components/InterviewList.jsx) (Interview history)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_interview_setup["Interview setup"]
  node_dashboard["Interview dashboard<br/>[page.jsx]"]
  node_create_interview["Interview creation"]
  node_interview_list["Interview history<br/>[InterviewList.jsx]"]
  node_interview_cards["Interview cards"]
  node_interview_brief["Interview briefing<br/>[page.jsx]"]
end

subgraph group_practice_feedback["Practice and feedback"]
  node_question_session["Question session<br/>[page.jsx]"]
  node_question_list["Question display<br/>[QuestionsList.jsx]"]
  node_answer_capture["Answer capture"]
  node_feedback_report["Feedback report<br/>[page.jsx]"]
  node_practice_questions["Practice questions<br/>[page.jsx]"]
end

subgraph group_data_ai["AI and data"]
  node_gemini{{"Gemini question and feedback AI<br/>[Geminimodel.js]"}}
  node_database_client["Database client<br/>[db.js]"]
  node_interview_store[("Interview and answer records<br/>[schema.js]")]
end

subgraph group_account_plans["Account and plans"]
  node_sign_in["Sign in<br/>[page.jsx]"]
  node_sign_up["Sign up<br/>[page.jsx]"]
  node_site_header["Dashboard header<br/>[Header.jsx]"]
  node_upgrade["Plan selection<br/>[page.jsx]"]
  node_plan_data["Plan definitions<br/>[planData.js]"]
  node_plan_card["Plan card<br/>[PlanItemCard.jsx]"]
end

subgraph group_ui["Interface primitives"]
  node_ui_dialog["Dialog primitive<br/>[dialog.jsx]"]
  node_ui_button["Button primitive<br/>[button.jsx]"]
  node_ui_input["Input primitive<br/>[input.jsx]"]
  node_ui_textarea["Textarea primitive<br/>[textarea.jsx]"]
  node_ui_toast["Toast primitive<br/>[sonner.jsx]"]
end

node_candidate(("Candidate"))
node_neon[("Neon database")]

node_candidate -->|"opens"| node_dashboard
node_dashboard -->|"renders"| node_create_interview
node_dashboard -->|"renders"| node_interview_list
node_create_interview -->|"requests questions"| node_gemini
node_create_interview -->|"saves interview"| node_database_client
node_create_interview -->|"routes to"| node_interview_brief
node_interview_list -->|"loads history"| node_database_client
node_interview_list -->|"renders"| node_interview_cards
node_interview_brief -->|"loads interview"| node_database_client
node_interview_brief -->|"starts session"| node_question_session
node_question_session -->|"renders"| node_question_list
node_question_session -->|"renders"| node_answer_capture
node_answer_capture -->|"evaluates answer"| node_gemini
node_answer_capture -->|"saves answer"| node_database_client
node_feedback_report -->|"loads feedback"| node_database_client
node_candidate -->|"practices questions"| node_practice_questions
node_practice_questions -.->|"generates questions"| node_gemini
node_dashboard -->|"shows header"| node_site_header
node_upgrade -->|"reads plans"| node_plan_data
node_upgrade -->|"renders"| node_plan_card
node_database_client -->|"uses schema"| node_interview_store
node_database_client -->|"connects to"| node_neon
node_create_interview -->|"uses"| node_ui_dialog
node_create_interview -->|"uses"| node_ui_button
node_create_interview -->|"uses"| node_ui_input
node_create_interview -->|"uses"| node_ui_textarea

click node_dashboard "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/page.jsx"
click node_create_interview "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/_components/AddNewInterview.jsx"
click node_interview_list "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/_components/InterviewList.jsx"
click node_interview_cards "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/_components/InterviewcardList.jsx"
click node_interview_brief "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/interview/%5Binterviewid%5D/page.jsx"
click node_question_session "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/interview/%5Binterviewid%5D/start/page.jsx"
click node_question_list "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/interview/%5Binterviewid%5D/start/_components/QuestionsList.jsx"
click node_answer_capture "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/interview/%5Binterviewid%5D/start/_components/RecordAnswerSection.jsx"
click node_feedback_report "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/interview/%5Binterviewid%5D/feedback/page.jsx"
click node_practice_questions "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/questions/page.jsx"
click node_gemini "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/utils/Geminimodel.js"
click node_database_client "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/utils/db.js"
click node_interview_store "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/utils/schema.js"
click node_sign_in "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/(auth)/sign-in/%5B%5B...sign-in%5D%5D/page.jsx"
click node_sign_up "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/(auth)/sign-up/%5B%5B...sign-up%5D%5D/page.jsx"
click node_site_header "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/_components/Header.jsx"
click node_upgrade "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/upgrade/page.jsx"
click node_plan_data "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/utils/planData.js"
click node_plan_card "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/upgrade/_components/PlanItemCard.jsx"
click node_ui_dialog "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/components/ui/dialog.jsx"
click node_ui_button "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/components/ui/button.jsx"
click node_ui_input "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/components/ui/input.jsx"
click node_ui_textarea "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/components/ui/textarea.jsx"
click node_ui_toast "https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/components/ui/sonner.jsx"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_dashboard,node_create_interview,node_interview_list,node_interview_cards,node_interview_brief toneBlue
class node_question_session,node_question_list,node_answer_capture,node_feedback_report,node_practice_questions,node_neon toneAmber
class node_gemini,node_database_client,node_interview_store toneMint
class node_sign_in,node_sign_up,node_site_header,node_upgrade,node_plan_data,node_plan_card toneRose
class node_ui_dialog,node_ui_button,node_ui_input,node_ui_textarea,node_ui_toast,node_candidate toneIndigo
```

## Components

### Interview setup

- [Interview dashboard](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/page.jsx): `app/dashboard/page.jsx`
- [Interview creation](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/_components/AddNewInterview.jsx): `app/dashboard/_components/AddNewInterview.jsx`
- [Interview history](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/_components/InterviewList.jsx): `app/dashboard/_components/InterviewList.jsx`
- [Interview cards](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/_components/InterviewcardList.jsx): `app/dashboard/_components/InterviewcardList.jsx`
- [Interview briefing](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/interview/%5Binterviewid%5D/page.jsx): `app/dashboard/interview/[interviewid]/page.jsx`

### Practice and feedback

- [Question session](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/interview/%5Binterviewid%5D/start/page.jsx): `app/dashboard/interview/[interviewid]/start/page.jsx`
- [Question display](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/interview/%5Binterviewid%5D/start/_components/QuestionsList.jsx): `app/dashboard/interview/[interviewid]/start/_components/QuestionsList.jsx`
- [Answer capture](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/interview/%5Binterviewid%5D/start/_components/RecordAnswerSection.jsx): `app/dashboard/interview/[interviewid]/start/_components/RecordAnswerSection.jsx`
- [Feedback report](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/interview/%5Binterviewid%5D/feedback/page.jsx): `app/dashboard/interview/[interviewid]/feedback/page.jsx`
- [Practice questions](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/questions/page.jsx): `app/dashboard/questions/page.jsx`

### AI and data

- [Gemini question and feedback AI](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/utils/Geminimodel.js): `utils/Geminimodel.js`
- [Database client](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/utils/db.js): `utils/db.js`
- [Interview and answer records](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/utils/schema.js): `utils/schema.js`

### Account and plans

- [Sign in](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/(auth)/sign-in/%5B%5B...sign-in%5D%5D/page.jsx): `app/(auth)/sign-in/[[...sign-in]]/page.jsx`
- [Sign up](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/(auth)/sign-up/%5B%5B...sign-up%5D%5D/page.jsx): `app/(auth)/sign-up/[[...sign-up]]/page.jsx`
- [Dashboard header](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/_components/Header.jsx): `app/dashboard/_components/Header.jsx`
- [Plan selection](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/upgrade/page.jsx): `app/dashboard/upgrade/page.jsx`
- [Plan definitions](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/utils/planData.js): `utils/planData.js`
- [Plan card](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/app/dashboard/upgrade/_components/PlanItemCard.jsx): `app/dashboard/upgrade/_components/PlanItemCard.jsx`

### Interface primitives

- [Dialog primitive](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/components/ui/dialog.jsx): `components/ui/dialog.jsx`
- [Button primitive](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/components/ui/button.jsx): `components/ui/button.jsx`
- [Input primitive](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/components/ui/input.jsx): `components/ui/input.jsx`
- [Textarea primitive](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/components/ui/textarea.jsx): `components/ui/textarea.jsx`
- [Toast primitive](https://github.com/sandeepgarikapati/ai-interview-coach/blob/main/components/ui/sonner.jsx): `components/ui/sonner.jsx`

### Other components

- **Candidate**
- **Neon database**

## Connections

- Candidate → Interview dashboard: opens (evidence: `README.md`)
- Interview dashboard → Interview creation: renders (evidence: `app/dashboard/page.jsx`)
- Interview dashboard → Interview history: renders (evidence: `app/dashboard/page.jsx`)
- Interview creation → Gemini question and feedback AI: requests questions (evidence: `app/dashboard/_components/AddNewInterview.jsx`)
- Interview creation → Database client: saves interview (evidence: `app/dashboard/_components/AddNewInterview.jsx`)
- Interview creation → Interview briefing: routes to (evidence: `app/dashboard/_components/AddNewInterview.jsx`)
- Interview history → Database client: loads history (evidence: `app/dashboard/_components/InterviewList.jsx`)
- Interview history → Interview cards: renders (evidence: `app/dashboard/_components/InterviewList.jsx`)
- Interview briefing → Database client: loads interview (evidence: `app/dashboard/interview/[interviewid]/page.jsx`)
- Interview briefing → Question session: starts session (evidence: `README.md`)
- Question session → Question display: renders (evidence: `app/dashboard/interview/[interviewid]/start/page.jsx`)
- Question session → Answer capture: renders (evidence: `app/dashboard/interview/[interviewid]/start/page.jsx`)
- Answer capture → Gemini question and feedback AI: evaluates answer (evidence: `app/dashboard/interview/[interviewid]/start/_components/RecordAnswerSection.jsx`)
- Answer capture → Database client: saves answer (evidence: `app/dashboard/interview/[interviewid]/start/_components/RecordAnswerSection.jsx`)
- Feedback report → Database client: loads feedback (evidence: `app/dashboard/interview/[interviewid]/feedback/page.jsx`)
- Candidate → Practice questions: practices questions (evidence: `README.md`)
- Practice questions → Gemini question and feedback AI: generates questions
- Interview dashboard → Dashboard header: shows header
- Plan selection → Plan definitions: reads plans (evidence: `app/dashboard/upgrade/page.jsx`)
- Plan selection → Plan card: renders (evidence: `app/dashboard/upgrade/page.jsx`)
- Database client → Interview and answer records: uses schema (evidence: `utils/db.js`)
- Database client → Neon database: connects to (evidence: `README.md`)
- Interview creation → Dialog primitive: uses (evidence: `app/dashboard/_components/AddNewInterview.jsx`)
- Interview creation → Button primitive: uses (evidence: `app/dashboard/_components/AddNewInterview.jsx`)
- Interview creation → Input primitive: uses (evidence: `app/dashboard/_components/AddNewInterview.jsx`)
- Interview creation → Textarea primitive: uses (evidence: `app/dashboard/_components/AddNewInterview.jsx`)
