Skip to main content

Lund University Publications

LUND UNIVERSITY LIBRARIES

ChatGeoAI: Enabling Geospatial Analysis for Public through Natural Language, with Large Language Models

Mansourian, Ali LU orcid and Oucheikh, Rachid LU (2024) In ISPRS International Journal of Geo-Information 13(10).
Abstract
Large Language Models (LLMs) such as GPT, BART, and Gemini stand at the forefront of Generative Artificial Intelligence, showcasing remarkable prowess in natural language comprehension and task execution. This paper proposes a novel framework developed on the foundation of Llama 2, aiming to bridge the gap between natural language queries and executable code for geospatial analyses within the PyQGIS environment. It empowers non-expert users to leverage GIS technology without requiring deep knowledge of geospatial programming or tools. Through cutting-edge Natural Language Processing (NLP) techniques, including tailored entity recognition and ontology mapping, the framework accurately interprets user intents and translates them into... (More)
Large Language Models (LLMs) such as GPT, BART, and Gemini stand at the forefront of Generative Artificial Intelligence, showcasing remarkable prowess in natural language comprehension and task execution. This paper proposes a novel framework developed on the foundation of Llama 2, aiming to bridge the gap between natural language queries and executable code for geospatial analyses within the PyQGIS environment. It empowers non-expert users to leverage GIS technology without requiring deep knowledge of geospatial programming or tools. Through cutting-edge Natural Language Processing (NLP) techniques, including tailored entity recognition and ontology mapping, the framework accurately interprets user intents and translates them into specific GIS operations. Integration of geospatial ontologies enriches semantic comprehension, ensuring precise alignment between user descriptions, geospatial datasets, and geospatial analysis tasks. A code generation module empowered by Llama 2 converts these interpretations into PyQGIS scripts, enabling the execution of geospatial analysis and results visualization. Rigorous testing across a spectrum of geospatial analysis tasks, with incremental complexity, evaluates the framework and the performance of such a system, with LLM at its core. The proposed system demonstrates proficiency in handling various geometries, spatial relationships, and attribute queries, enabling accurate and efficient analysis of spatial datasets. Moreover, it offers robust error-handling mechanisms and supports tasks related to map styling, visualization, and data manipulation. However, it has some limitations, such as occasional struggles with ambiguous attribute names and aliases, which leads to potential inaccuracies in the filtering and retrieval of features. Despite these limitations, the system presents a promising solution for applications integrating LLMs into GIS and offers a flexible and user-friendly approach to geospatial analysis. (Less)
Please use this url to cite or link to this publication:
author
and
organization
publishing date
type
Contribution to journal
publication status
published
subject
keywords
Large Language Models (LLMs), Generative AI, natural language processing (NLP), Code generation, Geospatial Artificial Intelligence (GeoAI), Llama, Spatial analysis, Geographic Information System (GIS), GIS democratization
in
ISPRS International Journal of Geo-Information
volume
13
issue
10
publisher
MDPI AG
external identifiers
  • scopus:85207678194
ISSN
2220-9964
DOI
10.3390/ijgi13100348
language
English
LU publication?
yes
id
2784db5e-364e-40a7-a885-4f861ed59273
date added to LUP
2024-10-28 21:41:22
date last changed
2025-04-04 15:11:43
@article{2784db5e-364e-40a7-a885-4f861ed59273,
  abstract     = {{Large Language Models (LLMs) such as GPT, BART, and Gemini stand at the forefront of Generative Artificial Intelligence, showcasing remarkable prowess in natural language comprehension and task execution. This paper proposes a novel framework developed on the foundation of Llama 2, aiming to bridge the gap between natural language queries and executable code for geospatial analyses within the PyQGIS environment. It empowers non-expert users to leverage GIS technology without requiring deep knowledge of geospatial programming or tools. Through cutting-edge Natural Language Processing (NLP) techniques, including tailored entity recognition and ontology mapping, the framework accurately interprets user intents and translates them into specific GIS operations. Integration of geospatial ontologies enriches semantic comprehension, ensuring precise alignment between user descriptions, geospatial datasets, and geospatial analysis tasks. A code generation module empowered by Llama 2 converts these interpretations into PyQGIS scripts, enabling the execution of geospatial analysis and results visualization. Rigorous testing across a spectrum of geospatial analysis tasks, with incremental complexity, evaluates the framework and the performance of such a system, with LLM at its core. The proposed system demonstrates proficiency in handling various geometries, spatial relationships, and attribute queries, enabling accurate and efficient analysis of spatial datasets. Moreover, it offers robust error-handling mechanisms and supports tasks related to map styling, visualization, and data manipulation. However, it has some limitations, such as occasional struggles with ambiguous attribute names and aliases, which leads to potential inaccuracies in the filtering and retrieval of features. Despite these limitations, the system presents a promising solution for applications integrating LLMs into GIS and offers a flexible and user-friendly approach to geospatial analysis.}},
  author       = {{Mansourian, Ali and Oucheikh, Rachid}},
  issn         = {{2220-9964}},
  keywords     = {{Large Language Models (LLMs); Generative AI; natural language processing (NLP); Code generation; Geospatial Artificial Intelligence (GeoAI); Llama; Spatial analysis; Geographic Information System (GIS); GIS democratization}},
  language     = {{eng}},
  number       = {{10}},
  publisher    = {{MDPI AG}},
  series       = {{ISPRS International Journal of Geo-Information}},
  title        = {{ChatGeoAI: Enabling Geospatial Analysis for Public through Natural Language, with Large Language Models}},
  url          = {{http://dx.doi.org/10.3390/ijgi13100348}},
  doi          = {{10.3390/ijgi13100348}},
  volume       = {{13}},
  year         = {{2024}},
}