Final Project ERD

Tables (39)

activity_region

  • id — BIGINT — Primary key — NOT NULL
  • region_code — VARCHAR(30) — NOT NULL
  • province_name — VARCHAR(50) — NOT NULL
  • region_name — VARCHAR(50) — NOT NULL
  • representative_latitude — DECIMAL(9,6) — NOT NULL
  • representative_longitude — DECIMAL(9,6) — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • updated_at — DATETIME(6) — NOT NULL

ai_practice_chat

  • id — BIGINT — Primary key — NOT NULL
  • session_id — BIGINT — Foreign key → ai_practice_session.id — NOT NULL
  • user_message — VARCHAR(500) — NOT NULL
  • ai_response — TEXT
  • status — VARCHAR(20) — NOT NULL
  • is_retry — BOOLEAN — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • completed_at — DATETIME(6)

ai_practice_session

  • id — BIGINT — Primary key — NOT NULL
  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • target_persona_id — BIGINT — Foreign key → persona.id — NOT NULL
  • status — VARCHAR(20) — NOT NULL
  • started_at — DATETIME(6) — NOT NULL
  • ended_at — DATETIME(6)

ai_simulation_message

  • id — BIGINT — Primary key — NOT NULL
  • session_id — BIGINT — Foreign key → ai_simulation_session.id — NOT NULL
  • content — JSON — NOT NULL
  • created_at — DATETIME(6) — NOT NULL

ai_simulation_report

  • id — BIGINT — Primary key — NOT NULL
  • session_id — BIGINT — Foreign key → ai_simulation_session.id — NOT NULL
  • status — VARCHAR(20) — NOT NULL
  • overall_score — DECIMAL(5,2)
  • summary — TEXT
  • conversation_flow_grade — CHAR(1)
  • question_exchange_grade — CHAR(1)
  • interest_expression_grade — CHAR(1)
  • initiative_balance_grade — CHAR(1)
  • detail_result — JSON
  • created_at — DATETIME(6) — NOT NULL
  • completed_at — DATETIME(6)

ai_simulation_session

  • id — BIGINT — Primary key — NOT NULL
  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • my_persona_id — BIGINT — Foreign key → persona.id — NOT NULL
  • target_persona_id — BIGINT — Foreign key → persona.id — NOT NULL
  • status — VARCHAR(20) — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • finished_at — DATETIME(6)

chat_delegation

  • id — BIGINT — Primary key — NOT NULL
  • chat_room_id — BIGINT — Foreign key → chat_room.id — NOT NULL
  • requester_member_id — BIGINT — Foreign key → member.id — NOT NULL
  • status — VARCHAR(30) — NOT NULL
  • consented_at — DATETIME(6) — NOT NULL
  • ended_at — DATETIME(6)
  • end_reason — VARCHAR(30)

chat_message

  • id — BIGINT — Primary key — NOT NULL
  • chat_room_id — BIGINT — Foreign key → chat_room.id — NOT NULL
  • sender_member_id — BIGINT — Foreign key → member.id — NOT NULL
  • delegation_id — BIGINT — Foreign key → chat_delegation.id
  • message_type — VARCHAR(20) — NOT NULL
  • text_content — VARCHAR(1000)
  • status — VARCHAR(20) — NOT NULL
  • sequence_no — BIGINT — NOT NULL
  • client_message_id — VARCHAR(64) — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • sender_deleted_at — DATETIME(6)
  • receiver_deleted_at — DATETIME(6)

chat_message_image

  • id — BIGINT — Primary key — NOT NULL
  • chat_message_id — BIGINT — Foreign key → chat_message.id — NOT NULL
  • image_key — VARCHAR(500) — NOT NULL
  • mime_type — VARCHAR(50) — NOT NULL
  • file_size — BIGINT — NOT NULL
  • sort_order — TINYINT — NOT NULL

chat_participant

  • id — BIGINT — Primary key — NOT NULL
  • chat_room_id — BIGINT — Foreign key → chat_room.id — NOT NULL
  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • status — VARCHAR(20) — NOT NULL
  • push_enabled — BOOLEAN — NOT NULL
  • left_at — DATETIME(6)
  • last_read_sequence_no — BIGINT — NOT NULL

chat_room

  • id — BIGINT — Foreign key → match.id — NOT NULL
  • status — VARCHAR(20) — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • ended_at — DATETIME(6)
  • end_reason — VARCHAR(30)

