Manuscript Offprint

arXiv:2610.27140

Representing short-term movement to reveal animal identity and learning progress

Ping Zhang, Quang-Huy Nguyen, Yingtie Lei, Sameera Shridhar, Zachary Leveroni, Ellie Quattrocchi, Jai Y Yu, Wei-Lun Chao

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Ping Zhang 1,∗^{1,*}

pingzh@bu.edu

Sameera Shridhar 3^{3}

sameerashridhar@uchicago.edu

Quang-Huy Nguyen 1,∗^{1,*}

quanghuy@bu.edu

Zachary Leveroni 3^{3}

leveroniz@uchicago.edu

Yingtie Lei 2,∗^{2,*}

lei.441@osu.edu

Ellie Quattrocchi 3^{3}

equattrocchi@uchicago.edu

Jai Y Yu 3^{3}

jaiyu@uchicago.edu

Wei-Lun Chao 1,2^{1,2}

chao209@bu.edu

1^{1}Boston University 2^{2}The Ohio State University 3^{3}University of Chicago

∗^{*}Equal contribution.

ABSTRACT

How learning progresses over time and varies across individuals is a longstanding question in cognitive and behavioral science. Behavioral changes are observable outcomes of learning and have been a long-established bedrock for understanding learning progress. However, a major challenge is identifying observable behavioral measures that faithfully capture learning progression. Existing approaches commonly rely on predefined behavioral features or task-level performance, while fine-scale posture and movement in freely behaving animals remain less explored. In this paper, we ask: can short-term movement trajectories reveal learning progress and individual identity? We introduce a self-supervised representation learning framework built on a simple hypothesis: behavioral characteristics associated with identity and learning remain relatively stable over nearby time intervals. Using temporal proximity as supervision, our framework learns compact representations directly from movement trajectories without manually defining behavioral states or kinematic features. Using behavior data from freely behaving rats, we show that the learned representations not only improve prediction of identity and learning-related readouts over existing methods, but also provide a tool for investigating broader scientific questions about when and how these signals appear in behavior. Specifically, trajectories as short as one second contain informative learning and identity signals. Egocentric pose dynamics are more predictive of identity, whereas allocentric motion is more predictive of learning-related variation, and both signals are strongest at decision junctions in the alternation cohort. We further use a representation-conditioned diffusion model to inspect movement patterns associated with identity and learning progress. Our findings establish short-term movement as an informative behavioral “fingerprint” for studying learning and individual differences. Our code is available at github.com/pizhn/TRAIL.

1 INTRODUCTION

A longstanding question in cognitive science is how learning progresses over time. We can study this progression by characterizing changes in brain networks and behavior. While characterizing neural changes requires recording brain activity, behavioral changes provide a directly observable window into the learning process. A major challenge, however, is identifying which aspects of behavior show learning-related changes and how they evolve. Standard approaches rely on predefined behavioral features, such as speed, latency, or the frequency of a target behavior, as well as task-level performance measures, such as success rate. These measures are interpretable and readily quantifiable, but often summarize behavior as coarse scalar changes over extended periods (Smith et al., 2004). In

Figure

Figure 1: Dataset and problem setting. Left: Repeated pose recordings span animals and days under two reward rules over the Y-shape spatial learning dataset: alternation and probabilistic rewards. L, C, and R denote the left, center, and right arms, respectively. Right: A compact representation of short-term movement trajectories is learned and evaluated for inferring identity, recording day, and performance (e.g., proficiency, success rate, and reward).

contrast, fine-scale changes in limb posture and movement can provide a wealth of information about learning progression, as demonstrated in studies of motor learning (Kawai et al., 2015; Bova et al., 2021; Dhawale et al., 2019; Nguyen et al., 2021). Yet, in unconstrained settings, where animals learn to navigate freely in space (Rosenberg et al., 2021), the complexity of movement patterns makes it difficult to determine which behavioral features to measure and how they can be used to understand changes in the underlying cognitive processes. Addressing this challenge could reveal the hidden structures and dynamics of learning.

