TL;DR
MBEC++ is a hybrid reinforcement learning (RL) framework that integrates model-based planning, episodic memory, and habitual learning (DQN). By representing experiences as learned trajectory vectors and using a neural network to dynamically weight episodic versus parametric knowledge, it achieves superior sample efficiency and robustness in noisy, stochastic, and partially observable environments.
The Challenge of Episodic Control
Reinforcement learning agents typically fall into two camps: "slow" learners (like DQN) that build a general statistical model of the world over millions of steps, and "fast" learners (Episodic Control) that recall specific past experiences to make quick decisions.
However, existing episodic RL methods have three major flaws:
- The Deterministic Trap: They often assume the world is near-deterministic. In noisy or stochastic environments, a single "lucky" high-reward trajectory can mislead the agent.
- Sample Inefficiency: Most store simple state-action pairs, requiring the agent to experience every possible action in every state to build a reliable memory.
- Rigid Integration: They usually combine episodic and habitual values using a fixed, manually tuned weight, ignoring the fact that an agent might need memory more in new situations and "habit" in familiar ones.
The authors aim to bridge these gaps by creating a system that mimics the human brain's Complementary Learning Systems (CLS)—balancing the fast-learning hippocampus with the slow-learning neocortex.
Methods: The MBEC++ Architecture
To address these limitations, the authors introduce MBEC++, which unifies model-based, episodic, and habitual learning.
The framework consists of several novel components:
- Trajectorial Recall: Instead of storing raw states, the model uses an LSTM-based trajectory model to encode the history of an episode into a vector. This model is trained via a self-supervised "recall loss," forcing it to reconstruct past observations, making the representation compressive and noise-tolerant.
- Model-Based Episodic Control (MBEC): The agent doesn't just look up the current state in memory. It uses its trajectory model to "plan" the outcome of an action and then queries the episodic memory for the value of that predicted future trajectory.
- Advanced Memory Operators:
- Weighted Writing: Updates multiple neighboring memory slots simultaneously to speed up learning.
- Memory Refining: An online operator that uses Temporal Difference (TD) error to propagate values within the memory, even before an episode ends.
- Dynamic Consolidation: A gating neural network dynamically decides how much to trust the episodic memory versus the parametric DQN. This allows the agent to transition from "relying on memory" to "relying on habit" as it gains expertise.
Datasets
The model was evaluated across a diverse suite of RL benchmarks:
- 2D Maze Exploration: Custom grid-worlds designed to test noisy, trap, and dynamic scenarios.
- Stochastic Classical Control: CartPole, MountainCar, and LunarLander, modified with Gaussian reward noise, Bernoulli noise, or stochastic transitions.
- Atari 2600: The standard 57-game benchmark, focusing on a 25-game subset for detailed comparison against other trajectory-based models.
- 3D Navigation (POMDP): Gym Mini-World’s "Pickup Objects," testing the agent's ability to handle partial observability.
Key Insights
- Trajectories Over States: By storing trajectory representations rather than individual states, the agent gains a "contextual" view. This is why it excels in non-Markovian and noisy settings where a single frame isn't enough to understand the environment.
- Non-Parametric Planning: MBEC performs a form of planning without a full "world model" simulator. It simply predicts the next "memory key" (trajectory vector) and asks the memory for its historical value.
- The Power of Distillation: Because the DQN is trained using the combined episodic-parametric value as a target, the "fast" episodic knowledge is gradually distilled into the "slow" parametric weights, leading to more stable long-term performance.
Key Results
MBEC++ demonstrates significant improvements over baseline models, particularly in challenging, noisy environments.
- Robustness to Noise: In noisy maze environments, MBEC maintained high performance while standard DQN and MFEC (Model-Free Episodic Control) performance collapsed.
- Superior Sample Efficiency: On the Atari benchmark at 10 million frames, MBEC++ achieved a median human-normalized score of 117.2%, significantly outperforming Nature DQN (51.3%) and even EMDQN (95.5%), which was trained for four times as many frames (40M).
- Solving the "Unsolvable": In the stochastic CartPole task, MBEC++ was the only model capable of consistently finding the optimal policy within 10,000 steps, while baselines struggled with the reward noise.
- Handling POMDPs: In 3D navigation, MBEC++ outperformed specialized recurrent models like DRQN, proving that its trajectory-based memory is an effective way to handle hidden states.
Limitations and Future Work
- Hyperparameter Complexity: The system introduces several new components (trajectory model, reward model, gating network), leading to a large number of hyperparameters that may require significant tuning for new domains.
- Discrete Action Space: The current implementation is designed for discrete actions. Extending this to continuous action spaces (common in robotics) is a key direction for future research.
- Computational Overhead: While sample-efficient in terms of environment steps, the nearest-neighbor lookups and trajectory modeling add computational complexity per step compared to a vanilla DQN.
Summary updated