GATSim: Urban Mobility Simulation with Generative Agents

Qi Liu, Can Li, Wanjing Ma

TL;DR

GATSim (Generative-Agent Transport Simulation) is a new framework that replaces the rigid, rule-based logic of traditional traffic simulations with LLM-powered "generative agents." These agents possess human-like cognitive structures—including hierarchical memory and multi-scale reflection—allowing them to learn from past commutes, coordinate with family members via natural language, and adapt to unexpected road closures just like real people.

What Problem Does This Paper Address?

Traditional Agent-Based Models (ABM), such as MATSim, are the workhorses of urban planning. However, they rely on "if-then" rules or mathematical utility maximization that struggle to capture the messy reality of human behavior. Real people don't just calculate the mathematically shortest path; they remember that a specific road is "usually a mess on Mondays," they change plans after a quick chat with a spouse, and they learn from bad experiences.

The gap is adaptability and behavioral diversity. Current models can't easily simulate how a population might collectively respond to a novel event (like a sudden festival or a bridge collapse) without researchers manually coding new rules for every scenario.

Methods

The authors introduce a three-tiered architecture:

  1. Urban Mobility Foundation Model: An LLM ensemble (using GPT-4o and the Qwen family) that handles high-level reasoning, population synthesis, and social coordination.
  2. Generative Agents: Each agent has a "cognitive engine" consisting of:
  3. Hierarchical Memory: Combines short-term working memory with a long-term "ConceptNode" structure. Retrieval isn't just a keyword search; it uses a multi-modal approach combining Jaccard similarity (keywords), cosine similarity (semantics), and Overlap Coefficients (spatial-temporal relevance).
  4. Psychologically-Informed Forgetting: To prevent memory bloat and mimic human cognition, memories decay based on power-law functions—mundane events fade quickly, while "significant" events (like a major accident) persist.
  5. Multi-Scale Reflection: Agents reflect at three levels: Immediate (during a trip), Daily (at the end of the day), and Long-term (consolidating habits over weeks).
  6. Simulation Environment: A backend that manages the physical transportation network (represented as graphs, tilemaps, and bitmaps) and handles traffic physics using a point-queue model.

Datasets

  • Stylized Network: The framework was tested on an augmented Nguyen-Dupuis network, featuring 13 nodes, road links, and two metro lines.
  • Synthetic Population: 70 unique agents were generated with diverse socioeconomic profiles (age, income, "barista" or "manager" roles, and specific lifestyle preferences).
  • Human-Agent Benchmark: To validate realism, the authors created 50 mobility scenarios where five human annotators and GATSim agents role-played travel decisions. These were then blindly judged by an independent LLM (GPT-o1).

Key Insights and Ideas

  • Emergent Equilibrium: Unlike traditional models where "User Equilibrium" is a mathematical constraint, GATSim agents reached a stable traffic state naturally. They "learned" to shift departure times earlier to avoid congestion simply by reflecting on their previous days' tardiness.
  • Behavioral Hysteresis: In incident response tests, agents exhibited "over-reactive avoidance." Even after a road capacity was restored, many agents continued to avoid it due to the "trauma" of the previous day's delay. This mirrors real-world "behavioral inertia" that is notoriously hard to code into rule-based systems.
  • Social Coordination as a Variable: By allowing agents to "chat," the model can simulate how household coordination (e.g., "I'll pick up the kids since you're stuck in traffic") impacts macroscopic traffic flow.

Key Results

  • Human-Level Realism: In the blind "LLM-as-a-judge" test, GATSim agents were rated as more realistic than human role-players in 46% of cases, while humans won 40% (with 14% ties).
  • Competitive Performance: Bayesian analysis indicated a 92% probability that generative agents perform at least as well as human annotators in role-playing mobility decisions.
  • Macroscopic Accuracy: The agents successfully produced realistic "peak spreading" patterns (widening the rush hour window) and demonstrated complex adaptation to a 50% capacity reduction on a major link.

Limitations and Future Work

The authors are transparent about several "AI-specific" hurdles:

  • The "Helpful Assistant" Bias: LLMs are trained to be agreeable, making agents occasionally too submissive in social negotiations compared to real (and often stubborn) humans.
  • Hallucinations: Agents sometimes "remembered" traffic congestion on routes they hadn't actually traveled yet.
  • Computational Cost: Each agent requires roughly one million inference tokens per simulation day, making city-scale simulations (millions of agents) currently cost-prohibitive without significant model compression or specialized hardware.
  • Simplified Physics: The current prototype uses a basic point-queue model; future versions need to integrate more sophisticated traffic flow dynamics and signal control.

Summary updated

Abstract

Traditional agent-based urban mobility simulations often rely on rigid rulebased systems that struggle to capture the complexity, adaptability, and behavioral diversity inherent in human travel decision making. Inspired by recent advancements in large language models and AI agent technologies, we introduce GATSim, a novel framework that leverages these advancements to simulate urban mobility using generative agents with dedicated cognitive structures. GATSim agents are characterized by diverse socioeconomic profiles, individual lifestyles, and evolving preferences shaped through psychologically informed memory systems and lifelong learning. The main contributions of this work are: 1) a comprehensive architecture that integrates urban mobility foundation model with agent cognitive systems and transport simulation environment; 2) a hierarchical memory designed for efficient retrieval of contextually relevant information, incorporating spatial and temporal associations; 3) planning and reactive mechanisms for modeling adaptive mobility behaviors which integrate a multi-scale reflection process to transform specific travel experiences into generalized behavioral insights. Experiments indicate that generative agents perform competitively with human annotators in role-playing scenarios, while naturally producing realistic macroscopic traffic patterns. The code for the prototype implementation is publicly available at https://github.com/qiliuchn/gatsim.
BibTeX
@misc{liu2025gatsim,
  author = {Qi Liu and Can Li and Wanjing Ma},
  title = {{GATSim: Urban Mobility Simulation with Generative Agents}},
  year = {2025},
  eprint = {2506.23306},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2506.23306},
}
Figure