Skip to Content
AI in EducationAI in Education
  • Article
  • Open Access

9 March 2026

19 Pages

Robust Deep Knowledge Tracing with Out-of-Distribution Detection

and
1
School of Computer Science, Northwestern Polytechnical University, Xi’an 710129, China
2
Big Data Storage and Management MIIT Lab, Xi’an 710129, China
*
Author to whom correspondence should be addressed.

Abstract

Modeling the temporal dynamics of student learning is a central goal in educational data mining. Deep Knowledge Tracing (DKT) has emerged as a key approach, yet existing models are highly sensitive to out-of-distribution (OOD) inputs, such as those arising from curriculum changes, new assessment formats, or behavioral noise, which severely degrade predictive reliability. To address this challenge, we propose Energy-Based Out-of-Distribution Deep Knowledge Tracing (EB-OOD DKT), a unified framework that integrates energy-based uncertainty estimation and contrastive representation learning within a transformer-based DKT architecture. The model computes energy scores via the negative log-sum-exponential of prediction logits, serving as confidence indicators for detecting OOD inputs during inference. Additionally, an InfoNCE-based contrastive loss enhances representation robustness by aligning in-distribution samples and separating OOD cases in latent space. Temporal and behavioral context features, such as normalized response intervals and cumulative attempt counts, are incorporated to enrich cognitive-behavioral modeling. Experiments on four public educational datasets demonstrate consistent improvements in prediction accuracy and OOD detection. EB-OOD DKT provides a promising approach for more reliable student modeling across educational platforms with different content distributions.

Article Metrics

Citations

Article Access Statistics

Multiple requests from the same IP address are counted as one view.