憂鬱症(Major Depressive Disorder, MDD)為常見且疾病負擔沉重之精神疾病,其形成涉及遺傳、環境、生活型態與心理社會因素,並具有高度異質性與多基因特性。現有憂鬱症基因體研究多以歐美大型族群為主,臺灣族群之基因體風險分類研究仍相對有限。因此,本研究以臺灣人體生物資料庫(Taiwan Biobank, TWB)為基礎,建立一套結合全基因組關聯分析(Genome-Wide Association Study, GWAS)與機器學習之憂鬱症病例/健康對照分類流程,並評估其於臺灣族群中的方法學可行性。 本研究建立憂鬱症病例組與嚴格健康對照組,並進行樣本與單核苷酸多型性(Single Nucleotide Polymorphism, SNP)品質控管、連鎖不平衡剪枝、親緣關係推估與基因關係矩陣(Genomic Relationship Matrix, GRM)建構。為降低親屬跨越資料集與測試集資訊提前進入模型所造成之效能高估,本研究採用親屬群組切分(family-aware split),使同一親屬群組不會同時出現在訓練集與測試集,並僅於訓練集執行 mixed model GWAS、候選 SNP 篩選與特徵建構。訓練集 GWAS 於 P < 1 × 10⁻² 門檻下取得 5,088 個候選 SNP,作為後續分析之候選母集合。 在特徵建構方面,本研究整合 SNP 訊號強度、效果方向一致性、交叉驗證穩定性與重抽樣穩定性,將 5,088 個候選 SNP 分為 stable biological core 1,196 個、extended support layer 1,804 個與 polygenic background 2,088 個,並建立 SNP100、SNP500、SNP1000、SNP2000、SNP3000 與 All-SNP 等不同 SNP pool。模型建構比較 raw dosage 與 score vector representation、age_sex 與 cov_core_family 協變量模式,以及 Logistic Regression、Random Forest、XGBoost、LightGBM、CatBoost、Soft Voting 與 Stacking 等模型。模型效能以 AUC、Accuracy、Balanced Accuracy、Sensitivity、Specificity、F1-score 與 Matthews Correlation Coefficient(MCC)等指標評估。 研究結果顯示,All-SNP(5,088 SNP)搭配 raw dosage、cov_core_family 與 Stacking 為內部保留測試集中整體表現最佳之組合,其 AUC 為 0.8987、Accuracy 為 0.8337、Balanced Accuracy 為 0.8225、Sensitivity 為 0.8024、Specificity 為 0.8426、F1-score 為 0.6798、MCC 為 0.5834。SNP3000 搭配 raw dosage、cov_core_family 與 Stacking 之 AUC 為 0.8571、Balanced Accuracy 為 0.7809,顯示在減少候選 SNP 特徵後仍可保留相當程度之分類能力。於固定 SNP3000、Logistic Regression、age_sex 與相同 train-OOF threshold 規則下,10-bin score vector 將特徵數由 3,002 降至 32,而 Balanced Accuracy 由 0.7661 降至 0.7559,顯示其具有大幅降維之可行性。 綜合而言,本研究建立一套由親屬群組切分、train-only GRM mixed model GWAS、候選 SNP 證據分層、SNP representation、協變量整合、多模型比較與 SNP-to-gene 註解所構成之可追溯流程。研究結果支持此流程於臺灣族群憂鬱症病例與嚴格健康對照分類之內部方法學可行性;惟目前結果仍屬研究性風險分類,尚未完成外部獨立驗證,不宜直接解讀為個人未來發病預測或臨床診斷工具。;Major depressive disorder (MDD) is a heterogeneous and polygenic psychiatric disorder influenced by genetic, environmental, lifestyle, and psychosocial factors. Most genomic studies of depression have been conducted in populations of European ancestry, whereas genomic risk classification studies focused on the Taiwanese population remain limited. This study therefore developed a genomic case-control classification pipeline for MDD by integrating genome-wide association study (GWAS) and machine learning using data from the TWB (TWB). MDD cases and strict healthy controls were established from TWB phenotype data. Genotype quality control, linkage disequilibrium pruning, kinship estimation, and genomic relationship matrix (GRM) construction were performed. A family-aware split was applied so that genetically related individuals were not assigned to both training and testing sets. Mixed model GWAS, candidate SNP selection, feature ranking, and preprocessing were conducted using the training set only. A total of 5,088 candidate SNPs were identified at GWAS P < 1 × 10⁻² and used as the candidate feature universe. The 5,088 candidate SNPs were further stratified into a stable biological core (1,196 SNPs), an extended support layer (1,804 SNPs), and a polygenic background (2,088 SNPs) based on signal strength, effect-direction consistency, cross-validation stability, and resampling stability. SNP100, SNP500, SNP1000, SNP2000, SNP3000, and All-SNP pools were evaluated. Raw SNP dosage and score-vector representations, age_sex and cov_core_family covariate settings, and seven classifiers (Logistic Regression, Random Forest, XGBoost, LightGBM, CatBoost, Soft Voting, and Stacking) were compared. The All-SNP model using 5,088 raw SNP features, cov_core_family covariates, and Stacking achieved the highest performance in the internal hold-out test set, with an AUC of 0.8987, Accuracy of 0.8337, Balanced Accuracy of 0.8225, Sensitivity of 0.8024, Specificity of 0.8426, F1-score of 0.6798, and MCC of 0.5834. The SNP3000 raw-dosage model with cov_core_family and Stacking achieved an AUC of 0.8571 and Balanced Accuracy of 0.7809. Under a fixed SNP3000, Logistic Regression, age_sex, and train-OOF threshold setting, 10-bin score vector reduced the feature count from 3,002 to 32 while Balanced Accuracy decreased from 0.7661 to 0.7559. In summary, this study developed a traceable genomic classification pipeline integrating family-aware splitting, train-only GRM mixed model GWAS, candidate SNP evidence stratification, SNP representation, covariate integration, multi-model comparison, and SNP-to-gene annotation. The findings support the internal methodological feasibility of classifying MDD cases and strict healthy controls in a Taiwanese population. External validation is still required, and the current model should not be interpreted as a clinical diagnostic tool or a validated predictor of future disease onset.