Event element generation method, system, terminal and storage medium

CN116306586BActive Publication Date: 2026-10-30BEIJING UNISOUND INFORMATION TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310286001.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-03-22
Publication Date
2026-10-30
Estimated Expiration
2043-03-22

AI Technical Summary

Technical Problem

[0004]本发明实施例的目的在于提供一种事件元素生成方法、系统、终端及存储介质,旨在解决现有的事件元素生成准确性低下的问题

Benefits of technology

[0038]本发明实施例,通过字前缀树构建字前缀向量矩阵,有效地保障了与字概率分布之间的融合,通过将字前缀向量矩阵与字概率分布进行融合,能有效地在字概率分布中添加词汇先验知识,进而提高了词表概率分布的准确性,基于词表概率分布构建事件元素集合,提高了事件元素生成的准确性。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116306586B_ABST
    Figure CN116306586B_ABST
Patent Text Reader

Abstract

The application provides an event element generation method, system, terminal and storage medium, and the method comprises the following steps: constructing a word prefix tree and a word prefix vector matrix according to a word set, performing coding processing on sample text to obtain a text representation vector, performing decoding processing on the text representation vector to obtain a text decoding result, determining a word probability distribution of each word according to the text decoding result, fusing the word prefix vector matrix and the word probability distribution to obtain a word list probability distribution; and constructing an event element set according to the word list probability distribution. By fusing the word prefix vector matrix and the word probability distribution, the application can effectively add word priori knowledge in the word probability distribution, thereby improving the accuracy of the word list probability distribution, and constructing the event element set based on the word list probability distribution can improve the accuracy of event element generation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of data processing technology, and in particular to an event element generation method, system, terminal, and storage medium. Background Technology

[0002] Event extraction typically consists of four parts: trigger word detection, event type identification, argument identification, and argument role classification. The trigger words and arguments extracted during the event extraction process are collectively referred to as event elements. Event elements and trigger words determine the event category. With the development of big data technology, the issue of event element generation is receiving increasing attention.

[0003] In existing event element generation processes, an encoder-decoder structure is generally used. The encoder encodes the original text to obtain the vector representation of each character, and the decoder generates event element information step by step. However, when event element generation is performed using only the encoding and decoding method, inaccurate word prediction occurs, which leads to low accuracy in event element generation. Summary of the Invention

[0004] The purpose of this invention is to provide an event element generation method, system, terminal, and storage medium, aiming to solve the problem of low accuracy in existing event element generation.

[0005] This invention is implemented as follows: an event element generation method, the method comprising:

[0006] A prefix tree is constructed based on the vocabulary set, and a prefix vector matrix is ​​constructed based on the prefix tree. The prefix tree is used to represent the vocabulary range of each character in the vocabulary set.

[0007] The sample text is encoded to obtain a text representation vector, and the text representation vector is decoded to obtain a text decoding result. The text representation vector includes the representation vector of each character in the sample text.

[0008] Based on the text decoding results, the probability distribution of each character in the sample text within the vocabulary set is determined, and the character prefix vector matrix is ​​fused with the character probability distribution to obtain the vocabulary probability distribution;

[0009] Construct a set of event elements based on the probability distribution of the vocabulary.

[0010] Preferably, the encoding process of the sample text to obtain a text representation vector includes:

[0011] The sample text is processed by extracting trigger words and arguments to obtain event trigger words and event arguments, and the event arguments are then separated into arguments.

[0012] The event arguments, separated by the event trigger words and arguments, are sorted to obtain an element text sequence, and the element text sequence is then represented by a vector to obtain the text representation vector.

[0013] Preferably, constructing the event element set based on the vocabulary probability distribution includes:

[0014] Based on the probability distribution of the vocabulary, the event characters in each sample text are determined, and the event trigger words and event arguments corresponding to each event character are queried.

[0015] Event elements are generated based on the event trigger words and event arguments corresponding to each event character, and the event element set is constructed based on each event element.

[0016] Preferably, the formula used to decode the text representation vector includes:

[0017]

[0018] in, , and These are the training parameters in the encoder. This represents the hidden layer representation of the upper layer in the decoder. The text decoding result, It is the text representation vector. express and Dimensions.

[0019] Preferably, the formula used to determine the probability distribution of each character in the sample text within the vocabulary set based on the text decoding result includes:

[0020]

[0021] in, This is the probability distribution of the character;

[0022] The formula used to fuse the word prefix vector matrix with the word probability distribution includes:

