Knowledge point semantic content-oriented online learning platform teaching resource classification method

By constructing a knowledge point-teaching resource interaction matrix and using deep learning models to extract features, the efficiency and accuracy problems of existing teaching resource classification methods are solved, efficient resource classification and recommendation are achieved, and resource utilization is improved.

CN118606793APending Publication Date: 2024-09-06CHANGSHU INSTITUTE OF TECHNOLOGY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410835781.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-26
Publication Date
2024-09-06

AI Technical Summary

Technical Problem

Existing teaching resource classification methods have problems such as inefficiency of manual classification, inability of coarse-grained classification to reflect resource content information, inability to effectively align text and visual features, and sparse interaction data between knowledge points and resources, resulting in difficulty in resource selection and low utilization.

Method used

An online learning platform classification method oriented to the semantic content of knowledge points is adopted. By constructing a knowledge point-teaching resource interaction matrix, the ChineseCLIP pre-training model and self-attention network are used to extract the text and image features of knowledge points and teaching resources, combined with cross-modal graphics and text. It uses a dynamic attention mechanism to learn the latent factor matrix of knowledge points and teaching resources, thereby achieving efficient classification.

Benefits of technology

It effectively solves the problem of resource sparseness, improves resource utilization and recommendation accuracy. By extracting and fusing voice and visual features, identifying key frame images, it enhances the interaction of image and text features, and improves the retrieval and recommendation effects of resources.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118606793A
    Figure CN118606793A
Patent Text Reader

Abstract

The invention discloses a knowledge point semantic content-oriented online learning platform teaching resource classification method, which comprises the following steps of: constructing a knowledge point-teaching resource interaction matrix, extracting a text embedding vector of a knowledge point based on a ChineseCLIP pre-training model, finely adjusting semantic features of the learning knowledge point based on a self-attention network, and classifying the knowledge point-teaching resource interaction matrix. Voice and visual feature variations of teaching resources are fused, videos, PPT and exercises are converted into text and image modal data by using a software tool, image features and text semantic features of the teaching resources are learned based on an image-text cross-modal attention mechanism, related teaching resources are searched based on knowledge point similarity and teaching resource similarity, and the teaching resources are displayed. The row vector and the column vector of the knowledge point-teaching resource interaction matrix are complemented, the potential factor matrix of the knowledge points and the potential factor matrix of the teaching resources are learned by using a gradient descent method, the knowledge point-teaching resource interaction matrix is reconstructed based on the potential characteristic matrix of the knowledge points and the teaching resources, and the probability that the teaching resources belong to the knowledge points is calculated.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to a teaching resource classification method, in particular to a teaching resource classification method for an online learning platform oriented to knowledge point semantic content. Background Art

[0002] In the era of digital education, a large number of excellent online learning platforms have emerged at home and abroad. Colleges and enterprises have spent a lot of manpower, material resources and financial resources to build a large amount of high-quality teaching resources, and they are constantly updating teaching resources every year. Faced with thousands of teaching resources, teachers and students are faced with the problem of information overload, that is, there are difficulties in resource selection. There is an urgent need for teaching resource retrieval, indexing and recommendation systems to help teachers and students more efficiently and accurately choose teaching resources that suit them, while also improving the utilization rate of teaching resources. Due to the huge scale of teaching resources, scientific and effective classification of digital learning resources is the basis for realizing intelligent retrieval, recommendation, indexing and data mining of teaching resources, which is of great value and significance to improving the utilization rate of teaching resources and promoting resource sharing.

[0003] At present, the classification of teaching resources is mainly based on the traditional literature classification standards of libraries or archives, which has the following problems: (1) Manual classification is time-consuming, labor-intensive and inefficient. The coarse-grained subject standard classification cannot reflect the specific content information contained in the resources, which is not conducive to the construction of teaching resources and retrieval recommendations for professional knowledge systems; (2) Teaching resources have the characteristics of long text information and little visual information change. How to effectively represent the learning text features and how to extract the key frames of teaching videos become difficult problems; (3) The text and visual features of teaching resources are located in different spaces, resulting in the inability to effectively align the complementary information of pictures and texts for the classification of teaching resources; (4) There is little interaction data between teaching resources and the knowledge points they contain, that is, there is a sparsity problem. How to use the similarity relationship between knowledge points and teaching resources becomes a challenge for the classification of teaching resources. To this end, we propose a teaching resource classification method for online learning platforms based on the semantic content of knowledge points. Summary of the invention

[0004] The purpose of the present invention is to provide a method for classifying teaching resources of an online learning platform oriented to the semantic content of knowledge points, so as to solve the problems raised in the above-mentioned background technology.

[0005] In order to solve the above technical problems, the present invention provides the following technical solutions: a method for classifying teaching resources of an online learning platform oriented to the semantic content of knowledge points, comprising the following steps:

[0006] Step 1: Extract knowledge points and teaching resources from the course outline of the online learning platform according to chapters, and organize n knowledge points into a set C, where C = {c1, c2, ..., c n}, mark l teaching resources as set B, B = {b1, b2, ..., b l}, construct the knowledge point-teaching resource interaction matrix X∈R n×l , if teaching resource b j ∈B contains knowledge point c i ∈C, where 1≤j≤l, 1≤i≤n, then X(c i ,b j )=1, otherwise X(c i ,b j )=0;

[0007] Step 2: Extract the text embedding vector of the knowledge point based on the ChineseCLIP pre-trained model, and fine-tune the semantic features of the knowledge point based on the self-attention network;

[0008] Step 2-1, extract the text embedding vector of the knowledge point based on the ChineseCLIP pre-trained model of the segmentation mechanism;

