You need to agree to share your contact information to access this dataset

This repository is publicly accessible, but you have to accept the conditions to access its files and content.

Log in or Sign Up to review the conditions and access this dataset content.

YAML Metadata Warning:The task_categories "conditional-text-generation" is not in the official list: text-classification, token-classification, table-question-answering, question-answering, zero-shot-classification, translation, summarization, feature-extraction, text-generation, fill-mask, sentence-similarity, text-to-speech, text-to-audio, automatic-speech-recognition, audio-to-audio, audio-classification, audio-text-to-text, voice-activity-detection, depth-estimation, image-classification, object-detection, image-segmentation, text-to-image, image-to-text, image-to-image, image-to-video, unconditional-image-generation, video-classification, reinforcement-learning, robotics, tabular-classification, tabular-regression, tabular-to-text, table-to-text, multiple-choice, text-ranking, text-retrieval, time-series-forecasting, text-to-video, image-text-to-text, image-text-to-image, image-text-to-video, visual-question-answering, document-question-answering, zero-shot-image-classification, graph-ml, mask-generation, zero-shot-object-detection, text-to-3d, image-to-3d, image-feature-extraction, video-text-to-text, keypoint-detection, visual-document-retrieval, any-to-any, video-to-video, other

🇹🇯 Tajik Spelling Correction Pairs (Clean ↔ Noisy)

A parallel corpus for training automatic spelling correction models for the Tajik language. Each record contains an original cleaned text (clean_text) and its version with artificially introduced typos and errors (noisy_text).

📖 Description

This dataset was created by merging four distinct Tajik language resources:

All texts underwent multi‑stage cleaning:

  • Removal of HTML tags, timestamps, and boilerplate prefixes/suffixes.
  • Normalization of Tajik characters (correcting common OCR/encoding errors).
  • Deletion of bracketed content containing non‑Tajik characters (e.g., Russian, Arabic).
  • Deduplication and filtering of very short texts.

After cleaning, realistic synthetic errors were injected:

  • Replacement of specific Tajik letters with visually or phonetically similar Russian/Latin characters (e.g., ҷч, ғг).
  • Random substitution with Russian letters (keyboard layout errors).
  • Alt‑combination special symbols (e.g., ғ=).
  • Character swaps, duplications, deletions, and insertions.
  • Word‑boundary mistakes (word merging).

The resulting dataset is ideal for training seq2seq models (T5, mBART, ByT5) for Tajik spelling and typo correction.

📊 Dataset Statistics

Total records: 119,625

Split Records Avg Clean Len Avg Noisy Len
Train 95,700 2086.9 2115.4
Validation 11,962 2103.5 2132.2
Test 11,963 2065.8 2094

📁 Data Format

The dataset is provided as a Hugging Face DatasetDict with three splits: train, validation, test.

Each record contains two string fields:

Field Type Description
clean_text string The original cleaned Tajik text
noisy_text string The same text with synthetic typos

📝 Examples

Example 1

  • Clean: Сангтӯда-1 аз пардохти фоизҳо аз қарзи андоз дар соли 2021 озод шуд Кумитаи андози назди ҳукумати Тоҷикистон соли оянда ба қарзи ҶСК НБО Сангтӯда-1 аз андоз, ки аз ҳисоби интиқоли барқ ба ШСХК Барқи т...
  • Noisy: Сангтӯда-1 аД пардохти фоиззҳо аз қЫрзи яандз дар соли 2021 озод шуд КумитЧи андози назди ҳукуюмат ТТоҷикистон соли оянда ба йарзи ҶСК Н%БО Сангтӯда-1 аз аандоз, ки аз ҳисоби интиқолВ бҷарқ ба ШСХК Ба...

Example 2

  • Clean: Планшет не, китоб харед! Омӯзишиилмуҳунардарҳаётиинсоннақшибасобориздорад. Фарди бомаърифат, оқил, соҳибхирадва ҳунармандҳарҷобиравад, бологузар ва маҳбубимардумонхоҳадгашт, зеронафъаш ба ҳамахурду ка...
  • Noisy: Планшет н, ькТитоб харед! Оӯшишиимуҳунардарҳаёттихинсоннақшияасобшриздорад. Фарди бома/ърифат, оқил, сҳоибхВрадва ҳунармандҳар'ҷобиравад, бологузар ва маҳбубимардумонохҳадгашт, зЗронафаъН ба хамахцрду...

Example 3

  • Clean: Тими наврасони Тоҷикистон бо шикаст додани Эрон ба Ҷоми ҷаҳон роҳ ёфт Шарҳҳоро бинедБозии даври сеюми гурӯҳи миёни дастаҳои мунтахаби наврасони Эрону Тоҷикистон шаби ҷумъаи 11-уми апрел даршаҳри Ҷидда...
  • Noisy: Тиими навеасони ТоҷикистГн бо шиаст дораЭи Эронн ба Цоми ҷаҳон роҳ ёфт Шарҳҳоро бинедБозии даври сеюми гурӯҳи миёни дастаҳои ммунЕахаби наврасони Эрону ТоҷикисЛо шаби ҷёмъаи 11-уми апрел драшаҳри МҶид...

🚀 Usage

Load with 🤗 Datasets

from datasets import load_dataset

dataset = load_dataset("TajikNLPWorld/tajik-spelling-correction-pairs")
print(dataset["train"][0])

Use in a training pipeline

from transformers import AutoTokenizer, AutoModelForSeq2SeqLM

tokenizer = AutoTokenizer.from_pretrained("google/mt5-small")
model = AutoModelForSeq2SeqLM.from_pretrained("google/mt5-small")

def preprocess(examples):
    inputs = tokenizer(examples["noisy_text"], max_length=512, truncation=True)
    targets = tokenizer(examples["clean_text"], max_length=512, truncation=True)
    inputs["labels"] = targets["input_ids"]
    return inputs

train_dataset = dataset["train"].map(preprocess, batched=True)

📜 License

This dataset is released under the Apache License 2.0.

🤝 Citation

If you use this dataset, please cite:

@dataset{tajik_spelling_correction_pairs,
    title = {Tajik Spelling Correction Pairs},
    author = {Arabov Mullosharaf Kurbonovich and TajikNLPWorld},
    year = {2025},
    publisher = {Hugging Face},
    url = {https://huggingface.co/datasets/TajikNLPWorld/tajik-spelling-correction-pairs}
}

Generated for the Tajik NLP community

Downloads last month
14