As Large Language Models (LLMs) become the backbone of global technology, a fundamental mystery remains: how do they actually manage multiple languages? Do they build a separate "brain" for each language, or do they find a common ground?
Previous research has been contradictory. Some studies suggest models use language-specific representations, while others point to incredible "cross-lingual transfer" where a model trained on English suddenly performs well in Spanish. Recent research employs the lens of mechanistic interpretability—the study of reverse-engineering a model's weights into human-understandable algorithms—to see if the "circuitry" used to solve a task in English is the same as the one used in Chinese.
Researchers have discovered that LLMs develop "universal" internal circuits to handle similar grammatical tasks across different languages, even when those models are trained entirely independently. However, when languages diverge, the models dynamically recruit language-specific "subroutines" to handle unique requirements while keeping the core logic shared.
Peering Inside the Black Box
To understand how models process different languages, researchers utilized two primary "microscopes" to look inside models like BLOOM-560M, Qwen2-0.5B, GPT2-small, and CPM-distilled:
- Path Patching: A causal intervention technique where researchers swap specific activations from a "clean" prompt with a "corrupted" one to see which specific components (attention heads) are responsible for the model's final decision.
- Information Flow Routes: A method that tracks the contribution of every attention head to the "residual stream" (the model's internal workspace) at each step, mapping how information moves through the network.
The study focused on two distinct linguistic phenomena to compare English and Chinese processing:
- Indirect Object Identification (IOI): A syntactic task that is virtually identical in English and Chinese (e.g., "Susan gave a drink to Mary. Susan gave it to [Mary]").
- Tense Marking: A task where the languages differ. English requires a morphological change (e.g., walk $\rightarrow$ walked), whereas Chinese uses the same verb form regardless of time.
Shared Circuits for Shared Grammar
Surprisingly, even when models are trained on completely different data (one only English, one only Chinese), they "discover" nearly the same internal algorithms to solve the same syntactic problems. This suggests there might be an "optimal" way for transformers to process certain linguistic structures.
For the IOI task, the correlation between English and Chinese head activations in the multilingual BLOOM model was remarkably high ($\rho = 0.72$). In contrast, the correlation between the IOI task and a random control task was much lower ($\rho = 0.48$).
The specific types of attention heads identified—such as "Duplicate Token Heads" and "S-Inhibition Heads"—performed the exact same functional roles across both languages. This functional alignment matches the circuit patterns found in previous English-only studies, proving that models exploit common structures to save "parameter space" when grammar allows it.
Divergent Circuits for Divergent Grammar
While models share core logic for similar tasks, they must adapt when languages diverge. The researchers identified a fascinating "Base + Plugin" architecture. In multilingual models, the core logic of a task is handled by a shared set of attention heads. However, language-specific requirements act like modular plugins.
This was clearly demonstrated in the Tense Marking task. Because English requires adding suffixes like "-ed" to verbs, English processing heavily recruited late-stage Feed-Forward Networks (FFNs) in layers 20–24.
When researchers "ablated" (turned off) these specific FFN layers, the model's English accuracy plummeted from 97.4% to 47.4%. However, Chinese performance—which doesn't utilize morphological tense changes and therefore doesn't need those "plugins"—remained almost entirely unaffected, dropping only marginally from 25.1% to 24.2%. Models are perfectly capable of carving out language-specific niches when the grammar demands it.
Conclusion and Future Directions
This research highlights a sophisticated trade-off in LLMs: they maximize efficiency by converging on universal circuits for shared linguistic structures, yet preserve the ability to route information through language-specific subroutines when grammatical rules diverge.
While this focused case study was limited to English and Chinese on relatively small models (under 1 billion parameters), it opens exciting doors for future work. Researchers can now explore whether these "universal circuits" hold up in massive models like GPT-4, or across more distant language pairs with vastly different word orders. Ultimately, understanding these circuits could allow us to manually align them, forcing better cross-lingual transfer and preventing one language's grammar from interfering with another's.
Summary updated