[0023]

[0024] in, These are the preset learning parameters. The probability distribution of the vocabulary is... It is the co-occurring character vector in the character prefix vector matrix.

[0025] Preferably, constructing the word prefix vector matrix based on the word prefix tree includes:

[0026] Obtain the index of each character in the prefix tree in the vocabulary set to obtain the first index, and obtain the index of the next character after each character in the vocabulary set to obtain the second index;

[0027] The co-occurring word vectors are determined based on the first index and the second index, and the word prefix vector matrix is ​​generated based on the co-occurring word vectors.

[0028] Preferably, the step of constructing a prefix tree based on the vocabulary set includes:

[0029] Query the word type of each word in the word set, and filter the words according to the word type;

[0030] Based on the filtered vocabulary, query the word groups corresponding to each character, and construct the word prefix tree using each character as the origin of the prefix tree and the queried word groups.

[0031] Another objective of this invention is to provide an event element generation system, the system comprising:

[0032] A matrix construction module is used to construct a prefix tree based on a vocabulary set and to construct a prefix vector matrix based on the prefix tree, wherein the prefix tree is used to represent the vocabulary range of each character in the vocabulary set;

[0033] The encoding / decoding module is used to encode the sample text to obtain a text representation vector, and to decode the text representation vector to obtain a text decoding result. The text representation vector includes the representation vector of each character in the sample text.

[0034] The vector fusion module is used to determine the probability distribution of each character in the sample text in the vocabulary set according to the text decoding result, and to fuse the character prefix vector matrix with the character probability distribution to obtain the vocabulary probability distribution;

[0035] The set construction module is used to construct a set of event elements based on the probability distribution of the vocabulary.

[0036] Another objective of this invention is to provide a terminal device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the method described above.

[0037] Another objective of this invention is to provide a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the above-described method.

[0038] In this embodiment of the invention, a prefix vector matrix is ​​constructed by a prefix tree, which effectively ensures the integration with the word probability distribution. By integrating the prefix vector matrix with the word probability distribution, prior lexical knowledge can be effectively added to the word probability distribution, thereby improving the accuracy of the word probability distribution. Based on the word probability distribution, an event element set is constructed, which improves the accuracy of event element generation. Attached Figure Description

[0039] Figure 1 This is a flowchart of the event element generation method provided in the first embodiment of the present invention;

[0040] Figure 2 This is a schematic diagram of the prefix tree provided in the first embodiment of the present invention;

[0041] Figure 3 This is a schematic diagram of the structure of the event element generation model provided in the first embodiment of the present invention;

[0042] Figure 4 This is a flowchart of the event element generation method provided in the second embodiment of the present invention;

[0043] Figure 5 This is a schematic diagram of the event element generation system provided in the third embodiment of the present invention;

[0044] Figure 6 This is a schematic diagram of the structure of the terminal device provided in the fourth embodiment of the present invention. Detailed Implementation

[0045] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention.

[0046] To illustrate the technical solution described in this invention, specific embodiments are described below.

[0047] Example 1

[0048] Please see Figure 1 This is a flowchart of an event element generation method provided in the first embodiment of the present invention. This event element generation method can be applied to any terminal device or system, and includes the following steps:

[0049] Step S10: Construct a prefix tree based on the vocabulary set, and construct a prefix vector matrix based on the prefix tree;

[0050] Herein, the character trie is used to characterize the vocabulary range of each character in the vocabulary set, which can be configured with vocabularies according to requirements. Based on the pre-configured vocabulary set, the occurrence range of the next character under the condition of a given character is searched. For example, in medical scenarios, there often exist cases such as Figure 2 shown in the figure, when the character "fa" (meaning "to emit / develop") is obtained by decoding, the usually accompanying characters include combinations of vocabularies such as "shao" (fever) and "re" (heat);

[0051] Optionally, in this step, the constructing a character trie according to the vocabulary set includes:

[0052] respectively querying the vocabulary type of each vocabulary in the vocabulary set, and screening the vocabularies according to the vocabulary types;

[0053] Herein, the vocabulary type is used to characterize the application scenario of the corresponding vocabulary, and the application scenario includes a medical scenario, an insurance assessment scenario, a tourism scenario and the like. In this step, a specified scenario is set for the current scenario, and vocabulary screening is performed according to the specified scenario and the vocabulary type of each vocabulary, thereby improving the accuracy of the vocabularies in the vocabulary set;

