Dialogue emotion perception method based on internal and external thinking chains

By employing the Inner and Outer Thought Chain (IoECoT) architecture and combining a large language model for data preprocessing and dual-task collaborative processing, the dual-task processing challenge of emotion recognition and emotion reasoning in existing technologies is solved, achieving efficient and personalized emotion perception and improving the adaptability and accuracy of the dialogue system.

CN121525697APending Publication Date: 2026-02-13NORTHEASTERN UNIV CHINA
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511699105.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-19
Publication Date
2026-02-13

AI Technical Summary

Technical Problem

Existing technologies cannot simultaneously handle both emotion recognition and emotion reasoning in the field of dialogue emotion perception, and they perform poorly in new scenarios and complex dialogues, exhibiting problems such as high resource consumption and insufficient adaptability.

Method used

By adopting the Inner and Outer Thinking Chain (IoECoT) architecture, it simulates the human emotional cognition process and uses a large language model for data preprocessing, extraction of internal and external factors, and dual-task collaborative processing to achieve a unified framework for emotion recognition and emotion reasoning, avoiding multi-system deployment and resource waste.

Benefits of technology

It achieves comprehensive, efficient, and personalized emotion perception capabilities, improves the accuracy and efficiency of emotion perception in multi-turn dialogues, and reduces computational resource consumption and system complexity.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121525697A_ABST
    Figure CN121525697A_ABST
Patent Text Reader

Abstract

The invention belongs to the technical field of large language model zero sample reasoning, and discloses a dialogue emotion perception method based on internal and external thinking chains. In order to solve the problem that double tasks of emotion recognition (ERC) and emotion reasoning (EIC) cannot be processed at the same time in the prior art, integrated processing of current emotion recognition and future emotion reasoning is achieved through the zero-shot advantage and unified framework design, and complexity and resource waste caused by deployment of two independent systems are avoided. According to the method, an internal and external thinking chain architecture is innovatively proposed, and the emotion perception accuracy of the model in multiple rounds of dialogues is remarkably improved through gradual reasoning from internal character factors to external emotion states instead of training with data in advance by simulating a human emotion cognition process. Through the technical innovation, the invention aims to provide a comprehensive, efficient and personalized emotion perception solution for the dialogue system, and overcomes the limitation of the prior art in the aspects of new scene adaptability and multi-task collaboration.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of zero-shot reasoning technology for large language models, and in particular to a dialogue emotion perception method based on internal and external thought chains. Background Technology

[0002] Emotion perception technology is one of the core technologies for building intelligent dialogue systems. Utilizing emotional information can significantly improve the interactive effect of dialogue and enhance emotional resonance, which is crucial for building high-quality dialogue systems. Dialogue systems that can effectively perceive the emotions of the speakers can provide more reasonable responses and effectively regulate the negative emotions of the speakers. This technology involves two main tasks: Emotion Recognition in Dialogue (ERC) and Emotion Inference in Dialogue (EIC).

[0003] In emotion recognition (ERC) tasks, to capture the complex relationships between dialogue participants and the sequential characteristics of the dialogue, researchers traditionally use graph convolutional neural networks (GCNs) to model the information interaction in the dialogue. The DialogueGCN method proposed by Ghosal D, Majumder N, Poria S, et al. DialogueGCN: A Graph Convolutional Neural Network for Emotion Recognition in Conversation[C] Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP). 2019: 154-164. treats each statement in the dialogue as a node in a graph and constructs edges based on the speaking order and speaker relationships. This method first uses pre-trained models such as BERT to extract textual features of the statements, combines them with metadata such as speaker IDs, aggregates information from neighboring nodes through a graph convolutional network, updates the node feature representations, and finally outputs the emotion label of the current statement through a classification layer.

