A method and apparatus for predicting affective derivative behavior

By acquiring the subject-emotion-behavior triplet from text data and using Tucker decomposition and attention mechanisms for multiple learning iterations, the problem of unintegrated emotional factors in existing technologies is solved, enabling accurate prediction of emotion-derived behaviors and behavioral attribution analysis.

CN118520108BActive Publication Date: 2026-07-31SHANGHAI UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
SHANGHAI UNIV
Filing Date
2024-05-09
Publication Date
2026-07-31

AI Technical Summary

Technical Problem

Existing technologies have failed to effectively integrate emotional factors in behavioral analysis in virtual environments and real-world scenarios, resulting in inaccurate predictions of emotional behavior. Furthermore, small-sample analyses from the field of psychology are difficult to apply to complex open-domain application scenarios.

Method used

By acquiring the subject-emotion-behavior triple relationship in text data, initial learning is performed using Tucker decomposition. Hypothetical triples are then constructed and an attention mechanism is incorporated to dynamically adjust the attention to the subject and emotion. Two behavior predictions are then performed to finally determine the output probability of the knowledge representation model.

Benefits of technology

It achieves accurate prediction of emotion-derived behaviors, analyzes the driving paths of different emotions on behaviors through emotion-driven paths, and analyzes the causes of specific behaviors from the behavior attribution path, thereby improving the accuracy of behavior analysis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118520108B_ABST
    Figure CN118520108B_ABST
Patent Text Reader

Abstract

This invention discloses a method and apparatus for predicting emotion-derived behaviors, belonging to the field of emotion-derived behavior prediction technology. The method includes: performing a first learning based on triplet relation metadata using a Tucker decomposition-based behavior prediction method to obtain a first behavior probability; constructing a hypothetical subject-emotion-behavior triplet based on hypothetical behaviors, embedding it into an attention mechanism, dynamically adjusting the subject's and emotion's attention to the hypothetical subject-emotion-behavior triplet to obtain an optimized hypothetical triplet, and calculating a second behavior probability based on this; and determining the final output probability of the knowledge representation model based on the first and second behavior probabilities. This invention dynamically adjusts the subject's and emotion's attention to the hypothetical subject-emotion-behavior triplet through an attention mechanism, self-reflects on the degree of dependence on the hypothetical context, completes the mining of implicit emotion-behavior driving relationships, and achieves accurate prediction of emotion-derived behaviors.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of emotion-derived behavior prediction technology, and in particular to a method and apparatus for predicting emotion-derived behavior. Background Technology

[0002] Existing behavioral analysis methods in computer science and social sciences can be categorized based on application scenarios into user behavior analysis in virtual environments and public behavior analysis in real-world scenarios. User behavior analysis in virtual environments analyzes users' opinions and viewpoints on social events by mining their social behaviors such as forwarding and commenting in online virtual environments like social media. Public behavior analysis in real-world scenarios primarily focuses on group behavior analysis under public surveillance, using visual motion information such as motion histograms and optical flow histograms to identify crowding, confrontational group behaviors, and to provide timely warnings of dangerous behaviors.

[0003] Behavioral analysis in psychology focuses on the driving force of emotion on behavior, but it is limited to small-sample analyses under strict experimental conditions, making it difficult to apply its experimental conclusions to complex open-domain applications. Meanwhile, behavioral analysis in computer science neglects the emotional drive of behavior, raising questions about the logical validity of its behavioral reasoning processes.

[0004] While behavioral analysis research has improved the performance of behavioral analysis models in virtual and real environments by modifying model structure or integrating multimodal information for feature enhancement, few scholars have considered incorporating the emotional factors that drive behavior into the behavioral analysis process, and have not considered the process of reflection, resulting in inaccurate prediction and analysis results of emotional behavior. Summary of the Invention

[0005] The purpose of this invention is to provide a method and apparatus for predicting emotion-derived behaviors. By dynamically adjusting the subject's and emotions' attention to the hypothetical subject-emotion-behavior triad through attention mechanisms, reflecting on the degree of dependence on the hypothetical context, the implicit emotional behavior driving relationship is explored, and the accurate prediction of emotion-derived behaviors is achieved.

[0006] To achieve the above objectives, the present invention provides the following solution:

[0007] A method for predicting emotion-derived behaviors, the method comprising:

[0008] Retrieve metadata about subject-sentiment-behavior triplet relationships from a text dataset;

[0009] Based on the triplet relation metadata, a first learning process is performed using a behavior prediction method based on Tucker decomposition to obtain a first score; the first score is obtained by calculating the scores from subject-emotion to all behaviors;

[0010] The first score is normalized using the Logistic Sigmoid activation function to obtain the probability of the first action.

[0011] The behavior corresponding to the highest value in the behavior probability is taken as the hypothetical behavior, and a hypothetical subject-emotion-behavior triplet is constructed.

[0012] By integrating the embedded representation of the hypothetical subject-emotion-behavior triple into the attention mechanism, the attention of the subject and emotion to the hypothetical subject-emotion-behavior triple is dynamically adjusted, thereby optimizing the representation of the subject and emotion and obtaining the optimized hypothetical triple.

[0013] A second learning process is performed using a behavior prediction method based on Tucker decomposition to obtain a second score; the second score is obtained by calculating the scores from subject-emotion to all behaviors in the optimized hypothetical triplet;

[0014] The second score is normalized using the Logistic Sigmoid activation function to obtain the probability of the second behavior.

[0015] The final output probability of the knowledge representation model based on the hypothetical subject-emotion-behavior triple is determined according to the first behavior probability and the second behavior probability, using the following formula: Where p represents the final output probability, p1 represents the probability of the first row, and p2 represents the probability of the second row.

[0016] Optionally, the method further includes:

[0017] Behavioral derivation and emotional attribution analysis are performed based on the optimized hypothetical subject-emotion-behavior triple.

[0018] Optionally, the behavioral derivation and emotional attribution analysis based on the optimized hypothetical subject-emotion-behavior triple specifically includes:

[0019] Based on the knowledge representation model, implicit subject-emotion-behavior triples are mined by using a combination of subject and emotion traversal as candidate inputs.

[0020] By removing the subject dimension from the implicit subject-emotion-behavior triplet, we obtain the emotion-behavior binary set.

[0021] By mapping the emotional dimension in the binary set of emotional behavior to emotional category labels, and deduplication is performed on the emotional dimension, we obtain the binary set of emotional behavior after deduplication of the emotional dimension.

[0022] The behavior dimension in the deduplicated emotional behavior binary set is mapped to the behavior category label to remove duplicates in the behavior dimension, resulting in the emotional behavior binary set after deduplication in the behavior dimension.

[0023] Construct an emotional behavior derivation matrix and a behavioral emotion attribution matrix based on the binary set of emotional behaviors after deduplication of behavioral dimensions;

