Introduction
Determining the geographical origin of social media content is essential for a wide range of applications, including localized event detection, demographic analysis, and targeted marketing. Despite its importance, obtaining precise location data remains a significant challenge. Only approximately 1% of tweets contain explicit GPS coordinates. While many users provide a "home location" in their profiles, this field is often populated with informal slang, abbreviations, or fictional entries.
This research addresses these challenges by proposing a robust, city-level geolocation system. By employing a stacking-based ensemble method, the system intelligently integrates noisy profile metadata with the linguistic content of a user’s tweets to achieve state-of-the-art performance.
Methodology: The Stacking Architecture
The geolocation task is framed as a multi-class classification problem, where users are mapped to one of 3,709 global cities. The core of the proposed solution is a two-level stacking architecture:
Level 0: Base Classifiers
Three independent Multinomial Naive Bayes (MNB) classifiers serve as the foundation:
- TEXT Classifier: Analyzes the content of tweets. To ensure scalability and focus on relevant signals, the authors utilize Information Gain Ratio (IGR) to identify "location indicative words" (LIWs).
- MB-LOC Classifier: Processes the user-declared location field from the profile. It uses character 4-grams to handle the high variability and informal nature of user-provided text (e.g., mapping "Brissie" to Brisbane).
- MB-TZ Classifier: Utilizes the user-declared time zone, also modeled via character 4-grams.
Level 1: Meta-Classifier
The outputs (predicted probabilities) from the base classifiers are fed into a Logistic Regression meta-classifier. This model learns the optimal weighting for each signal, effectively deciding when to trust the profile metadata versus the tweet text.
Data and Evaluation
The system was evaluated using two distinct datasets:
- WORLD Dataset: Comprising 1.4 million English-speaking users, this dataset provided the basis for time-homogeneous evaluation.
- LIVE_test Dataset: A newly curated dataset of 32,000 users collected over a year after the WORLD dataset. This allowed the researchers to measure the model's performance on "unseen" future data, testing its temporal robustness.
Results and Key Insights
The stacking approach demonstrated a significant leap in performance over existing benchmarks. On the WORLD dataset, the model achieved an exact city-level accuracy of 49%, nearly doubling the performance of previous text-only models (26-28%).
The Power of Metadata
A major finding was the unexpected utility of user-declared profile metadata. When modeled statistically, these fields provided a much stronger signal than previously assumed. The fusion of metadata and text resulted in a median error distance of just 9 kilometers, a drastic improvement over the 170+ kilometers seen in text-only baselines.
Temporal Decay
The study also revealed a critical vulnerability: temporal degradation. When tested on the newer LIVE_test dataset, accuracy dropped to 40.6%. Interestingly, the text-based classifier remained relatively stable, while the metadata-based classifier (MB-LOC) saw a sharp decline. This suggests that the way users describe their locations in profiles evolves more rapidly than the language they use in daily tweets.
Conclusion
This research proves that combining tweet content with profile metadata through a stacking architecture can yield highly accurate geolocation results. While the model sets a new standard for city-level prediction, the discovery of temporal decay in metadata highlights a need for continuous model updating or more robust feature engineering in live production environments. Future work will focus on understanding the drivers of this decay and refining predictions for challenging urban environments.
Summary updated