How to use from
SGLang
Install from pip and serve model
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
    --model-path "mariklolik/AraToken-Qwen3-1.7B-CPT" \
    --host 0.0.0.0 \
    --port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/chat/completions" \
	-H "Content-Type: application/json" \
	--data '{
		"model": "mariklolik/AraToken-Qwen3-1.7B-CPT",
		"messages": [
			{
				"role": "user",
				"content": "What is the capital of France?"
			}
		]
	}'
Use Docker images
docker run --gpus all \
    --shm-size 32g \
    -p 30000:30000 \
    -v ~/.cache/huggingface:/root/.cache/huggingface \
    --env "HF_TOKEN=<secret>" \
    --ipc=host \
    lmsysorg/sglang:latest \
    python3 -m sglang.launch_server \
        --model-path "mariklolik/AraToken-Qwen3-1.7B-CPT" \
        --host 0.0.0.0 \
        --port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/chat/completions" \
	-H "Content-Type: application/json" \
	--data '{
		"model": "mariklolik/AraToken-Qwen3-1.7B-CPT",
		"messages": [
			{
				"role": "user",
				"content": "What is the capital of France?"
			}
		]
	}'
Quick Links

AraToken-Qwen3-1.7B-CPT

The continued-pretraining baseline at 1.7B parameters. It uses the original tokenizer and the same data, trainable layers (24–27) and number of steps (2,000) as mariklolik/AraToken-Qwen3-1.7B-LEP.

Paper: AraToken: Optimizing Arabic Tokenization with Normalization Pipeline and Language Extension for Qwen3. Code: https://github.com/mariklolik/Aratoken.

Model Arabic BPC ↓
Qwen3-1.7B-Base 1.3313
this model 1.2672
AraToken-Qwen3-1.7B-LEP 1.2598

BPC is bits per character on the first 1,500 documents of the held-out test split of mariklolik/AraToken-FineWeb2-HQ-ar. It compares models with different vocabularies on the same characters.

from transformers import AutoModelForCausalLM, AutoTokenizer

repo = "mariklolik/AraToken-Qwen3-1.7B-CPT"
tokenizer = AutoTokenizer.from_pretrained(repo)
model = AutoModelForCausalLM.from_pretrained(repo, torch_dtype="bfloat16")

The tokenizer carries the AraToken normalizer: NFKC, Tatweel removal, Western digits, Latin punctuation and diacritics removal. Raw Arabic text can therefore be passed to it directly.

Citation

@article{kashirskiy2025aratoken,
  title   = {AraToken: Optimizing Arabic Tokenization with Normalization Pipeline and Language Extension for Qwen3},
  author  = {Kashirskiy, Mark and Lipinski, Artiom and Makarov, Ilya},
  journal = {arXiv preprint arXiv:2512.18399},
  year    = {2025}
}
Downloads last month
351
Safetensors
Model size
2B params
Tensor type
BF16
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for mariklolik/AraToken-Qwen3-1.7B-CPT

Finetuned
(449)
this model

Dataset used to train mariklolik/AraToken-Qwen3-1.7B-CPT

Paper for mariklolik/AraToken-Qwen3-1.7B-CPT