[0004] In the Emotional Inference (EIC) task, researchers aim to solve the challenge of achieving emotional consistency and knowledge integration. Since EIC requires predicting emotional responses to unknown statements, the incorporation of external common-sense knowledge becomes particularly important. DialogInfer, proposed by Li D, Zhu X, Li Y, et al. Emotion inference in multi-turn conversations with addressee-aware module and ensemble strategy[C] Proceedings of the 2021conference on empirical methods in natural language processing. 2021: 3935-3941., is a typical approach. It first uses the COMET model to generate common-sense knowledge related to the dialogue, such as "exam notification → student anxiety". This method encodes this knowledge into vectors, concatenates them with the dialogue history, and inputs them into a Long Short-Term Memory (LSTM) network or a Transformer model. Through sequence modeling and attention mechanisms, the model can analyze the association between the dialogue context and common-sense knowledge, thereby predicting the emotional label of the next statement.

[0005] Emotion perception technology is crucial for handling new scenarios. With the development of large language model technology, numerous general zero-shot methods based on large language models and tailored to new scenarios have emerged. Besides basic methods such as direct prompting and plan-solver, there are also a series of methods based on CoT (Cooperative Thought) technology, which allows large models to "think step by step." Among these, ECoT (Li Z, Chen G, Shao R, et al. Enhancing emotional generation capability of large language models via emotional chain-of-thought[J]. arXiv preprintarXiv:2401.06836, 2024.) is specifically optimized for emotion generation tasks. Based on Goleman's theory of emotional intelligence, ECoT decomposes the complex emotional response process into a series of explicit thought steps: first, understanding the context of the dialogue; then, identifying the emotions of others and one's own emotions; managing one's own emotions; considering the impact on the emotions of others; and finally, generating an emotional response. Unlike general CoT methods, ECoT introduces guiding principles written by psychology experts, constraining the model to generate responses within the range of human emotional preferences. This approach effectively addresses the issue of harmful content in LLM during emotion generation tasks through an explicit emotion reasoning chain, significantly improving response security and emotional consistency.

[0006] While the DialogueGCN method can effectively model interaction relationships in dialogues, its core drawback lies in its strong dependence on labeled data. Because it requires a large amount of sentiment-labeled dialogue data for graph structure training, the model's performance often drops sharply when facing new domains or scenarios due to a lack of corresponding training data. Furthermore, graph convolutional networks suffer from information dilution when processing long dialogues; as the number of dialogue rounds increases and the distance between nodes widens, the transmission effect of sentiment features gradually weakens.

[0007] While the DialogInfer method enhances sentiment reasoning capabilities by incorporating external common-sense knowledge, it still suffers from resource consumption issues. The process of generating common-sense knowledge in the COMET model requires significant computational resources, and the quality of the generated knowledge directly impacts the accuracy of subsequent sentiment prediction. Experiments show that when dialogues involve specialized domains or specific cultural backgrounds, pre-trained COMET models often fail to generate relevant common-sense knowledge, leading to reasoning failures.

[0008] Both of the above methods are only used to handle one of the tasks in ERC or EIC. Given the complementary nature of these two tasks, methods that only target one task have inherent limitations. Applying these methods under a dual-task design requires deploying two independent systems, which increases the complexity of the application.

[0009] While ECoT, as a cutting-edge sentiment generation technology, enhances response safety by incorporating psychological theories, its design has fundamental limitations. This method is primarily optimized for single-turn sentiment generation tasks and performs poorly when handling dynamic changes in emotional states across multi-turn dialogues. For example, when a user's emotions shift multiple times during a conversation, ECoT's fixed thought process struggles to capture this complex emotional evolution. Furthermore, ECoT relies excessively on pre-defined psychological guidelines, which, while preventing the generation of harmful content, also limits the model's creative expression in specific scenarios, resulting in more stereotypical responses. ECoT also exhibits significant shortcomings in personalized sentiment reasoning, failing to adjust sentiment response strategies based on different users' personality traits—a major deficiency in practical applications.

[0010] In summary, existing technologies either focus on a single task (ERC or EIC) or have functional limitations when handling complex dialogue scenarios, failing to achieve comprehensive, efficient, and personalized dialogue emotion perception capabilities. This creates an urgent need to develop more advanced emotion perception technologies. Summary of the Invention