[0009] Assume knowledge point c i The text information is c i .text, with a length of 77 characters as a standard, the text information c i .text is divided into n1 segments, and the text embedding vector is extracted from each segment using the ChineseCLIP pre-trained model

[0010] Where 1≤r1≤n1,

[0011] where c i .text.r1 is knowledge point c i The r1th paragraph of text information, d0 is the dimension of the text embedding vector, and the average value of the n1th paragraph of text embedding vector is calculated as the knowledge point c i The text embedding vector of

[0012]

[0013] Step 2-2, fine-tune the text semantic features of the learning knowledge points based on the self-attention network;

[0014] Assume knowledge point c i The text embedding vector is projected onto the query Projection to Key Projection to value Where LN(.) is the layer normalization function, and are the weight matrices projected to the query, key, and value, respectively. d is the potential feature dimension. c is the knowledge point. i The attention score of the text embedding vector is

[0015]

[0016] Where T is the transposition operation, Softmax() is the activation function, and the knowledge point c i The aggregate vector representation of the attention scores of the text embedding vector is projected back to space, then the text semantic features of the knowledge point are

[0017]

[0018] in It is a projection;

[0019] Step 3: Integrate the changes in the voice and visual features of teaching resources, and use software tools to convert videos, PPTs, and exercises into two modal data: text and images;

[0020] Step 3-1, extract teaching resources b j Key frame images of the video;

[0021] Step 3-2: Use speech recognition tools to translate teaching resources into j Convert the speech in the video to text;

[0022] Using Python's moviepy library to program speech extraction functions from teaching resources b j Extract the audio file from the video j , where 1≤j≤l, use the speech recognition function programming of the SpeechRecognition library to convert speech into text;

[0023] Step 3-3, using software tools to extract text and images from slide documents or exercises;

[0024] Use the functions provided by the python-pptx library to extract and automatically save text and images in slide documents, use the requests library in Python to obtain the web page content of the exercises on the online learning platform, and then use the BeautifulSoup library to parse HTML, extract and save text and images;

[0025] Step 4: Learn the image features and text semantic features of teaching resources based on the cross-modal attention mechanism of images and texts;

[0026] Step 4-1: Extract teaching resources based on the ChineseCLIP pre-trained model j Text embedding vector of ;

[0027] Assume that teaching resources b j The text information is b j.text, with a length of 77 characters as a standard, the text information b j .text is divided into n2 segments, and the r2 segment uses the ChineseCLIP pre-trained model to extract the text embedding vector

[0028] Where 1≤r2≤n2,

[0029] Where d0 is the dimension of text embedding, and the average value of the embedding vectors of n2 segments of text is calculated as the teaching resource b j The text embedding vector of

[0030] Step 4-2, calculate teaching resources b j Query of text embedding vectors;

[0031] Teaching resourcesb j The text embedding vector is projected onto the query Where d is the potential feature dimension, calculated as Where LN(.) is the layer normalization function, Is a teaching resource j The text embedding vector is projected onto the weight matrix of the query;

[0032] Step 4-3, extracting the image embedding vector of the teaching resources based on the ChineseCLIP pre-trained model;

[0033] Assume that teaching resources b j Image information is b j .image, contains n3 images, and the image embedding vector of the r3th image is extracted using the ChineseCLIP pre-trained model Where 1≤r3≤n3, calculate the average value of the embedding vectors of n3 images as teaching resource b j The image embedding vector is

[0034] Step 4-4, calculating the key and value of the image embedding vector of the teaching resource;

[0035] Assume that teaching resources b j The image embedding vector is projected onto the key The calculation formula is in is the weight matrix of the image embedding vector projected onto the key,

[0036] Assume that teaching resources b j The image embedding vector is projected to the value The calculation formula is in is the weight matrix projecting the image embedding vector to the value;

[0037] Step 4-5: learn the image features and text semantic features of teaching resources based on the cross-modal attention mechanism of images and texts;

[0038] Teaching resourcesb j The text content of the image is semantically related to the local content of the image. In order to increase the interaction between text and image modal features, the query of the text embedding vector and the key and value of the image embedding vector are used to construct the cross-modal attention score of the text-to-image query, that is,

[0039]

[0040] In order to embed the image in the common space of image and text, the aggregated image vector representation of cross-modal attention is projected back to the image space Then the image features of teaching resources are

[0041] in

[0042] Similarly, we construct a cross-modal attention model using the query of the image embedding vector and the key and value of the text embedding vector. Then the text semantic features of teaching resources are in

[0043] Using cross entropy as the loss function, the self-attention network is trained on the teaching resource dataset to estimate the optimal query, key, and value weight matrices. The image feature matrix of the teaching resource is composed of the image features of l teaching resources. The text semantic feature matrix of teaching resources is composed of the text semantic features of l teaching resources:

[0044] Step 5: construct a similarity matrix of the semantic features of the knowledge point text, find relevant teaching resources based on the similarity of the knowledge point, and complete the row vector of the knowledge point-teaching resource interaction matrix X;

[0045] Step 6: Find relevant teaching resources based on the similarity of teaching resources, and complete the column vector of the knowledge point-teaching resource interaction matrix X;

[0046] Step 7, based on the completed knowledge point-teaching resource interaction matrix, use the gradient descent method to learn the knowledge point latent factor matrix and the teaching resource latent factor matrix;

[0047] Step 7-1 Initialize the knowledge point latent factor matrix is 0 and the potential factor matrix of teaching resources is 0, where d2 is the dimension of the latent factor and the number of iterations is t=0;

