KERL:基于大语言模型的知识增强型个性化菜谱推荐系统
KERL: Knowledge-Enhanced Personalized Recipe Recommendation using Large Language Models
May 20, 2025
作者: Fnu Mohbat, Mohammed J Zaki
cs.AI
摘要
近期,大型语言模型(LLMs)的进展与海量食品数据的涌现,推动了利用LLMs提升食品理解的研究。尽管已有多个推荐系统结合了LLMs与知识图谱(KGs),但将食品相关KGs与LLMs整合的研究仍较为有限。我们提出了KERL,一个统一系统,它利用食品KGs与LLMs提供个性化食品推荐,并生成附带微量营养信息的食谱。面对自然语言提问,KERL首先提取实体,从KG中检索子图,随后将这些子图作为上下文输入LLM,以筛选出满足约束条件的食谱。接着,我们的系统为每个食谱生成烹饪步骤及营养信息。为评估该方法,我们还开发了一个基准数据集,通过整理与食谱相关的问题,结合约束条件与个人偏好。通过大量实验,我们证明了所提出的KG增强型LLM显著优于现有方法,为食品推荐、食谱生成及营养分析提供了一个完整且连贯的解决方案。我们的代码与基准数据集已公开于https://github.com/mohbattharani/KERL。
English
Recent advances in large language models (LLMs) and the abundance of food
data have resulted in studies to improve food understanding using LLMs. Despite
several recommendation systems utilizing LLMs and Knowledge Graphs (KGs), there
has been limited research on integrating food related KGs with LLMs. We
introduce KERL, a unified system that leverages food KGs and LLMs to provide
personalized food recommendations and generates recipes with associated
micro-nutritional information. Given a natural language question, KERL extracts
entities, retrieves subgraphs from the KG, which are then fed into the LLM as
context to select the recipes that satisfy the constraints. Next, our system
generates the cooking steps and nutritional information for each recipe. To
evaluate our approach, we also develop a benchmark dataset by curating recipe
related questions, combined with constraints and personal preferences. Through
extensive experiments, we show that our proposed KG-augmented LLM significantly
outperforms existing approaches, offering a complete and coherent solution for
food recommendation, recipe generation, and nutritional analysis. Our code and
benchmark datasets are publicly available at
https://github.com/mohbattharani/KERL.