arXiv:2510.13002cs.AIcs.LG2025-10

用大模型自动分析车祸描述,精准识别司机危险行为。

From Narratives to Probabilistic Reasoning: Predicting and Interpreting Drivers' Hazardous Actions in Crashes Using Large Language Model

  • 用微调的Llama 3.2模型从文本中自动推断危险驾驶行为。
  • 准确率达80%,在数据不平衡场景下优于传统机器学习模型。
  • 通过反事实分析揭示分心、年龄对危险行为概率的影响,可解释性强。

车辆碰撞涉及道路使用者间的复杂互动、瞬时决策及复杂环境条件。其中,两车相撞占道路事故约70%,是交通安全的主要挑战。识别司机危险行为(DHA)对理解事故成因至关重要,但大规模数据库中DHA数据的可靠性受限于人工标注不一致且耗时的问题。本文提出一种创新框架,利用微调的大语言模型从文本事故描述中自动推断DHA,提升分类的准确性与可解释性。基于五年两车事故数据(MTCF),将Llama 3.2 1B模型在详细事故叙述上进行微调,并与随机森林、XGBoost、CatBoost及神经网络等传统模型对比。微调后的LLM整体准确率达80%,显著优于所有基线模型,尤其在数据不平衡情况下表现突出。为增强可解释性,我们开发了概率推理方法,分析原始测试集及三种反事实场景下的模型输出变化:驾驶员分心程度变化、双驾驶员分心、青少年驾驶员设定。结果表明,单驾驶员分心显著提升“一般危险驾驶”概率;双驾驶员分心使“双方采取危险行为”概率最大;设置青少年驾驶员则大幅提高“超速与停车违规”概率。该框架与分析方法为大规模自动化DHA检测提供了稳健且可解释的解决方案,为交通安全管理与干预提供新机遇。

原文摘要 · Abstract (English)

Vehicle crashes involve complex interactions between road users, split-second decisions, and challenging environmental conditions. Among these, two-vehicle crashes are the most prevalent, accounting for approximately 70% of roadway crashes and posing a significant challenge to traffic safety. Identifying Driver Hazardous Action (DHA) is essential for understanding crash causation, yet the reliability of DHA data in large-scale databases is limited by inconsistent and labor-intensive manual coding practices. Here, we present an innovative framework that leverages a fine-tuned large language model to automatically infer DHAs from textual crash narratives, thereby improving the validity and interpretability of DHA classifications. Using five years of two-vehicle crash data from MTCF, we fine-tuned the Llama 3.2 1B model on detailed crash narratives and benchmarked its performance against conventional machine learning classifiers, including Random Forest, XGBoost, CatBoost, and a neural network. The fine-tuned LLM achieved an overall accuracy of 80%, surpassing all baseline models and demonstrating pronounced improvements in scenarios with imbalanced data. To increase interpretability, we developed a probabilistic reasoning approach, analyzing model output shifts across original test sets and three targeted counterfactual scenarios: variations in driver distraction and age. Our analysis revealed that introducing distraction for one driver substantially increased the likelihood of "General Unsafe Driving"; distraction for both drivers maximized the probability of "Both Drivers Took Hazardous Actions"; and assigning a teen driver markedly elevated the probability of "Speed and Stopping Violations." Our framework and analytical methods provide a robust and interpretable solution for large-scale automated DHA detection, offering new opportunities for traffic safety analysis and intervention.

大模型事故分析可解释性交通安全

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。