[0048] Step 7-2 Update the knowledge point potential factor matrix U and the teaching resource potential factor matrix V based on the gradient descent method, and calculate the partial derivative of the objective function with respect to the knowledge point potential factor matrix U Update with step size α in the opposite direction of the gradient Calculate the partial derivative of the objective function with respect to the latent factor matrix of teaching resources Update with step size α in the opposite direction of the gradient The number of iterations is increased by 1, that is, t+1→t, where the objective function is calculated is the Frobenius 2 normal form function;

[0049] Step 7-3 repeats step 7-2 until the objective function L converges or the number of iterations t reaches the threshold, and outputs the knowledge point latent factor matrix U and the teaching resource latent factor matrix V;

[0050] Step 8, re-estimate the knowledge point-teaching resource interaction matrix based on the knowledge point latent factor matrix U and the teaching resource latent factor matrix V, and classify the teaching resources into categories of knowledge points;

[0051] Step 8-1, normalize the knowledge point potential factor matrix U and the teaching resource potential factor matrix V, that is

[0052] Step 8-2: The normalized knowledge point latent factor matrix U and teaching resource latent factor matrix V are used to reconstruct a new knowledge point-teaching resource interaction matrix

[0053] Step 8-3, query teaching resources b j Corresponding to the new knowledge point-teaching resource interaction matrix The scores of the jth column of are sorted in descending order, then the teaching resource b j Divide into categories of the first K1 knowledge points.

[0054] As a further preferred embodiment of the present invention, in step 3-1, it is assumed that the video teaching resource b j The duration is T j Seconds, divided into several segments of speech and video images according to the time interval of 10 seconds, calculate the average rate of change of speech features within 10 seconds starting from time t Where 0 <t<T j -10, Indicates teaching resources b j The speech features at time t, calculate the average rate of change of the video frame image features within 10 seconds starting from time t Where 0 <t<T j -10, Table teaching resources b j At the image feature at time t, if the speech feature change rate At If the image feature change rate I is greater than the threshold ξ1, and the threshold ξ1 is equal to 0.4, it indicates that the sentence may be finished or the subject content may change. t is greater than the threshold ξ2, and the threshold ξ2 is equal to 0.5, which indicates that the subject content may change. t is greater than the threshold ξ1 and the image feature change rate I t If it is greater than the threshold ξ2, the output video frame is a key frame image.

[0055] As a further preference of the present invention, step 5 specifically comprises:

[0056] Step 5-1: construct the similarity matrix of knowledge point text features and calculate the similarity matrix of any two knowledge points. and Semantic features of text and The cosine similarity of Where 1≤i1,i2≤n, construct the similarity matrix of the semantic features of the knowledge point text

[0057] Step 5-2, based on the similarity of the knowledge points, find the relevant teaching resources, that is, retrieve the first K2 knowledge points that are most similar to the knowledge point, and merge the teaching resources corresponding to these knowledge points;

[0058] Similarity matrix from semantic features of knowledge point text Retrieve the text semantic feature f of the i-th knowledge point i The features of the first K2 most similar knowledge points are returned, and the corresponding knowledge points are marked with serial numbers. Set the serial number to Teaching resources corresponding to the knowledge points With knowledge point c i The original corresponding teaching resources Merge to form knowledge point c i New corresponding teaching resources

[0059]

[0060] Step 5-3, completing the row vector of the knowledge point-teaching resource interaction matrix;

[0061] Knowledge point c in the knowledge point-teaching resource interaction matrix X i Only the teaching resource collection before the update The elements interact by adding knowledge points c i and updated teaching resources The interaction of Complete the row vector of the knowledge point-teaching resource interaction matrix X.

[0062] As a further preference of the present invention, step 6 specifically comprises the following steps:

[0063] Step 6-1: Calculate the text features of any two teaching resources and The cosine similarity between in Constructing a similarity matrix of semantic features of teaching resource texts

[0064] Step 6-2: Calculate the features of any two teaching resource images and The cosine similarity between Where 1≤j1, j2≤l, construct the similarity matrix of teaching resource image features

[0065] Step 6-3, calculate any two teaching resources and The mean cross cosine similarity between the text features and image features is

[0066] Where 1≤j1, j2≤l, construct the similarity matrix of the graphic features of teaching resources

[0067] Step 6-4, based on the teaching resource text, image and image-text similarity, find the knowledge points related to it, that is, retrieve the top K3 teaching resources most similar to the teaching resource and merge the knowledge points corresponding to these teaching resources.

[0068] As a further preferred embodiment of the present invention, step 6-4 specifically comprises the following steps:

[0069] Step 6-4-1: Based on the similarity matrix of the semantic features of the teaching resource text Complete the column vector of the knowledge point-teaching resource interaction matrix X;

[0070] From the similarity matrix of semantic features of teaching resource text Search and teaching resources j Semantic features of text The top K3 most similar teaching resources are Assumption Teaching Resources The corresponding knowledge points are Where 1≤r≤K3,n r Indicates b jr The corresponding number of knowledge points is increased by increasing teaching resources And knowledge points The interaction of , where 1≤x1≤n r ,Right now Complete the column vector of the knowledge point-teaching resource interaction matrix X;

[0071] Step 6-4-2, based on the similarity matrix of teaching resource image features Complete the column vector of the knowledge point-teaching resource interaction matrix X;

[0072] Image similarity matrix from teaching resources Search and teaching resources j Image features The top K3 most similar teaching resources are Assumption Teaching Resources The corresponding knowledge points are Where 1≤r≤K3,n r express The corresponding number of knowledge points is increased by increasing teaching resources And knowledge points The interaction of , where 1≤x2≤n r ,Right now Complete the column vector of the knowledge point-teaching resource interaction matrix X;

