Knowledge tracking method and device based on attention mechanism embedding and forgetting curve integration
By introducing attention mechanism and forgetting curves into the knowledge tracking model, combined with the three-parameter model of project response theory, the problems of insufficient interpretability, forgetting phenomena and guessing behaviors in the existing model are solved, and higher prediction accuracy and reliability are achieved.
Patent Information
- Application Number
- CN202510110402.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-23
- Publication Date
- 2025-05-16
AI Technical Summary
The existing deep learning-based knowledge tracking model has problems such as insufficient interpretability and insufficient consideration of forgetting phenomena and guessing behavior, which affects the accuracy of prediction results.
The knowledge tracking method based on attention mechanism embedding and forgetting curve integration is adopted, and students' knowledge state matrix is updated by transforming problems and knowledge concepts into vector forms, using attention mechanisms to calculate the weight of knowledge concepts, and using forgetting curves to evaluate the forgetting rate and time interval of knowledge concepts. Combining students' knowledge status, guess coefficient and problem difficulty, a three-parameter model of project reaction theory is used to predict the probability of students answering questions correctly.
It improves the prediction accuracy and interpretability of the knowledge tracking model, significantly improves the accuracy and reliability of the prediction of answering results, and can more effectively capture the dynamic changes in students' knowledge state.
Smart Images

