LANGUAGE · HIERARCHICAL MODELS · 2026
What’s in a tree?
Language has structure across many scales. How can we vary that structure and measure its effect on learning? We introduce tree-grams: trainable language models with separate controls for context length and capacity.
Begin with a short context and fixed capacity.
Schematic hierarchy and illustrative channel counts. The animation shows the two controls, not the complete architecture or a measured model prediction.
Two controls on a language model
A conventional n-gram model predicts a token from the previous tokens. Storing every possible context becomes expensive as the window grows.
Tree-grams build the conditional distribution through a hierarchy of small tensor operations. The horizon sets the context window. The rank controls capacity. These controls let us generate different approximations of the same corpus.
Controlled data as an experiment
We train the generators on text, then use their samples to study learning. On TinyStories and Wiki-Text, tuning narrow transformers on simpler generated data improves learning-rate transfer under maximal update parametrization (μP).
Continued training on a new distribution also depends on the target’s entropy and correlation range. Allowing tree-grams to select among topologies produces sparse routing: up to 95% of candidate topologies can be pruned with little performance change in the tested setting.
What the comparison tells us
Tree-grams outperform the tested traditional n-gram baselines and scales better than shallow transformers. A gap to deep transformers remains at longer contexts. Their purpose is to make language a controlled experimental setting.
Read the animation
The schematic illustration shows what we alter - either the context or the capacity of the model at fixed context size.
A few useful terms
- Horizon. The maximal window of tokens, including the token to predict.
- Rank. The capacity parameter of the tree-gram.
- Autoregressive model. A model that generates a sequence one token at a time, conditioned on earlier tokens.
Read the paper, explore the research code, or browse the released models and datasets.
THE PAPER
What's in a Tree ? Hierarchical n-gram models as controlled approximators of language
Aritra Das, Francesco Cagnetta, Darshil Doshi, Victor V. Albert, Maissam Barkeshli, Andrey Gromov
arXiv:2611.23093 · November 2026
NEXT PROJECT