# A Deep Learning Approach to Classify AI-Generated and Human-Written Texts
## 5 Discussion
### Results Comparison  
Table 2 demonstrates that the 20-epoch model consistently outperforms the 50-epoch model in terms of FI Score and test accuracy. This performance gap validates the effectiveness of our initial model design, which prioritized a reduced regularization strength and a longer training period. These choices contributed to superior generalization and a balanced trade-off between precision and recall for both AI-generated and human-authored text, reinforcing the robustness of our approach. The incorporation of internal baselines further strengthens the credibility of these findings, underlining the innovative nature of our method. Table 3 outlines the configuration of the 10-epoch model, where several key hyperparameters were deliberately modified to assess their influence on learning capacity and  
Figure 9: Test 4 training loss validation. \begin{table}
\begin{tabular}{l l l} \hline \hline
**Model Features** & **20-Epoch Model** & **20-Epoch Model** \\ \hline Patch size & 128 & 128 \\ Embedding size & 300 & 300 \\ Regularization (L1, L2) & 0.0001 & 0.0001 \\ Dropout rate & 20\% & 20\% \\ Test data ratio & 30\% & 60\% \\ Model’s test accuracy & 97.28\% & 99.89\% \\ AI F1 Score & 98\% & 91\% \\ Human F1 Score & 97\% & 90\% \\ \hline \hline \end{tabular}
\end{table} 
Table 5: Test 4 results. overall performance. The embedding size was lowered from 300 to 100, limiting the model's ability to capture complex semantic relationships. A smaller embedding dimension restricts the available representational space, reducing the model's ability to discern intricate patterns and meaningful context within the training data. The regularization strength was elevated from 0.0001 to 0.001 (L1, L2), introducing a stronger penalty for large weights. While this can help control overfitting, it also reduces the model's flexibility, potentially restricting its capacity to learn nuanced features from the data. The dropout rate was increased from 20% to 40%. Although dropout is an effective mechanism to prevent overfitting by randomly omitting neurons during training, an excessively high dropout rate can disrupt learning by eliminating too much critical information, leading to fragmented learning and weakened model coherence. In contrast, the 20-epoch model exhibited superior performance in test 3, benefiting from its larger number of LSTM units (128) and a more expansive embedding size (300). These parameters significantly enhanced the model's representational capacity, enabling it to effectively capture complex semantic and sequential dependencies within the text. This configuration allowed the 20-epoch model to extract richer contextual insights, resulting in more precise and reliable classifications. Collectively, these results underscore the importance of carefully tuning hyperparameters to achieve optimal performance, balancing model complexity, regularization, and expressive power to enhance both accuracy and generalization. This study effectively demonstrated the potential of LSTM models for detecting Turkish AI-generated academic writing, providing critical insights into how the model configuration impacts its performance and generalization. By systematically adjusting epoch count, embedding size, dropout rate, and regularization, we identified the optimal settings that significantly enhance detection accuracy. Specifically, the model trained with 20 epochs, a larger embedding size (300), and a lower regularization coefficient (0.0001) outperformed its counterparts, achieving better generalization and reduced overfitting. In contrast, the 50-epoch model, despite its higher training accuracy, exhibited signs of overfitting, as reflected in the widening gap between training and validation loss. Moreover, our findings underscore the critical balance between model complexity and generalization. While increasing complexity can improve learning, it also increases the risk of overfitting.