Text-to-Speech
F5-TTS
Algerian Arabic
algerian-nlp
algerian-darija
darja
arabic
tts
dit
voice-cloning
north-africa

Run this model with HF Jobs

Run algerian-nlp/EL-HARRACHI on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.

Paste one of these prompts into your coding agent:

Fine-tune on my dataset

Use HF Jobs to fine-tune https://huggingface.co/algerian-nlp/EL-HARRACHI. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.

Run batch inference

Use HF Jobs to run batch inference with https://huggingface.co/algerian-nlp/EL-HARRACHI on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.

EL-HARRACHI

EL-HARRACHI (الحراشي) is a flow-matching Diffusion Transformer (DiT) text-to-speech and zero-shot voice-cloning model for Algerian Darija (arq), fine-tuned for 48,574 steps on 69,066 filtered Algerian utterances (~399 hours) spanning conversational podcasts, expressive stories, and oral folklore.

Formal speech-quality evaluation (MOS, intelligibility, speaker similarity) has not yet been measured; an interactive demo is available at f5tts-algerian-darja-demo.streamlit.app.

Task Text-to-Speech (TTS) & Zero-Shot Voice Cloning
Architecture F5-TTS Flow-Matching DiT (dim 1,024 / depth 22 / heads 18) + Vocos Vocoder
Audio Output 24 kHz mono WAV (100 mel channels)
Vocabulary 2,580 character tokens (vocab.txt included in repo)
License (Weights) Apache-2.0
Author(s) Kamel Touati, Algerian NLP Collective

Quickstart

Install dependencies:

pip install f5-tts huggingface_hub torch

Python Model Loading

Both model_last.pt and vocab.txt ship directly inside this repository:

import torch
from huggingface_hub import hf_hub_download
from f5_tts.model import CFM, DiT
from f5_tts.model.utils import get_tokenizer

REPO = "algerian-nlp/EL-HARRACHI"
ckpt_path = hf_hub_download(REPO, "model_last.pt")
vocab_path = hf_hub_download(REPO, "vocab.txt")

vocab_char_map, vocab_size = get_tokenizer(vocab_path, "custom")

model = CFM(
    transformer=DiT(
        dim=1024, depth=22, heads=18, ff_mult=2,
        text_dim=512, text_mask_padding=False,
        conv_layers=8, pe_attn_head=1,
        text_num_embeds=vocab_size, mel_dim=100,
    ),
    mel_spec_kwargs=dict(
        n_fft=1024, hop_length=256, win_length=1024,
        n_mel_channels=100, target_sample_rate=24000,
        mel_spec_type="vocos",
    ),
    vocab_char_map=vocab_char_map,
)

ckpt = torch.load(ckpt_path, map_location="cpu", weights_only=False)
model.load_state_dict(ckpt["ema_model_state_dict"], strict=False)
model.eval()

CLI Inference

f5-tts_infer-cli \
  --ckpt_file model_last.pt \
  --vocab_file vocab.txt \
  --ref_audio reference_darja.wav \
  --ref_text "واش راك خويا، كلشي لاباس؟" \
  --gen_text "النص اللي تبغي تولدو بالدارجة الجزائرية" \
  --output_dir ./output

Audio & Text Preparation Notes

Resample reference audio to 24,000 Hz mono float32 (clean 5–12 s clip with an accurate transcript). Keep French loanwords in Latin script rather than transliterating them into Arabic, and apply the training text normalizer before synthesis:

import re

_FR_TAG_RE = re.compile(r"\[\s*(?:French|FR)\s*:\s*(.*?)\]", re.IGNORECASE)
_BRACKET_RE = re.compile(r"\[.*?\]|<.*?>|\(.*?\)")
_NOISE_CHARS = re.compile(r"[*#@~_^&%$+=/\\|{}\[\]`\"«»]")

def normalize_darja(text: str) -> str:
    text = _FR_TAG_RE.sub(r"\1", text)
    text = _BRACKET_RE.sub("", text)
    text = _NOISE_CHARS.sub("", text)
    text = text.replace("ـ", "")
    text = text.replace("إ", "ا").replace("أ", "ا").replace("آ", "ا")
    text = text.replace("ى", "ي")
    return " ".join(text.split()).strip()

Evaluation

Evaluation status: Formal TTS evaluation (MOS listening tests, ASR round-trip intelligibility, and speaker similarity) is currently unmeasured. No held-out TTS test partition or baseline comparison has been scored yet. The 0.4950 figure recorded in Training Details is a single-batch training loss, not an evaluation metric.

Note on anchor suites: DziriEval and MADAR are text-only suites and do not evaluate speech synthesis.


Intended Use & Scope

Recommended uses:

  • Algerian Darija speech synthesis for narration, storytelling, dubbing, voice-assistant output, and accessibility reading.
  • Starting point for fine-tuning custom Algerian voice models.

Out-of-scope uses:

  • Speech recognition or translation.
  • Languages or dialects outside Algerian Darija.
  • Cloning or impersonating any person's voice without their explicit consent.
  • Automated decisions affecting individuals.

Heavy French code-switching renders best when French words remain in Latin script. This model has not been evaluated for bias, toxicity, or factuality.


Architecture

Component Specification
Initialization IbrahimSalah/Arabic-F5-TTS-v2 (547,500-step Arabic checkpoint, step and optimizer state reset before fine-tuning)
Backbone Flow-Matching Diffusion Transformer (DiT): dim 1,024, depth 22, 18 heads, ff_mult=2, 8 conv layers
Text Conditioning text_dim=512, text_mask_padding=False
Mel & Vocoder n_fft=1024, hop_length=256, win_length=1024, 100 mel channels, Vocos, 24,000 Hz
Vocabulary 2,580 non-empty character tokens (vocab.txt)
Training Utterance Length Filtered to 2.0–12.0 s during training
Objective Full DiT flow-matching fine-tuning (all parameters trainable)

