PageRenderTime 40ms CodeModel.GetById 11ms app.highlight 17ms RepoModel.GetById 2ms app.codeStats 0ms

/native/external/espeak/docs/voices.html

http://eyes-free.googlecode.com/
HTML | 249 lines | 239 code | 10 blank | 0 comment | 0 complexity | 07b03b3c039481e24aaa74bf3d4e2650 MD5 | raw file
  1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  2<html>
  3
  4<head>
  5  <title>eSpeak: Voice Files</title>
  6  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
  7</head>
  8<body>
  9<A href="index.html">Back</A>
 10<hr>
 11<h2>5. VOICES</h2>
 12<hr>
 13<h3>5.1 Voice Files</h3>
 14A Voice file specifies a language (and possibly a language variant or dialect) together with various attributes that affect the characteristics of the voice quality and how the language is spoken.<p>
 15Voice files are placed in the <code>espeak-data/voices</code> directory, or within subdirectories in there.<p>
 16The available voice files can be listed by:<pre>
 17   espeak --voices
 18or
 19   espeak --voices=&lt;language&gt;</pre>
 20<hr>
 21<h3>5.2 Contents of Voice Files</h3>
 22The <strong>language</strong> attribute is mandatory.  All the other attributes are optional.
 23<p>
 24<h4>Identification Attributes</h4>
 25<ul>
 26<dl>
 27<dt>
 28<strong>name &nbsp;&lt;name&gt;</strong><br>
 29<dd>A name given to this voice.
 30<p>
 31<dt>
 32<strong>language &nbsp;&lt;language code&gt; [&lt;priority&gt;]</strong><br>
 33<dd>This attribute should appear before the other attributes which are listed below.<p>
 34It selectes the default behaviour and characteristics for the language, and sets default values for
 35"phonemes", "dictionary" and other attributes. The &lt;language code&gt; should be a two-letter ISO 639-1 language code.  One or more language variant codes may be appended, separated by hyphens.  (eg.  en-uk-north).<p>
 36The optional &lt;priority&gt; value gives the preference of this voice compared with others for the specified language.  A low value indicates a more preferred voice.  The default value is 5.<p>
 37More than one <strong>language</strong> line may be present.  A voice may be selected for other related languages (variants which have the same initial 2 letter language code as the specified language), but it will be less preferred for these.  Different language variants may be specified by additional <strong>language</strong> lines in order to indicate that this is a preferred voice for them also.  Eg.<pre>
 38   language en-uk-north
 39   language en</pre>
 40indicates that this is voice is for the "en-uk-north" dialect, but it is also a main choice when a general "en" language is specified.  Without the second <strong>language</strong> line, it would be disfavoured for "en" for being a more specialised voice.
 41<p>
 42<dt>
 43<strong>gender &nbsp;&lt;gender&gt; [&lt;age&gt;]</strong><br>
 44<dd>
 45This attribute is only a label for use in voice selection.  It doesn't change the sound of the voice.
 46<ul>&lt;gender&gt may be  male, female, or unknown.<br>
 47&lt;age&gt; is optional and gives an age in years.
 48</dl>
 49</ul>
 50<h4>Voice Attributes</h4>
 51<ul>
 52<dl>
 53<dt>
 54<strong>pitch &nbsp;&lt;base&gt; &lt;range&gt;</strong><br>
 55<dd>   Two integer values.
 56   The first gives a base pitch to the voice (value in Hz)
 57   The second controls the range of pitches used by the voice. Setting
 58   it equal to the base pitch will give a monotone. The default values are 82 118.
 59<p>
 60<dt>
 61<strong>formant &nbsp;&lt;number&gt; &lt;frequency&gt; &lt;strength&gt; &lt;width&gt; &lt;freq_add&gt;</strong><br>
 62<dd>   Systematically adjusts the frequency, strength, and width of the
 63   resonance peaks of the voice.  Values are percentages of the
 64   default values.  Changing these affects the tone/quality of the voice.<p>
 65<strong>freq_add </strong> Adds a constant value (in Hz) to the frequency of the formant peak. The value may be negative.
 66<ul>
 67   <li>Formants 1,2,3 are the standard three formants which define vowels.</li>
 68   <li>Formant 0 is used to give a low frequency component to the sounds, of
 69      frequency lower than F1.</li>
 70   <li>Formants 4,5 are higher than F3.  They affect the quality of the voice.</li>
 71   <li>Formants 6,7,8 are weak, high frequency, additions to vowels to give
 72      a clearer sound.</li>
 73</ul>
 74<p>
 75<dt>
 76<strong>echo &nbsp;&lt;delay&gt; &lt;amplitude&gt;</strong><br>
 77<dd>   Parameter 1 gives the delay in mS  (0 to 250mS).<br>
 78   Parameter 2 gives the echo amplitude (0 to 100).<br>
 79
 80   Adding some echo can give a clearer or more interesting sound,
 81   especially when listening through a domestic stereo sound system,
 82   rather than small computer speakers.
 83<dt>
 84<strong>tone</strong><br>
 85<dd>  Controls the tone of the sound.<br>
 86<strong>tone</strong> is followed by up to 4 pairs of &lt;frequency&gt; &lt;amplitude&gt; which define a frequency response graph.  Frequency is
 87in Hz and amplitude is in the range 0 to 255. The default is:<p>
 88<code> &nbsp; tone 600 170 &nbsp;1200 135 &nbsp;2000 110</code><p>
 89This means that from frequency 0Hz to 600Hz the amplitude is 170. From
 90600Hz to 1200Hz the amplitude decreases from 170 to 135, then decreases to 110 at 2000Hz
 91and remains at 110 at higher frequencies.  This adjustment applies only to voiced sounds such as
 92vowels and sonorant consonants (such as [n] and [l]). Unvoiced sounds such
 93as [s] are unaffected.<p>
 94This <strong>tone</strong> statement can also appear in <code>espeak-data/config</code>, in which case it applies to all voices which
 95don't have their own <strong>tone</strong> statement.
 96<p>
 97<dt>
 98<strong>flutter &nbsp;&lt;value&gt;</strong><br>
 99<dd>   Default value: 2.<br>