[0054] respectively querying the character group corresponding to each character according to the screened vocabularies, taking each character as the origin of the trie, and performing tree construction according to the queried character groups to obtain the character trie;

[0055] Herein, the character trie is obtained by taking each character as the origin of the trie and supplementing the character group corresponding to each character respectively.

[0056] Step S20: performing encoding processing on the sample text to obtain a text representation vector, and performing decoding processing on the text representation vector to obtain a text decoding result;

[0057] Herein, the text representation vector includes the representation vector of each character in the sample text. For the text sequence of the sample text = , the encoder is input to obtain the representation vector of each character, so as to obtain the text representation vector E= , where n represents the length of the text sequence of the sample text input into the encoder.

[0058] Optionally, in this step, the performing encoding processing on the sample text to obtain a text representation vector includes:

[0059] performing extraction of trigger words and arguments on the sample text to obtain event trigger words and event arguments, and performing argument separation on the event arguments;

[0060] This can be achieved by inserting preset separators between different event arguments. These preset separators can be set as needed; for example, they can be set to " / ", "-", and "". <dsep>"etc., in this step, by separating the event arguments, it is effectively convenient to identify the different event arguments in the subsequent steps;

[0061] The event arguments, separated from the event trigger words and arguments, are sorted to obtain an element text sequence, and the element text sequence is vectorized to obtain the text representation vector;

[0062] For example, the text sequence of the sample text input to the encoder is "bleed". <asoc>Yin and Yang <asoc>time <asoc>Part <sep>The patient injured their left thumb at work this morning at 9:00 AM due to being crushed by a steel bar, resulting in bleeding, pain, and swelling. The event trigger word and event arguments are placed at the beginning of the original text. The identified event trigger word is "bleeding," and "positive / negative," "time," and "location" are the event argument roles. The decoding end needs to generate arguments for the corresponding argument roles sequentially. "positive" <dsep>9 a.m. today <dsep>"Left thumb", using the default separator " <dsep>Separate different arguments and represent the element text sequence generated at the decoding end as follows: = The text representation vector S is obtained by representing the text sequence of elements into a vector. .

[0063] Furthermore, in this step, the formula used for decoding the text representation vector includes:

[0064]

[0065] in, , and These are the training parameters in the encoder. This represents the hidden layer representation of the upper layer in the decoder. The result of text decoding. It is a text representation vector. express and In this embodiment, the semantic information E obtained by the encoder is fused into the vector representation in the decoder through the attention mechanism to achieve the effect of adding lexical information during the decoding process.

[0066] Step S30: Based on the text decoding result, determine the word probability distribution of each character in the sample text in the vocabulary set, and fuse the word prefix vector matrix with the word probability distribution to obtain the vocabulary probability distribution;

[0067] Specifically, by determining the word probability distribution of each character in the sample text within the vocabulary set, the probability of each character appearing in the vocabulary set is obtained. By fusing the character prefix vector matrix with the word probability distribution, prior vocabulary knowledge can be effectively added to the word probability distribution, thereby improving the accuracy of the vocabulary probability distribution.

[0068] Optionally, in this step, the formula used to determine the probability distribution of each character in the sample text within the vocabulary set based on the text decoding result includes:

[0069]

[0070] in, The word probability distribution is obtained by passing the output of the top layer of the decoder through a feedforward neural network and Softmax calculations. .

[0071] The formula used to fuse the word prefix vector matrix with the word probability distribution includes:

[0072]

[0073] in, These are the preset learning parameters. For the probability distribution of the vocabulary, These are the co-occurring word vectors in the word prefix vector matrix. Please refer to [link / reference]. Figure 3 Based on the word prefix vector matrix obtained in step S10, the co-occurrence word vector c is obtained by looking up the table. ][ ]= The prefix vector matrix of each character is fused into the probability distribution of the character to obtain the probability distribution of the vocabulary.

[0074] Step S40: Construct an event element set based on the vocabulary probability distribution;

[0075] Optionally, constructing the event element set based on the vocabulary probability distribution includes:

[0076] Based on the probability distribution of the vocabulary, the event characters in each sample text are determined, and the event trigger words and event arguments corresponding to each event character are queried.

[0077] In each sample text, the character with the highest probability in the vocabulary probability distribution is determined as the event character in each sample text, and the event trigger word and event argument corresponding to each event character are queried respectively.

[0078] Event elements are generated based on the event trigger words and event arguments corresponding to each event character, and the event element set is constructed based on each event element; wherein, for each sample text, the event elements corresponding to each event character are stored respectively to construct the event element set.