Figure CN120012825A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of combining deep learning with smart education, and in particular to a knowledge tracking method and device based on attention mechanism embedding and forgetting curve integration. Background Art
[0002] Knowledge tracing (KT) refers to building a model to simulate students' learning status and predict their future performance by analyzing their behavior in answering questions. Traditional knowledge tracing models are mainly divided into three categories: based on Bayesian networks, based on Markov decision processes, and based on machine learning. However, these traditional methods have several limitations: 1. They ignore the dynamic factors in the learning process, such as differences in learning benefits, guessing behavior, and forgetting phenomena; 2. The model is not interpretable enough, and it is difficult to understand the causes of the prediction results; 3. The generalization ability is limited, and it is difficult to adapt to diverse learning scenarios.
[0003] In order to overcome these limitations, researchers began to explore knowledge tracing models based on deep learning, such as DKT (Deep Knowledge Tracing), DKVMN (Dynamic Key-Value Memory Network), AKT (Attentive Knowledge Tracing), etc. Deep learning models can automatically learn the complex relationship between students' answering behavior and knowledge status, and show higher prediction accuracy and stronger generalization ability. Despite this, current deep learning models still face some challenges: 1. Insufficient interpretability: The existing models have poor interpretability in the learning and answering process, and the model structure is complex, making it difficult to understand its prediction mechanism; 2. The forgetting phenomenon is not fully considered: Many models fail to fully incorporate the impact of students' forgetting on their knowledge status, which leads to the loss of accuracy of the prediction results; 3. Guessing behavior is not fully considered: Students may make guesses when answering questions, and existing models rarely take guessing factors into consideration, which affects the accuracy of the prediction results. Summary of the invention
[0004] In view of the problems that the current knowledge tracking model based on deep learning has insufficient interpretability and does not fully consider the forgetting phenomenon and guessing behavior, the present invention proposes a knowledge tracking method and device based on attention mechanism embedding and forgetting curve integration, aiming to improve the prediction accuracy of the knowledge tracking model and enhance its interpretability.
[0005] To achieve the above object, the present invention provides the following technical solutions:
[0006] In a first aspect, the present invention provides a knowledge tracking method based on attention mechanism embedding and forgetting curve integration, comprising the steps of:
[0007] Acquire problems and knowledge concepts corresponding to said problems;
[0008] Perform embedding vector retrieval based on the question and the knowledge concept to obtain a question embedding vector and a knowledge concept embedding vector; use an attention mechanism to perform calculation based on the question embedding vector to obtain a weight of the knowledge concept corresponding to the question;
[0009] Using the forgetting curve, calculating according to the knowledge concept embedding vector and the time vector, obtaining the interval time and the forgetting rate corresponding to the knowledge concept, and using the interval time and the forgetting rate to update the knowledge state matrix of the specific student;
[0010] Calculating based on the updated knowledge state matrix of the specific student, the problem embedding vector and the weight of the knowledge concept and the pre-constructed item response theory three-parameter model to obtain a prediction result corresponding to the specific problem of the specific student;
[0011] The knowledge state matrix of the specific student is further updated according to the specific question and the answer to the question, the knowledge state matrix of the specific student and the weight of the knowledge concept corresponding to the question.
[0012] In a second aspect, the present invention provides a knowledge tracking device based on attention mechanism embedding and forgetting curve integration, comprising:
[0013] A question database, which is used to obtain questions and knowledge concepts corresponding to the questions;
[0014] An embedding representation module is used to retrieve an embedding vector according to the question and the knowledge concept to obtain a question embedding vector and a knowledge concept embedding vector, and use an attention mechanism to calculate according to the question embedding vector to obtain a weight of the knowledge concept corresponding to the question;
[0015] A forgetting quantification module is used to use a forgetting curve to calculate according to the knowledge concept embedding vector and the time vector to obtain the interval time and forgetting rate corresponding to the knowledge concept, and use the interval time and forgetting rate to update the knowledge state matrix of a specific student;
[0016] An answer prediction module is used to calculate based on the updated knowledge state matrix of the specific student, the weight of the knowledge concept corresponding to the question and the pre-constructed item response theory three-parameter model to obtain a prediction result corresponding to the specific question of the specific student;
[0017] The knowledge status updating module is used to further update the knowledge status matrix of the specific student according to the specific question and the answer to the question, the knowledge status matrix of the specific student and the weight of the knowledge concept corresponding to the question.
[0018] In a third aspect, the present invention further provides an electronic device, including a processor and a memory;
[0019] The memory is used to store programs;
[0020] The processor executes the program to implement the method described above.
[0021] In a fourth aspect, the present invention further provides a computer-readable storage medium, wherein the storage medium stores a program, and the program is executed by a processor to implement the method described above.
[0022] In a fifth aspect, the present invention further provides a computer program product or a computer program, the computer program product or the computer program comprising computer instructions, the computer instructions being stored in a computer-readable storage medium. A processor of a computer device can read the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the above method.
[0023] Compared with the prior art, the present invention has the following beneficial effects: the present invention converts questions and knowledge concepts into vector form to more accurately capture information in the learning process. The attention mechanism is used to calculate the weight of knowledge concepts when students answer questions, with special attention paid to knowledge concepts closely related to the current question. Subsequently, based on the forgetting curve principle, the forgetting rate and time interval of knowledge concepts related to the current question are evaluated, and the student's knowledge state matrix is updated accordingly to simulate the dynamic process of knowledge forgetting. Furthermore, the three-parameter model of item response theory is used to predict the probability of students answering questions correctly, combining the student's knowledge state, guessing coefficient and question difficulty, taking the student's ability parameter, question difficulty and guessing coefficient into consideration to improve the accuracy of the prediction. Finally, the student's knowledge state matrix is updated again according to the student's answer and question characteristics, and the forgetting mechanism is used to simulate the knowledge forgetting process in a more realistic way, thereby improving the model's real-world adaptability.
[0024] In the experimental verification, the present invention uses four real data sets to test the KVFKT model. The experimental results show that the KVFKT model performs better in tracking students' knowledge status and surpasses the current most advanced models in performance. For example, on the ASSISTments2012 data set, the AUC (Area Under the Curve) value of the KVFKT model is 9.5% higher than that of the SAINT (Separated Self-Attentive Neural Knowledge Tracing) model.
[0025] The present invention effectively solves the problem of difficulty in capturing the dynamic changes in students' abilities in the field of knowledge tracking, and significantly improves the accuracy and reliability of the prediction of answer results. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings required for use in the embodiments are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0027] Figure 1 A schematic diagram of a flow chart of a knowledge tracking method based on attention mechanism embedding and forgetting curve integration according to an embodiment of the present invention;
[0028] Figure 2 It is a schematic diagram of the structure of a knowledge tracking device based on attention mechanism embedding and forgetting curve integration according to an embodiment of the present invention;
[0029] Figure 3 It is a structural schematic diagram of an embedded representation module according to an embodiment of the present invention;
[0030] Figure 4 Schematic diagram of the structure of a forgetfulness quantization module according to an embodiment of the present invention;
[0031] Figure 5 A schematic diagram of the structure of an answer prediction module according to an embodiment of the present invention;
[0032] Figure 6 Schematic diagram of the structure of the knowledge status update module of the embodiment of the present invention. DETAILED DESCRIPTION
[0033] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0034] Example:
[0035] It should be noted that the terms "including" and "having" and any variations of the embodiments of the present invention are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0036] Figure 1 Schematic diagram of the flow of the knowledge tracking method based on attention mechanism embedding and forgetting curve integration in an embodiment of the present invention. Figure 1 As shown, the knowledge tracking method based on attention mechanism embedding and forgetting curve integration provided by the embodiment of the present invention may specifically include the following steps:
[0037] Step 100, obtaining a question and a knowledge concept corresponding to the question.
[0038] During the specific execution, the problem and the knowledge concepts corresponding to the problem are obtained, wherein the problem is the basic object processed by the embodiment of the present invention. For example, in a mathematical knowledge tracking scenario, the problem may be a specific math problem, such as "solving a quadratic equation". The knowledge concept is a knowledge element related to the problem. In mathematical knowledge tracking, the knowledge concept may include "the definition of a quadratic equation", "the formula for finding roots", "the factorization method", etc.
[0039] Step 200, performing embedding vector retrieval based on the question and the knowledge concept to obtain a question embedding vector and a knowledge concept embedding vector, and using an attention mechanism to perform calculations based on the question embedding vector to obtain a weight of the knowledge concept corresponding to the question.
[0040] When specifically executed, embedding vector retrieval is performed based on the question and the knowledge concept to obtain the question embedding vector and the knowledge concept embedding vector, which specifically includes: sub-step 201, setting the question input and the knowledge concepts corresponding to the problem Among them, q t is represented as the problem input, t is the time step, R is the set of real numbers, d q represents the number of questions in the question set, d c Represents the number of knowledge concepts in the knowledge concept set. Introducing the embedding matrix of the pre-trained problem and the embedding matrix of knowledge concepts d k is the dimension of the problem embedding vector, d m is the dimension of the knowledge concept embedding vector. t and c t The question embedding vector is obtained by embedding matrices Q and C respectively. and knowledge concept embedding vector Where Q t Indicates q t The embedding vector is a d k dimensional real vector, C t Demonstrate knowledge concept t The embedding vector is a d mdimensional real number vector. Using the attention mechanism, the weight of the knowledge concept corresponding to the question is obtained according to the question embedding vector. Specifically, sub-step 202, according to the question embedding vector Q t Querying the key-value store matrix Get each key-value storage unit The attention weight is implemented by embedding the question into the vector Q t With each key-value storage unit The inner product is activated by the Softmax function to obtain each key-value storage unit The attention weight ω t,u , the expression is Among them, u represents the u-th key-value storage unit, and t represents the time step.
[0041] It can be seen that this embodiment embeds the problem and knowledge concepts into a unified vector space through the embedding matrix, realizes the integration of exercise and concept features, provides a standardized representation for subsequent processing, and facilitates the model to process and calculate information. At the same time, the attention mechanism can automatically calculate the attention weight of the knowledge concept according to the problem, highlighting the important knowledge concepts related to the current problem, making the model pay more attention to key information, and improving the ability to capture the relationship between students' knowledge status and problems, thereby laying the foundation for more accurate knowledge tracking and prediction.
[0042] Step 300, using the forgetting curve, calculates according to the knowledge concept embedding vector and the time vector to obtain the interval time and forgetting rate corresponding to the knowledge concept, and uses the interval time and forgetting rate to update the knowledge state matrix of the specific student.
[0043] When specifically executed, the following sub-steps 301-305 may be specifically included:
[0044] Sub-step 301: embedding vector C according to the knowledge concept t Multiply the time vector T by a dot to get the intermediate vector Ω t , that is, Ω t =C t T;
[0045] Sub-step 302: Based on the x-th row vector in the forgetting matrix MF With the intermediate vector Ω t Execute the G(·) function to get the xth row vector of the updated forget matrix The specific form of the G(·) function is T is the current timestamp information; in the G(·) function, if the second parameter is greater than the first parameter and less than 0.5×T, G(·) takes the second parameter, otherwise it takes the first parameter; the intermediate vector Ω t and the forgetting matrix M F The x-th row vector in Substituting into the G(·) function, it means that if the intermediate vector is less than 0.5×T, it is assumed that the problem does not contain the knowledge concept represented by the vector unit, so the relevant elements in the forgetting matrix will not be updated, otherwise the forgetting matrix M will be updated. F The x-th row vector Therefore, after executing the G(·) function, the x-th row vector of the updated forgetting matrix can be obtained:
[0046] Sub-step 303: Based on the x-th row vector of the updated forgetting matrix and the xth row vector of the forgetting matrix Subtract and get the interval time τ corresponding to the knowledge concept j j ;Right now: is the element of the xth row and yth column of the updated forget matrix, is the element in the xth row and yth column of the original forget matrix.
[0047] Sub-step 304: Calculate the forgetting rate λ corresponding to the knowledge concept j according to the interval time corresponding to the knowledge concept and the forgetting curve formula j , where the forgetting curve formula is S is the forgetting parameter;
[0048] Sub-step 305: According to the forgetting rate λ corresponding to the knowledge concept j j and the original value matrix M V The value matrix of student i for knowledge concept j Perform element-by-element multiplication and activate the Softmax function to obtain the updated value matrix of student i for knowledge concept j Right now
[0049] It can be seen that the influence of time factors on students' knowledge forgetting is taken into account. By calculating the time interval and forgetting rate, the decay process of students' knowledge over time is more realistically simulated, making the model's prediction of students' knowledge status more in line with the actual situation. The updated forgetting matrix and value matrix can dynamically reflect the forgetting of students' knowledge, providing a more accurate basis for subsequent answer prediction and knowledge status update, and improving the adaptability and accuracy of the model.
[0050] Step 400, performing calculations based on the updated knowledge state matrix of the specific student, the weights of the knowledge concepts corresponding to the question, and the pre-constructed item response theory three-parameter model to obtain a prediction result of the specific student corresponding to the specific question;
[0051] When specifically executed, the following sub-steps 401-404 may be specifically included:
[0052] Sub-step 401: According to the weight ω of the knowledge concept corresponding to the problem t,u with the updated value matrix at time step t Multiply and get the read vector r t ,Right now in, is the updated value matrix of student i at time step t
[0053] Sub-step 402: Read vector r t and the question embedding vector Q t Concatenate and activate the tanh function in the fully connected layer to obtain the feature vector f t ,Right now Among them, W f is the weight matrix, b f is the bias vector;
[0054] Sub-step 403: According to the feature vector f t Parameterize and activate through tanh function to get the student's ability parameter θ ta , according to the question embedding vector Q t Parameterize and activate through tanh function to get the problem difficulty β a , the student's ability parameter θ ta and problem difficulty β a After the tanh activation function, the output value range is (-1,1), and the expressions are: θ ta =tanh(W θ f t +b θ ), β a =tanh(W β Q t +b β ), where W θ and W β is the weight matrix, b θ and b β is the bias vector;
[0055] Sub-step 404: Based on the student's ability parameter θ ta , Problem Difficulty β aand the calculated guess coefficient g a Substitute into the pre-built item response theory three-parameter model for calculation. The item response theory three-parameter model is specifically: D is a constant, usually set to 1.702, so as to obtain the prediction result P for a specific student corresponding to a specific question. t , that is, P t =g a +(1-g a )Softmax(3.0*θ ta -β a ), prediction result P t is the probability that the student answers the question correctly.
[0056] In the above embodiment, the guess coefficient g a Calculated according to the following steps:
[0057] Sub-step 411: Based on the average time to answer question a and the time at which student i answers question a i,a Subtract and take the absolute value to obtain the intermediate value; Sub-step 412: According to the intermediate value and the asymptotic value of the ICC project curve of problem a Add them together and activate them through the Softmax function to get the guess coefficient g a ,Right now Guess coefficient g a After the Softmax function, the output value range is (0, 1).
[0058] Step 500, further updating the knowledge state matrix of the specific student according to the specific question and the answer to the question, the knowledge state matrix of the specific student and the weight of the knowledge concept corresponding to the question.
[0059] It can be seen that by reading the vector, the student's knowledge status and the information of the current question are integrated, and the generated feature vector can comprehensively consider multiple factors, providing rich feature representation for subsequent parameter calculation. Calculating the student's ability, question difficulty and guessing coefficient separately, and integrating the IRT model for prediction, can comprehensively consider various factors that affect students' answers, improve the accuracy and reliability of predicting the probability of students answering questions correctly, and provide valuable reference for educational evaluation and personalized teaching.
[0060] When specifically executed, the following sub-steps 501-503 may be specifically included:
[0061] Sub-step 501: perform embedding vector retrieval based on the specific question and the answer to the question to obtain the intermediate vector Z t ; Among them, the specific question and the answer to the question (q t ,yt ) is converted to ζ, where q t Indicates the problem, y t Indicates the answer to the question, y t =1 means the answer is correct, y t =0 means the answer is wrong, the converted expression is Where n represents the total number of questions in the relevant dataset, y t represents the situation of students answering questions at time t. Next, from the embedding matrix Retrieve the embedding vector Z of ζ from t , which represents the students’ knowledge growth after learning the knowledge concept KC.
[0062] Sub-step 502: According to the embedding vector Z t Get the added vector a respectively t and the erasure vector e t ; Among them, for the embedding vector Z t After parameterization, the erasure vector e is calculated through the fully connected layer t , used to clear part of the memory, the expression is: e t =σ(W e Z t +b e ). After the embedding vector is parameterized, the added vector is calculated by the tanh activation function Used to add new information, the expression is a t =tanh(W a Z t +b a ).
[0063] Sub-step 503: using the addition vector a t , erase vector e t , the value matrix of student i and the attention weight ω t,u Further update the knowledge state matrix of a specific student. For the cells in the update value matrix, the expression is: in is the updated value matrix of student i at time step t in the forget quantization module, ω t,u is the attention weight in the embedding representation module.
[0064] It can be seen that state conversion and vector retrieval based on students' answer results can accurately capture the changing trend of students' knowledge status, especially the growth of knowledge, so that the model can timely reflect students' learning progress. By calculating the erase vector and add vector, and updating the value storage unit according to a specific update formula, the dynamic update of students' knowledge status is realized, so that the model can continuously track students' knowledge changes, provide real-time and accurate data support for subsequent learning analysis and intervention, and help improve the pertinence and effectiveness of education and teaching.
[0065] In the experimental stage, this embodiment selected four data sets for testing: ASSISTments2012, EdNet, NeurIPS, and FSAI-FltoF3, and compared the model established by the method provided in this embodiment with seven existing knowledge tracking models, including: DKT, DKVMN, AKT, SAKT, SAINT, LFBKT, and AT-DKT. In terms of parameter configuration, this embodiment uses the Adam optimizer for model training, the learning rate is set to 0.003, and the batch size is 32. The length of all sequences is set to 200. In addition to the FSAI-F1toF3 data set, this embodiment repeated the training and evaluation process five times.
[0066] The experimental results are as follows: In terms of evaluating the prediction of student performance, this embodiment uses AUC (Area Under Curve), ACC (Accuracy) and RMSE (Root Mean Square Error) as the main evaluation indicators. The results show that the KVFKT model surpasses other existing deep learning knowledge tracking models in all test data sets and evaluation indicators. When conducting ablation studies, this embodiment removes various components in the model and evaluates their specific impact on the overall performance. The study found that the forgetting matrix, guessing coefficient, difficulty coefficient and three-parameter logistic (3PL) module all have a significant positive impact on model performance. In response to the interpretability challenge of the three-parameter item response theory (IRT), this embodiment proves that the KVFKT model can capture more reasonable and detailed changes in knowledge status by visualizing the student's ability level, guessing coefficient and the probability of correctly answering the next knowledge component (KC) during the learning process. In the study of the hyperparameters of the forgetting cycle, this embodiment adjusts the forgetting cycle parameters to observe the prediction results of the KVFKT model. The research results show that the KVFKT model can effectively measure students' average forgetting cycle, and the modeling of forgetting behavior significantly improves the predictive performance of the model.
[0067] Figure 2 It is a schematic diagram of the structure of a knowledge tracking device based on attention mechanism embedding and forgetting curve integration according to an embodiment of the present invention; Figure 3It is a structural schematic diagram of an embedded representation module according to an embodiment of the present invention; Figure 4 Schematic diagram of the structure of a forgetfulness quantization module according to an embodiment of the present invention; Figure 5 A schematic diagram of the structure of an answer prediction module according to an embodiment of the present invention; Figure 6 Schematic diagram of the structure of the knowledge status update module of the embodiment of the present invention.
[0068] like Figures 2 to 5 As shown, based on the same inventive concept, an embodiment of the present invention further provides a knowledge tracking device based on attention mechanism embedding and forgetting curve integration, including:
[0069] A question database, which is used to obtain questions and knowledge concepts corresponding to the questions;
[0070] An embedding representation module is used to retrieve an embedding vector according to the question and the knowledge concept to obtain a question embedding vector and a knowledge concept embedding vector, and use an attention mechanism to calculate according to the question embedding vector to obtain a weight of the knowledge concept corresponding to the question;
[0071] A forgetting quantification module is used to use a forgetting curve to calculate according to the knowledge concept embedding vector and the time vector to obtain the interval time and forgetting rate corresponding to the knowledge concept, and use the interval time and forgetting rate to update the knowledge state matrix of a specific student;
[0072] An answer prediction module is used to calculate based on the updated knowledge state matrix of the specific student, the weight of the knowledge concept corresponding to the question and the pre-constructed item response theory three-parameter model to obtain a prediction result corresponding to the specific question of the specific student;
[0073] The knowledge status updating module is used to further update the knowledge status matrix of the specific student according to the specific question and the answer to the question, the knowledge status matrix of the specific student and the weight of the knowledge concept corresponding to the question.
[0074] Since the device is a device corresponding to the knowledge tracking method based on attention mechanism embedding and forgetting curve integration of an embodiment of the present invention, and the principle of solving the problem by the device is similar to that of the method, the implementation of the device can refer to the implementation process of the above-mentioned method embodiment, and the repeated parts will not be repeated.
[0075] Based on the same inventive concept, an embodiment of the present invention also provides an electronic device, comprising a processor and a memory, wherein the memory stores at least one instruction, at least one program, a code set or an instruction set, and the at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by the processor to implement the knowledge tracking method based on attention mechanism embedding and forgetting curve integration as described above.
[0076] It is understood that the memory may include a random access memory (RAM) or a read-only memory (ROM). Optionally, the memory includes a non-transitory computer-readable storage medium. The memory may be used to store instructions, programs, codes, code sets, or instruction sets. The memory may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function, instructions for implementing the above-mentioned various method embodiments, etc.; the data storage area may store data created according to the use of the server, etc.
[0077] The processor may include one or more processing cores. The processor uses various interfaces and lines to connect the various parts of the entire server, and executes various functions of the server and processes data by running or executing instructions, programs, code sets or instruction sets stored in the memory, and calling data stored in the memory. Optionally, the processor can be implemented in at least one hardware form of digital signal processing (DSP), field programmable gate array (FPGA), and programmable logic array (PLA). The processor can integrate one or a combination of a central processing unit (CPU) and a modem. Among them, the CPU mainly processes the operating system and application programs; the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor, but implemented separately through a chip.
[0078] Since the electronic device is the electronic device corresponding to the knowledge tracking method based on attention mechanism embedding and forgetting curve integration of the embodiment of the present invention, and the principle of solving the problem by the electronic device is similar to that of the method, the implementation of the electronic device can refer to the implementation process of the above-mentioned method embodiment, and the repeated parts will not be repeated.
[0079] Based on the same inventive concept, an embodiment of the present invention also provides a computer-readable storage medium, in which at least one instruction, at least one program, a code set or an instruction set is stored, and the at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by a processor to implement the knowledge tracking method based on attention mechanism embedding and forgetting curve integration as described above.
[0080] Those skilled in the art can understand that all or part of the steps in the various methods of the above embodiments can be completed by instructing related hardware through a program, and the program can be stored in a computer-readable storage medium, and the storage medium includes a read-only memory (ROM), a random access memory (RAM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), a one-time programmable read-only memory (OTPROM), an electronically erasable rewritable read-only memory (EEPROM), a compact disc (CD-ROM) or other optical disc storage, magnetic disk storage, magnetic tape storage, or any other computer-readable medium that can be used to carry or store data.
[0081] Since the storage medium is the storage medium corresponding to the knowledge tracking method based on attention mechanism embedding and forgetting curve integration of an embodiment of the present invention, and the principle of solving the problem by the storage medium is similar to that of the method, the implementation of the storage medium can refer to the implementation process of the above-mentioned method embodiment, and the repeated parts will not be repeated.
[0082] In some possible implementations, various aspects of the method of the embodiment of the present invention may also be implemented in the form of a program product, which includes a program code. When the program product is run on a computer device, the program code is used to enable the computer device to execute the steps of the knowledge tracking method based on attention mechanism embedding and forgetting curve integration according to various exemplary embodiments of the present application described above in this specification. Among them, the executable computer program code or "code" for executing each embodiment can be written in a high-level programming language such as C, C++, C#, Smalltalk, Java, JavaScript, Visual Basic, structured query language (e.g., Transact-SQL), Perl, or in various other programming languages.
[0083] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, a plurality of steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.
[0084] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, without contradiction.
[0085] The above embodiments are only for illustrating the technical concept and features of the present invention, and their purpose is to enable ordinary technicians in the field to understand the content of the present invention and implement it accordingly, and they cannot be used to limit the protection scope of the present invention. Any equivalent changes or modifications made based on the essence of the content of the present invention should be included in the protection scope of the present invention.
Claims
1. A knowledge tracking method based on attention mechanism embedding and forgetting curve integration, characterized in that: Includes steps: Obtaining a question and a knowledge concept corresponding to the question, performing embedding vector retrieval based on the question and the knowledge concept, and obtaining a question embedding vector and a knowledge concept embedding vector; Using the attention mechanism, calculation is performed based on the question embedding vector to obtain the weight of the knowledge concept corresponding to the question; Using the forgetting curve, calculating according to the knowledge concept embedding vector and the time vector, obtaining the interval time and the forgetting rate corresponding to the knowledge concept, and using the interval time and the forgetting rate to update the knowledge state matrix of the specific student; Calculating based on the updated knowledge state matrix of the specific student, the problem embedding vector and the weight of the knowledge concept and the pre-constructed item response theory three-parameter model to obtain a prediction result corresponding to the specific problem of the specific student; The knowledge state matrix of the specific student is further updated according to the specific question and the answer to the question, the knowledge state matrix of the specific student and the weight of the knowledge concept corresponding to the question.
2. The knowledge tracking method based on attention mechanism embedding and forgetting curve integration according to claim 1 is characterized in that: Performing embedding vector retrieval based on the question and the knowledge concept to obtain the question embedding vector and the knowledge concept embedding vector specifically includes: Set question input and the knowledge concepts corresponding to the problem Among them, q t is represented as the problem input, t is the time step, R is the set of real numbers, d q represents the number of questions in the question set, d c Represents the number of knowledge concepts in the knowledge concept set; introduces the embedding matrix of the pre-trained problem and the embedding matrix of knowledge concepts d k is the dimension of the problem embedding vector, d m is the dimension of the knowledge concept embedding vector; q t and c t The question embedding vector is obtained by embedding matrices Q and C respectively. and knowledge concept embedding vector Where Q t Indicates q t The embedding vector is a d k dimensional real vector, C t Demonstrate knowledge concept t The embedding vector is a d m -dimensional real vector.
3. The knowledge tracking method based on attention mechanism embedding and forgetting curve integration according to claim 2 is characterized in that: Using the attention mechanism, querying the key-value storage matrix according to the question embedding vector to obtain the weight of the knowledge concept corresponding to the question, specifically including: Embed the vector Q according to the problem t Querying the key-value store matrix Get each key-value storage unit The attention weight is implemented by embedding the question into the vector Q t With each key-value storage unit The inner product is activated by the Softmax function to obtain each key-value storage unit The attention weight ω t,u , where u represents the u-th key-value storage unit and t represents the time step.
4. The knowledge tracking method based on attention mechanism embedding and forgetting curve integration according to claim 2 is characterized in that: Using the forgetting curve, the interval time and forgetting rate corresponding to the knowledge concept are calculated according to the knowledge concept embedding vector and the time vector, and the pre-constructed knowledge state matrix of the specific student is updated using the interval time and forgetting rate, specifically including: According to the knowledge concept embedding vector C t Multiply the time vector T by a dot to get the intermediate vector Ω t ; According to the forgetting matrix The x-th row vector in With the intermediate vector Ω t Execute the G(·) function to get the xth row vector of the updated forget matrix Among them, the specific form of the G(·) function is T is the current timestamp information; According to the xth row and yth column element of the updated forget matrix and the element in the xth row and yth column of the forgetting matrix Subtract the corresponding elements to get the interval time τ corresponding to the knowledge concept j j , where j∈[1,d m ] indicates the range of the number of columns; According to the interval time τ corresponding to the knowledge concept j Calculate with the forgetting curve formula to get the forgetting rate λ corresponding to the knowledge concept j j , where the forgetting curve formula is S is the forgetting parameter; According to the forgetting rate λ corresponding to the knowledge concept j j and the original value matrix M V The knowledge state matrix of student i Perform element-by-element multiplication and activate the Softmax function to obtain the updated value matrix of student i for knowledge concept j 5. The knowledge tracking method based on attention mechanism embedding and forgetting curve integration according to claim 2 is characterized in that: The prediction result of the specific student corresponding to the specific question is obtained by calculating based on the updated knowledge state matrix of the specific student, the weight of the knowledge concept corresponding to the question and the pre-constructed item response theory three-parameter model, specifically including: According to the attention weight ω corresponding to the knowledge concept of the problem t,u with the updated value matrix at time step t Multiply and get the read vector r t , where t represents the time step; According to the read vector r t and the question embedding vector Q t Concatenate and activate through tanh function in the fully connected layer to get the feature vector f t ; According to the feature vector f t After parameterization, the student's ability parameter θ is obtained by activating the tanh function. ta , represents the student’s ability to answer question a at time step t; Embed the vector Q according to the question t After parameterization, the difficulty of the problem is obtained by activating the tanh function. a , indicating the difficulty of problem a; According to the student's ability parameter θ ta , Problem Difficulty β a and the calculated guess coefficient g a Substitute it into the pre-built three-parameter model of item response theory for calculation, and get the prediction result P corresponding to a specific question for a specific student. t .
6. The knowledge tracking method based on attention mechanism embedding and forgetting curve integration according to claim 5 is characterized in that: Guess coefficient g a Calculated according to the following steps: Based on the average answer time for question a and student i's answer time for question a at i,a The absolute value of the difference and the asymptotic value of the item characteristic curve ICC of question a Activate the Softmax function to get the guess coefficient g a .
7. The knowledge tracking method based on attention mechanism embedding and forgetting curve integration according to claim 4 is characterized in that: Further updating the knowledge state matrix of the specific student according to the specific question and the answer to the question, the knowledge state matrix of the specific student and the weight of the knowledge concept corresponding to the question, specifically including: According to the specific question and the answer to the question, the embedded vector is retrieved to obtain the intermediate vector Z t ; According to the intermediate vector Z t Get the added vector a respectively t and the erasure vector e t ; Using the addition vector a t , erase vector e t , the updated value matrix of student i and the attention weight ω t,u Further update the knowledge status matrix of a particular student.
8. A knowledge tracking device based on attention mechanism embedding and forgetting curve integration, characterized in that: include: A question database, which is used to obtain questions and knowledge concepts corresponding to the questions; An embedding representation module is used to retrieve an embedding vector according to the question and the knowledge concept to obtain a question embedding vector and a knowledge concept embedding vector, and use an attention mechanism to calculate according to the question embedding vector to obtain a weight of the knowledge concept corresponding to the question; A forgetting quantification module is used to use a forgetting curve to calculate according to the knowledge concept embedding vector and the time vector to obtain the interval time and forgetting rate corresponding to the knowledge concept, and use the interval time and forgetting rate to update the knowledge state matrix of a specific student; An answer prediction module is used to calculate based on the updated knowledge state matrix of the specific student, the weight of the knowledge concept corresponding to the question and the pre-constructed item response theory three-parameter model to obtain a prediction result corresponding to the specific question of the specific student; The knowledge status updating module is used to further update the knowledge status matrix of the specific student according to the specific question and the answer to the question, the knowledge status matrix of the specific student and the weight of the knowledge concept corresponding to the question.
9. An electronic device, characterized in that: The electronic device includes a processor and a memory, wherein the memory stores at least one instruction, at least one program, a code set or an instruction set, and the at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by the processor to implement the knowledge tracking method based on attention mechanism embedding and forgetting curve integration as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that: The storage medium stores at least one instruction, at least one program, a code set or an instruction set, and the at least one instruction, the at least one program, the code set or the instruction set are loaded and executed by the processor to implement the knowledge tracking method based on attention mechanism embedding and forgetting curve integration as described in any one of claims 1 to 7.
Citation Information
Cited By
Differential privacy knowledge tracking method and system considering forgetting factor, and medium
CN121883228A