Text information processing method, device, equipment and storage medium

By dividing and decomposing the event detection and argument recognition process, a mixed sequence of entity tags is constructed and the BILSTM-SOFTMAX and BILSTM-CRF models are used to solve the problem of sparse annotation of closed domain text data, and the accuracy and efficiency of event detection and argument recognition are improved.

CN114969360BActive Publication Date: 2025-08-2610TH RES INST OF CETC
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210512228.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-05-12
Publication Date
2025-08-26
Estimated Expiration
2042-05-12

AI Technical Summary

Technical Problem

The text data in the closed domain has many professional vocabulary and professional entities, and the labeling data is sparse, resulting in low accuracy of event detection and extraction.

Method used

Through the division and task decomposition of entity recognition, event detection and event argument recognition processes, a mixed sequence of entity tags is constructed, and feature capture and probability decisions are used to use BILSTM-SOFTMAX and BILSTM-CRF models to perform feature capture and probability decision-making, strengthen non-entity semantic coordination features, and improve the accuracy of event detection and argument recognition.

Benefits of technology

In professional fields, the effects of event detection and argument recognition have been improved, and the ability to quickly iterate the generation of event extraction models for specific closed-source fields is realized.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114969360B_ABST
    Figure CN114969360B_ABST
Patent Text Reader

Abstract

The present invention discloses a text information processing method, device, equipment and storage medium. The method comprises obtaining an entity detection sequence and an entity label sequence of target text information, constructing an entity label mixed sequence; extracting feature information of the entity label mixed sequence, and determining the event type of the target text information based on the feature information; splicing the feature of the event type with the feature of the entity label mixed sequence to obtain a feature matrix; and determining the event argument role of the target text information based on the feature matrix. The present invention separates the process of event detection and event argument recognition by dividing and decomposing the processes of entity recognition, event detection and event argument recognition, analyzes the data of each process, and blurs the entity information features and strengthens the non-entity semantic collocation features in the event feature construction, so that the model has better effect in professional fields in event detection and argument recognition.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of natural language processing technology, and in particular to a text information processing method, apparatus, device and storage medium. Background Art

[0002] Event detection and event extraction technologies belong to event analysis technologies in the closed-source field. Event detection technology determines whether text information belongs to a certain event category; event extraction technology extracts the roles in the event, generally including the participants, time, location, trigger words, etc.

[0003] Current event detection technologies are mainly divided into three categories, including: end-to-end event detection technology, event detection technology based on feature engineering, and event detection technology based on specification paradigms.

[0004] End-to-end event detection technology generally uses deep learning models, mainly deep learning models built on RNN, CNN, and Transformer. The features of text information are captured and learned through neural networks. SOFTMAX is generally used directly for probability normalization at the decision layer to achieve end-to-end event detection technology.

[0005] Event detection technology based on feature engineering primarily uses classification techniques to discriminate event types based on text feature learning. Unprocessed text features are one-hot encoded features. There are two main approaches for extracting these features. One is a matrix-based feature extraction method, including principal component analysis and independent component analysis, which can reduce matrix dimensionality, enhance data relevance, and address data sparsity. The other is an autoencoder-based neural network model. This performs contextual prediction based on the sequential contextual relationships between characters and words in a text. The neural network is trained and then processed using an intermediate feature output layer. This approach allows for learning and replenishing text contextual information, resulting in features with enhanced semantic characteristics. Based on feature processing, a classifier is generally used to learn the classification task, identifying the categories to which different samples belong, and implementing event detection technology. Commonly used classifiers include support vector machines (SVMs), decision trees, perceptrons, and logistic regression.

[0006] Event detection technology based on standard paradigms is generally implemented based on crawler technology. Its data generally has a fixed paradigm and a relatively fixed description form and description location. The data information is located through the crawler framework. Based on the data information at the specific location, the data is judged through mechanical word segmentation and regular expressions to implement event detection technology.

[0007] Current event extraction technologies include: end-to-end event extraction technology, event extraction technology based on dependency syntax analysis, semi-supervised event extraction technology, etc.

[0008] End-to-end event extraction technology directly extracts event-related elements from text input, converting the event extraction task into a sequence labeling task. Current mainstream sequence labeling models include CRF, BILSTM-CRF, BERT-CRF, etc., which directly recognize and extract event-related elements from text information based on semantics.

[0009] The event extraction technology based on dependency syntactic analysis is to identify the relationship between entities through entity recognition and shallow semantic analysis. On this basis, the corresponding event type is identified from the entity relationship network through event pattern matching. This type of method is generally divided into two steps. The first step is to perform entity recognition to identify the entity information in the text. It is generally implemented using a sequence labeling model. Then, based on the information from entity recognition, the shallow semantic relationship between entities is identified to obtain the dependency syntactic analysis results of the text, including subject-predicate relationship, parallel relationship, preposition-object relationship, etc. Here, conditional random fields or feedforward neural networks are generally used for recognition. Finally, pattern matching is performed on this basis to obtain event argument information.

[0010] Semi-supervised event extraction technology uses a small set of annotated data to perform similar queries within a large corpus, obtaining similar results. After manual review, the corpus is continuously iterated to achieve model generalization. This type of algorithm extensively uses twin networks to conduct comparative searches on similar data. Based on these results, it continuously identifies arguments for similar events to obtain event extraction results.

