De Bytes a Ideias: Modelagem de Linguagem com U-Nets Autoregressivas
From Bytes to Ideas: Language Modeling with Autoregressive U-Nets
June 17, 2025
Autores: Mathurin Videau, Badr Youbi Idrissi, Alessandro Leite, Marc Schoenauer, Olivier Teytaud, David Lopez-Paz
cs.AI
Resumo
A tokenização impõe uma granularidade fixa no texto de entrada, congelando como um modelo de linguagem opera sobre os dados e quão longe no futuro ele prevê. O Byte Pair Encoding (BPE) e esquemas semelhantes dividem o texto uma vez, constroem um vocabulário estático e deixam o modelo preso a essa escolha. Relaxamos essa rigidez ao introduzir uma U-Net autorregressiva que aprende a incorporar seus próprios tokens durante o treinamento. A rede lê bytes brutos, agrupa-os em palavras, depois em pares de palavras e, em seguida, em até 4 palavras, proporcionando uma visão multiescala da sequência. Em estágios mais profundos, o modelo deve prever mais adiante no futuro — antecipando as próximas palavras em vez do próximo byte —, então os estágios mais profundos focam em padrões semânticos mais amplos, enquanto os estágios iniciais lidam com detalhes mais finos. Ao ajustar e controlar cuidadosamente o cálculo de pré-treinamento, hierarquias rasas empatam com fortes baselines de BPE, e hierarquias mais profundas mostram uma tendência promissora. Como a tokenização agora reside dentro do modelo, o mesmo sistema pode lidar com tarefas em nível de caractere e transferir conhecimento entre idiomas de baixos recursos.
English
Tokenization imposes a fixed granularity on the input text, freezing how a
language model operates on data and how far in the future it predicts. Byte
Pair Encoding (BPE) and similar schemes split text once, build a static
vocabulary, and leave the model stuck with that choice. We relax this rigidity
by introducing an autoregressive U-Net that learns to embed its own tokens as
it trains. The network reads raw bytes, pools them into words, then pairs of
words, then up to 4 words, giving it a multi-scale view of the sequence. At
deeper stages, the model must predict further into the future -- anticipating
the next few words rather than the next byte -- so deeper stages focus on
broader semantic patterns while earlier stages handle fine details. When
carefully tuning and controlling pretraining compute, shallow hierarchies tie
strong BPE baselines, and deeper hierarchies have a promising trend. Because
tokenization now lives inside the model, the same system can handle
character-level tasks and carry knowledge across low-resource languages.