[0024] Normalize the emotion behavior derivation matrix and the behavior emotion attribution matrix to obtain the emotion behavior derivation probability matrix and the behavior emotion attribution probability matrix.

[0025] Emotional behavior derivation analysis is performed based on the emotion behavior derivation matrix and the emotion behavior derivation probability matrix to determine the probability of various behaviors generated in the current emotional state; behavioral emotion attribution analysis is performed based on the behavior emotion attribution matrix and the behavior emotion attribution probability matrix to determine the probability of the emotion that triggers the current behavior.

[0026] Optionally, the emotion category labels include: "love", "fear", "joy", "sorrow", "surprise", "anger" and "normal";

[0027] The behavioral category labels include: prosocial behavior, normal behavior, and antisocial behavior;

[0028] The specific labels for prosocial behavior include: altruism, win-win cooperation, and adherence to order;

[0029] The specific categories of labels for normal behavior include: pleasure, calmness, and panic;

[0030] The labels for antisocial behavior specifically include: harmful, aggressive, selfish, and disorderly.

[0031] Optionally, based on the triplet relation metadata, a first learning process is performed using a Tucker decomposition-based behavior prediction method to obtain a first score; the first score is obtained by calculating the scores from subject-emotion to all behaviors, specifically including:

[0032] The subject-emotion-behavior triple relationship is represented as a third-order binary tensor. ; where each element in the tensor For a given triplet relation, an element value of 1 indicates that the corresponding triplet actually exists, while an element value of 0 indicates that the corresponding triplet relation is incorrect or missing.

[0033] The score is calculated by integrating the subject's emotions into all behaviors, using the following formula: ;in, This represents the multiplication of the tensor at step n. Indicates the first Embedded representation of the subject Indicates the first Embedded representation of emotions, Indicates the first Embedded representation of a type of behavior.

[0034] Optionally, the embedded representation of the hypothetical subject-emotion-behavior triple is integrated into an attention mechanism to dynamically adjust the attention given to the hypothetical subject-emotion-behavior triple by the subject and emotion, thereby optimizing the subject and emotion representations and obtaining an optimized hypothetical triple, specifically including:

[0035] Based on the hypothetical subject-emotion-behavior triple, query the emotion embedding matrix respectively. Emotion Embedding Matrix With behavior embedding matrix Obtain the subject embedding Emotional embedding Embedded with hypothetical behavior The hypothetical context embedding matrix is ​​obtained. ; ;

[0036] Embed the hypothetical context into the matrix Viewed as the key and value matrices in the attention mechanism, the subject is embedded. The attention score is calculated in the hypothetical context using the query matrix, and the subject embedding representation in the hypothetical context is also calculated. ;

[0037] ;

[0038] Embedding emotions Treating it as a query matrix, calculate the sentiment embedding representation in the hypothetical context. ;

[0039] Computation of subject embeddings based on hypothetical context enhancement With emotional embedding ;

[0040] ; ;

[0041] The optimized hypothetical triplet is obtained.

[0042] Optionally, the formula for calculating the probability of behavior is:

[0043] ;

[0044] in, This represents the Sigmoid activation function. The k-th action word in the candidate set of action words. and Expressing the subject and emotion;

[0045] The loss function of the knowledge representation model is:

[0046] ;

[0047] in Indicates the number of actions. Let y represent the predicted probability and y represent the true label. , .

[0048] Optionally, obtain metadata about the subject-sentiment-behavior triplet relationships in the text dataset, specifically including:

[0049] The Jieba word segmentation tool was used to obtain the words and parts of speech in the text dataset, thus obtaining the corpus data.

[0050] Extract two behavioral pattern data, "emotion-behavior" and "subject-behavior," from the corpus data;

[0051] Based on the data from the two behavioral patterns, obtain the corresponding subject-emotion-behavior triple relationship metadata.

[0052] Optionally, two behavioral pattern data, "emotion-behavior" and "subject-behavior," are extracted from the corpus data, specifically including:

[0053] For "subject-behavior" behavior pattern extraction, a word order threshold is set to select the corpus data set. Center front A nominal morpheme, and based on word order relations according to the formula

[0054]

[0055] Mining data on "subject-behavior" behavioral patterns;

[0056] For “emotion-behavior” behavior pattern extraction, a word order window is defined to restrict the candidate emotion mining space to the semantic units adjacent to the behavior. The candidate ER behavior pattern extraction formula is as follows:

[0057]

[0058] After obtaining the subject-sentiment-behavior triple relation metadata from the text dataset, the following is also included:

[0059] The metadata of the triple relation is generalized using two methods: a thesaurus and semantic similarity.

[0060] A computer device includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that the processor executes the steps of the method for predicting emotion-derived behaviors described above.

[0061] According to specific embodiments provided by the present invention, the present invention discloses the following technical effects:

[0062] This invention obtains a first behavior probability by performing initial learning using a Tucker decomposition-based behavior prediction method based on triplet relation metadata. Then, it constructs a hypothetical subject-emotion-behavior triplet based on hypothetical behavior and embeds it into an attention mechanism. This dynamically adjusts the attention given to the hypothetical subject-emotion-behavior triplet by the subject and emotion to obtain an optimized hypothetical triplet, from which a second behavior probability is calculated. The final output probability of the knowledge representation model is determined based on the first and second behavior probabilities. This invention dynamically adjusts the attention given to the hypothetical subject-emotion-behavior triplet by the subject and emotion through an attention mechanism, reflecting on the degree of dependence on the hypothetical context, thereby mining implicit emotional behavior-driven relationships and achieving accurate prediction of emotion-derived behaviors. Attached Figure Description

[0063] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0064] Figure 1 This is a schematic flowchart of a method for predicting emotion-derived behaviors provided in Embodiment 1 of the present invention.

[0065] Figure 2 This is a schematic diagram of a method for predicting emotion-derived behaviors provided in Embodiment 5 of the present invention. Detailed Implementation

[0066] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0067] The purpose of this invention is to provide a method and apparatus for predicting emotion-derived behaviors. By dynamically adjusting the subject's and emotions' attention to the hypothetical subject-emotion-behavior triad through attention mechanisms, reflecting on the degree of dependence on the hypothetical context, the implicit emotional behavior driving relationship is explored, and the accurate prediction of emotion-derived behaviors is achieved.

[0068] This invention belongs to the field of text-based knowledge mining, and specifically proposes a study of emotion-driven behavior-derived knowledge. It integrates emotional factors into the social behavior analysis process to uncover the driving paths of different emotions on behavior. By extracting the subject-emotion-behavior triple relationship from a corpus related to social events, it reveals the public's emotions towards social events and the social behaviors driven by these emotions. A knowledge representation model based on hypothetical context representation enhancement is proposed to mine implicit subject-emotion-behavior derivative relationships. Finally, it mines the driving paths of different emotions on behavior and conducts specific behavioral attribution analysis from two perspectives: emotion-derived paths and behavioral attribution paths. Its main contributions are as follows:

[0069] 1) Subject-emotion-reaction metadata is mined through rules and manual review. This metadata is then expanded using a thesaurus and similarity calculations to construct an Aspect-Emotion-Reaction dataset. Simultaneously, the categories of prosocial and antisocial behavior are redefined based on existing research in behavioral analysis.

[0070] 2) A knowledge representation model based on hypothetical context feature enhancement is proposed. Based on the initial behavior prediction result and the subject and emotion input, a hypothetical subject-emotion-behavior context is constructed. The attention mechanism based on hypothetical context is used to strengthen the triple knowledge representation and calculate the final behavior prediction result. Implicit subject-emotion-behavior triple knowledge is mined based on the trained knowledge representation model.

[0071] 3) To analyze the behavioral driving paths of emotions and the emotional attribution paths of behaviors. From the perspective of emotion derivation, to analyze the driving strength of different prototype emotions on prosocial and antisocial behaviors. From the perspective of behavioral attribution, to explore the emotional reasons for specific behavioral categories, achieving a two-way influence analysis of emotions and behaviors on social events.

[0072] This invention addresses the lack of data in behavioral analysis within psychology and the lack of support in behavioral analysis within computational science. It proposes a study of behavior-derived knowledge based on emotion-driven behavior. This invention integrates emotional factors into the behavioral analysis process, enabling a complete behavioral chain study where individuals first experience personalized emotions triggered by environmental stimuli, and then these emotions drive behavior. Ultimately, it achieves behavioral analysis of social events from two perspectives: the derivation of emotion from behavior and the emotional attribution of behavior. Emotional behavioral knowledge is acquired through rules and manual review. A knowledge representation model based on hypothetical context features is proposed, aiming to learn from existing emotional behavioral data representations and uncover implicit emotional behavioral driving relationships. Finally, it analyzes the driving path of emotion on behavior and the attribution path of specific behaviors from a two-way perspective of emotion and behavior.

[0073] Abbreviations and key terms are defined as follows:

[0074] AER: Aspect-Emotion-Reaction.

[0075] MRR: Mean Reciprocal Ranking.

[0076] HCFE: Knowledge representation model based on hypothetical contextual feature enhancement.

[0077] This invention mainly learns from two processes based on Tucker decomposition: the first is learning from existing data, and the second is learning from hypothetical data.

[0078] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.

[0079] Example 1

[0080] like Figure 1 As shown, this embodiment provides a method for predicting emotion-derived behaviors, the method comprising:

[0081] S1. Obtain the metadata of the subject-sentiment-behavior triplet relationships in the text dataset. The text dataset can be derived from news text data.

[0082] Input text dataset:

[0083] The input to this embodiment is a text dataset (News Text Dataset, NTD), which mainly consists of descriptions related to social events. The text describing social events often contains a complete event timeline, that is, a certain subject performs a certain behavior under the drive of a certain emotion.

[0084] Use the Jieba word segmentation tool to obtain the given text. words in With part of speech ,in, and Refers to the first in the text Each word and its part of speech, The length of the text. Noun morphemes are grouped into the candidate subject set according to word order based on part-of-speech restrictions. ,in, Let i be the i-th noun in the text, and let i be the i-th subject word in the set; construct a candidate sentiment set based on adjectives and adverbs. ,in, Let j be the j-th modifier in the text, and also the j-th sentiment word in the set; consider verbal morphemes as the candidate behavior set. ,in, Let be the k-th verb in the text, and also the k-th action word in the set.

[0085] The study derivation of behavioral knowledge from the input text outputs entities in the text, their explicit behaviors, and their implicit behaviors.

[0086] Extraction of "emotion-behavior" and "subject-behavior" patterns:

[0087] Based on the SOR (Side-Oriented Reaction) behavioral theory and related psychological research, emotions are a direct and strong motivation for behavior, and an individual's cognition of external stimuli also significantly influences behavior. Public behavior triggered by certain specific stimuli is relatively stable; for example, during an earthquake, the public will flee dangerous areas. Similarly, certain specific emotions also drive behavior relatively steadily; for example, being moved will lead to crying. Therefore, this embodiment proposes two behavior mining models: specific subject and specific behavior, and specific emotion and specific behavior. By setting rules for word order and parts of speech, it extracts emotion-reaction (ER) and aspect-reaction (AR) behavior patterns from the corpus.

[0088] The main events in the text often appear as nouns, while emotional elements are mainly descriptive words, including adjectives and adverbs, and action words are mainly verbs. In the text dataset, the grammar describing social events is relatively standardized and stable. The main events, which are mainly nouns, often appear at the beginning of the text, while the word order of emotions and actions is more disordered, but they often appear in close semantic units.

[0089] For Aspect-Reaction (AR) behavior pattern extraction, since subject events often appear at the beginning of the text in word order, this embodiment selects candidate subjects (candidate subjects are obtained based on part-of-speech tags, adding nouns from the text to the candidate subject set) by setting a word order threshold. Center front Based on the word order relationship, candidate AR behavior patterns are mined using Formula 1. :

[0090] (1)

[0091] in, Calculate the word order of candidate morphemes in text S.

[0092] For Emotion-Reaction (ER) behavior pattern extraction, since the word order of emotion and behavior words in the original sentence is not stable, this embodiment defines a word order window to limit the candidate emotion mining space to the semantic units adjacent to the behavior. The candidate ER behavior pattern extraction method is shown in Formula 2:

[0093] (2)

[0094] in, Indicates the size of the word order window.

[0095] By manually reviewing and revising the candidate sets of the two behavioral patterns to filter out noise and erroneous data, the AR and ER behavioral patterns obtained in this embodiment will be supplemented and expanded with triples in subsequent work to obtain complete AER triple knowledge.

[0096] Step 3: Complete the "emotion-behavior" and "subject-behavior" models.

[0097] The aforementioned work has yielded stable emotion-behavior and subject-behavior patterns. For emotion-reaction (ER) patterns, even under complex and diverse subject events, the derivation patterns of specific emotions and behaviors are relatively stable. For example, the behavior pattern of "sadness" driving "crying" can hold even without considering the subject (aspect). This embodiment completes the emotion-reaction (ER) pattern by mining and filling in the subject elements preceding emotion and behavior words in the text, and completes the subject-reaction (AR) pattern by mining and filling in the emotion words between the subject and behavior word order. Finally, through manual evaluation, factually accurate and reasonable subject-emotion-behavior (AER) triple relation metadata is obtained.

[0098] S2. Based on the triplet relation metadata, calculate the subject-emotion to all behaviors score using the Tucker decomposition-based behavior prediction method to obtain the first score.

[0099] S3. Normalize the first score using the Logistic Sigmoid activation function to obtain the probability of the first line.

