from __future__ import annotations

from dataclasses import dataclass
from typing import Tuple


BASE_EXCLUDE_COLS = {
    "dataset_split",
    "student_faculty_key",
    "student_faculty_name",
    "IDSV",
    "target_NHHK",
    "target_semester_ordinal",
    "IDKQDK",
    "IDToHoc",
    "IDMH",
    "target_IDCongDiem",
    "target_grade10",
    "target_grade4",
    "target_status",
    "base_row_id",
    "course_cluster_label",
}


@dataclass(frozen=True)
class SuiteConfig:
    target_col: str = "target_grade10"
    target_grade4_col: str = "target_grade4"
    student_col: str = "IDSV"
    course_col: str = "IDMH"
    registration_col: str = "IDKQDK"
    semester_col: str = "target_semester_ordinal"
    semester_code_col: str = "target_NHHK"
    event: float = 5.0

    trunk: Tuple[int, ...] = (256, 128)
    head: int = 64
    dropout: float = 0.3
    epochs: int = 100
    batch_size: int = 512
    learning_rate: float = 1e-3
    weight_decay: float = 1e-5
    low_weight: float = 5.0
    cb_beta: float = 0.9999
    w_reg: float = 1.0
    w_cls: float = 1.0
    w_blend: float = 1.0
    seed: int = 42
    prediction_batch_size: int = 8192

    reliability_course_k: float = 5.0
    reliability_semester_k: float = 2.0
    reliability_component_k: float = 20.0
    reliability_same_course_k: float = 2.0
    reliability_target_course_k: float = 20.0
    shrinkage_alpha: float = 10.0
    robust_lower_quantile: float = 0.005
    robust_upper_quantile: float = 0.995

    exclude_cols: frozenset[str] = frozenset(BASE_EXCLUDE_COLS)