face_analysis

  • id — BIGINT — Primary key — NOT NULL
  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • status — VARCHAR(20) — NOT NULL
  • is_retry — BOOLEAN — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • finished_at — DATETIME(6)

face_analysis_result

  • id — BIGINT — Primary key — NOT NULL
  • face_analysis_id — BIGINT — Foreign key → face_analysis.id — NOT NULL
  • summary — TEXT — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • deleted_at — DATETIME(6)

face_compatibility

  • id — BIGINT — Primary key — NOT NULL
  • member_result_id — BIGINT — Foreign key → face_analysis_result.id — NOT NULL
  • target_result_id — BIGINT — Foreign key → face_analysis_result.id — NOT NULL
  • score — DECIMAL(5,2) — NOT NULL
  • detail_report — JSON — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • deleted_at — DATETIME(6)

face_recommendation_batch

  • id — BIGINT — Primary key — NOT NULL
  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • face_analysis_result_id — BIGINT — Foreign key → face_analysis_result.id — NOT NULL
  • created_at — DATETIME(6) — NOT NULL

face_recommendation_item

  • id — BIGINT — Primary key — NOT NULL
  • face_recommendation_id — BIGINT — Foreign key → face_recommendation_batch.id — NOT NULL
  • target_member_id — BIGINT — Foreign key → member.id — NOT NULL
  • rank_no — INT — NOT NULL

like

  • id — BIGINT — Primary key — NOT NULL
  • sender_member_id — BIGINT — Foreign key → member.id — NOT NULL
  • receiver_member_id — BIGINT — Foreign key → member.id — NOT NULL
  • status — VARCHAR(20) — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • resolved_at — DATETIME(6)

match

  • id — BIGINT — Primary key — NOT NULL
  • member1_id — BIGINT — Foreign key → member.id — NOT NULL
  • member2_id — BIGINT — Foreign key → member.id — NOT NULL
  • status — VARCHAR(20) — NOT NULL
  • matched_at — DATETIME(6) — NOT NULL
  • ended_at — DATETIME(6)
  • end_reason — VARCHAR(30)

member

  • id — BIGINT — Primary key — NOT NULL
  • status — VARCHAR(20) — NOT NULL
  • birth_date — DATE — NOT NULL
  • sex — ENUM('FEMALE', 'MALE') — NOT NULL
  • name — VARCHAR(100) — NOT NULL
  • face_verification_status — VARCHAR(20) — NOT NULL
  • last_accessed_at — DATETIME(6) — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • withdrawn_at — DATETIME(6)

member_auth_account

  • id — BIGINT — Primary key — NOT NULL
  • provider — VARCHAR(255) — NOT NULL
  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • provider_user_id — VARCHAR(255) — NOT NULL
  • linked_at — DATETIME(6) — NOT NULL

member_block

  • id — BIGINT — Primary key — NOT NULL
  • blocker_member_id — BIGINT — Foreign key → member.id — NOT NULL
  • blocked_member_id — BIGINT — Foreign key → member.id — NOT NULL
  • blocked_at — DATETIME(6) — NOT NULL
  • unblocked_at — DATETIME(6)

member_term_agreement

  • id — BIGINT — Primary key — NOT NULL
  • term_id — BIGINT — Foreign key → term.id — NOT NULL
  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • agreed_at — DATETIME(6) — NOT NULL

notification

  • id — BIGINT — Primary key — NOT NULL
  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • type — VARCHAR(30) — NOT NULL
  • title — VARCHAR(100) — NOT NULL
  • body — VARCHAR(500) — NOT NULL
  • target_type — VARCHAR(30)
  • target_id — BIGINT
  • read_at — DATETIME(6)
  • created_at — DATETIME(6) — NOT NULL
  • deleted_at — DATETIME(6)

persona

  • id — BIGINT — Primary key — NOT NULL
  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • system_prompt — TEXT — NOT NULL
  • personality_summary — JSON
  • built_at — DATETIME(6) — NOT NULL

persona_build

  • id — BIGINT — Primary key — NOT NULL
  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • build_type — VARCHAR(30) — NOT NULL
  • status — VARCHAR(20) — NOT NULL
  • input_data — JSON — NOT NULL
  • source_from_at — DATETIME(6)
  • source_to_at — DATETIME(6)
  • started_at — DATETIME(6) — NOT NULL
  • finished_at — DATETIME(6)

