# guianmedallion17-web/updated-study-quest architecture

> Architecture diagram of the GitHub repository guianmedallion17-web/updated-study-quest, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-16). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/guianmedallion17-web/updated-study-quest
- Repository: https://github.com/guianmedallion17-web/updated-study-quest

## Overview

StudyQuest appears to be a study website with serverless AI-generation endpoints: students can request lesson quizzes, arena flashcards, and mood-aware motivation. Each endpoint validates its request, builds a prompt, calls Gemini, and returns generated content. The README only names the project, and index.html was not sampled, so the browser workflow and endpoint wiring are uncertain; student-to-endpoint links are therefore unverified. The Gemini calls and response handling are visible in the endpoint source files.

Main entry points: [`api/generate-quiz.js`](https://github.com/guianmedallion17-web/updated-study-quest/blob/main/api/generate-quiz.js) (Lesson quiz), [`api/generate-arena-cards.js`](https://github.com/guianmedallion17-web/updated-study-quest/blob/main/api/generate-arena-cards.js) (Arena cards), [`api/generate-motivation.js`](https://github.com/guianmedallion17-web/updated-study-quest/blob/main/api/generate-motivation.js) (Motivation)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_study["Study content"]
  node_lesson_quiz["Lesson quiz<br/>[generate-quiz.js]"]
  node_arena_cards["Arena cards"]
end

subgraph group_support["Student support"]
  node_motivation["Motivation"]
end

node_student(("Student"))
node_gemini{{"Gemini API"}}

node_student -.->|"requests quiz"| node_lesson_quiz
node_student -.->|"requests cards"| node_arena_cards
node_student -.->|"requests support"| node_motivation
node_lesson_quiz -->|"generates quiz"| node_gemini
node_arena_cards -->|"generates cards"| node_gemini
node_motivation -->|"generates message"| node_gemini

click node_lesson_quiz "https://github.com/guianmedallion17-web/updated-study-quest/blob/main/api/generate-quiz.js"
click node_arena_cards "https://github.com/guianmedallion17-web/updated-study-quest/blob/main/api/generate-arena-cards.js"
click node_motivation "https://github.com/guianmedallion17-web/updated-study-quest/blob/main/api/generate-motivation.js"

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_lesson_quiz,node_arena_cards toneBlue
class node_motivation toneAmber
class node_student toneIndigo
class node_gemini toneMint
```

## Components

### Study content

- [Lesson quiz](https://github.com/guianmedallion17-web/updated-study-quest/blob/main/api/generate-quiz.js): `api/generate-quiz.js`
- [Arena cards](https://github.com/guianmedallion17-web/updated-study-quest/blob/main/api/generate-arena-cards.js): `api/generate-arena-cards.js`

### Student support

- [Motivation](https://github.com/guianmedallion17-web/updated-study-quest/blob/main/api/generate-motivation.js): `api/generate-motivation.js`

### Other components

- **Student**
- **Gemini API**

## Connections

- Student → Lesson quiz: requests quiz
- Student → Arena cards: requests cards
- Student → Motivation: requests support
- Lesson quiz → Gemini API: generates quiz (evidence: `api/generate-quiz.js`)
- Arena cards → Gemini API: generates cards (evidence: `api/generate-arena-cards.js`)
- Motivation → Gemini API: generates message (evidence: `api/generate-motivation.js`)