[0011] The purpose of this invention is to propose a dialogue emotion perception method based on internal and external thought chains to address the shortcomings of existing technologies in the field of dialogue emotion perception. First, addressing the problem that existing technologies cannot simultaneously handle the dual tasks of emotion recognition (ERC) and emotion reasoning (EIC), this invention achieves integrated processing of current emotion recognition and future emotion reasoning through zero-shot advantages and a unified framework design, avoiding the complexity and resource waste caused by deploying two independent systems. Addressing the poor performance of existing zero-shot methods in new dialogue scenarios, this invention innovatively proposes the Internal and External Thought Chain (IoECoT) architecture. By simulating the human emotional cognition process, it eliminates the need for pre-training with data, instead employing a progressive reasoning from internal personality factors to external emotional states, significantly improving the model's accuracy in emotion perception during multi-turn dialogues. Through these technological innovations, this invention aims to provide a comprehensive, efficient, and personalized emotion perception solution for dialogue systems, overcoming the limitations of existing technologies in adaptability to new scenarios and multi-task collaboration.

[0012] The technical solution of this invention is as follows: A dialogue emotion perception method based on internal and external thought chains, characterized in that it simultaneously handles the dual tasks of emotion recognition and emotion reasoning; the dialogue emotion perception method based on internal and external thought chains relies on a large language model, and the processing flow includes data preprocessing, internal and external factor extraction, dual-task collaborative processing, and result output; firstly, the input dialogue is preprocessed, and through internal and external factor extraction, personality information is extracted in parallel as the internal thought chain and historical emotional state as the external thought chain. Under the dual-task collaborative processing, the fused emotion features are obtained, and the current emotion recognition result and future emotion reasoning prediction are output simultaneously.

[0013] The data preprocessing section performs dialogue standardization on the input data;

[0014] Input the original multi-turn dialogue data in the format: [(u1, p1), (u2, p2), ..., (ui, pi), ...,(un, pn)], where ui represents the statement in the i-th round and pi represents the speaker; convert it to the uniform format: "speaker: statement".

[0015] The internal and external factors extraction section;

[0016] Personality information is extracted from the dialogue as the internal thought chain, while historical emotional states are extracted in parallel as the external thought chain based on the dialogue history. The internal and external thought chains serve as two guiding prompts for the large language model, prompting the model to output the information expected for the task. Subsequently, guided by the output of the internal thought chain, the output of the external thought chain is merged as the input for the next step in the process.

[0017] The internal thought chain is obtained by extracting personality information from dialogue;

[0018] To obtain the internal thought chain, it is necessary to extract the target user's personal personality information; input the standardized dialogue history into the large language model, use the "most accurate single-sentence brief description" as the generation standard, and set prompt words containing the target user's name and task requirements, so that the large language model can output a natural language description of the target user's personal personality based on the dialogue history.

[0019] Based on the extracted personal personality information of the target users, internal thought chain optimization is performed;

[0020] We employ a proven "step-by-step" approach to interpret personality traits. By combining dialogue history with personal personality information and inputting it into a large language model, the model progressively analyzes how target users with specific personality traits are affected by events in the dialogue context. The personality information obtained from the analysis already includes the target user's sensitivity to the emotional impact of the current scene, providing an intrinsic basis for judging whether emotions persist or are transmitted to the next stage.

[0021] Extract historical emotional states as external thought chains, and execute them in parallel with internal thought chains;

[0022] The large language model categorizes each dialogue content into neutral, positive, or negative and records them in the format of "speaker's name: emotional polarity". Since the intensity of emotional impact is related to the dialogue time interval, the emotional polarity results of all historical dialogues are arranged in the dialogue order to ensure the accuracy of the intensity of emotional impact. It captures the emotional changes that occur during the dialogue process and provides historical emotional states as external factors for emotional perception.

[0023] The dual-task collaborative processing component analyzes the emotional sensitivity and dialogue order of both parties in the conversation, and performs multi-dimensional analysis by combining internal factors such as personal personality information and external factors such as historical emotional states.

[0024] Simultaneously considering both emotion recognition and emotion reasoning tasks, internal and external factors are combined to perform the two tasks collaboratively.

[0025] Emotion recognition task processing:

[0026] Input: Current statement + Personality analysis results + Historical emotional state

[0027] Prompt word template: "Please analyze and provide the emotion label of [u]" i ]."

