q-tee
Tables (31)
classrooms
- id — serial — Primary key
- teacher_id — serial — Foreign key → teachers.id
- name — varchar — NOT NULL
- school_level — schoollevel — NOT NULL
- grade — integer — NOT NULL
- class_code — varchar — NOT NULL
- is_active — boolean
- created_at — timestamp
- updated_at — timestamp
english-assignment_deployments
- id — serial — Primary key
- assignment_id — serial — Foreign key → english-assignments.id
- student_id — integer — NOT NULL
- classroom_id — integer — NOT NULL
- status — varchar
- deployed_at — timestamp
- started_at — timestamp
- completed_at — timestamp
english-assignments
- id — serial — Primary key
- worksheet_id — serial — Foreign key → english-worksheets.worksheet_id
- title — varchar — NOT NULL
- classroom_id — integer — NOT NULL
- teacher_id — integer — NOT NULL
- problem_type — varchar(20) — NOT NULL
- total_questions — integer — NOT NULL
- is_deployed — varchar
- created_at — timestamp
- updated_at — timestamp
english-grading_results
- result_id — serial — Primary key
- worksheet_id — serial — Foreign key → english-worksheets.worksheet_id
- student_id — integer — NOT NULL
- completion_time — integer — NOT NULL
- total_score — integer — NOT NULL
- max_score — integer — NOT NULL
- percentage — double — NOT NULL
- needs_review — boolean
- is_reviewed — boolean
- reviewed_at — timestamp
- reviewed_by — varchar(100)
- created_at — timestamp — NOT NULL
english-passages
- id — serial — Primary key
- worksheet_id — serial — Foreign key → english-worksheets.worksheet_id
- passage_id — integer — NOT NULL
- passage_type — varchar(50) — NOT NULL
- passage_content — json — NOT NULL
- original_content — json
- korean_translation — json
- related_questions — json — NOT NULL
- created_at — timestamp — NOT NULL
english-question_results
- id — serial — Primary key
- grading_result_id — serial — Foreign key → english-grading_results.result_id
- question_id — integer — NOT NULL
- question_type — varchar(20) — NOT NULL
- student_answer — text
- correct_answer — text
- score — integer — NOT NULL
- max_score — integer — NOT NULL
- is_correct — boolean — NOT NULL
- grading_method — varchar(10) — NOT NULL
- ai_feedback — text
- needs_review — boolean
- reviewed_score — integer
- reviewed_feedback — text
- is_reviewed — boolean
- created_at — timestamp — NOT NULL
english-questions
- id — serial — Primary key
- worksheet_id — serial — Foreign key → english-worksheets.worksheet_id
- question_id — integer — NOT NULL
- question_text — text — NOT NULL
- question_type — varchar(20) — NOT NULL
- question_subject — varchar(20) — NOT NULL
- question_detail_type — varchar(100)
- question_difficulty — varchar(10) — NOT NULL
- question_choices — json
- passage_id — integer
- correct_answer — text
- example_content — text — NOT NULL
- example_original_content — text
- example_korean_translation — text
- explanation — text
- learning_point — text
- created_at — timestamp — NOT NULL
english-worksheets (english-workshhet)
- worksheet_id — serial — Primary key
- teacher_id — integer — NOT NULL
- worksheet_name — varchar(200) — NOT NULL
- school_level — varchar(20) — NOT NULL
- grade — varchar(10) — NOT NULL
- subject — varchar(50) — NOT NULL
- problem_type — varchar(20) — NOT NULL
- total_questions — integer — NOT NULL
- duration — integer
- created_at — timestamp — NOT NULL
korean-generations
- id — serial — Primary key
- generation_id — serial — Foreign key → korean-worksheets.id
- user_id — integer — NOT NULL
- school_level — varchar — NOT NULL
- grade — integer — NOT NULL
- korean_type — varchar — NOT NULL
- question_type — varchar — NOT NULL
- difficulty — varchar — NOT NULL
- problem_count — integer — NOT NULL
- question_type_ratio — json
- difficulty_ratio — json
- user_text — text
- total_generated — integer
- actual_korean_type_distribution — json
- actual_question_type_distribution — json
- actual_difficulty_distribution — json
- celery_task_id — varchar
- status — varchar
- created_at — timestamp
- updated_at — timestamp
korean-grading_sessions
- id — serial — Primary key
- worksheet_id — serial — Foreign key → korean-worksheets.id
- student_id — integer — NOT NULL
- graded_by — integer — NOT NULL
- total_problems — integer — NOT NULL
- correct_count — integer
- total_score — double
- max_possible_score — double — NOT NULL
- points_per_problem — double — NOT NULL
- input_method — varchar — NOT NULL
- ocr_text — text
- ocr_results — json
- multiple_choice_answers — json
- celery_task_id — varchar
- status — varchar
- teacher_id — integer
- approved_at — timestamp
- graded_at — timestamp
korean-problem_grading_results
- id — serial — Primary key
- grading_session_id — serial — Foreign key → korean-grading_sessions.id
- problem_id — integer — NOT NULL
- user_answer — text
- actual_user_answer — text
- correct_answer — text — NOT NULL
- is_correct — boolean — NOT NULL
- score — double — NOT NULL
- points_per_problem — double — NOT NULL
- problem_type — varchar — NOT NULL
- input_method — varchar — NOT NULL
- ai_score — double
- ai_feedback — text
- strengths — text
- improvements — text
- keyword_score_ratio — double
- explanation — text
korean-problems
- id — serial — Primary key
- worksheet_id — serial — Foreign key → korean-worksheets.id
- sequence_order — integer — NOT NULL
- korean_type — koreantype — NOT NULL
- problem_type — problemtype — NOT NULL
- difficulty — difficulty — NOT NULL
- question — text — NOT NULL
- choices — json
- correct_answer — text — NOT NULL
- explanation — text — NOT NULL
- source_text — text
- source_title — varchar
- source_author — varchar
- ai_model_used — varchar
- generation_prompt — text
- created_at — timestamp
- updated_at — timestamp
korean-worksheets (korean-worksheet)
- id — serial — Primary key
- title — varchar — NOT NULL
- school_level — varchar — NOT NULL
- grade — integer — NOT NULL
- korean_type — varchar — NOT NULL
- question_type — varchar — NOT NULL
- difficulty — varchar — NOT NULL
- problem_count — integer — NOT NULL
- question_type_ratio — json
- difficulty_ratio — json
- user_text — text
- generation_id — varchar — NOT NULL
- actual_korean_type_distribution — json
- actual_question_type_distribution — json
- actual_difficulty_distribution — json
- status — worksheetstatus
- celery_task_id — varchar
- teacher_id — integer — NOT NULL
- created_at — timestamp
- updated_at — timestamp
korean_assignment_deployments
- id — serial — Primary key
- assignment_id — serial — Foreign key → korean_assignments.id
- student_id — integer — NOT NULL
- classroom_id — integer — NOT NULL
- status — varchar
- deployed_at — timestamp
- submitted_at — timestamp
- graded_at — timestamp
korean_assignments
- id — serial — Primary key
- worksheet_id — serial — Foreign key → korean-worksheets.id
- title — varchar — NOT NULL
- classroom_id — integer — NOT NULL
- teacher_id — integer — NOT NULL
- korean_type — varchar — NOT NULL
- question_type — varchar — NOT NULL
- problem_count — integer — NOT NULL
- is_deployed — varchar
- created_at — timestamp
- updated_at — timestamp
market_products
- id — serial
- title — varchar(200) — NOT NULL
- description — text
- price — numeric(10, 2) — NOT NULL
- seller_id — integer — NOT NULL
- seller_name — varchar(100) — NOT NULL
- subject_type — varchar(20) — NOT NULL
- tags — json
- original_service — varchar(20) — NOT NULL
- original_worksheet_id — integer — NOT NULL
- status — varchar(20) — NOT NULL
- view_count — integer
- purchase_count — integer
- images — json
- main_image — varchar(255)
- created_at — timestamp
- updated_at — timestamp
market_purchases
- id — serial
- product_id — integer — NOT NULL
- buyer_id — integer — NOT NULL
- buyer_name — varchar(100) — NOT NULL
- purchase_price — numeric(10, 2) — NOT NULL
- payment_method — varchar(50)
- payment_status — varchar(20)
- purchased_at — timestamp
market_reviews
- id — serial
- product_id — integer — NOT NULL
- reviewer_id — integer — NOT NULL
- reviewer_name — varchar(100) — NOT NULL
- rating — integer — NOT NULL
- comment — text — ex
- created_at — timestamp
- updated_at — timestamp
math-assignment_deployments
- id — serial — Primary key
- assignment_id — serial — Foreign key → math-assignments.id
- student_id — integer — NOT NULL
- classroom_id — integer — NOT NULL
- status — varchar
- deployed_at — timestamp
- started_at — timestamp
- completed_at — timestamp
math-assignments
- id — serial — Primary key
- worksheet_id — serial — Foreign key → math-worksheets.id
- title — varchar — NOT NULL
- classroom_id — integer — NOT NULL
- teacher_id — integer — NOT NULL
- unit_name — varchar — NOT NULL
- chapter_name — varchar — NOT NULL
- problem_count — integer — NOT NULL
- is_deployed — varchar
- created_at — timestamp
- updated_at — timestamp
math-curriculum
- id — serial — Primary key
- grade — varchar — NOT NULL
- subject — varchar — NOT NULL
- semester — varchar — NOT NULL
- unit_number — varchar — NOT NULL
- unit_name — varchar — NOT NULL
- chapter_number — varchar — NOT NULL
- chapter_name — varchar — NOT NULL
- learning_objectives — text
- keywords — text
- difficulty_levels — json
- created_at — timestamp
- updated_at — timestamp
math-grading_sessions
- id — serial — Primary key
- worksheet_id — serial — Foreign key → math-worksheets.id
- celery_task_id — varchar(255)
- total_problems — integer — NOT NULL
- correct_count — integer — NOT NULL
- total_score — double — NOT NULL
- max_possible_score — double — NOT NULL
- points_per_problem — double — NOT NULL
- ocr_text — text
- ocr_results — json
- multiple_choice_answers — json
- input_method — varchar(50)
- graded_at — timestamp
- graded_by — integer — NOT NULL
math-problem_grading_results
- id — serial — Primary key
- grading_session_id — serial — Foreign key → math-grading_sessions.id
- problem_id — integer — NOT NULL
- user_answer — text
- actual_user_answer — text
- correct_answer — text — NOT NULL
- is_correct — boolean — NOT NULL
- score — double — NOT NULL
- points_per_problem — double — NOT NULL
- problem_type — varchar(50) — NOT NULL
- difficulty — varchar(10)
- input_method — varchar(50)
- ai_score — double
- ai_feedback — text
- strengths — text
- improvements — text
- keyword_score_ratio — double
- explanation — text
math-problems
- id — serial — Primary key
- worksheet_id — serial — Foreign key → math-worksheets.id
- sequence_order — integer — NOT NULL
- problem_type — varchar — NOT NULL
- difficulty — varchar — NOT NULL
- question — text — NOT NULL
- choices — json
- correct_answer — text — NOT NULL
- explanation — text
- latex_content — text
- image_url — varchar
- has_diagram — varchar
- diagram_type — varchar
- diagram_elements — json
- created_at — timestamp
- updated_at — timestamp
math-test_answers
- id — serial — Primary key
- session_id — varchar — NOT NULL
- answer — text
- answered_at — timestamp
- updated_at — timestamp
- problem_id
math-test_sessions
- id — serial — Primary key
- session_id — varchar — NOT NULL
- assignment_id — integer — NOT NULL
- student_id — integer — NOT NULL
- status — varchar
- started_at — timestamp
- completed_at — timestamp
- submitted_at — timestamp
math-worksheets
- id — serial — Primary key
- title — varchar — NOT NULL
- school_level — varchar — NOT NULL
- grade — integer — NOT NULL
- semester — varchar — NOT NULL
- unit_number — varchar — NOT NULL
- unit_name — varchar — NOT NULL
- chapter_number — varchar — NOT NULL
- chapter_name — varchar — NOT NULL
- problem_count — integer — NOT NULL
- difficulty_ratio — json — NOT NULL
- problem_type_ratio — json — NOT NULL
- user_prompt — text — NOT NULL
- generation_id — varchar — NOT NULL
- actual_difficulty_distribution — json
- actual_type_distribution — json
- status — worksheetstatus
- celery_task_id — varchar
- error_message — text
- completed_at — timestamp
- teacher_id — integer — NOT NULL
- created_by — integer
- created_at — timestamp
- updated_at — timestamp
math_problem_generations
- id — serial — Primary key
- generation_id — serial — Foreign key → math-worksheets.id
- school_level — varchar — NOT NULL
- grade — integer — NOT NULL
- semester — varchar — NOT NULL
- unit_number — varchar — NOT NULL
- unit_name — varchar — NOT NULL
- chapter_number — varchar — NOT NULL
- chapter_name — varchar — NOT NULL
- problem_count — integer — NOT NULL
- difficulty_ratio — json — NOT NULL
- problem_type_ratio — json — NOT NULL
- user_text — text — NOT NULL
- actual_difficulty_distribution — json
- actual_type_distribution — json
- total_generated — integer
- created_by — integer
- created_at — timestamp
- updated_at — timestamp
student_join_requests
- id — serial — Primary key
- classroom_id — serial — Foreign key → classrooms.id
- student_id — serial — Foreign key → students.id
- status — varchar
- requested_at — timestamp
- processed_at — timestamp
students
- id — serial — Primary key
- username — varchar — NOT NULL
- email — varchar — NOT NULL
- name — varchar — NOT NULL
- phone — varchar — NOT NULL
- parent_phone — varchar — NOT NULL
- school_level — schoollevel — NOT NULL
- grade — integer — NOT NULL
- hashed_password — varchar — NOT NULL
- is_active — boolean
- created_at — timestamp
- updated_at — timestamp
teachers
- id — serial — Primary key
- username — varchar — NOT NULL
- email — varchar — NOT NULL
- name — varchar — NOT NULL
- phone — varchar — NOT NULL
- hashed_password — varchar — NOT NULL
- is_active — boolean
- created_at — timestamp
- updated_at — timestamp