[0011] Currently, in closed-source professional fields, event extraction, which allows for trend analysis, statistical analysis, and decision support for events in specific fields, has become a key technology for empowering intelligence in specific fields. However, event extraction in specific fields differs from event extraction in open-source fields. First, the annotated data for event information in specific fields is very sparse, and it is necessary to consider the generalization of event detection in the case of sparse data. Second, event arguments and entity types in specific fields are interdependent, and the event arguments corresponding to different event types vary greatly. Third, event extraction analysis of specific field information is based on the analysis results of entity information and other information. The results of each type of analysis need to be managed, corrected, and traced to facilitate multi-dimensional data analysis.

[0012] Therefore, how to provide a method that can quickly iterate and generate event extraction models for specific closed-source fields, and a text information processing method that can define events based on event types, argument types, and entity types in specific fields, is a technical problem that needs to be solved urgently.

[0013] The above content is only used to assist in understanding the technical solution of the present invention and does not constitute an admission that the above content is prior art. Summary of the Invention

[0014] The main purpose of the present invention is to provide a text information processing method, device, equipment and storage medium, aiming to solve the technical problem that the current closed domain text data has a large number of professional vocabulary and professional entities, sparse annotation data, different event information types, and thus low accuracy in detecting and extracting text data.

[0015] To achieve the above object, the present invention provides a text information processing method, which comprises the following steps:

[0016] Obtaining an entity detection sequence and an entity label sequence of target text information, and constructing an entity label mixed sequence based on the entity detection sequence and the entity label sequence;

[0017] Extracting feature information of the entity tag mixed sequence, and determining the event type of the target text information based on the feature information;

[0018] Concatenate the event type features with the entity label mixed sequence features to obtain a feature matrix;

[0019] Based on the feature matrix, the event argument role of the target text information is determined.

[0020] Optionally, before the step of obtaining the entity detection sequence and entity label sequence of the target text information, the method further includes:

[0021] When receiving the target text information, performing standardization processing on the target text information;

[0022] The standardization process includes sentence segmentation process.

[0023] Optionally, before the target text information is segmented, half-width normalization and uppercase and lowercase normalization may be performed on the target text information.

[0024] Optionally, the step of obtaining an entity detection sequence and an entity label sequence of target text information specifically includes:

[0025] Performing entity recognition on the target text information according to the sentence processing result of the target text information to obtain entity information and non-entity information of the target text information;

[0026] constructing an entity detection sequence based on the entity information and non-entity information;

[0027] Obtain a label for each element in the entity detection sequence, and construct an entity label sequence based on all the labels.

[0028] Optionally, the step of constructing an entity label mixed sequence according to the entity detection sequence and the entity label sequence specifically includes:

[0029] If an element in the entity detection sequence has a corresponding label in the entity label sequence, the label corresponding to the element is used as the label element in the entity label mixed sequence;

[0030] If an element in the entity detection sequence has no corresponding label in the entity label sequence, the character corresponding to the element is used as the character element in the entity label mixed sequence;

[0031] An entity tag mixed sequence is constructed according to the tag elements and the character elements.

[0032] Optionally, the step of extracting feature information of the mixed sequence of entity tags and determining the event type of the target text information based on the feature information specifically includes:

[0033] Using a BILSTM-SOFTMAX model to identify the event type of each entity information in the entity label mixed sequence; wherein the BILSTM-SOFTMAX model includes a feature capture layer and a probability decision layer;

[0034] The feature capture layer captures the context sequence of the entity tag sequence, and maps the feature information to the feature matrix of event type distribution based on the linear fully connected layer to obtain the event tag category probability distribution matrix corresponding to the entity tag mixed feature;

[0035] The probability decision layer normalizes the event label category probability distribution matrix to obtain the event type of each entity information in the entity label mixed sequence.

[0036] Optionally, the step of concatenating the event type feature and the entity label mixed sequence feature to obtain a feature matrix specifically includes:

[0037] Based on the entity tag mixed sequence, one-hot encoding is used to encode the features of the entity tag mixed sequence, and the features of the feature encoding are extracted to obtain a feature vector matrix;

[0038] One-hot encoding is performed on the event type to obtain a feature code of the event type, and the feature vector matrix and the feature code of the event type are concatenated to obtain a feature matrix.

[0039] Optionally, the step of determining the event argument role of the target text information based on the feature matrix specifically includes:

[0040] Using a BILSTM-CRF model to identify the event argument role corresponding to each feature in the feature matrix; wherein the BILSTM-CRF model includes a sequence feature capture layer and a sequence label prediction layer;

[0041] The sequence feature capture layer captures the context features of the feature matrix and maps the features to corresponding event argument roles based on a linear fully connected layer to obtain a probability distribution matrix of event argument role types corresponding to the feature matrix;

[0042] The sequence label prediction layer generates a feature transfer matrix of the observation sequence and the observed sequence according to the event argument role type probability distribution matrix, and obtains the event argument role of each feature in the feature matrix.

[0043] In addition, in order to achieve the above-mentioned object, the present invention further provides a text information processing device, the text information processing device comprising:

[0044] A construction module is used to obtain an entity detection sequence and an entity label sequence of target text information, and construct an entity label mixed sequence based on the entity detection sequence and the entity label sequence;