[0028] Output: The sentiment tag of the current statement.

[0029] Emotional reasoning task processing:

[0030] Input: Personality analysis results + historical emotional state

[0031] Prompt template: "Please analyze and provide the emotion label of the nextutterance."

[0032] Output: Predicted sentiment label for the target statement.

[0033] The beneficial effects of this invention are as follows: This invention constructs a unified system architecture: a dual-task collaborative processing framework that places the two major tasks of emotion recognition (ERC) and emotion reasoning (EIC) in the same processing flow. This framework achieves seamless integration of current emotion state recognition and future emotion trend prediction through shared data preprocessing modules and internal and external thought chain reasoning modules, avoiding the drawbacks of separate deployment of multiple systems in existing technologies.

[0034] This invention proposes the Internal and External Thinking Chains (IoECoT) as a core reasoning mechanism. This mechanism initiates two processing paths in parallel: the internal thinking chain focuses on extracting and analyzing the target user's stable personality traits; the external thinking chain is responsible for capturing the dynamically changing emotional state sequence during the dialogue. This parallel design, while ensuring depth of reasoning, also establishes a fusion strategy of "internal factors guiding the interpretation of external factors," thereby enabling in-depth analysis of the emotional response patterns of users with specific personalities in specific dialogue contexts. This significantly improves the system's processing efficiency and effectiveness.

[0035] In extracting and classifying historical emotions and personality traits, this invention abandons the traditional fixed personality label classification and instead utilizes a large language model to generate more expressive natural language to describe personality. Simultaneously, it fully leverages the high accuracy of LLM in classifying emotional polarity (neutral / positive / negative) as a key auxiliary feature, providing a richer and more accurate data foundation for emotion perception. Attached Figure Description

[0036] Figure 1 shows the IoECoT framework and its application examples;

[0037] Figure 2 This is a flowchart of the processing procedure. Detailed Implementation

[0038] This invention proposes a dialogue emotion perception method based on internal and external thought chains, which simultaneously handles the dual tasks of emotion recognition (ERC) and emotion reasoning (EIC) through a unified framework. The system architecture includes a data preprocessing module, an internal and external thought chain reasoning module, a dual-task collaborative processing module, and a result output module. Figure 1 As shown, the system first standardizes the input dialogue, then gradually extracts internal personality information and external emotional state through a four-step thought chain reasoning process, and finally outputs the current emotion recognition result and future emotion reasoning prediction based on the fused emotional features.

[0039] Step 1: Dialogue Standardization

[0040] Input raw multi-turn dialogue data in the format: [(u1, p1), (u2, p2), ..., (un, pn)], where ui represents the i-th round statement and pi represents the speaker. Convert it to a uniform format: speaker: statement, for example: "Jack: Oh, theexam is moved up!"

[0041] Then, following the internal and external thought chains, the extraction of personality information from the internal thought chain (step 2) and the extraction of historical emotional states from the external thought chain (step 4) are initiated in parallel.

[0042] Step 2: Extraction of personality information from internal thought chains (extraction of internal factors)

[0043] First, we extract the target user's personal personality information from the internal thought process. Since large models are more prone to errors when their outputs are too long, we use the "most accurate single-sentence concise description" as the generation standard to ensure that the generated personality description is both concise and accurate. Specifically, we input standardized dialogue history into the large model and set prompts containing the target user's name and task requirements, enabling the model to output a natural language description of the target user's personality based on the dialogue history.

[0044] Input: Standardized conversation history + target username

[0045] Prompt template: "Please provide the most accurate one-sentence short description of the [user's] personality."

[0046] Output: A concise natural language personality description.

[0047] Step 3: Internal Thinking Chain Personality Analysis (Deepening Internal Factor Analysis)

[0048] After extracting personality information, it undergoes personality analysis. The system leverages this data through in-depth analysis to fully realize its value. However, directly using personality data cannot comprehensively reflect the target user's emotional sensitivity in the current dialogue scenario. Therefore, a "step-by-step analysis" method is employed for personality trait interpretation. By combining dialogue history with personality trait data and inputting it into a large language model, the model progressively analyzes how target users with specific personality traits are affected by events in the dialogue context. Because the analyzed personality information already includes the target user's sensitivity to the emotional impact of the current scenario, it provides an intrinsic basis for determining whether emotions persist or propagate to the next stage. Through these two steps of information extraction and interpretation, the large language model ultimately uses the target user's personality information as the intrinsic driving force behind emotional changes.

