Retrieval Augmented Generation-Enhanced Distributed LLM Agents for Generalizable Traffic Signal Control with Emergency Vehicles
Xinhang Li, Qing Guo, Junyu Chen, Zheng Guo, Shengzhe Xu, Lei Li, Lin Zhang
TL;DR
This work tackles the challenge of generalizable traffic signal control with emergency vehicles by leveraging Retrieval Augmented Generation (RAG) and distributed LLM agents. It introduces REG-TSC, an emergency-aware framework that uses Reviewer-Based Emergency RAG (RERAG) to distill historical guidance and a type-agnostic traffic representation to handle heterogeneous intersections, augmented by Reward-Guided Reinforced Refinement (R^3) for cross-intersection generalization. The training pipeline combines imitation fine-tuning and reward-weighted reinforcement to align policies with high-reward coordinates across scenarios. Experiments on three real-world networks show REG-TSC significantly reduces travel time, queue lengths, and emergency-vehicle waiting times, indicating high potential for deployable, reliable TSC in complex urban environments.
Abstract
With increasing urban traffic complexity, Traffic Signal Control (TSC) is essential for optimizing traffic flow and improving road safety. Large Language Models (LLMs) emerge as promising approaches for TSC. However, they are prone to hallucinations in emergencies, leading to unreliable decisions that may cause substantial delays for emergency vehicles. Moreover, diverse intersection types present substantial challenges for traffic state encoding and cross-intersection training, limiting generalization across heterogeneous intersections. Therefore, this paper proposes Retrieval Augmented Generation (RAG)-enhanced distributed LLM agents with Emergency response for Generalizable TSC (REG-TSC). Firstly, this paper presents an emergency-aware reasoning framework, which dynamically adjusts reasoning depth based on the emergency scenario and is equipped with a novel Reviewer-based Emergency RAG (RERAG) to distill specific knowledge and guidance from historical cases, enhancing the reliability and rationality of agents' emergency decisions. Secondly, this paper designs a type-agnostic traffic representation and proposes a Reward-guided Reinforced Refinement (R3) for heterogeneous intersections. R3 adaptively samples training experience from diverse intersections with environment feedback-based priority and fine-tunes LLM agents with a designed reward-weighted likelihood loss, guiding REG-TSC toward high-reward policies across heterogeneous intersections. On three real-world road networks with 17 to 177 heterogeneous intersections, extensive experiments show that REG-TSC reduces travel time by 42.00%, queue length by 62.31%, and emergency vehicle waiting time by 83.16%, outperforming other state-of-the-art methods.