[0045] A first determination module is configured to extract feature information of the entity tag mixed sequence and determine the event type of the target text information based on the feature information;

[0046] The splicing module is used to splice the features of the event type and the entity label mixed sequence to obtain the feature matrix;

[0047] The second determination module is configured to determine the event argument role of the target text information based on the feature matrix.

[0048] In addition, in order to achieve the above-mentioned purpose, the present invention also provides a text information processing device, which includes: a memory, a processor, and a text information processing method program stored in the memory and executable on the processor, wherein the text information processing method program implements the steps of the above-mentioned text information processing method when executed by the processor.

[0049] In addition, to achieve the above-mentioned purpose, the present invention further provides a storage medium, on which a text information processing method program is stored. When the text information processing method program is executed by a processor, the steps of the above-mentioned text information processing method are implemented.

[0050] The embodiment of the present invention proposes a text information processing method, device, equipment and storage medium, which includes obtaining an entity detection sequence and an entity label sequence of target text information, constructing an entity label mixed sequence based on the entity detection sequence and the entity label sequence; extracting feature information of the entity label mixed sequence, and determining the event type of the target text information based on the feature information; splicing the features of the event type with the features of the entity label mixed sequence to obtain a feature matrix; and determining the event argument role of the target text information based on the feature matrix. The present invention separates the process of event detection and event argument recognition by dividing and decomposing the processes of entity recognition, event detection and event argument recognition, analyzes the data conditions of each process, and blurs the entity information features and strengthens the non-entity semantic collocation features in the construction of event features, so that the model has better effects in professional fields in event detection and argument recognition. BRIEF DESCRIPTION OF THE DRAWINGS

[0051] Figure 1 This is a structural diagram of a text information processing device according to an embodiment of the present invention;

[0052] Figure 2 Schematic diagram of a text information processing method according to an embodiment of the present invention;

[0053] Figure 3 Schematic diagram of the principle of the text information processing method in an embodiment of the present invention;

[0054] Figure 4 Schematic diagram of the phase of a frequency hopping system without phase compensation in an embodiment of the present invention;

[0055] Figure 5 Schematic diagram of the phase of a frequency hopping system after phase compensation in an embodiment of the present invention;

[0056] Figure 6 This is a structural block diagram of a text information processing device in an embodiment of the present invention.

[0057] The purpose, features and advantages of the present invention will be further described with reference to the accompanying drawings and in conjunction with the embodiments. DETAILED DESCRIPTION

[0058] It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.

[0059] Currently, in related technical fields, closed-domain text data often contains a high concentration of specialized vocabulary and entities, sparsely labeled data, and diverse event information types, leading to low accuracy in detecting and extracting text data. Therefore, providing a method for rapidly iterating event extraction models for specific closed-source domains, and a text information processing method that can define events based on the event type, argument type, and entity type of a specific domain, is a pressing technical issue.

[0060] To address this issue, various embodiments of the text information processing method of the present invention are proposed. The text information processing method provided by the present invention separates the process of event detection and event argument recognition by dividing and decomposing the entity recognition, event detection, and event argument recognition processes. The data from each process is analyzed, and by blurring entity information features and strengthening non-entity semantic collocation features in event feature construction, the model achieves better results in event detection and argument recognition in specialized fields.

[0061] Reference Figure 1 , Figure 1 This is a structural diagram of a text information processing device involved in an embodiment of the present invention.

[0062] The device can be a user equipment (UE) such as a mobile phone, smart phone, laptop computer, digital broadcast receiver, personal digital assistant (PDA), tablet computer (PAD), handheld device, vehicle-mounted device, wearable device, computing device or other processing device connected to a wireless modem, mobile station (MS), etc. The device may be called a user terminal, portable terminal, desktop terminal, etc.

[0063] Typically, the device includes: at least one processor 301, a memory 302, and a text information processing method program stored in the memory and executable on the processor, wherein the text information processing method program is configured to implement the steps of the text information processing method described above.

[0064] The processor 301 may include one or more processing cores, such as a quad-core processor or an octa-core processor. The processor 301 may be implemented in at least one of the following hardware forms: a DSP (Digital Signal Processing), an FPGA (Field-Programmable Gate Array), or a PLA (Programmable Logic Array). The processor 301 may also include a main processor and a coprocessor. The main processor is a processor for processing data in the awake state, also known as a CPU (Central Processing Unit); the coprocessor is a low-power processor for processing data in the standby state. In some embodiments, the processor 301 may be integrated with a GPU (Graphics Processing Unit), which is responsible for rendering and drawing the content to be displayed on the display screen. The processor 301 may also include an AI (Artificial Intelligence) processor, which is used to process operations related to the text information processing method, so that the text information processing method model can be trained and learned autonomously to improve efficiency and accuracy.

[0065] The memory 302 may include one or more computer-readable storage media, which may be non-transitory. The memory 302 may also include high-speed random access memory and non-volatile memory, such as one or more disk storage devices and flash memory storage devices. In some embodiments, the non-transitory computer-readable storage medium in the memory 302 is used to store at least one instruction, which is executed by the processor 301 to implement the text information processing method provided in the method embodiment of the present application.

