Downloads · 30 days
0
Uunan/turkish-bpe-tokenizer-128
turkish-bpe-tokenizer-128 is a machine learning model from Uunan. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
This repository contains a Byte-Level BPE (Byte Pair Encoding) tokenizer specifically trained on a Turkish corpus (Uunan/turkish-synthetic-corpus). It is designed to optimally tokenize Turkish texts with a vocabulary…
Downloads · 30 days
0
Access
Public
Updated Jul 20, 2026
Repo size
—
Likes
0
Public
Click a slice to open those files.
.json10.4 MB · 100%
From the Hugging Face model README
This repository contains a Byte-Level BPE (Byte Pair Encoding) tokenizer specifically trained on a Turkish corpus (Uunan/turkish-synthetic-corpus). It is designed to optimally tokenize Turkish texts with a vocabulary size of 128,000 tokens.
<pad><unk><bos><eos><bos> and <eos> tokens.You can easily use this tokenizer using the transformers library or the tokenizers library.
transformersfrom transformers import PreTrainedTokenizerFast
tokenizer = PreTrainedTokenizerFast(tokenizer_file="tokenizer.json")
tokenizer.pad_token = "<pad>"
tokenizer.unk_token = "<unk>"
tokenizer.bos_token = "<bos>"
tokenizer.eos_token = "<eos>"
text = "Türkiye yapay zekâ alanında büyük yatırımlar yapıyor."
encoded = tokenizer.encode(text)
print(encoded)
decoded = tokenizer.decode(encoded)
print(decoded)
tokenizersfrom tokenizers import Tokenizer
tokenizer = Tokenizer.from_file("tokenizer.json")
text = "Türkiye yapay zekâ alanında büyük yatırımlar yapıyor."
encoded = tokenizer.encode(text)
print("Tokens:", encoded.tokens)
print("IDs:", encoded.ids)
This tokenizer was trained on the Uunan/turkish-synthetic-corpus dataset, which contains high-quality Turkish synthetic text data, ensuring better coverage for modern Turkish language semantics and morphological structures.
With a vocabulary size of 128k, this tokenizer minimizes the sequence length for Turkish text generation and understanding tasks, improving the efficiency of Language Models (LLMs) trained on Turkish.