Database / Persistence Model
This diagram documents the entities used if persistence is ever added. For the ephemeral MVP these exist only in-memory on the backend.
Clarifications​
- A round corresponds to one
WINE. Thecurrent_roundfield onSESSIONis the index of the wine currently being played. - Each
WINEalways has exactly 4QUESTIONrows, one per fixed category:color,country,grape_variety,vintage_year. - Each
QUESTIONalways has exactly 4ANSWER_OPTIONrows (1 correct, 3 distractors). Options are stored and delivered in the order the host entered them — no per-player shuffling. PARTICIPANT.scoreis the running cumulative total (incremented by 100 per correct answer).RESPONSEis only created when a participant actually submits an answer. No response row = 0 points for that question (no penalty record is needed).SESSION.codeis a 4-digit numeric string (e.g."4821"), randomly generated and unique among active sessions at creation time.