eSpeak NG is an open source speech synthesizer that supports more than hundred languages and accents.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

ar_rules 11KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384
  1. // * Arabic Language ar ar_rules
  2. // * This file writen by Taha Zerrouki 2012
  3. // ***************************************************************************
  4. // * This program is free software; you can redistribute it and/or modify *
  5. // * it under the terms of the GNU General Public License as published by *
  6. // * the Free Software Foundation; either version 3 of the License, or *
  7. // * (at your option) any later version. *
  8. // * *
  9. // * This program is distributed in the hope that it will be useful, *
  10. // * but WITHOUT ANY WARRANTY; without even the implied warranty of *
  11. // * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
  12. // * GNU General Public License for more details. *
  13. // * *
  14. // * You should have received a copy of the GNU General Public License *
  15. // * along with this program; if not, see: *
  16. // * <http://www.gnu.org/licenses/>. *
  17. // ***************************************************************************/
  18. //
  19. // This file is UTF-8 encoded
  20. // all words must be LOWER CASE (although the initial letter will be automatically
  21. // converted if it's a 7bit ascii character)
  22. // Text to phoneme rules for Arabic
  23. //
  24. // replace Arabic eastern character numbers with Arabic western character numbers
  25. .replace
  26. ٠ 0
  27. ۰ 0
  28. ۱ 1
  29. ١ 1
  30. ٢ 2
  31. ۲ 2
  32. ٣ 3
  33. ۳ 3
  34. ٤ 4
  35. ۴ 4
  36. ٥ 5
  37. ۵ 5
  38. ٦ 6
  39. ۶ 6
  40. ٧ 7
  41. ۷ 7
  42. ٨ 8
  43. ۸ 8
  44. ٩ 9
  45. ۹ 9
  46. ، ,
  47. ؛ ;
  48. //all vowels
  49. .L01 ا ي و َ ُ ِ ً ٌ ٍ ّ ى
  50. //short vowels (commonly unwritten )
  51. .L02
  52. //list of consonants
  53. .L03 ب پ ت ة ث ج ح خ د ذ ر ز س ش ص ض ط ظ ع غ ف ق ك ل م ن ئ ؤ ء أ آ إ ه
  54. // all Arabic characters without ا آ
  55. .L04 ض ص ث ق ف غ ع ه خ ح ج ً ٌ ٍ ، ؛ ش س ي ب ل ت ن م ك َ ُ ِ ّ ـ « » ظ ط ز ر ذ د ئ و ة ي ؤ إ أ ء پ گ
  56. // all Arabic characters without short vowels and A
  57. .L05 ض ص ث ق ف غ ع ه خ ح ج ش س ي ب ل ت ن م ك ظ ط ز ر ذ د ئ و ة ي ؤ إ أ ء پ گ
  58. // group of digits
  59. .L06 0 1 2 3 4 5 6 7 8 9
  60. // all Arabic characters
  61. .L09 ض ص ث ق ف غ ع ه خ ح ج ً ٌ ٍ ، ؛ ش س ي ب ل ا ت ن م ك َ ُ ِ ّ آ ـ « » ظ ط ز ر ذ د ئ و ة ي ژ ؤ إ أ ء ؟ پ گ
  62. // Arabic Sun characters
  63. .L10 ض ص ث ش س ل ت ن ظ ط ز ر ذ د
  64. // Arabic Moon characters
  65. .L11 ق ف غ ع ه خ ح ج ي ب م ك و إ أ ء
  66. // Arabic diacritics
  67. .L20 ۡ ـ ً ٌ ٍ َ ُ ِ ّ ْ
  68. .group آ
  69. آ ?a:
  70. .group ا
  71. L03) ا a: // if a consonant is before it, make the fatha long
  72. L03) ا (L03 a:
  73. ا (َ ?
  74. ا (ُ ?
  75. ا (ِ ?
  76. _) ا a // make the previous fatha long
  77. _) ال (L10P2 ?a //الشمس
  78. _) ال (L11P2 ?al //القمر
  79. _) ال (تP2 ?at
  80. _) ال (ثP2 ?aT
  81. _) ال (دP2 ?ad
  82. _) ال (ذP2 ?aD
  83. _) ال (رP2 ?ar
  84. _) ال (زP2 ?az
  85. _) ال (سP2 ?as
  86. _) ال (شّP2 ?a
  87. _) ال (شP2 ?aS
  88. _) ال (صP2 ?as[
  89. _) ال (ضP2 ?adH
  90. _) ال (ظP2 ?aZ
  91. _) ال (لP2 ?al
  92. _) ال (نP2 ?an
  93. _ب) ا (ل i
  94. .group أ
  95. أ a
  96. .group إ
  97. إ ?i
  98. .group ب
  99. ب b
  100. بّ b:
  101. ب (_ b
  102. _) بال (L10P3 bi //بالشمس
  103. _) بال (L11P3 bil //بالقمر
  104. _) بال (تP3 bit
  105. _) بال (ثP3 biT
  106. _) بال (دP3 bid
  107. _) بال (ذP3 biD
  108. _) بال (رP3 bir
  109. _) بال (زP3 biz
  110. _) بال (سP3 bis
  111. _) بال (شP3 biS
  112. _) بال (صP3 bis[
  113. _) بال (ضP3 bidH
  114. _) بال (طP3 bit[
  115. _) بال (ظP3 biZ
  116. _) بال (لP3 bil
  117. _) بال (نP3 bin
  118. .group پ
  119. پ p
  120. .group ت
  121. ت t
  122. ت (ّ t:
  123. ت (_ t
  124. ت (L20ّ t:
  125. _) ت (َP1 t
  126. _) ت (P1 ta //تسأل
  127. _َ) ت (P2 t
  128. ت (_S1 at //سألت
  129. تّ t:
  130. .group ث
  131. ث T
  132. .group ج
  133. ج dZ
  134. جّ dZdZ
  135. .group ح
  136. ح H
  137. .group خ
  138. خ X
  139. .group د
  140. د d
  141. د (ّ d:
  142. د (L20ّ d:
  143. .group ذ
  144. ذ D
  145. .group ر
  146. ر r
  147. .group ز
  148. ز z
  149. .group س
  150. س s
  151. س (ّ s:
  152. س (L20ّ s:
  153. .group ش
  154. ش S
  155. ش (ّ S:
  156. ش (L20ّ S:
  157. .group ص
  158. ص s[
  159. صّ s[s[
  160. .group ض
  161. ض dH
  162. .group ط
  163. ط t[
  164. .group ظ
  165. ظ Z
  166. .group ع
  167. ع A
  168. .group غ
  169. غ gH
  170. .group ف
  171. ف f
  172. ف (_ f
  173. _) فال (L10P3 fa //فالشمس
  174. _) فَال (L10P4 fa
  175. _) فَالْ (L10P4 fa
  176. _) فال (L11P3 fal //فالقمر
  177. _) فَال (L11P4 fa
  178. _) فَالْ (L11P4 fal
  179. _) فال (تP3 fat
  180. _) فال (ثP3 faT
  181. _) فال (دP3 fad
  182. _) فال (ذP3 faD
  183. _) فال (رP3 far
  184. _) فال (زP3 faz
  185. _) فال (سP3 fas
  186. _) فال (شP3 faS
  187. _) فال (صP3 fas[
  188. _) فال (ضP3 fadH
  189. _) فال (طP3 fat[
  190. _) فال (ظP3 faZ
  191. _) فال (لP3 fal
  192. _) فال (نP3 fan
  193. .group ق
  194. ق q
  195. .group ك
  196. ك k
  197. ك (_ k
  198. ك (_S1 ka // الضمير المتصل
  199. ك (ّ k:
  200. ك (L20ّ k:
  201. _) كال (L10P3 ka //كالشمس
  202. _) كَال (L10P4 ka
  203. _) كَالْ (L10P4 ka
  204. _) كال (L11P3 kal //كالقمر
  205. _) كَالْ (L11P4 kal
  206. _) كال (تP3 kat
  207. _) كال (ثP3 kaT
  208. _) كال (دP3 kad
  209. _) كال (ذP3 kaD
  210. _) كال (رP3 kar
  211. _) كال (زP3 kaz
  212. _) كال (سP3 kas
  213. _) كال (شP3 kaS
  214. _) كال (صP3 kas[
  215. _) كال (ضP3 kadH
  216. _) كال (طP3 kat[
  217. _) كال (ظP3 kaZ
  218. _) كال (لP3 kal
  219. _) كال (نP3 kan
  220. كم (_S2 kum //الضمير المتصل
  221. كما (_S3 kuma: //الضمير المتصل
  222. كن (_S2 kun:a //الضمير المتصل
  223. .group گ
  224. گ g
  225. .group ل
  226. ل l
  227. _ا) ل (L10 ' // Sun letters
  228. _بِا) ل (L10 ' // Sun letters
  229. _فَا) ل (L10 ' // Sun letters
  230. _كَا) ل (L10 ' // Sun letters
  231. ل (ّ l:
  232. ل (L20ّ l:
  233. _لِ) ل (L10 ' // Sun letters
  234. _وَا) ل (L10 ' // Sun letters
  235. .group م
  236. م m
  237. .group ن
  238. ن n
  239. ن (ب m
  240. ن (ْب m
  241. .group ه
  242. ه h
  243. ه (_ h
  244. ه (_S1 h // الضمير المتصل
  245. ها (_S2 ha: //الضمير المتصل
  246. هم (_S2 hum //الضمير المتصل
  247. هما (_S3 huma: //الضمير المتصل
  248. هن (_S2 hun:a //الضمير المتصل
  249. .group و
  250. L03) و u: //واو بعد صامت دون تشكيل
  251. ا) و w //واو بعد الألف
  252. و (L01 w //واو بعدها حرف علة
  253. ْ) و w // واو بعد سكون
  254. َ) و w //واو بعد فتحة
  255. ِ) و w //واو بعد كسرة
  256. _) و w //واو في أول الكلمة
  257. وا (_S2 u
  258. وا (_S2 u: // فعل مع ضمائر الجمع المذكرة درسوا
  259. _) وال (L10P3 wa //والشمس
  260. _) وَال (L10P4 wa
  261. _) وَالْ (L10P4 wa
  262. _) وال (L11P3 wal //والقمر
  263. _) وَال (L11P4 wal
  264. _) وَالْ (L11P4 wal
  265. _) وال (تP3 wat
  266. _) وال (ثP3 waT
  267. _) وال (دP3 wad
  268. _) وال (ذP3 waD
  269. _) وال (رP3 war
  270. _) وال (زP3 waz
  271. _) وال (سP3 was
  272. _) وال (شP3 waS
  273. _) وال (صP3 was[
  274. _) وال (ضP3 wadH
  275. _) وال (طP3 wat[
  276. _) وال (ظP3 waZ
  277. _) وال (لP3 wal
  278. _) وال (نP3 wan
  279. ون (_S2 u:na //جمع مذكر سالم فلاحون
  280. .group ي
  281. L03) ي i: // ياء بعد صامت دون تشكيل
  282. ا) ي j // ياء بعد ألف
  283. يِ ji:
  284. ْ) ي j //ياء بعد سكون
  285. ُ) ي j //ياء بعد ضمّة
  286. َ) ي j // ياء بعد فتحة
  287. _) ي j // ياء في أول الكلمة
  288. ي (L01 j //يا بعدها حروف علة
  289. ي (_S1 i
  290. يات (_S3 ij:a:t //يّة النسبة في جمع المؤنث جزائريات
  291. ية (_S2 ij:ah //يّة النسبة
  292. ين (_S2 i:na //جمع مذكر سالم منصوب أو مجرور
  293. يون (_S3 ij:u:n //kجمع مذكر سالم منسوب جزائريون
  294. يين (_S3 ij:i:n //kجمع مذكر سالم منسوب جزائريين
  295. .group ى //ألف مقصورة
  296. ى a
  297. L03) ى (_ a:
  298. .group ء
  299. ء ?
  300. ء (ً ?an
  301. .group ئ
  302. ئ j?
  303. _) ئ ?j
  304. .group ؤ
  305. ؤ w?
  306. _) ؤ ?w
  307. .group ة
  308. ة t
  309. ةً tan
  310. // Other diacritics
  311. .group
  312. ٍ (_S1 in // kasratan at the end of word
  313. ٌ (_S1 un // dammatan at the end of word
  314. ُ u // damma
  315. ُو u:
  316. َا a:
  317. ًا (_S2 an
  318. َى a:
  319. ٰ a: // superscript alef
  320. ِ i // kasra
  321. َ %a // fatha
  322. // Following are default rules for other diacritics and they are just silence.
  323. // Diacritics should be consumed together with leading letters in rules above.
  324. ٌ // dammatan
  325. ً // fathatan
  326. ٍ // kasratan
  327. ـ // tatweel
  328. ۡ // small high dotless head of khan
  329. ْ // sukun
  330. ّ // shadda
  331. // non-ascii characters with specified pronunciations
  332. // List the accented characters in en_list with the $accent attribute