Source-linked AI summary
Hello Again! LLM-powered Personalized Agent for Long-term Dialogue
Hao Li, Chenghao Yang, An Zhang, Yang Deng, Xiang Wang, Tat-Seng Chua
TL;DR
Existing dialogue systems often focus on brief single-session exchanges, leaving long-term memory and personalized consistency insufficiently addressed. LD-Agent combines modular event-memory perception, persona extraction, and response generation, and the paper reports strong effectiveness, generality, and cross-domain performance across benchmarks, models, and tasks.
Problem
Most dialogue systems focus on brief single-session interactions, while long-term companionship requires retaining events and consistently modeling user and agent personas.
Method
LD-Agent is a model-agnostic framework that separately handles long- and short-term event memory, dynamically extracts user and agent personas, and integrates them for response generation.
Results
LD-Agent achieves state-of-the-art performance on both benchmarks, improves results across models and tasks, and nearly matches in-domain performance in cross-domain settings.
Takeaways & Limitations
A modular long-term dialogue agent can support coherent interactions across sessions while adapting across models, tasks, and domains.
Takeaways & Limitations
The evaluation is confined to synthetic long-dialogue datasets, and the modules use basic implementations rather than more sophisticated memory and persona methods.
Abstract
from arXiv · showhide
Open-domain dialogue systems have seen remarkable advancements with the development of large language models (LLMs). Nonetheless, most existing dialogue systems predominantly focus on brief single-session interactions, neglecting the real-world demands for long-term companionship and personalized interactions with chatbots. Crucial to addressing this real-world need are event summary and persona management, which enable reasoning for appropriate long-term dialogue responses. Recent progress in the human-like cognitive and reasoning capabilities of LLMs suggests that LLM-based agents could significantly enhance automated perception, decision-making, and problem-solving. In response to this potential, we introduce a model-agnostic framework, the Long-term Dialogue Agent (LD-Agent), which incorporates three independently tunable modules dedicated to event perception, persona extraction, and response generation. For the event memory module, long and short-term memory banks are employed to separately focus on historical and ongoing sessions, while a topic-based retrieval mechanism is introduced to enhance the accuracy of memory retrieval. Furthermore, the persona module conducts dynamic persona modeling for both users and agents. The integration of retrieved memories and extracted personas is subsequently fed into the generator to induce appropriate responses. The effectiveness, generality, and cross-domain capabilities of LD-Agent are empirically demonstrated across various illustrative benchmarks, models, and tasks. The code is released at https://github.com/leolee99/LD-Agent.
1 Introduction
Long-term personalized dialogue requires systems to retain event history while maintaining consistent user and agent personas. LD-Agent addresses this need with modular memory, persona, and generation components and demonstrates effectiveness, generality, and cross-domain adaptability.
- Motivation: Existing dialogue systems mainly support brief single-session interactions, whereas long-term companionship requires remembering dialogue history and consistently updating user and agent characteristics.The paper identifies simultaneous event-memory retention and persona consistency as the core challenge.
- Proposed Framework: LD-Agent is a model-agnostic framework with independently tunable modules for event-memory perception, persona extraction, and response generation.Its memory module separates long-term historical summaries from short-term ongoing context, while persona representations are continuously updated.
- Proposed Framework: The framework integrates retrieved event memories with dynamically extracted user and agent personas to guide appropriate long-term responses.This design targets coherence across sessions and consistency of conversational character.
- Evaluation: LD-Agent achieves state-of-the-art performance on both benchmarks and substantial improvements across different models and multiparty dialogue tasks.The evaluation includes online and offline models, including both LLMs and non-LLMs.
- Evaluation: Across two cross-domain settings, LD-Agent delivers competitive performance that nearly matches in-domain training results.The settings train on MSC and test on CC, and then reverse those datasets.
2 Related Work
Prior work has extended dialogue beyond short sessions using external and internal knowledge, while LLM agents have been applied to task execution and human-behavior simulation. Figure 1 illustrates how LD-Agent combines event memory and personas for personalized long-term interaction.
- Long-term Dialogue Illustration: Figure 1 shows event memory prompting a follow-up about a previously scheduled swimming lesson, while personas guide careful and professional advice.The memory and persona information comes from a conversation held one week earlier.
- Long-term Dialogues: Earlier long-term dialogue research supplements extended conversations with external knowledge such as commonsense, medical, and psychological information.These knowledge sources provide guidance for reasoning and logical coherence in extended contexts.
- Long-term Dialogues: Internal knowledge in long-term dialogue systems dynamically captures historical events and other information from ongoing conversations.This complements external knowledge when maintaining continuity across sessions.
- LLM-based Autonomous Agents: LLM-based agents are broadly organized around autonomous perception, decision-making, and problem-solving, with applications spanning task-oriented and simulation-oriented settings.Examples include web assistance, game-playing, software development, psychology, social networking, conflict resolution, and recommendation.
3 Method
LD-Agent is a model-agnostic framework for long-term multi-session dialogue that combines event memory, dynamic personas, and response generation. It separates historical and current-session memory, improves retrieval with semantic, topic, and time signals, and feeds retrieved memories and personas into the generator.
- Framework: LD-Agent combines event perception, persona extraction, and response generation to generate responses using current context and selected historical information.The framework is designed for long-term multi-session dialogue rather than single-session interaction.
- Event Memory: The event memory module separates long-term historical memory from short-term current-session context to support coherent responses across sessions.Long-term memory stores encoded event summaries, while short-term memory preserves detailed ongoing dialogue context.
- Event Memory: Memory retrieval combines semantic relevance, topic overlap, and time decay, while filtering memories below a semantic threshold.The retrieval score is reweighted with exponential time decay, and memories are returned only when their semantic score exceeds γ=0.5.
- Event Memory: The short-term cache triggers event summarization and long-term storage when the interval since its last record exceeds the configured threshold.The stated threshold is 600 seconds; the cache is then cleared and the new dialogue record is added.
- Persona and Response Generation: The persona module dynamically manages separate user and agent persona banks, and the response generator combines personas with retrieved memories and short-term context.The persona extractor and response generator are tunable modules within the framework.
- Persona and Response Generation: Generator tuning uses dynamically simulated multi-session data containing retrieved memories, context, and personas from the MSC and CC datasets.Each sample covers five sessions and uses the previously tuned event summarization, persona extraction, and retrieval modules.
4 Experiments
Experiments evaluate LD-Agent across long-term dialogue benchmarks, models, modules, retrieval strategies, and domains. Results show strong effectiveness, generality, cross-domain transfer, and benefits from event memory and tuned persona extraction.
- 4.3 Results of Multi-Session Dialogue: LD-Agent consistently improves performance across all sessions and metrics on MSC and CC, outperforming the previous state-of-the-art HAHT on BLEU-2.BlenderBot with LD-Agent achieves a large BLEU-2 gap over HAHT from sessions 2 to 5 on both datasets.
- 4.3 Results of Multi-Session Dialogue: LD-Agent generalizes across zero-shot and tuned settings, improving ChatGPT, ChatGLM, and BlenderBot across both long-term dialogue benchmarks.The reported results support transferability across online and offline models, including LLMs and traditional language models.
- 4.4 Module Ablation Study: Adding event memory, agent personas, or user personas improves long-term dialogue, with event memory contributing most and producing more stable performance as sessions increase.All modules show performance decline across sessions, but event memory declines less than the persona-only variants.
- 4.5 Persona Extraction Analysis: The tuned persona extractor outperforms zero-shot Chain-of-Thought extraction on persona metrics and improves response generation, with the gap widening across sessions.Higher BLEU, ROUGE-L, and accuracy indicate stronger persona extraction and classification performance after tuning.
- 4.6 Human Evaluation: Topic-based retrieval significantly outperforms direct semantic retrieval on human-annotated accuracy and recall.The comparison is reported in Figure 3(a) and supports more accurate retrieval of relevant memories.
- 4.7 Generality Analysis: LD-Agent transfers across domains and tasks, retaining strong performance when tuned on one dialogue dataset and achieving state-of-the-art performance on most Ubuntu IRC metrics.Cross-domain models show only a slight decrease from same-domain tuning, while BART with LD-Agent outperforms prior multiparty dialogue methods in most metrics.
5 Conclusion
LD-Agent addresses long-term, personalized dialogue by combining historical events with user and agent personas in a modular framework. Experiments show strong capability and practicality across multiple benchmarks, models, and tasks.
- LD-Agent combines historical events with user-agent personas to support coherent and consistent long-term conversation.
- Its three learnable modules enhance the framework’s adaptability and transferability across dialogue settings.
- Extensive experiments demonstrate strong long-term dialogue capability and practicality across multiple benchmarks, models, and tasks.
Limitations
The paper identifies synthetic data and basic module implementations as the main limitations of LD-Agent. Future work should validate the framework on authentic long-term dialogues and explore more sophisticated memory and persona methods.
- The paper notes that long-term open-domain dialogue research remains incomplete despite LD-Agent’s reported effectiveness and generality.
- The evaluation is confined to synthetic long-dialogue datasets because authentic real-world long-term dialogue data are difficult to collect.The authors plan to validate LD-Agent on real long-term dialogue data in future work.
- LD-Agent’s modules use basic methods, leaving sophisticated summarization, retrieval, personality extraction, and persona retrieval for future exploration.The limitation applies especially to the memory and persona modules.
A.4 Implementation Details
The implementation uses shared base models with LoRA across the three LD-Agent modules and evaluates memory retrieval through human-evaluation guidelines. The appendix also provides concrete retrieval scenarios and evaluation materials.
- Implementation Details: The event summarizer, persona extractor, and response generator share a base model and use LoRA across configurations.Training and evaluation were conducted on a single NVIDIA A100 GPU.
- Human Evaluation: Human evaluation includes guidelines for assessing memory retrieval in context-sensitive conversations.
- Human Evaluation: The retrieval guideline asks evaluators to choose the memory entry most relevant to the current topic and useful for responding.The example contrasts relevant memories with unrelated memories and a no-relevant-memory option.
B Qualitative Analysis
Because practical open-domain dialogue lacks a single gold response, the appendix adds qualitative analyses of persona and memory effects. These examples show more proactive persona-consistent responses and better continuity when memory is available.
- Qualitative analysis supplements quantitative evaluation because practical open-domain dialogue has no single gold reference answer.
- Persona Module: Using initial personas leads the agent to proactively inquire about a new company, aligning with enthusiastic and proactive persona traits.
- Memory Module: Adding the memory module enables the agent to recall previously recommended movies and improves conversational continuity.
B.3 Event Summarizer Analysis
The trained event summarizer is evaluated in-domain and out-of-distribution, with results indicating stronger performance and more concise long-term memory summaries than zero-shot ChatGLM.
- B.3 Event Summarizer Analysis: The analysis evaluates the summarizer through in-domain evaluation, out-of-distribution evaluation, and module impact analysis.The evaluation uses DialogSum for in-domain testing and SAMSum as an out-of-domain dataset.
- B.3 Event Summarizer Analysis: The trained summarizer consistently improves over zero-shot ChatGLM across all metrics on both DialogSum and SAMSum.The out-of-domain SAMSum gains indicate stronger generalization ability.
- B.3 Event Summarizer Analysis: LD-Agent summaries are more concise and preserve the conversation’s most important information, making them better suited to long-term memory storage.Figure 7 compares summaries generated from the same dialogue context by zero-shot ChatGLM and the LD-Agent summarizer.
B.4 Persona Extractor Analysis
The dynamic persona extractor is compared with zero-shot ChatGLM, while an example illustrates LD-Agent’s ability to use historical information in response generation.
- B.4 Persona Extractor Analysis: The tuned persona extractor produces more concise and logical personas than zero-shot ChatGLM, supporting longer-term dialogue processes.Figure 8 uses an utterance from a real-world scenario as input for the comparison.
- B.4 Persona Extractor Analysis: LD-Agent generates a response that captures information about General Nathan Bedford Forrest from a prior history session, outperforming original ChatGLM in the example.The comparison is illustrated in Figure 10.
C.1 Part of Speech Importance Analysis
The topic-based retrieval mechanism uses noun overlap to estimate topic similarity, motivated by the greater information content associated with less frequent words.
- C.1 Part of Speech Importance Analysis: LD-Agent computes noun overlap to represent topic similarity in its topic-based retrieval mechanism.The method treats nouns as especially informative for determining relevance.
- C.1 Part of Speech Importance Analysis: The analysis examines information entropy to support the use of nouns for relevance estimation.The rationale links information entropy and word frequency, with less frequent words generally carrying more information.
C.2 Generation Diversity Analysis
LD-Agent’s responses are evaluated for diversity and illustrated through its event, persona, and response-generation prompts and an example of history-aware dialogue.
- C.2 Generation Diversity Analysis: LD-Agent responses are consistently more diverse than ChatGLM responses on MSC according to Dist-1/2/3 evaluation.The authors interpret this result as evidence of the generator’s stronger generation capability.
- C.2 Generation Diversity Analysis: The event-summary prompt asks for brief English summaries of a conversation’s main points within 20 words.This prompt supports concise event memory construction.
- C.2 Generation Diversity Analysis: The persona-extraction prompt directs the model to extract personal traits and return NO_TRAIT when no trait is available.Its examples distinguish current and former personal attributes.
- C.2 Generation Diversity Analysis: The base response prompt conditions generation on the recent conversation and the user’s latest statement while role-playing the agent.It specifies an English response with a maximum length of 30 words.
- C.2 Generation Diversity Analysis: The agent response prompt combines recent context, retrieved memories, user traits, and agent traits before generating a response.The prompt constrains responses to English and a maximum of 30 words.
- C.2 Generation Diversity Analysis: An example shows LD-Agent producing a more relevant response to a history conversation than original ChatGLM.The comparison is presented in Figure 10.