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%의 컴파일 성공률을 달성했다.
핵심 기여도
- 첫 번째 반복적 RAG 기반 DSL 시나리오 생성 프레임워크 제안 (Chat2Scenic).
- 컴파일 성공률 76.42%, 프레임워크 정확도 58.17% 달성.
- 123개 규제 기반 시나리오로 구성된 오픈 벤치마크 제안.
- 기존 방법 대비 CSR 46.36%P, FA 47.14%P 개선.
핵심 아이디어
기존 시나리오 생성 방법은 두 가지 주요 제약을 가진다. Retrieval-assemble 방법은 컴파일률은 높지만 확장성이 낮고, Retrieval-based full-script generation은 컴파일 성공률이 낮다. Chat2Scenic은 이 문제를 반복적 RAG 프레임워크로 해결한다. 사용자와의 대화를 통해 시나리오를 반복적으로 수정하고, RAG를 통해 규제 지식과 DSL 구문을 기반으로 생성한다. 이는 단순한 텍스트 생성을 넘어, 실행 가능한 DSL 스크립트를 생성하는 데 초점을 맞춘다.
기술적 접근법
- **DSL 기반 스크립트 생성**: Scenic 언어를 사용한 실행 가능한 시나리오 생성.
- **RAG 통합**: 규제 문서와 DSL 구문을 검색하여 생성 과정에 통합.
- **인터랙티브 인터페이스**: 사용자 피드백을 반복적으로 통합하는 챗봇 기반 UI.
- **SOTA LLM 활용**: 최신 대형 언어 모델을 기반으로 평가 수행.
- **하이퍼파라미터**: 명시되지 않음.
주요 결과
- **123개 규제 기반 시나리오 데이터셋**에서 Chat2Scenic은 **76.42% CSR** (기존 Retrieval Assemble: 30.08%)와 **58.17% FA** (기존 Retrieval full script generation: 10.86%)를 달성.
- CSR 기준, Retrieval Assemble 대비 +46.36%, Retrieval full script generation 대비 +60.16% 개선.
- FA 기준, Retrieval Assemble 대비 +47.14%, Retrieval full script generation 대비 +47.31% 개선.
의의 및 한계
Chat2Scenic은 규제 기반 시나리오 생성의 정확성과 실행 가능성 사이의 균형을 맞춘 첫 번째 시도로, 자율주행 시스템 검증의 자동화를 촉진할 수 있다. 특히, RAG와 DSL 통합은 기존 방법의 한계를 극복하며, 사용자 피드백을 통한 반복적 개선은 실용성 향상에 기여한다. 그러나, 사용자 인터페이스의 복잡성이나 규제 문서의 질에 따라 성능이 변동될 수 있는 한계가 있다.
실용적 활용
Chat2Scenic은 자율주행 시스템 개발사가 규제 기반 시나리오를 자동으로 생성하고 검증할 수 있도록 지원하며, 특히 시뮬레이션 기반 테스트 환경에서 유용하게 활용될 수 있다. 또한, 규제 준수를 요구하는 다른 산업 분야에도 적용 가능하다.