[0073] Step 6-4-3, based on the similarity matrix of teaching resource graphic features Complete the column vector of the knowledge point-teaching resource interaction matrix X;

[0074] From the teaching resource picture and text similarity matrix Search and teaching resources j The top K3 teaching resources with the most similar graphic and text features are Assumption Teaching Resources The corresponding knowledge points are Where 1≤r≤K3,n r Indicates teaching resources The corresponding number of knowledge points is increased by increasing teaching resources And knowledge points The interaction of , where 1≤x3≤n r ,Right now Complete the column vector of the knowledge point-teaching resource interaction matrix X.

[0075] The beneficial effects of the present invention are as follows: (1) by constructing a similarity matrix of semantic features of knowledge point texts, searching for teaching resources based on knowledge point similarity, completing the row vectors of the knowledge point-teaching resource interaction matrix, and constructing text, image and graphic similarity matrices of teaching resources, searching for teaching resources related to them based on teaching resource similarity, completing the column vectors of the knowledge point-teaching resource interaction matrix, solving the sparsity problem of the knowledge point-teaching resource interaction matrix, and based on the completed knowledge point-teaching resource interaction matrix, using the gradient descent method to learn the latent factor matrix of the knowledge point and the latent factor matrix of the teaching resource;

[0076] (2) In view of the problem that the visual information of the video in the teaching resources has little change, the present invention proposes an automatic key frame image extraction method that integrates the changes in the speech and visual features of the video segments in the teaching resources, and utilizes the complementarity of speech and visual features to identify the key frame images of the video in the teaching resources;

[0077] (3) In order to utilize the important complementary information between the text and vision of teaching resources, and considering the relationship between the text content and the partial image content of the video image being described, the present invention proposes a semantic feature learning method for teaching resource images and texts based on a cross-modal attention mechanism for local content of images and texts, and utilizes the query projection of the text to guide the key projection and value projection of the image to construct the image feature learning of teaching resources with a cross-modal attention mechanism for images and texts. The query projection of the image is used to guide the key projection and value projection of the text to construct the text feature learning of teaching resources with a cross-modal attention mechanism for images and texts. In the face of the long text problem of knowledge points and teaching resources, the present invention proposes a semantic feature learning method for learning knowledge points based on a pre-trained model of a segmentation mechanism and fine-tuning of a self-attention network. BRIEF DESCRIPTION OF THE DRAWINGS

[0078] Figure 1 It is a flow chart of the present invention. DETAILED DESCRIPTION

[0079] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the specific implementation methods of the present invention are described in detail below in conjunction with the accompanying drawings.

[0080] The specific working process of the present invention is as follows Figure 1 shown.

[0081] Step 1: Extract knowledge points and teaching resources from the course outline of the online learning platform according to chapters, and organize n knowledge points into a set C, where C = {c1, c2, ..., c n}, mark l teaching resources as set B, B={b1,b2,…,b l}, construct the knowledge point-teaching resource interaction matrix X∈R n×l , if teaching resource b j∈B contains knowledge point c i ∈C, where 1≤j≤l, 1≤i≤n, then X(c i ,b j )=1, otherwise X(c i ,b j )=0.

[0082] Step 2: Extract the text embedding vector of the knowledge point based on the ChineseCLIP pre-trained model, and fine-tune the semantic features of the knowledge point based on the self-attention network;

[0083] Step 2-1, extract the text embedding vector of the knowledge point based on the ChineseCLIP pre-trained model of the segmentation mechanism;

[0084] Assume knowledge point c i The text information is c i .text, with a length of 77 characters as a standard, the text information c i .text is divided into n1 segments, and the text embedding vector is extracted from each segment using the ChineseCLIP pre-trained model

[0085] Where 1≤r1≤n1,

[0086] where c i .text.r1 is knowledge point c i The r1th paragraph of text information, d0 is the dimension of the text embedding vector, and the average value of the n1th paragraph of text embedding vector is calculated as the knowledge point c i The text embedding vector of

[0087]

[0088] Step 2-2, fine-tune the text semantic features of the learning knowledge points based on the self-attention network;

[0089] Assume knowledge point c i The text embedding vector is projected onto the query Projection to Key Projection to value Where LN(.) is the layer normalization function, and are the weight matrices projected to the query, key, and value, respectively. d is the potential feature dimension. c is the knowledge point. i The attention score of the text embedding vector is

[0090]

[0091] Where T is the transposition operation, Softmax() is the activation function, and the knowledge point c iThe aggregate vector representation of the attention scores of the text embedding vector is projected back to space, then the text semantic features of the knowledge point are

[0092]

[0093] in It's a projection.

[0094] Step 3: Integrate the changes in the voice and visual features of teaching resources, and use software tools to convert videos, PPTs, and exercises into two modal data: text and images;

[0095] Step 3-1, extract teaching resources b j Key frame images of the video;

[0096] Preferably, in step 3-1, it is assumed that the video teaching resource b j The duration is T j Seconds, divided into several segments of speech and video images according to the time interval of 10 seconds, calculate the average rate of change of speech features within 10 seconds starting from time t Where 0 <t<T j -10, Indicates teaching resources b j The speech features at time t, calculate the average rate of change of the video frame image features within 10 seconds starting from time t Where 0 <t<T j -10, Table teaching resources b j At the image feature at time t, if the speech feature change rate A t If the image feature change rate I is greater than the threshold ξ1, and the threshold ξ1 is equal to 0.4, it indicates that the sentence may be finished or the subject content may change. t is greater than the threshold ξ2, and the threshold ξ2 is equal to 0.5, which indicates that the subject content may change. t is greater than the threshold ξ1 and the image feature change rate I t If it is greater than the threshold ξ2, the output video frame is a key frame image;

