A method, device and electronic device for predicting cooperative relationships based on sequence recommendation
Through the sequence recommendation method of time embedding and high-order embedding combined with content embedding, the problem of low accuracy of cooperative relationship prediction is solved, and efficient cooperative relationship prediction is achieved under large data sets, which is suitable for multi-author scenarios.
Patent Information
- Application Number
- CN202411041665.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-31
- Publication Date
- 2025-09-05
- Estimated Expiration
- 2044-07-31
AI Technical Summary
The accuracy of cooperative relationship prediction in the existing technology is low, mainly because the manual selection of collaborators is affected by subjective factors, and the existing models cannot effectively capture the dynamic information and higher-order relationships of collaborators, resulting in too high computing demand on large data sets, making it difficult to achieve accurate and efficient cooperative relationship prediction.
Describe the dynamic changes of the author's text through time embedding, combine the author's higher-order embedding and content embedding, predict the cooperative relationship using a sequence recommendation-based method, adopt multiple tokens to represent the author, and use a large language model and graph neural network model to consider direct and indirect cooperative relationships to train a cooperative relationship prediction model based on sequence recommendation.
It improves the accuracy and comprehensiveness of cooperative relationship prediction, can efficiently predict cooperative relationships under large-scale data, saves computing resources, and is suitable for scenarios with a large number of authors.
Smart Images

