Metadata-Version: 2.4
Name: arabickit
Version: 0.1.0
Summary: Arabic text cleanup: tashkeel, letter variants, digits.
Author: episodely
License: MIT
Project-URL: Homepage, https://github.com/episodely/arabickit
Project-URL: Issues, https://github.com/episodely/arabickit/issues
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Operating System :: OS Independent
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Dynamic: license-file

# arabickit

Small, dependency-free helpers to clean and normalize Arabic text before search, comparison, NLP or LLM prompts. Works as a library or a CLI.

```python
from arabickit import clean, strip_tashkeel, digits_to_ascii

clean("  أَهْلاً   بِكَ  ١٢  ")      # 'اهلا بك 12'
strip_tashkeel("بِسْمِ اللَّهِ")      # 'بسم الله'
digits_to_ascii("٢٠٢٦")               # '2026'
```

```
echo "أَهْلاً بِكَ ١٢" | python arabickit.py
```

## Install

```
pip install arabickit
```

Or copy `arabickit.py` into your project, it has no dependencies.

## Functions

| Function | What it does |
|---|---|
| `strip_tashkeel` | remove harakat and Quranic marks |
| `strip_tatweel` | remove kashida (ـ) |
| `normalize_letters` | أ إ آ ٱ -> ا, ى -> ي |
| `normalize_ta_marbuta` | ة -> ه (optional, lossy) |
| `digits_to_ascii` / `digits_to_arabic` | Arabic-Indic and Persian digits <-> 0-9 |
| `normalize_punct` | ، ؛ ؟ -> , ; ? |
| `clean` | the usual combination in one call |

Normalization is lossy by design (good for matching, not for display). Keep the original text if you need to show it.

```
python -m pytest
```

MIT licensed.
