Institut

Studium

Forschung


 

next up previous contents
Next: Initialization Up: The IMS German Festival Previous: Acknowledgments &nbsp Contents


Modules

The file ``lib/synthesis.scm'' contains the definition of several basic 'utterance types' (``Text'', ``Words'', ``Phrase'', ...).

festival> (set! utt (Utterance Text "Uni ist toll, sagt Martin."))

A list of modules is assigned to each utterance type with the help of ``defUttType''. Each module operates on the underlying utterance, the principle data structure used in Festival. The utterance is organized in relations. A module may modify relations or add new relations to the utterance. The function ``utt.synth'' processes all modules sequentially, but each module may be called on its own by using ``(MODULNAME UTT)''. ``MODULNAME'' may be ``Initialize'', ``Text'', ``Token'', ...

festival> (Initialize utt)
festival> (Text utt)
festival> (Token_POS utt)
festival> (Token utt)

The contents of an utterance structure can be saved by using ``(utt.save UTT FILENAME)''.
Two more functions which are useful when working with Festival are:
(utt.relationnames UTT), which returns a list of currently defined relations:

festival> (utt.relationnames utt)
(Token Word)

and (utt.relation_tree UTT RELATIONNAME), which displays a relation:

festival> (utt.relation_tree utt 'Token)
((("Uni"((id "_1")(name "Uni")(whitespace "")(prepunctuation "")))
 (("Uni" ((id "_6") (name "Uni")))))
 (("ist"((id "_2")(name "ist")(whitespace "")(prepunctuation "")))
 (("ist" ((id "_7") (name "ist")))))
 (("toll"
 ((id "_3")
 (name "toll")
 (punc ",")
 (whitespace " ")
 (prepunctuation " ")))
 (("toll" ((id "_8") (name "toll")))))
 (("sagt"
 ((id "_4") (name "sagt")(whitespace "")(prepunctuation "")))
 (("sagt" ((id "_9") (name "sagt")))))
 (("Martin"
 ((id "_5")
 (name "Martin")
 (punc ".")
 (whitespace " ")
 (prepunctuation " ")))
 (("Martin" ((id "_10") (name "Martin"))))))



Subsections
next up previous contents
Next: Initialization Up: The IMS German Festival Previous: Acknowledgments &nbsp Contents
Martin Barbisch
2001-08-28