[0066] In some embodiments, the terminal may optionally include a communication interface 303 and at least one peripheral device. The processor 301, memory 302, and communication interface 303 may be connected via a bus or signal lines. Each peripheral device may be connected to the communication interface 303 via a bus, signal lines, or circuit boards. Specifically, the peripheral device may include at least one of a radio frequency circuit 304, a display screen 305, and a power supply 306.

[0067] The communication interface 303 can be used to connect at least one peripheral device related to I / O (Input / Output) to the processor 301 and the memory 302. The communication interface 303 is used to receive the movement trajectories and other data of multiple mobile terminals uploaded by users through the peripheral device. In some embodiments, the processor 301, the memory 302, and the communication interface 303 are integrated on the same chip or circuit board; in some other embodiments, any one or two of the processor 301, the memory 302, and the communication interface 303 can be implemented on a separate chip or circuit board, which is not limited in this embodiment.

[0068] The RF circuit 304 is used to receive and transmit RF (Radio Frequency) signals, also known as electromagnetic signals. The RF circuit 304 communicates with communication networks and other communication devices via electromagnetic signals, thereby acquiring the movement trajectories and other data of multiple mobile terminals. The RF circuit 304 converts electrical signals into electromagnetic signals for transmission, or converts received electromagnetic signals into electrical signals. Optionally, the RF circuit 304 includes: an antenna system, an RF transceiver, one or more amplifiers, a tuner, an oscillator, a digital signal processor, a codec chipset, a user identity module card, and the like. The RF circuit 304 can communicate with other terminals via at least one wireless communication protocol. Such wireless communication protocols include, but are not limited to, metropolitan area networks, various generations of mobile communication networks (2G, 3G, 4G, and 5G), wireless local area networks, and / or WiFi (Wireless Fidelity) networks. In some embodiments, the RF circuit 304 may also include circuits related to NFC (Near Field Communication), which is not limited in this application.

[0069] Display screen 305 is used to display a UI (User Interface). This UI may include graphics, text, icons, videos, or any combination thereof. When display screen 305 is a touch screen display, it is also capable of collecting touch signals on or above the surface of display screen 305. This touch signal can be input as a control signal to processor 301 for processing. In this case, display screen 305 can also be used to provide virtual buttons and / or a virtual keyboard, also known as soft buttons and / or a soft keyboard. In some embodiments, display screen 305 can be a single display screen, the front panel of the electronic device; in other embodiments, display screen 305 can be at least two, each disposed on different surfaces of the electronic device or in a foldable design; in still other embodiments, display screen 305 can be a flexible display screen, disposed on a curved or foldable surface of the electronic device. Display screen 305 can also be configured as a non-rectangular irregular shape, i.e., a special-shaped screen. Display screen 305 can be made of materials such as LCD (Liquid Crystal Display) and OLED (Organic Light-Emitting Diode).

[0070] Power supply 306 is used to power various components in the electronic device. Power supply 306 can be AC ​​power, DC power, a disposable battery, or a rechargeable battery. When power supply 306 includes a rechargeable battery, the rechargeable battery can support wired charging or wireless charging. The rechargeable battery can also be used to support fast charging technology.

[0071] Those skilled in the art will understand that Figure 1 The structure shown in the figure does not constitute a limitation on the text information processing device, and may include more or less components than shown in the figure, or combine certain components, or arrange the components differently.

[0072] The embodiment of the present invention provides a text information processing method, referring to Figure 2 , Figure 2 Schematic diagram of a flow chart of an embodiment of a text information processing method of the present invention.

[0073] In this embodiment, the text information processing method includes the following steps:

[0074] Step S100: Acquire an entity detection sequence and an entity label sequence of target text information, and construct an entity label mixed sequence according to the entity detection sequence and the entity label sequence.

[0075] Specifically, before obtaining the entity detection sequence and the entity label sequence of the target text information, it is also necessary to perform standardization processing on the target text information when the target text information is received.

[0076] In practical applications, the standardization process includes half-width standardization, uppercase and lowercase standardization, and bureau standardization.

[0077] In this embodiment, an entity detection sequence and an entity label sequence of the target text information are obtained. According to the sentence processing result of the target text information, entity recognition is performed on the target text information to obtain entity information and non-entity information of the target text information. Then, based on the entity information and non-entity information, an entity detection sequence is constructed. Finally, a label for each element in the entity detection sequence is obtained, and an entity label sequence is constructed based on all the labels.

[0078] After that, an entity label mixed sequence can be further constructed based on the constructed entity detection sequence and entity label sequence.

[0079] Specifically, if the element in the entity detection sequence has a corresponding label in the entity label sequence, the label corresponding to the element is used as the label element in the entity label mixed sequence; if the element in the entity detection sequence does not have a corresponding label in the entity label sequence, the character corresponding to the element is used as the character element in the entity label mixed sequence; finally, an entity label mixed sequence is constructed based on the label element and the character element.

[0080] Step S200: extracting feature information of the entity tag mixed sequence, and determining the event type of the target text information based on the feature information.

[0081] Specifically, after constructing the entity tag mixed sequence, it is necessary to extract feature information of the entity tag mixed sequence, so as to determine the event type of the target text information based on the feature information.

