CityGPT:增强大语言模型的城市空间认知能力
CityGPT: Empowering Urban Spatial Cognition of Large Language Models
AI总结:
本文提出CityGPT框架,通过构建城市指令数据集CityInstruction和自加权微调方法SWFT训练中小规模大语言模型,并设计CityEval基准验证其在城市空间任务上可媲美甚至超越专有模型。
摘要:
大语言模型(LLMs)凭借其强大的语言生成和推理能力,已在数学和代码生成等许多领域取得了显著成功。然而,在处理城市环境中的现实地理空间任务时,它们往往表现不足。这一局限源于训练过程中缺乏物理世界知识和相关数据。为弥补这一差距,我们提出了CityGPT,一个系统性框架,旨在通过将城市尺度的“世界模型”集成到模型中,增强LLMs对城市空间的理解,并提高其解决相关城市任务的能力。首先,我们构建了一个多样化的指令微调数据集CityInstruction,用于向LLMs注入城市知识并有效提升其空间推理能力。通过结合CityInstruction和开源通用指令数据,我们引入了一种新颖且易于使用的自加权微调方法(SWFT),用于训练多种LLMs(包括ChatGLM3-6B、Llama3-8B和Qwen2.5-7B),以增强其城市空间能力,同时不损害甚至提升其通用能力。最后,为验证所提框架的有效性,我们开发了一个全面的基于文本的空间基准CityEval,用于评估LLMs在广泛的城市场景和地理空间任务中的表现。大量评估结果表明,使用CityInstruction并通过SWFT方法训练的较小规模LLMs,在CityEval评估下能够取得与专有LLMs相当、在某些情况下甚至更优的性能。
英文摘要:
Large language models(LLMs), with their powerful language generation and reasoning capabilities, have already achieved notable success in many domains, e.g., math and code generation. However, they often fall short when tackling real-life geospatial tasks within urban environments. This limitation stems from a lack of physical world knowledge and relevant data during training. To address this gap, we propose \textit{CityGPT}, a systematic framework designed to enhance LLMs' understanding of urban space and improve their ability to solve the related urban tasks by integrating a city-scale `world model' into the model. Firstly, we construct a diverse instruction tuning dataset, \textit{CityInstruction}, for injecting urban knowledge into LLMs and effectively boosting their spatial reasoning capabilities. Using a combination of \textit{CityInstruction} and open source general instruction data, we introduce a novel and easy-to-use self-weighted fine-tuning method (\textit{SWFT}) to train various LLMs (including ChatGLM3-6B, Llama3-8B, and Qwen2.5-7B) to enhance their urban spatial capabilities without compromising, or even improving, their general abilities. Finally, to validate the effectiveness of our proposed framework, we develop a comprehensive text-based spatial benchmark \textit{CityEval} for evaluating the performance of LLMs across a wide range of urban scenarios and geospatial tasks. Extensive evaluation results demonstrate that smaller LLMs trained with \textit{CityInstruction} by \textit{SWFT} method can achieve performance that is competitive with, and in some cases superior to, proprietary LLMs when assessed using \textit{CityEval}.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。