# debjitds/reverie-meetops architecture

> Architecture diagram of the GitHub repository debjitds/reverie-meetops, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-25). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/debjitds/reverie-meetops
- Repository: https://github.com/debjitds/reverie-meetops

## Overview

This is a Supabase-backed resource-booking and administration app. Users enter through public landing or account pages, then use the authenticated dashboard to find resources, create and manage bookings, or view them on a calendar; administrators also have user and AI-insight views. The tree documents additional server functions for multi-day bookings, agenda generation, conflict explanations, booking-status updates, and text translation. The sampled source confirms auth/profile access and the chat assistant’s database/LLM work; page-level wiring and several function internals were not sampled, so those connections are omitted.

Main entry points: [`src/routes.tsx`](https://github.com/debjitds/reverie-meetops/blob/main/src/routes.tsx) (Route table), [`src/contexts/LanguageContext.tsx`](https://github.com/debjitds/reverie-meetops/blob/main/src/contexts/LanguageContext.tsx) (Language provider), [`src/App.tsx`](https://github.com/debjitds/reverie-meetops/blob/main/src/App.tsx) (App router), [`supabase/functions/chat-assistant/index.ts`](https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/chat-assistant/index.ts) (Chat assistant)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["App and access"]
  node_app["App router<br/>[App.tsx]"]
  node_routes["Route table<br/>[routes.tsx]"]
  node_auth["Auth provider<br/>[AuthContext.tsx]"]
  node_login["Account pages<br/>[LoginPage.tsx]"]
  node_profile["Profile page<br/>[ProfilePage.tsx]"]
end

subgraph group_booking["Booking workflows"]
  node_dashboard["Dashboard<br/>[DashboardPage.tsx]"]
  node_bookings["Booking list<br/>[BookingsPage.tsx]"]
  node_newbooking["New booking<br/>[NewBookingPage.tsx]"]
  node_detail["Booking detail"]
  node_calendar["Booking calendar<br/>[CalendarPage.tsx]"]
  node_resources["Resource catalog<br/>[ResourcesPage.tsx]"]
  node_chat["Booking assistant<br/>[ChatWidget.tsx]"]
end

subgraph group_admin["Administration"]
  node_users["User administration<br/>[UsersPage.tsx]"]
  node_insights["Admin insights<br/>[AdminInsights.tsx]"]
end

subgraph group_services["Backend services"]
  node_supaclient["Supabase client<br/>[supabase.ts]"]
  node_store[("Supabase data")]
  node_chatfn["Chat assistant<br/>[index.ts]"]
  node_multiday["Multi-day booking<br/>[index.ts]"]
  node_agenda["Agenda generation<br/>[index.ts]"]
  node_conflict["Conflict explanation<br/>[index.ts]"]
  node_statuses["Status updater<br/>[index.ts]"]
  node_insightfn["Insights generation<br/>[index.ts]"]
  node_translatefn["Text translation<br/>[index.ts]"]
end

subgraph group_language["Language support"]
  node_language["Language provider"]
  node_dictionaries["Static dictionaries<br/>[index.ts]"]
end

node_user(("User"))
node_llm["LLM API"]

node_user -->|"uses"| node_app
node_app -->|"renders routes"| node_routes
node_app -->|"provides auth"| node_auth
node_routes -->|"routes to"| node_login
node_routes -->|"routes to"| node_dashboard
node_routes -->|"routes to"| node_bookings
node_routes -->|"routes to"| node_newbooking
node_routes -->|"routes to"| node_detail
node_routes -->|"routes to"| node_calendar
node_routes -->|"routes to"| node_resources
node_routes -->|"routes to"| node_users
node_routes -->|"routes to"| node_profile
node_auth -->|"queries auth/profile"| node_supaclient
node_supaclient -->|"accesses"| node_store
node_chat -->|"requests"| node_chatfn
node_chatfn -->|"reads/writes"| node_store
node_chatfn -.->|"requests completion"| node_llm
node_language -->|"reads profile"| node_auth
node_language -->|"saves preference"| node_supaclient
node_language -->|"selects language"| node_dictionaries
node_insights -.->|"requests insights"| node_insightfn

click node_app "https://github.com/debjitds/reverie-meetops/blob/main/src/App.tsx"
click node_routes "https://github.com/debjitds/reverie-meetops/blob/main/src/routes.tsx"
click node_auth "https://github.com/debjitds/reverie-meetops/blob/main/src/contexts/AuthContext.tsx"
click node_login "https://github.com/debjitds/reverie-meetops/blob/main/src/pages/LoginPage.tsx"
click node_dashboard "https://github.com/debjitds/reverie-meetops/blob/main/src/pages/DashboardPage.tsx"
click node_bookings "https://github.com/debjitds/reverie-meetops/blob/main/src/pages/BookingsPage.tsx"
click node_newbooking "https://github.com/debjitds/reverie-meetops/blob/main/src/pages/NewBookingPage.tsx"
click node_detail "https://github.com/debjitds/reverie-meetops/blob/main/src/pages/BookingDetailPage.tsx"
click node_calendar "https://github.com/debjitds/reverie-meetops/blob/main/src/pages/CalendarPage.tsx"
click node_resources "https://github.com/debjitds/reverie-meetops/blob/main/src/pages/ResourcesPage.tsx"
click node_users "https://github.com/debjitds/reverie-meetops/blob/main/src/pages/UsersPage.tsx"
click node_insights "https://github.com/debjitds/reverie-meetops/blob/main/src/components/ai/AdminInsights.tsx"
click node_chat "https://github.com/debjitds/reverie-meetops/blob/main/src/components/ai/ChatWidget.tsx"
click node_supaclient "https://github.com/debjitds/reverie-meetops/blob/main/src/db/supabase.ts"
click node_chatfn "https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/chat-assistant/index.ts"
click node_multiday "https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/create-multi-day-booking/index.ts"
click node_agenda "https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/generate-agenda/index.ts"
click node_conflict "https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/generate-conflict-explanation/index.ts"
click node_statuses "https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/update-booking-statuses/index.ts"
click node_insightfn "https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/generate-admin-insights/index.ts"
click node_translatefn "https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/translate-text/index.ts"
click node_language "https://github.com/debjitds/reverie-meetops/blob/main/src/contexts/LanguageContext.tsx"
click node_dictionaries "https://github.com/debjitds/reverie-meetops/blob/main/src/i18n/index.ts"
click node_profile "https://github.com/debjitds/reverie-meetops/blob/main/src/pages/ProfilePage.tsx"

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_app,node_routes,node_auth,node_login,node_profile,node_user toneBlue
class node_dashboard,node_bookings,node_newbooking,node_detail,node_calendar,node_resources,node_chat toneAmber
class node_users,node_insights,node_llm toneMint
class node_supaclient,node_store,node_chatfn,node_multiday,node_agenda,node_conflict,node_statuses,node_insightfn,node_translatefn toneRose
class node_language,node_dictionaries toneIndigo
```

## Components

### App and access

- [App router](https://github.com/debjitds/reverie-meetops/blob/main/src/App.tsx): `src/App.tsx`
- [Route table](https://github.com/debjitds/reverie-meetops/blob/main/src/routes.tsx): `src/routes.tsx`
- [Auth provider](https://github.com/debjitds/reverie-meetops/blob/main/src/contexts/AuthContext.tsx): `src/contexts/AuthContext.tsx`
- [Account pages](https://github.com/debjitds/reverie-meetops/blob/main/src/pages/LoginPage.tsx): `src/pages/LoginPage.tsx`
- [Profile page](https://github.com/debjitds/reverie-meetops/blob/main/src/pages/ProfilePage.tsx): `src/pages/ProfilePage.tsx`

### Booking workflows

- [Dashboard](https://github.com/debjitds/reverie-meetops/blob/main/src/pages/DashboardPage.tsx): `src/pages/DashboardPage.tsx`
- [Booking list](https://github.com/debjitds/reverie-meetops/blob/main/src/pages/BookingsPage.tsx): `src/pages/BookingsPage.tsx`
- [New booking](https://github.com/debjitds/reverie-meetops/blob/main/src/pages/NewBookingPage.tsx): `src/pages/NewBookingPage.tsx`
- [Booking detail](https://github.com/debjitds/reverie-meetops/blob/main/src/pages/BookingDetailPage.tsx): `src/pages/BookingDetailPage.tsx`
- [Booking calendar](https://github.com/debjitds/reverie-meetops/blob/main/src/pages/CalendarPage.tsx): `src/pages/CalendarPage.tsx`
- [Resource catalog](https://github.com/debjitds/reverie-meetops/blob/main/src/pages/ResourcesPage.tsx): `src/pages/ResourcesPage.tsx`
- [Booking assistant](https://github.com/debjitds/reverie-meetops/blob/main/src/components/ai/ChatWidget.tsx): `src/components/ai/ChatWidget.tsx`

### Administration

- [User administration](https://github.com/debjitds/reverie-meetops/blob/main/src/pages/UsersPage.tsx): `src/pages/UsersPage.tsx`
- [Admin insights](https://github.com/debjitds/reverie-meetops/blob/main/src/components/ai/AdminInsights.tsx): `src/components/ai/AdminInsights.tsx`

### Backend services

- [Supabase client](https://github.com/debjitds/reverie-meetops/blob/main/src/db/supabase.ts): `src/db/supabase.ts`
- **Supabase data**
- [Chat assistant](https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/chat-assistant/index.ts): `supabase/functions/chat-assistant/index.ts`
- [Multi-day booking](https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/create-multi-day-booking/index.ts): `supabase/functions/create-multi-day-booking/index.ts`
- [Agenda generation](https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/generate-agenda/index.ts): `supabase/functions/generate-agenda/index.ts`
- [Conflict explanation](https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/generate-conflict-explanation/index.ts): `supabase/functions/generate-conflict-explanation/index.ts`
- [Status updater](https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/update-booking-statuses/index.ts): `supabase/functions/update-booking-statuses/index.ts`
- [Insights generation](https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/generate-admin-insights/index.ts): `supabase/functions/generate-admin-insights/index.ts`
- [Text translation](https://github.com/debjitds/reverie-meetops/blob/main/supabase/functions/translate-text/index.ts): `supabase/functions/translate-text/index.ts`

### Language support

- [Language provider](https://github.com/debjitds/reverie-meetops/blob/main/src/contexts/LanguageContext.tsx): `src/contexts/LanguageContext.tsx`
- [Static dictionaries](https://github.com/debjitds/reverie-meetops/blob/main/src/i18n/index.ts): `src/i18n/index.ts`

### Other components

- **User**
- **LLM API**

## Connections

- User → App router: uses
- App router → Route table: renders routes
- App router → Auth provider: provides auth
- Route table → Account pages: routes to
- Route table → Dashboard: routes to
- Route table → Booking list: routes to
- Route table → New booking: routes to
- Route table → Booking detail: routes to
- Route table → Booking calendar: routes to
- Route table → Resource catalog: routes to
- Route table → User administration: routes to
- Route table → Profile page: routes to
- Auth provider → Supabase client: queries auth/profile
- Supabase client → Supabase data: accesses
- Booking assistant → Chat assistant: requests
- Chat assistant → Supabase data: reads/writes
- Chat assistant → LLM API: requests completion
- Language provider → Auth provider: reads profile
- Language provider → Supabase client: saves preference
- Language provider → Static dictionaries: selects language
- Admin insights → Insights generation: requests insights
