Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

DATABASE_SCHEMA

Category: 01. AI / ML Hackathons
Section: Phase 2: Technical Blueprint


Act as a senior database engineer.
Using the PRD and System Architecture below, design the database schema for an AI hackathon project.

PRD: [PASTE PRD]
ARCHITECTURE: [PASTE SYSTEM_ARCHITECTURE]

Provide:
1. Tables (Include standard tables + AI-specific tables like ChatHistory, PromptLogs, Embeddings)
2. Columns
3. Data types
4. Primary keys
5. Foreign keys
6. Relationships
7. Required fields
8. Optional fields
9. Indexes where useful
10. Example records
11. SQL schema

Explain why each table exists. 
Keep the database simple enough for a beginner hackathon team to understand and maintain.

-------------------------