发表机构
Swansea University(斯旺西大学)
机构由 AI 辅助整理,请以论文原文为准。AI 中文总结
研究针对计算营养中成分数据问题,提出结合统计估计、不变性检查和网络获取的大语言模型管道。通过该管道可获取精确数据,在参考集上实现高匹配度并大幅降低误差,将大语言模型辅助数据库构建变为可控流程。
AI 中文摘要
计算营养需要精确的成分数据,但当前数据库不完整、不一致,且是为人类参考而非自动推理构建。大语言模型可填补这些空白,但单遍输出不可靠且会在下游计算中引入隐性错误。我们提出一种用于成分数据获取的质量控制大语言模型管道,它结合了稳健的统计估计、特定领域不变性检查和网络获取备用方案。对233个食谱的说明性赫普定律拟合表明,独特成分增长呈次线性且前端加载。对于每个成分属性,重复的大语言模型查询被视为来自模型诱导答案分布的样本,我们在数值、布尔、多项选择、开放分类和可选整数类型上应用稳健的点估计器和标准化置信分数。不变保护层在每个成分记录内强制营养和逻辑自洽。较小的数值不一致通过线性规划协调,重大违规则升级到基于网络证据的修复,仅在失败时进行人工审核。在一个精心策划的30成分参考集上,该管道在营养标志上实现了98.4%的精确匹配,并将营养比的中位数绝对百分比误差从中位数聚合基线的31.9%降至10.1%,降低了21.8个百分点,每个成分的API成本约为1美元。这将大语言模型辅助的数据库构建框架为一个可控的数据工程工作流程,使不确定性可操作而非丢弃。
英文摘要
Computational nutrition needs precise ingredient data, but current databases are incomplete, inconsistent, and built for human reference rather than automated reasoning. LLMs could help fill these gaps, but single-pass outputs are unreliable and can introduce silent errors into downstream computation. We present a quality-controlled LLM pipeline for ingredient data acquisition that combines robust statistical estimation, domain-specific invariant checks, and a web-fetch fallback. An illustrative Heap's Law fit to 233 recipes suggests that unique-ingredient growth is sub-linear and front-loaded: the projected ratio of unique ingredients to recipes falls from 1.74 at 100 recipes to 0.19 at 5,000. For each ingredient attribute, repeated LLM queries are treated as samples from a model-induced answer distribution, and we apply robust point estimators and normalised confidence scores across numerical, Boolean, multiple-choice, open categorical, and optional integer types. An invariant guard layer enforces nutritional and logical self-consistency within each ingredient record. Minor numeric inconsistencies are reconciled via a linear program that minimises worst-case percentage deviation while preserving semantic zeros, and major violations are escalated to web-evidence-grounded repair, then human review only if that fails. On a curated 30-ingredient reference set, the pipeline achieves 98.4% exact match on nutrient flags and cuts median absolute percentage error on nutrient ratios from 31.9% for the median-aggregated baseline to 10.1%, a reduction of 21.8 percentage points, at an API cost of about $1 per ingredient. This frames LLM-assisted database construction as a controlled data-engineering workflow that makes uncertainty operational rather than discarding it.