This paper focuses on addressing the challenges of enabling Large Language Models (LLMs) to perform urban spatial reasoning. Existing methods have a main limitation: Retrieval Augmented Frameworks (RAG) lack effective spatial knowledge injection and fail to adequately address spatial semantics, it leads to insufficient knowledge perception of urban spatial scenarios in LLMs. To overcome this issue, we propose a novel geographic retrieval-augmented generation framework (GeoRAG). The approach avoids significant computational overhead and prevents sacrificing generalizability. GeoRAG uses OpenStreetMap data to automatically build a spatio-temporal knowledge graph (STKG). STKG organizes and stores urban spatio-temporal knowledge. GeoRAG incorporates both hierarchical and proximity based spatial features, it introduces a dual retrieval mechanism, the mechanism combines placename matching and coordinate based querying. The retrieved results need to serve as supplementary knowledge for LLMs. To inject contextual spatial knowledge into large models, a spatial prompt template was designed. Our template enabled seamless integration of the knowledge retrieved with LLMs. The experimental results on the CityGPT benchmark show that GeoRAG significantly improves the spatial reasoning performance of Qwen2.5-32B. It achieves relative accuracy gains of 11.89%, 13.25%, and 7.49% on Beijing, London, and New York datasets respectively. This demonstrates the effectiveness of plug-and-play geographic augmentation for LLMs.

错误:搜索内容不能为空,请输入英文关键词
错误:关键词超出字数限制,请精简
高级检索

GeoRAG: A Geographic Retrieval Augmented Generation Framework Based on Urban Spatio-Temporal Knowledge Graph

  • Tao Chen,
  • Shengfa Miao,
  • Shuangfeng Cai,
  • Houcheng Liu,
  • Yongkang Mu,
  • Kaiming Yu,
  • Hualong Deng,
  • Xin Jin,
  • Qian Jiang,
  • Hua Jiang,
  • Puming Wang,
  • Dinan Ma,
  • Ahmed Zahir

摘要

This paper focuses on addressing the challenges of enabling Large Language Models (LLMs) to perform urban spatial reasoning. Existing methods have a main limitation: Retrieval Augmented Frameworks (RAG) lack effective spatial knowledge injection and fail to adequately address spatial semantics, it leads to insufficient knowledge perception of urban spatial scenarios in LLMs. To overcome this issue, we propose a novel geographic retrieval-augmented generation framework (GeoRAG). The approach avoids significant computational overhead and prevents sacrificing generalizability. GeoRAG uses OpenStreetMap data to automatically build a spatio-temporal knowledge graph (STKG). STKG organizes and stores urban spatio-temporal knowledge. GeoRAG incorporates both hierarchical and proximity based spatial features, it introduces a dual retrieval mechanism, the mechanism combines placename matching and coordinate based querying. The retrieved results need to serve as supplementary knowledge for LLMs. To inject contextual spatial knowledge into large models, a spatial prompt template was designed. Our template enabled seamless integration of the knowledge retrieved with LLMs. The experimental results on the CityGPT benchmark show that GeoRAG significantly improves the spatial reasoning performance of Qwen2.5-32B. It achieves relative accuracy gains of 11.89%, 13.25%, and 7.49% on Beijing, London, and New York datasets respectively. This demonstrates the effectiveness of plug-and-play geographic augmentation for LLMs.