Downloads · 30 days
0
marcelo-earth/toktok-es-8k
toktok-es-8k is a machine learning model from marcelo-earth. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
BPE tokenizer trained on Spanish Wikipedia using SentencePiece.
Downloads · 30 days
0
Access
Public
Updated Mar 7, 2026
Repo size
370 KB
Likes
0
Public
Click a slice to open those files.
.model370 KB · 77%
From the Hugging Face model README
BPE tokenizer trained on Spanish Wikipedia using SentencePiece.
import sentencepiece as spm
sp = spm.SentencePieceProcessor()
sp.load("tokenizer.model")
text = "El procesamiento de lenguaje natural es fascinante."
tokens = sp.encode_as_pieces(text)
print(tokens)
English-centric tokenizers (GPT-4, Llama) use 20-40% more tokens on Spanish text. This tokenizer is optimized for Spanish, giving better compression and cheaper inference.