Downloads · 30 days
0
alakxender/dhivehi-roberta-tokenizer-extended
dhivehi-roberta-tokenizer-extended is a machine learning model from alakxender. Use it for the machine learning task on the model card, and read the license before you ship it in a product. It is set up for transformers. The card lists the license as mit.
This repository contains a custom extension of the roberta-base tokenizer, enhanced with 10,000 frequently used Dhivehi tokens.
Downloads · 30 days
0
Access
Public
Updated Jun 12, 2025
Repo size
—
Likes
0
Public
Click a slice to open those files.
.json8.5 MB · 95%
From the Hugging Face model README
This repository contains a custom extension of the roberta-base tokenizer, enhanced with 10,000 frequently used Dhivehi tokens.
roberta-base (vocab size: 50265)އީދުގެ ހަރަކާތްroberta-baseTokens: ['Þ', 'ĩ', 'Þ', '©', 'Þ', 'ĭ', 'Þ', 'ª', 'Þ', 'İ', 'Þ', '¬', 'Ġ', ...]
Token IDs: [49944, 6382, 49944, 15375, 49944, 13859, ...]
Dhivehi ExtendedTokens: ['އީދުގެ', 'Ġ', 'ހަރަކާތް']
Token IDs: [59825, 1437, 53039]
The extended tokenizer produces clean, language-aware tokens from valid Thaana characters, unlike the corrupted outputs from the base tokenizer.
Tokens: ['The', 'Ġquick', 'Ġbrown', 'Ġfox', 'Ġjumps', 'Ġover', 'Ġthe', 'Ġlazy', 'Ġdog', '.']
Token IDs: [133, 2119, 6219, 23602, 13855, 81, 5, 22414, 2335, 4]
English performance remains identical to the original roberta-base.
from transformers import AutoTokenizer
tokenizer = AutoTokenizer.from_pretrained("alakxender/dhivehi-roberta-tokenizer-extended")
tokens = tokenizer.tokenize("އީދުގެ ހަރަކާތް")
print(tokens)