SanDRA: Safe Large-Language-Model-Based Decision Making for Automated Vehicles Using Reachability Analysis
Yuanfei Lin, Sebastian Illing, Matthias Althoff
TL;DR
This work tackles the safety problem of deploying large language models (LLMs) for automated vehicle decision making by marrying LLM-driven action generation with formal reachability analysis. SanDRA prompts LLMs to produce and rank candidate longitudinal-lateral actions, translates those actions into $LTL_{\text{f}}$ formulas, and verifies them against both most likely and set-based predictions using reachability and model checking; formalized traffic rules are conjoined to ensure legal safety, with a fail-safe plan guaranteeing infinite-horizon safety when needed. The approach yields provable safety guarantees and improved rule compliance, while enabling downstream trajectory planners to operate within verified safe corridors; it demonstrates strong performance in open- and closed-loop evaluations and shows practicality via public code release. The framework reduces reliance on large labeled datasets for decision making, offers a transparent safety layer around LLM reasoning, and paves the way for safer integration of learning-based components in autonomous driving. Overall, SanDRA provides a principled, extensible pathway to deploy LLM-based decision making in automated vehicles without sacrificing formal safety guarantees or legal compliance.
Abstract
Large language models have been widely applied to knowledge-driven decision-making for automated vehicles due to their strong generalization and reasoning capabilities. However, the safety of the resulting decisions cannot be ensured due to possible hallucinations and the lack of integrated vehicle dynamics. To address this issue, we propose SanDRA, the first safe large-language-model-based decision making framework for automated vehicles using reachability analysis. Our approach starts with a comprehensive description of the driving scenario to prompt large language models to generate and rank feasible driving actions. These actions are translated into temporal logic formulas that incorporate formalized traffic rules, and are subsequently integrated into reachability analysis to eliminate unsafe actions. We validate our approach in both open-loop and closed-loop driving environments using off-the-shelf and finetuned large language models, showing that it can provide provably safe and, where possible, legally compliant driving actions, even under high-density traffic conditions. To ensure transparency and facilitate future research, all code and experimental setups are publicly available at github.com/CommonRoad/SanDRA.
