Downloads · 30 days
15
35% of all-time downloads
PersianML/gemma-3n-e4b-persian
gemma-3n-e4b-persian is a text generation model from PersianML. Use it when you need the model to write or continue text. The card lists the license as gemma.
<div align="center" <img src="https://github.com/user-attachments/assets/0c52d460-1831-46aa-b3e6-b1a5249c0174" alt="Hugging Face" width="500"/ <br <strong🇮🇷 Persian Language Model | 🤖 Conversational AI | 📚 General…
Downloads · 30 days
15
35% of all-time downloads
All-time downloads
43
Public
Parameters
7.8B
9.9 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors9.9 GB · 100%
How the weights are stored.
U84.1B · 51%
From the Hugging Face model README
This model is a fine-tuned version of unsloth/gemma-3n-E4B-it, optimized for Persian (Farsi) conversational tasks focused on general knowledge. It employs QLoRA techniques for efficient adaptation and is merged into a standalone model suitable for deployment.
unsloth/gemma-3n-E4B-it (Google Gemma 3N 4B Instruction-Tuned).This model is designed for direct use in Persian conversational AI, including instruction-following and general knowledge queries in domains such as Persian heritage, programming, architecture, and tourism. It is suitable for downstream applications like chat interfaces or educational tools. Out-of-scope uses include non-Persian languages or safety-critical applications.
mshojaei77/persian-gk (cleaned version: mshojaei77/persian-gk-cleaned), comprising 5,897 Persian conversations in ChatML format.The model was fine-tuned using QLoRA with 4-bit quantization.
q_proj, k_proj, v_proj, o_proj, gate_proj, up_proj, down_proj.The merging process integrated LoRA adapters into the base model, converting to 16-bit precision for standalone use.
The model achieved a final training loss of 1.78, with gradient norms stabilizing between 0.7 and 2.0. Training completed in 2 hours and 20 minutes on a T4 GPU.
Inference performance:
| Scenario | GPU | max_new_tokens=256 | Runtime |
|---|---|---|---|
| Single prompt | RTX T4 (16 GB) | 8.5 s | 22 tok s⁻¹ |
| Batch 4 | RTX T4 | 19 s | 54 tok s⁻¹ aggregated |
For detailed analyses of training dynamics, including loss and gradient norm charts, refer to the technical report.
Training emitted approximately 0.5 kg CO₂ equivalent, based on GPU usage and regional electricity factors.
For detailed technical information about the training process, methodology, and evaluation results, see the technical report.
unsloth/gemma-3n-E4B-it.mshojaei77/gemma-3n-E4B-persian-lora-adapters.mshojaei77/persian-gk.@misc{gemma3n_persian_2025,
title={Gemma-3N 4B Persian Fine-tuned Model},
author={Shojaei, M.},
year={2025},
publisher={Hugging Face},
url={https://huggingface.co/mshojaei77/gemma-3n-E4B-persian},
note={Fine-tuned using QLoRA on Persian General Knowledge dataset}
}
Dataset citation:
@misc{persian_gk_2025,
title={persian-gk: Persian General Knowledge Chat Dataset},
author={Shojaei, M. and Contributors},
year={2025},
url={https://huggingface.co/datasets/mshojaei77/persian-gk}
}
Licensed under the Gemma Terms of Use (https://ai.google.dev/gemma/terms). Downstream users must adhere to these terms.
Thanks to Google for the Gemma architecture, the Unsloth team for training tools, Hugging Face for hosting, and the Persian NLP community for contributions.