Retrieval-Augmented Large Language Model-Based Framework for Hierarchical Classification of Public Feedback on Transportation Infrastructure
Source abstract
Abstract
Transportation agencies receive large volumes of free-form public comments describing infrastructure conditions, safety concerns, and service issues. These comments are often processed manually for downstream operational actions, which is time-consuming, inconsistent across reviewers, and difficult to scale, thereby limiting their value for operational decision-making. This study presents a machine learning and Large Language Model (LLM) framework for automated triage of free-form public comments, assigning each report to a three-level hierarchical taxonomy consisting of Category, Subcategory, and Final Decision. The proposed framework uses agency historical data together with retrieval-based evidence, where semantically similar past comments are provided to the LLM as contextual support to better align predictions with agency-specific labeling practices. The framework was evaluated using TF-IDF with Logistic Regression, TF-IDF with Linear SVM, embedding-based kNN with cosine similarity, few-shot LLM prompting, and retrieval-based LLM prompting. Results show that retrieval-based prompting achieved the best overall performance, with the highest accuracy at both the Category and Subcategory levels. At the Final Decision level, retrieval-based prompting slightly outperformed kNN, while few-shot prompting performed worse. Error analysis showed that many misclassifications were semantically plausible alternatives, reflecting the overlap across infrastructure-related complaint categories. When a second candidate label was allowed, further improving performance. Latency analysis also indicated that the framework can process more than 2000 comments in under 30 min, supporting faster and more consistent agency workflows.
Source: crossref · Quality: baseline
Research context
OpenAlex topics: Public Relations and Crisis Communication · Infrastructure Maintenance and Monitoring · Sentiment Analysis and Opinion Mining
SciVX discovery tags are terminology-based. OpenAlex topics are source-provided classifications.
Affiliations
Department of Civil and Environmental Engineering, University of Pittsburgh, 3700 O’Hara Street, Pittsburgh, PA 15213, USA
Funding
Safety and Mobility Advancements Regional Transportation and Economics Research (SMARTER) Center
References (41)
Show source-provided references
1. Steger-Vonmetz, D. (2005). Improving modal choice and transport efficiency with the virtual ridesharing agency. Proceedings of the 2005 IEEE Intelligent Transportation Systems, IEEE.10.1109/ITSC.2005.1520186 ↗
2. Review of road traffic control strategies10.1109/JPROC.2003.819610 ↗
3. A multiagent approach to autonomous intersection management10.1613/jair.2502 ↗
4. Combined alternate-direction lane assignment and reservation-based intersection control10.1109/TITS.2019.2943521 ↗
5. Knezevic, M., and Stevanovic, A. (2025). Optimizing Pedestrian Operations within Combined Alternate Direction Lane Assignment Reservation-Based Intersection Control. Proceedings of the 2025 IEEE Intelligent Vehicles Symposium (IV), Cluj-Napoca, Romania, 22–25 June 2025, IEEE.10.1109/IV64158.2025.11097539 ↗
6. Partnerships between agencies and Transportation Network Companies for transportation-disadvantage populations: Benefits, problems, and challenges10.1177/03611981211032629 ↗
7. Transportation agencies as consumers and producers of science: The case of state, regional, and county transportation agencies in California10.1016/j.tranpol.2022.08.016 ↗
8. A web platform for the management of road survey and maintenance information: A preliminary step towards smart road management systems10.1002/stc.2905 ↗
9. Federal Highway Administration (2015). Public Involvement Techniques for Transportation Decisionmaking, U.S. Department of Transportation. 2015 Update.
10. Wandelt, S., Zheng, C., Wang, S., Liu, Y., and Sun, X. (2024). Large language models for intelligent transportation: A review of the state of the art and challenges. Appl. Sci., 14.10.3390/app14177455 ↗
11. Townsend, H., Samach, M., Cetin, M., Ishak, S., Bare, K., and Ozbay, K. (2024). Implementing Machine Learning at State Departments of Transportation: A Guide, National Academies Press. NCHRP Research Report 1122.10.17226/27880 ↗
12. Chandra, C., Jing, X., Bendarkar, M.V., Sawant, K., Elias, L., Kirby, M., and Mavris, D.N. (2023). Aviation-BERT: A preliminary aviation-specific natural language model. Proceedings of the AIAA Aviation 2023 Forum, San Diego, CA, USA, 12–16 June 2023, AIAA.10.2514/6.2023-3436 ↗
13. Zheng, O., Abdel-Aty, M., Wang, D., Wang, Z., and Ding, S. (2023). ChatGPT is on the horizon: Could a large language model be all we need for Intelligent Transportation. arXiv.
14. K-nearest neighbor10.4249/scholarpedia.1883 ↗
15. Large language models are zero-shot reasoners
16. Machine learning for next-generation intelligent transportation systems: A survey10.1002/ett.4427 ↗
17. Behrooz, H., and Hayeri, Y.M. (2022). Machine learning applications in surface transportation systems: A literature review. Appl. Sci., 12.10.3390/app12189156 ↗
18. Naseralavi, S., Soltanirad, M., Ranjbar, E., Lucero, M., Gorzin, F., Hakiminejad, Y., Azimi, S., Baghersad, M., and Mazaheri, A. (2025). Machine Learning Modeling of Household Trip Generation by State Using NHTS Data. Urban Sci., 9.10.3390/urbansci9090353 ↗
19. Short term traffic flow prediction for a non urban highway using artificial neural network10.1016/j.sbspro.2013.11.170 ↗
20. Intelligent traffic control for autonomous vehicle systems based on machine learning10.1016/j.eswa.2019.113074 ↗
21. ChatGPT in connected and autonomous vehicles: Benefits and challenges10.20517/ir.2023.08 ↗
22. Leveraging chatgpt for real-time decision-making in autonomous systems
23. Yang, Z., Jia, X., Li, H., and Yan, J. (2023). Llm4drive: A survey of large language models for autonomous driving. arXiv.
24. Da, L., Gao, M., Mei, H., and Wei, H. (2023). Llm powered sim-to-real transfer for traffic signal control. arXiv.10.1109/CASE56687.2023.10260398 ↗
25. Putting ChatGPT vision (GPT-4V) to the test: Risk perception in traffic images10.1098/rsos.231676 ↗
26. Evaluating Expertise of Concrete Pavement Construction in Modern Large Language Models10.1177/03611981251350643 ↗
27. Tan, S., Ivanovic, B., Weng, X., Pavone, M., and Kraehenbuehl, P. (2023). Language conditioned traffic generation. arXiv.
28. Jing, X., Chennakesavan, A., Chandra, C., Bendarkar, M.V., Kirby, M., and Mavris, D.N. (2023). BERT for aviation text classification. Proceedings of the AIAA Aviation 2023 Forum, San Diego, CA, USA, 12–16 June 2023, AIAA.10.2514/6.2023-3438 ↗
29. Andrade, S.R., and Walsh, H.S. (2023). SafeAeroBERT: Towards a safety-informed aerospace-specific language model. Proceedings of the AIAA Aviation 2023 Forum, San Diego, CA, USA, 12–16 June 2023, AIAA.10.2514/6.2023-3437 ↗
30. Metroberta: Leveraging traditional customer relationship management data to develop a transit-topic-aware language model10.1177/03611981231225655 ↗
31. City transit rider tweets: Understanding sentiments and politeness10.1080/10630732.2021.1903288 ↗
32. Utilizing the Twitter social media to identify transportation-related grievances in Indian cities10.1007/s13278-024-01278-x ↗
33. Framework for evaluating online public opinions on urban rail transit services through social media data classification and mining
34. Machine-learning-augmented analysis of textual data: Application in transit disruption management10.1109/OJITS.2020.3038395 ↗
35. Supporting sustainable system adoption: Socio-semantic analysis of transit rider debates on social media10.1016/j.scs.2017.12.025 ↗
36. Rakhimzhanov, D., Belginova, S., and Yedilkhan, D. (2025). Automated Classification of Public Transport Complaints via Text Mining Using LLMs and Embeddings. Information, 16.10.3390/info16080644 ↗
37. Ding, Y., McCarthy, C., O’Shea, K., and Liu, M. (2025). Leveraging RAG-LLMs for Urban Mobility Simulation and Analysis. arXiv.10.1109/SMC58881.2025.11343289 ↗
38. Mpnet: Masked and permuted pre-training for language understanding
39. Grohe, M. (2020). word2vec, node2vec, graph2vec, x2vec: Towards a theory of vector embeddings of structured data. Proceedings of the 39th ACM SIGMOD-SIGACT-SIGAI Symposium on Principles of Database Systems, Portland, OR, USA, 14–19 June 2020, Association for Computing Machinery.10.1145/3375395.3387641 ↗
40. Team, G., Anil, R., Borgeaud, S., Alayrac, J.B., Yu, J., Soricut, R., Schalkwyk, J., Dai, A.M., Hauth, A., and Millican, K. (2023). Gemini: A family of highly capable multimodal models. arXiv.
41. Retrieval-augmented generation for knowledge-intensive nlp tasks