[0079] In this embodiment, the word prefix vector matrix is ​​constructed by word prefix tree, which effectively ensures the integration with word probability distribution. By integrating word prefix vector matrix with word probability distribution, prior lexical knowledge can be effectively added to word probability distribution, thereby improving the accuracy of word probability distribution. The event element set is constructed based on word probability distribution, which improves the accuracy of event element generation.

[0080] Example 2

[0081] Please see Figure 4 This is a flowchart of an event element generation method provided in the second embodiment of the present invention. This embodiment further refines step S10 in the first embodiment, including the following steps:

[0082] Step S11: respectively acquiring the index of each character in the character trie in the vocabulary set to obtain a first index, and respectively acquiring the index of the next character after each said character in the vocabulary set to obtain a second index;

[0083] Wherein, by respectively acquiring the first index and the second index, the accuracy of subsequent co-occurrence character vector determination is effectively improved. For example, when the character trie includes "fever" and "pyrexia", the index of the character "fa" in the vocabulary set is acquired to obtain the first index, and the indices of the characters "shao" and "re" in the vocabulary set are respectively acquired to obtain the second index;

[0084] Step S12: determining a co-occurrence character vector according to the first index and the second index, and generating the character prefix vector matrix according to the co-occurrence character vector;

[0085] For example, the size of the vocabulary set is v, and the co-occurrence character vector matrix is , the index of character w in the vocabulary set is , the character that appears after w is a, and the index of character a in the vocabulary list is , then in the co-occurrence character vector, c =1, otherwise c =0, and the character prefix vector matrix with complete character prefix relationships is constructed by traversing each word in the character trie.

[0086] In this embodiment, by respectively acquiring the first index and the second index, the accuracy of subsequent co-occurrence character vector determination is effectively improved, the co-occurrence character vector can be effectively determined based on the first index and the second index, and the character prefix vector matrix can be effectively generated based on the co-occurrence character vector.

[0087] Example 3

[0088] Please refer to Figure 5 , which is a schematic structural diagram of an event element generation system 100 provided by the third embodiment of the present invention, comprising: a matrix construction module 10, an encoding and decoding module 11, a vector fusion module 12, and a set construction module 13, wherein:

[0089] The matrix construction module 10 is configured to construct a character trie according to a vocabulary set, and construct a character prefix vector matrix according to the character trie, wherein the character trie is configured to represent the vocabulary range of each character in the vocabulary set. The vocabulary set can be set with vocabularies according to requirements, and based on the pre-set vocabulary set, the range of the next character appearing under the condition of a given character is found. For example, in medical scenarios, combinations of vocabularies such as Figure 2 often exist, and when "fa" is obtained by decoding, the usually accompanying characters include combinations of vocabularies such as "shao" and "re". ​​

[0090] Optionally, the matrix construction module 10 is further configured to: obtain the index of each character in the prefix tree in the vocabulary set to obtain a first index, and obtain the index of the next character after each character in the vocabulary set to obtain a second index;

[0091] The co-occurring word vectors are determined based on the first index and the second index, and the word prefix vector matrix is ​​generated based on the co-occurring word vectors.

[0092] Furthermore, the matrix construction module 10 is also used to: query the word type of each word in the word set respectively, and filter the words according to the word type; wherein, the word type is used to represent the application scenario of the corresponding word, the application scenario includes medical scenario, insurance assessment scenario and tourism scenario, etc. In this module, a specified scenario is set for the current scenario, and the word is filtered according to the specified scenario and the word type of each word, thereby improving the accuracy of the words in the word set;

[0093] Based on the filtered vocabulary, the word groups corresponding to each character are queried, and a tree is constructed based on the queried word groups, using each character as the origin of the prefix tree, to obtain the word prefix tree. In this process, the word prefix tree is obtained by supplementing the word groups corresponding to each character with each character as the origin of the prefix tree.

[0094] The encoding / decoding module 11 is used to encode the sample text to obtain a text representation vector, and to decode the text representation vector to obtain a text decoding result. The text representation vector includes the representation vector of each character in the sample text. For a text sequence of the sample text... = The encoder is input to obtain the representation vector of each character, resulting in the text representation vector E= , where n represents the length of the text sequence of the sample text in the input encoder.

