ChatPaper.aiChatPaper

Existe um Caso para Tokenizadores Otimizados para Conversação em Modelos de Linguagem de Grande Escala?

Is There a Case for Conversation Optimized Tokenizers in Large Language Models?

June 23, 2025
Autores: Raquel Ferrando, Javier Conde, Gonzalo Martínez, Pedro Reviriego
cs.AI

Resumo

Os custos computacionais e energéticos dos Modelos de Linguagem de Grande Escala (LLMs, na sigla em inglês) aumentaram exponencialmente, impulsionados pelo crescimento no tamanho dos modelos e pela adoção massiva de LLMs por centenas de milhões de usuários. O custo unitário de um LLM é o cálculo de um token. Portanto, o tokenizador desempenha um papel importante na eficiência de um modelo, e eles são cuidadosamente otimizados para minimizar o número de tokens para o texto em seu corpus de treinamento. Uma das aplicações mais populares dos LLMs são os chatbots que interagem com os usuários. Uma observação crucial é que, para esses chatbots, o que importa é o desempenho do tokenizador no texto de entrada do usuário e nas respostas do chatbot. Esses textos provavelmente diferem do texto presente no corpus de treinamento. Assim, surge imediatamente a questão de saber se há um benefício potencial em otimizar tokenizadores para conversas de chatbot. Neste artigo, essa ideia é explorada para diferentes tokenizadores, utilizando um corpus publicamente disponível de conversas de chatbot para redesenhar seus vocabulários e avaliar seu desempenho nesse domínio. Os resultados mostram que tokenizadores otimizados para conversas reduzem consistentemente o número de tokens em diálogos de chatbot, o que pode levar a economias significativas de energia, na faixa de 5% a 10%, enquanto têm um impacto mínimo ou até ligeiramente positivo na eficiência de tokenização para o corpus de treinamento original.
English
The computational and energy costs of Large Language Models (LLMs) have increased exponentially driven by the growing model sizes and the massive adoption of LLMs by hundreds of millions of users. The unit cost of an LLM is the computation of a token. Therefore, the tokenizer plays an important role in the efficiency of a model, and they are carefully optimized to minimize the number of tokens for the text in their training corpus. One of the most popular applications of LLMs are chatbots that interact with users. A key observation is that, for those chatbots, what is important is the performance of the tokenizer in the user text input and the chatbot responses. Those are most likely different from the text in the training corpus. So, a question that immediately arises is whether there is a potential benefit in optimizing tokenizers for chatbot conversations. In this paper, this idea is explored for different tokenizers by using a publicly available corpus of chatbot conversations to redesign their vocabularies and evaluate their performance in this domain. The results show that conversation-optimized tokenizers consistently reduce the number of tokens in chatbot dialogues, which can lead to meaningful energy savings, in the range of 5% to 10% while having minimal or even slightly positive impact on tokenization efficiency for the original training corpus.
PDF81June 26, 2025