LangChain Arabic
A published Python package that repairs Arabic model output for speech — restoring diacritics and reading numbers as words — as a drop-in LangChain parser.
- <5ms
- Dictionary latency
- 5
- Number contexts
- 2
- Dialects supported

What had to change
Arabic text-to-speech mispronounces undiacritised words and reads figures digit by digit, and language models return Arabic without diacritics most of the time. Every Arabic voice product ends up rewriting the same repair layer before a single word can be spoken.
What Louay built
Louay extracted that layer from a production Arabic RAG system, rebuilt it on LangChain's streaming parser base, and published it to PyPI. Deterministic longest-match diacritics replacement and context-aware number-to-word conversion, composed into a chain like any other parser.
What the work enabled
An installable package that drops into any chain as ArabicTextOutputParser and inherits streaming, batching and composition for free — filling a gap an ecosystem of hundreds of integrations had left open.