In the quest to build artificial intelligence that understands the world as we do, researchers are increasingly looking toward representation learning—the art of teaching machines to organize sensory data into meaningful internal models. A new paper introduces the Homomorphism Autoencoder (HAE), a framework that doesn't just learn what the world looks like, but mathematically captures how our actions transform it.
The Challenge of Action-Aware Representations
Most world models in machine learning are purely observational; they learn to predict the next frame in a video but don't necessarily understand the underlying "rules" of the transformations occurring. For an agent to act effectively, it needs an internal model where its actions (like "rotate 90 degrees" or "move left") have a consistent, predictable effect on its internal representation of the world.
The challenge is learning this structure without prior knowledge. Usually, if we want a model to understand rotations, we have to hard-code the math of rotations into it. The authors ask: Can an agent learn the mathematical structure of its actions (the "group structure") simply by interacting with the world and observing the transitions?
The Homomorphism Autoencoder (HAE)
The HAE is built on the architecture of a standard autoencoder, consisting of an encoder and a decoder, but it introduces a sophisticated "action-aware" middle layer.
- Group Representation: Instead of just concatenating an action vector to the latent state, the HAE maps actions to a group representation—essentially a matrix that acts on the latent vector via multiplication.
- Lie Algebra & Exponential Map: To make the math work smoothly, the authors use a trick from differential geometry. They map actions to a Lie Algebra (a linear space of matrices) and then use the matrix exponential to turn those into valid group elements (invertible matrices). This allows the model to learn complex, continuous symmetries like rotations.
- The 2-Step Loss: A key theoretical contribution is the proof that a simple 1-step prediction isn't enough to learn the group structure from scratch—it often leads to "trivial" solutions where the model ignores the action. The HAE uses a 2-step latent prediction loss, ensuring that the composition of two actions in the latent space matches the result of those actions in the real world.
- Sparsity for Disentanglement: They introduce a "soft" sparsity constraint that encourages the learned matrices to be block-diagonal. This naturally forces the model to separate independent factors, like horizontal vs. vertical movement.
Key Insights: Homomorphism and Orbits
- Homomorphism as a Learning Principle: The core insight is that for a representation to be "veridical" (truthful), the mapping from world-actions to latent-matrices must be a homomorphism. This means the mathematical structure of the latent space must mirror the physical world's structure.
- Orbits Define Identity: In group theory, an "orbit" is the set of all states you can reach by applying actions. The HAE learns that "identity" (e.g., being a heart vs. a square) is what remains invariant under the action group. It effectively separates the "What" (identity) from the "Where" (pose) without any labels.
- Generalization through Algebra: Because the model learns the underlying Lie Algebra, it can generalize. For example, even if it was only trained on small 30-degree rotations, it can perform a full 360-degree "linear traversal" in the latent space because it has captured the "generator" of the rotation.
Experimental Results
The authors evaluated the HAE on several synthetic but mathematically rich datasets, including a modified dSprites dataset where a shape moves on a 2D torus, a multi-object version, and 3D rotations of the Stanford Bunny.
- Topology Discovery: The HAE successfully recovered the 2D toroidal structure of the dSprites world, organizing its latent space into a "donut" shape that perfectly matches the environment's true geometry.
- Long-term Rollouts: In 128-step "mental simulations" of future actions, the HAE maintained significantly higher accuracy than unstructured models. While standard models' predictions "drifted" off the manifold, the HAE's group structure kept the latent states physically plausible.
- Complex Symmetry Learning: The model successfully learned the non-commutative structure of 3D rotations and separated them from color shifts, even when the input actions were "mixed" through a random neural network.
Limitations and Future Directions
While promising, the current HAE assumes a deterministic world, whereas real-world transitions are often stochastic. Additionally, the experiments focused on single objects or simple scenes; scaling this to complex, multi-object dynamic environments remains a challenge.
Future work could involve combining this group-structured approach with Reinforcement Learning (RL). This could lead to agents that plan much more efficiently by "thinking" in terms of the environment's natural symmetries, paving the way for more robust and mathematically grounded internal world models.
Summary updated