Harnessing the Power of Large Language Models for Empathetic Response Generation: Empirical Investigations and Improvements

Yushan Qian, Wei-Nan Zhang, Ting Liu · DOI

Abstract

Empathetic response generation is a critical component of human-centric artificial intelligence, requiring models to understand and respond to user emotions with depth and sensitivity. While traditional approaches relied on specialized, small-scale models, this research explores the potential of Large Language Models (LLMs) to redefine the state-of-the-art. By introducing three novel prompting strategies—Semantically Similar In-Context Learning, Two-stage Interactive Generation, and Knowledge Base Integration—the authors demonstrate that LLMs like ChatGPT significantly outperform previous models in both diversity and human preference. Furthermore, the study validates GPT-4 as a viable proxy for human evaluation in subjective empathy assessments.

Introduction

The ability of an AI to exhibit empathy—recognizing, understanding, and reacting appropriately to a user's emotional state—is essential for applications ranging from mental health support to customer service. Historically, this task was approached by training specialized models such as MoEL or MIME on specific empathetic dialogue datasets. However, these models often suffer from "generic response syndrome," where the AI provides repetitive and shallow comforts like "I am sorry to hear that," failing to engage with the specific nuances of the user's situation.

The emergence of Large Language Models (LLMs) presents a new opportunity. These models possess vast latent knowledge about human social dynamics and language patterns. This paper investigates how to effectively steer LLMs to generate deep, context-aware empathetic responses without the need for computationally expensive fine-tuning.

Methodology

To enhance the empathetic capabilities of LLMs, the authors propose a unified prompt template augmented by three "Advanced Exploration" strategies:

1. Semantically Similar In-Context Learning (SS ICL)

Standard In-Context Learning often uses random dialogue examples as exemplars. In contrast, SS ICL utilizes a sentence encoder (all-mpnet-base-v2) to retrieve examples from the training set that are semantically closest to the current user input. By providing the LLM with contextually relevant examples, the model can better mimic linguistic patterns appropriate for the specific emotional scenario.

2. Two-stage Interactive Generation

Drawing inspiration from "Chain-of-Thought" prompting, this method implements a "think-before-speaking" workflow. In the first stage, the LLM is prompted to explicitly infer the user's emotion and the underlying situation. In the second stage, the model uses these inferences, alongside the dialogue history, to craft the final response. This explicit reasoning step ensures the model's response is grounded in a correct understanding of the user's state.

3. Knowledge Base Integration

To provide the LLM with a deeper understanding of social cause-and-effect, the authors integrate external commonsense knowledge. Using COMET-BART to query the ATOMIC 20/20 knowledge base, the system extracts five social relations—such as the user's intent, needs, and likely reactions. This structured knowledge is then injected into the prompt, allowing the LLM to generate responses informed by human social dynamics.

Experimental Setup

The study utilizes the EMPATHETICDIALOGUES dataset, a benchmark containing multi-turn conversations across 32 emotion labels. The researchers compared LLMs (specifically ChatGPT and GPT-4) against previous state-of-the-art models like CASE and BlenderBot. Evaluation was conducted using both automatic metrics (such as Distinct-n for linguistic diversity) and rigorous human A/B testing.

Key Findings

The Superiority of LLMs in Diversity

One of the most significant findings was the disparity in response diversity. ChatGPT (+5-shot) achieved a Dist-2 score of 18.29, a nearly six-fold increase over the previous state-of-the-art model, CASE, which scored only 3.26. This indicates that LLMs effectively overcome the "generic response syndrome" that plagued smaller models.

Human Preference and Reasoning

Human annotators overwhelmingly preferred LLM-generated responses. In head-to-head testing, ChatGPT's responses were favored over BlenderBot in 74.7% of cases for empathy and 71.0% for informativity. The "Two-stage" reasoning approach was particularly effective, achieving an emotion inference accuracy of 39.18%, outperforming many models specifically trained for emotion classification.

GPT-4 as a Scalable Evaluator

A major bottleneck in empathy research is the cost of human evaluation. The authors found that GPT-4’s ratings correlate strongly with human judges, achieving a Spearman correlation of 0.485 for empathy. This suggests that GPT-4 can serve as a reliable and cost-effective proxy for evaluating subjective dialogue qualities.

Conclusion and Future Work

This research demonstrates a paradigm shift in empathetic AI, showing that the "knowledge" required for empathy is already latent in large-scale pre-training. While LLMs set a new bar for performance, challenges remain. Empathy is highly subjective and influenced by cultural and personal contexts that current models do not fully capture. Future research should focus on adapting LLMs to specific user personas and exploring deeper comprehension of complex social contexts to further refine AI-driven empathy.

Summary updated

BibTeX
@inproceedings{qian2023harnessing,
  author = {Yushan Qian and Wei-Nan Zhang and Ting Liu},
  title = {{Harnessing the Power of Large Language Models for Empathetic Response Generation: Empirical Investigations and Improvements}},
  booktitle = {Conference on Empirical Methods in Natural Language Processing},
  year = {2023},
  url = {https://openreview.net/forum?id=cMMxJxzYkZ},
}
Figure