How kaithwasaditya/ai-learning-management-system-saas- works
This is a Next.js LMS for building AI voice tutors, discovering them, and tracking tutoring sessions. The main workflow is to define a companion, save it, start a voice session, and record the session for later review. Supabase backs companion and session-history data; Clerk provides identity and subscription checks; Vapi powers voice sessions. The graph follows sampled calls and imports plus README-documented integrations; some listed capabilities, including real-time database sync and billing, are documented but not visible in sampled implementation.
Main entry points: companion.actions.ts Companion data actions · companions/page.tsx Tutor library · CompanionComponent.tsx Voice session UI · my-journey/page.tsx Learning history
Components 22
Tutor discovery & creation
- Home dashboard
app/page.tsx - Tutor library
app/companions/page.tsx - Search input
components/SearchInput.tsx - Subject filter
components/SubjectFilter.tsx - Tutor cards
components/CompanionCard.tsx - Tutor builder
components/CompanionForm.tsx - New tutor page
app/companions/new/page.tsx
Tutoring sessions
- Session page
app/companions/[id]/page.tsx - Voice session UI
components/CompanionComponent.tsx - Assistant configuration
lib/utils.ts - Vapi client
lib/vapi.sdk.ts
User platform
- Learning history
app/my-journey/page.tsx - Session and tutor lists
components/CompanionsList.tsx - Sign-in page
- Subscription page
app/subscription/page.tsx - Reusable UI primitives
components/ui
Data & integrations
- Companion data actions
lib/actions/companion.actions.ts - Supabase client
lib/supabase.ts - Supabase
- Clerk identity and billing
- Tutor options and colors
constants/index.ts
Other components
- Learner
Connections 32
- Learner → Home dashboard: opens
- Home dashboard → Companion data actions: loads tutors and sessions
app/page.tsx - Home dashboard → Tutor cards: renders
app/page.tsx - Learner → Tutor library: browses
- Tutor library → Companion data actions: loads filtered tutors
app/companions/page.tsx - Tutor library → Search input: renders
app/companions/page.tsx - Tutor library → Subject filter: renders
app/companions/page.tsx - Search input → Tutor library: updates query
components/SearchInput.tsx - Tutor library → Tutor cards: renders
app/companions/page.tsx - Learner → New tutor page: creates tutor
- New tutor page → Tutor builder: renders
app/companions/new/page.tsx - Tutor builder → Companion data actions: creates tutor
components/CompanionForm.tsx - Learner → Session page: starts session
- Session page → Companion data actions: loads tutor
app/companions/[id]/page.tsx - Session page → Voice session UI: renders
app/companions/[id]/page.tsx - Voice session UI → Assistant configuration: configures assistant
components/CompanionComponent.tsx - Voice session UI → Vapi client: controls voice call
components/CompanionComponent.tsx - Voice session UI → Companion data actions: records completed session
components/CompanionComponent.tsx - Learner → Learning history: reviews progress
- Learning history → Clerk identity and billing: gets current user
app/my-journey/page.tsx - Learning history → Companion data actions: loads history and tutors
app/my-journey/page.tsx - Learning history → Session and tutor lists: renders history
app/my-journey/page.tsx - Companion data actions → Supabase client: uses client
lib/actions/companion.actions.ts - Supabase client → Supabase: accesses database
README.md - Companion data actions → Clerk identity and billing: checks identity and plan
lib/actions/companion.actions.ts - Learner → Sign-in page: authenticates
- Sign-in page → Clerk identity and billing: provides sign-in
README.md - Learner → Subscription page: manages plan
- Subscription page → Clerk identity and billing: uses billing
README.md - Assistant configuration → Tutor options and colors: reads voice options
lib/utils.ts - Tutor builder → Reusable UI primitives: uses form controls
components/CompanionForm.tsx - Subject filter → Reusable UI primitives: uses select controls
components/SubjectFilter.tsx