[0095] Optionally, the encoding / decoding module 11 is further configured to: extract trigger words and arguments from the sample text to obtain event trigger words and event arguments, and perform argument separation on the event arguments; wherein, the separation effect of event arguments can be achieved by inserting preset separators between different event arguments, and the preset separators can be set according to requirements, for example, the preset separators can be set to " / ", "-", and "". <dsep>In this module, by separating event arguments, the identification of different event arguments in the subsequent steps is effectively facilitated.

[0096] The event arguments, separated from the event trigger words and arguments, are sorted to obtain an element text sequence, and then the element text sequence is vectorized to obtain the text representation vector; for example, the text sequence of the sample text input by the encoder is "bleeding". <asoc>Yin and Yang <asoc>time <asoc>Part <sep>The patient injured their left thumb at work this morning at 9:00 AM due to being crushed by a steel bar, resulting in bleeding, pain, and swelling. The event trigger word and event arguments are placed at the beginning of the original text. The identified event trigger word is "bleeding," and "positive / negative," "time," and "location" are the event argument roles. The decoding end needs to generate arguments for the corresponding argument roles sequentially. "positive" <dsep>9 a.m. today <dsep>"Left thumb", using the default separator " <dsep>Separate different arguments and represent the element text sequence generated at the decoding end as follows: = The text representation vector S is obtained by representing the text sequence of elements into a vector. .

[0097] Furthermore, the formula used for decoding the text representation vector includes:

[0098]

[0099] in, , and These are the training parameters in the encoder. This represents the hidden layer representation of the upper layer in the decoder. The text decoding result, It is the text representation vector. express and Dimensions.

[0100] The vector fusion module 12 is used to determine the probability distribution of each character in the sample text in the vocabulary set according to the text decoding result, and to fuse the character prefix vector matrix with the character probability distribution to obtain the vocabulary probability distribution. By determining the probability distribution of each character in the sample text in the vocabulary set, the probability of each character appearing in the vocabulary set is obtained. By fusing the character prefix vector matrix with the character probability distribution, prior vocabulary knowledge can be effectively added to the character probability distribution, thereby improving the accuracy of the vocabulary probability distribution.

[0101] Optionally, the formula used to determine the probability distribution of each character in the sample text within the vocabulary set based on the text decoding result includes:

[0102]

[0103] in, This is the probability distribution of the character;

[0104] The formula used to fuse the word prefix vector matrix with the word probability distribution includes:

[0105]

[0106] in, These are the preset learning parameters. The probability distribution of the vocabulary is... It is the co-occurring character vector in the character prefix vector matrix.

[0107] The set construction module 13 is used to construct a set of event elements based on the probability distribution of the vocabulary.

[0108] Optionally, the set construction module 13 is further configured to: determine the event characters in each sample text according to the vocabulary probability distribution, and query the event trigger words and event arguments corresponding to each event character;

[0109] Event elements are generated based on the event trigger words and event arguments corresponding to each event character, and the event element set is constructed based on each event element.

[0110] In this embodiment, a prefix vector matrix is ​​constructed by using a prefix tree, which effectively ensures the integration with the word probability distribution. By integrating the prefix vector matrix with the word probability distribution, prior lexical knowledge can be effectively added to the word probability distribution, thereby improving the accuracy of the word probability distribution. The event element set is constructed based on the word probability distribution, which improves the accuracy of event element generation.

[0111] Example 4

[0112] Figure 6 This is a structural block diagram of a terminal device 2 provided in the fourth embodiment of this application. For example... Figure 6 As shown, the terminal device 2 in this embodiment includes: a processor 20, a memory 21, and a computer program 22 stored in the memory 21 and executable on the processor 20, such as a program for an event element generation method. When the processor 20 executes the computer program 22, it implements the steps in the various embodiments of the event element generation methods described above.

[0113] For example, the computer program 22 may be divided into one or more modules, which are stored in the memory 21 and executed by the processor 20 to complete this application. The one or more modules may be a series of computer program instruction segments capable of performing specific functions, which describe the execution process of the computer program 22 in the terminal device 2. The terminal device may include, but is not limited to, the processor 20 and the memory 21.

[0114] The processor 20 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor.

[0115] The memory 21 can be an internal storage unit of the terminal device 2, such as a hard drive or memory of the terminal device 2. The memory 21 can also be an external storage device of the terminal device 2, such as a plug-in hard drive, Smart Media Card (SMC), Secure Digital (SD) card, or Flash Card equipped on the terminal device 2. Furthermore, the memory 21 can include both internal and external storage units of the terminal device 2. The memory 21 is used to store the computer program and other programs and data required by the terminal device. The memory 21 can also be used to temporarily store data that has been output or will be output.