[0100] S4. Take the behavior corresponding to the highest value in the behavior probability as the hypothetical behavior and construct a hypothetical subject-emotion-behavior triplet.

[0101] Generalization of the "subject-emotion-behavior" triple:

[0102] The generalization of the subject-emotion-behavior triple is mainly carried out through two methods: thesaurus and semantic similarity. For the AER triple metadata based on AR behavior pattern completion, the emotion elements in the AER triple are generalized and extended by using emotion synonyms and semantic near-synonyms.

[0103] The semantic similarity-based AER generalization method is similar to the thesaurus generalization process, transforming the process of selecting synonyms based on a thesaurus into selecting near-synonyms based on semantic similarity. By training a word2vec model on the NTD dataset, text words are converted into 200-dimensional feature embeddings. Cosine similarity is used to measure the semantic similarity between words, and similar semantic words are used to generalize and extend AER metadata. Given AER triples completed based on ER behavior patterns... , with the main body To achieve the generalization goal, a word set is obtained through the word2vec model. Embedded representation The generalized subject words are obtained through Formula 3. :

[0104] (3)

[0105] in, This represents selecting the k words with the highest cosine similarity in word embedding, based on the generalized subject word. Expand AER metadata to The same approach was used to generalize sentiment words to AER triples based on AR behavioral patterns, and high-quality AER triple relationships were finally selected through manual evaluation.

[0106] Predict hypothetical behaviors and construct hypothetical "subject-emotion-behavior" triplets:

[0107] This embodiment utilizes the Tucker decomposition method proposed by Ledyard R. Tucker in 1964, based on a given subject... With emotions Initial hypothetical behavior prediction is performed, and a hypothetical subject-emotion-behavior tripartite is constructed based on the hypothetical behavior. The subject-emotion-behavior third-order binary tensor is then used. Decomposed into core tensors With three types of distribution matrices, including the main embedding matrix Emotion Embedding Matrix and behavior embedding matrix ,in Where I, J, and K represent the number of subjects, emotions, and behaviors in the candidate set, respectively; , , , Third-order binary tensor It can be approximated as the core tensor The forms of multiplication with three parts matrices:

[0108] (4)

[0109] in, These represent the embedding dimensions of the subject, emotion, and behavior, respectively, and in this embodiment, all three dimensions are the same. This represents the multiplication of the tensor at step n. This is the vector inner product. Since there is an intersection between the subject and the behavior, the initialization... and Union matrices are often used when embedding matrices. express.

[0110] Given triples The hypothetical behavior prediction score function based on Tucker decomposition It can be calculated according to Formula 5:

[0111] (5)

[0112] in, Indicates the first Embedded representation of the subject Indicates the first Embedded representation of emotions, Indicates the first Embedded representation of a type of behavior.

[0113] During the training process, In the triplet As a masked state, the behavior prediction method based on Tucker decomposition will calculate The scores for all behaviors are then normalized using the Logistic Sigmoid activation function to obtain the behavior probabilities. :

[0114] (6)

[0115] in, This represents the Sigmoid activation function. This represents the k-th action word in the candidate action word set. The predicted probability is... The highest value represents the behavioral label. Defined as hypothetical behavior, based on a given subject's emotional binary. and hypothetical behavior Construct a hypothetical subject-emotion-behavior triad .

[0116] S5. Integrate the embedded representation of the hypothetical subject-emotion-behavior triple into the attention mechanism, dynamically adjust the attention of the subject and emotion to the hypothetical subject-emotion-behavior triple, optimize the subject and emotion representation, and obtain the optimized hypothetical triple.

[0117] Optimization of subject-emotion representation based on the hypothetical subject-emotion-behavior triplet:

[0118] This embodiment constructs a hypothetical AER triplet using the subject, emotional input, and hypothetical behavior obtained from the initial prediction. The embedding representation of this hypothetical triplet is then integrated with the attention mechanism to optimize the subject and emotional representation.

[0119] Based on the given subject-emotion binary The hypothetical AER triple is represented as Query the sentiment embedding matrix separately. Emotion Embedding Matrix With behavior embedding matrix Obtain the subject embedding Emotional embedding Embedded with hypothetical behavior Embed the hypothetical AER triples into the matrix. Defined as:

[0120] (7)

[0121] Embed the hypothetical AER triplet into the matrix Viewed as the key matrix in the attention mechanism, The transpose, i.e. Viewed as a value matrix, the subject is embedded. The attention score for the hypothetical AER triple is calculated as a query matrix, and the subject embedding representation under the hypothetical AER triple is further calculated. :

[0122] (8)

[0123] Embedding emotions Treating it as a query matrix allows for the calculation of the sentiment embedding representation under the hypothetical AER triples. To dynamically adjust the attention given to the hypothetical triple by the original subject and emotional representation, this embodiment introduces hyperparameters. and Embedding the subject based on hypothetical triplet optimization With emotional embedding Defined as:

[0124] (9)

[0125] (10)

[0126] The subject sentiment optimization features based on hypothetical AER triples are also solved using the Tucker decomposition algorithm, defining the core matrix. For a given triple Scoring function based on hypothetical AER triples Calculated using Formula 11:

[0127] (11)

[0128] S6. Calculate the scores of the subject-emotion to all behaviors in the optimized hypothetical triplet to obtain the second score.

[0129] S7. Normalize the second score using the Logistic Sigmoid activation function to obtain the probability of the second action.

[0130] S8. Determine the final output probability of the knowledge representation model based on the hypothetical subject-emotion-behavior triplet according to the first behavior probability and the second behavior probability, using the following formula: , where p represents the final output probability, p1 represents the probability of the first row, and p2 represents the probability of the second row.

[0131] Secondary behavioral prediction is performed based on the optimized subject and emotional representations:

[0132] In the secondary prediction of behavior, the computational subjects are traversed. With emotions The scores for all behavior categories are normalized using the Logistic Sigmoid activation function to obtain the first behavior probability p1 of the fused artifact triple:

[0133] (12)

[0134] Calculate the final decision output In this embodiment, the first behavior probability p1 in the initial prediction of hypothetical behavior and the second behavior probability p2 in the optimized subject and sentiment features after fusing hypothetical triples are considered simultaneously. This aims to help the model optimize the core matrix at the same time. and This improves the model's prediction accuracy for hypothetical behaviors, thereby enhancing the reliability of hypothetical AER triples. The knowledge representation model based on hypothetical AER triples ultimately outputs probabilities. Defined as:

[0135] (13)

[0136] The loss function used for model training is the Bernoulli negative log-likelihood loss function, based on the predicted probability. With real labels loss function The result is obtained through formula 14:

[0137] (14)

[0138] in, Indicates the number of actions. .

[0139] Optionally, the method further includes: performing behavioral derivation and emotional attribution analysis based on the optimized hypothetical subject-emotion-behavior triple.

