We propose a novel framework for persona-based language model system, motivated by the need for personalized AI agents that adapt to individual user preferences. In our approach, the agent embodies the user's "persona" (e.g. user profile or taste) and is powered by a large language model (LLM). To enable the agent to leverage rich contextual information, we introduce a Knowledge-Graph-enhanced Retrieval-Augmented Generation (Graph RAG) mechanism that constructs an LLM-derived graph index of relevant documents and summarizes communities of related information. Our framework generates personalized prompts by combining: (1) a summary of the user's historical behaviors and preferences extracted from the knowledge graph, and (2) relevant global interaction patterns identified through graph-based community detection. This dynamic prompt engineering approach allows the agent to maintain consistent persona-aligned behaviors while benefiting from collective knowledge. On the LaMP benchmark, our method improves news categorization F1 by 11.1%, movie tagging F1 by 56.1%, and reduces product rating MAE by 10.4% over prior methods. Our code is available at https://anonymous.4open.science/r/PersonaAgentwGraphRAG-DE6F


翻译:本文提出了一种新颖的基于角色的大语言模型系统框架,其动机源于对适应用户个性化偏好的智能代理的需求。在该框架中,代理通过大语言模型驱动,并体现用户的“角色”(例如用户画像或偏好)。为使代理能够利用丰富的上下文信息,我们引入了一种知识图谱增强的检索增强生成机制,该机制构建了基于大语言模型的相关文档图谱索引,并对关联信息社区进行摘要提取。我们的框架通过结合以下两部分生成个性化提示:(1)从知识图谱中提取的用户历史行为与偏好摘要;(2)通过基于图谱的社区检测识别出的相关全局交互模式。这种动态提示工程方法使代理在保持与角色一致行为的同时,能够受益于集体知识。在LaMP基准测试中,相较于现有方法,我们的方法将新闻分类F1值提升了11.1%,电影标注F1值提升了56.1%,并将产品评分平均绝对误差降低了10.4%。代码已发布于https://anonymous.4open.science/r/PersonaAgentwGraphRAG-DE6F。

0
下载
关闭预览

相关内容

语义分割中的深度学习方法全解:从FCN、SegNet到DeepLab
炼数成金订阅号
26+阅读 · 2017年7月10日
国家自然科学基金
4+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
17+阅读 · 2008年12月31日
VIP会员
相关基金
国家自然科学基金
4+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
17+阅读 · 2008年12月31日
Top
微信扫码咨询专知VIP会员