[0097] Step 3-2: Use speech recognition tools to translate teaching resources into j Convert the speech in the video to text;

[0098] Using Python's moviepy library to program speech extraction functions from teaching resources b j Extract the audio file from the video j , where 1≤j≤l, use the speech recognition function programming of the SpeechRecognition library to convert speech into text;

[0099] Step 3-3, using software tools to extract text and images from slide documents or exercises;

[0100] Use the functions provided by the python-pptx library to extract and automatically save text and images in slide documents, use the requests library in Python to obtain the web page content of exercises on the online learning platform, and then use the BeautifulSoup library to parse HTML, extract and save text and images.

[0101] Step 4: Learn the image features and text semantic features of teaching resources based on the cross-modal attention mechanism of images and texts;

[0102] Step 4-1: Extract teaching resources based on the ChineseCLIP pre-trained model j Text embedding vector of ;

[0103] Assume that teaching resources b j The text information is b j .text, with a length of 77 characters as a standard, the text information b j .text is divided into n2 segments, and the r2 segment uses the ChineseCLIP pre-trained model to extract the text embedding vector

[0104] Where 1≤r2≤n2,

[0105] Where d0 is the dimension of text embedding, and the average value of the embedding vectors of n2 segments of text is calculated as the teaching resource b j The text embedding vector of

[0106] Step 4-2, calculate teaching resources b j Query of text embedding vectors;

[0107] Teaching resourcesb j The text embedding vector is projected onto the query Where d is the potential feature dimension, calculated as Where LN(.) is the layer normalization function, Is a teaching resource j The text embedding vector is projected onto the weight matrix of the query;

[0108] Step 4-3, extracting the image embedding vector of the teaching resources based on the ChineseCLIP pre-trained model;

[0109] Assume that teaching resources b j Image information is b j.image, contains n3 images, and the image embedding vector of the r3th image is extracted using the ChineseCLIP pre-trained model Where 1≤r3≤n3, calculate the average value of the embedding vectors of n3 images as teaching resource b j The image embedding vector is

[0110] Step 4-4, calculating the key and value of the image embedding vector of the teaching resource;

[0111] Assume that teaching resources b j The image embedding vector is projected onto the key The calculation formula is in is the weight matrix of the image embedding vector projected onto the key,

[0112] Assume that teaching resources b j The image embedding vector is projected to the value The calculation formula is in is the weight matrix projecting the image embedding vector to the value;

[0113] Step 4-5: learn the image features and text semantic features of teaching resources based on the cross-modal attention mechanism of images and texts;

[0114] Teaching resourcesb j The text content of the image is semantically related to the local content of the image. In order to increase the interaction between text and image modal features, the query of the text embedding vector and the key and value of the image embedding vector are used to construct the cross-modal attention score of the text-to-image query, that is,

[0115]

[0116] In order to embed the image in the common space of image and text, the aggregated image vector representation of cross-modal attention is projected back to the image space Then the image features of teaching resources are

[0117] in

[0118] Similarly, we construct a cross-modal attention model using the query of the image embedding vector and the key and value of the text embedding vector. Then the text semantic features of teaching resources are in

[0119] Using cross entropy as the loss function, the self-attention network is trained on the teaching resource dataset to estimate the optimal query, key, and value weight matrices. The image feature matrix of the teaching resource is composed of the image features of l teaching resources. The text semantic feature matrix of teaching resources is composed of the text semantic features of l teaching resources:

[0120] Step 5: construct a similarity matrix of the semantic features of the knowledge point text, find relevant teaching resources based on the similarity of the knowledge point, and complete the row vector of the knowledge point-teaching resource interaction matrix X;

[0121] Preferably, step 5-1 constructs a similarity matrix of knowledge point text features and calculates the similarity matrix of any two knowledge points. and Semantic features of text and The cosine similarity of Where 1≤i1,i2≤n, construct the similarity matrix of the semantic features of the knowledge point text

[0122] Preferably, step 5-2, based on the similarity of the knowledge points, find the teaching resources related to the knowledge points, that is, retrieve the first K2 knowledge points most similar to the knowledge points, and merge the teaching resources corresponding to these knowledge points;

[0123] Similarity matrix from semantic features of knowledge point text Retrieve the text semantic feature f of the i-th knowledge point i The features of the first K2 most similar knowledge points are returned, and the corresponding knowledge points are marked with serial numbers. Set the serial number to Teaching resources corresponding to the knowledge points With knowledge point c i The original corresponding teaching resources Merge to form knowledge point c i New corresponding teaching resources

[0124]

[0125] Preferably, step 5-3, completing the row vector of the knowledge point-teaching resource interaction matrix;

[0126] Knowledge point c in the knowledge point-teaching resource interaction matrix X i Only the teaching resource collection before the update The elements interact by adding knowledge points c i and updated teaching resources The interaction of Complete the row vector of the knowledge point-teaching resource interaction matrix X.

[0127] Step 6: Find relevant teaching resources based on the similarity of teaching resources, and complete the column vector of the knowledge point-teaching resource interaction matrix X;

[0128] Preferably, step 6-1, calculate the text features of any two teaching resources and The cosine similarity between Where 1≤j1, j2≤l, construct the similarity matrix of the semantic features of the teaching resource text

