Implementations of the present specification disclose an event risk detection method, apparatus, and device. The method includes: obtaining event description information provided by a plurality of different event initiators when the plurality of different event initiators each initiate a target event to a same event target party in a same event service; then converting, into a token sequence, a plurality of character sequences of the event description information provided by the plurality of different event initiators, the token sequence including a plurality of sub-token sequences each corresponding to a character sequence of event description information provided by an event initiator; setting a set of a first number of token positions for each sub-token sequence of the plurality of sub-token sequences, and sequentially placing characters in each sub-token sequence of the plurality of sub-token sequences at a corresponding set of the first number of token positions based on an order of each sub-token sequence; and determining, based on a corresponding sub-token sequence placed at each set of the first number of token positions, token information of an event initiator corresponding to each set of the first number of token positions, and a text classification model, whether the target event is at risk.
Legal claims defining the scope of protection, as filed with the USPTO.
. A method, the method comprising:
. The method according to, wherein the classifying the target event includes:
. The method according to, wherein the classifying the target event includes:
. The method according to, wherein the classifying, based on the encoding result, the target event includes:
. The method according to, wherein the encoder is constructed by using a Transformer Block.
. The method according to, further comprising:
. The method according to, wherein the text classification model is constructed based on a Bidirectional Encoder Representations from Transformers (BERT) model.
. A computing system, comprising:
. The computing system according to, wherein the classifying the target event includes:
. The computing system according to, wherein the classifying the target event includes:
. The computing system according to, wherein the classifying, based on the encoding result, the target event includes:
. The computing system according to, wherein the encoder is constructed by using a Transformer Block.
. The computing system according to, wherein the operations further include:
. The computing system according to, wherein the text classification model is constructed based on a Bidirectional Encoder Representations from Transformers (BERT) model.
. A non-transitory storage medium, the storage medium having computer-executable instructions stored thereon, the executable instructions, when executed by one or more processors, causing the one or more processors to, individually or collectively, implement acts comprising:
. The storage medium according to, wherein the classifying the target event includes:
. The storage medium according to, wherein the classifying the target event includes:
. The storage medium according to, wherein the classifying, based on the encoding result, the target event includes:
. The storage medium according to, wherein the encoder is constructed by using a Transformer Block.
. The storage medium according to, wherein the acts further include:
Complete technical specification and implementation details from the patent document.
The present specification relates to the field of computer technologies, and in particular, to risk event detection and classification detection method, apparatus, and device.
In human-computer interaction of a risk event control scenario, a user may provide false information to obtain undue benefits. An account of an event target party in the risk control scenario is fixed, and a number of event initiators is large.
Generally, a plurality of pieces of evidence can be obtained to determine whether certain information is true or false or whether a certain event is a risk event.
The present specification provides a risk event detection and classification mechanism, which quickly and accurately detects whether event description information provided by a plurality of event initiators for a specified event is contradictory to each other, so as to determine whether an event initiator in the plurality of event initiators provides false information, and further determine whether the event is at risk. The event detection and classification mechanism includes a natural language processing technique that processes event descriptions provided by event initiators of a target event.
The solution determines whether event description information provided by a plurality of event initiators for a specified event is contradictory to each other, so as to determine whether a certain event initiator in the plurality of event initiators provides false information, and further determine whether the event is a risk event.
The present specification may be implemented using the following example implementations:
An implementation of the present specification provides an event risk detection method. The method includes: obtaining event description information provided by a plurality of different event initiators when the plurality of different event initiators each initiate a target event to a same event target party in a same event service; converting, into a token sequence, a plurality of character sequences of the event description information provided by the plurality of different event initiators, the token sequence including a plurality of sub-token sequences each corresponding to a character sequence of event description information provided by an event initiator; setting a set of a first number of token positions for each sub-token sequence of the plurality of sub-token sequences, and sequentially placing characters in each sub-token sequence of the plurality of sub-token sequences at a corresponding set of the first number of token positions based on an order of each sub-token sequence; and determining, based on a corresponding sub-token sequence placed at each set of the first number of token positions, token information of an event initiator corresponding to each set of the first number of token positions, and a pre-trained text classification model, whether the target event is at risk.
An implementation of the present specification provides an event risk detection apparatus. The apparatus includes: a text information acquisition module, configured to obtain event description information provided by a plurality of different event initiators when the plurality of different event initiators each initiate a target event to a same event target party in a same event service; a conversion module, configured to convert, into a token sequence, a plurality of character sequences of the event description information provided by the plurality of different event initiators, the token sequence including a plurality of sub-token sequences each corresponding to a character sequence of event description information provided by an event initiator; a processing module, configured to set a set of a first number of token positions for each sub-token sequence of the plurality of sub-token sequences, and sequentially place characters in each sub-token sequence of the plurality of sub-token sequences at a corresponding set of the first number of token positions based on an order of each sub-token sequence; and a risk determining module, configured to determine, based on a corresponding sub-token sequence placed at each set of the first number of token positions, token information of an event initiator corresponding to each set of the first number of token positions, and a pre-trained text classification model, whether the target event is at risk.
An implementation of the present specification provides an event risk detection device. The event risk detection device includes a processor, and a memory configured to store computer-executable instructions. The executable instructions are execute to cause processor to perform the following operations: obtaining event description information provided by a plurality of different event initiators when the plurality of different event initiators each initiate a target event to a same event target party in a same event service; converting, into a token sequence, a plurality of character sequences of the event description information provided by the plurality of different event initiators, the token sequence including a plurality of sub-token sequences each corresponding to a character sequence of event description information provided by an event initiator; setting a set of a first number of token positions for each sub-token sequence of the plurality of sub-token sequences, and sequentially placing characters in each sub-token sequence of the plurality of sub-token sequences at a corresponding set of the first number of token positions based on an order of each sub-token sequence; and determining, based on a corresponding sub-token sequence placed at each set of the first number of token positions, token information of an event initiator corresponding to each set of the first number of token positions, and a pre-trained text classification model, whether the target event is at risk.
An implementation of the present specification further provides a storage medium. The storage medium is configured to store computer-executable instructions. The executable instructions are executed by a processor to implement the following process: obtaining event description information provided by a plurality of different event initiators when the plurality of different event initiators each initiate a target event to a same event target party in a same event service; converting, into a token sequence, a plurality of character sequences of the event description information provided by the plurality of different event initiators, the token sequence including a plurality of sub-token sequences each corresponding to a character sequence of event description information provided by an event initiator; setting a set of a first number of token positions for each sub-token sequence of the plurality of sub-token sequences, and sequentially placing characters in each sub-token sequence of the plurality of sub-token sequences at a corresponding set of the first number of token positions based on an order of each sub-token sequence; and determining, based on a corresponding sub-token sequence placed at each set of the first number of token positions, token information of an event initiator corresponding to each set of the first number of token positions, and a pre-trained text classification model, whether the target event is at risk.
Implementations of the present specification provide an event risk detection method, apparatus, and device.
To make a person skilled in the art better understand the technical solutions in the present specification, the following clearly and completely describes the technical solutions in the implementations of the present specification with reference to the accompanying drawings in the implementations of the present specification. Clearly, the described implementations are merely some not all of the implementations of the present specification. All other implementations obtained by a person of ordinary skill in the art based on the implementations of the present specification without making innovative efforts shall fall within the protection scope of the present specification.
As shown in, the implementation of the present specification provides an event risk detection method. The method can be performed by a terminal device or a server. The terminal device can be a terminal device such as a mobile phone or a tablet computer, or can be a computer device such as a notebook computer or a desktop computer, or can be an Internet of Things (IoT) device (for example, a smart watch or an in-vehicle device). The server can be an independent server, or can be a server cluster including a plurality of servers, or the like. The server can be a background server of a financial service, an online shopping service, or the like, or can be a background server of a certain application. In the implementation, the server is used as an example for detailed description. For an execution process of the terminal device, references can be made to the following related content. Details are omitted herein for simplicity. The method can for example include the following steps:
In step S, it is obtained event description information provided by a plurality of different event initiators to a same event target party in a same event service when the plurality of different event initiators initiate a target event. In some implementations, an event service refers to a service provided by a service provider, e.g., an internet-based online service provider, to facilitate the performance of an event initiated by the event initiators. For example, an on-line shopping platform may facilitate a logistic process of an event of transferring a product. Multiple event initiators, e.g., a seller of the product, one or more transportation carriers, a warehouse or other storage facilities, may initiate the logistic process as an event, all to a same buyer who is supposed to receive the product ultimately shipped to the buyer. An on-line platform may provide service for the logistic event initiated by the multiple event initiators and may determine whether the initiated logistic event is at risk by processing the event description information provided by the multiple event initiators.
The event service can be any service used to perform an event. For example, the event service can be online shopping, a physical transaction, a marketing event, a transfer service, a payment service, or the like. The event can be any event based on an actual situation. This is not limited in the implementation of the present specification. The event initiator can be a party that initiates a corresponding event when the above event service is executed. For example, if the event service is a transfer service, the event initiator can be a party that performs transfer. This can be set correspondingly based on different event services. The event target party can be a target party to which a corresponding event is directed when the above event service is executed. For example, if the event service is a transfer service, the event target party can be a transferee or a party that receives a resource or goods transferred by the event initiator. The event description information can be information describing a purpose or a content of a certain event. The purpose or content of the event can be determined based on an attribute of the event, for example, “dedicated to XX project”, or can be determined based on a function of the event, for example, “huan qian” or “mai dong xi” in Chinese, or can be determined based on other information, for example, “xue fei”, “ke cheng”, and “peng you ji shi” in Chinese. The specification is not limited by any specific purpose or content of an event.
In implementations, in human-computer interaction of a risk control scenario, a user may provide false information to obtain undue benefits. An account of an event target party in the risk control scenario is fixed, and a number of event initiators is large. Therefore, it is determined whether event description information of a plurality of event initiators for a specified event is contradictory to each other, so as to determine whether a certain event initiator in the plurality of event initiators provides false information, and further determine whether the event is a risk. Generally, a plurality of pieces of evidence can be obtained to determine whether certain information is true or false or whether a certain object is at risk. However, in the above scenario, all the event initiators provide the event description information for the same event, and different event initiators are different in many aspect, e.g., credibility of corresponding evidence provided by some initiator is higher than that provided by other event initiators. Implementations of the present specification provides an implementable natural language processing technical solution that can help quickly and accurately detect whether event description information provided by a plurality of transaction initiators for an event is contradictory to each other, so as to determine whether an event initiator in the plurality of event initiators provides false information, and further determine whether the event is at risk.
shows an example scenario of the implementation, e.g., a scenario of a transfer service. The event initiator is a resource transfer party, and the event target party is a resource transferee party, e.g., a payee of a money transfer event or a buyer of a goods transfer event. As shown in the left figure in, when event description information (“xue fei”, “xue fei”, and “ke cheng”) provided by three transfer parties for a current event is closely related to or consistent with each other, it can be considered that the transferee is relatively credible and the current transfer event is not at risk. As shown in the right figure in, when the event description information (“huan qian”, “mai dong xi”, “peng you ji shi”) provided by the three transfer parties for the current transfer event is quite different from each other, it indicates that a transfer party may provide false event description information. In this case, it can be considered that the transferee is possibly at risk and the current transfer event is at risk or risky.
For a common text classification model, e.g., using natural language processing, if the event description information provided by the plurality of different event initiators is directly spliced and then input to the above text classification model for text classification, the text classification model cannot well distinguish which event initiator the different text content contained in the information obtained through splicing belongs to, causing poor classification effect. For example, the text classification model is constructed based on a Bidirectional Encoder Representations from Transformers (BERT) model. For example, as shown in, the BERT model is a pre-training model, and input data of the BERT model includes two parts: One part is a token sequence, representing an input character (or word or letter or other ways of segmenting the text of an event description), and the other part is a token position, representing a position of the input character. In the description herein, a character is used as an example of a segment of the text of an event description, which does not limit the scope of the specification. When the text classification model with the above structure is applied to the above scenario, the above text classification model cannot well distinguish which event initiator (or which event initiator provides a certain character) each character belongs to. For example, for some token sequences, a character at the 20th token position belongs to event initiator A, and for some token sequences, a character at the 20th token position belongs to event initiator B. Although a separator [SEP] is set between token sequences corresponding to different event initiators, when a data volume is small, the above text classification model still cannot well determine, through learning, which event initiator different text content included in the token sequence belongs to. Based on this, the structure of the above text classification model can be improved, and details are described herein.
For a certain event service, when a certain user needs to initiate an event of the event service to another user, the user can initiate the event of the event service to the another user by using a corresponding application installed in a terminal device, e.g. the event initiator can initiate a target event to the event target party. In addition, not only one event initiator initiates the target event to the above event target party, and a plurality of different event initiator can further initiate the target event to the above event target party. In this case, for a same event service, a plurality of different event initiators can initiate a target event to a same event target party. When initiating the target event to the event target party, each event initiator can describe a purpose or content of initiating the target event. Therefore, when initiating the target event to the event target party, each event initiator can provide event description information for initiating the target event. When it is required to detect whether the event description information provided by the plurality of event initiators for the target event is contradictory to each other, so as to determine whether an event initiator in the plurality of event initiators provides false information, and further determine whether the target event is at risk, the event description information provided by the plurality of different event initiators can be obtained.
For example, in a scenario where an event service is a resource transfer service, when a plurality of different transfer parties initiate a transfer event to a same transferee, each transfer party can further provide event description information of the transfer event when each transfer party initiates the transfer event to the transferee. When it is required to detect whether the event description information provided by the plurality of transfer parties for the transfer event is contradictory to each other, so as to determine whether a transfer party in the plurality of transfer parties provides false information, and further determine whether the transfer event is at risk, the event description information provided by the plurality of different transfer parties can be obtained.
In step S, a plurality of character sequences of the event description information provided by the plurality of different event initiators are converted into a token sequence, the token sequence including a plurality of sub-token sequences each corresponding to a character sequence of event description information provided by an event initiator.
In implementations, the plurality of pieces of obtained event description information can be analyzed based on a requirement of input data of the text classification model. In the implementation, the plurality of character sequences of the event description information provided by the plurality of different event initiators can be converted into the token sequence based on the requirement of the input data of the text classification model. For example, a total of three different event initiators provide event description information: “wo gei wo peng you huan qian”, “mai yi fu”, and “jiu peng you you dian shi” in Chinese. In this case, “wo gei wo peng you huan qian”, “mai yi fu”, and “jiu peng you you dian shi” can be spliced, and an obtained character sequence can be “wo gei wo peng you huan qian, mai yi fu, jiu peng you you dian shi”. The above character sequence can be converted into a token sequence: [CLS] wo gei wo peng you huan qian [SEP] mai yi fu [SEP] jiu peng you you dian shi. The above token sequence includes a plurality of sub-token sequences each corresponding to a character sequence of event description information provided by an event initiator: [CLS] wo gei wo peng you huan qian, [SEP] mai yi fu, and [SEP] jiu peng you you dian shi.
In step S, a set of a first number of token positions are set for each sub-token sequence of the plurality of sub-token sequences, and characters in each sub-token sequence of the plurality of sub-token sequences are sequentially placed at a corresponding set of the first number of token positions based on an order of each sub-token sequence.
The first number can be set based on an actual situation automatically and/or dynamically. For example, the first number can be, for example, determined based on numbers of characters included in a plurality of sub-token sequences. For example, a sub-token sequence including a greatest number of characters can be obtained, and a number of characters included in the sub-token sequence can be used as the first number, or an average value of numbers of characters included in the plurality of sub-token sequences can be calculated, and the calculated average value can be used as the first number. In addition, the first number can be set based on expert or experimental experience, for example, the first number is set at 40 or 50. This can be, for example, set based on an actual situation dynamically. This is not limited in this specification.
In implementations, the token sequence can be obtained in the above manner, including a plurality of sub-token sequences. To well distinguish which event initiator (or which sub-token sequence) each character belongs to, a token position of a fixed length can be set for each sub-token sequence. As such, each sub-token sequence can be placed at a token position of a fixed length. For example, a set of a first number of token positions can be set for each sub-token sequence. Then, characters in each sub-token sequence are sequentially placed at a corresponding set of the first number of token positions based on an order of each sub-token sequence and an order of the set of the first number of token positions. Based on the same illustrative example, if the first number is 10, token positions 0 to 9 belong to the first sub-token sequence, token positions 10 to 19 belong to the second sub-token sequence, and token positions 20 to 29 belong to the third sub-token sequence. In this case, the first sub-token sequence “[CLS] wo gei wo peng you huan qian” can be placed at token positions 0 to 9, e.g. the token character “[CLS]” is placed at token position 0, the token character “wo” is placed at token position 1, the token character “gei” is placed at token position 2, the token character “wo” is placed at token position 3, the token character “peng” is placed at token position 4, the token character “you” is placed at token position 5, the token character “huan” is placed at token position 6, and the token character “qian” is placed at token position 7. In this case, all the token characters have been placed, but there are still two remaining token positions 8 and 9, and the two remaining token positions 8 and 9 can be left open without any character. Then, in the same manner as the above manner, the second sub-token sequence “[SEP] mai yi fu” can be placed at token positions 10 to 19, e.g. the token character “[SEP]” is placed at token position 10, the token character “mai” is placed at token position 11, . . . . Similarly, the third sub-token sequence “[SEP] jiu peng you you dian shi” can be placed at token positions 20 to 29, e.g., the token character “[SEP]” is placed at token position 20, the token character “jiu” is placed at token position 21, . . . , and so on.
For an example, as shown in, using the same illustrative example, if the first number is 6, token positions 0 to 5 belong to the first sub-token sequence, token positions 6 to 11 belong to the second sub-token sequence, and token positions 12 to 17 belong to the third sub-token sequence. In this case, the first sub-token sequence “[CLS] wo gei wo peng you huan qian” can be placed at token positions 0 to 5, e.g. the token character “[CLS]” is placed at token position 0, the token character “wo” is placed at token position 1, the token character “gei” is placed at token position 2, the token character “wo” is placed at token position 3, the token character “peng” is placed at token position 4, and the token character “you” is placed at token position 5. Because all the token positions are occupied, the last two token characters cannot be placed. In this case, it can be determined that placement of the first sub-token sequence at the token position has been completed. Then, in the same manner as the above manner, the second sub-token sequence “[SE9a iyi yi fu” can be placed at token positions 6 to 11, e.g., the token character “[SEP]” is placed at token position 6, the token character “mai” is placed at token position 7, . . . , and so on. Similarly, the third sub-token sequence “[SEP] jiu peng you you dian shi” can be placed at token positions 12 to 17, e.g., the token character “[SEP]” is placed at token position 12, the token character “jiu” is placed at token position 13, . . . , and so on. If a number of token characters exceeds a number of token positions, the sub-token sequence can be truncated based on the number of token positions, e.g., the process manner of the above first sub-token sequence is used. In the above manner, the event description information provided by each event initiator falls within a specified position range, e.g., a start position of a sub-token sequence corresponding to the event description information provided by each event initiator is fixed. As such, for the text classification model, the event description information of each event initiator has a fixed position interval, so that it can be easier to distinguish which event initiator each character belongs to.
In step S, it is determined, based on a corresponding sub-token sequence placed at each set of the first number of token positions, token information of an event initiator corresponding to each set of the first number of token positions, and a pre-trained text classification model, whether the target event is at risk.
The token information of the event initiator corresponding to each set of the first number of token positions can be an identifier of the event initiator, for example, A, B, C . . . or,,. . . . The token information of the event initiator can be set based on the token position. For example, as shown in, if token positions 0 to 5 belongs to event initiator A, the token information of the event initiator of token positions 0 to 5 can be all A. If token positions 6 to 11 belong to event initiator B, the token information of the event initiator of token positions 6 to 11 can be all B. This can be for example set based on an actual situation. The text classification model can be constructed based on a plurality of different algorithms. For example, the text classification model can be constructed based on a Robustly Optimized BERT Pretraining Approach (RoBERTa) model, or the text classification model can be constructed based on a BERT model, or the text classification model can be constructed based on a convolutional neural network for text (TextCNN) model. This can be for example set based on an actual situation. This is not limited in the implementation of the present specification.
In implementations, a corresponding training sample can be obtained based on a situation of the text classification model, and model training can be performed on the text classification model based on the obtained training sample, so that the text classification model has a capability of classifying text information, so as to obtain a trained text classification model. The corresponding sub-token sequence that is placed at each set of the first number of token positions and that is obtained through the above processing can be input into the above pre-trained text classification model together with the token information of the event initiator corresponding to each set of the first number of token positions. Through processing by the text classification model, related information about whether the event description information provided by the plurality of event initiators is contradictory to each other can be output. It can be determined, based on the above related information, whether an event initiator in the plurality of event initiators provides false information. If an event initiator in the plurality of event initiators provides false information, it can be determined that the event target party is at risk, and it can be determined that the target event is at risk. If no event initiator in the plurality of event initiators provides false information, it can be determined that the target event is not at risk. It should be noted that, as shown in, for the above-mentioned some token positions that are not filled with the token character, the token positions that are not filled with the token character can be removed before being input into the text classification model. In practice, the token positions that are not filled in with the token character may not need to be removed. This can be for example set based on an actual situation.
The implementation of the present specification provides an event risk detection method. Event description information provided by a plurality of different event initiators when the plurality of different event initiators each initiate a target event to a same event target party in a same event service is obtained. Then, a plurality of character sequences of the event description information provided by the plurality of different event initiators are converted into a token sequence, the token sequence including a plurality of sub-token sequences each corresponding to a character sequence of event description information provided by an event initiator. A set of a first number of token positions are set for each sub-token sequence of the plurality of sub-token sequences, and characters in each sub-token sequence of the plurality of sub-token sequences are sequentially placed at a corresponding set of the first number of token positions based on an order of each sub-token sequence. Finally, it is determined, based on a corresponding sub-token sequence placed at each set of the first number of token positions, token information of an event initiator corresponding to each set of the first number of token positions, and a text classification model, whether the target event is at risk. In this case, in the above manner, the event description information provided by each event initiator falls with a specified position range (a start position of a sub-token sequence corresponding to the event description information provided by each event initiator is fixed). As such, for the text classification model, the event description information of each event initiator has a fixed position interval, so that it can be easier to distinguish which event initiator each character belongs to, thereby quickly and accurately detecting whether event description information provided by a plurality of event initiators for a specified event is contradictory to each other, so as to determine whether an event initiator in the plurality of event initiators provides false information, and further determine whether the event is at risk.
As shown in, the implementation of the present specification provides an event risk detection method. The method can be performed by a terminal device or a server. The terminal device can be a terminal device such as a mobile phone or a tablet computer, or can be a computer device such as a notebook computer or a desktop computer, or can be an IoT device (is for example, for example, a smart watch or an in-vehicle device). The server can be an independent server, or can be a server cluster including a plurality of servers, or the like. The server can be a background server of a logistics service, a financial service, an online shopping service, or the like, or can be a background server of a certain application. In the implementation, the server is used as an example for detailed description. For an execution process of the terminal device, references can be made to the following related content. Details are omitted herein for simplicity. The method can for example include the following steps:
In step S, historical event description information of a historical event in a plurality of different event services is obtained, where the historical event description information is information provided by a plurality of different historical event initiators when the plurality of different historical event initiators each initiate the historical event to a same historical event target party in an event service of the plurality of different event services.
In step S, a plurality of character sequences of the historical event description information provided by the plurality of different historical event initiators is converted into a token sequence sample, where the token sequence sample includes a plurality of sub-token sequence samples each corresponding to a character sequence of historical event description information provided by a historical event initiator.
In step S, a set of a first number of token positions are set for each sub-token sequence sample of the plurality of sub-token sequence samples, and characters in each sub-token sequence sample of the plurality of sub-token sequence samples are sequentially placed at a corresponding set of the first number of token positions based on an order of each sub-token sequence sample.
For a specific processing procedure of step Sto step S, references can be made to related content in the above Implementation. Details are omitted herein for simplicity.
In step S, model training is performed on the text classification model based on a corresponding sub-token sequence sample placed at each set of the first number of token positions and token information of a historical event initiator corresponding to each set of the first number of token positions, to obtain a trained text classification model.
The text classification model can be constructed based on a RoBERTa model, a BERT model, a TextCNN model, or the like.
In implementations, for example, the text classification model is constructed based on the BERT model. The BERT model is an encoder based on Transformers, and a main model structure is a stack of Transformers. In the BERT model, a corresponding number of hidden vectors are obtained by using the Transformer encoder at each Transformer layer, and are transferred to a next Transformer layer. In this case, the vector is transferred downward layer by layer until a final output result is obtained. A model structure of the BERT model used to classify text information can be selected, and the BERT model can be constructed by using a corresponding algorithm. The above BERT model can be trained by using the corresponding sub-token sequence sample placed at each set of the first number of token positions and the token information of the historical event initiator corresponding to each set of the first number of token positions, to obtain a trained BERT model. Finally, the text classification model can be obtained.
In step S, event description information provided by a plurality of different event initiators when the plurality of different event initiators each initiate a target event to a same event target party in a same event service is obtained.
In step S, a plurality of character sequences of the event description information provided by the plurality of different event initiators are converted into a token sequence, the token sequence including a plurality of sub-token sequences each corresponding to a character sequence of event description information provided by an event initiator.
In step S, a set of a first number of token positions are set for each sub-token sequence of the plurality of sub-token sequences, and characters in each sub-token sequence of the plurality of sub-token sequences are sequentially placed at a corresponding set of the first number of token positions based on an order of each sub-token sequence.
For a specific processing procedure of step Sto step S, references can be made to related content in the above Implementation. Details are omitted herein for simplicity.
In practice, in the above Implementation, there can be various specific processing manners for determining, based on a corresponding sub-token sequence placed at each set of the first number of token positions, token information of an event initiator corresponding to each set of the first number of token positions, and a pre-trained text classification model, whether the target event is at risk. The following provides an optional processing manner that can for example include the following content: inputting, into the pre-trained text classification model, the corresponding sub-token sequence placed at each set of the first number of token positions and the token information of the event initiator corresponding to each set of the first number of token positions, to obtain a corresponding output result, and determining, based on the output result, whether the target event is at risk.
In addition, when the text classification model is constructed based on the BERT model, a specific processing manner of determining, based on a corresponding sub-token sequence placed at each set of the first number of token positions, token information of an event initiator corresponding to each set of the first number of token positions, and a pre-trained text classification model, whether the target event is at risk can be further implemented by using the following step Sand step S.
In step S, the corresponding sub-token sequence placed at each set of the first number of token positions and the token information of the event initiator corresponding to each set of the first number of token positions are input into the pre-trained text classification model, to obtain a corresponding output result.
In step S, an embedded feature corresponding to a first character in the event description information provided by each event initiator is extracted from the output result, the embedded feature is input into a predetermined encoder to obtain a corresponding encoding result, and it is determined, based on the encoding result, whether the target event is at risk.
The predetermined encoder can be implemented in a plurality of different manners. This can be for example set based on an actual situation. In the implementation, to reduce resources consumed for producing and selecting an encoder, the predetermined encoder can be directly constructed by using a Transformer Block.
In implementations, the system architecture can be shown in. At an upper layer of the text classification model (e.g. the BERT model), the embedded feature corresponding to the first character (for example, “wo”, “mai”, and “jiu” in) in the event description information provided by each event initiator can be extracted from the above output result, and then the extracted embedded feature corresponding to the first character in the event description information provided by each event initiator can be processed by using two layers of Transformer Blocks (encoders). Alternatively, an embedded feature corresponding to each character in the event description information provided by each event initiator can be extracted, and then an embedded feature corresponding to a maximum value or an average value in the embedded features corresponding to the characters in the event description information provided by each event initiator is processed by using two layers of Transformer Blocks. At the second layer of Transformer Block (encoder), each input data (e.g. a corresponding encoding result obtained by inputting the above embedded feature into the predetermined encoder) basically represents the event description information provided by each event initiator, and it is easier to perform distinguishment by the text classification model. Then, it can be determined, based on the encoding result, whether the event description information provided by the plurality of event initiators is contradictory to each other, so that it can be determined whether an event initiator in the plurality of event initiators provides false information. If an event initiator in the plurality of event initiators provides false information, it can be determined that the event target party is at risk, and it can be determined that the target event is at risk. If no event initiator in the plurality of event initiators provides false information, it can be determined that the target event is not at risk.
There can be various specific processing manner for determining, based on the encoding result, whether the target event is at risk. The following provides an optional processing manner that can for example include processing of the following step Aand step A.
In step A, similarities among a plurality of encoding results are determined based on a predetermined similarity algorithm.
Unknown
March 24, 2026
Browse 5M+ US patents with plain-English claim translations and AI-generated analysis.