[0082] In practical applications, the BILSTM-SOFTMAX model can be used to identify the event type of each entity information in the entity label mixed sequence; wherein, the BILSTM-SOFTMAX model includes a feature capture layer and a probability decision layer.

[0083] Furthermore, the feature capture layer captures the context sequence of the entity label sequence, and maps the feature information to the feature matrix of the event type distribution based on the linear fully connected layer to obtain the event label category probability distribution matrix corresponding to the entity label mixed feature; the probability decision layer normalizes the event label category probability distribution matrix to obtain the event type of each entity information in the entity label mixed sequence.

[0084] In this embodiment, by using a hybrid feature of entity sequences and label sequences as the input for event detection tasks, event detection features can be better generalized and the accuracy of event detection can be improved when the corpus is sparse. Furthermore, the BILSTM-SOFTMAX model is used to determine the event detection type in event detection tasks. As a time series neural network model, this model has a strong ability to capture the contextual features of sequences. It can more accurately capture the event detection category corresponding to its input features, thereby improving the accuracy of event detection tasks.

[0085] Step S300: Concatenate the event type features and the entity label mixed sequence features to obtain a feature matrix.

[0086] Specifically, after obtaining the entity label mixed sequence, the features of the event type can be spliced ​​with the features of the entity label mixed sequence to obtain a feature matrix, thereby providing data support for determining the event argument role of the target text information.

[0087] In practical applications, when splicing, one-hot encoding is used based on the entity label mixed sequence to encode the features of the entity label mixed sequence, and the features of the feature encoding are extracted to obtain a feature vector matrix. After that, one-hot encoding is performed on the event type to obtain the feature encoding of the event type, and the feature vector matrix and the feature encoding of the event type are spliced ​​to obtain a feature matrix.

[0088] In this embodiment, a hybrid feature of entity sequence and label sequence is used as input for event detection tasks in event argument recognition, which enables the relationship between entities and event arguments in professional closed-source fields to be better learned and expressed in the model. Secondly, the feature of event detection labels is also introduced in the input feature layer. This can effectively solve the changes and regulations of argument roles for the same entity in different event types in the closed-source field. At the same time, since event arguments in closed-source fields cannot be effectively normalized, it is necessary to characterize the type changes of their arguments through event features. By introducing event detection label type features, such problems can be better solved.

[0089] Step S400: determining the event argument role of the target text information based on the feature matrix.

[0090] Specifically, after obtaining the feature matrix, the event argument role of the target text information can be determined based on the feature matrix.

[0091] In practical applications, the BILSTM-CRF model can be used to identify the event argument role corresponding to each feature in the feature matrix; wherein the BILSTM-CRF model includes a sequence feature capture layer and a sequence label prediction layer.

[0092] Furthermore, the sequence feature capture layer captures the contextual features of the feature matrix, and maps the features to the corresponding event argument roles based on the linear fully connected layer to obtain the event argument role type probability distribution matrix corresponding to the feature matrix; the sequence label prediction layer generates a feature transfer matrix of the observation sequence and the observed sequence based on the event argument role type probability distribution matrix to obtain the event argument role of each feature in the feature matrix.

[0093] In this example, a BILSTM-CRF model is used in the event argument recognition task. By capturing text context information through the BILSM model, the model can better represent the characteristics of sequence information. A CRF model is used at the upper decision layer. The CRF model can reduce the results based on the characteristics of sequence information, avoiding the occurrence of many unlikely sequence characteristics in the prediction results and training features. Furthermore, the CRF model uses the transition probabilities of the observed and observed sequences to better predict the labels of the observed sequences, thus achieving better event argument recognition results.

[0094] This embodiment provides a text information processing method, which separates the process of event detection and event argument recognition by dividing and decomposing the entity recognition, event detection and event argument recognition processes, analyzes the data situation of each process, and blurs the entity information features and strengthens the non-entity semantic matching features in the construction of event features, so that the model has better effects in professional fields in event detection and argument recognition.

[0095] In order to explain the present application more clearly, a specific example of a text information processing method is provided.

[0096] See Figure 3 In this embodiment, the text data is first normalized, and the characters in the text data are first converted to half-width characters. Then, the text is segmented into sentences, and the text is segmented based on the sentence scale by recognizing punctuation marks.

[0097] After that, based on the sentence information of the text, entity recognition is performed to construct the entity detection sequence and entity label sequence of the text. Let the entity detection sequence be (word1, word2,…, word n ) n , the entity tag sequence is (tag1,tag2,…,tag n) n Among them, the entity detection sequence refers to the division of sentences based on the boundaries of entities. For recognized entities, the division is based on the beginning and end of the entity, and for information that is not recognized as an entity, it is divided into single words to form a continuous sequence to obtain the entity detection sequence; the entity label sequence refers to the label sequence obtained by predicting the label corresponding to each element in the detection sequence based on the entity detection sequence.

[0098] Based on the entity detection sequence and the entity label sequence, an entity label mixed sequence is constructed. Let the entity label mixed sequence be (wt1, wt2,…, wt n ) n For labels detected in the entity label sequence, the labels are used at the corresponding positions in the model input. For labels not detected in the entity label sequence, the characters corresponding to the entity detection sequence are used at the corresponding positions in the model input to complete the construction of the entity label mixed sequence.

