Emergency vehicle (EV) response time is a critical determinant of survival outcomes, yet deployed signal preemption strategies remain reactive and uncontrollable. We propose a return-conditioned framework for emergency corridor optimization based on the Decision Transformer (DT). By casting corridor optimization as offline, return-conditioned sequence modeling, our approach (1) eliminates online environment interaction during policy learning, (2) enables dispatch-level urgency control through a single target-return scalar, and (3) extends to multi-agent settings via a Multi-Agent Decision Transformer (MADT) with graph attention for spatial coordination. On the LightSim simulator, DT reduces average EV travel time by 37.7% relative to fixed-timing preemption on a 4x4 grid (88.6 s vs. 142.3 s), achieving the lowest civilian delay (11.3 s/veh) and fewest EV stops (1.2) among all methods, including online RL baselines that require environment interaction. MADT further improves on larger grids, overtaking DT with 45.2% reduction on 8x8 via graph-attention coordination. Return conditioning produces a smooth dispatch interface: varying the target return from 100 to -400 trades EV travel time (72.4-138.2 s) against civilian delay (16.8-5.4 s/veh), requiring no retraining. A Constrained DT extension adds explicit civilian disruption budgets as a second control knob.
Figures & tables
Method
Online/Offline
Controllable
Multi-agent
EV-specific
Simulator
EMVLight [ 50 ]
Online
×
✓
✓
SUMO
OffLight [ 5 ]
Offline
×
✓
×
CityFlow
DTLight [ 19 ]
Offline → Online
×
✓
×
CityFlow
CoLight [ 61 ]
Online
×
✓
×
CityFlow
PressLight [ 60 ]
Online
×
✓
×
CityFlow
DataLight [ 69 ]
Offline
×
✓
×
CityFlow
Table 1: Comparison of representative RL-based traffic signal control and EV preemption methods. Our DT and MADT are the only methods that combine offline training, return-conditioned controllability, and EV-specific corridor optimization.
Feature
LightSim
SUMO
CityFlow
Traffic model
CTM (macroscopic)
Krauss (microscopic)
SOTL (cell-based)
Speed ( 4×4 )
11,174 steps/s
1,800 steps/s
3,200 steps/s
Speed ( 8×8 )
3,919 steps/s
620 steps/s
1,100 steps/s
RL interface
Gymnasium + PettingZoo
SUMO-RL
CityFlow-RL
EV support
Native EVTracker
Via TraCI
None
Dependencies
NumPy only
SUMO binary
C++ binary
Table 2: Comparison of LightSim, SUMO, and CityFlow across dimensions relevant to RL-based traffic control research. Simulation speeds measured on Intel Xeon Gold 6248, single core.
Figure 1: Network topology of the 4×4 grid used in our primary experiments. Red nodes and thick red edges indicate a representative EV corridor ( K=7 intersections). Each link spans 300 m, discretized into 4 CTM cells of length ℓ=vf⋅Δt=75 m. The EV originates at v4 (northwest) and traverses to v13 (southeast), encountering 7 signalized intersections along its route. Background intersections (gray) operate under the same signal controller but are not part of the EV corridor. Traffic enters and exits the network at all boundary nodes with configurable demand rates (default: 0.10 veh/s per entry point).
Component
Purpose
Weight
Typical magnitude
αΔdt
EV progress per step
α=1.0
0–75 m
−β∑vwv(t)
Queue penalty (civilian disruption)
β=0.01
−0.5 to −3.0
λ1[EV arrived]
Terminal arrival bonus
λ=10.0
0 or 10.0
Table 3: Reward function components, weights, and typical magnitudes on the 4×4 grid.
Figure 2: Architecture overview of the three proposed models. Left: The single-agent DT processes interleaved (return-to-go, state, action) tokens through a causal GPT-style transformer ( L=4 layers, NH=4 heads) to predict per-intersection phase logits. Right: MADT enriches state embeddings via a 2-layer GAT that aggregates neighbor information before the transformer, enabling decentralized inter-intersection coordination. CDT extends the token sequence with a cost-to-go token per timestep (Section 5.7 ), providing a second dispatch control knob.
Figure 3: Training pipeline for the DT-based EV corridor optimizer. Data is collected in LightSim using a mixed-quality behavioral policy (70% expert, 15% random, 15% noisy), producing 5,000 episodes with broad return coverage. The offline dataset is tokenized into (return-to-go, state, action) sequences and used to train the DT via cross-entropy minimization for 100 epochs. At deployment, the trained model receives a dispatcher-specified target return G⋆ and autoregressively generates phase commands at 2.3 ms per step, well within the 5 s control cycle.
Figure 4: Performance comparison of nine methods on the 4×4 grid (100 evaluation episodes). DT (ours) achieves the lowest EV travel time (88.6 s), lowest civilian delay (11.3 s/veh), and fewest EV stops (1.2), all without online environment interaction. Error bars show ± 1 standard deviation. Numerical values are in Table 4 .
Method
ETT (s) ↓
ACD (s/veh) ↓
Throughput ↑
EV Stops ↓
Rule-based
FT-EVP
142.3±18.5
12.4±2.1
1842±156
4.2±1.3
Greedy
98.7±12.3
18.6±3.4
1654±189
1.8±0.9
MaxPressure
118.7±16.2
11.9±2.0
1912±145
3.1±1.2
Online RL
DQN
108.4±15.7
14.2±2.8
1789±167
2.4±1.1
Table 4: Results on 4×4 grid (mean ± std over 100 evaluation episodes). Best bold , second-best underlined . ETT is in seconds; ACD is average civilian delay in seconds per vehicle. Baselines are grouped by type: rule-based, online RL, and offline methods.
Figure 5: Return conditioning sweep on the 4×4 grid (100 episodes per G⋆ value). Varying G⋆ from 100 (aggressive corridor) to −400 (conservative) produces a smooth, monotonic trade-off: ETT ranges from 72.4 s to 138.2 s while ACD ranges from 16.8 to 5.4 s/veh. The shaded region marks the operational sweet spot ( G⋆∈[−100,0] ) where both metrics are near-optimal. See Table 5 for exact values.
G⋆
ETT (s) ↓
ACD (s/veh) ↓
Throughput ↑
100
72.4
16.8
1642
50
78.1
14.3
1724
0
88.6
11.3
1897
−50
96.3
9.8
1956
−100
108.7
8.2
2014
−200
124.5
6.7
2089
Table 5: Return conditioning sweep on 4×4 grid. Varying G⋆ trades EV speed against civilian delay in a smooth, monotonic fashion. All values are mean over 100 episodes.
Figure 6: Scalability of EV travel time across three grid sizes ( 4×4 , 6×6 , 8×8 ; 100 episodes each). Both DT and MADT consistently outperform FT-EVP by 35–45%. MADT overtakes DT starting at the 6×6 grid (4.8% advantage), with the gap widening to 8.9% on 8×8 , demonstrating the growing benefit of GAT-based coordination. See Table 6 for exact values.
Grid
DT ETT (s)
MADT ETT (s)
FT-EVP ETT (s)
DT Impr.
MADT Impr.
4×4
88.6
92.4
142.3
37.7%
35.1%
6×6
156.2
148.7
268.4
41.8%
44.6%
8×8
248.5
226.3
412.7
39.8%
45.2%
Table 6: Scalability results. ETT in seconds (mean over 100 episodes). Improvement is relative to FT-EVP. MADT overtakes DT on 6×6 + grids.
Figure 7: Ablation study on the 4×4 grid (100 episodes per variant). Bars show ETT relative to the full DT model (88.6 s). Expert-only data causes the largest degradation ( +33.7% ), followed by removing return conditioning ( +26.7% ), short context ( +18.3% ), and a shallower model ( +9.8% ). See Table 7 for ACD values.
Variant
ETT (s) ↓
ACD (s/veh) ↓
Δ ETT
DT (full)
88.6
11.3
—
w/o return cond.
112.3
13.7
+26.7%
context C=5
104.8
12.9
+18.3%
expert-only data
118.5
14.1
+33.7%
2 layers (vs. 4)
97.3
12.2
+9.8%
Table 7: Ablation study on 4×4 grid (100 evaluation episodes). Δ is relative change in ETT compared to the full model.
Composition
ETT (s) ↓
ACD (s/veh) ↓
100/0/0 (expert-only)
118.5
14.1
90/5/5
96.2
12.4
70/15/15 (ours)
88.6
11.3
50/25/25
91.4
11.7
30/35/35
98.7
12.5
0/50/50 (no expert)
126.3
15.2
Table 8: Dataset composition sweep on 4×4 grid (100 episodes). Expert/Random/Noisy proportions (%). The 70/15/15 mix achieves the best ETT.
Variant
4×4
6×6
8×8
MADT (full, C=20 )
92.4
148.7
226.3
w/o GAT ( C=20 )
91.1
162.8
258.1
C=30 + GAT
89.8
144.3
219.7
DT (single-agent, C=30 )
88.6
156.2
248.5
Table 9: MADT ablation across grid sizes (ETT in seconds, 100 episodes). Removing GAT degrades performance sharply on 6×6 + grids, confirming that inter-agent coordination, not context length, drives MADT’s scalability advantage.
Figure 8: CDT two-knob dispatch interface on the 4×4 grid. The heatmap shows average civilian delay (s/veh) across 9 combinations of return target G⋆ (columns) and cost budget C⋆ (rows), each averaged over 100 episodes. Tight budgets ( C⋆=0 ) cap civilian delay at 5.2–5.8 s/veh regardless of G⋆ ; loose budgets ( C⋆=−100 ) allow G⋆ to modulate disruption freely (8.4–14.2 s/veh). EV travel time remains within 82–94 s across all configurations.
Position
DT delay (s)
FT-EVP delay (s)
Savings (s)
Mechanism
1–3 (near origin)
8.2
14.8
6.6
Early green activation
4–5 (mid-route)
12.4
24.7
12.3
Pre-clearance of queues
6–7 (near destination)
6.8
11.2
4.4
Residual green wave
Total (7 intersections)
27.4
50.7
23.3
—
Table 10: Per-intersection delay decomposition on 4×4 grid (DT at G⋆=0 , mean over 100 episodes). Mid-route intersections contribute the most delay; DT achieves its largest savings at these locations by anticipating congestion and pre-clearing queues.
Demand (veh/s)
DT ETT (s)
FT-EVP ETT (s)
DT Impr.
DT ACD (s/veh)
0.05 (low)
78.2
124.6
37.2%
6.4
0.10 (medium)
88.6
142.3
37.7%
11.3
0.20 (high)
108.4
178.5
39.3%
18.7
0.30 (heavy)
134.7
215.2
37.4%
28.4
Table 11: Congestion sensitivity on 4×4 grid (100 episodes per demand level). DT maintains consistent improvement over FT-EVP (37–39%) across all demand levels. All models trained on the medium demand dataset.
Figure 9: Space-time diagram of a representative EV trajectory on the 4×4 grid, comparing DT ( G⋆=0 ), FT-EVP, and Greedy Preemption. The vertical axis represents the EV’s position along its 7-intersection route (from origin v4 to destination v13 ); the horizontal axis is elapsed simulation time (seconds). Green bands indicate EV-compatible signal phases at each intersection; red bands indicate red phases for the EV approach. DT exhibits a smooth “staircase” trajectory with only 1 brief stop at intersection v10 , reaching the destination at t=87 s. FT-EVP shows 4 stops (vertical flat segments) totaling 50.7 s of intersection delay. Greedy Preemption has fewer stops (2) but creates visible queue buildups (shaded gray regions) at cross-traffic approaches. DT’s anticipatory green-wave activation is visible as green bands that begin 10–15 s before the EV reaches each intersection, contrasting with FT-EVP’s reactive phase changes that occur only upon EV detection.
Grid
DT Train (min)
DT Infer (ms/step)
MADT Infer (ms/step)
Memory (MB)
4×4
12.3
2.3
4.1
245
6×6
28.7
3.1
6.8
512
8×8
51.4
4.2
8.7
891
Table 12: Runtime analysis across grid sizes (NVIDIA A100 GPU). All latencies are well within the 5 s control cycle. Training times reflect 100 epochs on 5,000 episodes.
Comparison
ETT p -value
ACD p -value
DT vs. PPO
0.003
0.018
DT vs. CQL
< 0.001
0.004
DT vs. IQL
< 0.001
0.009
DT vs. MaxPressure
< 0.001
0.142
DT vs. MADT ( 4×4 )
0.087
0.231
MADT vs. DT ( 8×8 )
< 0.001
0.015
Table 13: Statistical significance (Welch’s t -test, two-tailed) for key pairwise comparisons on the 4×4 grid (100 episodes per method). Comparisons with p<0.05 are statistically significant.
Appendix figures & tables4 assets
Supplementary material from the paper’s appendix.
Appendix
Parameter
DT
MADT
Hidden dim d
128
128
Layers L
4
3
Heads NH
4
4
Context C
30
20
GAT layers
—
2
GAT heads
—
4
Appendix
Table 14: Full hyperparameter settings for DT and MADT. Both models use AdamW optimization with identical learning rate and weight decay. MADT uses fewer transformer layers but adds 2 GAT layers for spatial coordination.
Figure 10: Training loss curves for three DT variants over 100 epochs on the 4×4 dataset. The full DT converges within 15 epochs. Expert-only data overfits (loss approaches 0) due to limited trajectory diversity. The w/o RTG variant converges at a similar rate to the full model but generalizes worse at evaluation (Table 7 ).
Parameter
Values tested
Best ETT (s)
Worst ETT (s)
Optimal
Hidden dim d
32, 64, 128, 256
88.6 ( d=128 )
102.4 ( d=32 )
128
Layers L
1, 2, 3, 4, 6
88.6 ( L=4 )
97.3 ( L=2 )
4
Context C
5, 10, 20, 30, 50
86.9 ( C=50 )
104.8 ( C=5 )
50
Learning rate
10−3 , 5×10−4 , 10−4 , 5×10−5
88.6 ( 10−4 )
118.3 ( 10−3 )
10−4
Batch size
16, 32, 64, 128
87.2 (128)
92.8 (16)
128
Appendix
Table 15: Hyperparameter sensitivity sweep on 4×4 grid (100 episodes per configuration). Each row varies one parameter while holding all others at default values. Performance is stable across most settings, with context length C and learning rate having the largest impact.
Symbol
Definition
Typical value
Section
Network and traffic
G=(V,E)
Traffic network graph
4×4 to 8×8 grid
4
V
Set of signalized intersections
∣V∣∈{16,36,64}
4
E
Set of road segments (edges)
—
4
ni(t)
Vehicle count in cell i at time t
0 – 11 vehicles
3.1
nimax
Cell capacity (maximum vehicles)
11 vehicles
3.1
Appendix
Table 16: Notation reference. All symbols are listed with their definitions, typical values in our experiments, and the section where they are first introduced.
Traffic signal control studies how to set intersection phases and green times to reduce congestion while balancing safety, emissions, and priority needs.