arrow
Return

Optimizing context-based location extraction by tuning open-source LLMs with RAG

delete2025-07-09
delete0
delete
OA
AI
Z
Zifu Wang
Y
Yahya Masri
A
Anusha Srirenganathan Malarvizhi
T
Tayven Stover
S
Samir Ahmed
D
David W. S. Wong *
Y
Yongyao Jiang *
Y
Yun Li
M
Mathieu Bere
D
Daniel Rothbart *
D
Dieter Pfoser
D
David Marshall
C
Chaowei Yang *
DOI:10.1080/17538947.2025.2521786delete
deleteOriginal
deleteOriginal request for help
deleteShare
deleteSave
Abstract

Abstract

En 中文
Text data such as news from media include different types of geographic information, represented by location, that indicates the whereabout of events or phenomena. Extracting the geographic locations from text within their contexts is challenging, even with Natural Language Processing (NLP) tools and the latest Large Language Models (LLMs). We propose to optimize LLMs using Retrieval-Augmented Generation (RAG) and prompt-tuning methods, such as zero-shot and instruction-based prompting to improve the precision of extracting location information from news. Using Sudan conflict as an example, we extracted the corresponding locations and dates for conflict incidents. We compared runtime and accuracy of using various open-source LLMs, different hyperparameter settings, with and without RAG. Traditional Named Entity Recognition (NER), zero-shot prompting, instruction-based prompting, few-shot prompting, chain-of-thought (CoT) prompting, and RAG-based tuning were compared using an evaluation matrix. RAG-based tuning delivered the highest F1 score (>0.9) for extracting and associating location data with conflict incidents. This research highlights the benefits of using RAG for multi-incident context-based location extraction and provides insights into optimizing LLMs through prompt-tuning, hyperparameter adjustment, and model selection for location extraction tasks. The results can also be used to extract context-based locations or relevant information from text-based documents of other applications.
Keywords:
Context-based location extraction
large language model
retrieval augmented generation
natural language processing
Sudan conflict
media

Journal

International Journal of Digital Earth cover
International Journal of Digital Earth
IF:
4.9
Papers:
1.9K
Citations:
4.7K

Organization

G
George Mason University
Scholars:
7.7K
Papers: 7.9K
Citations: 1.0W