[0099] Based on the construction of the mixed entity label sequence, the BILSTM-SOFTMAX model is used to capture and predict the features of the mixed entity label sequence in the text sentence, thereby detecting the event type of each sentence in the text. The event detection model consists of two parts: the feature capture layer and the probabilistic decision layer. The feature capture layer uses the BILSTM model to express the context of the entity label sequence information. A linear fully connected layer maps this feature information to the feature matrix of the event type distribution, resulting in a probability distribution matrix of event label categories corresponding to the mixed entity label features. The probabilistic decision layer normalizes the event label category probability distribution matrix using the SOFTMAX layer to obtain the event label category, completing the event detection task.

[0100] Based on the above tasks, the BILSTM-CRF model is used to capture and predict the features of mixed entity label sequences in text sentences, thereby identifying and extracting the role of event arguments in mixed text entity label sequences. The event argument recognition model is divided into three parts: the feature weighting layer, the sequence feature capture layer, and the sequence label prediction layer.

[0101] The feature weighting layer constructs a feature matrix for the mixed entity label sequence through linear weighting and concatenation of event type features. The sequence feature capture layer uses BILSTM to capture the contextual features of the feature matrix of the mixed entity label sequence. A linear fully connected layer then maps this feature information to the corresponding event argument role type probability distribution matrix. The sequence label prediction layer uses a CRF, taking the event argument role type probability distribution matrix as input and implementing the event argument recognition task based on the feature transfer matrix between the observed and observed sequences.

[0102] See Figure 4 The event detection process is as follows:

[0103] First, based on the results of entity text entity recognition, we obtain the entity detection sequence and entity label sequence of the text. In the event detection task, the factors affecting the type of event are mainly the types of participating entities and the language collocation in the event description. Therefore, when constructing the event detection model, we use the entity label mixed sequence to express its input features and construct the input sequence of the event detection model. Let the length of the entity label mixed sequence be n and the length of the model input sequence be n. eventdetec , and n eventdetec >n, for positions without labels, empty placeholders are used to fill them, and the last position is filled with a special placeholder to complete the input sequence of the model Construct, where pad is an empty placeholder and eve is a special placeholder.

[0104] Secondly, the input sequence is subjected to feature extraction. The input sequence is passed to the Word-Tag Embedding layer for feature extraction. The specific formula is as follows:

[0105]

[0106] Among them, X represents the extracted feature vector matrix, InputSeq represents the input one-hot encoded entity label mixed sequence matrix, Emb is the feature extraction matrix of the Word-Tag Embedding layer, and n eventdetec The length of the input sequence, n char Indicates the length of the one-hot encoding of the input sequence, n emb Dimensions that encode features of the feature matrix.

[0107] Constructing feature vector sequence by extracting feature vector The feature vector sequence is passed to the BILSTM for bidirectional sequence feature capture. The LSTM module is a time sequence permutation module whose input includes the feature input of the current moment and the feature input of the previous moment. Its calculation process is divided into three parts. First, the output of the forget gate is calculated. The formula is as follows:

[0108] f(t)=δ(W f [h t-1 ,x t ]+b f )

[0109] Among them, h t-1 is the state output of the previous moment, x t is the feature input vector at the current moment, δ is the nonlinear activation function of sigmoid, W fis the forget gate feature transfer matrix, b f is the offset of the forget gate.

[0110] Then, calculate the state output of the LSTM unit at the current moment. The formula is as follows:

[0111] i t =δ(W i [h t-1 ,x t ]+b i )

[0112]

[0113]

[0114] Among them, i t is the input gate, W i is the input gate feature transfer matrix, b i is the offset of the input gate, is the unit state update value, tanh is the nonlinear activation function, W C is the neuron state transfer matrix, b C is the neuron offset, C t is the current state feature of the neuron.

[0115] Finally, the output eigenvalue is calculated, and the formula is as follows:

[0116] o t =δ(W o [h t-1 ,x t ]+b o )

[0117] h t =o t *tanh(C t )

[0118] Among them, t is the output gate, W o is the output gate feature transfer matrix, b o is the offset of the output gate, h t is the output feature at time t.

[0119] Based on the characteristics of BILSTM, its feature calculation will capture features from the forward direction to obtain the forward features at each moment Capture features from the reverse direction to obtain reverse features at each moment The output features are obtained by concatenating the forward features and the reverse features, which can be expressed as From the characteristics of sequence capture, we can see that the features of the last moment of the sequence reflect the characteristic expression of the entire sequence. Therefore, the features of the last special placeholder are taken as the feature output of the BILSTM layer.

[0120] The features of the BILSTM layer are connected to the fully connected layer, and the probability distribution information corresponding to each event category is output through the fully connected layer. The calculation formula is as follows:

[0121]

[0122] Among them, W y is the fully connected matrix, and Y is the output event probability distribution matrix. The probability distribution Y is input into the Softmax layer for calculation to obtain the detection result of the event category.

[0123] The loss function of the event detection model adopts the cross entropy loss function and is defined as follows:

[0124]

[0125] where y i is the output probability distribution of the target, y i ' is the predicted output probability distribution. The model training process is a back-propagation process. The model parameters are continuously updated based on the minimization of the loss function until the model reaches the optimal solution for training evaluation and the model training process is completed.

