← Latest papers
🤖 machine learning

Shortcut Solutions Learned by Transformers Impair Continual Compositional Reasoning

This paper investigates continual compositional reasoning in Transformers using an extended LEGO framework, revealing that while feedforward BERT models fail due to entrenched shortcut solutions, recurrent ALBERT models exhibit superior performance by learning algorithmic "for-loop" strategies that can be further enhanced through cross-experience training.

Original authors: William T. Redman, Erik C. Johnson, Brian Robinson

Published 2026-05-08
📖 5 min read🧠 Deep dive

Original authors: William T. Redman, Erik C. Johnson, Brian Robinson

Original paper licensed under CC BY 4.0 (http://creativecommons.org/licenses/by/4.0/). This is an AI-generated explanation of the paper below. It is not written or endorsed by the authors. For technical accuracy, refer to the original paper. Read full disclaimer

Imagine you are teaching a robot to solve a series of puzzles. The puzzles aren't just random; they are variations of the same underlying logic. For example, one puzzle might ask you to rotate a triangle, the next to flip it, and the next to do both. The goal is to see if the robot can learn the logic of the first puzzle and use it to instantly solve the second and third, without forgetting how to do the first one.

This paper investigates how two popular types of AI "brains" (called BERT and ALBERT) handle this kind of learning. The researchers found that while these AI models are incredibly smart, they often take "mental shortcuts" that make them bad at learning new things later on.

Here is the breakdown of their findings using simple analogies:

1. The Two Types of Learners

The researchers tested two models:

  • BERT: Think of this as a photographer. It looks at a whole picture at once and tries to memorize the specific details of that single image. It's very fast and good at recognizing patterns in the moment, but it doesn't really understand the process of how the image was made.
  • ALBERT: Think of this as a programmer. Instead of just memorizing the picture, it learns a set of instructions (like a loop in a computer code) that can be repeated to solve the problem. It understands the mechanism behind the puzzle.

2. The "Shortcut" Trap

When the models were taught the first puzzle (let's call it "Puzzle A"), both did well. However, when the researchers introduced "Puzzle B" (which was very similar but slightly different), a problem arose.

  • BERT (The Photographer): It learned a shortcut. It realized, "Hey, if I just look at the very first clue in the puzzle, I can guess the answer for this specific type of puzzle." It didn't learn the actual logic; it just memorized a trick that worked for Puzzle A.

    • The Result: When faced with Puzzle B, BERT got confused. Because it was relying on a trick specific to Puzzle A, it couldn't adapt. It also completely forgot how to do Puzzle A once it started learning Puzzle B. This is called catastrophic forgetting.
  • ALBERT (The Programmer): It learned the algorithm. It figured out, "Oh, I need to take the current state, apply a rule, and move to the next step." This is like learning a "For Loop" (a computer instruction that repeats an action).

    • The Result: Because ALBERT learned the method rather than a specific trick, it could apply that method to Puzzle B much faster. It showed forward transfer, meaning it used what it learned in Puzzle A to speed up learning Puzzle B.

3. The Size Matters (But Not How You Think)

The researchers tried making the models bigger (adding more layers, like adding more rooms to a house).

  • For ALBERT: Bigger was better. More "rooms" meant it could refine its algorithm and get even better at transferring knowledge.
  • For BERT: Bigger actually made things worse or unstable. Because BERT relies on shortcuts, making the model more complex just gave it more ways to get stuck in a bad habit. It couldn't generalize its learning to new puzzles.

4. The "Memory Replay" Fix

Both models suffered from catastrophic forgetting—when they learned the new puzzle, they completely erased the memory of the old one.

To fix this, the researchers used a Replay Buffer. Imagine a student who, while studying for a new math test, keeps a few flashcards from the old test on their desk to glance at occasionally.

  • The Result: This worked wonders. By showing the models a tiny bit (just 1%) of the old data while they learned the new data, they stopped forgetting. Both BERT and ALBERT could remember the old puzzles while learning the new ones.

5. The Final Hurdle: Combining the Puzzles

The ultimate test of "compositional reasoning" is whether the AI can mix and match rules from different puzzles to solve a brand-new, complex puzzle that combines them all.

  • The Problem: Even with the "Replay Buffer" helping them remember, both models struggled to combine the rules. They could remember Puzzle A and Puzzle B separately, but they couldn't easily weave them together to solve a hybrid puzzle.
  • The Difference: The researchers found a way to help ALBERT succeed at this. If they taught ALBERT using a strategy where they slowly stitched the old puzzles and new puzzles together during training (rather than keeping them separate), ALBERT could learn to combine them.
  • The Limit: This "stitching" strategy did not work for BERT. Because BERT had already entrenched itself in its "shortcut" way of thinking during the initial training, it couldn't be taught to combine the rules later. It was too set in its ways.

The Bottom Line

The paper concludes that while AI models like BERT and ALBERT are powerful, they have a hidden flaw: they tend to learn "cheats" (shortcuts) instead of deep logic.

  • ALBERT is better at learning the deep logic (the "For Loop"), which helps it learn new, related tasks faster.
  • BERT gets stuck on surface-level tricks, which makes it bad at adapting to new situations and causes it to forget old ones.

The study suggests that to make AI truly capable of continual learning (learning forever without forgetting), we need to move away from models that rely on shortcuts and toward architectures that are built to understand the underlying "algorithms" of the world.

Drowning in papers in your field?

Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.

Try Digest →