[0049] Input: Personality description + dialogue context

[0050] Prompt template: "Let's explain personality step by step in context."

[0051] Output: A step-by-step explanation of personality based on emotions expressed in the context of the dialogue.

[0052] Step 4: Extracting Historical Emotional States from External Thought Chains (External Factors)

[0053] The extraction of historical emotional states from external thought chains is performed in parallel with that from internal thought chains. Since the Large Language Model (LLM) has been experimentally validated to have higher accuracy in emotional polarity classification, we utilize LLM to categorize each dialogue content as neutral, positive, or negative, recording it in the format "Speaker Name: Emotional Polarity". Because the intensity of emotional impact is related to the dialogue interval—the shorter the interval, the stronger the emotional impact—we arrange the emotional polarity results of all historical dialogues in dialogue order to ensure the accuracy of emotional impact intensity. This method captures emotional changes occurring during the dialogue process, providing historical emotional states as an external factor for emotional perception.

[0054] Input: Conversation history

[0055] Prompt template: "Please judge the polarity of each."

[0056] Output: A time-ordered sequence of sentiment polarities.

[0057] Step 5: Emotion Perception (Dual-Task Collaboration)

[0058] Building upon steps 3 and 4, the Large Language Model (LLM) performs a multi-dimensional analysis by examining the emotional sensitivity and dialogue sequence of both parties, combining internal factors (personality traits) with external factors (historical emotional states). Here, because both the ERC and EIC tasks need to be considered simultaneously, internal and external factors are mixed for collaborative execution of both tasks.

[0059] ERC task processing:

[0060] Input: Current statement + Personality analysis results + Historical emotional state

[0061] Prompt word template: "Please analyze and provide the emotion label of [u]" i ]."

[0062] Output: The sentiment tag of the current statement.

[0063] EIC Task Processing:

[0064] Input: Personality analysis results + historical emotional state

[0065] Prompt template: "Please analyze and provide the emotion label of the nextutterance."

[0066] Output: Predicted sentiment tag for the target statement

[0067] This invention, through deep reasoning using the Inner and Outer Thought Chain (IoECoT) and an inside-out fusion strategy, can more accurately identify current emotions and predict future emotion trends. Compared with existing non-training techniques (such as Cue-CoT, ECoT, etc.), it significantly improves the accuracy of ERC and EIC tasks on multiple standard datasets, especially when dealing with complex emotions and dynamic changes in multi-turn dialogues. Furthermore, the unified dual-task framework means that developers no longer need to develop and maintain two separate systems for ERC and EIC tasks. This not only simplifies the technical architecture and reduces the consumption of computing resources, but also significantly reduces the workload and cost of system integration, version updates, and subsequent maintenance.

[0068] Table 1 shows that IoECoT achieves state-of-the-art performance on the ERC task. Compared to traditional zero-shot and chain-thinking methods, IoECoT excels in information extraction and organization. It efficiently extracts key information closely related to emotion recognition, ensuring that the system fully utilizes all necessary contextual information when identifying the current emotion. Therefore, IoECoT demonstrates superior accuracy and robustness in emotion recognition. Table 2 shows that IoECoT performs well on the EIC task. Through deep reasoning and the fusion of internal and external information, IoECoT comprehensively captures the emotional dynamics in dialogue and accurately infers the evolution of emotions. This makes it more adaptable and accurate than other methods when handling emotion reasoning tasks, especially when dealing with complex dialogues, where IoECoT's advantages are even more pronounced.

[0069] The method of this invention does not rely on labeled data for a specific task and has excellent zero-shot generalization ability. When faced with entirely new application scenarios, user groups, or dialogue domains, the system can immediately demonstrate excellent performance without the need for expensive and time-consuming data collection and model retraining. This is a major breakthrough in freeing the system from dependence on data training.