[0126] See Figure 5 The event argument recognition process is as follows:

[0127] First, based on the entity tag mixed sequence, one-hot encoding is used to encode the entity tag mixed sequence features. This entity tag mixed sequence feature encoding is then passed to the Word-Tag Embedding layer for feature extraction, resulting in a feature vector matrix. Next, one-hot encoding is performed on the event detection type results to obtain the event type encoding features. Feature concatenation is then used to concatenate the feature vector matrix with the event type encoding features to construct the event argument feature sequence vector.

[0128] Secondly, based on the characteristics of BILSTM, the event features are captured from the positive direction to obtain the positive features at each moment. Capture the event features in reverse to obtain the reverse features at each moment The output features are obtained by concatenating the forward features and the reverse features, which can be expressed as The captured features at each moment are sequenced and encapsulated to obtain the output of the event argument feature BILSTM layer.

[0129] Based on the feature output of BILSTM, a fully connected layer is constructed for linear activation. The formula is as follows:

[0130]

[0131] Among them, y t Represents the event argument category output at position t, W role is the fully connected matrix of event arguments. Through linear activation, the features of the BILSTM layer are transferred into k-dimensional features, whose eigenvalues ​​represent the predicted probability distribution of the corresponding event argument role.

[0132] After the fully connected layer, a CRF layer is added for reduced prediction. The probability calculation formula of CRF is as follows:

[0133]

[0134] Among them, Z(x) is the normalization factor used to normalize the conditional probability, exp is a natural constant, and t k (y i-1 ,y i ,i) is the time series characteristic function of the observed sequence, i represents the position of the label, y represents the observed sequence, τ k t k (y i-1 ,y i ,i) Weight parameter of the feature function, k represents the number of functions, s l (y i ,x,i) is the relationship function between the observed prediction and the observed sequence characteristics, u l Indicates s l (y i ,x,i) weight parameter of the feature function, l represents the number of functions.

[0135] Then, based on the Viterbi algorithm, the maximum probability path of the entire sequence information is solved to obtain the data label type corresponding to each input unit, and the identification of event arguments is completed.

[0136] The loss function of the event argument recognition model is as follows:

[0137]

[0138] Among them, P RealPath is the probability of occurrence of the correct prediction sequence, P N is the probability of an incorrect prediction sequence, and by maximizing the loss function, P is continuously improved. RealPath The proportion in the predicted probability is achieved by back propagation and adjusting the model parameters to realize the model training process.

[0139] This embodiment provides a pipeline-based event detection and event extraction method. By dividing and decomposing the data preprocessing, entity recognition, event detection, and event argument recognition processes, the event detection and event argument recognition processes are separated. The data situation of each process can be analyzed, and the data of each module can be fed back in a hierarchical manner. In the construction of event features, the entity information features are blurred and the non-entity semantic matching features are strengthened, so that the model has better effects in event detection and argument recognition in professional fields.

[0140] Reference Figure 6 , Figure 6 This is a structural block diagram of an embodiment of a text information processing device of the present invention.

[0141] like Figure 6 As shown, the text information processing device proposed in the embodiment of the present invention includes:

[0142] A construction module 10 is configured to obtain an entity detection sequence and an entity label sequence of target text information, and construct an entity label mixed sequence based on the entity detection sequence and the entity label sequence;

[0143] A first determination module 20 is configured to extract feature information of the entity tag mixed sequence and determine the event type of the target text information based on the feature information;

[0144] A concatenation module 30 is configured to concatenate the event type feature and the entity label mixed sequence feature to obtain a feature matrix;

[0145] The second determining module 40 is configured to determine the event argument role of the target text information based on the feature matrix.

[0146] Other embodiments or specific implementations of the text information processing device of the present invention can refer to the above-mentioned method embodiments and will not be described in detail here.

[0147] In addition, an embodiment of the present invention further proposes a storage medium, on which a text information processing method program is stored, and when the text information processing method program is executed by a processor, the steps of the text information processing method as described above are implemented. Therefore, no further description will be given here. In addition, the description of the beneficial effects of adopting the same method will not be repeated. For technical details not disclosed in the computer-readable storage medium embodiment involved in this application, please refer to the description of the method embodiment of this application. As an example, the program instructions can be deployed to be executed on one computing device, or on multiple computing devices located at one location, or on multiple computing devices distributed at multiple locations and interconnected by a communication network.

[0148] Those skilled in the art will appreciate that all or part of the processes in the above-described method embodiments can be implemented by instructing related hardware through a computer program. The above-described program can be stored in a computer-readable storage medium. When executed, the program can include the processes in the above-described method embodiments. The above-described storage medium can be a magnetic disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).

[0149] It should also be noted that the device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed across multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the present embodiment. In addition, in the drawings of the device embodiments provided by the present invention, the connection relationship between the modules indicates that there is a communication connection between them, which may be specifically implemented as one or more communication buses or signal lines. A person of ordinary skill in the art can understand and implement the present invention without inventive effort.

