FaultGene: LLM-Assisted Fault-Augmented Test Generation for Hardware-in-the-Loop Validation of Autonomous Driving Systems
Organizations: Center for Embedded and Cyber-Physical Systems, University of California, Irvine, Irvine, USA
Abstract
Reliable validation of autonomous driving cyber-physical systems requires testing not only nominal driving behavior but also failures arising from faults in sensing and embedded computation. Physical road testing provides realistic system behavior but is costly and difficult to reproduce, while simulation enables scalable evaluation but cannot fully capture hardware-dependent behavior and fault propagation. Hardware-in-the-loop (HIL) validation bridges this gap by executing the driving stack on real embedded hardware within a simulated environment. However, preparing fault-augmented scenarios for HIL testing remains largely a manual process, limiting test coverage, scalability, and efficiency. We present FaultGene, an LLM-assisted framework for automated generation of executable fault-augmented tests for HIL fault-resilience validation. Given a baseline Scenic/CARLA scenario and a structured fault specification, FaultGene generates a fault-augmented test case that captures the effects of HIL-level fault injection. During offline refinement, semantic-consistency checks and execution-level feedback are used to correct candidates that fail to preserve the intended scenario context or produce the desired fault-induced degradation, and to construct high-quality supervision for fine-tuning. The resulting generator then produces fault-augmented tests directly at deployment time without requiring manually engineered reference executions or repeated refinement loops.
Figures & tables
| System | Method | Semantic Alignment | Compilation | Execution Success |
|---|---|---|---|---|
| Score* | Success(%) | Among Compiled(%) | ||
| Modular | One-shot LLM | 0.45 | 68 | 81 |
| Modular | Fine-tuned FaultGene Generator | 0.89 | 96 | 93 |
| End-to-end | One-shot LLM | 0.43 | 71 | 74 |
| End-to-end | Fine-tuned FaultGene Generator | 0.86 | 94 | 90 |
| System | Source | Scenario | 1% | 2% | 5% | 10% |
|---|---|---|---|---|---|---|
| Modular | ADDT | Large-curv. turning | 100.00% | 99.58% | 96.25% | 88.75% |
| Vehicle following | 99.58% | 99.58% | 97.92% | 94.16% | ||
| Overtaking | 97.08% | 87.50% | 73.75% | 54.58% | ||
| FaultGene | Large-curv. turning | 99.58% | 98.60% | 94.83% | 86.18% | |
| Vehicle following | 97.92% | 96.05% | 95.91% | 92.37% | ||
| Overtaking | 94.83% | 85.25% | 71.69% | 62.33% |
| Metric | Manual ADDT | FaultGene + ADDT* | FaultGene benefit |
|---|---|---|---|
| Fault-scenario preparation | Manual engineering | Single-pass generation | Automated preparation |
| Preparation per fault type | 12 h | 10 min | 72 preparation-time speedup |
| Preparation for 20 fault types | 240 h | 3.33 h | 72 preparation-time speedup |
| Setup + execution for 1,000 runs | 200 h | 200 h | Unchanged HIL run time |
| Total campaign time | 440 h | 203.33 h | 2.16 speedup; 53.8% less time |
Automated Test Generation
Automated test generation creates inputs, scenarios, and checks to expose software and system defects with less manual effort.
See all 132 papers