Chat2Scenic:一种基于检索增强生成的迭代式自动驾驶场景生成框架
Chat2Scenic: An Iterative RAG-Based Framework for Scenario Generation in Autonomous Driving
July 15, 2026
作者: Yuan Gao, Wenting Miao, Mattia Piccinini, Haoyu Wang, Qunying Song, Johannes Betz
cs.AI
摘要
验证自动驾驶系统需要多样化且符合法规的测试场景。在基于仿真的测试中,场景被定义为可执行脚本。然而,从法规描述中自动生成此类脚本仍是一个开放性挑战,现有方法面临根本性权衡。检索-组合方法虽能达到合理的编译成功率,但缺乏可扩展性;而基于检索的完整脚本生成则面临编译成功率低的问题。我们提出Chat2Scenic,首个采用迭代检索增强的框架,用于生成领域特定语言(DSL)的场景脚本。具体而言,Chat2Scenic提供支持交互式场景优化的聊天机器人界面,并集成检索增强生成(RAG)技术,使场景生成基于法规知识与DSL语法。此外,我们提出了一个开放的场景生成基准测试,包含来自美国国家公路交通安全管理局(NHTSA)、联合国车辆法规及其他来源的123个场景。基于最先进大语言模型的广泛评估表明,Chat2Scenic实现了76.42%的编译成功率与58.17%的框架准确率,显著优于现有方法(检索-组合方法编译成功率30.08%、框架准确率11.03%;检索全脚本生成编译成功率16.26%、框架准确率10.86%)。为促进后续研究,我们已将代码开源至https://github.com/TUM-AVS/chat2scenic。
English
Validating autonomous driving systems requires diverse, regulation-compliant test scenarios. In simulation-based testing, scenarios are defined as executable scripts. Yet automatically generating such scripts from regulatory descriptions remains an open challenge, and existing approaches face fundamental trade-offs. Retrieval-assemble methods achieve reasonable compilation rates but lack scalability, whereas retrieval-based full-script generation suffers from low compilation success rates. We present Chat2Scenic, the first iterative retrieval-augmented framework to generate scenario scripts in Domain Specific Language (DSL). Specifically, Chat2Scenic provides a chatbot interface that supports interactive scenario refinement and integrates Retrieval-augmented Generation (RAG) to ground scenario generation in regulatory knowledge and DSL syntax. Furthermore, we propose an open benchmark for scenario generation comprising 123 scenarios from various regulations, including NHTSA and United Nations Vehicle Regulations, as well as other sources. Extensive evaluation with State-of-the-Art (SOTA) Large Language Models (LLMs) demonstrates that Chat2Scenic achieves 76.42% Compilation Success Rate (CSR) and 58.17% Framework Accuracy (FA), outperforming existing methods (Retrieval Assemble with 30.08% CSR, 11.03% FA and Retrieval full script generation with 16.26% CSR, 10.86% FA). To facilitate future research, we release our code as open source at https://github.com/TUM-AVS/chat2scenic.