[0150] Through the description of the above embodiments, those skilled in the art can clearly understand that the present invention can be implemented by means of software plus necessary general-purpose hardware, and of course can also be implemented by means of dedicated hardware including application-specific integrated circuits, dedicated CPUs, dedicated memories, dedicated components, etc. In general, all functions performed by computer programs can be easily implemented by corresponding hardware, and the specific hardware structures used to implement the same function can also be diverse, such as analog circuits, digital circuits, or dedicated circuits. However, for the present invention, software program implementation is a better implementation method in most cases. Based on this understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which is stored in a readable storage medium, such as a computer floppy disk, USB flash drive, mobile hard disk, read-only memory (ROM), random access memory (RAM), magnetic disk or optical disk, etc., and includes a number of instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) to execute the methods described in each embodiment of the present invention.

Claims

1. A text information processing method, characterized in that: The method comprises the following steps: When receiving the target text information, performing standardization processing on the target text information, wherein the standardization processing includes sentence segmentation processing; Obtaining an entity detection sequence and an entity label sequence of target text information, including: performing entity recognition on the target text information according to a sentence processing result of the target text information to obtain entity information and non-entity information of the target text information; constructing an entity detection sequence based on the entity information and non-entity information; obtaining a label for each element in the entity detection sequence, and constructing an entity label sequence based on all the labels; and constructing an entity label mixed sequence according to the entity detection sequence and the entity label sequence; Extracting feature information of the entity tag mixed sequence, and determining the event type of the target text information based on the feature information; Concatenate the event type features with the entity label mixed sequence features to obtain a feature matrix; Based on the feature matrix, the event argument role of the target text information is determined.

2. The text information processing method according to claim 1, wherein: The step of constructing an entity label mixed sequence according to the entity detection sequence and the entity label sequence specifically includes: If an element in the entity detection sequence has a corresponding label in the entity label sequence, the label corresponding to the element is used as the label element in the entity label mixed sequence; If an element in the entity detection sequence has no corresponding label in the entity label sequence, the character corresponding to the element is used as the character element in the entity label mixed sequence; An entity tag mixed sequence is constructed according to the tag elements and the character elements.

3. The text information processing method according to claim 2, wherein: The step of extracting feature information of the entity tag mixed sequence and determining the event type of the target text information based on the feature information specifically includes: Using a BILSTM-SOFTMAX model to identify the event type of each entity information in the entity label mixed sequence; wherein the BILSTM-SOFTMAX model includes a feature capture layer and a probability decision layer; The feature capture layer captures the context sequence of the entity tag sequence, and maps the feature information to the feature matrix of event type distribution based on the linear fully connected layer to obtain the event tag category probability distribution matrix corresponding to the entity tag mixed feature; The probability decision layer normalizes the event label category probability distribution matrix to obtain the event type of each entity information in the entity label mixed sequence.

4. The text information processing method according to claim 3, wherein: The step of concatenating the event type feature and the entity label mixed sequence feature to obtain the feature matrix specifically includes: Based on the entity tag mixed sequence, one-hot encoding is used to encode the features of the entity tag mixed sequence, and the features of the feature encoding are extracted to obtain a feature vector matrix; One-hot encoding is performed on the event type to obtain a feature code of the event type, and the feature vector matrix and the feature code of the event type are concatenated to obtain a feature matrix.

5. The text information processing method according to claim 4, wherein: The step of determining the event argument role of the target text information based on the feature matrix specifically includes: Using a BILSTM-CRF model to identify the event argument role corresponding to each feature in the feature matrix; wherein the BILSTM-CRF model includes a sequence feature capture layer and a sequence label prediction layer; The sequence feature capture layer captures the context features of the feature matrix and maps the features to corresponding event argument roles based on a linear fully connected layer to obtain a probability distribution matrix of event argument role types corresponding to the feature matrix; The sequence label prediction layer generates a feature transfer matrix of the observation sequence and the observed sequence according to the event argument role type probability distribution matrix, and obtains the event argument role of each feature in the feature matrix.

6. A text information processing device, characterized in that: The text information processing device includes: a processing module, configured to perform standardization processing on the target text information when receiving the target text information, wherein the standardization processing includes sentence segmentation processing; A construction module is used to obtain an entity detection sequence and an entity label sequence of target text information, including: performing entity recognition on the target text information based on the sentence processing result of the target text information to obtain entity information and non-entity information of the target text information; constructing an entity detection sequence based on the entity information and non-entity information; obtaining a label for each element in the entity detection sequence, and constructing an entity label sequence based on all the labels; and constructing an entity label mixed sequence based on the entity detection sequence and the entity label sequence; A first determination module is configured to extract feature information of the entity tag mixed sequence and determine the event type of the target text information based on the feature information; The splicing module is used to splice the features of the event type and the entity label mixed sequence to obtain the feature matrix; The second determination module is configured to determine the event argument role of the target text information based on the feature matrix.

7. A text information processing device, characterized in that: The text information processing device includes: a memory, a processor, and a text information processing method program stored in the memory and executable on the processor. When the text information processing method program is executed by the processor, the steps of the text information processing method according to any one of claims 1 to 5 are implemented.

8. A storage medium, characterized in that: The storage medium stores a text information processing method program, which implements the steps of the text information processing method according to any one of claims 1 to 5 when executed by a processor.

Citation Information

Patent Citations

  • Event extraction method and device based on preset neural network, computer equipment and storage medium

    CN112183030A

  • Method for extracting event argument in text and electronic equipment

    CN114297394A