[0070] Table 1 Experimental results of IoECoT in ERC tasks

[0071]

[0072] Where w-F1 represents the weighted F1 score and m-F1 represents the macro F1 score.

[0073] Table 2 Experimental results of IoECoT performing EIC tasks.

[0074]

Claims

1. A dialogue emotion perception method based on internal and external thought chains, characterized in that, Simultaneously handling both emotion recognition and emotion reasoning tasks; the dialogue emotion perception method based on internal and external thought chains relies on a large language model, and the processing flow includes data preprocessing, internal and external factor extraction, dual-task collaborative processing, and result output; firstly, the input dialogue is preprocessed, and through internal and external factor extraction, personality information is extracted in parallel as the internal thought chain and historical emotional state as the external thought chain. Under dual-task collaborative processing, the fused emotion features are obtained, and the current emotion recognition result and future emotion reasoning prediction are output simultaneously.

2. The dialogue emotion perception method based on internal and external thought chains according to claim 1, characterized in that, The data preprocessing section performs dialogue standardization on the input data; Input the original multi-turn dialogue data in the format: [(u1, p1), (u2, p2), ..., (ui, pi), ...,(un, pn)], where ui represents the statement in the i-th round and pi represents the speaker; convert it to the uniform format: "speaker: statement".

3. The dialogue emotion perception method based on internal and external thought chains according to claim 1, characterized in that, The internal and external factors extraction section; Personality information is extracted from the dialogue as the internal thought chain, and historical emotional states are extracted in parallel based on the dialogue history as the external thought chain, thus constructing internal and external thought chains. The internal and external thought chains serve as two guidance prompts for the large language model, prompting the model to output the information expected for the task. Subsequently, the output of the external thought chain is integrated under the guidance of the internal thought chain output as the input for the next step of the process.

4. The dialogue emotion perception method based on internal and external thought chains according to claim 3, characterized in that, The internal thought chain is obtained by extracting personality information from dialogue; To obtain the internal thought chain, it is necessary to extract the target user's personal personality information; input the standardized dialogue history into the large language model, use "the most accurate single-sentence concise description" as the generation standard, and set prompt words containing the target user's name and task requirements, so that the large language model can output a natural language description of the target user's personal personality based on the dialogue history.

5. The dialogue emotion perception method based on internal and external thought chains according to claim 4, characterized in that, Based on the extracted personal personality information of the target users, internal thought chain optimization is performed; We employ a proven "step-by-step" approach to interpret personality traits. By combining dialogue history with personal personality information and inputting it into a large language model, the model progressively analyzes how target users with specific personality traits are affected by events in the dialogue context. The personality information obtained from the analysis already includes the target user's sensitivity to the emotional impact of the current scene, providing an intrinsic basis for judging whether emotions persist or are transmitted to the next stage.

6. The dialogue emotion perception method based on internal and external thought chains according to claim 3, characterized in that, Extract historical emotional states as external thought chains, and execute them in parallel with internal thought chains; The large language model categorizes each dialogue content into neutral, positive, or negative and records them in the format of "speaker's name: emotional polarity". Since the intensity of emotional impact is related to the dialogue time interval, the emotional polarity results of all historical dialogues are arranged in the dialogue order to ensure the accuracy of the intensity of emotional impact. It captures the emotional changes that occur during the dialogue process and provides historical emotional states as external factors for emotional perception.

7. The dialogue emotion perception method based on internal and external thought chains according to claim 1, characterized in that, The dual-task collaborative processing component analyzes the emotional sensitivity and dialogue order of both parties in the conversation, and performs multi-dimensional analysis by combining internal factors such as personal personality information and external factors such as historical emotional states. Simultaneously considering both emotion recognition and emotion reasoning tasks, internal and external factors are combined to perform the two tasks collaboratively. Emotion recognition task processing: Input: Current statement + Personality analysis results + Historical emotional state Prompt word template: "Please analyze and provide the emotion label of [u]" i ]." Output: The sentiment tag of the current statement. Emotional reasoning task processing: Input: Personality analysis results + historical emotional state Prompt template: "Please analyze and provide the emotion label of the nextutterance." Output: Predicted sentiment label for the target statement.