[0129] Step 6-2: Calculate the features of any two teaching resource images and The cosine similarity between Where 1≤j1, j2≤l, construct the similarity matrix of teaching resource image features

[0130] Step 6-3, calculate any two teaching resources and The mean cross cosine similarity between the text features and image features is

[0131] Where 1≤j1, j2≤l, construct the similarity matrix of teaching resource graphic features

[0132] Step 6-4, searching for knowledge points related to the teaching resource based on the text, image and image-text similarity, that is, retrieving the top K3 teaching resources most similar to the teaching resource, and merging the knowledge points corresponding to these teaching resources;

[0133] Preferably, step 6-4 specifically includes:

[0134] Step 6-4-1: Based on the similarity matrix of the semantic features of the teaching resource text Complete the column vector of the knowledge point-teaching resource interaction matrix X;

[0135] From the similarity matrix of semantic features of teaching resource text Search and teaching resources j Semantic features of text The top K3 most similar teaching resources are Assumption Teaching Resources The corresponding knowledge points are Where 1≤r≤K3,n r express The corresponding number of knowledge points is increased by increasing teaching resources And knowledge points The interaction of , where 1≤x1≤n r ,Right now Complete the column vector of the knowledge point-teaching resource interaction matrix X;

[0136] Step 6-4-2, based on the similarity matrix of teaching resource image features Complete the column vector of the knowledge point-teaching resource interaction matrix X;

[0137] Image similarity matrix from teaching resources Search and teaching resources j Image features The top K3 most similar teaching resources are Assumption Teaching Resources The corresponding knowledge points are Where 1≤r≤K3,n r express The corresponding number of knowledge points is increased by increasing teaching resources And knowledge points The interaction of , where 1≤x2≤n r ,Right now Complete the column vector of the knowledge point-teaching resource interaction matrix X;

[0138] Step 6-4-3, based on the similarity matrix of teaching resource graphic features Complete the column vector of the knowledge point-teaching resource interaction matrix X;

[0139] From the teaching resource picture and text similarity matrix Search and teaching resources j The top K3 teaching resources with the most similar graphic and text features are Assumption Teaching Resources The corresponding knowledge points are Where 1≤r≤K3,n r Indicates teaching resources The corresponding number of knowledge points is increased by increasing teaching resources And knowledge points The interaction of , where 1≤x3≤n r ,Right now Complete the column vector of the knowledge point-teaching resource interaction matrix X.

[0140] Step 7, based on the completed knowledge point-teaching resource interaction matrix, use the gradient descent method to learn the knowledge point latent factor matrix and the teaching resource latent factor matrix;

[0141] Step 7-1 Initialize the knowledge point latent factor matrix is 0 and the potential factor matrix of teaching resources is 0, where d2 is the dimension of the latent factor and the number of iterations is t=0;

[0142] Step 7-2 Update the knowledge point potential factor matrix U and the teaching resource potential factor matrix V based on the gradient descent method, and calculate the partial derivative of the objective function with respect to the knowledge point potential factor matrix U Update with step size α in the opposite direction of the gradient Calculate the partial derivative of the objective function with respect to the latent factor matrix of teaching resources Update with step size α in the opposite direction of the gradient The number of iterations is increased by 1, that is, t+1→t, where the objective function is calculated is the Frobenius 2 normal form function;

[0143] Step 7-3 repeats step 7-2 until the objective function L converges or the number of iterations t reaches the threshold, and outputs the knowledge point latent factor matrix U and the teaching resource latent factor matrix V.

[0144] Step 8, re-estimate the knowledge point-teaching resource interaction matrix based on the knowledge point latent factor matrix U and the teaching resource latent factor matrix V, and classify the teaching resources into categories of knowledge points;

[0145] Step 8-1, normalize the knowledge point potential factor matrix U and the teaching resource potential factor matrix V, that is

[0146] Step 8-2: The normalized knowledge point latent factor matrix U and teaching resource latent factor matrix V are used to reconstruct a new knowledge point-teaching resource interaction matrix

[0147] Step 8-3, query teaching resources b j Corresponding to the new knowledge point-teaching resource interaction matrix The scores of the jth column of are sorted in descending order, then the teaching resource b j Divide into categories of the first K1 knowledge points.

[0148] It should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the preferred embodiments, those skilled in the art should understand that the technical solutions of the present invention may be modified or replaced by equivalents without departing from the spirit and scope of the technical solutions of the present invention, which should all be included in the scope of the claims of the present invention.

Claims