In addition to behavioral changes over time, inter-individual differences in movement have been reported across species (Godesberg et al., 2024; Chao et al., 2019). Such movement “fingerprints” are increasingly being linked to biologically important variation in genetic and cognitive traits (Levy et al., 2023; Forkosh et al., 2019; Freund et al., 2013; von Ziegler et al., 2024; Sheppard et al., 2022; Ding et al., 2026). If successfully applied to learning-related movement analysis, these fingerprints could add a new dimension to understanding individual learning dynamics. However, current methods vary widely in their performance and the observation periods required to identify individuals, ranging from tens of seconds to minutes (Levy et al., 2023; Forkosh et al., 2019; von Ziegler et al., 2024).

These limitations raise a fundamental question: can short-term movement trajectories reveal learning progress and individual identity? We focus on body posture and movement patterns unfolding over only a few seconds—a timescale that is often insufficient to assess task-level performance. Nevertheless, how animals move, coordinate their body parts, or respond to their surroundings within these short intervals may already provide informative signals (Weinreb et al., 2026). We investigate whether a representation learned directly from movement trajectories can capture these signals without manually defining behavioral states or kinematic features.

To this end, we study movement data from rat spatial learning experiments described in (Shridhar et al., 2026). We first evaluate existing approaches for representing movement trajectories, spanning traditional state-based methods (Durbin & Koopman, 2012; Wiltschko et al., 2015; Paraschos et al., 2013; Weinreb et al., 2024), recent machine learning methods (Hinton & Salakhutdinov, 2006; Luxem et al., 2022; Grill et al., 2020; Bai et al., 2018; Azabou et al., 2023; Stoffl et al., 2025), and time-series foundation models (Google Research, 2026; Ansari et al., 2025). Across identity- and learning-related evaluations such as task performance, these approaches have limited predictive performance.

We therefore develop a representation learning framework, TRAIL (TRAjectory-Identity Latent), tailored to capturing information about individual differences and learning progress from short segments of movement data, as illustrated in figure 1. Our framework combines a trajectory encoder with a self-supervised objective. Inspired by Wayformer (Nayakanti et al., 2022), an architecture developed for short-term motion forecasting in autonomous driving, the encoder maps short movement trajectories into compact latent representations. Our training objective builds on a simple hypothesis: although an animal's movements may vary rapidly, the underlying behavioral characteristics associated with identity and learning are more stable over nearby time intervals. We therefore use temporal proximity as a self-supervisory signal, encouraging representations of nearby trajectory segments to be similar while contrasting them with segments from other recordings or sufficiently distant times within the same recording. This objective enables representation learning without identity or learning-progress labels during training.

We evaluate our framework on the spatial learning data (Shridhar et al., 2026) and find clear improvements over existing methods. Linear probes trained on the learned representations predict learning-related readouts more accurately, demonstrating that such information is accessible from short movement trajectories. Interestingly, the representations also support accurate identity prediction, even though segments from different recordings of the same individual can be contrasted during training. Beyond these learning-focused datasets, our method remains competitive on the established behavioral benchmark MABe22 (Sun et al., 2023), suggesting broader applicability to representation learning from short movement sequences.

The superior performance of our framework not only provides an affirmative answer to our fundamental question, but also offers a tool for investigating broader scientific questions: At what timescale does behavior vary in relation to learning? How long must a trajectory be to capture identity- and learning-related signals, and under what conditions are these signals strongest? Which movement patterns reveal individual identity and learning progress?

First, our temporal-window analysis favors local temporal neighborhoods: expanding the positive-pair window beyond the default 10% of a recording partition reduces prediction of learning-related readouts. Second, trajectories as short as one second already contain information predictive of both identity and learning-related readouts. In the alternation cohort, both signals are stronger at locations where animals must choose a direction than along straight paths. Third, local pose dynamics are more predictive of identity, whereas global motion is more predictive of learning-related readouts. Together, these findings identify temporal, spatial, and postural factors that can guide more targeted hypotheses about behavior and learning. Finally, we use a representation-conditioned diffusion model (Peebles & Xie, 2023) to explore the movement patterns associated with individual identity and learning progress. By varying the conditioning representation, we generate trajectories that preserve broad motion structure while exhibiting subtle changes in stopping, accelerating, and stretching. These qualitative results make behavioral differences associated with the learned representations directly inspectable.

Taken together, our study shows that short movement trajectories contain observable signatures of both individual identity and learning progress. By combining self-supervised representation learning with controlled analyses and conditional generation, we provide a framework for predicting these properties and examining the movement patterns associated with them.

References (42)