nextlocllm: next location prediction using LLMs
Liu, Shuai, Cao, Ning, Chen, Yile, Jiang, Yue, Cong, Gao
–arXiv.org Artificial Intelligence
Next location prediction is a critical task in human mobility analysis and serves as a foundation for various downstream applications. Existing methods typically rely on discrete IDs to represent locations, which inherently overlook spatial relationships and cannot generalize across cities. In this paper, we propose NextLocLLM, which leverages the advantages of large language models (LLMs) in processing natural language descriptions and their strong generalization capabilities for next location prediction. Specifically, instead of using IDs, NextLocLLM encodes locations based on continuous spatial coordinates to better model spatial relationships. These coordinates are further normalized to enable robust cross-city generalization. Another highlight of NextlocLLM is its LLM-enhanced POI embeddings. These embeddings are then integrated via nonlinear projections to form this LLM-enhanced POI embeddings, effectively capturing locations' functional attributes. Furthermore, task and data prompt prefix, together with trajectory embeddings, are incorporated as input for partly-frozen LLM backbone. NextLocLLM further introduces prediction retrieval module to ensure structural consistency in prediction. Experiments show that NextLocLLM outperforms existing models in next location prediction, excelling in both supervised and zero-shot settings. With the rapid advancement of smart city infrastructure and positioning techniques, the acquisition of human mobility trajectories has become increasingly widespread, offering unprecedented research opportunities (Yabe et al., 2024a). Accurately predicting a user's next location holds significant value across multiple key domains.
arXiv.org Artificial Intelligence
Oct-11-2024