Browse Source

Merge remote-tracking branch 'valdisvi/master'

master
Reece H. Dunn 7 years ago
parent
commit
2aa7c5a1de

+ 1
- 0
CHANGELOG.md View File

@@ -44,6 +44,7 @@ new languages:

* hak (Hakka Chinese) -- Chen Chien-ting
* ht (Haitian Creole) -- Valdis Vitolins
* shn (Shan Tay Yai) -- ronaldaug

updated languages:


+ 5
- 5
Makefile.am View File

@@ -370,6 +370,7 @@ phsource/phonemes.stamp: \
phsource/ph_s_gaelic \
phsource/ph_serbian \
phsource/ph_setswana \
phsource/ph_shan \
phsource/ph_sinhala \
phsource/ph_slovak \
phsource/ph_slovenian \
@@ -520,6 +521,7 @@ dictionaries: \
espeak-ng-data/ro_dict \
espeak-ng-data/ru_dict \
espeak-ng-data/sd_dict \
espeak-ng-data/shn_dict \
espeak-ng-data/si_dict \
espeak-ng-data/sk_dict \
espeak-ng-data/sl_dict \
@@ -759,6 +761,9 @@ endif
sd: espeak-ng-data/sd_dict
espeak-ng-data/sd_dict: dictsource/sd_list dictsource/sd_rules dictsource/sd_extra dictsource/sd_emoji

shn: espeak-ng-data/shn_dict
espeak-ng-data/shn_dict: dictsource/shn_list dictsource/shn_rules dictsource/shn_extra

si: espeak-ng-data/si_dict
espeak-ng-data/si_dict: dictsource/si_list dictsource/si_rules dictsource/si_extra dictsource/si_emoji

@@ -841,7 +846,6 @@ dictsource/zhy_emoji:
mbrola: \
espeak-ng-data/mbrola_ph/af1_phtrans \
espeak-ng-data/mbrola_ph/ar1_phtrans \
espeak-ng-data/mbrola_ph/ar2_phtrans \
espeak-ng-data/mbrola_ph/ca_phtrans \
espeak-ng-data/mbrola_ph/cr1_phtrans \
espeak-ng-data/mbrola_ph/cs_phtrans \
@@ -888,10 +892,6 @@ espeak-ng-data/mbrola_ph/ar1_phtrans: phsource/mbrola/ar1 src/espeak-ng
mkdir -p espeak-ng-data/mbrola_ph
ESPEAK_DATA_PATH=$(PWD) src/espeak-ng --compile-mbrola=phsource/mbrola/ar1

espeak-ng-data/mbrola_ph/ar2_phtrans: phsource/mbrola/ar2 src/espeak-ng
mkdir -p espeak-ng-data/mbrola_ph
ESPEAK_DATA_PATH=$(PWD) src/espeak-ng --compile-mbrola=phsource/mbrola/ar2

espeak-ng-data/mbrola_ph/ca_phtrans: phsource/mbrola/ca src/espeak-ng
mkdir -p espeak-ng-data/mbrola_ph
ESPEAK_DATA_PATH=$(PWD) src/espeak-ng --compile-mbrola=phsource/mbrola/ca

+ 42
- 28
dictsource/ar_rules View File

@@ -73,6 +73,9 @@
// Arabic Moon characters
.L11 ق ف غ ع ه خ ح ج ي ب م ك و إ أ ء

// Arabic diacritics
.L20 ۡ ـ ً ٌ ٍ َ ُ ِ ّ ْ

.group آ
آ ?aa

@@ -132,11 +135,13 @@