Figure CN118966440B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data prediction, and more specifically, to a method, device and electronic device for predicting cooperative relationships based on sequence recommendation. Background Art
[0002] As scientific research expands across academia, scholars are producing a steady stream of research results. However, as research deepens, the cost of producing these results increases. Individual collaborators must collaborate with other researchers to discover new results. Predicting academic collaborations can reduce the time it takes to find collaborators, lower research costs, and improve research efficiency when producing research results.
[0003] Currently, when predicting cooperative relationships, suitable partners are selected manually based on experience. This method is easily affected by subjective factors, resulting in low accuracy of cooperative relationship prediction. Summary of the Invention
[0004] In view of this, the present invention provides a method, device and electronic device for predicting cooperative relationships based on sequence recommendation to solve the problem of low accuracy in cooperative relationship prediction.
[0005] In order to solve the above technical problems, the present invention adopts the following technical solutions:
[0006] A cooperative relationship prediction method based on sequential recommendation, comprising:
[0007] Obtain the target author for cooperation relationship prediction;
[0008] Calculating the time embedding and content embedding of the text published by the target author;
[0009] Determining an author embedding set of the target author, wherein the author embedding set includes the research embedding and high-order embedding of the target author; the high-order embedding is the research embedding of co-authors who have a direct or indirect cooperative relationship with the target author;
[0010] Get multiple tokens configured for the target author, and query the token embedding corresponding to the token;
[0011] Based on the time embedding, the content embedding, the author embedding set, and the token embedding, the collaborators of the target author are predicted; the collaborators are composed of multiple tokens.
[0012] Optionally, calculating the time embedding of the text published by the target author includes:
[0013] Determine the time of publication of the said text;
[0014] Performing a normalization operation on the disclosed time to obtain an intermediate time;
[0015] A time embedding value corresponding to the intermediate time is determined to obtain the time embedding of the text.
[0016] Optionally, calculating the content embedding of the text published by the target author includes:
[0017] Obtaining key information of the text;
[0018] An embedding vector of the key information is calculated as the content embedding of the text.
[0019] Optionally, determining the author embedding set of the target author includes:
[0020] Acquire co-authors who have collaborated with the target author; the collaboration includes direct collaboration or indirect collaboration;
[0021] Calculating the research embedding of the target author based on the content embedding;
[0022] Calculate the research embedding of the co-authors;
[0023] Calculate the high-order embedding of the target author using the research embeddings of the co-authors and the author collaboration graph structure;
[0024] The research embedding and high-order embedding of the target author are combined to obtain the author embedding set.
[0025] Optionally, calculating the research embedding of the target author based on the content embedding includes:
[0026] The weighted average of the content embeddings decayed over time is calculated to obtain the scientific research embedding of the target author.
[0027] Optionally, obtaining multiple tokens configured for the target author and querying the token embedding corresponding to the tokens includes:
[0028] Get the preset number of split tokens;
[0029] Performing a dimensionality reduction operation on the sparse matrix representing the relationship between the author and the text to obtain a token dictionary constructed based on quantization accuracy and a preset number of split tokens. Based on the token dictionary, multiple tokens are configured for the target author.
[0030] Input each token into the embedding layer to obtain the token embedding corresponding to the token.
[0031] Optionally, predicting the collaborators of the target author based on the time embedding, the content embedding, the author embedding set, and the token embedding includes:
[0032] Combining the time embedding, the content embedding, the author embedding set, and the token embedding to obtain input data;
[0033] Sequentially inputting the input data into a cooperative relationship prediction model based on sequence recommendation to obtain a cooperative relationship score of the target author;
[0034] A classifier is used to perform a classification operation on the cooperation relationship scores to obtain the collaborators.
[0035] Optionally, the process of generating the cooperative relationship prediction model based on sequence recommendation includes:
[0036] Obtain training samples, where the training samples include a combination of time embeddings, content embeddings, author embedding sets, and token embeddings corresponding to different authors;
[0037] Based on a preset training method, the training sample is used to perform a training operation on the cooperative relationship prediction model based on sequence recommendation until a training stop condition is met.
[0038] A cooperative relationship prediction device based on sequence recommendation, comprising:
[0039] The author acquisition module is used to obtain the target author for cooperation relationship prediction;
[0040] an embedding calculation module, configured to calculate the time embedding and content embedding of the text published by the target author;
[0041] a set determination module, configured to determine the target author's author embedding set, wherein the author embedding set includes the target author's research embedding and high-order embedding; the high-order embedding is the research embedding of co-authors who have a direct or indirect cooperative relationship with the target author;
[0042] An embedding acquisition module, configured to acquire multiple tokens configured for the target author and query the token embedding corresponding to the token;
[0043] An author prediction module is used to predict the collaborators of the target author based on the time embedding, the content embedding, the author embedding set and the token embedding; the collaborators are composed of multiple tokens.
[0044] An electronic device comprising: a memory and a processor;
[0045] Wherein, the memory is used to store programs;
[0046] The processor calls the program and is used to execute the above-mentioned cooperative relationship prediction method based on sequence recommendation.
[0047] Compared with the prior art, the present invention has the following beneficial effects:
[0048] The present invention provides a method, device and electronic device for predicting cooperative relationships based on sequence recommendation. In the present invention, when predicting cooperative relationships, the dynamic changes of the text corresponding to the author over time are described by time embedding, the historical cooperative relationship between the author and the collaborator is considered by the author's high-order embedding, and the core description of the text is represented by content embedding. Then, based on the time embedding, the content embedding, the author embedding set and the token embedding, when predicting the collaborators of the target author, the cooperative relationship can be predicted from multiple angles, thereby improving the accuracy of the prediction. In addition, the present invention does not directly use one author as a sequence token, but configures multiple tokens for the author to obtain multiple token embeddings corresponding to the author. This can save computing resources during model training and can also achieve cooperative relationship prediction in scenarios with a large number of authors, with high accuracy and reliability and high efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0049] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are merely embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying any creative work.
[0050] Figure 1 A flowchart of a method for predicting cooperative relationships based on sequence recommendation provided by an embodiment of the present invention;
[0051] Figure 2 A schematic diagram of a document co-authoring network provided by an embodiment of the present invention;
[0052] Figure 3 A flowchart of a method for determining an author embedding set provided by an embodiment of the present invention;
[0053] Figure 4 A schematic diagram of input data provided by an embodiment of the present invention;
[0054] Figure 5 A flowchart of a method for determining a token provided by an embodiment of the present invention;
[0055] Figure 6 A network structure diagram of a VAE provided in an embodiment of the present invention;
[0056] Figure 7 A schematic diagram of a model structure provided by an embodiment of the present invention;
[0057] Figure 8 A schematic diagram of a model training provided by an embodiment of the present invention;
[0058] Figure 9 An operating logic diagram of a k-best-crf algorithm provided in an embodiment of the present invention;
[0059] Figure 10 A schematic diagram of the structure of a cooperative relationship prediction device based on sequence recommendation provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0060] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.
[0061] Time embedding refers to the vector corresponding to the publication time of the text published by the author. Specifically, the publication time of the text published by the author can be encoded into "time embedding" using a time encoding algorithm;
[0062] Content embedding refers to: the vector corresponding to the key information in the text published by the author;
[0063] Research embedding refers to: the weighted average of content embedding;
[0064] High-order embeddedness refers to the scientific research embeddedness of co-authors who have direct or indirect cooperative relationships with the target author.
[0065] Token embedding involves representing each author with multiple tokens in a token dictionary. By sharing tokens across authors, authors are appropriately densified and encoded using a multi-hot encoding. This encoding is then fed into the embedding layer. The embedding layer is a trainable matrix that uses the embedding ID (identity document) to find the vector for the corresponding row in the matrix. Using the token ID to retrieve the corresponding vector from the embedding layer is token embedding.
[0066] Sequential recommendation means: arranging the above-mentioned time embedding, content embedding, author embedding set (including scientific research embedding and high-order embedding) and token embedding in ascending order according to the author's publication time to form a sequence, and inputting the embedding vectors sorted by time series into the collaborative relationship prediction model based on sequential recommendation to predict the author's collaborators.
[0067] Currently, when predicting cooperative relationships, suitable partners are selected manually based on experience. This method is easily affected by subjective factors, resulting in low accuracy of cooperative relationship prediction.
[0068] To avoid the low accuracy associated with manual selection, intelligent recommendation methods can be employed. For example, GCN (graph convolutional networks) link prediction methods can be used to predict collaborative relationships. However, this method analyzes static graphs and fails to capture dynamic information about collaborators, resulting in low prediction accuracy. Furthermore, the prediction process fails to embed the time of collaboration, which results in loss of information about the author's publication date. Furthermore, the model's limited scale makes it difficult to capture more complex features, further reducing the accuracy of the prediction results.
[0069] When using CoBERT (Collaboration Bidirectional Encoder Representations from Transformers) for collaboration prediction, the model does not consider the time when the text was published, resulting in lower prediction accuracy. Furthermore, the model only considers direct collaborators and does not consider higher-order author relationships beyond direct collaboration, making the prediction results less comprehensive. Furthermore, for larger datasets, the VRAM (Video RAM) and computing requirements are too high, making its application on large datasets unrealistic.
[0070] To address these issues, the present invention considers the time factor of the text when predicting collaborative relationships through time embedding, thereby taking into account the dynamic information of collaborators and improving the accuracy of the prediction results. Furthermore, in addition to considering direct collaborators, the present invention also considers higher-level indirect collaborators, improving the comprehensiveness of the prediction results.
[0071] In addition, the present invention utilizes the powerful understanding and generation capabilities of large language models. Specifically, the transformer-based language model can understand and parse complex language structures and contexts. By treating the collaborator sequence as a language, the capabilities of the large language model are fully utilized. At the same time, compared with the graph neural network model, the transformer-based language model is easy to scale up. When there is sufficient computing power and a large data set, the large-scale transformer language model can capture more complex features, further improving the accuracy of the prediction results.
[0072] Based on the above content, the present invention provides a method, device and electronic device for predicting cooperative relationships based on sequence recommendation. In the present invention, when predicting cooperative relationships, the dynamic changes of the text corresponding to the author over time are described by time embedding, the historical cooperative relationship between the author and the collaborator is considered by the author's high-order embedding, and the core description of the text is represented by content embedding. Then, based on the time embedding, the content embedding, the author embedding set and the token embedding, when predicting the collaborators of the target author, the cooperative relationship can be predicted from multiple angles to improve the accuracy of the prediction. In addition, the present invention does not directly use one author as a sequence token, but configures multiple tokens for the author to obtain multiple token embeddings corresponding to the author. This can save computing resources during model training and can also achieve cooperative relationship prediction in scenarios with a large number of authors, with high accuracy and reliability and high efficiency.
[0073] Reference Figure 1 The embodiment of the present invention provides a method for predicting cooperative relationships based on sequence recommendation, referring to Figure 1 , which may include:
[0074] S11. Obtain the target author for whom cooperation relationship prediction is to be performed.
[0075] In this embodiment, the target author is the author for whom sequence recommendation-based cooperative relationship prediction is required, and there may be one or more target authors. If there are more than one target author, prediction is performed independently for each target author.
[0076] After identifying the target author, you need to obtain the target author's published texts. Published texts can include published papers (scientific or non-scientific), applied patents, new drug applications, published technological achievements, or published reviews.
[0077] For a text, you can obtain its specific content, or only obtain key content, such as title, abstract, keywords and other information.
[0078] It should be noted that before predicting cooperative relationships based on sequence recommendations, it is necessary to solve the problem of multiple authors with the same name and authors with the same name from different institutions, that is, to normalize the authors. For example, if author A (such as Zhang San) publishes texts using the pseudonyms Zhang Yier, Zhang Zhang, and Zhang San, then the author of the texts published by Zhang San using all pseudonyms needs to be unified as Zhang San. In addition, it is necessary to distinguish whether Zhang San with the same name from multiple institutions is the same author Zhang San. This is to avoid missing some texts when counting the texts corresponding to the author, and to avoid counting the output of different authors as one author.
[0079] S12: Calculate the time embedding and content embedding of the text published by the target author.
[0080] In this embodiment, time embedding refers to the embedding vector corresponding to the time when the text is published, and content embedding refers to the embedding vector corresponding to the text content.
[0081] In practical applications, time embedding is determined based on the time when the text was published, and content embedding is determined based on the key content of the text.
[0082] Specifically, when using the Transformer for predicting partnerships based on sequential recommendations, the Transformer's traditional position encoding is an absolute position encoding. The encoding of each position is only related to its position and the maximum length set by the model. It is pre-given and non-trainable. In this embodiment, this position encoding is modified to a time encoding.
[0083] In the text sequence corresponding to the target author, each text has a publication time, which can be directly queried, such as the publication time of March 2011, July 2023, etc. A text has a publication time. The publication time of text i can be recorded as P is text, such as a paper, etc. The time is in years and is retained to the month.
[0084] Because an author publishes multiple texts, such as papers, a single text may have multiple authors. Table 1 shows examples of text publication times and corresponding author combinations. Multiple authors are associated with a single text, so we first replicate the time of each text multiple times to align the text time series with the author time series. The first author in the author sequence in Table 1 is the author, and their time is set to zero. The padding time at the end of the sequence is set to a large value.
[0085] Table 1
[0086]
[0087] It should be noted that for multiple authors in the same text, their time codes are the same, and due to the characteristics of the transformer, it is impossible to distinguish their order. Therefore, multiple authors in the same text are order-independent.
[0088] Based on Table 1, the text disclosure time t k The subscript k in represents the subscript of the author sequence. For example, in the table above, t0 = 0, t4 = March 2011.
[0089] When calculating time embedding, we can first determine the publication time of the text, that is, determine the above t k , since the original t k It is a date, and the value is large. In order to facilitate subsequent calculations, it is necessary to normalize the public time to obtain the intermediate time. Specifically, the numerical range is reduced by translation and scaling. For example, if the beginning of 2000 is set as the time origin and each year is represented by 0.3, then October 2021 can be expressed as [(2021-2000)+10 / 12]×0.3=6.55, that is, t k In October 2021, the corresponding middle time is 6.55.
[0090] After determining the middle, the next step is to determine the time embedding value corresponding to the middle time to obtain the time embedding of the text.
[0091] Specifically, the "text disclosure time" is encoded as a "time embedding". The dimension of the time embedding is equal to the embedding dimension of the model, and the length is equal to the sequence length. Each dimension is a trigonometric function with different periods. In trigonometric functions, odd dimensions are sine functions and even dimensions are cosine functions. Let the embedding dimension be D, and use represents the kth element of the dth dimension of the time embedding, where d is the number of the dimension and k is the number of the sequence element, then:
[0092]
[0093] in,
[0094]
[0095] Then we can use the formula to calculate the kth element of the dth dimension Then by combining each Get the time embedding of each text
[0096] In this embodiment, by calculating time embedding, scientific research collaboration is regarded as a series of time-related sequences, which includes dynamic information that changes over time, such as changes in the author's scientific research interests and changes in collaborative relationships. Compared with static graphs, it can consider the dynamic changes of text over time.
[0097] After calculating the time embedding, we also need to calculate the content embedding.
[0098] Specifically, key information of the text, such as title, abstract, keywords and the like, can be directly extracted from the text content or directly obtained.
[0099] Then, the embedding vector of the key information is calculated as the content embedding of the text.
[0100] Specifically, the key information is constructed into a prompt sentence with a fixed pattern. The prompt sentence can be, for example, the title is ******, the summary is ******, and the keywords are *******.
[0101] Then, we use the text vector generation model to generate a fixed-size embedding vector corresponding to the prompt sentence. Specifically, we can use the pre-trained model all-mpnet-base-v2 of SentenceTransformers (a neural network model and tool library for organizing natural language) to calculate the embedding vector. The embedding vector is recorded as content embedding. The embedding of text i can be recorded as When the content embedded is too long, the fixed-size vector at the front is truncated and the subsequent vectors are directly discarded, thus ensuring the consistency of the embedded content length.
[0102] It should be noted that the calculation of time embedding and content embedding in this embodiment has no particular order and can be performed simultaneously or sequentially. There is no requirement for the order of execution.
[0103] S13. Determine the author embedding set of the target author.
[0104] In this embodiment, the author embedding set includes the scientific research embedding and high-level embedding of the target author.
[0105] In other words, in this invention, when determining the author embedding set, not only the author's own research embedding is considered, but also the research embedding of collaborators. In this embodiment, collaborators refer to direct or indirect collaborators of the target author. In other words, all authors who have a direct or indirect collaborative relationship with the target author are considered collaborators.
[0106] For example, refer to Figure 2 , Figure 2Figure 1 is a schematic diagram of a document co-authorship network. The target author is A, whose direct collaborators are B and C, B's direct collaborators are D and E, and D's direct collaborator is F. In this example, when predicting collaboration for target author A, the author embedding set used includes the research embedding of target author A as well as the research embeddings of B, C, D, and E. This means that only direct collaborators and their direct collaborators are included.
[0107] In another implementation of the present invention, referring to Figure 3 , step S13 may include:
[0108] S21. Acquire co-authors who collaborate with the target author.
[0109] by Figure 2 For example, collaboration refers to direct or indirect collaboration. The direct collaborators of target author A are B and C, and the direct collaborators of the direct collaborator are D and E.
[0110] S22. Calculate the scientific research embedding of the target author based on the content embedding.
[0111] In this embodiment, the author embedding set can be pre-configured in a calculation method. In this embodiment, the text written by the author is directly related to the author, so the scientific research embedding can be determined based on the content embedding of the text.
[0112] Specifically, the weighted average of the content embedding attenuated over time is calculated to obtain the scientific research embedding of the target author.
[0113] In this embodiment, scientific research embedding refers to the weighted average of content embedding, and the scientific research embedding of an author can be calculated based on all the author's texts. The scientific research embedding of author j is denoted as R stands for research.
[0114] In practical applications, the weighted average of the content embeddings of all the author's texts is calculated to obtain the scientific research embedding.
[0115] In addition to the method for determining scientific research embedding in this embodiment, all the author's content embeddings can also be input into the model to obtain scientific research embedding. This method takes into account the changes in the text, and not only considers the author's past research direction but also reflects the author's latest research direction. It also considers the changes in the author's influence over time, so that scientific research embedding can be determined more quickly and accurately.
[0116] S23. Calculate the scientific research embedding of the co-authors.
[0117] The calculation process of the research embedding of the co-author is similar to that of the target author. Please refer to the corresponding instructions above.
[0118] S24. Calculate the high-order embedding of the target author using the scientific research embeddings of the co-authors and the author collaboration graph structure.
[0119] Among them, the author cooperation relationship graph structure can be as follows Figure 2 As shown in Figure 2, high-order embeddedness refers to the scientific research embeddedness of co-authors who have direct or indirect cooperation relationships with the target author.
[0120] In this embodiment, for the sake of computational convenience, only direct collaborators and their direct collaborators are selected when selecting collaborators, i.e., with the target author as the core, a two-layer collaboration relationship is considered. Alternatively, three or more layers of collaboration may be selected as needed.
[0121] In this embodiment, a two-layer cooperative relationship is taken as an example. Figure 2 For the target author A, we consider the direct cooperation relationship between A and B and C, and also consider the indirect cooperation relationship with D and E. This indirect cooperation relationship is a high-order cooperation.
[0122] The calculation process of the scientific research embedding of B, C, D, and E is the same as that of the scientific research embedding of A. The scientific research embedding of B, C, D, and E is the high-order embedding in this embodiment.
[0123] In this embodiment, not only the first-order neighbors of the author are considered, but also the high-order neighbors of the author are incorporated into the sequence as features, which is equivalent to having a wider field of view from the perspective of the graph.
[0124] S25. Combining the scientific research embedding and high-order embedding of the target author to obtain an author embedding set.
[0125] After obtaining the research embedding and high-order embedding of the target author, they are directly combined to obtain the author embedding set.
[0126] Taking the target author A as an example, the author embedding set of A is initialized as:
[0127] Scientific research embedding of A, B, C, D and E.
[0128] In this embodiment, when calculating the author embedding set, higher-order collaborators are taken into consideration, so that when performing subsequent collaborative relationship prediction based on sequence recommendation, not only authors with whom the author has collaborated in the past can be predicted, but also authors with whom the author has not collaborated in the past can be predicted.
[0129] S14. Obtain multiple tokens configured for the target author, and query the token embedding corresponding to the token.
[0130] Specifically, the above embodiment is a relatively simple method of corresponding one author to one token, so there is no need for a Tokenizer (a tokenizer is a method of generating tokens from the original sequence, also called a word segmenter). During model training, when the number of authors is not too large, that is, tens of thousands to hundreds of thousands, the method of corresponding one author to one token is effective. If the number of authors is much larger than this number, for example, there are millions of authors, corresponding to millions of tokens, then the token content in the formed token dictionary will be relatively large, and it will also lead to excessive GPU (Graphics Processing Unit) and video memory usage. The video memory of a single GPU is difficult to carry a large number of tokens, making the present invention unable to be applied to large data sets.
[0131] Therefore, to avoid the problem of model training being unable to achieve sufficient results with too many tokens when there are a large number of authors, this example uses a tokenizer for natural language models to segment each author into multiple "author segments." Each author is represented by multiple tokens in the token dictionary. By allowing different authors to share tokens, the author's one-hot encoding is appropriately densified into a multi-hot encoding. Because the segmentation fully considers the characteristics of the authors, tokens of similar authors are also similar. This better captures the correlation between authors and improves model performance.
[0132] When each author is represented by multiple tokens, Figure 4 For example, each author is represented by 3 tokens. Figure 4 Each element in the last three rows of the table in [1] is split into three, tripling the sequence length. The superscripts in rows e and h indicate whether it is the 0th, 1st, or 2nd of the three tokens representing an author.
[0133] Depend on Figure 4 As can be seen from the table, for a target author, there are content embedding, time embedding, author embedding set (including scientific research embedding and high-order embedding) and token embedding. Figure 4 For example, the table in gives examples of five embeddings.
[0134] Combining the text's content embedding, time embedding, author embedding set (including research embeddings and high-order embeddings), and token embedding yields a collaborator sequence. The first position in this sequence is the author, acting as a starting symbol. The list of co-authors is then sorted chronologically.
[0135] It should be noted that The target author's token is embedded, and the co-author's token is encoded as Figure 4 As shown in the table.
[0136] The last row h is the data to be input into the model, that is, the obtained collaborator sequence, which is e A row, e T row, e R row, e H The sum of the contents of line 1 and line e:
[0137] h=e A +e T +e R +e H +e
[0138] in, And so on.
[0139] In order to achieve the token embedding representation of the author, refer to Figure 5 , step S14 may include:
[0140] S31. Obtain the preset number of split tokens.
[0141] In this embodiment, the preset number of split tokens is the number of tokens that an author is split into, which is represented by t. Generally, it is set based on experience, such as 2, 3 or 4.
[0142] S32. Perform a dimensionality reduction operation on the sparse matrix representing the relationship between the author and the text to obtain a token dictionary constructed based on quantization accuracy and a preset number of split tokens. Based on the token dictionary, configure multiple tokens for the target author.
[0143] In this embodiment, the dimensionality reduction operation can be performed using two methods: one is the truncated singular value decomposition (TSVD) method, and the other is the β-VAE (β-variational autoencoder) method. Both methods are now introduced.
[0144] 1. Truncated singular value decomposition method
[0145] The calculation formula of truncated singular value decomposition is:
[0146] M≈PΣE T
[0147] Where M is a sparse matrix of text-author relationships, where 0 indicates no relationship and 1 indicates a relationship. P is an m×t text relationship embedding matrix, where m is the number of authors and t is the number of tokens to be split, i.e., the number of tokens to be decomposed for each author. T is a t×n author relationship embedding matrix, where n is the number of texts; Σ is a t×t diagonal matrix with the t largest singular values on the diagonal.
[0148] The truncated singular value decomposition is based on the singular value decomposition (SVD) method. In the singular value decomposition, the square matrix M T M and MM T have the same eigenvalue λ i , whose standardized eigenvectors are p i and e i .Right now:
[0149] M T Mp i =λ i p i
[0150] MM T e i =λ i e i
[0151] All eigenvectors p i and e i They form matrices P and E respectively T . Singular values Construct a singular value diagonal matrix Σ. σ i The corresponding eigenvector is called a singular vector, indicating the direction in which the matrix stretching effect is strongest. T , which constitutes the singular value decomposition of M.
[0152] Compared with the singular value decomposition, the truncated singular value decomposition only takes the largest first t singular values to form a new diagonal matrix Σ, and the corresponding eigenvectors to form new P and E T , therefore, the corresponding PΣE T It will be an approximation of M, that is, M≈PΣE T .
[0153] In the truncated singular value decomposition, the singular vectors need to be processed into token numbers. Specifically, the values of the E matrix are first normalized by author, so that each value is between 0 and 1.
[0154] Then add a mean of 0 and a variance of 10 to the E matrix -2Gaussian noise is added to the dataset, making the embeddings of any two authors different. This is to handle cases where token numbers are repeated. For example, if a text has two authors and they have no other texts, the two authors are indistinguishable from the perspective of the text-author relationship alone, resulting in the same embeddings calculated by truncated singular value decomposition. Adding Gaussian noise can avoid duplicate token number tuples for authors.
[0155] In the truncated singular value decomposition, the E matrix also needs to be quantized. Specifically, each vector is quantized. The 0-1 values in the vector are divided into v steps and quantized to values 0 to v-1, where v is the quantization precision.
[0156] The quantization values of different dimensions are offset so that different dimensions use quantization values in different ranges. For example, the quantization value of the 0th dimension is 0~v-1, the quantization value of the 1st dimension is v~2v-1, and so on. Thus, v·t different tokens are obtained as a dictionary. Each author is composed of t tokens in the dictionary, so that the Token dictionary can be used to configure multiple tokens for the target author. Specifically, after constructing the Token dictionary, for each author in the author set, based on its quantization value, the quantized value is selected from v steps and quantized to a value of 0~v-1 respectively.
[0157] By offsetting the quantization values of different dimensions, different ranges of quantization values are used for different dimensions. For example, the quantization value of the 0th dimension is 0 to v-1, the quantization value of the 1st dimension is v to 2v-1, and so on. This results in t (t is the preset number of tokens to be split) tokens.
[0158] In addition to using truncated singular value decomposition (SVD), principal component analysis (PCA) can also be used. PCA and truncated singular value decomposition (SVD) can effectively decompose the characteristics of the source data into independent dimensions for dimensionality reduction. These two linear methods are simple and perform poorly when dealing with complex nonlinear relationships. Therefore, β-VAE can be used when dealing with complex nonlinearities. The choice of method can be determined by the technician based on the actual situation.
[0159] 2. β-VAE
[0160] In this example, β-VAE is used to generate a very low-dimensional embedding for the author, and the number of dimensions is used as the decomposition number. For example, if each author is decomposed into 8 tokens, an 8-dimensional author embedding is generated.
[0161] When decomposing, the following goals should be achieved:
[0162] Authors with similar author relationships should have more common tokens. Therefore, embedding should effectively decompose the features of the source data into various dimensions that are independent of each other.
[0163] In order to improve the ability to capture complex relationships, the β-VAE method is introduced in the graph node embedding calculation. The embedding generated by β-VAE has the characteristic of effectively decoupling independent features.
[0164] VAE is a generative model that approximately models the data generation process as a probability distribution process through variational inference. The model is encouraged to make the potential representation of each observed data as close to the standard Gaussian distribution as possible, that is, to make each dimension of the potential representation close to an independent Gaussian distribution.
[0165] β-VAE is a variation of the VAE model. Its parameter β can adjust the weight of the KL (Kullback-Leibler) divergence part, which means that the model pays more attention to the feature decoupling of the latent space.
[0166] When using β-VAE to decompose tokens, in order to better decouple features and have lower requirements for reconstruction error, you can choose a value of β>1 to increase the weight of the KL divergence part to better decouple features. Figure 6 This is the network structure diagram of VAE. Where μ is the mean of the Gaussian distribution of the latent variable, and σ is the standard deviation of the Gaussian distribution of the latent variable.
[0167] For a set of observation data X={x1,x2,…,x n}, assume that a generative model p(x|z) is used to describe the relationship between X and a latent variable Z, which has a prior distribution p(z), which is assumed to be a standard Gaussian distribution.
[0168] The training goal of VAE is to maximize the marginal log-likelihood of the observed data logp(x). Since direct calculation is not feasible, variational inference is used to approximate it, that is, the variational posterior distribution q(z|x) is introduced to approximate the true prior distribution p(z|x). q(z|x) is also modeled as a Gaussian distribution and output by the encoder. Deform logp(x):
[0169]
[0170] Where the first term is the expectation of the conditional log-likelihood of the data, denoted as The second term is to add the expectation of the prior, and the third term is to subtract the entropy of the variational posterior. Overall, it is to subtract the KL divergence D between the prior and the variational posterior. KL (q(z|x)||p(z)). Therefore, the above formula can be written as:
[0171]
[0172] The right side of the inequality is called the Evidence Lower Bound (ELBO). In VAE, logp(x) is approximately maximized by maximizing the evidence lower bound. In β-VAE, a parameter β is added to the KL divergence term of ELBO:
[0173]
[0174] The optimization objective of β-VAE is the ELBO mentioned above. A larger β means that the optimization objective places more emphasis on KL divergence.
[0175] The training steps are as follows:
[0176] 1) Set the potential layer dimension to the number of tokens to be decomposed, t;
[0177] 2) The rows representing each author in the sparse matrix M of the document-author relationship are used as the sparse embeddings of the author and fed into the β-VAE model, with the model output being able to restore the input. Graph convolution can also be used to obtain the input vector, but this approach complicates the model.
[0178] 3) Conduct model training;
[0179] 3.1) Take the mean output of the VAE latent layer as the data after dimensionality reduction;
[0180] 3.2) Add noise, normalize, and quantize, and also set a quantization precision v;
[0181] Through the above steps, v·t different tokens can be obtained as a dictionary, that is, a token dictionary. All authors are composed of t tokens in the dictionary, so that multiple tokens can be configured for the target author using the token dictionary.
[0182] S33. Input each Token into the embedding layer to obtain the Token embedding corresponding to the Token.
[0183] Specifically, the embedding layer is used to process the Token to obtain the Token embedding corresponding to the Token, and each Token corresponds to a Token embedding.
[0184] S15. Predict the collaborators of the target author based on the time embedding, the content embedding, the author embedding set, and the token embedding.
[0185] Wherein, the collaborator is composed of multiple Tokens.
[0186] In practical applications, after the content embedding, time embedding, author embedding set and the multiple token embeddings (determined based on tokens, which can actually be token ids) are known, a partnership prediction model based on sequence recommendation can be used to predict partnerships.
[0187] In this embodiment, the pure decoder of the GPT (Generative Pre-Trained Transformer) model can be used as the cooperative relationship prediction model based on sequence recommendation. The structure of the cooperative relationship prediction model based on sequence recommendation is as follows: Figure 7 shown.
[0188] The generation process of the cooperative relationship prediction model based on sequence recommendation includes:
[0189] 1) Obtain training samples.
[0190] The training samples include a combination of time embedding, content embedding, author embedding set and token embedding corresponding to different authors. In this embodiment, the author name can be replaced with the id in the dictionary to achieve uniformity.
[0191] Specifically, we can obtain a large number of authors and the texts corresponding to them, and calculate the time embedding and content embedding for each text. Then, for each author, we use the truncated singular value decomposition method or β-VAE method to split the author and obtain multiple token embeddings. For details, please refer to Figure 4 The table in .
[0192] After knowing the time embedding, content embedding, author embedding set, and token embedding, for each author, determine its input data h, that is, the collaborator sequence.
[0193] 2) Based on a preset training method, the training samples are used to perform a training operation on the cooperative relationship prediction model based on sequence recommendation until a training stop condition is met.
[0194] During specific training, it is necessary to divide the data into training sets and test sets. The version without the last element in the input data h is used as the training set, and the version containing the last element is used as the test set.
[0195] During training, the model outputs each element in the training set and predicts the next element. When testing the model, the output of the second-to-last element in the test set is tested to see if it is the last element.
[0196] During training, refer to Figure 8, using a "teacher-forcing" training method. Specifically, because each author uses multiple tokens, during training, the classification output for each author in the sequence is forced to be the next author. Specifically, the output of an author's first token is the first token of the next author, the output of the second token is the second token of the next author, and so on. This is equivalent to an author at any position using all information about themselves and the previous sequence to predict the next collaborator, without knowing the information behind them. Cross-entropy loss is used to achieve this goal. Figure 8 Shown is the relationship between the training set input data and labels during training. Figure 8 Each author has four tokens, represented by four squares filled with the same fill. The upward arrows represent the inference of the output data above from the input data below. As can be seen, the labels used for training are formed by shifting the original input sequence by four positions.
[0197] The training stop conditions during training can be configured according to actual conditions, such as when the cross entropy loss is less than a preset threshold or when the number of training times reaches a threshold.
[0198] In addition, during training, we incorporate label smoothing regularization and employ dropout (discarding some data) to prevent model overfitting and improve generalization. This also prevents the model from being overconfident in its output, which could reduce the diversity of recommendation results.
[0199] During training, a classifier is set after the cooperative relationship prediction model based on sequence recommendation, and the cooperative relationship prediction model based on sequence recommendation and the classifier can be trained at the same time.
[0200] Specifically, the classifier in the embodiment of the present invention adopts the k-best-crf algorithm (conditional random field algorithm of k optimal paths). The operation logic of the k-best-crf algorithm is shown in Figure 9 Where k is the path length, which can be t, and γ is the number of classification labels.
[0201] The k-best-crf algorithm does not calculate the optimal token for each j∈k individually, but instead finds an optimal path among the k-dimensional tokens. This algorithm makes the predicted k tokens more representative of the true author.
[0202] In actual calculation, in order to reduce the search space, the matrix a in the k-best-crf algorithm i,j (i∈γ,j∈k) stores the sum of all paths from j=1 to the current Token. After this planning algorithm, the search space is expanded from γ k Reduce the dimension to γ×k.
[0203] After training is complete, the training effect is tested using the test set. Each sequence in the test set has one more author (t tokens) than the training set. During testing, the classification output of the second-to-last author in the test set is counted to see if it matches the last author to determine whether the training meets the requirements.
[0204] If the test set fails to meet the requirements, retraining is performed. If it does, the model is used to predict collaborations based on sequence recommendations. The model's author classification prediction output is the next t tokens in the current sequence that will form the next collaborator. After classification calculations, the authors with the highest probability scores are selected as potential collaboration partners.
[0205] After obtaining the model, the time embedding, the content embedding, the author embedding set, and the token embedding can be combined to obtain input data, which is then sequentially input into a sequence-based recommendation-based collaboration prediction model to obtain a collaboration score for the target author. A classifier is then used to classify the collaboration score to obtain collaboration data.
[0206] The output of the k-best-crf algorithm is any of the following:
[0207] 1) The top five authors ranked by probability score;
[0208] 2) The authors whose probability scores accumulate to a preset value from high to low are ranked. For example, the probability scores are accumulated in descending order. When the accumulated score reaches 80, all the accumulated authors are predicted collaborators.
[0209] 3) Collaborators whose probability score is greater than the preset score threshold;
[0210] 4) Select several of the historical collaborators and several of the ones with whom the partners have not collaborated in the past, so as to diversify the recommendation methods.
[0211] 5) Recommend authors who rank high among authors from different ranges, such as those from the same department or the same city.
[0212] For example, the model output can be as follows:
[0213] Cooperate with Wang Wu in May 2023 and cooperate with Sun Liu in June 2023.
[0214] In practical applications, the model's input data is h, which is the aforementioned time embedding, content embedding, and author embedding set, along with token embedding. For each author, the input data h is determined, consisting of the time embedding, content embedding, author embedding set, and token embedding. The output collaborators are similar to h, also consisting of the time embedding, content embedding, author embedding set, and token embedding. Token embedding can be used to predict collaborators. This means that collaborator prediction is achieved through the present invention.
[0215] As can be seen from the above, the present invention utilizes the co-authorship relationship formed by the authors of documents in the field to construct a document co-authorship network, and embeds the semantic information of the document (such as the key information mentioned above), time information and author information into the network nodes. The multi-head, high-dimensional information of the cooperation network is extracted through the Transformer decoder sequence model to predict the collaborators of a certain author, the time of cooperation and the topic of the cooperation text.
[0216] In this embodiment, when predicting cooperative relationships, time embedding is used to describe the dynamic changes of the text corresponding to the author over time, the historical cooperative relationship between the author and the collaborator is considered through the author's high-order embedding, and the core description of the text is represented through content embedding. Then, based on the time embedding, the content embedding, the author embedding set and the token embedding, when predicting the collaborators of the target author, the cooperative relationship can be predicted from multiple angles, thereby improving the accuracy of the prediction.
[0217] In addition, the present invention does not directly use one author as a sequence token, but configures multiple tokens for the author, uses multiple tokens to represent one author, and obtains multiple token embeddings corresponding to the author. This can save computing resources during model training, and can process a large number of authors with a smaller dictionary size, thereby realizing cooperative relationship prediction in scenarios with a large number of authors, with higher accuracy, reliability, and efficiency.
[0218] In addition, using the optimized Token decomposition method, compared with the one-hot representation method of a single token, the multi-hot (multi-hot encoding) representation method of multiple tokens has a certain degree of densification and carries richer feature information, thereby making the prediction results more accurate.
[0219] In order to verify the prediction feasibility and prediction effect of the cooperative relationship prediction method based on sequence recommendation of the present invention, another embodiment of the present invention carried out the following verification experiment.
[0220] 1. Experimental Dataset
[0221] We retrieved 855,120 articles from the Web of Science database, limiting the literature types to articles, reviews, and conference proceedings (including articles, reviews, proceeding papers, letters, and meeting abstracts). We extracted author information and inter-author collaborations from these articles. Data preprocessing included removing anonymous authors and normalizing the author list by filtering out authors with the name "[anonymous]." Furthermore, we normalized the author list using the author's email address, as provided in the bibliographic information.
[0222] 2. Experimental Evaluation Indicators This invention adopts the HR (Hits Rati) and NDCG (Normalized Discounted Cumulative Gain) indicators used in evaluating recommendation algorithms.
[0223]
[0224] Where N is the length of the test sample, and hits(i) indicates whether the i-th recommendation result is in the test sample, which is 1 if it is, and 0 if it is not. HR emphasizes the accuracy of the prediction results. When N is the evaluation length K, it is specifically expressed as HR@K.
[0225]
[0226] Where N is the length of the test sample, p i is the position of the i-th recommendation result in the test sample. If this value does not exist in the test sample, then p i →∞. NDCG places greater emphasis on the accuracy of the order of prediction results. When N is the evaluation length K, it is specifically expressed as NDCG@K.
[0227] 3. Experimental benchmarking model
[0228] In order to compare the innovation of the present invention, the present invention is compared with the CoBERT model experiment. The comparison results are shown in Table 4.
[0229] Table 4
[0230]
[0231]
[0232] 4. Experimental Results
[0233] Table 5
[0234]
[0235] The experimental results show that:
[0236] (1) In this experimental data set, the various indicators of the present invention far exceed those of the Cobert model;
[0237] (2) In the Dropout comparison experiment, the model works best when Dropout=0.3, which shows that appropriately discarding some data can enhance the robustness of the model;
[0238] (3) In the feedforward width comparison experiment, the best effect is achieved when the width is 1024 in 4 layers. This shows that when the input vector dimension of this model is around 1000, the width of 1024 can avoid data loss (512 width) and can also avoid embedding too much padding.
[0239] (4) In the head number comparison experiment, the number of heads in the transformer is 8 and 16, which shows that the appropriate number of heads can capture more data without causing overfitting of the model;
[0240] (5) In the layer comparison experiment, the effect is better at 2 and 4 layers, which shows that the present invention can achieve better results when the number of layers is small, even if the parameters of the model are relatively small.
[0241] Based on the above embodiment of the cooperative relationship prediction method based on sequence recommendation, another embodiment of the present invention provides a cooperative relationship prediction device based on sequence recommendation, referring to Figure 10 , which may include:
[0242] The author acquisition module 11 is used to acquire the target author for cooperation relationship prediction;
[0243] an embedding calculation module 12, for calculating the time embedding and content embedding of the text published by the target author;
[0244] A set determination module 13 is configured to determine an author embedding set of the target author, wherein the author embedding set includes the research embedding and high-order embedding of the target author; the high-order embedding is the research embedding of co-authors who have a direct or indirect cooperative relationship with the target author;
[0245] The embedding acquisition module 14 is used to acquire multiple tokens configured for the target author and query the token embedding corresponding to the token;
[0246] The author prediction module 15 is configured to predict the collaborators of the target author based on the time embedding, the content embedding, the author embedding set, and the token embedding; the collaborators are composed of multiple tokens.
[0247] In an optional implementation, when the embedding calculation module 12 is used to calculate the time embedding of the text published by the target author, it is specifically used to:
[0248] Determine the publication time of the text, perform a standardization operation on the publication time to obtain an intermediate time, determine a time embedding value corresponding to the intermediate time, and obtain the time embedding of the text.
[0249] In an optional implementation, when the embedding calculation module 12 is used to calculate the content embedding of the text published by the target author, it is specifically used to:
[0250] The key information of the text is obtained, and an embedding vector of the key information is calculated as the content embedding of the text.
[0251] In an optional implementation, the set determination module 13 includes:
[0252] An author acquisition submodule is used to acquire co-authors who have collaborated with the target author; the collaboration includes direct collaboration or indirect collaboration;
[0253] A first embedding calculation submodule, configured to calculate the scientific research embedding of the target author based on the content embedding;
[0254] A second embedding calculation submodule, for calculating the scientific research embedding of the co-author;
[0255] A third embedding calculation submodule is used to calculate the high-order embedding of the target author using the scientific research embeddings of the co-authors and the author collaboration graph structure;
[0256] The set determination submodule is used to combine the scientific research embedding and high-order embedding of the target author to obtain an author embedding set.
[0257] In an optional implementation, the first embedded computing submodule is specifically configured to:
[0258] The weighted average of the content embeddings decayed over time is calculated to obtain the scientific research embedding of the target author.
[0259] In an optional implementation, the embedding acquisition module 14 includes:
[0260] The data acquisition submodule is used to obtain the preset number of split tokens;
[0261] The token configuration submodule is used to perform a dimensionality reduction operation on the sparse matrix representing the relationship between the author and the text, obtain a token dictionary based on quantization accuracy and a preset number of split tokens, and configure multiple tokens for the target author based on the token dictionary;
[0262] The embedding determination submodule is used to input each token into the embedding layer to obtain the token embedding corresponding to the token.
[0263] In an optional implementation, the author prediction module 15 includes:
[0264] a combining submodule, configured to combine the time embedding, the content embedding, the author embedding set, and the token embedding to obtain input data;
[0265] A score determination submodule is used to sequentially input the input data into a cooperative relationship prediction model based on sequence recommendation to obtain a cooperative relationship score of the target author;
[0266] The classification submodule is used to use a classifier to perform a classification operation on the cooperation relationship score to obtain the collaborator.
[0267] An optional implementation further includes:
[0268] The model training module is used to obtain training samples, which include a combination of time embeddings, content embeddings, author embedding sets, and token embeddings corresponding to different authors; based on a preset training method, the training samples are used to train the sequence-based recommendation-based partnership prediction model until the training stop condition is met.
[0269] In this embodiment, when predicting collaborative relationships, the dynamic changes in the text corresponding to the author over time are described through time embedding, the historical collaborative relationship between the author and the collaborator is considered through the author's high-order embedding, and the core description of the text is represented through content embedding. Then, based on the time embedding, the content embedding, the author embedding set, and the token embedding, when predicting the collaborators of the target author, the collaborative relationship can be predicted from multiple angles, thereby improving the accuracy of the prediction. In addition, the present invention does not directly use one author as a sequence token, but configures multiple tokens for the author to obtain multiple token embeddings corresponding to the author. This can save computing resources during model training and can also achieve collaborative relationship prediction in scenarios with a large number of authors, with high accuracy, reliability, and efficiency.
[0270] It should be noted that, for the working process of each module and sub-module in this embodiment, please refer to the corresponding description in the above embodiment, which will not be repeated here.
[0271] Another embodiment of the present invention provides an electronic device, including: a memory and a processor;
[0272] Wherein, the memory is used to store programs;
[0273] The processor calls the program and is used to execute the above-mentioned cooperative relationship prediction method based on sequence recommendation.
[0274] In this embodiment, when predicting collaborative relationships, the dynamic changes in the text corresponding to the author over time are described through time embedding, the historical collaborative relationship between the author and the collaborator is considered through the author's high-order embedding, and the core description of the text is represented through content embedding. Then, based on the time embedding, the content embedding, the author embedding set, and the token embedding, when predicting the collaborators of the target author, the collaborative relationship can be predicted from multiple angles, thereby improving the accuracy of the prediction. In addition, the present invention does not directly use one author as a sequence token, but configures multiple tokens for the author to obtain multiple token embeddings corresponding to the author. This can save computing resources during model training and can also achieve collaborative relationship prediction in scenarios with a large number of authors, with high accuracy, reliability, and efficiency.
[0275] The above description of the disclosed embodiments is intended to enable one skilled in the art to implement or use the present invention. Various modifications to these embodiments will be readily apparent to one skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention is not limited to the embodiments shown herein but is intended to conform to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A cooperative relationship prediction method based on sequence recommendation, characterized in that: include: Obtain the target author for cooperation relationship prediction; Calculating the time embedding and content embedding of the text published by the target author; Determining an author embedding set of the target author, wherein the author embedding set includes the research embedding and high-order embedding of the target author; the high-order embedding is the research embedding of co-authors who have a direct or indirect cooperative relationship with the target author; Get multiple tokens configured for the target author, and query the token embedding corresponding to the token; Predicting collaborators of the target author based on the time embedding, the content embedding, the author embedding set, and the token embedding; The collaborator consists of multiple tokens; Calculate the temporal embedding of the text published by the target author, including: Determine the time of publication of the said text; Performing a normalization operation on the disclosed time to obtain an intermediate time; Determining a time embedding value corresponding to the intermediate time to obtain a time embedding of the text; Calculating the content embedding of the text published by the target author, including: Obtaining key information of the text; Calculating an embedding vector of the key information as content embedding of the text; Get multiple tokens configured for the target author and query the token embedding corresponding to the token, including: Get the preset number of split tokens; Performing a dimensionality reduction operation on the sparse matrix representing the relationship between the author and the text to obtain a token dictionary constructed based on quantization accuracy and a preset number of split tokens. Based on the token dictionary, multiple tokens are configured for the target author. Input each token into the embedding layer to obtain the token embedding corresponding to the token; Predicting collaborators of the target author based on the time embedding, the content embedding, the author embedding set, and the token embedding includes: Combining the time embedding, the content embedding, the author embedding set, and the token embedding to obtain input data; Sequentially inputting the input data into a cooperative relationship prediction model based on sequence recommendation to obtain a cooperative relationship score of the target author; A classifier is used to perform a classification operation on the cooperation relationship scores to obtain the collaborators.
2. The method for predicting cooperative relationships based on sequence recommendation according to claim 1, characterized in that: Determining an author embedding set of the target author, including: Obtaining co-authors who have collaborated with the target author; collaboration includes direct collaboration or indirect collaboration; Calculating the research embedding of the target author based on the content embedding; Calculate the research embedding of the co-authors; Calculate the high-order embedding of the target author using the research embeddings of the co-authors and the author collaboration graph structure; The research embedding and high-order embedding of the target author are combined to obtain the author embedding set.
3. The method for predicting cooperative relationships based on sequence recommendation according to claim 2, characterized in that: Calculating the research embedding of the target author based on the content embedding, including: The weighted average of the content embeddings decayed over time is calculated to obtain the scientific research embedding of the target author.
4. The method for predicting cooperative relationships based on sequence recommendation according to claim 1, characterized in that: The generation process of the cooperative relationship prediction model based on sequence recommendation includes: Obtain training samples, where the training samples include a combination of time embeddings, content embeddings, author embedding sets, and token embeddings corresponding to different authors; Based on a preset training method, the training sample is used to perform a training operation on the cooperative relationship prediction model based on sequence recommendation until a training stop condition is met.
5. A cooperative relationship prediction device based on sequence recommendation, characterized in that: include: The author acquisition module is used to obtain the target author for cooperation relationship prediction; an embedding calculation module, configured to calculate the time embedding and content embedding of the text published by the target author; a set determination module, configured to determine the target author's author embedding set, wherein the author embedding set includes the target author's research embedding and high-order embedding; the high-order embedding is the research embedding of co-authors who have a direct or indirect cooperative relationship with the target author; An embedding acquisition module, configured to acquire multiple tokens configured for the target author and query the token embedding corresponding to the token; An author prediction module, configured to predict collaborators of the target author based on the time embedding, the content embedding, the author embedding set, and the token embedding; The collaborator consists of multiple tokens; Calculate the temporal embedding of the text published by the target author, including: Determine the time of publication of the said text; Performing a normalization operation on the disclosed time to obtain an intermediate time; Determining a time embedding value corresponding to the intermediate time to obtain a time embedding of the text; Calculating the content embedding of the text published by the target author, including: Obtaining key information of the text; Calculating an embedding vector of the key information as content embedding of the text; Get multiple tokens configured for the target author and query the token embedding corresponding to the token, including: Get the preset number of split tokens; Performing a dimensionality reduction operation on the sparse matrix representing the relationship between the author and the text to obtain a token dictionary constructed based on quantization accuracy and a preset number of split tokens. Based on the token dictionary, multiple tokens are configured for the target author. Input each token into the embedding layer to obtain the token embedding corresponding to the token; Predicting collaborators of the target author based on the time embedding, the content embedding, the author embedding set, and the token embedding includes: Combining the time embedding, the content embedding, the author embedding set, and the token embedding to obtain input data; Sequentially inputting the input data into a cooperative relationship prediction model based on sequence recommendation to obtain a cooperative relationship score of the target author; A classifier is used to perform a classification operation on the cooperation relationship scores to obtain the collaborators.
6. An electronic device, characterized in that: include: memory and processor; Wherein, the memory is used to store programs; The processor calls a program and is used to execute the cooperative relationship prediction method based on sequence recommendation as described in any one of claims 1-4.
Citation Information
Patent Citations
Scientific achievement affiliation prediction method and system based on natural language processing and social network
CN116644833A
Theme monitoring method and device, electronic equipment and readable storage medium
CN118070786A