customized-ar-translator

This model is a fine-tuned version of Qwen/Qwen2.5-0.5B-Instruct on the trans_finetune_train dataset. It achieves the following results on the evaluation set:

  • Loss: 0.8289

Model description


language: - ar - en tags: - translation - technical-translation - education - nlp license: apache-2.0

🤖 Tech-En-Ar-Translator-Glossary

Model Description

This model is a specialized English-to-Arabic translator designed specifically for the IT and Technology domain.

Unlike standard translators, this model does not translate technical jargon (like "Cloud Computing," "Servers," "Infrastructure") into obscure Arabic terms. Instead, it:

  1. Preserves Technical Terms: Keeps key English terminology within the Arabic sentence structure.
  2. HTML-Ready Output: Wraps the text in HTML tags (dir="rtl", <span>) for immediate web rendering.
  3. Auto-Glossary: Generates a separate "Explaining" section that defines the preserved English terms in Arabic.

It is designed for educational platforms, technical documentation, and learning management systems where students need to learn standard English IT terminology while reading in Arabic.

✨ Key Features

  • Smart Code-Switching: Fluent Arabic grammar mixed with English technical nouns.
  • Dual Output: Returns a JSON object containing the translated text and the explaining (glossary) text.
  • Frontend Friendly: Outputs sanitized HTML strings ready for integration into web apps (React, Vue, plain HTML).

🚀 Example Output

Input Text: > "Cloud computing is the delivery of IT resources including servers, storage, and databases over the internet."

Model Output (JSON):

'''json { "translated": "<div dir="rtl">إنترنت كمبيوتر (<span dir="ltr">Cloud computing) هو توصيل <span dir="ltr">IT resources، بما في ذلك موارد <span dir="ltr">servers و<span dir="ltr">storage و<span dir="ltr">databases، عبر الإنترنت مع أسعار <span dir="ltr">pay-as-you-go.", "explaining": "<div dir="rtl">Cloud computing: هي تقنية تسمح للمستخدمين ب Retrieving (توصيل) برامج وتطبيقات وبيانات...<div dir="rtl">servers: هي مكونات أساسية في نظام تشغيل كمبيوتر..." }'''

Intended uses & limitations

This model is fine-tuned specifically for IT contexts. It may not perform well on general conversational English (e.g., translating a novel or a poem).

The output includes HTML tags; if you need plain text, you will need to strip the tags post-processing.

Training hyperparameters

The following hyperparameters were used during training:

  • learning_rate: 0.0001
  • train_batch_size: 3
  • eval_batch_size: 1
  • seed: 42
  • gradient_accumulation_steps: 3
  • total_train_batch_size: 9
  • optimizer: Use OptimizerNames.ADAMW_TORCH_FUSED with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
  • lr_scheduler_type: cosine
  • lr_scheduler_warmup_ratio: 0.1
  • num_epochs: 3.0

Training results

Training Loss Epoch Step Validation Loss
1.251 0.2 10 1.1727
1.0906 0.4 20 1.0423
0.9856 0.6 30 0.9799
1.0287 0.8 40 0.9357
0.998 1.0 50 0.9081
0.7978 1.2 60 0.8900
0.7939 1.4 70 0.8629
0.7864 1.6 80 0.8529
0.7682 1.8 90 0.8424
0.7936 2.0 100 0.8330
0.6651 2.2 110 0.8357
0.6441 2.4 120 0.8340
0.6665 2.6 130 0.8300
0.6833 2.8 140 0.8287
0.691 3.0 150 0.8289

Framework versions

  • PEFT 0.17.1
  • Transformers 4.57.1
  • Pytorch 2.9.0+cu126
  • Datasets 4.0.0
  • Tokenizers 0.22.1
Downloads last month
14
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for mohammedkhas/customized-ar-translator

Adapter
(855)
this model