100
101   Adds pitch fluctuations to give a wavering or older-sounding voice.
102   A large value (eg. 20) makes the voice sound "croaky".
103<p>
104<dt>
105<strong>roughness &nbsp;&lt;value&gt;</strong><br>
106<dd>   Default value: 2. Range 0 - 7<br>
107
108   Reduces the amplitude of alternate waveform cycles in order to make the voice sound creaky.
109<p>
110<dt>
111<strong>voicing &nbsp;&lt;value&gt;</strong><br>
112<dd>   Default value: 100.<br>
113
114   Adjusts the strength of formant-synthesized sounds (vowels and sonorant consonants).
115<p>
116<dt>
117<strong>consonants &nbsp;&lt;value&gt;&nbsp;&lt;value&gt;</strong><br>
118<dd>   Default values: 100, 100.<br>
119
120   Adjusts the strength of noise sounds which are used in consonants.  The first value is the strength of unvoiced consonants such as "s" and "t".  The second value is the strength of the noise component of voiced consonants such as "z" and "d".
121<p>
122<dt>
123<strong>breath &nbsp;&lt;up to 8 integer values&gt;</strong><br>
124<dd>   Default values: 0.<br>
125
126   Adds noise which corresponds to the formant frequency peaks.  The values give the strength
127   of noise for each formant peak (formants 1 to 8).
128<p>
129   Use together with a low or zero value of the <strong>voicing</strong> attribute to make a "wisper".
130   For example:<br>
131   <code>breath &nbsp; 75 75 60 40 15 10<br>
132         breathw &nbsp;150 150 200 200 400 400<br>
133         voicing &nbsp;18<br>
134         flutter &nbsp;20<br>
135         formant &nbsp; 0 100 0 100 &nbsp; // remove formant 0
136   </code>
137
138<p>
139<dt>
140<strong>breathw &nbsp;&lt;up to 8 integer values&gt;</strong><br>
141<dd> 
142   These values give bandwidths of the noise peaks of the <strong>breath</strong> attribute.  If <strong>breathw</strong> values are not given, then suitable default values will be used.
143<p>
144</dl>
145</ul>
146<h4>Language Attributes</h4>
147<ul>
148<dl>
149<p>
150<dt>
151<strong>phonemes &nbsp;&lt;name&gt;</strong><br>
152<dd>Specifies which set of phonemes to use from those contained in the
153   phontab, phonindex, and phondata data files.
154   This is a <strong>phonemetable</strong> name as given in the "phoneme" source file.
155<p>
156   This parameter is usually not needed as it is set by default to the first two letters of the "language" parameter.
157   However, different voices of the same language can use different phoneme sets, to give different accents.
158</dd>
159<dt>
160<strong>dictionary &nbsp;&lt;name&gt;</strong><br>
161<dd>   Specifies which pair of dictionary files to use.  eg. "english"
162   indicates that <em>speak-data/en_dict</em> should
163   be used to translate from words to phonemes.  This parameter is usually
164   not needed as it is set by default to the first two letters of "language" parameter.</dd>
165<p>
166<dt>
167<strong>dictrules &nbsp;&lt;list of rule numbers&gt;</strong><br>
168<dd>
169Gives a list of conditional dictionary rules which are applied for this voice.  Rule numbers are in the range 0 to 31 and are specific to a language dictionary.  They apply to rules in the language's <b>_rules</b> dictionary file and also its <b>_list</b> exceptions list.
170See <a href="dictionary.html">dictionary.html</a>.
171</dd>
172<p>
173<dt>
174<strong>replace &nbsp;&lt;flags&gt; &lt;phoneme&gt; &lt;replacement phoneme&gt;</strong><br>
175<dd>   Replace a phoneme by another whenever it occurs.<p>
176   &lt;replacement phoneme&gt; may be NULL.<p>
177   Flags: bit 0:  replacement only occurs on the final phoneme of a word.<br>
178   Flags: bit 1:  replacement doesn't occur in stressed syllables.<br>
179   eg.
180<pre>
181      replace  0  h  NULL      // drops h's
182      replace  0  V  U         // replaces vowel in 'strut' by that in 'foot'
183                               // as occurs in northern British English
184      replace  3  N  n         // change 'fishing' to 'fishin' etc.
185                               // (only the last phoneme of a word, only in unstressed syllables)
186</pre>
187   The phoneme mnemonics can be defined for each language, but some are listed in <A href="phonemes.html">phonemes.html</A>
188</dd>
189<p>
190<dt>
191<strong>stressLength &nbsp;&lt;8 integer values&gt;</strong><br>
192<dd>   Eight integer parameters.  These control the relative lengths of the vowels in
193   stressed and unstressed syllables.
194<ul>
195<li>      0 &nbsp; unstressed
196</li><li>      1 &nbsp; diminished. Its use depends on the language. In English it's used for unstressed syllables within multisyllabic words. In Spanish it's used for unstressed final syllables.
197</li><li>      2 &nbsp; secondary stress
198</li><li>      3 &nbsp; words marked as "unstressed" in the dictionary
199</li><li>      4 &nbsp; &nbsp;  not currently used
200</li><li>      5 &nbsp; &nbsp;  not currently used
201</li><li>      6 &nbsp; stressed syllable (the main syllable in stressed words)
202</li><li>      7 &nbsp; tonic syllable (by default, the last stressed syllable in the clause)
203</li></ul>
204</dd>
205<p>
206<dt>
207<strong>stressAdd &nbsp;&lt;8 integer values&gt;</strong><br>
208<dd>   Eight integer parameters.  These are added to the voice's corresponding stressLength values.  They are used in the voice variant files in <code>espeak-data/voices/!v</code> to give some variety.  Negative values may be used.</dd>
209<p>
210<dt>
211<strong>stressAmp &nbsp;&lt;8 integer values&gt;</strong><br>
212<dd>   Eight integer parameters.  These control the relative amplitudes of the vowels in
213   stressed and unstressed syllables (see stressLength above).
214   The general default values are:  16, 16, 20, 20, 20, 24, 24, 22, although these defaults may be different for particular languages.</dd>
215<p>
216<dt>
217<strong>intonation &nbsp;&lt;param1&gt;</strong><br>
218<dd><ul>
219<li>1 &nbsp; Default.</li>
220<li>2 &nbsp; Less intonation.</li>
221<li>3 &nbsp; Less intonation, and comma does not raise the pitch.</li>
222<li>4 &nbsp; Pitch rises (rather than falls) at the end of sentence.</li>
223</ul>
224</dd>
225<p>
226<dt>
227<strong>charset &nbsp;&lt;param1&gt;</strong><br>
228<dd>
229The ISO 8859 character set number. (not all are implemented).
230</dd>
231<p>
232Additional attributes are available to set various internal options which control how language is processed.  These would normally be set in the program code rather than in a voice file.
233</ul>
234<hr>
235<h3>5.3 Voice Files Provided</h3>
236A number of Voice files are provided in the <code>espeak-data/voices</code> directory.
237You can select one of these with the <strong>-v &lt;voice filename&gt;</strong> parameter to the
238speak command.
239<p>
240<dl>
241<dt>
242<strong>default</strong><br>
243<dd>   This voice is used if none is specified in the speak command.  Copy your preferred voice to "default" so you can use the speak command without the need to specify a voice.</dd>
244</dl>
245For a list of voices provided for English and other languages see <a href="languages.html">Languages</a>.
246
247
248</body>
249</html>