i6_core.lexicon.modification

class i6_core.lexicon.modification.AddEowPhonemesToLexiconJob(*args, **kwargs)

Extends phoneme set of a lexicon by additional end-of-word (eow) versions of all regular phonemes. Modifies lemmata to use the new eow-version of the final phoneme in each pronunciation.

Parameters:
  • bliss_lexicon – Base lexicon to be modified.

  • nonword_phones – List of nonword-phones for which no eow-versions will be added, e.g. [noise]. Phonemes that occur in special lemmata are found automatically and do not need to be specified here.

  • boundary_marker – String that is appended to phoneme symbols to mark eow-version.

run()
tasks()
Returns:

yields Task’s

Return type:

list[sisyphus.task.Task]

class i6_core.lexicon.modification.MergeLexiconJob(*args, **kwargs)

Merge multiple bliss lexica into a single bliss lexicon.

Phonemes and lemmata can be individually sorted alphabetically or kept as is.

When merging a lexicon with a static lexicon, putting the static lexicon first and only sorting the phonemes will result in the “typical” lexicon structure.

Please be aware that the sorting or merging of lexica that were already used will create a new lexicon that might be incompatible to previously generated alignments.

Parameters:
  • bliss_lexica (list[Path]) – list of bliss lexicon files (plain or gz)

  • sort_phonemes (bool) – sort phoneme inventory alphabetically

  • sort_lemmata (bool) – sort lemmata alphabetically based on first orth entry

  • compressed (bool) – compress final lexicon

run()
tasks()
Returns:

yields Task’s

Return type:

list[sisyphus.task.Task]

class i6_core.lexicon.modification.WriteLexiconJob(*args, **kwargs)

Create a bliss lexicon file from a static Lexicon.

Supports optional sorting of phonemes and lemmata.

Example for a static lexicon:

Parameters:
  • static_lexicon (lexicon.Lexicon) – A Lexicon object

  • sort_phonemes (bool) – sort phoneme inventory alphabetically

  • sort_lemmata (bool) – sort lemmata alphabetically based on first orth entry

  • compressed (bool) – compress final lexicon

classmethod hash(parsed_args)
Parameters:

parsed_args (dict[str]) –

Returns:

hash for job given the arguments

Return type:

str

run()
tasks()
Returns:

yields Task’s

Return type:

list[sisyphus.task.Task]