arXiv:2610.34638q-bio.NCOct 2026

Manuscript Offprint

arXiv:2610.34638

Intrinsic Goals for Autonomous Agents: Hierarchical Exploration Captures Future Volitional Action in Drosophila

Declan Kutscher, Reece Keller, Alyn Kirsch, Felix Pei, Aran Nayebi

ABSTRACT

Animals have a remarkable ability to act autonomously—driven by intrinsic motivation—without external sensory cues or extrinsic objectives, yet the computational mechanisms behind this ability largely remain a mystery. To understand how biological autonomy may emerge from optimizing intrinsic goals, we use recent whole-brain recordings in the fruit fly (Drosophila melanogaster) that identify neural representations of spontaneous exploratory decisions more than 10 seconds in advance. Combined with a neuromechanical digital twin of Drosophila, these recordings allow us to test whether intrinsically motivated artificial agents with realistic embodiments quantitatively match fly behavior and internal representations of future volitional action during exploration. We implement a hierarchical, intrinsically motivated agent whose policy operates over a discrete library of motor primitives—fixed low-level controllers that actuate joint dynamics—closely matching ethological theories of behavioral syllables. We train agents with no external reward using 20 intrinsic motivation algorithms spanning curiosity, entropy, and competency methods. We evaluate frozen policies in a virtual tethered-ball assay modeled after the fruit-fly experiment, allowing us to compare spontaneous locomotor statistics and internal representations and decode future turn direction from both kinematics and neural activations on the same timescales observed in flies. We find that DIAYN—a hierarchical competency algorithm that learns a discrete set of policies maximizing behavioral entropy and the separability of their induced sensory observations—achieves the strongest joint behavioral and neural prospective coding performance with the fruit fly. Surprisingly, DIAYN's learned policies closely capture individual variability in fly exploration strategies, suggesting that this behavioral diversity optimizes a concrete computational goal of maximizing state-space coverage at the population level. Furthermore, DIAYN agents' latent activity closely captures the specific sum-difference rule in interhemispheric encoding of future kinematics in biological flies. Together, these results establish hierarchical, intrinsically motivated agents as a powerful framework for reverse-engineering animal autonomy.

1 INTRODUCTION

Animals continuously structure experience even in the absence of an explicit task, external reward, or instructive sensory cue. They explore their environment and learn about how their own actions affect the world before those experiences are necessarily tied to a particular extrinsic goal. Such self-directed experience may contribute to the flexibility with which animals later learn new tasks, adapt to changing environments, and acquire new behaviors over their lifetime. In contrast, artificial agents are commonly optimized for extrinsic objectives and task-specific reward functions, and achieving

∗^{*}Equal contribution.

Project website: https://neuroagents-lab.github.io/autonomous_drosophila/ a Environment

b Evaluation

Figure

Figure

c Olfaction

Figure

d Proprioception

e Vision

Figure

Figure

Figure 1: Environment Overview. (a) The fly policy is trained in an environment with obstacles and multiple odor sources. (b) The policy is then evaluated in a tethered-ball environment where the fly is head-fixed. The angular and forward velocities are read from the ball, analogous to the biological experiment of Brezovec et al. (2023). (c) The policy receives olfaction as a weighted sum of intensities sampled at the antennae and maxillary palps. (d) The policy’s proprioceptive input comes directly from NeuroMechFly and includes joint angles, joint velocities, and body-frame gravity, height, and linear and angular velocities. (e) Vision is also provided to the policy by simulating the ommatidia mapping of pale and yellow type cells to pixels.

similarly broad and persistent autonomy remains challenging (Hughes et al., 2024). Understanding the computational objectives that explain intrinsically-driven animal behavior may therefore provide principles for building artificial agents that autonomously learn useful representations and behaviors without extrinsic goals (Keller et al., 2025).

A wide range of intrinsic-motivation objectives have been proposed as computational mechanisms for generating autonomous behavior in the context of exploration and reinforcement learning. These include objectives such as novelty (Burda et al., 2019), prediction error (Pathak et al., 2017), uncertainty (Pathak et al., 2019), state-space coverage (Liu & Abbeel, 2021), empowerment (Klyubin et al., 2008), and unsupervised skill discovery (Eysenbach et al., 2019). However, these methods are typically evaluated according to criteria designed for artificial agents, such as downstream task performance on highly specific environments.