1. A method for classifying teaching resources on online learning platforms based on semantic content of knowledge points. It is characterized in that The steps include: Step 1: Extract knowledge points and teaching resources from the course outline of the online learning platform according to chapters, and organize n knowledge points into a set C, C = {c 1 , c 2 , ..., c n }, mark l teaching resources as set B, B = {b 1 ,b 2 ,…,b l }, construct the knowledge point-teaching resource interaction matrix X∈R n×l , if teaching resource b j ∈B contains knowledge point c i ∈C, where 1≤j≤l, 1≤i≤n, then X(c i ,b j )=1, otherwise X(c i ,b j )=0; Step 2: Extract the text embedding vector of the knowledge point based on the ChineseCLIP pre-trained model, and fine-tune the text semantic features of the knowledge point based on the self-attention network; Step 2-1, extract the text embedding vector of the knowledge point based on the ChineseCLIP pre-trained model of the segmentation mechanism; Assume knowledge point c i The text information is c i .text, with a length of 77 characters as a standard, the text information c i .text is divided into n 1 Each segment uses the ChineseCLIP pre-trained model to extract text embedding vectors Where 1≤r 1 ≤n 1 , where c i .text.r 1 It is knowledge point c i The rth 1 Segment text information, d 0 is the dimension of the text embedding vector, calculate n 1 The average value of the segment text embedding vector is used as the knowledge point c i The text embedding vector of Step 2-2, fine-tune the text semantic features of the learning knowledge points based on the self-attention network; Assume knowledge point c i The text embedding vector is projected onto the query Projection to Key Projection to value Where LN(.) is the layer normalization function, and are the weight matrices projected to the query, key, and value, respectively. d is the potential feature dimension. c is the knowledge point. i The attention score of the text embedding vector is Where T is the transposition operation, Softmax() is the activation function, and the knowledge point c i The aggregate vector representation of the attention scores of the text embedding vector is projected back to space, then the text semantic features of the knowledge point are in It is a projection; Step 3: Integrate the changes in the voice and visual features of teaching resources, and use software tools to convert videos, PPTs, and exercises into two modal data: text and images; Step 3-1, extract teaching resources b j Key frame images of the video; Step 3-2: Use speech recognition tools to translate teaching resources into j Convert the speech in the video to text; Using Python's moviepy library to program speech extraction functions from teaching resources b j Extract the audio file V from the video j , where 1≤j≤l, use the speech recognition function programming of the SpeechRecognition library to convert speech into text; Step 3-3, using software tools to extract text and images from slide documents or exercises; Use the functions provided by the python-pptx library to extract and automatically save text and images in slide documents, use the requests library in Python to obtain the web page content of the exercises on the online learning platform, and then use the BeautifulSoup library to parse HTML, extract and save text and images; Step 4: Learn the image features and text semantic features of teaching resources based on the cross-modal attention mechanism of images and texts; Step 4-1: Extract teaching resources based on the ChineseCLIP pre-trained model j Text embedding vector of ; Assume that teaching resources b j The text information is b j .text, with a length of 77 characters as a standard, the text information b j .text is divided into n 2 Paragraph, r 2 Use the ChineseCLIP pre-trained model to extract text embedding vectors Where 1≤r 2 ≤n 2 , where d 0 is the dimension of text embedding, calculate n 2 The average value of the segment text embedding vector is used as teaching resource b j The text embedding vector of Step 4-2, calculate teaching resources b j Query of text embedding vectors; Teaching resourcesb j The text embedding vector is projected onto the query Where d is the potential feature dimension, calculated as Where LN(.) is the layer normalization function, Is a teaching resource j The text embedding vector is projected onto the weight matrix of the query; Step 4-3, extracting the image embedding vector of the teaching resources based on the ChineseCLIP pre-trained model; Assume that teaching resources b j Image information is b j .image, containing n 3 Image, r 3 Extract image embedding vectors using the ChineseCLIP pre-trained model Where 1≤r 3 ≤n 3 , calculate n 3 The average value of the image embedding vector is used as the teaching resource b j The image embedding vector is Step 4-4, calculating the key and value of the image embedding vector of the teaching resource; Assume that teaching resources b j The image embedding vector is projected onto the key The calculation formula is in is the weight matrix of the image embedding vector projected onto the key, Assume that teaching resources b j The image embedding vector is projected to the value The calculation formula is in is the weight matrix projecting the image embedding vector to the value; Step 4-5: learn the image features and text semantic features of teaching resources based on the cross-modal attention mechanism of images and texts; Teaching resourcesb j The text content of the image is semantically related to the local content of the image. In order to increase the interaction between text and image modal features, the query of the text embedding vector and the key and value of the image embedding vector are used to construct the cross-modal attention score of the text-to-image query, that is, In order to embed the image in the common space of image and text, the aggregated image vector representation of cross-modal attention is projected back to the image space Then the image features of teaching resources are in Similarly, we construct a cross-modal attention model using the query of the image embedding vector and the key and value of the text embedding vector. Then the text semantic features of teaching resources are in Using cross entropy as the loss function, the self-attention network is trained on the teaching resource dataset to estimate the optimal query, key, and value weight matrices. The image feature matrix of the teaching resource is composed of the image features of l teaching resources. The text semantic feature matrix of teaching resources is composed of the text semantic features of l teaching resources: Step 5: construct a similarity matrix of the semantic features of the knowledge point text, find relevant teaching resources based on the similarity of the knowledge point, and complete the row vector of the knowledge point-teaching resource interaction matrix X; Step 6: Find relevant teaching resources based on the similarity of teaching resources, and complete the column vector of the knowledge point-teaching resource interaction matrix X; Step 7, based on the completed knowledge point-teaching resource interaction matrix, use the gradient descent method to learn the knowledge point latent factor matrix and the teaching resource latent factor matrix; Step 7-1 Initialize the knowledge point latent factor matrix is 0 and the potential factor matrix of teaching resources is 0, where d 2 is the dimension of the latent factor, the number of iterations is t = 0; Step 7-2 Update the knowledge point potential factor matrix U and the teaching resource potential factor matrix V based on the gradient descent method, and calculate the partial derivative of the objective function with respect to the knowledge point potential factor matrix U Update with step size α in the opposite direction of the gradient Calculate the partial derivative of the objective function with respect to the latent factor matrix of teaching resources Update with step size α in the opposite direction of the gradient The number of iterations is increased by 1, that is, t+1→t, where the objective function is calculated is the Frobenius 2 normal form function; Step 7-3 repeats step 7-2 until the objective function L converges or the number of iterations t reaches the threshold, and outputs the knowledge point latent factor matrix U and the teaching resource latent factor matrix V; Step 8, re-estimate the knowledge point-teaching resource interaction matrix based on the knowledge point latent factor matrix U and the teaching resource latent factor matrix V, and classify the teaching resources into categories of knowledge points; Step 8-1, normalize the knowledge point potential factor matrix U and the teaching resource potential factor matrix V, that is Step 8-2: The normalized knowledge point latent factor matrix U and teaching resource latent factor matrix V are used to reconstruct a new knowledge point-teaching resource interaction matrix Step 8-3, query teaching resources b j Corresponding to the new knowledge point-teaching resource interaction matrix The scores of the jth column of are sorted in descending order, then the teaching resource b j Divided into first K 1 The category of knowledge points.

