Liu E, Yang H, Sharma S, van Leerdam M B, Niu P, VandeHaar M J, Hostens M
Department of Animal Science, Cornell University, Ithaca, NY 14850.
Department of Animal Science, Cornell University, Ithaca, NY 14850.
J Dairy Sci. 2025 Sep 11. doi: 10.3168/jds.2025-26775.
Large language models (LLM) hold significant promise to transform dairy science by enhancing research interpretation, supporting decision making, and improving knowledge dissemination. However, without proper systematic design, LLM may generate irrelevant or factually inaccurate responses for domain-specific questions. Moreover, most existing LLM and related tools are not tailored to the needs of the dairy domain, limiting their practical application within the field. To demonstrate the feasibility and practical value of embracing LLM in dairy science, we developed a 2-component agentic system: (1) a decision-support chatbot grounded in the Journal of Dairy Science (JDS) for science-backed insights and (2) a natural language interface for interacting with academic models and visualizing prediction results. All publicly available JDS abstracts and associated metadata dating back to 1917 were compiled using the PubMed application programming interface, forming a scientific knowledge base that enables the chatbot to answer user questions. A retrieval-augmented generation framework was implemented to ensure that responses generated by LLaMA (a LLM developed by Meta) were well-grounded in peer-reviewed literature, with the 5 most relevant sources cited alongside each answer. To address questions beyond the coverage of JDS literature, a web search agent was incorporated into the system to retrieve supplementary information from external online sources. Grading agents, powered by Databricks Research Transformer X (DBRX; a LLM developed by Databricks), were incorporated to evaluate the credibility and relevance of LLM-generated content to mitigate the risk of misinformation or hallucinated responses. The second component of the system facilitates natural language interaction with MilkBot, a published Bayesian milk yield prediction model. After users submit questions in plain language, the system converts the question into model parameters for MilkBot, executes the model prediction, and uses the predicted output to generate visualizations. This work demonstrates the capability of LLM to serve as intuitive, user-friendly interfaces for dairy-specific models. To our knowledge, this is the first chatbot prototype that integrates large-scale information from scientific literature, web-based resources, and academic models, along with self-evaluation capability, to provide dairy-specific insights to scholars, consultants, and farmers. However, challenges remain to realize the full value of LLM-assisted decision making, such as the lack of region-specific data to tailor the answers to the local circumstances, the need for more robust measures to protect data security and privacy, and the need to integrate additional functions to enable more comprehensive decision support.
大型语言模型(LLM)在通过加强研究解读、支持决策制定和改善知识传播来变革乳品科学方面具有重大前景。然而,如果没有适当的系统设计,LLM可能会针对特定领域的问题生成不相关或事实不准确的回答。此外,大多数现有的LLM和相关工具并非针对乳品领域的需求定制,限制了它们在该领域的实际应用。为了证明在乳品科学中采用LLM的可行性和实际价值,我们开发了一个由两部分组成的智能系统:(1)一个基于《乳品科学杂志》(JDS)的决策支持聊天机器人,用于提供有科学依据的见解;(2)一个自然语言界面,用于与学术模型交互并可视化预测结果。使用PubMed应用程序编程接口汇编了所有可公开获取的、可追溯到1917年的JDS摘要及相关元数据,形成了一个科学知识库,使聊天机器人能够回答用户问题。实施了一个检索增强生成框架,以确保由Meta开发的LLM——LLaMA生成的回答有同行评审文献作为充分依据,每个答案旁边会列出5个最相关的来源。为了解决超出JDS文献涵盖范围的问题,系统中纳入了一个网络搜索代理,以从外部在线来源检索补充信息。由Databricks Research Transformer X(DBRX;Databricks开发的一个LLM)驱动的评分代理被纳入,以评估LLM生成内容的可信度和相关性,从而降低错误信息或幻觉回答的风险。该系统的第二部分促进了与已发表的贝叶斯产奶量预测模型MilkBot的自然语言交互。用户以通俗易懂的语言提交问题后,系统将问题转换为MilkBot的模型参数,执行模型预测,并使用预测输出生成可视化结果。这项工作展示了LLM作为特定于乳品的模型的直观、用户友好界面的能力。据我们所知,这是第一个整合了来自科学文献、基于网络的资源和学术模型的大规模信息以及自我评估能力,为学者、顾问和农民提供特定于乳品的见解的聊天机器人原型。然而,要实现LLM辅助决策的全部价值仍存在挑战,例如缺乏针对当地情况定制答案的特定区域数据,需要更有力的措施来保护数据安全和隐私,以及需要整合更多功能以提供更全面的决策支持。