Before fine-tuning, step counters and optimizer momentum from the upstream Arabic checkpoint were stripped, and gradient checkpointing was enabled to fit 16 GB VRAM.


Training Data

Streamed and resampled on the fly to 24,000 Hz mono float32 from three OddAdmix Algerian speech collections, filtered to 2.0–12.0 s duration and 1.0–25.0 chars/sec density (69,066 retained of 77,150 raw utterances, 89.5% overall retention):

Subset Domain Raw Utterances Filtered Utterances Duration
Kahwa podcast Conversational / spontaneous 23,264 23,264 ~110 h
Loubna stories Expressive narratives 48,590 41,301 ~237 h
Rawi folklore Cultural oral folklore 5,296 4,501 ~52 h
Total Multi-domain 77,150 69,066 ~399 h

Decontamination: Unmeasured; no held-out TTS test partition or train/test audio deduplication is documented.

Training Data License Composition

The model weights are released under Apache-2.0. That grant applies to the weights and card only and does not relicense the underlying audio.

Tier Utterances Share
other (unresolvable Hub license on all three OddAdmix collections) 77,150 raw (69,066 filtered) 100.0%

Training Details

Parameter Value
Objective Flow-matching TTS fine-tuning of the full DiT
Optimizer AdamW 8-bit (bitsandbytes), peak lr=2e-5, max_grad_norm=1.0 (betas unrecorded)
Batch Size 2,000 mel-frames × 6 accumulation = ~12,000 frames/step
Schedule Cosine annealing, 2,000-step warmup
Steps 48,574 across 8 multi-session Kaggle runs (Sep 20–23, 2026)
Regularization Gradient checkpointing (checkpoint_activations=True)
Precision FP16 mixed precision
Hardware & Duration 1× NVIDIA Tesla T4 (16 GB), multi-session (~12 h per Kaggle session)
Seed Unrecorded
Run Log W&B k_touati-estin/f5tts-algerian-darja

Multi-Session Resume Progression

Each session resumed from model_last.pt. Per-session final losses are single-batch training values rather than a held-out validation curve:

Session Run ID Date Steps Reached Final Batch Loss Status
1 wxcxx3mi Sep 20 0 — Setup/env error
2 ymp61rc4 Sep 20 2 1.0581 Setup/env error
3 cknieh8f Sep 20 969 0.4266 Session time limit
4 m2zoj7ak Sep 20 0 — Setup/env error
5 hniwvpbu Sep 21 13,214 0.9916 Session time limit
6 gyrlliys Sep 22 26,014 1.1612 Session time limit
7 zyah6mu2 Sep 22 38,865 0.4460 Session time limit
8 tk464wii Sep 23 48,574 0.4950 Completed

Limitations

  • Speech quality is unmeasured. No MOS listening study, ASR intelligibility score, or speaker-similarity benchmark has been run on this checkpoint yet.
  • Small speaker set. The three OddAdmix collections reflect a limited set of speakers, so synthesized outputs may resemble those voices; voice cloning without consent is out of scope.
  • Domain and accent scope. Training covers Kahwa, Loubna, and Rawi (Central/Western registers); Eastern, Saharan, and heavily French-matrix speech are outside measured coverage.
  • No documented test partition. Without a held-out TTS test set, train/test separation is unmeasured.
  • No safety evaluation. Bias, toxicity, and audio misuse safeguards have not been evaluated.

Repository Contents

File Size Description / SHA-256
model_last.pt 3.54 GB Final checkpoint at step 48,574 (ema_model_state_dict) · SHA-256 940fb1930b522b50213ef03c815a77364584c83fe9cecf5efa10f887f93265cc
vocab.txt 11.4 KB 2,580-token character vocabulary
F5TTS_Base_8_18.yaml 1.9 KB DiT + Vocos model configuration

Intermediate checkpoints (model_48000.pt, model_48500.pt) and training audio are excluded.


The name

Dahmane El Harrachi (1926–1980), born Abderrahmane Amrani in El Harrach, Algiers, was one of the defining voices and mandole masters of Algerian Chaâbi music. His songs — most famously Ya Rayah (1973) — gave unmistakable voice to everyday working-class life, exile, and Algerian street poetry across decades.

His vocal delivery remains woven into how Algerian Darija is remembered and heard. Naming the collective's speech synthesis family after him honors that legacy: building technology that speaks Algerian Darija naturally.

The naming is homage and implies no endorsement.


Citation

@misc{algerian_nlp_el_harrachi_2026,
  title  = {EL-HARRACHI: Flow-Matching Speech Synthesis for Algerian Darija},
  author = {Touati, Kamel and Algerian NLP Collective},
  year   = {2026},
  url    = {https://huggingface.co/algerian-nlp/EL-HARRACHI}
}

Upstream initialization checkpoint:

@misc{salah_arabic_f5_tts_v2,
  title  = {Arabic-F5-TTS-v2},
  author = {Salah, Ibrahim},
  url    = {https://huggingface.co/IbrahimSalah/Arabic-F5-TTS-v2}
}

License

Weights and card are released under Apache-2.0. Refer to the Training Data License Composition section above regarding the underlying audio before redistributing derivatives.

Downloads last month
304
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Datasets used to train algerian-nlp/EL-HARRACHI

Collection including algerian-nlp/EL-HARRACHI