2. A method for classifying teaching resources of an online learning platform oriented to knowledge point semantic content as claimed in claim 1, It is characterized in that In step 3-1, assume that the video teaching resource b j The duration is T j Seconds, divided into several segments of speech and video images according to the time interval of 10 seconds, calculate the average rate of change of speech features within 10 seconds starting from time t Where 0 <t<T j -10, Indicates teaching resources b j The speech features at time t, calculate the average rate of change of the video frame image features within 10 seconds starting from time t Where 0 <t<T j -10, Table teaching resources b j At the image feature at time t, if the speech feature change rate A t Greater than the threshold ξ 1 , threshold ξ 1 If the image feature change rate I t Greater than the threshold ξ 2 , threshold ξ 2 is equal to 0.5, indicating that the subject content may change. t Greater than the threshold ξ 1 And the image feature change rate I t Greater than the threshold ξ 2 , the output video frame is a key frame image.

3. A method for classifying teaching resources of an online learning platform oriented to knowledge point semantic content as claimed in claim 1, It is characterized in that Step 5 specifically includes: Step 5-1: construct the similarity matrix of knowledge point text features and calculate the similarity matrix of any two knowledge points. and Semantic features of text and The cosine similarity of Where 1≤i 1 ,i 2 ≤n, construct the similarity matrix of the semantic features of the knowledge point text Step 5-2: Find relevant teaching resources based on the similarity of knowledge points, that is, retrieve the top K most similar knowledge points. 2 knowledge points and merge the teaching resources corresponding to these knowledge points; Similarity matrix from semantic features of knowledge point text Retrieve the text semantic feature f of the i-th knowledge point i Most similar top K 2 knowledge point features, return the corresponding knowledge point, and the serial number is marked as Set the serial number to Teaching resources corresponding to the knowledge points With knowledge point c i The original corresponding teaching resources Merge to form knowledge point c i New corresponding teaching resources Step 5-3, completing the row vector of the knowledge point-teaching resource interaction matrix; Knowledge point c in the knowledge point-teaching resource interaction matrix X i Only the teaching resource collection before the update The elements interact by adding knowledge points c i and updated teaching resources The interaction of Complete the row vector of the knowledge point-teaching resource interaction matrix X.

4. A method for classifying teaching resources of an online learning platform oriented to knowledge point semantic content as claimed in claim 1, It is characterized in that Step 6 specifically includes: Step 6-1: Calculate the text features of any two teaching resources and The cosine similarity between Where 1≤j 1 , j 2 ≤l, construct the similarity matrix of the semantic features of the teaching resource text Step 6-2: Calculate the features of any two teaching resource images and The cosine similarity between Where 1≤j 1 , j 2 ≤l, construct the similarity matrix of teaching resource image features Step 6-3, calculate any two teaching resources and The mean cross cosine similarity between the text features and image features is Where 1≤j 1 , j 2 ≤l, construct the similarity matrix of teaching resource graphic features Step 6-4: Search for relevant knowledge points based on the text, image, and image-text similarity of the teaching resource, that is, retrieve the top K most similar to the teaching resource. 3 teaching resources and merge the knowledge points corresponding to these teaching resources.

5. A method for classifying teaching resources of an online learning platform oriented to knowledge point semantic content as claimed in claim 4, It is characterized in that Step 6-4 specifically includes: Step 6-4-1: Based on the similarity matrix of the semantic features of the teaching resource text Complete the column vector of the knowledge point-teaching resource interaction matrix X; From the similarity matrix of semantic features of teaching resource text Search and teaching resources j Semantic features of text Most similar top K 3 The teaching resources are Assumption Teaching Resources The corresponding knowledge points are Where 1≤r≤K 3 , n r express The corresponding number of knowledge points is increased by increasing teaching resources And knowledge points The interaction, where 1≤x 1 ≤n r ,Right now Complete the column vector of the knowledge point-teaching resource interaction matrix X; Step 6-4-2, based on the similarity matrix of teaching resource image features Complete the column vector of the knowledge point-teaching resource interaction matrix X; Image similarity matrix from teaching resources Search and teaching resources j Image features Most similar top K 3 The teaching resources are Assumption Teaching Resources The corresponding knowledge points are Where 1≤r≤K 3 , n r express The corresponding number of knowledge points is increased by increasing teaching resources And knowledge points The interaction, where 1≤x 2 ≤n r ,Right now Complete the column vector of the knowledge point-teaching resource interaction matrix X; Step 6-4-3, based on the similarity matrix of teaching resource graphic features Complete the column vector of the knowledge point-teaching resource interaction matrix X; From the teaching resource picture and text similarity matrix Search and teaching resources j The top K most similar image and text features 3 The teaching resources are Assumption Teaching Resources The corresponding knowledge points are Where 1≤r≤K 3 , n r Indicates teaching resources The corresponding number of knowledge points is increased by increasing teaching resources And knowledge points The interaction, where 1≤x 3 ≤n r ,Right now Complete the column vector of the knowledge point-teaching resource interaction matrix X.