[0116] Furthermore, the functional modules in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0117] If an integrated module is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. This computer-readable storage medium can be non-volatile or volatile. Based on this understanding, all or part of the processes in the methods of the above embodiments can also be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable storage medium can include: any entity or device capable of carrying computer program code, recording media, USB flash drives, portable hard drives, magnetic disks, optical disks, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signals, telecommunication signals, and software distribution media, etc. It should be noted that the contents of a computer-readable storage medium may be appropriately added to or subtracted from the contents as required by the legislation and patent practice in a jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, a computer-readable storage medium may not include electrical carrier signals and telecommunication signals.

[0118] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.< / dsep> < / dsep> < / dsep> < / sep> < / asoc> < / asoc> < / asoc> < / dsep> < / dsep> < / dsep> < / dsep> < / sep> < / asoc> < / asoc> < / asoc> < / dsep>

Claims

1. A method for generating event elements, characterized in that, The method includes: A prefix tree is constructed based on the vocabulary set, and a prefix vector matrix is ​​constructed based on the prefix tree. The prefix tree is used to represent the vocabulary range of each character in the vocabulary set. The sample text is encoded to obtain a text representation vector, and the text representation vector is decoded to obtain a text decoding result. The text representation vector includes the representation vector of each character in the sample text. Based on the text decoding results, the probability distribution of each character in the sample text within the vocabulary set is determined, and the character prefix vector matrix is ​​fused with the character probability distribution to obtain the vocabulary probability distribution; Construct a set of event elements based on the probability distribution of the vocabulary; The step of constructing a prefix vector matrix based on the prefix tree includes: Obtain the index of each character in the prefix tree in the vocabulary set to obtain the first index, and obtain the index of the next character after each character in the vocabulary set to obtain the second index; The co-occurring character vectors are determined based on the first index and the second index, and the character prefix vector matrix is ​​generated based on the co-occurring character vectors.

2. The event element generation method as described in claim 1, characterized in that, The encoding process of the sample text to obtain a text representation vector includes: The sample text is processed by extracting trigger words and arguments to obtain event trigger words and event arguments, and the event arguments are then separated into arguments. The event arguments, separated by the event trigger words and arguments, are sorted to obtain an element text sequence, and the element text sequence is then represented by a vector to obtain the text representation vector.

3. The event element generation method as described in claim 2, characterized in that, The step of constructing the event element set based on the vocabulary probability distribution includes: Based on the probability distribution of the vocabulary, the event characters in each sample text are determined, and the event trigger words and event arguments corresponding to each event character are queried. Event elements are generated based on the event trigger words and event arguments corresponding to each event character, and the event element set is constructed based on each event element.

4. The event element generation method as described in any one of claims 1 to 3, characterized in that, The construction of a prefix tree based on the vocabulary set includes: Query the word type of each word in the word set, and filter the words according to the word type; Based on the filtered vocabulary, the word groups corresponding to each character are queried, and a tree is constructed based on the queried word groups, using each character as the origin of the prefix tree, to obtain the word prefix tree; wherein, by using each character as the origin of the prefix tree, the word groups corresponding to each character are supplemented to obtain the word prefix tree.

5. An event element generation system, characterized in that, The system includes: A matrix construction module is used to construct a prefix tree based on a vocabulary set and to construct a prefix vector matrix based on the prefix tree, wherein the prefix tree is used to represent the vocabulary range of each character in the vocabulary set; The encoding / decoding module is used to encode the sample text to obtain a text representation vector, and to decode the text representation vector to obtain a text decoding result. The text representation vector includes the representation vector of each character in the sample text. The vector fusion module is used to determine the probability distribution of each character in the sample text in the vocabulary set according to the text decoding result, and to fuse the character prefix vector matrix with the character probability distribution to obtain the vocabulary probability distribution; The set construction module is used to construct a set of event elements based on the vocabulary probability distribution; The matrix construction module is further configured to: obtain the index of each character in the prefix tree in the vocabulary set to obtain a first index, and obtain the index of the next character after each character in the vocabulary set to obtain a second index; The co-occurring character vectors are determined based on the first index and the second index, and the character prefix vector matrix is ​​generated based on the co-occurring character vectors.

6. A terminal device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the method as described in any one of claims 1 to 4.

7. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method as described in any one of claims 1 to 4.