OsmT: Bridging OpenStreetMap Queries and Natural Language with Open-source Tag-aware Language Models

Fuente: arXiv
Gespeichert in:
Bibliographische Detailangaben
Hauptverfasser: Wan, Zhuoyue, Hu, Wentao, Zhang, Chen Jason, Song, Yuanfeng, Li, Shuaimin, Xiao, Ruiqiang, Wei, Xiao-Yong, Wong, Raymond Chi-Wing
Format: Preprint
Veröffentlicht: 2025
Schlagworte:
Online-Zugang:
Tags: Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
_version_ 1866914179799056384
author Wan, Zhuoyue
Hu, Wentao
Zhang, Chen Jason
Song, Yuanfeng
Li, Shuaimin
Xiao, Ruiqiang
Wei, Xiao-Yong
Wong, Raymond Chi-Wing
author_facet Wan, Zhuoyue
Hu, Wentao
Zhang, Chen Jason
Song, Yuanfeng
Li, Shuaimin
Xiao, Ruiqiang
Wei, Xiao-Yong
Wong, Raymond Chi-Wing
contents Bridging natural language and structured query languages is a long-standing challenge in the database community. While recent advances in language models have shown promise in this direction, existing solutions often rely on large-scale closed-source models that suffer from high inference costs, limited transparency, and lack of adaptability for lightweight deployment. In this paper, we present OsmT, an open-source tag-aware language model specifically designed to bridge natural language and Overpass Query Language (OverpassQL), a structured query language for accessing large-scale OpenStreetMap (OSM) data. To enhance the accuracy and structural validity of generated queries, we introduce a Tag Retrieval Augmentation (TRA) mechanism that incorporates contextually relevant tag knowledge into the generation process. This mechanism is designed to capture the hierarchical and relational dependencies present in the OSM database, addressing the topological complexity inherent in geospatial query formulation. In addition, we define a reverse task, OverpassQL-to-Text, which translates structured queries into natural language explanations to support query interpretation and improve user accessibility. We evaluate OsmT on a public benchmark against strong baselines and observe consistent improvements in both query generation and interpretation. Despite using significantly fewer parameters, our model achieves competitive accuracy, demonstrating the effectiveness of open-source pre-trained language models in bridging natural language and structured query languages within schema-rich geospatial environments.
format Preprint
id arxiv_https___arxiv_org_abs_2512_04738
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle OsmT: Bridging OpenStreetMap Queries and Natural Language with Open-source Tag-aware Language Models
Wan, Zhuoyue
Hu, Wentao
Zhang, Chen Jason
Song, Yuanfeng
Li, Shuaimin
Xiao, Ruiqiang
Wei, Xiao-Yong
Wong, Raymond Chi-Wing
Computation and Language
Artificial Intelligence
Databases
Bridging natural language and structured query languages is a long-standing challenge in the database community. While recent advances in language models have shown promise in this direction, existing solutions often rely on large-scale closed-source models that suffer from high inference costs, limited transparency, and lack of adaptability for lightweight deployment. In this paper, we present OsmT, an open-source tag-aware language model specifically designed to bridge natural language and Overpass Query Language (OverpassQL), a structured query language for accessing large-scale OpenStreetMap (OSM) data. To enhance the accuracy and structural validity of generated queries, we introduce a Tag Retrieval Augmentation (TRA) mechanism that incorporates contextually relevant tag knowledge into the generation process. This mechanism is designed to capture the hierarchical and relational dependencies present in the OSM database, addressing the topological complexity inherent in geospatial query formulation. In addition, we define a reverse task, OverpassQL-to-Text, which translates structured queries into natural language explanations to support query interpretation and improve user accessibility. We evaluate OsmT on a public benchmark against strong baselines and observe consistent improvements in both query generation and interpretation. Despite using significantly fewer parameters, our model achieves competitive accuracy, demonstrating the effectiveness of open-source pre-trained language models in bridging natural language and structured query languages within schema-rich geospatial environments.
title OsmT: Bridging OpenStreetMap Queries and Natural Language with Open-source Tag-aware Language Models
topic Computation and Language
Artificial Intelligence
Databases
url https://arxiv.org/abs/2512.04738