用大模型当优化器,轻松搞定复杂仿真模型校准。
Agentic Calibration of Grey-Box Simulation Models: An LLM-Driven Alternative
- 让大模型直接当优化器,通过自然语言描述约束条件
- 比传统方法少调几次就能达到更好精度,约束下也表现优秀
- 过程可解释,适合需要透明决策的医疗仿真场景
灰色框仿真模型的校准是一个受限优化问题:模型评估成本高、参数空间维度高,且需满足合理性约束。尽管模拟代码对分析者完全开放,但多个参数的联合效应仍难以解析预测。经典优化器如Nelder-Mead(NM)部署简单但采样效率低,尤其在有约束时;现代贝叶斯优化(BO)虽以更少评估次数获得较优解,但需复杂建模处理约束。本文提出一种代理型校准方法:由大语言模型充当优化器,将约束以自然语言形式嵌入系统提示中。我们在无约束与临床约束条件下,对宫颈癌仿真模型测试了该方法、NM和BO。无约束时,该方法误差显著低于BO和NM,且所需评估次数更少;有约束时,其误差水平与两者相当,均优于NM。代价是每次迭代推理时间增加。该方法在仿真耗时主导的场景下尤为适用,不仅性能优异,且每轮搜索逻辑可追溯、可解释,便于向第三方说明决策依据。
原文摘要 · Abstract (English)
Calibration of grey-box simulation models is a constrained optimization problem in which model evaluations are expensive, the parameter space can be high-dimensional, and the search must respect plausibility constraints. Although the simulation code is fully available to the analyst, the joint effect of multiple parameters remains difficult to predict analytically. Classical optimizers such as Nelder--Mead (NM) are simple to deploy but sample-inefficient, particularly under constraints. Modern Bayesian Optimization methods achieve competitive solutions with far fewer evaluations but require non-trivial modeling machinery for constraint handling. We introduce an agentic calibration method in which a large language model acts as the optimizer, with constraints incorporated as a plain-language section of the system prompt. We evaluate the agentic method, NM, and Bayesian Optimization (BO) on an anal cancer simulation model under both unconstrained and clinically constrained calibration. Under unconstrained calibration, the agentic method achieves substantially lower best error than BO and NM, while requiring fewer model evaluations. Under constrained calibration, the agentic method reaches comparable error levels and both outperform NM. These results are obtained at the cost of increased inference time per iteration. Agentic calibration achieves competitive performance with substantially fewer model evaluations, and constraint handling is essentially free at the modeller-facing interface through simple textual specifications rather than additional modelling machinery. The main trade-off lies in increased per-iteration inference cost, making the approach particularly suitable when simulation time dominates. Beyond performance, the per-iteration rationale makes the search auditable and explainable, so its decisions can be scrutinised and justified to third parties.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。