Dependency analysis model and chinese joint event extraction method based on dependency analysis
By fusing syntactic structure information through dependency parsing models and graph convolutional neural networks, the problem of low data processing accuracy and efficiency caused by neglecting syntactic structure in existing technologies is solved, thereby improving the accuracy and efficiency of event extraction.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- MYRON INTELLIGENT TECH (SHANGHAI) CO LTD
- Filing Date
- 2022-04-27
- Publication Date
- 2026-04-24
AI Technical Summary
Existing joint event extraction methods pay little attention to textual semantic information and neglect syntactic structure information when extracting arguments, resulting in low data processing accuracy and efficiency.
A dependency parsing model is adopted, which constructs three types of edges to represent the dependency relationships between words, uses undirected graph representation and combines graph convolutional neural networks to extract events by fusing syntactic structure information.
It improves the extraction of event trigger words and event arguments, alleviates the cascading error propagation problem in traditional pipeline methods, and enhances the deep interaction of information and the flow of information between words.
Smart Images

Figure CN114841140B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the research field of event extraction in information extraction in natural language processing, specifically involving a dependency parsing model and a Chinese joint event extraction method based on dependency parsing. Background Technology
[0002] The rapid development of the internet has brought about massive amounts of data, containing invaluable information. However, quickly locating the desired information from hundreds of millions of data points has always been a pressing problem. Data carriers are diverse, including sound, images, and text. Language, as the most important means of human communication, is studied in a way that helps machines understand human intelligence, thus giving rise to the field of Natural Language Processing (NLP). Text is inseparable from language; the vast majority of human knowledge is recorded and passed down in written form. Therefore, text research has always been a core part of artificial intelligence. Combining the above research areas and problems, information extraction tasks have emerged, used to extract the core information needed by people from text.
[0003] Event extraction, a core task in the field of information extraction, aims to extract events from natural text and represent them in a structured, tabular form. A complete event consists of an event trigger word defining the event type and multiple arguments related to the event; the trigger word and arguments are often entities. Based on the extraction stages, the event extraction task can be decomposed into two sub-tasks: event trigger word extraction and event argument extraction. Event trigger word extraction extracts the keywords (often verbs or nouns) indicating the event type from the text, while event argument extraction extracts all arguments related to the event based on the known event trigger word and event type. For the complete event extraction task, the traditional pipeline method executes these two sub-tasks sequentially; however, this method suffers from a significant cascading error propagation problem.
[0004] To mitigate the cascading error propagation problem inherent in pipeline-based event extraction methods, joint event extraction models have emerged that train two subtasks using the same pattern. However, existing joint event extraction methods focus solely on semantic information when extracting arguments, paying little attention to syntactic structure information. Therefore, how to incorporate syntactic structure information into the encoding process to guide information extraction is of significant research value. Summary of the Invention
[0005] The technical problem to be solved by this invention is to provide a dependency parsing model and a Chinese joint event extraction method based on dependency parsing, which solves the problem that the event argument extraction algorithms involving syntactic structure information in the prior art have little impact on the accuracy and efficiency of data processing.
[0006] To solve the above-mentioned technical problems, the present invention adopts the following technical solution:
[0007] A method for constructing a dependency parsing model based on text representation is proposed. First, the text is segmented into words, and dependency parsing is used to obtain the master-slave relationship between words, establishing the dependency relationship between words. Second, three types of edges are constructed, and three two-dimensional adjacency matrices are generated for each type of edge to construct a graph representation, which is represented by an undirected graph. Then, the initial text representation is input into a graph convolutional neural network, and neighbor node information is aggregated using the undirected graph. The output of the convolutional neural network is fused with the initial text representation. Finally, the classification vector obtained after fusion is used as the output of the model.
[0008] The specific process of representing dependency relations using undirected graphs is as follows:
[0009] The dependency relationships between words are simplified to the dependency relationships between the first characters of words, and three types of edge representations are constructed, namely e along e loop e rev A two-dimensional adjacency matrix is constructed for the three types of edges according to the pre-established dependency relationships, and the dependency relationships are abstracted into an undirected graph representation. The adjacency matrix uses single characters as nodes. If there is a relationship between two nodes, the value of the corresponding position in the adjacency matrix is set to 1, and otherwise it is set to 0.
[0010] The specific process of fusing to obtain the classification vector is as follows:
[0011] The obtained word embedding text representation is used as the initial input to the graph convolutional neural network. The neighbor node information is aggregated by combining the undirected graph to calculate the graph convolution vector. The graph convolution vectors of the three edge types are concatenated and the node vector of the (k+1)th layer is updated using the activation function. The output of the last layer of the graph convolutional network is combined with the word embedding text representation to obtain the final classification vector, where k represents the number of graph convolution layers.
[0012] Calculate the graph convolution vector using the following formula.
[0013]
[0014] Where v represents the currently updated node, K(v,u) indicates the type of the current edge, corresponding to e along e loop e rev There are three types: N(v,K(v,u)) is the set of neighboring nodes of the current node on the current edge, which is the part of the two-dimensional adjacency matrix with a value of 1. and These are the weight matrix and offset parameters for node and edge type constraints.
[0015] In the dependency parsing described above, the official toolkit Stanford CoreNLP is used to perform dependency parsing on Chinese text. First, the Chinese text is segmented into words, and then dependency parsing is used to obtain the Chinese syntactic dependency relationships between the governing words and the subordinate words at the word level.
[0016] A method for extracting Chinese joint events based on dependency parsing includes the following steps:
[0017] Step 1: Preprocess the input text, which includes the event type and a description of the event. Use a pre-trained language model to encode the text in the dataset to obtain the initial text representation of the model.
[0018] Step 2: Segment the original input text into words, and input the segmentation results and the text representation obtained in Step 1 into the dependency analysis model to obtain the fused classification vector;
[0019] Step 3: Input the classification vector obtained in Step 2 into the event trigger word classifier, and use the 0 / 1 labeling format to predict the first and last indices of the candidate trigger words for each event type. Calculate the classification probability vector p of the current character being the start and end of the trigger word. ts / te ;
[0020] Step 4: Input the classification vector obtained in Step 2 into the event argument classifier, predict the start and end indices of candidate arguments for each role type using 0 / 1 labeling format, and calculate the classification probability vector p of the current word being the start and end word of that argument. as / ae ;
[0021] Step 5: Use the vector p obtained in step 3. ts / te and the vector p obtained in step 4 as / ae Trigger words and arguments are extracted separately, and the model is trained through parameter sharing and joint learning. The optimal model is obtained through iteration.
[0022] The specific process of step 1 is as follows:
[0023] The training and test sets are divided. Long documents in the document are divided into a set of sentences with a fixed length of 200 characters. Each sentence corresponds to a sample in the dataset. The initial text representation h is obtained by word embedding using the pre-trained language model BERT.
[0024] The specific process of step 3 is as follows:
[0025] Input the fused classification vector obtained in step 2 into the event trigger word classifier, and use an independent feedforward neural network to calculate the classification probability that the current character is the beginning and end of the trigger word for each event type:
[0026] p ts / te (i)=W 1ts / te(tanh(W 2ts / te ·g i +b 2ts / te ))+b 1ts / te
[0027] Where 'ts' indicates the start of the index triggered by the trigger word, and 'te' indicates the end of the index triggered by the trigger word. 1ts b 1ts W 1te b 1te W 2ts b 2ts W 2te b 2te All of these are learnable parameter matrices.
[0028] The specific process of step 4 is as follows:
[0029] Input the fused classification vector obtained in step 2 into the event argument classifier, and use a feedforward neural network to calculate the classification probability of the current word being the start and end word of the argument for each argument role:
[0030] p as / ae (i)=W 1as / ae (tanh(W 2as / ae ·g i +b 2as / ae ))+b 1as / ae
[0031] Where as indicates the start index of the argument, and ae indicates the end index of the argument. W 1as b 1as W 1ae b 1ae W 2as b 2as W 2ae b 2ae All of these are learnable parameter matrices.
[0032] The specific process of step 5 is as follows:
[0033] The vector p obtained in step 3 ts / te and the vector p obtained in step 4 as / ae Multiple binary classifiers are used for classification. The argmax function is used to obtain the predicted 0 / 1 labels, indicating whether the current word is the beginning or end of an entity that is a specific event trigger word or argument role. At the same time, the event trigger word and the arguments involved in the event are extracted.
[0034] y ts / te =argmax(p ts / te )
[0035] y as / ae =argmax(p as / ae ).
[0036] Compared with the prior art, the present invention has the following beneficial effects:
[0037] 1. This scheme first introduces dependency parsing to construct syntactic structures and enhance the deep interaction of information; secondly, it designs three types of edge representations to calculate graph convolution features in order to bridge the inconsistency of words; finally, by jointly learning the event trigger word classification task and the event argument classification task, it alleviates the cascading error propagation problem of traditional pipeline methods and improves the effect of extracting event trigger words and arguments from documents.
[0038] 2. The Chinese joint event extraction model based on dependency analysis incorporates syntactic structure information while encoding semantics, enhancing the information flow between characters. Furthermore, it designs different types of edge representations for constructing undirected graphs, taking into account the characteristics of Chinese word segmentation.
[0039] 3. This scheme models the direct relationships between words through dependency analysis and uses graph convolutional neural networks to combine this syntactic structure information with text semantic information, which is then used for joint event extraction tasks, thereby improving the extraction results of event trigger words and event arguments at the same time. Attached Figure Description
[0040] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0041] Figure 1 This is a flowchart of a Chinese joint event extraction method based on dependency analysis according to the present invention.
[0042] Figure 2 This is a schematic diagram of the master-slave dependency relationship used in dependency analysis in this invention.
[0043] Figure 3 This is an abstract schematic diagram of dependency relationships based on three types of edges used in this invention.
[0044] Figure 4 This is a schematic diagram of the undirected graph used in the graph convolutional neural network of this invention.
[0045] Figure 5 This is a schematic diagram of the overall structure of the Chinese joint event extraction task of this invention. Detailed Implementation
[0046] It should be understood that the specific embodiments described herein are for illustrative purposes only and are not intended to limit the scope of the invention.
[0047] It will be understood by those skilled in the art that certain well-known structures and their descriptions may be omitted in the accompanying drawings.
[0048] To better illustrate this embodiment, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings.
[0049] The purpose of this invention is to overcome the shortcomings of existing technologies and provide a Chinese joint event extraction method based on dependency analysis, so as to better utilize syntactic structure information while mitigating the propagation of cascading errors, combine structure and semantics, and ultimately improve the classification accuracy of the algorithm.
[0050] To address the aforementioned technical problems, this invention constructs syntactic-structure-based association information between words based on dependency analysis, models this dependency information using graph convolutional neural networks, and fully integrates syntactic and semantic information to obtain a good vector representation for classification. A novel method for extracting joint events in Chinese is proposed and implemented.
[0051] The innovations of this invention mainly include the following aspects:
[0052] 1) It is proposed to use dependency parsing to incorporate syntactic structure information into the semantics of text.
[0053] 2) Three types of edge-based graph convolutional networks are proposed to aggregate neighbor node features from Chinese text.
[0054] 3) A joint learning model based on dependency analysis is proposed to jointly learn two sub-tasks: trigger word extraction and argument extraction.
[0055] A method for constructing a dependency parsing model based on text representation is proposed. First, the text is segmented into words, and dependency parsing is used to obtain the master-slave relationship between words, establishing the dependency relationship between words. Second, three types of edges are constructed, and three two-dimensional adjacency matrices are generated for each type of edge to construct a graph representation, which is represented by an undirected graph. Then, the initial text representation is input into a graph convolutional neural network, and neighbor node information is aggregated using the undirected graph. The output of the convolutional neural network is fused with the initial text representation. Finally, the classification vector obtained after fusion is used as the output of the model.
[0056] The specific process of representing dependency relations using undirected graphs is as follows:
[0057] The dependency relationships between words are simplified to the dependency relationships between the first characters of words, and three types of edge representations are constructed, namely e along e loop e rev;e represents an edge, along is a type, e along Representing edges of type "along"; constructing a two-dimensional adjacency matrix for the three types of edges according to pre-established dependency relationships, and abstracting the dependency relationships into an undirected graph representation; the adjacency matrix uses single characters as nodes, and if there is a relationship between two nodes, the value of the corresponding position in the adjacency matrix is set to 1, otherwise it is set to 0.
[0058] The specific process of fusing to obtain the classification vector is as follows:
[0059] The obtained word embedding text representation is used as the initial input to the graph convolutional neural network. The neighbor node information is aggregated by combining the undirected graph to calculate the graph convolution vector. The graph convolution vectors of the three edge types are concatenated and the node vector of the (k+1)th layer is updated using the activation function. The output of the last layer of the graph convolutional network is combined with the word embedding text representation to obtain the final classification vector, where k represents the number of graph convolution layers.
[0060] Calculate the graph convolution vector using the following formula.
[0061]
[0062] Where v represents the currently updated node, K(v,u) indicates the type of the current edge, corresponding to e along e loop e rev There are three types: N(v,K(v,u)) is the set of neighboring nodes of the current node on the current edge, which is the part of the two-dimensional adjacency matrix with a value of 1. and These are the weight matrix and offset parameters for node and edge type constraints.
[0063] In the dependency parsing described above, the official toolkit Stanford CoreNLP is used to perform dependency parsing on Chinese text. First, the Chinese text is segmented into words, and then dependency parsing is used to obtain the Chinese syntactic dependency relationships between the governing words and the subordinate words at the word level.
[0064] A method for extracting Chinese joint events based on dependency parsing includes the following steps:
[0065] Step 1: Preprocess the input text, which includes the event type and a description of the event. Use a pre-trained language model to encode the text in the dataset to obtain the initial text representation of the model.
[0066] Step 2: Segment the original input text into words, and input the segmentation results and the text representation obtained in Step 1 into the dependency analysis model to obtain the fused classification vector;
[0067] Step 3: Input the classification vector obtained in Step 2 into the event trigger word classifier, and use the 0 / 1 labeling format to predict the first and last indices of the candidate trigger words for each event type. Calculate the classification probability vector p of the current character being the start and end of the trigger word. ts / te ;
[0068] Step 4: Input the classification vector obtained in Step 2 into the event argument classifier, predict the start and end indices of candidate arguments for each role type using 0 / 1 labeling format, and calculate the classification probability vector p of the current word being the start and end word of that argument. as / ae ;
[0069] Step 5: Use the vector p obtained in step 3. ts / te and the vector p obtained in step 4 as / ae Trigger words and arguments are extracted separately, and the model is trained through parameter sharing and joint learning. The optimal model is obtained through iteration.
[0070] Specific embodiments, such as Figures 1 to 5 As shown,
[0071] A joint event extraction method based on dependency analysis, comprising the following steps:
[0072] S1: Preprocessing includes the event type and the input text describing the event. The text in the dataset is encoded using a pre-trained language model to obtain the initial text representation of the model.
[0073] S2: Segment the original input text into words and use dependency parsing to obtain the subordinate relationship between words. In a sentence, if one word modifies another word, the modifier is called the subordinate word, the modified word is called the dominant word, and the grammatical relationship between the two is called the dependency relationship.
[0074] S3: Represent the dependencies obtained in step S2 using an undirected graph. Three types of edge representations were designed, namely e along e loop e rev Three two-dimensional adjacency matrices are generated for each of the three types of edges to construct an undirected graph representation. Each adjacency matrix uses a single character as a node. If there is a relationship between two nodes, the value of the corresponding position in the adjacency matrix is set to 1, otherwise it is set to 0.
[0075] S4: Input the initial text representation obtained in step S1 into the graph convolutional neural network, aggregate the neighbor node information using the undirected graph constructed in step S3, and calculate the graph convolution vector; concatenate the graph convolution vectors of the three edge types, and use the activation function to update the node vector of the (k+1)th layer; combine the output of the last layer of the graph convolutional network with the word embedding text representation to obtain the final classification vector, where k represents the number of graph convolution layers;
[0076] S5: Input the classification vector obtained in step 4 into the event trigger word classifier, predict the first and last indices of the candidate trigger words for each event type using a 0 / 1 labeling format, and calculate the classification probability vector p that the current character is the start and end of the trigger word. ts / te ;
[0077] S6: Input the classification vector obtained in step 4 into the event argument classifier, predict the start and end indices of candidate arguments for each role type using 0 / 1 labeling format, and calculate the classification probability vector p of the current word being the start and end word of the argument. as / ae ;
[0078] S7: Use the vector p obtained in step 5 ts / te and the vector p obtained in step 6 as / ae Trigger words and arguments are extracted separately, and the model is trained through parameter sharing and joint learning. The optimal model is obtained through iteration.
[0079] The specific process of step S1 is as follows:
[0080] The dataset used to train the model is divided into training and testing sets. Documents in the dataset are separated into sentence sets with a maximum length of 200 characters. Trigger words and event arguments are extracted from each sentence. Each sentence corresponds to one sample in the dataset. The pre-trained language model BERT is used for encoding, mapping each character to a fixed dimension d. h The vectors are used to obtain a general semantic embedded text representation h:
[0081] {h1,h2,...,h N} = BERT{t1,t2,...,t N}
[0082] Where h i For each word embedding representation, N indicates the length of the text sequence; the size of the text representation h is N*d. h .
[0083] The specific process of step S2 is as follows:
[0084] Stanford CoreNLP, an official tool, was used for word segmentation and dependency parsing. For Chinese text, Stanford CoreNLP first performed word segmentation, and then obtained the relationships between words based on Chinese grammar, that is, the relationships between governing words and subordinate words, such as direct objects (dobj), compound noun modifiers (nmod), and clause complements (ccomp). A diagram illustrating the direct results of dependency parsing is shown below. Figure 2 As shown, the Chinese word segmentation results and dependency syntax tree structure are obtained.
[0085] For example, the two words "Shougang" and "invested" are connected by an edge of the nsubj (noun subject) type, indicating that the noun subject of the action "invested" is "Shougang"; the two words "1993" and "invested" are connected by an edge of the nmod (compound noun modifier) type, indicating that "1993" modifies the action "invested".
[0086] The specific process of step S3 is as follows:
[0087] Step S300: Use an undirected graph to represent the text dependency relationship.
[0088] Step S301: Since the word embedding text representation obtained in step S1 is in units of characters, while the syntactic dependency relationship obtained in step S2 is in units of words, the result of dependency analysis cannot be directly used; to bridge the two-stage difference, the dependency relationship needs to be converted into an undirected graph representation in units of characters; therefore, the direct association between words is converted into the direct association between the first characters of words, and at the same time, to avoid losing the information of the word segmentation result, a self-loop edge (loop) is introduced to represent that a character belongs to the same word in the word segmentation result.
[0089] Step 302: To distinguish the information flow direction of nodes in the original dependency analysis tree, an edge of the along type is designed to represent the edge flowing from the governing word to the subordinate word, and an edge of the rev type is designed to represent the edge flowing from the subordinate word to the governing word. The dependency analysis relationship graph finally simplified through the above steps is as Figure 3 shown. For example, there are an edge of the along type and an edge of the rev type between the two characters "Shou" and "Chi", and there is an edge of the loop type between the two characters "Shou" and "Gang".
[0090] Step 303: Combine Figure 4 For the above three types of edges, three adjacency matrices are constructed to represent the undirected graph of the dependency relationship. The sizes of the three adjacency matrices are all N*N, where N is the text length and also represents the number of nodes; each character in the text is a node, and if two nodes are associated, the corresponding value in the adjacency matrix is set to 1, otherwise it is 0. The specific process of step S4 is as follows:
[0091] Step S400: Aggregate the information of neighbor nodes using a graph convolutional neural network based on the adjacency matrix obtained in step S3.
[0092] Step S401: Use the word embedding obtained in step S1 as the initial input of the graph convolutional neural network.
[0093]
[0094] where h i is the word embedding representation of the i-th character in the text, vi The node representation of the word is indicated by 0, which indicates the number of layers in the convolutional neural network, meaning that the current vector only contains its own node information and has not yet started to aggregate information.
[0095] Step S402: Use the undirected graph obtained in step S3 to perform information aggregation, V = (v1, v2, ..., v N () is the set of nodes. For a graph convolutional neural network of layer k, we compute the graph convolution vector for any v∈V.
[0096]
[0097] Where v represents the currently updated node, K(v,u) indicates the type of the current edge, corresponding to along, loop, and rev, and N(v,K(v,u)) is the set of neighboring nodes of the current node on the current edge, that is, the part of the two-dimensional adjacency matrix with a value of 1. and These are the weight matrices and offset parameters for node and edge type constraints. Through this step, nodes continuously aggregate information from neighboring nodes in the dependency parsing results. Furthermore, as the number of layers in the graph convolutional neural network increases, the current node can also aggregate information from neighboring nodes several hops away.
[0098] Step S403: Step S402 yields the hidden vector representations of the three edge types. These three representations are concatenated and activated using the activation function f to obtain the final vector propagated forward from the (k+1)th layer. The graph node vectors have been updated.
[0099]
[0100] Step S404: Fuse the output of the last layer of the graph convolutional network with the word embedding h obtained in step S1 to obtain the vector g used for classifying trigger words and event roles:
[0101]
[0102] Where i indicates the current word index, h i It is the original semantic vector. It is the output vector of a graph convolutional neural network that integrates syntactic structure information through several hops of iteration. λ is a hyperparameter that controls the influence factor of dependency parsing.
[0103] The specific process of step S5 is as follows:
[0104] The vector g obtained in step S4 is input into two dual affine layers (i.e., the input event trigger word classifier) to obtain the probability matrix corresponding to the first and last indices of the event trigger words. A feedforward neural network is then used to calculate the classification probability p for the start and end words of each event type.ts / te :
[0105] p ts / te (i)=W 1ts / te (tanh(W 2ts / te ·g i +b 2ts / te ))+b 1ts / te
[0106] Among them, W 1ts b 1ts W 1te b 1te W 2ts b 2ts W 2te b 2te Both are learnable parameter matrices, p ts Indicates the start index of the trigger word, p te This indicates the probability that the current character becomes the end index of the trigger word; both are of size N*num. e *2, where N is the length of the text sequence, num e This represents the number of event types.
[0107] The specific process of step S6 is as follows:
[0108] Input the vector g obtained in step S4 into two other independent dual affine layers (i.e., the event argument classifiers) to obtain the probability matrix p corresponding to the first and last indices of the event arguments. as / ae The classification probability of each argument role is calculated using a feedforward neural network for the start and end words:
[0109] p as / ae (i)=W 1as / ae (tanh(W 2as / ae ·g i +b 2as / ae ))+b 1as / ae
[0110] Among them W 1as b 1as W 1ae b 1ae W 2as b 2as W 2ae b 2ae Both are learnable parameter matrices, p as p indicates the probability that the current word is the start index of a certain argument. ae This indicates the probability that the current word becomes the index of the end position of a certain argument; both are of size N*num. r *2, where num rThe number of argument roles.
[0111] The specific process of step S7 is as follows:
[0112] Step S700: Simultaneously extract event trigger words and event arguments.
[0113] Step S701: Convert the vector p obtained in step S5 into... ts / te The trigger word classifier is used for classification, and the argmax function is used to obtain the predicted 0 / 1 label, where 1 represents the start / end index of a certain trigger word, and 0 represents the other. The event type is also obtained.
[0114] y ts / te =argmax(p ts / te )
[0115] Step S702: Convert the vector p obtained in step S6 into... as / ae The argument classifier is used for classification. The argmax function is used to obtain the predicted 0 / 1 label. 1 means that the word is the start / end index of an argument of a certain event, and 0 means otherwise.
[0116] y as / ae =argmax(p as / ae ).
[0117] In summary, this scheme uses the pre-trained BERT language model to encode text sequences into word embeddings; it uses official tools for analysis to obtain the dependency relations implied by Chinese syntactic structure; it designs three different types of edge representations tailored to Chinese characteristics and uses a two-dimensional matrix to abstract the dependency relations into an undirected graph representation; based on the undirected graph, it uses a graph neural network to aggregate neighbor node information to obtain a classification representation that incorporates Chinese syntactic structure information; it uses an event classifier to extract event trigger words and event types; and it uses an argument classifier to obtain all relevant elements involved in the event. This invention enriches semantic feature representation by incorporating syntactic structure knowledge contained in Chinese text and effectively improves the sentence-level event extraction effect by using a joint learning method.
[0118] Thus, the Chinese joint event extraction method based on dependency analysis has been completed. Through the above scheme, Chinese syntactic information is fully explored and utilized to enhance text semantics. During the encoding process, the characteristics of Chinese sentences are fully considered, and text dependency relations are constructed into an undirected graph representation. Furthermore, a graph convolutional neural network is used to fully integrate the syntactic structural information contained in the event text, enhancing the relevance of the text context. Finally, joint learning is used to improve the accuracy and performance of event trigger words and element extraction.
[0119] Those skilled in the art should understand that variations can be implemented by combining existing technology with the above embodiments, which will not be elaborated here. Such variations do not affect the substantive content of the present invention, and will not be elaborated here.
[0120] The preferred embodiments of the present invention have been described above. It should be understood that the present invention is not limited to the specific embodiments described above. Devices and structures not described in detail herein should be understood as being implemented in a manner common to the art. Any person skilled in the art can make many possible variations and modifications to the technical solutions of the present invention using the methods and techniques disclosed above, or modify them into equivalent embodiments with equivalent changes, without departing from the scope of the present invention. This does not affect the essential content of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims. Any simple modifications, equivalent changes, and modifications made to the above embodiments based on the technical essence of the present invention without departing from the content of the present invention's technical solutions shall still fall within the scope of protection of the present invention.
Claims
1. A method for extracting joint events in Chinese based on dependency analysis, characterized in that: The joint learning model based on dependency parsing jointly learns two subtasks: trigger word extraction and argument extraction, including the following steps: Step 1: Preprocess the input text containing the event type and the description of the event. Use a pre-trained language model to encode the text in the dataset to obtain word embedding text representations in units of characters. Step 2: Segment the original input text into words, and embed the segmentation results and the words obtained in Step 1 into the text representation input dependency analysis model to obtain the fused classification vector. First, segment the text into words and use dependency analysis to obtain the master-slave relationship between words, establishing the dependency relationship between words. Second, simplify the dependency relationship between words to the dependency relationship between the first characters of words, constructing three types of edges, namely... , , ,in, This indicates the boundary from the governing word to the subordinate word. This represents a self-looping edge, where the characters belong to the same word in the word segmentation result. This involves representing the edges flowing from dependent words to dominant words; and generating three two-dimensional adjacency matrices for each of the three edge types to construct a graph representation, using an undirected graph to represent the dependency relationship; each two-dimensional adjacency matrix uses single characters as nodes, and if there is a relationship between two nodes, the value at the corresponding position in the two-dimensional adjacency matrix is set to 1, otherwise it is set to 0; then, the word embedding text representation is input into a graph convolutional neural network, and the neighbor node information is aggregated using an undirected graph, and the output of the convolutional neural network is fused with the word embedding text representation; the specific fusion process is as follows: the obtained word embedding text representation is used as the initial input of the graph convolutional neural network, and the neighbor node information is aggregated using an undirected graph to calculate the graph convolution vector; the graph convolution vectors of the three edge types are concatenated, and the activation function is used to update the first edge. The node vectors of the layer are combined with the output of the last layer of the graph convolutional network and the word embedding text representation to obtain the final classification vector. This indicates the number of layers in the graph convolution; finally, the fused classification vector is used as the output of the dependency parsing model. Step 3: Input the classification vector obtained in Step 2 into the event trigger word classifier. Use 0 / 1 labeling format to predict the first and last indices of the candidate trigger words for each event type, and calculate the classification probability vectors of whether the current character is the start or end of the trigger word. ; Step 4: Input the classification vector obtained in Step 2 into the event argument classifier, predict the start and end indices of candidate arguments for each role type using 0 / 1 labeling format, and calculate the classification probability vectors of the current word being the start and end word of an argument. ; Step 5: Use the vector obtained in Step 3 and the vector obtained in step 4 Trigger words and arguments are extracted separately, and the model is trained through parameter sharing and joint learning. The optimal model is obtained through iteration.
2. The Chinese joint event extraction method based on dependency analysis according to claim 1, characterized in that: Calculate the graph convolution vector using the following formula. : in, Indicates the currently updated node. Indicates the type of the current edge, corresponding to , , Three types, It is the set of neighboring nodes of the current node on the current edge, that is, the part of the two-dimensional adjacency matrix with a value of 1. and These are the weight matrix and offset parameters for node and edge type constraints.
3. The Chinese joint event extraction method based on dependency analysis according to claim 1, characterized in that: In the dependency analysis, the official toolkit Stanford CoreNLP was used to perform dependency analysis on Chinese text. First, the Chinese text was segmented into words, and then dependency analysis was performed to obtain the Chinese syntactic dependency relationships between the governing words and the subordinate words at the word level.
4. The Chinese joint event extraction method based on dependency analysis according to claim 1, characterized in that: The specific process of step 1 is as follows: The dataset is divided into training and testing sets. Long documents are split into sentences of fixed length (200 characters each), with each sentence corresponding to a sample in the dataset. Word embeddings are then used to obtain word embedding text representations using the pre-trained language model BERT. .
5. The Chinese joint event extraction method based on dependency analysis according to claim 1, characterized in that: The specific process of step 3 is as follows: Input the fused classification vector obtained in step 2 into the event trigger word classifier, and use an independent feedforward neural network to calculate the classification probability that the current character is the beginning and end of the trigger word for each event type: in Indicates the trigger word to start indexing. Indicates the end of the trigger word index; , , , , , , , All are learnable parameter matrices. Indicates the first The fusion classification vector of each character.
6. The Chinese joint event extraction method based on dependency analysis according to claim 1, characterized in that: The specific process of step 4 is as follows: Input the fused classification vector obtained in step 2 into the event argument classifier, and use a feedforward neural network to calculate the classification probability of the current word being the start and end word of an argument for each argument role: in Indicator argument start index, Indicator argument end index, , , , , , , , All are learnable parameter matrices. Indicates the first The fusion classification vector of each character.
7. The Chinese joint event extraction method based on dependency analysis according to claim 1, characterized in that: The specific process of step 5 is as follows: The vector obtained in step 3 and the vector obtained in step 4 Classification is performed using multiple binary classifiers. The function obtains the predicted 0 / 1 labels, indicating whether the current word is the beginning or end of an entity that triggers the event or is an argument. It also extracts the event trigger word and the arguments involved in the event. 。
Citation Information
Patent Citations
Text event extraction method and device based on grammar dependency information
CN111581954A
Vietnamese news event detection method based on Chinese information and Vietnamese statement method guidance
CN112668319A