# Knowledge Tracing Model and Student Profile Based on Clustering-Neural-Network
## 3 Experiment
### Setup  
Public datasets do not contain the question texts that are needed for the proposed scheme; thus, in this paper, real questions are collected and labeled from a university calculus textbook. In this dataset, a total of 715 questions are labeled by \(n\) graduate students of computer science over two months. Labels include question text, knowledge points, the relations between knowledge points, and other information. The real answer data of students come from our real admission collection of nearly 1000 students, and a total of 82,517 behavior data are collected. Then, according to the real data distribution, 3000 students' answering behaviors are simulated (See Figure 1). To evaluate the effectiveness of the proposed method, several related works are compared. For fairness, all models are tuned for optimal performance. The details are as follows:  
* DKT: The classical DKT model [17], in which the data embedding is based on the one-hot method. * EERNN: Exercise-Enhanced Sequential Modeling [15]--the improved DKT model, in which the data embedding is based on the bidirectional LSTM method. * R-DKT: Random Deep Knowledge Tracing--the clustered DKT model, in which the clustering algorithm is based on the random method. * B-KT: Bert Knowledge Tracing--the improved DKT model, in which the data embedding is based on the Bert method. * C-DKT, C-EERNN: Clustering Deep Knowledge Tracing and Clustering Exercise-Enhanced Sequential Modeling--the improved DKT models, in which the clustering idea is added to the basic models. * C-B-KT: The proposed scheme, which uses the idea of clustering based on B-KT. A qualified model for student performance prediction should have good results from both regression and classification perspectives. The output value is a continuous probability value, and regression indicators can be used to calculate the error of the continuous value. In this work, the sum of squares due to error (SSE) is used to evaluate the density of the cluster. The mean absolute error (MAE), the mean squared error (MSE), the root mean error (R2), and Root Mean Square Error (RMSE) are used to evaluate the error of the proposed methods. They are also used in other related work [15; 20]. The Area Under Curve (AUC), Recall, Precision, and F1-score are used to evaluate the accuracy of models. They are also used in other related works [21; 22; 23; 24; 25]. The calculation details are as shown in Table 2.  
The configuration of the proposed models is set as follows:  
Question embedding supplements. The words of the mathematical questions embedded in the question are different from the traditional ones. To preserve the mathematical semantics, a formula tool in the Spotlight mechanism is used to convert each formula into its TEX code feature [26]. Frame settings. The dimension of each embedded problem, \(d_{0}\), is set to 768; the dimension of the hidden state in the student embedding, \(d_{h}\), is set to 100; and the dimension of the dynamic matrix in the output layer, \(d_{K}\), is set to \(K\), which is equal to the number of knowledge points. Training settings. Initialize all parameters of C-B-KT, with the range of \(0.5\pm 0.1\). In addition, the _batch_ size is set to 32 and the dropout is set to 0.5 to prevent overfitting. Determine the optimal number of clusters. As for K-means, the number of clusters should be determined manually. This article uses the elbow method (an algorithm for calculating the optimal clustering number \(k\)) to determine the optimal number of clusters, as shown in Figure 4.  
In the results, when the number of clusters \(k\) increases, the samples are divided more finely and the degree of aggregation of each cluster increases, so SSE decreases. When \(k\) is less than the optimal number of clusters, an increase of \(k\) will significantly increase the degree of aggregation of each cluster and therefore decrease the SSE significantly.