[0140] Specifically, it includes:

[0141] Based on the knowledge representation model, implicit subject-emotion-behavior triples are mined by using a combination of subject and emotion traversal as candidate inputs.

[0142] By removing the subject dimension from the implicit subject-emotion-behavior triplet, we obtain the emotion-behavior binary set.

[0143] The emotional dimension in the emotional behavior binary set is mapped to an emotional category label to remove duplicates in the emotional dimension, resulting in the emotional behavior binary set after emotional dimension deduplication; by deduplication in the emotional dimension, different emotional dimensions can be mapped to a single emotional category label.

[0144] The behavior dimensions in the deduplicated emotional behavior binary set are mapped to behavior category labels to remove duplicates in the behavior dimension, resulting in a deduplicated emotional behavior binary set. By removing duplicates in the behavior dimension, different behavior dimensions can be mapped to a single behavior category label.

[0145] Based on the deduplicated binary set of emotional behaviors according to the behavioral dimension, construct the emotional behavior derivation matrix and the behavioral emotion attribution matrix.

[0146] Normalize the emotion behavior derivation matrix and the behavior emotion attribution matrix to obtain the emotion behavior derivation probability matrix and the behavior emotion attribution probability matrix.

[0147] Emotional behavior derivation analysis is performed based on the emotion behavior derivation matrix and the emotion behavior derivation probability matrix to determine the probability of various behaviors generated in the current emotional state; behavioral emotion attribution analysis is performed based on the behavior emotion attribution matrix and the behavior emotion attribution probability matrix to determine the probability of the emotion that triggers the current behavior.

[0148] This embodiment can train a knowledge representation model using a small sample size, and perform behavior derivation and sentiment attribution analysis based on the knowledge representation model, so that the behavior derivation and sentiment attribution analysis model can be applied to a wider range of samples.

[0149] Optionally, the emotion category labels include: "love", "fear", "joy", "sorrow", "surprise", "anger" and "normal";

[0150] The behavioral category labels include: prosocial behavior, normal behavior, and antisocial behavior.

[0151] The specific labels for prosocial behavior include: altruism, win-win cooperation, and adherence to order.

[0152] The specific labels for the normal behavior include: pleasure, calmness, and panic.

[0153] The labels for antisocial behavior specifically include: harmful, aggressive, selfish, and disorderly.

[0154] Behavioral derivation and affective attribution analysis:

[0155] Acquisition of the implicit "subject-emotion-behavior" triple:

[0156] The aforementioned model was used to mine implicit subject-emotion-behavior triples, using subject and emotion traversal combinations as candidate inputs. By setting thresholds and manual screening, high-confidence implicit subject-emotion-behavior structured knowledge was mined.

[0157] The model takes subject and emotion as input. First, construct the candidate input set for the knowledge representation model. :

[0158] (15)

[0159] in, and These represent all candidate subjects and all candidate emotion sets, respectively.

[0160] The model's output is the subject's sentiment. Binary relation to score function for all behavioral categories , , The candidate behavior set is determined by setting a threshold. Filter out low-confidence behavioral dimension scores and mine implicit AER triple relationships with high-confidence scores. :

[0161] (16)

