EmotionGraphRAG: Enhancing LLM-Based Emotion Analysis through Graph Retrieval-Augmented Generation

Fangzheng Ye · 2025

Aiming at the problems faced by large language models (LLMs) in the emotion domain, such as generating "illusions", lack of domain knowledge, and relying on limited training data, this paper proposes a graph-structure-based retrieval augmentation generation (RAG) framework-EmotionGraphRAG. Traditional retrieval augmentation generation (RAG) methods mainly rely on textual knowledge base, which is difficult to effectively model the complex structured relationships in emotion data. To this end, this framework significantly improves the accuracy and interpretability of the emotion quiz task by introducing graph-structured data and combining entity-relationship modeling with hierarchical retrieval strategies. Specifically, EmotionGraphRAG adopts a three-phase architecture: semantic-based document chunking with entity extraction from the LIWC2015 lexicon to construct a knowledge graph; Louvain algorithm is used to generate hierarchical community summaries to capture global semantics; and the BM25 algorithm is combined with the BM25 algorithm to dynamically retrieve information from multiple sources and integrate to obtain a global answer. Experiments validate the effectiveness of the model on the EmoryNLP and MELD datasets. The results show that the EmotionGraphRAG framework significantly improves the effectiveness of mainstream LLMs (Llama3.1, Deepseek-r1, and GPT-4o-mini) on emotional quizzing in terms of F1 scores. This work provides a traceable, evidence-based generative scheme for emotional analysis in psychology and a new technical avenue for domain-adaptive research in LLM.

Read the paper · More papers on PaperTik