Such evaluations do not directly test for autonomy, nor do they establish whether the resulting behavior or internal representations resemble those of biological agents—systems that already exhibit robust autonomous behavior. Biological systems therefore provide an additional and independently motivated constraint on the space of possible intrinsic objectives. Hence, a candidate objective should not only produce useful exploration, but ideally reproduce measurable properties of animal behavior and neural activity (Keller et al., 2025).

Recent whole-brain recordings in Drosophila provide a particularly useful “ground-truth” target for these kinds of comparisons. Brezovec et al. (2023) recorded neural activity while head-fixed flies explored spontaneously on a spherical treadmill in darkness. They found that interhemispheric activity in a subregion of the Inferior Posterior Slope (IPS) was weakly but significantly predictive of future left-versus-right turn direction approximately 15 to 8 seconds before a turn. This activity emerged well before the onset of widespread locomotion-related activity across the brain. This provides two complementary constraints on computational hypotheses of internally generated behavior; namely, the spatial and temporal dynamics of the agent’s behavior and internal representations of future actions.

Methods in computational ethology that describe spontaneous behavior of recurring behavioral syllables (Wiltschko et al., 2015; Mathis et al., 2018; Hsu & Yttri, 2021; Pereira et al., 2022) motivate us to consider the level of behavioral abstraction at which the intrinsic-drive methods should operate.

These syllables exhibit organizational structure across multiple timescales, motivating our implementation of a hierarchical policy distribution over motor primitives. These motor primitives are then implemented at the joint-torque level by a low-level central pattern generator (CPG) (Mantziaris et al., 2020; Chun et al., 2021; Lobato-Rios et al., 2022) and kinematic replays of real fly behaviors, such as grooming (Fig. 2b). This separates exploratory action selection from the mechanics of locomotion and allows intrinsic objectives to operate over behaviorally meaningful variables rather than individual motor commands.

We extend the goal-driven modeling approach of computational neuroscience (Yamins & DiCarlo, 2016; Richards et al., 2019; Feather et al., 2025), in which candidate objectives are instantiated in artificial networks and compared against neural recordings, to intrinsic motivation (Keller et al., 2025). We require that a candidate objective account for behavior as well as neural activity. Our agents are embodied in NeuroMechFly v2, a biomechanical model of Drosophila simulated in FlyGym, with vision, olfaction, proprioception, and articulated body dynamics (Lobato-Rios et al., 2022; Wang-Chen et al., 2024) (Fig. 1). We train recurrent policies with 20 intrinsic drive methods (IDM) spanning curiosity, entropy, and competency objectives (Fig. 2a). All methods share the same embodiment, architecture, training environment, and training budget. We then freeze each policy and evaluate it in a virtual tethered-ball assay that reproduces the biological experiment of Brezovec et al. (2023) (Fig. 1b). For each agent, we compare turning behavior with that of the flies, test whether internal representations predict future turn direction on the timescale of the IPS signal, compare this with what ongoing behavior alone predicts, ask whether its low-dimensional activity shares IPS's sum-difference relationship to angular and forward velocity.

Contributions To summarize, our contributions are as follows:

• We implement hierarchical, intrinsically motivated agents embodied in a biomechanically-realistic fly body, in which 20 intrinsic objectives operate over seven ethologically motivated behavioral primitives.

• We show that representations of future action can emerge from intrinsic motivation alone, without an externally specified task or reward. In particular, several intrinsically motivated agents develop internal states that predict turn direction seconds in advance, paralleling the prospective signal observed in the fly IPS.

• Among the intrinsic objectives tested, unsupervised skill discovery provides the strongest computational account of spontaneous population-wide fly behavior and its neural dynamics. DIAYN, hierarchically operating on behavioral primitives, jointly reproduces future-action predictivity, the relationship between neural and behavioral predictability, inter-animal variability in turning behavior, and low-dimensional activity structure related to forward and angular velocity.

• We demonstrate that behavioral predictability and average locomotor statistics alone are insufficient to distinguish candidate explanations of spontaneous action. Objectives that generate predictable behavior or match mean turning bias can fail to reproduce the fly’s prospective internal signal; jointly evaluating behavioral variability and internal future-action predictivity distinguishes DIAYN from these alternatives.

References (100)

Couldn't load all references. Reload the page to try again.