[0162] in Representative triplet ( The score.

[0163] Finally, noisy data in the implicit subject-emotion-behavior triplet based on reasoning mining is filtered out through manual review to achieve the mining of implicit subject-emotion-behavior relationships.

[0164] Emotion-driven behavioral derivative knowledge reveals the patterns of emotions evoked by objective facts or subjects in social events, as well as the driving paths of emotion-driven behavior. This section, based on the already mined subject-emotion-behavior triad, analyzes the driving paths of multidimensional emotions on various behaviors, and the emotional attributions of various prosocial or antisocial behaviors, from two analytical perspectives: the behavioral derivatives of emotions and the emotional attributions of behaviors.

[0165] The subject dimension of the existing Aspect-Emotion-Reaction (AER) triplet is removed to analyze the driving and attribution paths of emotion and behavior. The emotion-behavior binary set is then modified. After the sentiment words in the text are mapped to sentiment tags, they are represented as follows:

[0166] (17)

[0167] in, This means that the emotional label number after mapping is 0, which is Love. The sentiment label number after mapping is m. The 7 sentiment labels and their corresponding numbers are: "Love->0", "Fear->1", "Joy->2", "Sad->3", "Surprise->4", "Anger->5", and "Normal->6".

[0168] For example, the emotion-behavior binary <anger, aggression> and <rage, aggression> are both represented as <anger, aggression> after emotion label replacement.

[0169] In emotional behavior data mining, this embodiment expands the AER triple knowledge by generalizing sentiment words. For example, <rage, aggression> is generalized from <anger, aggression>. Therefore, in this embodiment, it is necessary to remove the generalized sentiment-behavioral relationships to avoid affecting the driving strength of sentiment on behavior and the sentiment attribution strength of behavior. This is achieved by mapping sentiment words to sentiment labels. The set is deduplicated, retaining only the single mapping relationship between emotion and behavior granularity. For example, <rage, aggression> is obtained by generalizing from <anger, aggression>, and after the above operation, only the emotion-behavior binary relationship of <anger, aggression> is retained.

[0170] After deduplication A binary set maps behavioral dimensions to behavioral category labels and represents them as follows: At this point, the elements in this binary set represent the driving paths of coarse-grained emotions and multi-dimensional behaviors. A behavioral derivation matrix of emotions is constructed. The seven dimensions correspond to seven emotional labels: "love," "fear," "joy," "sorrow," "surprise," "anger," and "normal." The ten dimensions correspond to three prosocial behaviors, three neutral behaviors, and four antisocial behaviors.

[0171] according to Emotional behavior derived matrix Assignment:

[0172]

[0173]

[0174] The assigned emotional behavior derivation matrix Each element in the matrix represents the number of 10 behaviors driven by the emotional dimension in that row, thus generating an emotional behavior matrix. The transposed matrix yields the behavioral-affective attribution matrix. , Each element in the matrix represents one of the seven affective attribution paths for the behavior represented in that row.

[0175] Emotional behavior derivative matrix Behavioral attribution matrix After row normalization, the behavior-derived probability matrix of emotions is obtained. Emotional attribution probability matrix of behavior .

[0176] (20)

[0177] Emotional Behavior Derivation Probability Matrix Each row of elements represents the probability of that emotion driving 10 behaviors, forming the emotion attribution probability matrix for each behavior. Each row of elements represents the attribution probability that the behavior is driven by one of the seven emotions.

[0178] This invention dynamically adjusts the attention level of the subject and emotion towards the hypothetical subject-emotion-behavior triad through an attention mechanism, reflects on the degree of dependence on the hypothetical context, and completes the mining of implicit emotional-behavioral driving relationships to achieve accurate prediction of emotion-derived behaviors. This invention integrates emotional factors into the behavior analysis process, first realizing the personalized emotions generated by individuals in response to environmental stimuli, then predicting and analyzing the complete behavioral chain driven by emotions, and finally achieving behavior prediction for social events from the perspectives of emotional-behavioral derivation and emotional attribution of behavior. It acquires emotional behavior knowledge through rules and manual review, and proposes a knowledge representation model based on hypothetical context feature enhancement. This model aims to learn from existing emotional behavior data representations and mine implicit emotional-behavioral driving relationships, predicting the driving force of emotions on behavior from a two-way perspective of emotional behavior.

[0179] Example 2

[0180] This embodiment provides a computer 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 for predicting emotion-derived behaviors as described in Embodiment 1.

[0181] Example 3

[0182] Please see Figure 2 This embodiment provides a method for predicting emotion-derived behaviors, with the following specific steps:

[0183] Step 1: Mining behaviorally derived knowledge:

[0184] This embodiment categorizes fine-grained emotional behaviors within the Aspect-Emotion-Reaction (AER) triple relationship to facilitate subsequent analysis of emotional behavior derivation paths. Fine-grained emotions are categorized as coarse-grained love, joy, anger, sorrow, fear, surprise, and neutrality. This embodiment integrates existing behavior classification methods, dividing social behavior into two levels and labeling fine-grained behaviors as primary and secondary behavior types. Specifically, it distinguishes between Spite and Aggressive behaviors in antisocial behavior: Spite emphasizes the resulting harm to others, while Aggressive emphasizes the intention to attack others. The specific behavior classification method is shown in Table 1.

[0185] Table 1. Behavioral Multilevel Classification Table

[0186]

[0187] Table 2 Fine-grained sentiment distribution table

[0188]

[0189] The fine-grained sentiment distribution is shown in Table 2. Although the same prototype sentiment includes multiple sentiment words, the sentiment intensity represented by different sentiment words is different. Normalizing them to a specific coarse-grained prototype sentiment will lead to the loss of sentiment intensity information. For example, "sadness" and "grief" both belong to the "sorrow" category of sentiment, but their sentiment intensities are different, and their derivative behavioral paths also differ. Therefore, in the knowledge representation model experiment based on hypothetical context feature enhancement, the triplet relationship used in this embodiment still retains fine-grained sentiment and fine-grained behavior, and prototype sentiment labels and behavior categories are applied in the process of sentiment-oriented behavior derivation and sentiment attribution analysis of behavior.

[0190] Step 2: Performance of the knowledge representation model based on hypothetical contextual features:

[0191] Step 2.1, Dataset Display:

[0192] In this embodiment, the subject-emotion-behavior triples in the AER dataset are divided into 18,000 training data entries and 1,306 test data entries to verify the performance of the knowledge representation model based on hypothetical context feature enhancement, as shown in Table 3. In addition to the AER dataset constructed in this embodiment, the publicly available dataset KINSHIP was also used to evaluate the performance of the proposed knowledge representation model based on hypothetical context feature enhancement. The triple knowledge representations in the KINSHIP dataset represent kinship relationships between entities and objects, including 104 types of entities and 26 types of kinship relationships, containing 8,544 training data entries and 1,074 test data entries.

[0193] Table 3. Division of AER dataset and KINSHIP dataset

[0194]

[0195] This embodiment uses the MRR, Hits@1, Hits@3 and Hits@10 metrics commonly used in knowledge representation model prediction tasks to evaluate the effectiveness of the model.

[0196] MRR: short for Mean Reciprocal Ranking, which is calculated by formula (21):

[0197] (twenty one)

[0198] in, Refers to the set of triples. Refers to the first The MRR (Mean Reversal Rate) is the predicted ranking of links within a set of triples. A higher MRR value indicates that the predicted ranking is closer to the actual ranking.

[0199] Hits@n: This metric refers to links whose predicted ranking is less than or equal to... The average percentage of triplets. Hits@n is calculated using formula (22):

[0200] (twenty two)

[0201] Wherein, when the condition is true The function value is 1 if it is not 1, otherwise it is 0.

[0202] Step 2.2, Model performance on the AER dataset and the KINSHIP public dataset:

[0203] The experimental results of the knowledge representation model based on hypothetical context feature enhancement and the baseline model on the AER dataset are shown in Table 4.

[0204] Table 4. Performance of knowledge representation models on the AER dataset

[0205]

[0206] In the AER dataset, this embodiment proposes a knowledge representation model based on hypothetical contextual feature enhancement (HCFE). The HCFE model reflects on and judges the hypothetical labels obtained in the initial prediction. In the final prediction, it considers both the decision opinion of the initial prediction and the decision opinion of the fused contextual information. The aim is to improve the decision quality of the model's initial prediction, thereby generating hypothetical contextual relationships that are closer to the facts. Ultimately, the model improves the quality of the final decision through self-reflection.

[0207] The experimental results of the knowledge representation model based on hypothetical context feature enhancement on the KINSHIP dataset are shown in Table 5 in terms of MRR, H@3, and H@1 metrics.

[0208] Table 5. Performance of knowledge representation models on the KINSHIP dataset

[0209]

[0210] The difference between the AER dataset constructed in this embodiment and the publicly available KINSHIP dataset lies in the complexity of the fine-grained sentiment categories considered as relationships. The AER dataset contains more complex relationships, while KINSHIP only has 25 kinship relationships and 104 person entities. There are 10,686 triples between the 104 person entities and the 25 kinship relationships, indicating that the same person entity and the same kinship relationship will correspond to more person objects. The HCFE model proposed in this embodiment only makes assumptions about a single optimal path when constructing the hypothetical context. This leads to the inability of the person entity and kinship relationship representation enhanced by a single optimal path to handle triple relationships where the same person entity and the same kinship relationship correspond to multiple person objects. Therefore, this embodiment introduces two weight hyperparameters to help the model dynamically integrate hypothetical context features, allowing the model to reflect on its dependence on the hypothetical context during training. In the AER dataset, it is relatively rare for the same subject to trigger multiple behaviors under the same fine-grained sentiment. Therefore, the hypothetical context environment constructed based on a single optimal path can more comprehensively approximate the facts derived from sentiment behaviors. In this context, the HCFE model proposed in this embodiment relies more heavily on hypothetical contexts that closely resemble reality. This results in higher quality representation enhancement for subject embedding and sentiment embedding under the adjustment of the two weight parameters, leading to higher accuracy in behavior prediction. In summary, the HCFE model proposed in this embodiment achieves superior performance improvement when the number of derived objects under the same subject and relationship is small. Even in datasets with a large number of derived objects under the same subject and relationship, the model can still achieve good performance by dynamically adjusting the weights of the hypothetical context.

[0211] Step 3: Emotional Derivation from Behavior and Emotional Attribution Analysis of Behavior:

[0212] Emotion-driven behavioral derivative knowledge contains complete event chain knowledge of how emotions in social events drive behavior. Starting from emotions, we can observe the driving path and intensity of multidimensional emotions on multidimensional behaviors, while reverse analysis from behavioral derivative triple knowledge can uncover the emotional attribution path of multidimensional behaviors. For social managers, emotion-driven behavioral paths help them prevent or intervene in potential antisocial behaviors after the outbreak of social events based on the emotions involved, and conduct forward emotional inference after the outbreak of egregious behaviors, which is of great significance to social stability and security.

[0213] A knowledge representation model based on hypothetical context features is used to mine hidden links in existing AER triple knowledge, obtaining complete subject, emotion, and behavior-derived knowledge for social events. During the inference process, 4,365 AER triples were obtained after manual filtering, resulting in 23,671 AER triple knowledge entries after merging with the original AER triples. This serves as the raw data for emotion-driven behavior analysis and behavior attribution analysis. After filtering and deduplicating the subjects in these 23,671 triple knowledge entries, 3,692 emotion-behavior-driven knowledge entries were obtained. During the construction of the triple dataset, to obtain more comprehensive and applicable emotion-behavior-driven knowledge for various research scenarios, the emotion elements in the triples were generalized using a thesaurus and approximate embedding relationships. Ignoring this generalized data would lead to errors in driving strength due to duplicate data in emotion-behavior-driven analysis and attribution analysis. Therefore, after converting emotion words into emotion tags, the 3,692 emotion-behavior-driven knowledge entries were deduplicated, resulting in 911 emotion-behavior-driven knowledge entries that correspond to the actual derivation strength.

[0214] The behavioral derivative analysis oriented towards emotions aims to explore the driving strength of different emotions for various behaviors, as shown in Table 6. Behaviors driven by the emotion of "love" totaled 78, all consisting of prosocial and normal behaviors. Furthermore, "love" emotions showed a low probability of triggering antisocial behaviors. The emotion driving the most behaviors was "fear," with 194 fine-grained behaviors driven by "fear." The highest proportion of these were Panic-type behaviors within normal behaviors and Congestion-type behaviors within antisocial behaviors. For the behavioral driving paths of the emotion of "sorrow," the behaviors driven by "sorrow" were primarily Panic-type behaviors, with a 17.17% probability of triggering Altruism within prosocial behaviors. Behavioral paths triggered by the emotion of "anger" mostly resulted in antisocial behaviors, with a small number of Disciplined behaviors within prosocial behaviors. Therefore, when social events are characterized by "anger" and "fear," social managers need to intervene promptly to prevent the occurrence of antisocial behaviors.

[0215] Table 6. Emotion-Oriented Behavioral Derivation Table

[0216]

[0217] The affective attribution analysis of behavior aimed to uncover the multidimensional affective causes of different behaviors, as shown in Table 7. In this analysis, prosocial behavior occurred a total of 271 times, including 115 instances of altruism, 46 instances of mutual benefit, and 110 instances of disciplined behavior. Altruism was primarily driven by "love" and "normal" emotions, with 27 instances each driven by either. However, altruism driven by "anger" occurred only 5 times, accounting for 4.35%. These results indicate that altruism is more likely to be derived from "love" and "normal" emotions, and only very rarely from "anger." The affective attribution of mutual benefit behavior showed the same regularity as that of altruism, namely, it was primarily driven by "love" emotions.

[0218] Table 7 Behavior-Oriented Emotional Attribution Table

[0219]

[0220] Regarding the "spite" aspect of antisocial behavior, this embodiment recorded 117 instances of spite behavior, of which 45 were triggered by anger, accounting for 38.46%. Fear and shock were also significant causes of spite behavior, accounting for 18.18% and 22.73% respectively. The patterns observed in aggressive, selfish, and congestion behaviors in antisocial behavior are consistent with those in spite behavior, primarily caused by anger, fear, and shock. Therefore, the primary emotional factors attributable to antisocial behavior are anger, fear, and shock.

[0221] Technical Impact: Behavioral analysis of social events is of great significance for guiding prosocial behavior and intervening in harmful behaviors. Psychologists have demonstrated that emotion is a direct and powerful driving force of behavior. However, psychological research on behavioral analysis is limited to small-sample experiments under strict conditions. Computer science research on group behavior analysis includes target behavior analysis in specific scenarios and target behavior analysis in generalized scenarios, neglecting the emotional drive of behavior, resulting in weak logical rationality and scenario generalization in behavioral analysis. This chapter proposes research on emotion-driven behavior-derived knowledge, integrating emotional factors into the social behavior analysis process to explore the driving paths of different emotions on behavior. It mines the subject-emotion-behavior triad relationship from a social event corpus and utilizes a knowledge representation model based on hypothetical context representation enhancement to uncover implicit subject-emotion-behavior derivative relationships.

[0222] This invention explores the driving paths of different emotions on behavior and conducts emotional attribution analysis of specific behaviors from two perspectives: the behavioral derivation path of emotions and the emotional attribution path of behaviors. Experimental results demonstrate that the knowledge representation model based on hypothetical context representation enhancement proposed in this invention can integrate the driving knowledge of emotions and behaviors, thereby improving the performance of intelligent knowledge representation algorithms. Furthermore, the behavioral derivation path analysis of emotions reveals that "anger" and "fear" emotions have a strong arousal intensity for social behaviors, while "love" emotions have a high arousal intensity for prosocial behaviors. The emotional attribution analysis of behaviors shows that antisocial behaviors are mainly generated by "fear" and "anger" emotional stimuli.

[0223] It should be noted that the object information (including but not limited to object device information, object personal information, etc.) and data (including but not limited to data used for analysis, data stored, data displayed, etc.) involved in this invention are all information and data authorized by the object or fully authorized by all parties, and the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions.

[0224] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0225] This document uses specific examples to illustrate the principles and implementation methods of the present invention. The descriptions of the above embodiments are only for the purpose of helping to understand the method and core ideas of the present invention. Furthermore, those skilled in the art will recognize that, based on the ideas of the present invention, there will be changes in the specific implementation methods and application scope. Therefore, the content of this specification should not be construed as a limitation of the present invention.

