Leviathan: Decoupling Input and Output Representations in Language Models
The paper introduces Leviathan, a Transformer architecture that decouples input and output representations by replacing the standard tied embedding matrix with a learned embedding vectorization (LEV), achieving significant improvements in language modeling performance and downstream benchmarks with minimal parameter overhead.
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
The Problem: The "One-Size-Fits-All" Dictionary
Imagine you are teaching a robot to speak. To do this, the robot needs a dictionary that does two very different jobs:
- Reading: It looks up a word to understand what it means (Input).
- Writing: It looks up a word to predict what comes next (Output).
In most modern AI models, the robot uses a single, giant physical dictionary for both jobs. This is called "weight tying." The paper argues that this is like forcing a Swiss Army knife to be both a precise surgeon's scalpel and a heavy-duty hammer. It tries to do both, but it's not great at either because the requirements are different.
- Reading needs smoothness: Words that mean similar things (like "cat" and "kitten") should be close together in the robot's mind.
- Writing needs sharpness: The robot needs to clearly distinguish between every single word in the dictionary, even the weird ones.
When you force one tool to do both, the robot has to compromise. It ends up being "okay" at both, but not "great" at either.
The Failed Fix: Buying Two Dictionaries
The obvious solution seems to be: "Just give the robot two separate dictionaries—one for reading and one for writing."
The researchers tried this. They gave the robot a massive, fully separate dictionary for reading. But it didn't work. The robot got confused, learned slower, and actually performed worse than the single-dictionary version, even though it had 50% more memory (parameters) to work with. It was like giving a student two textbooks but no study guide; the extra information just became noise.
The Solution: Leviathan (The "Smart Generator")
The paper introduces Leviathan, a new way of building the robot's brain. Instead of a giant physical dictionary for reading, Leviathan uses a smart, compact generator.
The Analogy: The Recipe Book vs. The Grocery Store
- The Old Way (Tied Embeddings): Imagine a massive grocery store where every single item (every word) has its own specific shelf. If you want "apple," you go to shelf A. If you want "apricot," you go to shelf B. If you want a rare fruit like "durian," you have to find its specific, tiny shelf. If the store is huge, finding that rare shelf is hard, and the robot often forgets where it is.
- The Leviathan Way (LEV): Instead of a shelf for every single word, Leviathan has a recipe book.
- To make an "apple," the robot doesn't look up a shelf; it follows a recipe: Take 1 part "fruit," add 2 parts "red," mix with "sweet."
- To make a "durian" (a rare word), it follows a similar recipe: Take 1 part "fruit," add 2 parts "spiky," mix with "strong smell."
Because the robot uses a recipe (a mathematical function) rather than a shelf, it can create a perfect "apple" or "durian" on the fly.
- The Magic: If the robot learns what "apple" tastes like, it automatically gets better at understanding "pear" because the recipes share ingredients. This is called smoothness.
- The Efficiency: The recipe book is tiny compared to the massive grocery store. This means the robot can keep its "Writing Dictionary" (the output head) huge and separate without needing extra memory. It gets the best of both worlds: a tiny, smart reading system and a massive, powerful writing system.
What Happened in the Experiments?
The researchers tested this new "Leviathan" robot against the old "Single Dictionary" robot at three different sizes (Small, Medium, and Large).
- It Learned Faster: The Leviathan robot reached the same level of skill using 2.1 times fewer training words than the old robot.
- It Got Smarter: At the largest size, the Leviathan robot was 9% better at predicting the next word (a metric called perplexity).
- The "Rare Word" Superpower: The biggest surprise was where the improvement happened.
- For common words (like "the" or "and"), both robots were about the same.
- For rare words (words the robot sees only once in a million), the Leviathan robot was 81% better.
- Why? In the old system, if a word is rare, the robot barely gets a chance to learn its "shelf location," so it forgets it. In Leviathan, because the word is built from a recipe of shared parts, the robot can still figure it out even if it's seen it only once.
The Bottom Line
The paper proves that the way we connect the "reading" and "writing" parts of AI matters. You don't need to just throw more memory at the problem. Instead, by switching from a giant lookup table to a compact, smooth recipe generator, you can make AI models smarter, faster, and much better at understanding rare and difficult words, all while using almost the same amount of computer power.
In short: Leviathan stops the AI from memorizing a giant phone book and starts it learning the grammar of how words are built, making it a much more efficient and capable learner.
Drowning in papers in your field?
Get daily digests of the most novel papers matching your research keywords — with technical summaries, in your language.