{"status":"ok","message-type":"work","message-version":"1.0.0","message":{"indexed":{"date-parts":[[2026,10,14]],"date-time":"2026-10-14T08:47:59Z","timestamp":1791967679291,"version":"4.3.4"},"reference-count":71,"publisher":"American Society of Civil Engineers (ASCE)","issue":"1","content-domain":{"domain":["ascelibrary.org"],"crossmark-restriction":true},"short-container-title":["J. Comput. Civ. Eng."],"published-print":{"date-parts":[[2027,1,1]]},"abstract":"<jats:title>Abstract<\/jats:title>\n                  <jats:p>Building codes are complex documents that pose significant challenges for consistent interpretation and efficient compliance checking in the construction industry. Existing automated methods often overlook the interrelationships between provisions and lack comprehensive evaluation support from practical engineering perspectives. In this study, we develop a retrieval-augmented generation (RAG) system enhanced with a knowledge graph to interpret building codes by leveraging both the semantic content and structural relationships within the documents. We evaluated the system using 661 query-context-answer triplets from a particular building code. The RAG-enhanced model outperformed state-of-the-art pretrained transformer models and general-purpose large language models (LLMs) in answer quality. Shorter text chunks led to higher semantic relevance, while longer chunks improved precision. The closed-source model achieved better accuracy and speed than the open-source alternative. These findings demonstrate the potential of knowledge-graph-based RAG systems to support accurate, efficient, and scalable regulatory interpretation in real-world engineering contexts.<\/jats:p>","DOI":"10.1061\/jccee5.cpeng-7400","type":"journal-article","created":{"date-parts":[[2026,10,14]],"date-time":"2026-10-14T08:02:22Z","timestamp":1791964942000},"update-policy":"https:\/\/doi.org\/10.1061\/do.news.20190416.0001","source":"Crossref","is-referenced-by-count":0,"title":["Building Code Question-Answering Systems Enhanced by Large Language Models and Knowledge-Graph-Based Retrieval-Augmented Generation"],"prefix":"10.1061","volume":"41","author":[{"ORCID":"https:\/\/orcid.org\/0000-0001-9842-719X","authenticated-orcid":true,"given":"Fan","family":"Yang","sequence":"first","affiliation":[{"name":"Research Assistant Professor, UT-Oak Ridge Innovation Institute, and Joint Research Assistant Professor, Dept. of Civil and Environmental Engineering, Univ. of Tennessee, Knoxville, TN 37996; formerly, Graduate Student, Automation and Intelligent Construction Laboratory, Bowen School of Construction, Purdue Univ., West Lafayette, IN 47907\u00a0(corresponding author). ORCID: . Email:\u00a0"}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0000-0001-5225-5943","authenticated-orcid":true,"given":"Jiansong","family":"Zhang","sequence":"additional","affiliation":[{"name":"Purdue Univ."}],"role":[{"vocabulary":"crossref","role":"author"}]}],"member":"30","reference":[{"key":"e_1_3_4_2_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.dibe.2020.100039"},{"key":"e_1_3_4_3_1","unstructured":"Bhat S. R. M. Rudat J. Spiekermann and N. Flores-Herr. 2025. \u201cRethinking chunk size for long-document retrieval: A multi-dataset analysis.\u201d Preprint submitted May 27 2025. https:\/\/arxiv.org\/abs\/2505.21700."},{"key":"e_1_3_4_4_1","unstructured":"Brown T. et al. 2020. \u201cLanguage models are few-shot learners.\u201d In Proc. Advances in Neural Information Processing Systems 1877\u20131901. New York: Curran Associates."},{"key":"e_1_3_4_5_1","unstructured":"Bureau of Labor Statistics. 2025. \u201cConstruction and building inspectors.\u201d Accessed April 9 2025. https:\/\/www.bls.gov\/ooh\/construction-and-extraction\/construction-and-building-inspectors.htm."},{"key":"e_1_3_4_6_1","doi-asserted-by":"publisher","DOI":"10.1061\/(ASCE)0887-3801(2005)19:1(25)"},{"key":"e_1_3_4_7_1","doi-asserted-by":"crossref","unstructured":"Devlin J. M.-W. Chang K. Lee and K. Toutanova. 2019. \u201cBERT: Pre-training of deep bidirectional transformers for language understanding.\u201d In Vol. 1 of Proc. 2019 Conf. of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies edited by J. Burstein C. Doran and T. Solorio 4171\u20134186. Stroudsburg PA: Association for Computational Linguistics.","DOI":"10.18653\/v1\/N19-1423"},{"key":"e_1_3_4_8_1","doi-asserted-by":"publisher","DOI":"10.1016\/S0959-440X(96)80056-X"},{"key":"e_1_3_4_9_1","unstructured":"Edge D. H. Trinh N. Cheng J. Bradley A. Chao A. Mody S. Truitt D. Metropolitansky R. O. Ness and J. Larson. 2025. \u201cFrom local to global: A graph RAG approach to query-focused summarization.\u201d Preprint submitted April 24 2024. https:\/\/arxiv.org\/abs\/2404.16130."},{"key":"e_1_3_4_10_1","doi-asserted-by":"crossref","unstructured":"Es S. J. James L. Espinosa Anke and S. Schockaert. 2024. \u201cRAGAs: Automated evaluation of retrieval augmented generation.\u201d In Proc. 18th Conf. of the European Chapter of the Association for Computational Linguistics: System Demonstrations edited by N. Aletras and O. De Clercq 150\u2013158. Stroudsburg PA: Association for Computational Linguistics.","DOI":"10.18653\/v1\/2024.eacl-demo.16"},{"key":"e_1_3_4_11_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.jobe.2024.110312"},{"key":"e_1_3_4_12_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.strusafe.2014.02.001"},{"key":"e_1_3_4_13_1","unstructured":"Fuchs S. 2021. \u201cNatural language processing for building code interpretation: Systematic literature review report.\u201d In Proc. Conf. CIB W78 11\u201315. Auckland New Zealand: Univ. of Auckland."},{"key":"e_1_3_4_14_1","unstructured":"Fuchs S. M. Witbrock J. Dimyadi and R. Amor. 2024. \u201cUsing large language models for the interpretation of building regulations.\u201d Preprint submitted July 26 2024. https:\/\/arxiv.org\/abs\/2407.21060."},{"key":"e_1_3_4_15_1","unstructured":"GitHub. 2025 \u201cGitHub\u2014gusye1234\/nano-graphrag: A simple easy-to-hack GraphRAG implementation.\u201d Accessed May 21 2025. https:\/\/github.com\/gusye1234\/nano-graphrag\/tree\/main."},{"key":"e_1_3_4_16_1","unstructured":"Greenwood D. S. Lockley S. Malsane and J. Matthews. 2010. \u201cAutomated compliance checking using building information models.\u201d In Proc. Construction Building and Real Estate Research Conf. 363\u2013371. London: Royal Institution of Chartered Surveyors."},{"key":"e_1_3_4_17_1","unstructured":"Guo D. et al. 2025. \u201cDeepSeek-R1: Incentivizing reasoning capability in LLMs via reinforcement learning.\u201d Preprint submitted January 22 2025. https:\/\/arxiv.org\/abs\/2501.12948."},{"key":"e_1_3_4_18_1","doi-asserted-by":"crossref","unstructured":"Hadi M. U. et al. 2023. \u201cA survey on large language models: Applications challenges limitations and practical usage.\u201d Accessed June 23 2025. https:\/\/www.techrxiv.org\/doi\/full\/10.36227\/techrxiv.23589741.v1.","DOI":"10.36227\/techrxiv.23589741.v1"},{"key":"e_1_3_4_19_1","unstructured":"Han H. et al. 2025. \u201cRetrieval-augmented generation with graphs (GraphRAG).\u201d Preprint submitted December 31 2024. https:\/\/arxiv.org\/abs\/2501.00309."},{"key":"e_1_3_4_20_1","doi-asserted-by":"crossref","unstructured":"Hu Y. and Y. Lu. 2024. \u201cRAG and RAU: A survey on retrieval-augmented language model in natural language processing.\u201d Preprint submitted April 30 2024. https:\/\/arxiv.org\/abs\/2404.19543.","DOI":"10.2139\/ssrn.4900122"},{"key":"e_1_3_4_21_1","doi-asserted-by":"publisher","DOI":"10.1145\/3703155"},{"key":"e_1_3_4_22_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.jval.2024.10.2262"},{"key":"e_1_3_4_23_1","unstructured":"Hurst A. et al. 2024. \u201cGPT-4o system card.\u201d Preprint submitted October 25 2024. https:\/\/arxiv.org\/abs\/2307.06435."},{"key":"e_1_3_4_24_1","unstructured":"ICC (International Code Council). 2023. \u201cOnline learning subscription plan.\u201d Accessed April 9 2025. https:\/\/www.iccsafe.org\/content\/online-learning-subscription\/."},{"key":"e_1_3_4_25_1","volume-title":"International building code 2015 IBC","author":"International Code Council","year":"2014","unstructured":"International Code Council. 2014. International building code 2015 IBC. Country Club Hills, IL: International Code Council."},{"key":"e_1_3_4_26_1","unstructured":"Jeong M. T. Kim S. Kim and H. Kim. 2024. \u201cRetrieval-augmented generation-based question answering technology for construction safety.\u201d In Proc. Int. Conf. on Construction Engineering and Project Management 439\u2013446. Seoul: Korea Institute of Construction Engineering and Management. https:\/\/doi.org\/10.6106\/ICCEPM.2024.0439."},{"key":"e_1_3_4_27_1","doi-asserted-by":"publisher","DOI":"10.3390\/buildings15152633"},{"key":"e_1_3_4_28_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.aei.2021.101449"},{"key":"e_1_3_4_29_1","unstructured":"Joren H. J. Zhang C.-S. Ferng D.-C. Juan A. Taly and C. Rashtchian. 2025. \u201cSufficient context: A new lens on retrieval augmented generation systems.\u201d Preprint submitted November 9 2024. https:\/\/arxiv.org\/abs\/2411.06037."},{"key":"e_1_3_4_30_1","unstructured":"Kuratov Y. A. Bulatov P. Anokhin D. Sorokin A. Sorokin and M. Burtsev. 2024. \u201cIn search of needles in a 11M haystack: Recurrent memory finds what LLMs miss.\u201d Preprint submitted February 16 2024. https:\/\/arxiv.org\/abs\/2402.10790."},{"key":"e_1_3_4_31_1","unstructured":"Lewis P. et al. 2020. \u201cRetrieval-augmented generation for knowledge-intensive NLP tasks.\u201d In Proc. Advances in Neural Information Processing Systems 9459\u20139474. New York: Curran Associates."},{"key":"e_1_3_4_32_1","unstructured":"Li D. et al. 2025. \u201cFrom generation to judgment: Opportunities and challenges of LLM-as-a-judge.\u201d Preprint submitted November 25 2024. https:\/\/arxiv.org\/abs\/2411.16594."},{"key":"e_1_3_4_33_1","unstructured":"Lipton Z. C. J. Berkowitz and C. Elkan. 2015. \u201cA critical review of recurrent neural networks for sequence learning.\u201d Preprint submitted May 29 2015. https:\/\/arxiv.org\/abs\/1506.00019."},{"key":"e_1_3_4_34_1","first-page":"157","article-title":"Lost in the middle: How language models use long contexts","volume":"12","author":"Liu N. F.","year":"2024","unstructured":"Liu, N. F., K. Lin, J. Hewitt, A. Paranjape, M. Bevilacqua, F. Petroni, and P. Liang. 2024. \u201cLost in the middle: How language models use long contexts.\u201d Trans. Assoc. Comput. Ling. 12: 157\u2013173. https:\/\/doi.org\/10.1162\/tacl_a_00638.","journal-title":"Trans. Assoc. Comput. Ling."},{"key":"e_1_3_4_35_1","doi-asserted-by":"crossref","unstructured":"Narayanaswamy H. H. Liu and M. Al-Hussein. 2019. \u201cBIM-based automated design checking for building permit in the light-frame building industry.\u201d In Proc. 36th Int. Symp. on Automation and Robotics in Construction. Bratislava Slovakia: International Association for Automation and Robotics in Construction.","DOI":"10.22260\/ISARC2019\/0139"},{"key":"e_1_3_4_36_1","unstructured":"Naveed H. A. U. Khan S. Qiu M. Saqib S. Anwar M. Usman N. Akhtar N. Barnes and A. Mian. 2024. \u201cA comprehensive overview of large language models.\u201d Preprint submitted July 12 2023. https:\/\/arxiv.org\/abs\/2307.06435."},{"key":"e_1_3_4_37_1","unstructured":"Ollama. 2025a. \u201cDeepSeek-R1:70b.\u201d \u00a0\u00a0\u00a0Accessed April 24 2025. https:\/\/ollama.com\/library\/deepseek-r1:70b."},{"key":"e_1_3_4_38_1","unstructured":"Ollama. 2025b. \u201cnomic-embed-text.\u201d Accessed April 24 2025. https:\/\/ollama.com\/library\/nomic-embed-text."},{"key":"e_1_3_4_39_1","doi-asserted-by":"publisher","DOI":"10.1061\/JCCEE5.CPENG-6106"},{"key":"e_1_3_4_40_1","unstructured":"Paruchuri V. 2025. \u201cMarker: Convert PDF to markdown quickly with high accuracy.\u201d Accessed April 25 2025. https:\/\/github.com\/VikParuchuri\/marker."},{"key":"e_1_3_4_41_1","unstructured":"Peeperkorn M. T. Kouwenhoven D. Brown and A. Jordanous. 2024. \u201cIs temperature the creativity parameter of large language models?\u201d Preprint submitted May 1 2024. https:\/\/arxiv.org\/abs\/2405.00492."},{"key":"e_1_3_4_42_1","doi-asserted-by":"publisher","DOI":"10.1038\/s41598-023-34342-1"},{"key":"e_1_3_4_43_1","unstructured":"Pipitone N. and G. H. Alami. 2024. \u201cLegalBench-RAG: A benchmark for retrieval-augmented generation in the legal domain.\u201d Preprint submitted August 19 2024. https:\/\/arxiv.org\/abs\/2408.10343."},{"key":"e_1_3_4_44_1","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-319-92862-3_22"},{"key":"e_1_3_4_45_1","unstructured":"Pulkkinen T. 2024. \u201cGenerative AI for identifying conflicts in construction industry documents.\u201d Master\u2019s thesis School of Engineering Aalto Univ."},{"key":"e_1_3_4_46_1","doi-asserted-by":"crossref","unstructured":"Rajpurkar P. J. Zhang K. Lopyrev and P. Liang. 2016. \u201cSQuAD: 100 000+ Questions for machine comprehension of text.\u201d Preprint submitted June 16 2016. https:\/\/arxiv.org\/abs\/1606.05250.","DOI":"10.18653\/v1\/D16-1264"},{"key":"e_1_3_4_47_1","doi-asserted-by":"publisher","DOI":"10.3390\/app14177782"},{"key":"e_1_3_4_48_1","doi-asserted-by":"crossref","unstructured":"Shuai B. and C. H. Caldas. 2024. A case-based rag methodology to analyze contract risks for construction projects. SSRN Scholarly Paper No. 4946907. Rochester NY: Social Science Research Network.","DOI":"10.2139\/ssrn.4946907"},{"key":"e_1_3_4_49_1","unstructured":"Smith B. and A. Troynikov. 2024. \u201cEvaluating chunking strategies for retrieval.\u201d Accessed November 13 2025. https:\/\/research.trychroma.com\/evaluating-chunking?utm_source=chatgpt.com."},{"key":"e_1_3_4_50_1","doi-asserted-by":"publisher","DOI":"10.31462\/jcemi.2020.02113130"},{"key":"e_1_3_4_51_1","doi-asserted-by":"publisher","DOI":"10.1038\/s41598-019-41695-z"},{"key":"e_1_3_4_52_1","unstructured":"Unstructured. 2025. \u201cChunking for RAG: Best practices.\u201d Accessed November 13 2025. https:\/\/unstructured.io\/blog\/chunking-for-rag-best-practices?utm_source=chatgpt.com."},{"key":"e_1_3_4_53_1","unstructured":"Vaswani A. N. Shazeer N. Parmar J. Uszkoreit L. Jones A. N. Gomez \u0141. Kaiser and I. Polosukhin. 2017. \u201cAttention is all you need.\u201d In Proc. Advances in Neural Information Processing Systems. New York: Curran Associates."},{"key":"e_1_3_4_54_1","unstructured":"Wang C. et al. 2023. \u201cSurvey on factuality in large language models: Knowledge retrieval and domain-specificity.\u201d Preprint submitted October 11 2023. https:\/\/arxiv.org\/abs\/2310.07521."},{"key":"e_1_3_4_55_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.aei.2025.103158"},{"key":"e_1_3_4_56_1","unstructured":"Xu A. S. Bansal Y. Ming S. Yavuz and S. Joty. 2025. \u201cDoes context matter? ContextualJudgeBench for evaluating LLM-based judges in contextual settings.\u201d Preprint submitted March 19 2025. https:\/\/arxiv.org\/abs\/2503.15620."},{"key":"e_1_3_4_57_1","doi-asserted-by":"crossref","unstructured":"Xu Z. M. J. Cruz M. Guevara T. Wang M. Deshpande X. Wang and Z. Li. 2024. \u201cRetrieval-augmented generation with knowledge graphs for customer service question answering.\u201d In Proc. 47th Int. ACM SIGIR Conf. on Research and Development in Information Retrieval 2905\u20132909. New York: Association for Computing Machinery.","DOI":"10.1145\/3626772.3661370"},{"key":"e_1_3_4_58_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.autcon.2024.105730"},{"key":"e_1_3_4_59_1","doi-asserted-by":"crossref","unstructured":"Yang F. H. N. Dib and J. Zhang. 2025a. \u201cKnowledge graph-enhanced large language model framework for privacy-preserving document processing in the AEC domain.\u201d In Proc. AHFE 2025 Hawaii Int. Conf. on Human Factors in Design Engineering and Computing. Abingdon Oxfordshire: Routledge. https:\/\/doi.org\/10.54941\/ahfe1006921.","DOI":"10.54941\/ahfe1006921"},{"key":"e_1_3_4_60_1","doi-asserted-by":"crossref","unstructured":"Yang F. and J. Zhang. 2024a. \u201cApplication of graph convolutional networks to classification of building code requirements.\u201d In Proc. Construction Research Congress 2024 836\u2013845. Reston VA: ASCE. https:\/\/doi.org\/10.1061\/9780784485262.085.","DOI":"10.1061\/9780784485262.085"},{"key":"e_1_3_4_61_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.autcon.2024.105817"},{"key":"e_1_3_4_62_1","doi-asserted-by":"crossref","unstructured":"Yang F. J. Zhang and L. K. Duong. 2024. \u201cGenerative pre-trained transformers (GPT)-based automated building regulatory information transformation.\u201d In Proc. Computing in Civil Engineering 2024 522\u2013531. Reston VA: ASCE. https:\/\/doi.org\/10.1061\/9780784486115.055.","DOI":"10.1061\/9780784486115.055"},{"key":"e_1_3_4_63_1","doi-asserted-by":"crossref","unstructured":"Yang F. J. Zhang and H. Nicholas. 2025b. \u201cA design information extraction method for architectural drawings to support automated building code compliance checking.\u201d In Proc. Computing in Civil Engineering 2025: Computational and Intelligent Technologies 720\u2013729. Reston VA: ASCE. https:\/\/doi.org\/10.1061\/9780784486436.076.","DOI":"10.1061\/9780784486436.076"},{"key":"e_1_3_4_64_1","unstructured":"Yepes A. J. Y. You J. Milczek S. Laverde and R. Li. 2024. \u201cFinancial report chunking for effective retrieval augmented generation.\u201d Preprint submitted February 5 2024. https:\/\/arxiv.org\/abs\/2402.05131."},{"key":"e_1_3_4_65_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.jbi.2024.104702"},{"key":"e_1_3_4_66_1","doi-asserted-by":"publisher","DOI":"10.1061\/(ASCE)CP.1943-5487.0000346"},{"key":"e_1_3_4_67_1","unstructured":"Zhang R. and N. El-Gohary. 2019. \u201cA machine learning-based method for building code requirement hierarchy extraction.\u201d In Proc. Annual Conf.-Canadian Society for Civil Engineering 1\u201310. Montr\u00e9al: Canadian Society for Civil Engineering."},{"key":"e_1_3_4_68_1","doi-asserted-by":"crossref","unstructured":"Zheng L. et al. 2023. \u201cJudging LLM-as-a-judge with MT-bench and chatbot arena.\u201d In Vol. 36 of Proc. Advances in Neural Information Processing Systems 46595\u201346623. Red Hook NY: Curran Associates.","DOI":"10.52202\/075280-2020"},{"key":"e_1_3_4_69_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.engappai.2023.107207"},{"key":"e_1_3_4_70_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.aei.2020.101195"},{"key":"e_1_3_4_71_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.aei.2020.101152"},{"key":"e_1_3_4_72_1","doi-asserted-by":"publisher","DOI":"10.1016\/j.aei.2019.101003"}],"container-title":["Journal of Computing in Civil Engineering"],"original-title":[],"language":"en","link":[{"URL":"https:\/\/ascelibrary.org\/doi\/pdf\/10.1061\/JCCEE5.CPENG-7400","content-type":"unspecified","content-version":"vor","intended-application":"similarity-checking"}],"deposited":{"date-parts":[[2026,10,14]],"date-time":"2026-10-14T08:02:46Z","timestamp":1791964966000},"score":1,"resource":{"primary":{"URL":"https:\/\/ascelibrary.org\/doi\/10.1061\/JCCEE5.CPENG-7400"}},"subtitle":[],"short-title":[],"issued":{"date-parts":[[2027,1,1]]},"references-count":71,"journal-issue":{"issue":"1","published-print":{"date-parts":[[2027,1,1]]}},"alternative-id":["10.1061\/JCCEE5.CPENG-7400"],"URL":"https:\/\/doi.org\/10.1061\/jccee5.cpeng-7400","relation":{},"ISSN":["0887-3801","1943-5487"],"issn-type":[{"value":"0887-3801","type":"print"},{"value":"1943-5487","type":"electronic"}],"subject":[],"published":{"date-parts":[[2027,1,1]]},"assertion":[{"value":"2025-07-12","order":0,"name":"received","label":"Received","group":{"name":"publication_history","label":"Publication History"}},{"value":"2026-05-01","order":2,"name":"accepted","label":"Accepted","group":{"name":"publication_history","label":"Publication History"}},{"value":"2026-10-14","order":3,"name":"published","label":"Published","group":{"name":"publication_history","label":"Publication History"}}],"article-number":"05026009"}}