IEEE Transactions on Knowledge and Data Engineering

Capturing Context-Aware Route Choice Semantics for Trajectory Representation Learning

Ji Cao1,2,*, Yu Wang1,*, Tongya Zheng3, Jie Song4, Qinghong Guo5, Zujie Ren2,1,†, Canghong Jin3, Gang Chen1, Mingli Song1
1 College of Computer Science and Technology, Zhejiang University, Hangzhou 310027, China 2 Zhejiang Lab, Hangzhou 311121, China 3 Zhejiang Provincial Engineering Research Center for Real-Time SmartTech in Urban Security Governance, Hangzhou City University, Hangzhou 310015, China 4 School of Software Technology, Zhejiang University, Ningbo 315100, China 5 Polytechnic Institute of Zhejiang University, Hangzhou 310015, China
*Equal contribution. †Corresponding author.
Overview of the CORE framework
CORE constructs a context-aware road network from multi-granular POI semantics, models route choice behavior with an MoE-based encoder, and aggregates route-choice-aware representations for downstream trajectory tasks.

Abstract

Trajectory representation learning (TRL) aims to encode raw trajectory data into low-dimensional embeddings for downstream tasks such as travel time estimation, mobility prediction, and trajectory similarity analysis. From a behavioral perspective, a trajectory reflects a sequence of route choices within an urban environment. However, most existing TRL methods ignore this underlying decision-making process and instead treat trajectories as static, passive spatiotemporal sequences, thereby limiting the semantic richness of the learned representations.

To bridge this gap, we propose CORE, a TRL framework that integrates context-aware route choice semantics into trajectory embeddings. CORE first incorporates a multi-granular Environment Perception Module, which leverages large language models (LLMs) to distill environmental semantics from point of interest (POI) distributions, thereby constructing a context-enriched road network. Building upon this backbone, CORE employs a Route Choice Encoder with a mixture-of-experts (MoE) architecture, which captures route choice patterns by jointly leveraging the context-enriched road network and navigational factors.

Finally, a Transformer encoder aggregates the route-choice-aware representations into a global trajectory embedding. Extensive experiments on 4 real-world datasets across 6 downstream tasks demonstrate that CORE consistently outperforms 15 state-of-the-art TRL methods, achieving an average improvement of 9.20% over the best-performing baseline.

Downstream Results

CORE is evaluated on four real-world datasets across six downstream tasks. Tables report CORE's scores and relative improvements over the strongest baseline; Gain values follow the metric order in each table.

BibTeX

@article{cao2026capturing,
  title={Capturing Context-Aware Route Choice Semantics for Trajectory Representation Learning},
  author={Cao, Ji and Wang, Yu and Zheng, Tongya and Song, Jie and Guo, Qinghong and Ren, Zujie and Jin, Canghong and Chen, Gang and Song, Mingli},
  journal={IEEE Transactions on Knowledge and Data Engineering},
  year={2026},
  volume={38},
  number={10},
  pages={6408-6423},
  doi={10.1109/TKDE.2026.3708608},
}