persona_trait

  • id — BIGINT — Primary key — NOT NULL
  • persona_id — BIGINT — Foreign key → persona.id — NOT NULL
  • category — VARCHAR(30) — NOT NULL
  • label — VARCHAR(20) — NOT NULL
  • observation_count — SMALLINT — NOT NULL
  • deleted_at — DATETIME(6)

profile

  • id — BIGINT — Primary key — NOT NULL
  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • activity_region_id — BIGINT — Foreign key → activity_region.id
  • nickname — VARCHAR(10)
  • height — SMALLINT
  • body_type — VARCHAR(30)
  • education_level — VARCHAR(30)
  • job — VARCHAR(50)
  • religion — VARCHAR(30)
  • mbti — VARCHAR(4)
  • drinking — VARCHAR(30)
  • smoking — VARCHAR(30)
  • created_at — DATETIME(6) — NOT NULL
  • updated_at — DATETIME(6) — NOT NULL

profile_image

  • id — BIGINT — Primary key — NOT NULL
  • profile_id — BIGINT — Foreign key → profile.id — NOT NULL
  • image_key — VARCHAR(500) — NOT NULL
  • display_order — SMALLINT — NOT NULL
  • is_frontal — BOOLEAN — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • deleted_at — DATETIME(6)

recommendation_batch

  • id — BIGINT — Primary key — NOT NULL
  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • generation_type — VARCHAR(20) — NOT NULL
  • created_at — DATETIME(6) — NOT NULL

recommendation_item

  • id — BIGINT — Primary key — NOT NULL
  • recommendation_batch_id — BIGINT — Foreign key → recommendation_batch.id — NOT NULL
  • candidate_member_id — BIGINT — Foreign key → member.id — NOT NULL
  • ranking_order — INTEGER — NOT NULL

recommendation_pass

  • id — BIGINT — Primary key — NOT NULL
  • passer_member_id — BIGINT — Foreign key → member.id — NOT NULL
  • passed_member_id — BIGINT — Foreign key → member.id — NOT NULL
  • created_at — DATETIME(6) — NOT NULL

recommendation_preference

  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • min_age — SMALLINT
  • max_age — SMALLINT
  • min_height — SMALLINT
  • max_height — SMALLINT
  • relationship_preference — VARCHAR(30)
  • religion — VARCHAR(30)
  • drinking — VARCHAR(30)
  • smoking — VARCHAR(30)
  • created_at — DATETIME(6) — NOT NULL
  • updated_at — DATETIME(6) — NOT NULL

saju_analysis

  • id — BIGINT — Primary key — NOT NULL
  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • input_snapshot — JSON — NOT NULL
  • status — VARCHAR(20) — NOT NULL
  • is_retry — BOOLEAN — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • finished_at — DATETIME(6)

saju_analysis_result

  • id — BIGINT — Primary key — NOT NULL
  • saju_analysis_id — BIGINT — Foreign key → saju_analysis.id — NOT NULL
  • summary — TEXT — NOT NULL
  • detail_result — JSON — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • deleted_at — DATETIME(6)

saju_compatibility

  • id — BIGINT — Primary key — NOT NULL
  • requester_result_id — BIGINT — Foreign key → saju_analysis_result.id — NOT NULL
  • target_result_id — BIGINT — Foreign key → saju_analysis_result.id — NOT NULL
  • score — DECIMAL(5,2) — NOT NULL
  • detail_result — JSON — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • deleted_at — DATETIME(6)

saju_profile

  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • birth_time — VARCHAR(20)
  • updated_at — DATETIME(6) — NOT NULL

saju_recommendation_batch

  • id — BIGINT — Primary key — NOT NULL
  • member_id — BIGINT — Foreign key → member.id — NOT NULL
  • saju_analysis_result_id — BIGINT — Foreign key → saju_analysis_result.id — NOT NULL
  • created_at — DATETIME(6) — NOT NULL

saju_recommendation_item

  • id — BIGINT — Primary key — NOT NULL
  • saju_recommendation_id — BIGINT — Foreign key → saju_recommendation_batch.id — NOT NULL
  • target_member_id — BIGINT — Foreign key → member.id — NOT NULL
  • compatibility_score — DECIMAL(5,2) — NOT NULL
  • rank_no — INT — NOT NULL

term

  • id — BIGINT — Primary key — NOT NULL
  • code — VARCHAR(50) — NOT NULL
  • title — VARCHAR(150) — NOT NULL
  • content — TEXT — NOT NULL
  • required — BOOLEAN — NOT NULL
  • created_at — DATETIME(6) — NOT NULL
  • ended_at — DATETIME(6)