Claims

1. A method of predicting affectively derived behavior, characterized by, The method includes: Retrieve metadata about subject-sentiment-behavior triplet relationships from a text dataset; Based on the triplet relation metadata, a first learning process is performed using a behavior prediction method based on Tucker decomposition to obtain a first score; the first score is obtained by calculating the scores from subject-emotion to all behaviors; The first score is normalized using the Logistic Sigmoid activation function to obtain the probability of the first action. The behavior corresponding to the highest value in the behavior probability is taken as the hypothetical behavior, and a hypothetical subject-emotion-behavior triplet is constructed. By integrating the embedded representation of the hypothetical subject-emotion-behavior triple into the attention mechanism, the attention of the subject and emotion to the hypothetical subject-emotion-behavior triple is dynamically adjusted, thereby optimizing the representation of the subject and emotion and obtaining the optimized hypothetical triple. A second learning process is performed using a behavior prediction method based on Tucker decomposition to obtain a second score; the second score is obtained by calculating the scores from subject-emotion to all behaviors in the optimized hypothetical triplet; The second score is normalized using the Logistic Sigmoid activation function to obtain the probability of the second behavior. A final output probability of the knowledge representation model based on the hypothetical subject-emotion-behavior triplets is determined according to the first behavior probability and the second behavior probability, and the formula is: ; wherein p represents the final output probability, p1 represents the first behavior probability, and p2 represents the second behavior probability.