.group ت
ت t
ت (ّ t:
ت (L20ّ t:
_) ت (َP1 t
_) ت (P1 ta //تسأل
_َ) ت (P2 t
ت (_S1 at //سألت
تّ tt
تّ t:

.group ث
ث T
@@ -153,7 +158,8 @@

.group د
د d
دّ dd
د (ّ d:
د (L20ّ d:

.group ذ
ذ D
@@ -166,11 +172,13 @@

.group س
س s
سّ ss
س (ّ s:
س (L20ّ s:

.group ش
ش S
شّ SS
ش (ّ S:
ش (L20ّ S:

.group ص
ص s[
@@ -220,6 +228,8 @@
.group ك
ك k
ك (_S1 ka // الضمير المتصل
ك (ّ k:
ك (L20ّ k:
_) كال (L10P3 ka //كالشمس
_) كَال (L10P4 ka
_) كَالْ (L10P4 ka
@@ -240,8 +250,8 @@
_) كال (لP3 kal
_) كال (نP3 kan
كم (_S2 kum //الضمير المتصل
كما (_S3 kumaa //الضمير المتصل
كن (_S2 kunna //الضمير المتصل
كما (_S3 kuma: //الضمير المتصل
كن (_S2 kun:a //الضمير المتصل

.group گ
گ g
@@ -252,7 +262,8 @@
_بِا) ل (L10 ' // Sun letters
_فَا) ل (L10 ' // Sun letters
_كَا) ل (L10 ' // Sun letters
لّ ll
ل (ّ l:
ل (L20ّ l:
_لِ) ل (L10 ' // Sun letters
_وَا) ل (L10 ' // Sun letters

@@ -267,13 +278,13 @@
.group ه
ه h
ه (_S1 h // الضمير المتصل
ها (_S2 haa //الضمير المتصل
ها (_S2 ha: //الضمير المتصل
هم (_S2 hum //الضمير المتصل
هما (_S3 humaa //الضمير المتصل
هن (_S2 hunna //الضمير المتصل
هما (_S3 huma: //الضمير المتصل
هن (_S2 hun:a //الضمير المتصل

.group و
L03) و uu //واو بعد صامت دون تشكيل
L03) و u: //واو بعد صامت دون تشكيل
ا) و w //واو بعد الألف
و (L01 w //واو بعدها حرف علة
ْ) و w // واو بعد سكون
@@ -281,7 +292,7 @@
ِ) و w //واو بعد كسرة
_) و w //واو في أول الكلمة
وا (_S2 u
وا (_S2 uu // فعل مع ضمائر الجمع المذكرة درسوا
وا (_S2 u: // فعل مع ضمائر الجمع المذكرة درسوا
_) وال (L10P3 wa //والشمس
_) وَال (L10P4 wa
_) وَالْ (L10P4 wa
@@ -302,38 +313,39 @@
_) وال (ظP3 waZ
_) وال (لP3 wal
_) وال (نP3 wan
ون (_S2 uuna //جمع مذكر سالم فلاحون
ون (_S2 u:na //جمع مذكر سالم فلاحون

.group ي
L03) ي ii // ياء بعد صامت دون تشكيل
L03) ي i: // ياء بعد صامت دون تشكيل
ا) ي j // ياء بعد ألف
يِ jii
يِ ji:
ْ) ي j //ياء بعد سكون
ُ) ي j //ياء بعد ضمّة
َ) ي j // ياء بعد فتحة
_) ي j // ياء في أول الكلمة
ي (L01 j //يا بعدها حروف علة
ي (_S1 i
ي (_S1 ii //ياء النسبة
يات (_S3 ijjaat //يّة النسبة في جمع المؤنث جزائريات
ية (_S2 ijjah //يّة النسبة
ين (_S2 iina //جمع مذكر سالم منصوب أو مجرور
يون (_S3 ijjuun //kجمع مذكر سالم منسوب جزائريون
يين (_S3 ijjiin //kجمع مذكر سالم منسوب جزائريين
يات (_S3 ij:aat //يّة النسبة في جمع المؤنث جزائريات
ية (_S2 ij:ah //يّة النسبة
ين (_S2 i:na //جمع مذكر سالم منصوب أو مجرور
يون (_S3 ij:u:n //kجمع مذكر سالم منسوب جزائريون
يين (_S3 ij:i:n //kجمع مذكر سالم منسوب جزائريين

.group ى //ألف مقصورة
ى a
L03) ى (_ aa
L03) ى (_ a:

.group ء
ء ?
ء (ً ?an

.group ئ
ئ ?
ئ j?
_) ئ ?j

.group ؤ
ؤ ?
ؤ w?
_) ؤ ?w

.group ة
ة t
@@ -344,10 +356,11 @@
ٍ (_S1 in // kasratan at the end of word
ٌ (_S1 un // dammatan at the end of word
ُ u // damma
ُو uu
َا aa
َى aa
ٰ aa // superscript alef
ُو u:
َا a:
ًا (_S2 an
َى a:
ٰ a: // superscript alef
ِ i // kasra
َ %a // fatha

@@ -360,6 +373,7 @@
ـ // tatweel
ۡ // small high dotless head of khan
ْ // sukun
ّ // shadda

// non-ascii characters with specified pronunciations
// List the accented characters in en_list with the $accent attribute

+ 5
- 0
dictsource/lv_list View File

@@ -250,6 +250,7 @@ kur $u+
labad $u
lai $u+
līdz $u+
lūk $u+
ļoti $u+
nav $u+
nedz $u $brk
@@ -270,6 +271,8 @@ pie $u
pirms $u+
pret $u+
priekš $u
projām $u+
prom $u+
protams $u+
sauc $u+
starp $u
@@ -279,6 +282,7 @@ taču $u $pause
tad $u+
tagad $u+
tas $u+
tātad $u+ $pause
te $u+
tiek $u+
tikai $u+
@@ -436,6 +440,7 @@ vismaz $2
(it sevišķi) it||seviSci $u2+
(kaut arī) kaut||aRi: $u2+
(kaut cik) kaut||tsik $u2+
(kaut gan) kaut||gan $u2+
(kaut kad) kaut||kad $u2+
(kaut kam) kaut||kam $u2+
(kaut kas) kaut||kas $u2+

+ 32
- 8
dictsource/lv_rules View File

@@ -224,6 +224,7 @@
_b) e (z_ e
_b) e (z+ e
_C) e (_ e // re, te, ve
c) e (nL83+ e
c) e (tur e
č) e (tr e
d) ebe (L83 ebe
@@ -247,6 +248,7 @@
e (strāL72 e
etno etno
_) e (vL04_+ e // Eva
e (vol e
g) e (t e
gr) e (dz E
gr) e (z E
@@ -256,6 +258,7 @@
int) ere (L83 eRe
_j) e (b_ e
_j) e (l_ e
kur) e (n e
_ķ) eme (rL01_ eme // Ķemeri
_L20) e (sam_+ _!e // esam
_L20) e (sat_+ _!e // esat
@@ -275,12 +278,15 @@
ņ) e (m e
orķ) e e
p) e (rs e
pr) ece (den etse
pr) e (cL52z e
pr) e (L71L05_ e // prece
pr) e (s e
_pr) e (t e
pr) etē (@ ete:
proc) e (s e
r) ecep (L88L05_ etsep // recepte
r) e (dak e
r) e (dz e
r) e (pub e
r) e (put e
@@ -295,6 +301,7 @@
_s) evastopo (lL05_ evastopo: // Sevastopole
_s) e (v_ e // sev
_s) e (vi_ e
sp) e (ķ e
st) e (nd e
str) e (s e
t) e (c+ e
@@ -303,6 +310,7 @@
t) e (km e
t) ele ele
_t) e (mp e
t) ende (n ende
t) ermo eRmo
t) e (st e
_t) e (v_ e // tev
@@ -376,11 +384,13 @@
// specific words ------------------------------------------------------------------- //
ap) ē (d+ e:
b) ē (g@ e:
C) ē (ts_ e:
cilv) ē (L75 E:
d) ē (ļ_+ e:
d) ē (vē e:
dv) ēse (L77 e:se
dz) ē (t e:
dz) ē (rL89 e:
dz) ē (t e:
ēcē e:tse:
ēdē e:de:
ē (kL04_+ E: // ēka
@@ -401,6 +411,7 @@
m) ē (L77L05+ e: // mēle
m) ēne (L83 e:ne
m) ē (rķ e:
m) ē (rL71 e:
_m) ē (s_ e: // mēs
_n) ē (_ e:
ņ) ē (m++ e:
@@ -409,6 +420,7 @@
_p) ē (c+ e:
p) ē (dL04_ E:
_p) ē (rL01_ e: // pērs
p) ē (rn E:
p) ēte (r e:te // Pēter..
piem) ē (r E:
sāp) ē (+ e:
@@ -467,6 +479,8 @@

.group k
k k
_) kaut (_ k,aut // secondary stress as average between verb and particle
_) klāt (_ kl,a:t // ... and similarly
k (ļ k} // tiny pause between k and ļ

.group ķ
@@ -497,6 +511,8 @@
l) n (C n // but not after (lengthened) l
L59) n (@ :n
n (d N
_) ne (kād n%e
_) ne (vienādo n'e
ne (vienl+ n'e // nevienlīdzība
ne (vienmērīg n'e // nevienmērīgi
_) ne (vien n%e // stress on 2nd syllable
@@ -797,7 +813,7 @@ L46L45L45) o (<< uo
versm) o uo // versmo
viegl) o (+ uo
vizm) o uo
zil) o (L80 uo
zil) o (L80+ uo
žēl) o (L65+ uo
žir) o o

@@ -811,6 +827,8 @@ L46L45L45) o (<< uo
g) ob (e ob
k) ob ob
l) ob (ē ob
_l) ob (ij ob
_l) ob (is ob
l) oboto (m oboto
m) ob ob
_) ob (amL01_ ob // Obama
@@ -916,6 +934,7 @@ L46L45L45) o (<< uo
l) oj (L50 oj
_ob) oj (L04_ oj // oboja
_) oj (ārL01_ oj // Ojārs
_pr) oj (ām_ uoj
pr) oj (L42 oj
_tr) oj (L04_ oj // Troja
z) oj (L01_+ oj // ..zojs
@@ -1089,6 +1108,7 @@ L46L45L45) o (<< uo
b) om (zL02_ om // bomzis
br) om om
c) om (_ om
_č) om (L01_ om
d) om (in om
d) om (nL04_ om // domna
dr) om (L01_ o:m // ..droms
@@ -1151,6 +1171,7 @@ L46L45L45) o (<< uo
b) on (ē on
b) on (us on
br) on on
cens) on uon
daig) on uon
dail) on uon
dalt) on o:n
@@ -1209,7 +1230,7 @@ L46L45L45) o (<< uo
on (ijL04_ o:n
on (ist o:n
on (ko oN
_) on (kuL77L02_ oN // onkulis
on (kuL77 oN
on (L01_+ o:n // ..ons
on (l oN
onn onnn
@@ -1250,9 +1271,8 @@ L46L45L45) o (<< uo
z) oo oo:

.group op

L41Jsk) op (L01_ o:p // ...skops
ad) op op
att) op uop
cikl) op (L01_ o:p // ciklops
d) op op
eir) op (L04_ o:p
@@ -1267,13 +1287,14 @@ L46L45L45) o (<< uo
k) op (ē_ op // ..kopē
k) op (ij op // ..kopij..
k) op (j uop // ..kopj..
k) op (L65+ uop // ..kuop..
k) op (L04_+ uop // ..kopa
k) op (L65+ uop // ..kuop..
k) opo uopuo
k) op (pr uop // ..koppr..
k) op (ulā op
k) op (ulē op
kr) op (ļo uop
L41Jsk) op (L01_ o:p // ...skops
l) op (L01_+ uop
m) op op
net) op (_ uop
@@ -1296,6 +1317,7 @@ L46L45L45) o (<< uo
_p) op (L05_ uop // Pope
p) op op
pr) op op
sast) op uop
sk) op (ijL04_ o:p // ..skopija
sk) op (is o:p
sk) op (L01_ o:p // ..skops
@@ -1303,7 +1325,6 @@ L46L45L45) o (<< uo
s) op (r op
st) opo (s_ uopuo // ..stopos
_str) op (L01_ uop // strops
_t) op uo`p // top with short uo because of ambiguity
_t) op (āzL01_ op // topāzs
_t) op (b op // topbura
_t) op (inam op // topinambūrs
@@ -1314,6 +1335,7 @@ L46L45L45) o (<< uo
_t) opol opol
_t) opon opon
t) opot uopuot
_t) op uo`p // top with short uo because of ambiguity
tr) op o:p
ut) op (i o:p

@@ -1551,6 +1573,7 @@ L46L45L45) o (<< uo
n) ov (āci ov
n) ov (elL05_ ov // novele
_n) ov (emb ov // novembris
n) ov (ēr uov
n) ov (it ov
n) ov (L04_ ov // nova
n) ov (o ov
@@ -1558,8 +1581,8 @@ L46L45L45) o (<< uo
_pl) ov (L01_ ov // plovs
pr) ov (an ov
pr) ov (in ov
pr) ov (L52z ov
pr) ov (L05_ uov // prove
pr) ov (L52z ov
pr) ovo ovo
r) ov ov
sl) ov ov
@@ -1685,6 +1708,7 @@ L46L45L45) o (<< uo
y y // y is used instead of simple "i", to distinguish them in writing
y (A y_|
y (_ y: // for international words
y (outub y

.group z
z z

+ 24
- 0
dictsource/shn_list View File

@@ -0,0 +1,24 @@
// numbers

_0 son // သူၼ်
_1 nEN3 // ၼိုင်ႈ
_2 sON // သွင်
_3 sa:m // သၢမ်
_4 si:2 // သီႇ
_5 ha:3 // ႁႃႈ
_6 hok4 // ႁူၵ်း
_7 tS;et4 // ၸဵတ်း
_8 pEt2 // ပႅတ်ႇ
_9 kaw3 // ၵဝ်ႈ
_1X sip4|| // သိပ်း
_11 sip4||?et4 // သိပ်းဢဵတ်း
_2X sa:w4|| // သၢဝ်း
_21 sa:w4||?et4 // သၢဝ်းဢဵတ်း
_3X sa:m||sip4|| // သၢမ်သိပ်း
_4X si:2||sip4|| // သီႇသိပ်း
_5X ha:3||sip4|| // ႁႃႈသိပ်း
_6X hok4||sip4|| // ႁူၵ်းသိပ်း
_7X tS;et4||sip4|| // ၸဵတ်းသိပ်း
_8X pEt2||sip4|| // ပႅတ်ႇသိပ်း
_9X kaw3||sip4|| // ၵဝ်ႈသိပ်း


+ 177
- 0
dictsource/shn_rules View File

@@ -0,0 +1,177 @@
// Shan (Tai Yay) pronunciation rules (Burmese script)

.group င // U+1004
င N

.group တ // U+1010
တ t

.group ထ // U+1011
ထ t_h

.group ပ // U+1015
ပ p

.group မ // U+1019
မ m

.group ယ // U+101A
ယ j

.group ရ // U+101B
ရ R

.group လ // U+101C
လ l

.group ဝ // U+101D
ဝ w

.group သ // U+101E
သ s

.group ဢ // U+1022
ဢ ?

.group ၵ // U+1075
ၵ k

.group ၶ // U+1076
ၶ k_h

.group ၷ // U+1077: rare, used for sounds in other languages
ၷ g

.group ၸ // U+1078
ၸ tS;

.group ၹ // U+1079: rare, used for sounds in other languages
ၹ z

.group ၺ // U+107A
ၺ J

.group ၻ // U+107B: rare, used for sounds in other languages
ၻ d

.group ၼ // U+107C
ၼ n

.group ၽ // U+107D
ၽ p_h

.group ၾ // U+107E
_) ၾ p_h // Except for Eastern dialects, which use 'f'.
ၾ f

.group ႀ // U+107F: rare, used for sounds in other languages
ႀ T

.group ၿ // U+1080: rare, used for sounds in other languages
ၿ b

.group ႁ // U+1081
ႁ h



// Vowels in groups

// All vowels below are suffixs

.group ႃ
ႃ a
ေ)ႃ O
.group ီ
ီ i
.group ိ
ိ i

.group ဵ
ဵ e
.group ႅ
_) ႅ (_ E
.group ူ
ူ u

.group ု
ု u

.group ေ
ေ ei // default rule without other characters
_) ေႃ O // in group with other characters if necessary
.group ႄ
ႄ E
.group ႆ
ႆ ai

.group ၢ
_) ၢ a:
.group ၢႆ // U+1062
_) ၢႆ a:i



.group ွႆ
_) ွႆ oi


.group ႂၢႆ
_) ႂၢႆ Oi



.group ြ
ြ ra
.group ျ
_) ျ ja
.group ဝ်
_)ဝ် w

.group ႂ်
_) ႂ် @i


.group ၺ်
_)ၺ် Wi

.group မ်
_)မ် m
.group ၼ်
_)ၼ် n

.group င်
_)င် g // ipa = ɳ ( temporary word )
// very short sounds
.group ပ်
_) ပ် p
.group တ်
_) တ် t
.group ၵ်
_) ၵ် k // temporary word

+ 6
- 6
docs/dictionary.md View File

@@ -56,8 +56,8 @@ The utility 'phonemes' are:
| `=` | put the primary stress on the preceding syllable |
| `_:` | short pause |
| `_` | a shorter pause |
| <code>&#124;</code> | indicates a word boundary within a phoneme string |
| <code>&#124;&#124;</code> | can be used to separate two adjacent characters, to prevent them from being considered as a multi-character phoneme mnemonic |
| <code>&#124;</code> | use to separate two adjacent characters, to prevent them from being considered as a single multi-character phoneme |
| <code>&#124;&#124;</code> | indicates a word boundary within a phonetic string |

It is not necessary to specify the stress of every syllable. Stress
markers are only needed in order to change the effect of the language's
@@ -509,11 +509,11 @@ each language. The number fragments are given in the `*_list` file.
## Character Substitution

Character substitutions can be specified by using a `.replace` section
at the start of the `*_rules` file. Each line specified either one or
two alphabetic characters to be replaced by another one or two
alphabetic characters. This substitution is done to a word before word is searched
at the start of the `*_rules` file. In each line one character can be
replaced by one or two characters. (Source and target of replacement can consume
up to four bytes.) This substitution is done to a word _before_ word is searched
in `*_list` or `*_listx` file and translated using the spelling-to-phoneme rules.
Only the lower-case version of the characters needs to be specified. e.g.
Only the lower-case version of the characters needs to be specified. e.g.:

.replace
ô   ő   // (Hungarian) allow the use of o-circumflex instead of o-double-accute

+ 4
- 0
espeak-ng-data/lang/tai/shn View File

@@ -0,0 +1,4 @@
name Shan (Tai Yai)
language shn
maintainer ronaldaug <[email protected]>
status testing

+ 1
- 1
espeak-ng-data/voices/mb/mb-ar2 View File

@@ -3,4 +3,4 @@ language ar 2
gender male

pitch 82 117
mbrola ar2 ar2_phtrans
mbrola ar2 ar1_phtrans

+ 73
- 75
phsource/mbrola/ar1 View File

@@ -1,77 +1,75 @@

volume 50
0 B b 20 b b
0 b NULL 0 b
0 t NULL 0 t
0 T NULL 0 T
0 dZ NULL 0 Z
1 H a 40 X a
1 H u 40 X u
1 H i 40 X i
0 H NULL 0 X

0 X NULL 0 x

0 d d 20 d d
0 d NULL 0 d
0 D NULL 0 D
0 r/ NULL 0 r
0 r NULL 0 r

0 z NULL 0 z
0 s NULL 0 s
0 S NULL 0 S

1 s[ a 40 s. a.
1 s[ u 40 s. u.
1 s[ i 40 s. i.
0 s[ NULL 0 s.

1 dH dH 40 d. d.
1 dH a 40 d. a.
1 dH i 40 d. i.
1 dH u 40 d. u.
0 dH NULL 0 d.

0 t[ a 90 t. a.
0 t[ u 90 t. u.
0 t[ i 90 t. i.
0 t[ NULL 0 t.


1 Z a 20 z. a.
1 Z u 20 z. u.
1 Z i 20 z. i.
0 Z NULL 0 z.

0 A NULL 0 H
0 gH NULL 0 G
0 f NULL 0 f
0 q NULL 0 q
0 k NULL 0 k
0 l/ NULL 0 l
0 l NULL 0 l

0 m m 100 n m
0 m NULL 0 m

0 n NULL 0 n
0 h NULL 0 h
0 w NULL 0 w
0 j NULL 0 j
0 ? NULL 0 ?
0 p NULL 0 NULL
0 g NULL 0 NULL
0 a a 150 a a
0 u u 150 u u
0 i i 150 i i
0 a NULL 0 a
0 u NULL 0 u
0 i NULL 0 i




0 b b 20 b b
0 b NULL 0 b
0 t : 50 t t
0 t NULL 0 t
0 T NULL 0 T
0 dZ NULL 0 Z

1 H a 40 X a
1 H u 40 X u
1 H i 40 X i
0 H NULL 0 X

0 X NULL 0 x

0 d : 50 d d
0 d NULL 0 d

0 D NULL 0 D
0 r/ NULL 0 r
0 r NULL 0 r

0 z NULL 0 z
0 s : 50 s s
0 s NULL 0 s
0 S : 50 S S
0 S NULL 0 S

1 s[ a 40 s. a.
1 s[ u 40 s. u.
1 s[ i 40 s. i.
0 s[ NULL 0 s.

1 dH dH 40 d. d.
1 dH a 40 d. a.
1 dH i 40 d. i.
1 dH u 40 d. u.
0 dH NULL 0 d.

0 t[ a 90 t. a.
0 t[ u 90 t. u.
0 t[ i 90 t. i.
0 t[ NULL 0 t.

1 Z a 20 z. a.
1 Z u 20 z. u.
1 Z i 20 z. i.
0 Z NULL 0 z.

0 A NULL 0 H
0 gH NULL 0 G
0 f NULL 0 f
0 q NULL 0 q
0 k NULL 0 k
0 l/ NULL 0 l
0 l NULL 0 l

0 m m 100 n m
0 m NULL 0 m

0 n NULL 0 n
0 h NULL 0 h
0 w NULL 0 w
0 j : 50 j j
0 j NULL 0 j
0 ? NULL 0 ?
0 p NULL 0 NULL
0 g NULL 0 NULL
0 a : 50 a a
0 a NULL 0 a
0 u : 50 u u
0 u NULL 0 u
0 i : 50 i i
0 i NULL 0 i

+ 0
- 74
phsource/mbrola/ar2 View File

@@ -1,74 +0,0 @@

volume 50
0 b b 20 b b
0 b NULL 0 b
0 t NULL 0 t
0 T NULL 0 T
0 dZ NULL 0 Z
1 H a 40 X a
1 H u 40 X u
1 H i 40 X i
0 H NULL 0 X

0 X NULL 0 x
0 d NULL 0 d
0 D NULL 0 D
0 r/ NULL 0 r
0 r NULL 0 r

0 z NULL 0 z
0 s NULL 0 s
0 S NULL 0 S

1 s[ a 40 s. a.
1 s[ u 40 s. u.
1 s[ i 40 s. i.
0 s[ NULL 0 s.

0 dH dH 30 d. d.
1 dH a 40 d. a.
1 dH i 40 d. i.
1 dH u 40 d. u.
0 dH NULL 0 d.

0 t[ a 90 t. a.
0 t[ u 90 t. u.
0 t[ i 90 t. i.
0 t[ NULL 0 t.


1 Z a 20 z. a.
1 Z u 20 z. u.
1 Z i 20 z. i.
0 Z NULL 0 z.

0 A NULL 0 H
0 gH NULL 0 G
0 f NULL 0 f
0 q NULL 0 q
0 k NULL 0 k
0 l/ NULL 0 l
0 l NULL 0 l

0 m m 100 n m
0 m NULL 0 m

0 n NULL 0 n
0 h NULL 0 h
0 w NULL 0 w
0 j NULL 0 j
0 ? NULL 0 ?
0 p NULL 0 NULL
0 g NULL 0 NULL
0 a a 150 a a
0 u u 150 u u
0 i i 150 i i
0 a NULL 0 a
0 u NULL 0 u
0 i NULL 0 i





+ 295
- 0
phsource/ph_shan View File

@@ -0,0 +1,295 @@
//*******************************************************************
// TONES
//*******************************************************************

phoneme 1 // rising tone (contour: 24)
stress
Tone(20, 40, envelope/p_rise, NULL)
endphoneme

phoneme 2 // low tone (contour: 11)
stress
Tone(10, 10, envelope/i_risefall, NULL)
endphoneme

phoneme 3 // mid(-falling) tone (contour: 32)
stress
Tone(30, 20, envelope/p_fall, NULL)
endphoneme

phoneme 4 // high tone (contour: 55)
stress
Tone(50, 50, envelope/i_risefall, NULL)
endphoneme

phoneme 5 // falling (creaky) tone (contour: 42)
stress
Tone(40, 20, envelope/p_fall, NULL)
endphoneme

phoneme 6 // emphatic (contour: 343)
stress
Tone(30, 40, envelope/i_risefall, NULL)
endphoneme

//*******************************************************************
// CONSONANTS (PLOSIVES/STOPS)
//*******************************************************************

phoneme p // unaspirated
vls blb stp
lengthmod 2
Vowelin f1=0 f2=1000 -50 -100 f3=-200 80 amp=11
Vowelout f1=0 f2=1000 -500 -350 f3=-300 80 rms=22

IF nextPh(isPause2) THEN
WAV(ustop/p_)
ENDIF
WAV(ustop/p_unasp)
endphoneme

phoneme p_h // aspirated
vls blb stp
lengthmod 2
Vowelin f1=0 f2=1000 -50 -100 f3=-200 80
Vowelout f1=0 f2=1000 -500 -350 f3=-300 80 rms=30

WAV(ustop/p_asp)
endphoneme

phoneme t // unaspirated
vls alv stp
lengthmod 2
Vowelin f1=0 f2=1700 -300 300 f3=-100 80
Vowelout f1=0 f2=1700 -300 250 f3=-100 80 rms=20

IF nextPh(isPause2) THEN
WAV(ustop/t_)
ENDIF
WAV(ustop/t_unasp)
endphoneme

phoneme t_h // aspirated
vls alv stp
lengthmod 2
Vowelin f1=0 f2=1700 -300 300 f3=-100 80
Vowelout f1=0 f2=1700 -300 250 f3=-100 80 rms=20

WAV(ustop/t) // TODO: This should be aspirated.
endphoneme

phoneme k // unaspirated
vls vel stp
lengthmod 2
Vowelin f1=0 f2=2300 200 300 f3=-200 80
Vowelout f1=0 f2=2300 300 400 f3=-200 80 rms=20

IF KlattSynth THEN
Vowelout f1=0 f2=2300 200 300 f3=-200 80 rms=20
ENDIF

IF nextPh(isPause2) THEN
WAV(ustop/k_)
ENDIF
WAV(ustop/k_unasp)
endphoneme

phoneme k_h
vls vel stp
lengthmod 2
Vowelin f1=0 f2=2300 200 300 f3=-150 80
Vowelout f1=0 f2=2300 300 400 f3=-150 80 rms=20

WAV(ustop/k_asp)
endphoneme

//*******************************************************************
// VOWELS
//*******************************************************************

phoneme i
vwl starttype #i endtype #i
length 200

FMT(vowel/i)
endphoneme

phoneme i.
vwl starttype #i endtype #i
length 200
ipa ɨ

FMT(vowel/i#_6)
endphoneme

phoneme W
vwl starttype #a endtype #u
length 200
ipa ɯ

FMT(vowel/8_2)
endphoneme

phoneme u
vwl starttype #u endtype #u
length 200

FMT(vowel/u_bck)
endphoneme

phoneme e
vwl starttype #e endtype #e
length 200

FMT(vowel/e_2)
endphoneme

phoneme @
vwl starttype #@ endtype #@
length 200
ipa ə

FMT(vowel/3_2)
endphoneme

phoneme o
vwl starttype #o endtype #o
length 220

FMT(vowel/o)
endphoneme

phoneme E
vwl starttype #e endtype #e
length 200
ipa ɛ

FMT(vowel/ee_2)
endphoneme

phoneme a
vwl starttype #a endtype #a
length 200

FMT(vowel/a)
endphoneme

phoneme a:
vwl starttype #a endtype #a
length 250
ipa aː

FMT(vowel/a)
endphoneme

phoneme O
vwl starttype #o endtype #o
length 260
ipa ɔ

FMT(vwl_it/o_open)
endphoneme


//*******************************************************************
// DIPHTHONGS
//*******************************************************************

phoneme iu
vwl starttype #i endtype #u
length 200

FMT(vdiph2/iu)
endphoneme

phoneme eu
vwl starttype #e endtype #u
length 200

FMT(vdiph/eu)
endphoneme

phoneme Eu
vwl starttype #e endtype #u
length 200
ipa ɛu

FMT(vdiph/eeu)
endphoneme

phoneme au
vwl starttype #a endtype #u
length 200

FMT(vdiph/au_2)
endphoneme

phoneme a:u
vwl starttype #a endtype #u
length 250
ipa aːu

FMT(vdiph/au_2)
endphoneme

phoneme Wi
vwl starttype #i endtype #i
length 200
ipa ɯi

FMT(vdiph/ui_3)
endphoneme

phoneme ui
vwl starttype #u endtype #i
length 200

FMT(vdiph/ui)
endphoneme

phoneme @i
vwl starttype #@ endtype #i
length 200
ipa əi // ႂ်

FMT(vdiph/@i)
endphoneme

phoneme oi
vwl starttype #o endtype #i
length 200

FMT(vdiph/ooi)
endphoneme

phoneme ai
vwl starttype #a endtype #i
length 200

FMT(vdiph/ai)
endphoneme

phoneme a:i
vwl starttype #a endtype #i
length 250
ipa aːi

FMT(vdiph/ai)
endphoneme

phoneme Oi
vwl starttype #o endtype #i
length 200
ipa ɔi

FMT(vdiph/ooi_3)
endphoneme

phoneme aW
vwl starttype #a endtype #u
length 200
ipa aɯ

FMT(vdiph/aau_4)
endphoneme


+ 3
- 0
phsource/phonemes View File

@@ -1990,3 +1990,6 @@ include ph_kyrgyz

phonemetable mi base1
include ph_maori

phonemetable shn base1
include ph_shan

+ 5
- 0
src/libespeak-ng/tr_languages.c View File

@@ -1512,6 +1512,11 @@ Translator *SelectTranslator(const char *name)
tr->langopts.stress_rule = STRESSPOSN_1L;
tr->langopts.numbers = NUM_AND_UNITS | NUM_HUNDRED_AND | NUM_OMIT_1_HUNDRED | NUM_OMIT_1_THOUSAND | NUM_SINGLE_STRESS;
break;
case L3('s', 'h', 'n'):
tr->langopts.tone_language = 1; // Tone language, use CalcPitches_Tone() rather than CalcPitches()
tr->langopts.length_mods0 = tr->langopts.length_mods; // don't lengthen vowels in the last syllable
tr->langopts.numbers = 1;
break;
case L3('c', 'm', 'n'): // no break, just go to 'zh' case
case L3('z', 'h', 'y'): // just go to 'zh' case
case L('z','h'):

+ 20
- 5
src/libespeak-ng/translate.c View File

@@ -382,7 +382,7 @@ int utf8_in(int *c, const char *buf)
/* Read a unicode characater from a UTF8 string
* Returns the number of UTF8 bytes used.
* buf: position of buffer is moved, if character is read
* c: holds integer representation of multibyte character by
* c: holds UTF-16 representation of multibyte character by
* skipping UTF-8 header bits of bytes in following way:
* 2-byte character "ā":
* hex binary
@@ -395,7 +395,7 @@ int utf8_in(int *c, const char *buf)
* 1010 011001 000101
* | + +--.\ \ | |
* V `--. \`. `.| |
* A645 0001001101000101
* A645 1010011001000101
* 4-byte character "𠜎":
* f0a09c8e 11110000101000001001110010001110
* V 000 100000 011100 001110
@@ -407,7 +407,7 @@ int utf8_in(int *c, const char *buf)

int utf8_out(unsigned int c, char *buf)
{
// write a unicode character into a buffer as utf8
// write a UTF-16 character into a buffer as UTF-8
// returns the number of bytes written

int n_bytes;
@@ -1788,6 +1788,7 @@ static int EmbeddedCommand(unsigned int *source_index_out)
return 1;
}

// handle .replace rule in xx_rules file
static int SubstituteChar(Translator *tr, unsigned int c, unsigned int next_in, int *insert, int *wordflags)
{
int ix;
@@ -1845,6 +1846,19 @@ static int SubstituteChar(Translator *tr, unsigned int c, unsigned int next_in,
new_c = ucd_toupper(new_c);

*wordflags |= FLAG_CHAR_REPLACED;
if (option_phonemes & espeakPHONEMES_TRACE) {
char msg[21] = {'R','e','p','l','a','c','e',':',' '};
char *index = &msg;
index +=9;
index += utf8_out(c, index);
*index++ = ' ';
*index++ = '>';
*index++ = ' ';
index += utf8_out(new_c, index);
index += utf8_out(c2, index);
*index = 0;
fprintf(f_trans, "%s\n", msg);
}
return new_c;
}

@@ -1914,6 +1928,7 @@ static int TranslateChar(Translator *tr, char *ptr, int prev_in, unsigned int c,
}
break;
}
// handle .replace rule in xx_rules file
return SubstituteChar(tr, c, next_in, insert, wordflags);
}

@@ -2188,8 +2203,8 @@ void TranslateClause(Translator *tr, int *tone_out, char **voice_change)
c = ' ';
word_flags |= FLAG_COMMA_AFTER;
}
c = TranslateChar(tr, &source[source_index], prev_in, c, next_in, &char_inserted, &word_flags); // optional language specific function
// language specific character translations
c = TranslateChar(tr, &source[source_index], prev_in, c, next_in, &char_inserted, &word_flags);
if (c == 8)
continue; // ignore this character


+ 1
- 0
tests/language-phonemes.test View File

@@ -98,3 +98,4 @@ test_lang lt 615e503b996ea5f7b267ebd77b91e77c5b874e18 "ma m;a na n;a pa p;a ta t
test_lang lv ebd5378940b27e39ac35cda90e027ee0fa625fde "ma na n^a Na pa ba ta da ca Ja ka ga tsa dza Dz\`a tSa dZa DZ\`a fa va sa za Sa Za xa ha ja la l^a Ra ra _:_ mi my mu mE me mo ma mi: my: mu: mE: me: mo: ma: mai mau mei mie miu mui muo muo\` moi"
test_lang mi b6e622de46c33181cdfea351b907f932da9a0a1a "ma na Na pa ta ka fa ha ra wa _:_ ma ma: me me: mi mi: mo mo: mu mu:"
test_lang mk 072d0a74acf54bea528e7dde427eb04808d38364 "ma na n^a Na pa ta xa k^a ka ba da Ja ga tsa tSa tS;a dza dZa dZ;a fa sa Sa xa va za Za l^a la ja Ra @-*a ra _:_ ma me mi mo mu mA mE ma: me: mi: mo: mu: moU"
test_lang shn e568aca66c2f58fdaf5dda8a67f4d21f05710234 "ma na Ja Na pa p_ha ba ta t_ha da ka k_ha ga ?a fa sa za Ta ha tS;a Ra ja wa la _:_ mi mI mW mu me m@ mo mE ma ma: mO miu meu mEu mau ma:u mWi mui m@i moi mai ma:i mOi maW _:_ ma1 ma2 ma3 ma4 ma5 ma6"

Loading…
Cancel
Save