Chat2Scenic: An Iterative RAG-Based Framework for Scenario Generation in Autonomous Driving

Yuan Gao, Wenting Miao, Mattia Piccinini, Haoyu Wang, Qunying Song, Johannes Betz

arXiv:2607.14387 · 2026-07-19 공개 · arXiv · PDF

llm-evaluation retrieval-augmented autonomous-driving scenario-generation iterative-framework regulatory-compliance dsl-syntax chatbot-interface

Abstract

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.

한국어 요약

한 줄 요약

Chat2Scenic은 자율주행 시스템 시나리오 생성을 위한 반복적 RAG 기반 프레임워크로, 76.42%의 컴파일 성공률을 달성했다.

핵심 기여도

핵심 아이디어

기존 시나리오 생성 방법은 두 가지 주요 제약을 가진다. Retrieval-assemble 방법은 컴파일률은 높지만 확장성이 낮고, Retrieval-based full-script generation은 컴파일 성공률이 낮다. Chat2Scenic은 이 문제를 반복적 RAG 프레임워크로 해결한다. 사용자와의 대화를 통해 시나리오를 반복적으로 수정하고, RAG를 통해 규제 지식과 DSL 구문을 기반으로 생성한다. 이는 단순한 텍스트 생성을 넘어, 실행 가능한 DSL 스크립트를 생성하는 데 초점을 맞춘다.

기술적 접근법

주요 결과

의의 및 한계

Chat2Scenic은 규제 기반 시나리오 생성의 정확성과 실행 가능성 사이의 균형을 맞춘 첫 번째 시도로, 자율주행 시스템 검증의 자동화를 촉진할 수 있다. 특히, RAG와 DSL 통합은 기존 방법의 한계를 극복하며, 사용자 피드백을 통한 반복적 개선은 실용성 향상에 기여한다. 그러나, 사용자 인터페이스의 복잡성이나 규제 문서의 질에 따라 성능이 변동될 수 있는 한계가 있다.

실용적 활용

Chat2Scenic은 자율주행 시스템 개발사가 규제 기반 시나리오를 자동으로 생성하고 검증할 수 있도록 지원하며, 특히 시뮬레이션 기반 테스트 환경에서 유용하게 활용될 수 있다. 또한, 규제 준수를 요구하는 다른 산업 분야에도 적용 가능하다.