2. The method of predicting emotion-derived behavior of claim 1, wherein, The method further includes: Behavioral derivation and emotional attribution analysis are performed based on the optimized hypothetical subject-emotion-behavior triple.

3. The method of predicting emotion-derived behavior of claim 2, wherein, The behavioral derivation and sentiment attribution analysis based on the optimized hypothetical subject-emotion-behavior triple specifically includes: Based on the knowledge representation model, implicit subject-emotion-behavior triples are mined by using a combination of subject and emotion traversal as candidate inputs. By removing the subject dimension from the implicit subject-emotion-behavior triplet, we obtain the emotion-behavior binary set. By mapping the emotional dimension in the binary set of emotional behavior to emotional category labels, and deduplication is performed on the emotional dimension, we obtain the binary set of emotional behavior after deduplication of the emotional dimension. The behavior dimension in the deduplicated emotional behavior binary set is mapped to the behavior category label to remove duplicates in the behavior dimension, resulting in the emotional behavior binary set after deduplication in the behavior dimension. Construct an emotional behavior derivation matrix and a behavioral emotion attribution matrix based on the binary set of emotional behaviors after deduplication of behavioral dimensions; Normalize the emotion behavior derivation matrix and the behavior emotion attribution matrix to obtain the emotion behavior derivation probability matrix and the behavior emotion attribution probability matrix. Emotional behavior derivation analysis is performed based on the emotion behavior derivation matrix and the emotion behavior derivation probability matrix to determine the probability of various behaviors generated in the current emotional state; behavioral emotion attribution analysis is performed based on the behavior emotion attribution matrix and the behavior emotion attribution probability matrix to determine the probability of the emotion that triggers the current behavior.

4. The method of predicting emotion-derived behavior of claim 3, wherein, The emotion category labels include: "love", "fear", "joy", "sorrow", "surprise", "anger" and "normal"; The behavioral category labels include: prosocial behavior, normal behavior, and antisocial behavior; The specific labels for prosocial behavior include: altruism, win-win cooperation, and adherence to order; The specific categories of labels for normal behavior include: pleasure, calmness, and panic; The labels for antisocial behavior specifically include: harmful, aggressive, selfish, and disorderly.

5. The method for predicting emotion-derived behaviors according to claim 1, characterized in that, Based on the triplet relation metadata, the behavior prediction method based on Tucker decomposition is used for the first learning to obtain the first score. The first score is obtained by calculating the scores from subject-emotion to all behaviors, specifically including: The subject-emotion-behavior triple relationship is represented as a third-order binary tensor. ; where each element in the tensor For a given triplet relation, an element value of 1 indicates that the corresponding triplet actually exists, while an element value of 0 indicates that the corresponding triplet relation is incorrect or missing; the third-order binary tensor X is decomposed into a core tensor. With three types of partial matrices, the three types of partial matrices include the main embedding matrix e a Emotional embedding matrix e ε and behavior embedding matrix e r ; The score is calculated by integrating the subject's emotions into all behaviors, using the following formula: ;in, This represents the multiplication of the tensor at step n. Indicates the first Embedded representation of the subject Indicates the first Embedded representation of emotions, Indicates the first Embedded representation of a type of behavior; The k-th action word in the candidate set of action words. and It represents the subject and emotions.

6. The method for predicting emotion-derived behaviors according to claim 5, characterized in that, The embedded representation of the hypothetical subject-emotion-behavior triple is integrated into the attention mechanism to dynamically adjust the attention paid by the subject and emotion to the hypothetical subject-emotion-behavior triple, thereby optimizing the subject and emotion representations and obtaining an optimized hypothetical triple, specifically including: Based on the hypothetical subject-emotion-behavior triple, query the subject embedding matrix respectively. Emotion Embedding Matrix With behavior embedding matrix Obtain the subject embedding Emotional embedding Embedded with hypothetical behavior The hypothetical context embedding matrix is ​​obtained. ; Embed the hypothetical context into the matrix Viewed as the key and value matrices in the attention mechanism, the subject is embedded. The attention score is calculated in the hypothetical context using the query matrix, and the subject embedding representation in the hypothetical context is also calculated. ; ; Embedding emotions Treating it as a query matrix, calculate the sentiment embedding representation in the hypothetical context. ; Introducing hyperparameters α and β, we compute subject embeddings based on hypothetical context enhancement. With emotional embedding ; ; ; The optimized hypothetical triplet is obtained.

7. The method for predicting emotion-derived behaviors according to claim 6, characterized in that, The formula for calculating the probability of a behavior is: ; in, This represents the Sigmoid activation function; The loss function of the knowledge representation model is: ; in Indicates the number of actions. Let y represent the predicted probability and y represent the true label. , .

8. The method for predicting emotion-derived behaviors according to claim 7, characterized in that, Retrieve metadata about subject-sentiment-behavior triple relationships from a text dataset, specifically including: The Jieba word segmentation tool was used to obtain the words and parts of speech in the text dataset, thus obtaining the corpus data. Extract "emotion-behavior" and "subject-behavior" behavioral pattern data from the corpus data; Based on the data from the two behavioral patterns, obtain the corresponding subject-emotion-behavior triple relationship metadata.

9. A method for predicting emotion-derived behaviors according to claim 8, characterized in that, Extracting "emotion-behavior" and "subject-behavior" behavioral pattern data from the corpus data, specifically including: For "subject-behavior" behavior pattern extraction, a word order threshold is set to select the corpus data set. Center front A nominal morpheme, and based on word order relations according to the formula Mining data on "subject-behavior" behavioral patterns; For "emotion-behavior" behavior pattern extraction, a word order window is defined to restrict the candidate sentiment mining space to the semantic units adjacent to the behavior. The candidate ER behavior pattern extraction formula is as follows: ; After obtaining the subject-sentiment-behavior triple relation metadata from the text dataset, the following is also included: The metadata of the triple relation is generalized using two methods: a thesaurus and semantic similarity.

10. A computer device comprising: The memory and processor contain a computer program stored in the memory and executable on the processor, characterized in that the processor executes the computer program to implement the steps of a method for predicting emotion-derived behaviors as described in any one of claims 1-9.