How kairyu1207/sokdaksokdak works
SokdakSokdak is a student mental-wellbeing web app for student/teacher access, supportive chat, and teacher-facing analysis of chat history. Students log in, chat with an AI, and can view teacher messages and daily goals; teachers log in to view students, save notes/goals, and request an analysis. The graph reflects sampled routes and client code; template contents were not sampled, so chat-page submission wiring and other page behavior are not assumed.
Main entry points: script.js Client interactions · main.py Chat endpoint · firebase_config.py Server Firebase client · teacher.html Teacher page
Components 14
Web interface
- Client interactions
static/script.js - Home page
templates/index.html
Login and roles
- Login page
templates/login.html - Firebase database
- Server Firebase client
firebase_config.py
Student support
- Student page
templates/student.html - Chat page
templates/chat.html - Chat endpoint
main.py - Chat history
main.py - OpenAI API
Teacher analysis
- Teacher page
templates/teacher.html - Analysis endpoint
main.py
Other components
- Student
- Teacher
Connections 20
- Student → Home page: opens
- Teacher → Home page: opens
- Client interactions → Login page: navigates to
static/script.js - Client interactions → Firebase database: reads credentials
static/script.js - Client interactions → Student page: navigates to
static/script.js - Client interactions → Teacher page: navigates to
static/script.js - Client interactions → Firebase database: reads class data
static/script.js - Client interactions → Firebase database: writes notes and goals
static/script.js - Client interactions → Firebase database: reads notes and goals
static/script.js - Client interactions → Analysis endpoint: requests results
static/script.js - Student → Chat endpoint: submits message
main.py - Chat endpoint → Server Firebase client: uses database
main.py - Server Firebase client → Firebase database: connects to
firebase_config.py - Chat endpoint → OpenAI API: requests reply
main.py - Chat endpoint → Chat history: saves exchange
main.py - Chat history → Firebase database: writes history
main.py - Teacher → Teacher page: uses
- Analysis endpoint → Server Firebase client: loads history
main.py - Analysis endpoint → OpenAI API: requests analysis
main.py - Teacher page → Analysis endpoint: requests analysis