Abstract
This paper presents a novel Variational Bayesian framework that unifies habitual and goal-directed behaviors through a single latent variable termed "intention." By conceptualizing habits as a prior distribution and goals as a posterior distribution, the model enables agents to share motor skills across both systems and perform complex tasks "zero-shot" without additional training. Experimental results in a simulated T-maze environment demonstrate high success rates in navigating toward novel visual targets by minimizing variational free energy.
Introduction: The Habit-Goal Dichotomy
In both biological brains and artificial intelligence, behavior is often split into two distinct systems:
- Habitual (Model-Free): Fast and efficient but inflexible, operating on "autopilot."
- Goal-Directed (Model-Based): Flexible and planning-oriented but computationally expensive.
Conventionally, these systems are treated as separate modules requiring an arbitration mechanism to decide which takes control. The challenge lies in the lack of effective knowledge sharing; a model-free agent may master motor skills but cannot easily apply them to new goals without extensive retraining. This paper addresses how to integrate these systems so they share a common "motor vocabulary" while maintaining flexibility.
The Bayesian Behavior Framework
The researchers introduce Bayesian Behavior, a framework where a probabilistic latent variable $z$, or "intention," acts as a bridge between sensory input and action.
- Habits as the Prior: Habitual behavior is generated using the prior distribution of $z$, trained via Model-Free Reinforcement Learning (Soft Actor-Critic) to maximize general rewards.
- Goals as the Posterior: Goal-directed behavior is treated as an inference problem. Using Active Inference (AIf) and Predictive Coding, the agent calculates the posterior distribution of $z$ that minimizes variational free energy relative to a desired goal observation.
The architecture utilizes a Recurrent Neural Network (GRU) for internal state maintenance and a Convolutional Neural Network (CNN) for processing 360° visual inputs. By treating the goal-seeking process as a posterior inference, the agent can repurpose its habitual motor skills for new objectives.
Key Insights: Intention and Skill Sharing
A central innovation is using "intention" as a bottleneck. By forcing communication through a low-dimensional latent variable, the model learns a compact representation of behavior. This significantly accelerates planning, as the agent optimizes $z$ rather than individual motor commands.
Because the habitual and goal-directed pathways share the same policy network, the goal-directed system inherits the smooth, efficient motor skills developed by the habitual system. This synergy allows for zero-shot generalization, where the agent achieves goals it never encountered during training—such as "avoid blue" or "seek red"—simply by minimizing prediction error between its internal world model and the target state.
Experimental Results
The framework was tested in a custom PyBullet T-maze environment where the agent perceived the world through a high-dimensional 360° RGB camera.
- High Success Rates: The agent achieved 97.9% success in reaching specific visual locations and 100% in color-avoidance tasks zero-shot.
- Efficiency vs. Diversity: Ablation studies confirmed that the Bayesian components are crucial for behavioral diversity; without them, agents often became "stuck" in repetitive paths.
- Amortized Inference: The study demonstrated that repeated goal-directed tasks can be "compiled" back into habits using a feedforward network, mimicking the human process of learning complex tasks until they become automatic.
Conclusion
While currently limited to simple 2D environments, this framework provides a powerful template for bridging the gap between fast intuition and slow deliberation. By unifying habits and goals under a single Bayesian umbrella, the model offers a more biologically plausible and computationally efficient approach to flexible AI behavior. Future work will explore higher-dimensional 3D environments and the autonomous generation of intrinsic goals.
Summary updated