Most aspects of the operation can be customized by changing options. This can be enforced by TTSCP commands, in configuration files and on the command line. Basically, an option is an option name/option value pair. There are a few possible option types: number, string, yes/no, character, and a few enumerated types.
Almost all individual options are documented in
this document. If you strongly suspect this section of
documentation to be out-of date, the reliable list of all built-in
long options can be found in src/options.lst
. (See approximately
line 320 and below. Every line represents at most one option for every
option class as explained below. The option name is quoted; its
semantics is usually explained following the option.) You can also
list the option names and types using epos -H
.
Basically, there are three major classes of options: global options, language options and voice options. For instance, switching a voice means switching to another set of voice options, while the language options and global options stay the same.
Every voice is language specific (implies a specific language). That's why switching the language automatically switches the voice to the voice defined as default for this particular language. (It is however possible to use the same configuration file to setup a similarly sounding voice for every language if desired.) It is also important to distinguish between a voice and an inventory. An inventory is a set of speaker-dependent files used to base a voice, that is, a mode of speech, on. Multiple different voices may use the same inventory, and may even sound quite different depending on various configuration options. The average user may expect to be able to modify the voice dependent configuration files, but not inventory files. Also, the inventories may often be distributed externally to Epos, while sample voices based on them may either be included with Epos, or with the segment inventory, or their creation may be left to the user.
A set of voice options should completely describe a voice. A set of language options should completely describe a language, except for voice-specific behavior. A set of global options should cover language independent aspects of operation. It should be understood that a set of options may employ various references to other information, especially filenames (of language dependent transcription rules, voice dependent segment inventories etc.)
Some language and/or voice specific options may have suitable defaults for all but specific languages/voices. That's why there is a corresponding language option for every voice option to default to if unspecified for a given voice. Likewise, there is a global option for every language option to default to. Therefore, adding a new language or voice options doesn't necessarily imply adding them to each language or voice configuration file, if a reasonable default can be suggested.
Whenever an option name is given, it is first understood as a voice option (of the current voice); if there is no such voice option, the name is treated as a language option, then as a global option. To override this order, you can prefix an option with "C:", "L:" or "V:". This will restrict the search to global, language or voice options, respectively. (This is automatically done with configuration files, because every configuration file describes either a language or a voice, or it is unrelated to the current language and voice altogether.)
Whenever the program starts up, it reads a number of configuration
files, setting up the initial (default) values of the options.
These are located under /usr/lib/epos
(unless overidden
at configure/compile time or
with the --base_dir
option on the command line). By convention,
configuration file names have the ".ini" suffix.
(On a Windows NT-like operating system, you can use the
HKEY_LOCAL_MACHINE\SOFTWARE\Epos\Setup
registry key to set the value of Path
to a path leading
to the configuration files. This value can still be overridden
by the command line.)
Unless overridden, three files in /usr/lib/epos/cfg
will be processed
to setup the global configuration: fixed.ini
, epos.ini
and
either ansi.ini
or rtf.ini
(depending on the preferred
output format if colored output is turned on -- either ANSI escape sequences
or RTF are supported at the moment; other markup formats can be added easily).
By convention, fixed.ini
contains the standard global configuration
values used by a given installation and rarely or never changes, while
epos.ini
contains less permanent parameters and temporary values.
The global parameters include a list of languages, or language
configurations which will be parsed when the global configuration is set up.
Every language .ini
file in turn contains a list of voices to be
configured for this particular language. Language configuration files
are located under /usr/lib/epos/lng/*/*.ini
, voice configuration files
under /usr/lib/epos/inv/*/*.ini
, where *
represents any string
listed in the list of languages (or voices for a language). Go see the real
files under /usr/lib/epos/cfg/*.ini
for an example.
A configuration file contains one option per line (empty lines are ignored).
Each option is a name-value pair, separated with whitespace. A string value
may be (and sometimes must be, e.g. if it begins with whitespace) enclosed
in double quotes. Every configuration
file is associated with a certain option set, that is, it contains either just
global options, or options related to some language or voice. (In the latter
two cases, the name
option identifies the language or voice properly.)
It is possible to enter some special characters using escape sequences, such
as "\ "
for a space, "\n"
for a newline, or "\~"
for "..."
or "dots"
(treated as a single character in Epos).
The available escape sequences are listed in
the table of escape sequences.
(If you suspect this table to be out-of-date, you can consult the token_esc
and value_esc
constants in option.cc
, or the table in
parser.h
.) ASCII codes in parentheses are ASCII codes used for different
purposes by Epos.
A configuration file usually contains various comments. A comment can start on any line with a semicolon or hash mark and lasts to the end of line. The semicolon (or hash mark) must be located at the beginning of line or just after some whitespace. Semicolons in the middle of a word don't start a comment.
If a line begins with @include
(possibly preceded by whitespace),
it is treated as the include directive.
The format of the line should be @include "filename"
and it will
cause the contents of the filename
file to be inserted at this place of the
main .ini
file. These includes can be nested to any finite depth; if no or
relative path is specified, the directory which holds the topmost file is used for
the lookup.
Sometimes it is not convenient or possible to encode all configuration files
in the same character encoding. For example, character encoding may be
language dependent. But it is even possible for different lines of the
same file to use different encodings. You can switch character encodings
for the same file using the @charset
directive.
Charset name must be specified as a parameter and it must be enclosed in
parentheses. Epos attempts to load the corresponding unicode character
mapping file and immediately switches the charset number for the current
file. Please note two differences from the charset
option:
the directive only affects the current "logical" file (including included
files as well as any files it has been included from using the
@include
directive), whereas the option doesn't affect it at
all, but it affects all subsequent files (e.g. for the given language).
Two more directives, @warn
and @error
with obvious semantics
are available for diagnostic purposes.
Command line option values can be passed to Epos
at server startup, or to the say
utility.
The behavior of these two command lines is very similar, though not identical.
The monolithic Epos executable should not deviate from the server executable,
unless specified otherwise.
The options can be specified anywhere on the command line, and are processed
from left to right before any other text (which is treated as the text to be
synthesized) on the command line. Long options, which correspond directly
to the options specified in configuration files, are preceded with a double dash
and they take a value, which can be separated
using the equality sign (=
), or spacing; the value (true
or the empty string)
can be understood implicitly, if applicable to the option type, and the option
is followed by another option or comes last at the command line.
Short options are denoted by single letters, preceded with a single dash, and
they never take a value.
Technically speaking, this section doesn't cover options, but it is nevertheless included.
The main purpose of the say
utility is to convert a specified
text to speech. Therefore, any command line text which is not part of an option
name or option value is concatenated together with spaces, and
sent to the server for the usual processing (TTS and phonetic
transcription), after all preceding, intervening or following
options have been sent to the server.
The same is true for the monolithic Epos executable, but in this case, only a single argument of this sort is accepted. (Just enclose the text with quotes to have it treated as a single argument. The sole reason why this is so is the less-than-maintained status of the monolithic executable.)
In both cases, quite random defaults are supplied if no input text is specified.
It is not possible nor desirable to specify the input text for the TTSCP server executable. It is accepted and silently ignored.
The long options are also available through the say
utility;
in such case, the long option is passed to the TTSCP server
without any effect on the say
client.
The ordering of the options on the command line is usually not significant, unless the current language or voice is switched during the processing. An example:
say --language german --pausing "Wie geht es?" --show_segments
This sets the default language to German, enables pausing after each
transformation rule is applied to the text (sets the pausing
option
to true
, in other words) and prints the segment string generated
in the process (sets the show_segments
option to true
). The string
to be transcribed and synthesized is given on the command line as well
(it must be quoted unless it consists of a single word).
The list of all available long options together with their types
can be obtained with epos -H
of the main program (not the client
stub, sorry). The semantics of nearly all individual long options is described
below.
For turning long boolean options off, it is possible to give their name with three dashes. Therefore,
say ---show_transcript "Say this, do not show the transcription"
is equivalent to
say --show_transcript off "Say this, do not show the transcription"
Refer to the individual options subsection for documentation on available long options.
Two pseudo-options --language
and --voice
can be used to switch
the current language or voice, or to specify options for other than the
default language or voice. There may be multiple options of this kind
given to the say
utility or the monolithic Epos executable, and
their ordering is important. For example,
say Something. --init_f 80 --voice vichova
doesn't do the expected thing, i.e. use the voice named "vichova" as modified by setting the neutral pitch for this command to 80. Instead, the neutral pitch is set for the default voice, and then the voice is switched to the specified one. To get the intended behavior, reorder the command line:
say Something. --voice vichova --init_f 80
The most frequently used options and occasionally even collections of options and/or other stuff are given a shortcut, called a short option. A short option is a single letter preceded by a single dash. Usual conventions for merging short options into a single string are available, and the example above may thus be abbreviated as
say --language german -p "Wie geht es?" -d
or even
say --language german -pd "Wie geht es?"
(There is no short option for --language
.)
The short options are interpreted directly by the say
utility;
that's why the list of short options available with this utility
is different from the list of short options available with the server
or the monolithic Epos executable.
A list of (the most of) the server short options can be obtained with
epos --help
, or epos -h
/. A list of (the most of)
short options understood by the say
utility can be obtained with
say -h
. Such list however includes undocumented options
which may disappear in the next releases.
Please keep in mind that the say utility is only an example of a TTSCP client and not a full-fledged controlling interface to Epos.
Do not fork at startup. Same as ---forking
.
Show a summary of available short options
Same as --pausing
.
Show Epos version.
Turn on debugging output. Multiple -D
options cause the output to be more
verbose.
In addition to a summary of short options, show also a list of all available long options.
Shut down the server.
List all available languages and available voices for the current language.
Write the waveform to a file (said.vox in the client's current directory) instead of writing it to the local sound card; the output doesn't include any header and is in the mu law format.
Write the waveform to the standard output. In this case, no transcription is performed.
Turn on utterance chunking. This option has unintuitive consequences
when combined with -w
.
Write the waveform to a file (said.wav in the client's directory) instead of writing it to the local sound card.
See the
TTSCP specification for general
overview of TTSCP and the set
command.
restr.ini
file
Setting options in TTSCP can be a security problem, as some options can cause the server to access unrelated files. It is therefore strongly recommended not to run the Epos daemon with superuser privileges, but sometimes a more fine-grained access control mechanism is needed. It is authentication and limiting access to specified options for some or all users.
By default, all settable parameters can be changed by any outside connection
(this doesn't affect any other connections in any way).
You can control this privilege by restricting it in cfg/restr.ini
.
Every line of that file is in the form
option_name access_rights
The access rights must be in lowercase and must not contain spaces. They are
a sequence of r
, w
', $
and #
, none of which may be repeated.
Their order is significant, the interpretation is as follows:
r
is mentioned, nobody can read the option valuew
is mentioned, nobody can change the option valuer
or w
appears without $
or #
to the left of them,
they grant the read and write rights, respectively, to even
anonymous connections.
r | read only |
w | write only |
rw | no restriction |
#w$r | root can write, authenticated users can read |
r#w | anyone can read, root can also write |
#rw | root can read/write |
|
Unknown parameters are considered just not to have been implemented in this
particular version of Epos and are not reported. Parameters not mentioned
in restr.ini
are allowed unlimited access by any connection.
Note that the location of this file can be changed at the command line
(with base_dir
).
If many users with different needs and aesthetic feelings
share the same Epos daemon installation, they may choose to
place the appropriate TTSCP commands into a file and to point
the TTSCP_USER
environment variable to this file.
The contents of that file will be transmitted by the client
to set up the working environment at the beginning of every
session.
An example:
set language czech
set voice kadlec
set init_f 90
set init_i 110
set language slovak
This example will adjust the preferred pitch and volume for a certain Czech voice; it will also set the default language to Slovak. See the TTSCP specification for more info.
Most options (discussed until this point) have built-in meanings and semantics; for most uses this is sufficient and necessary. However, the user may also decide to define additional options to be provided by a language to its voices. This mechanism is called soft options; soft options are always voice options and are described at the language level (that is, the name, type and default value is supplied with the language, but individual voices may choose to specify a value for the option).
The soft options are described by the language option soft_options
.
It is a list of colon separated descriptions of individual soft options;
every item is of the format name[(type)][=default]
, where name
is an arbitrary option name, type
is either b
or s
(meaning boolean or string; other possibilities include
n, c
for integers and characters, but these are untested
and don't seem to be widely useful. The default
is the default
value to be used if the option is left unspecified by a voice. It should be
chosen as a backward compatible value for a new option if applicable.
The type and/or the default may be left unspecified. The default type
is
boolean, the default default
is an empty string.
An example:
soft_options "colloquial=false:segment_listing_file(s)=traditnl.dph"
This example defines two options, a boolean colloquial
and
a string segment_listing_file
.
The sets of soft options for individual languages are independent and never clash with each other. However, built-in option names may not be used as soft option names.
Some options, especially pertaining to parsing the input and formatting the output, are set separately for every layer of the TSR, so that each of them is actually an array of options, indexed using the commercial at character (@) followed by a layer name. For example,
perm@colon ":,"
defines the permissible colon terminators. Since the TSR layer names
are themselves defined by the unit_levels
option, the availability
of such options is dependent on the current value of some other option.
For other options, such as default_scope
, the value is a layer name,
and is thus meaningful only after the layers are defined; all such options
can only be set after the unit_levels
option has been set correctly.
As level description dependent options (the former type) do not yet exist
upon program startup, the access control in restr.ini
only works
for the arrays of options, not individual options:
perm r
For these and other reasons, changing the unit_levels
option is not
recommended after any of both types of level of description dependent
options has been set.
Most individual options will be described in this section. The rest are either
straightforward or rarely useful. A complete list of options can be obtained
through epos -H
or in src/options.lst
.
The type and the semantic class of the argument is indicated for all individual
options except for truth value (on
/off
) options. This is because
these options, when found without an argument, are automatically interpreted
as on
.
Many options may not make any sense to you; indeed, some of them don't actually make sense to me. Such options are usually relics from now forgotten ad hoc configurations. I appreciate any suggestions on how to replace any old fashioned configuration mechanisms with more generic and/or simpler ones.
Some options control overall preferences, strategies and assumptions to be used by Epos. Most of them are global booleans. They are usually of technical nature and the output produced by Epos should not change with these options changed, but they can be useful in some special configurations. They also get added to resolve some simple software engineering dilemmata.
This is the delimiter for Epos-generated lists, especially in TTSCP; an arbitrary string is allowed. Do not change.
The character to replace any unknown characters in the input text.
See also the relax_input
option.
The character to terminate the input text. This defaults to the
escape character. The length of the input text is usually
defined externally (by the apply
command within a control
TTSCP connection or by the end of an input), however, there
are cases where this is not applicable or desirable for some
reason. The character specified by this option terminates
the input text, but not the input stream. It is also necessary
to press Enter
after the character. Applies only to the
monolithic Epos.
Turn on to enable asynchronous close() processing. Usable only on unices; uses fork to delegate the synchronous close() to a child. This option can be useful for eliminating communication delays when closing a sound card file descriptor, but it can cause subsequent references to the same device fail, because the child still hasn't released the device. The option has no meaning on non-UNIX systems, where the close() is always synchronous.
Turn on to allow forking and fully detaching the Epos daemon.
Usable only on unices. If off, some debugging information will
be written to stdout
in some configurations.
If set to a non-zero value under a UNIX, the parent process will wait for at most n seconds for the daemon process to start accepting connections. One second is likely to be more than enough except when the machine is severely overloaded. Note that most Epos initialization takes place before the fork, whereas this option is only used after the fork.
The parameter is either "ansi", "rtf" or "none". This parameter
is only effective in fixed.ini
or on the command
line. Depending on its value, the ansi.ini
or rtf.ini
configuration file is appended to the fixed.ini
file during
parsing the configuration. These two files contain the complete
output formatting information necessary for printing text in
either the ANSI escape sequences (ISO 6429) or the Rich Text
Format; they use colors to distinguish between symbols of different
levels of description.
The maximum number of subtasks waiting in an input queue for
a single agent. If this limit is reached, the preceding
agent stops processing further input until only pend_min
subtasks are left in the queue. Setting this limit higher
will consume additional memory, as more processing can happen
in advance, but setting it too low may cause unnecessary delays.
The minimum desired number of subtasks waiting in an input
queue for a single agent. If the queue length decrements
to this limit and the preceding agent has enough input
to process, it resumes operation. This limit should
be set roughly to half the pend_max
value.
Turn on if you're very low on memory. This mode sacrifices speed
for a little bit of saved memory. Basically, turning this on
caused various dictionaries to be discarded whenever the rule
which has used them has been applied and reloaded the next time
it is needed. Likewise, cached files are released upon the
last unclaim
. Otherwise these data structures are kept cached
in for the next use.
With this option on, Epos will tend to detect more errors in various kinds of input files than without. It will rather try to reject suspicious or formally incorrect inputs, than to do something reasonable with them. Useful for debugging.
With this option on, Epos will pause and wait for a keypress
after every rule is applied. Of course, this is incompatible
with the forking
option and some other setups. Should
be only used for debugging.
One of the checks performed when the trusted option is disabled is checking whether some pointers are actually pointers, that is, very big numbers when cast to an integer. This can be useful on some machines, but it is absolutely unportable. It may or may not work with your compiler; enable this option to skip these checks.
Turn on in real life situations. When off, Epos will quit parsing
any text which contains an unknown character (not listed in on of the
perm_*
options). This option replaces such characters with
the value of the default_char
option before they're classified.
Print each rule before it is applied. This is useful mostly for debugging situations (when a text is parsed in an unexpected way and the user is trying to find out which rule has escaped his attention). This option may not work with all setups.
Setting this option to a file name causes profiling information
to be recorded to the file named. The file is created in the
current directory of the server if a relative pathname is given.
Each line of the profile log corresponds to one timeslice of
an agent. First, the time spend before running the agent
(after the last agent has finished). Second, agent type.
Third, time spent by the agent. Both time intervals are given
in microseconds and their accuracy depends on the
gettimeofday
system call. Using the profiler on a loaded
machine is going to give almost meaningless results.
An alternative password for server-level authentication. Can be useful when debugging the TTSCP implementation, with the obvious security implications.
The TTSCP handle length in character. The handles are always generated randomly using a 64 character alphabet. Use small values for debugging the TTSCP implementation manually (and accept the risk of a handle-guessing attack); use higher values in a production environment.
The picture to be printed to stdshriek
in case of an error.
May or may not work. Small integers such as 0, 1 or 2 are possible.
Code related to the class unit
often calls its sanity
method
to detect any serious structure violation before it makes Epos crash
mysteriously. In stable versions, however, these checks are unlikely
to be necessary. Use this option to skip them.
When the rules are dumped with the debug
rule type and this
option is set, all of them will be displayed. Otherwise only the
current rule is displayed. That's all.
Enables the use of the TTSCP #localsound
output module.
Enables the use of file system based TTSCP input modules. See
the
pseudo_root_dir option
for more details. Note that this option can not be turned on
unless the underlying operating system has a fully functional
implementation of the select
call.
Enables the use of file system based TTSCP output modules. See the pseudo_root_dir option for more details.
Levels of description. Must be a colon separated list which includes
segm
and phone
as the two lowest levels, and text
as the highest level of description. There are reasons why this should not
be a language dependent option; you can however define this to be the
union of all levels of description needed by any language.
The default scope level of a rule -- one of the levels of description
defined with the unit_levels
option.
The default target level of a rule -- one of the levels of description
defined with the unit_levels
option.
Lists initially available languages. The parameter is a colon separated
list of language names. Every language must have its associated .ini
file; the name of the file is obtained by suffixing .ini
to the
language name, while the directory name matches the language name and is
located under the directory as determined by the lang_base_dir
option. The first language listed will become the default language.
When Epos is compiled as a TTSCP server, the variability of data formats is controlled by TTSCP rather than by option settings. However, there are some options related to the output formats produced by the monolithic binary (executable). There are also some conventional informative outputs that can be produced by the monolithic and server binaries equally.
Print the sequence of sounds generated from the text processed. Monolithic binary only.
Print the sequence of segments generated from the text processed. Monolithic binary only.
When used in conjunction with the show_segments
option, the segments
will be not only listed by name, but they will also include the actual
numbers generated. Monolithic binary only.
Synthesize the waveform and say it through the sound card. Monolithic binary only.
When dumping the waveform into a file or a TTSCP data connection,
put the RIFF wave file header at its beginning. Regardless of
this value, the header is never added when writing the waveform
to a sound output device (a file descriptor which understands
the usual ioctls). TTSCP requires this option be always set
to on
; consequently, the option is only reasonably useful with the
monolithic binary.
Generated waveform uses mu law sample encoding instead of linear encoding.
Voice dependent option. May be used to downsample the output by one half.
If this option is enabled, an appropriate low band filter is used whenever downsampling. This is necessary to avoid phantom sounds in the output.
Output segment (diphone) labels in the output waveform using the appropriate RIFF WAVE chunks.
Output phone labels in the output waveform. This is only possible if phone boundary information is made available for the inventory using the snl_file option. For other voices, this option has no effect.
Very experimental. If used in conjunction with the label_phone
,
the phone labels are assigned not the phone level, but the highest
level whose boundary is detected at this place. If you do use this
option, be aware that Epos will use a (very slightly) TTSCP 0
non-compatible internal representation for the segment (diphone) stream
to preserve the necessary suprasegmental unit boundary information.
Consequently, network voices provided by different TTSCP servers may
fail reporting unexpected segment numbers.
Print the sequence of segments generated from the text processed
just after the segments
rule. This is useful especially
in conjunction with the neuronet
option where the segment layer
is created, but later to be discarded by the rules.
Monolithic binary only.
Very experimental. See doc/czech/nnet.doc
for more info.
Monolithic binary only.
Print a brief synopsis of short options upon startup. No data processing is performed.
Print a list of long options upon startup. No data processing is performed.
Print the current version number to stdshriek
upon startup.
You can tailor the conventions for printing out processed text quite a lot. Basically, we're printing out a text structure representation, so that we can see what level of description does a character belong to. Preserving this information in the output is often very desirable; it can either be done by inserting delimiters such as custom syllable breaks, or by coloring some levels of description.
This family of options can result in a quite complex configuration.
That's why we provide at least
two complete sets of settings in ansi.ini
and rtf.ini
. You can use the
markup_language option to switch between them
in fixed.ini
.
Some options control the colors used for output. For the time being, these options actually take the escape sequence needed to switch the color for the current format (e.g. ANSI escape sequences or RTF). In principle, other strings than escape sequences can be printed, but such configuration is discouraged.
Some options configure the appearance of the
TSR
to the user. The model we use is assigning a few colors consistently
to the individual levels of description and marking up the boundaries
between units with parentheses, separators or both. The levels of
description are
defined in compile time.
The segment
and text
may not be applicable for some of
these options. This model of displaying the TSR is not used for
transmitting the text over TTSCP.
If disabled, all color manipulating options will be ignored. Many configurations will enable this by default, because the escape sequences are rarely usable directly and never indirectly.
String to switching to the neutral (default) color. Issued at the end of every colored piece of text.
String to switch to the a bold color. The bold color will be used to highlight the current rule in the list of rules printed by the debug rule type.
String to switch to the color used for printing out fatal error messages.
The value is the file name of a file in the directory specified
by the ini_dir
option, which is to be printed before any
phonetic transcription.
The value is the file name of a file in the directory specified
by the ini_dir
option, which is to be printed after any
phonetic transcription.
The asterisk stands for a @-separated symbolic name of a linguistic description
level, such as phone
, syll
or word
. The parameter
is a string which will be printed before the first unit within this
unit, for example before the word-initial syllable in case of
begin@word
).
The asterisk stands for a @-separated symbolic name of a linguistic description
level, such as phone
, syll
or word
. The parameter
is a string which will be printed after the last unit within this
unit, for example before the word-final syllable in case of
close@word
).
The asterisk stands for a @-separated symbolic name of a linguistic description
level, such as phone
, syll
or word
. The parameter
is the string to switch the color for this level of description.
The asterisk stands for a @-separated symbolic name of a linguistic description
level, such as phone
, syll
or word
. The parameter
is a string which will be printed between adjacent units of this
level of description, for example between words in case of
separ@word
).
Whether the verbose model of displaying the TSR as described above
is used. When off, only the text itself is printed and simple
spacing is used to delimit units which do not correspond to
actual characters. This option is orthogonal to the colored
option.
If on, the upper level characters (such as punctuation) are printed after the lower level characters (such as letters or sounds) in the phonetic transcription.
If on, the upper level characters (such as punctuation) are printed
before the lower level characters (such as letters or sounds)
in the phonetic transcription. Disabling both prefix
and
postfix
options effectively disables printing other characters
than sounds. This option is orthogonal to the structured
option.
Epos uses the low line (_
) character to represent
suprasegmental units with no content at their level (e.g. syllables
are often only implicitly terminated or even generated
by the rules and have no associated symbol.); this option,
when enabled, suppresses them completely.
Most algorithms used in Epos are boundless, avoiding techniques like fixed size arrays or buffers. On the other hand, there are instances when this is inadequate, especially for speed or space considerations. In these cases Epos tries to use growable data structures, so that they perform well up to a certain size limit and then somewhat slower, but still correctly. We call such a limit a soft limit, as opposed to a hard limit which cannot be exceeded. Most limits in Epos are configurable and soft, but some hard limits have also been imposed. This subsection also covers some time vs. space trade-off configuration parameters, though these are no limits at all. Also some sanity check limits are imposed; these act as hard limits, but can be effectively disabled by setting them to absurdly high values, with no direct impact on efficiency in the typical case.
In fact, you can ignore this section completely, as the few hard limits tend to employ reasonably high values.
Soft limit. Maximum number of segments generated by the diphoniser
and synthesized at once. It more segments have to be generated,
they are synthesized in chunks of seg_buff_size
. If this
option is set to zero, a growable buffer is used instead, and
there is no limit on memory consumed.
This option has no effect in the monolithic Epos.
Soft limit. The initial buffer size for a wave file. This value is not used, if we already know that we will eventually write this waveform to a sound card device; in this case we use ioctls to find out the size of its hardware buffer to maximize the chance of getting a smooth playback.
Sanity check limit. When reading from a device, this is the maximum amount of data which will be read for processing. This is not necessary when reading from a file, because the length of a file can be known in advance and it is always finite.
Trade-off. Controls how many multipliers are tried out when constructing a perfect hash table, for each table size. The search begins at 1 and continues up to n. If the table still has collisions, hash table size is increased by one and the search restarts. This is iterated until a perfect hash table is found. As we only use perfect hash tables for representing constant sets and functions, they are only constructed during Epos startup. Setting this option to a small value (such as 17) speeds up Epos startup, while larger values can sometimes arrive at a smaller table, thus saving some memory.
Trade-off. Controls how full should a hash table ideally be. The hash tables used in Epos are actually quite robust performance-wise, so that even values like 1000, that is, ten data items per a hash table slot, result in near-optimal speed. Values somewhere below 100 are the best bet.
Sanity check limit. If more than count of errors in a rules file is found, Epos quits parsing the file.
Hard limit. Maximum line length in a text-oriented input file. Longer lines are truncated.
Hard limit. Maximum TTSCP command length. TTSCP lines longer than this will be truncated. The protocol requires this value to be at least 80, but a few kilobytes is recommended.
Sanity check limit. Maximum rule weight in a choice, as well as the maximum rule repeat count. Using very large weights can result in memory exhaustion. Values on the order of 10000 are still perfectly safe.
Sanity check limit. Maximum amount of space allowed for growable processing buffers, or for the input text (checked just before parsing). This option is generally used to avoid memory exhaustion.
Sanity check limit. How may substitutions will be applied to a unit
during processing of a subst
rule. The rule is applied until
the unit settles down or until this limit is reached. In the latter
case, the substitution is considered impossible (infinite).
Soft limit. Number of rules used in a block of of rules.
Hard limit. Epos uses a temporary internal buffer in a few places. Usually only very few bytes of the buffer are needed, but overflowing it is fatal. It is recommended to provide at least a few hundred bytes, preferably kilobytes, for this buffer.
Soft limit. Number of variables used in a set of rules.
This subsection lists some options defined for each language. Additional language dependent options are certain directory and file names and possibly others. As every voice is associated with a single language (two voices may share a multilingual segment inventory if desired), every voice dependent option is thence language dependent.
This option assigns a name to a newly created language. If there is no name specified, this option defaults to the configuration file name (from the last slash to the nearest dot) the configuration has been loaded from. The name is then used to refer to the language in TTSCP. The language name must begin with an alphabetical character and consist of alphanumerical characters (dashes and underscores are also allowed).
Lists initially available voices. The parameter is a colon separated
list of voice names. Every voice must have its associated .ini
file; the name of the file is obtained by suffixing .ini
to the voice name
while the directory name matches the voice name and is located under
the directory as determined by the per language (default) inv_dir
option. The first voice listed will become the default voice for its
language until switched.
Lists available soft options as described in subsection soft options.
Not used under normal circumstances. Epos initialises its synthesis type dependent specific structures the first time it uses a voice. Should such an initialization fail because of a network error, the current voice will be switched to the voice specified by this option and the initialisation will be retried.
The parameter is a filename. The file contains the transformational rules to be applied for this language.
The asterisk stands for a @-separated symbolic name of a linguistic description
level, such as phone
, syll
or word
. The parameter
is a simple sequence of all characters belonging to this level
of description. For example, perm_phones
will list letters,
numbers and other segmental symbols. Punctuation will be assigned
to the higher level sets. The sets should be disjoint and only the
characters actually processed by the rules should be listed here.
The language independent built-in parser tries to resolve the most
common ambiguities of Latin-based writing systems, like periods.
This option assigns a name to a newly created voice. If there is no name specified, this option defaults to the configuration file name (from the last slash to the nearest dot) the configuration has been loaded from. The name is then used to refer to the voice in TTSCP. The voice name must begin with an alphabetical character and consist of alphanumerical characters (dashes and underscores are also allowed).
The parameter, the speech synthesis type, is one of the following:
none | voice is mute |
internet | voice uses a remote speech synthesis using TCP/IP |
lpc-int | voice uses a LPC synthesis (integer based) |
lpc-float | voice uses a LPC synthesis (floating point based) |
lpc-vq | voice uses a LPC synthesis (vector quantified) |
ktd | voice uses a time domain synthesis (Zdenek Kadlec) |
ptd | voice uses a time domain synthesis (Martin Petriska) |
If this speech synthesis is of the internet
type,
this option can be used to set the hostname of the remote
server. If the remote server is listening on a non-standard port number
(currently the standard port is considered to be 8778), the
host name may be followed by a colon and the port number
requested. The desired remote voice and language may be optionally specified
before the host name, separated with a @
character
from the host name and with a dot from each other. If a language name
is specified, while a voice name is not, the language name should be
preceded with a dot.
The defaults for voice, language, and port number are
remote default voice, local current language, and 8778,
respectively.
For other synthesis types, this is a directory name which holds inventory related files (in the "inv" subtree), and is subject to normal file naming conventions, as described in file naming.
The value is a time interval in seconds. This option is meaningless
for voices of type other then internet
. For remote voices,
if the remote server is successfully connected to, but doesn't send
any TTSCP session header (nor anything else) to the local server
acting as a TTSCP client, it is either severely misconfigured,
overloaded, deadlocked (e.g. tries to use itself as a remote
server for its current voice), or communicating over a congested, unreliable
or slow network connection.
A value of 0
is actually a very small positive value and negative
values are not accepted.
The total number of segments withing the segment inventory.
The value is a file name. The file contains the segment inventory proper. Its format is speech synthesis type dependent.
The value is a file name. The file contains the lengths of individual segments in this segment inventory.
The value is a file name. The file contains the symbolic segment names for user output.
The value is a file name. The file contains the code book for
the vector quantified LPC speech synthesis (lpc-vq
type only).
The value is a file name. The file contains phone boundary information for individual segments in this segment inventory. Each line of the file contains three space-separated items: segment number, relative position within the segment (valued from 1 to 1024, e.g. 512 is the middle of the segment) and the character (phone representation) which is to be associated with the position. Lines not conforming to this specification are ignored. Currently, at most one label may be indicated for one segment, but it would be easy to get rid of this limit. See also label_phones option.
The auditory neutral integer value for the fundamental frequency. The typical value is 100.
The auditory neutral integer value for the volume. The typical value is 100.
The auditory neutral integer value for the prosodic duration of segments.
The typical value is 100. Of course, it is segment length relative
(some segments are longer than others), just as the init_f
and init_i
options are.
The parameter, the output channel type, is one of the following:
mono | mono output signal |
left | stereo output signal, right channel is mute |
right | stereo output signal, left channel is mute |
both | stereo output signal, two identical channels |
The sampling rate this segment inventory has been recorded at. The algorithms we use also imply that we use the same frequency for the synthesis.
Number of bits per sample. If some kind of a stereo output is turned on, this option set the number of bits per channel. Again, this is related to the quality of recording of the segment inventory. We currently only support 8 and 16 bits.
The options in this section control how the resulting per segment prosodic information is assembled from the prosodic adjustments done to the structural units by the rules. It actually controls the interpretation of those adjustments themselves.
The asterisk stands for a @-separated symbolic name of a linguistic description
level, such as phone
, syll
or word
. The parameter
is an integer value primarily used for enabling (1) or disabling (0)
certain levels of description when the total quantities for a segment
are computed. It must however be understood that when some rules
like smooth
are applied, the prosodic values are distributed
down to the target level of such a rule and cannot be distinguished
anymore. If higher values than 1 are set, that will multiply the
prosodic effect assigned to a level correspondingly.
The asterisk stands for a single letter, f
, i
or t
,
that is, a prosodic quantity symbol. This option controls how
are the prosodic values for individual levels of description
combined. If it is off, they are summed up (taking the corresponding pros_neutral_*
as the baseline); if it is on, they get multiplied with each other
(again taking pros_neutral_*
as the neutral value). See
prosody modelling for more information and examples.
The asterisk stands for a single letter, f
, i
or t
,
that is, a prosodic quantity symbol. This option controls what
prosodic value is to be considered neutral for use in Epos. The current
configuration file use 100 and prosodic adjustments are essentially
percentages, but a higher value could be used for more fine grained
prosody control (provided the synthesis algorithms can take advantage
of it).
In Epos, most of the files ever opened are located in a single directory tree.
This tree usually starts at /usr/lib/epos
, but it can be changed at
configure time. For example, after issuing
cd src
./configure --prefix=/usr/local
and after recompiling and reinstalling Epos, the files will be searched under
/usr/local/lib/epos
. See configure --help
for more
details on configuring Epos. It is also possible to use the command
line option base_dir
at Epos startup to change the
tree base without recompilation. Files of the same type -- and related
to the same language or voice, if applicable -- are located in the same subdirectory
by default. Thus, the path name actually used by Epos consists of the base directory
path, the subdirectory (or directory for short) and a relative file name.
This makes it possible to move either the whole configuration structure, or
a specific part of it, or a single file to another place.
The relative file name may contain slashes (directory name separators).
If they only occur in the middle of the name, the file name is still
relative to the directory it would normally
be located in. However, if the file name begins with a slash or with ./
,
the file is treated as absolute or relative to the current working directory
of the Epos process, respectively. The second case is thus slightly unreliable,
but the first one allows to place any file in an arbitrary directory.
Likewise, if the directory name begins with a slash, it is not considered
to be relative to the base directory.
Changing these options in run time does not immediately cause re-reading the renamed files.
The value is an absolute directory name. This option can be used to change the location of the whole configuration structure, which can also be used for trying out Epos before installing it:
cd src
./epos --base_dir ../cfg
The value is a directory name. Sets the path prepended to any file name referenced in the TTSCP stream command. This subtree cannot be escaped with cute parent-of-root paths, but you can use symlinks to arbitrary accessible parts of the kernel name space, again, without giving access to the rest of the file system. Write access to this subtree to any user except Epos effectively gives him the privilege to use the Epos file access rights anywhere in the system through creating a symlink to the absolute root directory.
The value is a directory name. Sets the path to language independent configuration files.
The value is a file name. This option can be used to change the file name
of the fixed.ini
file, which usually contains operating system
independent, relatively fixed default global configuration.
The value is a file name. This option can be used to change the file name
of the epos.ini
file.
The value is a file name. This option can be used to change the file name
of the local sound card device. In many unices,
setting this to /dev/dsp
is the recommended way to actually hear
Epos speak. Other unices don't have /dev/dsp
, however. If the
sound card has no file name at all, set this to the null device
file name.
The value is a file name. This option can be used to change the file name of the implicit input text used by the monolithic version of Epos. The value is language dependent.
The value is a file name. This option can be used to change the file name
of the file produced by the experimental neuronet
option.
The value is a file name. This option can be used to change the file name
whereto various debugging output should be written. If not set at all,
stdout
will be used.
The value is a file name. This option can be used to change the file name whereto output unrelated to the usual output should be printed. It includes especially error messages.
The language dependent value is a directory name. The directory shall contain the rules file.
The language dependent value is a directory name. The directory shall contain any dictionaries used by the rules.
The language dependent value is a directory name. The directory shall contain the implicit input text file for the monolithic version of Epos.
The value is a global directory name, not a language dependent one. It serves as the base directory for looking up the newly constructed languages.
The value is a global directory name, not a language dependent one. It serves as the base directory for looking up the newly constructed voices. It is however only used for configuration files, not for inventories. A language dependent subdirectory name is appended to it.
The value is a global directory name, not a language dependent one.
It serves as the base directory for looking up inventories and
related data. A voice dependent subdirectory name (the location
option) is appended to it.
The value is a directory name. In this directory, TTSCP help files
for individual TTSCP commands and other help topics are located.
The contents of these files is sent to the TTSCP control connection
in reply to a corresponding help
command.
The value is a global directory name. Any waveform files created by Epos without explicit directory specification will be created in this directory. Applies only to the monolithic Epos.
The value is a global directory name.
An input file for the experimental neural networks will be created
in the directory when the neuronet
option is on. Its name
is specified by the nnet_file
option.
Applies only to the monolithic Epos.
The options in this section usually have no effect if changed in run time; change them in the configuration files instead and restart Epos.
The value is a file name. This option can be used to set the file where various information about the Epos process is recorded. At the moment that is of little practical use except for debugging.
Log all TTSCP error messages with syslogd, if the syslog facility is available. Due to the internal design of Epos, some of these messages are never actually sent over TTSCP to anyone - for example, a fatal misconfiguration condition detected before the first client connects.
Log all TTSCP completion messages with syslogd, if the syslog facility is available, including 1xx and 2xx class messages.
Log all security relevant TTSCP completion messages with the
facility authpriv
instead of daemon
. This includes
messages concerning denial of access or incorrectly specified
resource or password. In that case, the err
message level
is used instead of warn
. Notice that network errors
are not affected by this option.
When set, all TTSCP messages are preceded with their numeric codes as in TTSCP.
The value is a file name. This option can be used to force the server
to store its internal password to a file. This password can then
be used for TTSCP authentication in order to issue restricted commands
such as down
. If the file can not be created, no error is reported.
The file named by this parameter provides access control in TTSCP to individual options. Its syntax is described above.
The TCP port number where the daemon should be listening for incoming TTSCP connections. The daemon will check if no other service is already running on that port and refuses to run if the port is already occupied.
When this option is set, the daemon accepts no new connections on network interfaces except the localhost one. This way, only clients running on the same machine can connect to the server. If this option is not set, the server accepts new connections on all available interfaces.
Various kinds of debugging information can be printed by Epos.
The amount and topics of it can be reasonably tuned by a couple
of options. Most debugging information is printed throughout
the code using the DEBUG
macro; other sources or debugging
information are not discussed in this subsection. The DEBUG
macro takes three parameters: the code area, the
severity level and the code to be executed if the severity
level supplied is considered sufficient under current settings.
This code is usually a fprintf
to the stddbg
stream.
The decision whether to execute the debugging code, based on the
code area and severity level is carried out by the debug_wanted
function supplied in src/interf.cc
. You can either edit
it yourself, or, you can use the options described in this section
to control the behavior of the default debug_wanted
function
supplied by Epos. Note that #define DEBUGGING
must be
enabled in interf.h
, else the DEBUG
macro is ignored
altogether.
The level argument taken by many options in this subsection is a severity level number.
level | debugging messages | comment |
0 | detailed | non-systematic chaos |
1 | verbose | too verbose |
2 | normal | informative |
3 | rare | warnings, and such |
|
This option must be on
to provide any debugging information (except for
daemon activity logging controlled by
the daemon_log option.
Severity level threshold for the code area of regress
and
related types of rules, as well as their implementation in the
src/unit.cc
file.
Severity level threshold for the code area of parsing
the Epos configuration .ini
files.
A few instances in this area may not be handled properly, because
they are called before this option is set itself. In this case,
the default severity level threshold as found in the
src/options.lst
file.
Severity level threshold for the code areas of scheduling and TTSCP interpretation. This code is absent from the monolithic Epos.
Severity level threshold for the code area of the text structure representation. This usually does not include code which is specifically written to support a particular rules type.
Severity level threshold for the "interface" code area;
that is, for assorted (usually) non-member functions, usually
located in src/interf.cc
. This is a catch-all area.
Severity level threshold for the code area of parsing
text to yield a
text structure representation.
It nearly coincides with the src/parser.cc
file.
Severity level threshold for the code area of parsing and application of the rules. This usually does not include any code which is rule type specific.
Severity level threshold for the code area of most
types of rules, as well as their implementation in the
src/unit.cc
file. This covers especially
syllabification, diphonization and other structure
manipulations.
Severity level threshold for the code area of subst
and
related types of rules, as well as their implementation in the
src/unit.cc
file
Severity level threshold for the code area of low level speech syntheses (segments to speech). It covers both individual algorithms and the common code.
The global positive severity level threshold. Any debugging code which reaches at least this severity level is executed regardless of the code area specific threshold. This option is especially useful for generic debugging, when the code area responsible for incorrect behavior is still unknown.
The global negative severity level threshold. No debugging code
which fails to reach at least this severity level is executed regardless
of the code area specific threshold. This option is useful for setting
up a global severity level threshold for most (non-focused) code areas.
Should the always_dbg
and limit_dbg
options come into conflict,
the former takes precedence.
The parameter is a code area to be excepted from the limit_dbg
option.
This code area will obey its own severity level limit, even if the global
negative limit is stricter. The global positive severity level is however
unaffected. Every area uses the same name as in its corresponding severity
level threshold option, without the _dbg
suffix.