Mova0.6 pre-release

the flag of the Democratic Republic of the Congo 30. Lingala in Mova

Lingala uses the language code ln in Mova. Its package has no annotated treebank or parser model, so it has no measured parsing baseline. The Lingala text available in Mova’s corpora can illustrate the forms an implementation must handle. Parser training and evaluation require a separate layer of annotation.

Language and span identification in the multilingual pipeline

Mova assigns languages at two scopes in the first stage of its multilingual pipeline. It assigns a language to each sentence and to each span. The second stage uses the span’s language to select a parser model. Sentence and span labels serve different purposes in mixed text. A sentence label describes the sentence as a whole, while a span label determines which model is looked up for that part of the sentence.

For Latin script, tools/langseg distinguishes English and French using a Latin table, a lexicon for each language, and a character 4-gram model. It also distinguishes Hebrew-script varieties and recognizes Hebrew or Aramaic in scholarly transliteration. Scripts outside the supported ones receive other. A further Latin-script language can be added by supplying a lexicon built from an open Universal Dependencies (UD) training split through langseg latin-lexicon and adding a Lang code. The manual’s use of ln identifies the language of this edition. Identifying a span as Lingala requires support in the segmenter.

The corpus illustrates why a page’s language and a span’s language are separate judgments. These excerpts come from Lingala Wikipedia pages and have Latin-script forms.

FormGlossTranslationCorpus sentence id
“Aspect de”aspect of“aspect of”wiki:ln:Mbuma
“nyama ya mabɛ́lɛ”animal of breasts“mammal”wiki:ln:Nzɔku

The French label and the Lingala phrase illustrate what a span identifier may encounter in material collected from the same edition. The table gives human readings of the excerpts. It supplies no measured span-identification result.

Model lookup and unannotated Lingala output

At level 2, tools/mova-parse looks for the model corresponding to the language assigned to each span. The lookup uses the template <code>.bin, with the same language code in the directory and the filename. There is no ln model. When a span is assigned a language whose model is missing, the # parse comment reports that language and the output rows for the span have the following values.

CoNLL-U fieldOutput for a span whose model is missing
LEMMA_
UPOS_
XPOS_
FEATS_
HEAD_
DEPREL_
MISCParse=None

Parse=None records the absence of a parse. An underscore in HEAD leaves the head unspecified, while an underscore in DEPREL leaves the relation unspecified. In particular, this output assigns neither a root nor grammatical relations to the span. The rows can carry the input forms even though Mova supplies no Lingala tokenization, tagging, lemmatization, or parsing. Their presence therefore gives no evidence about where a Lingala tokenizer would place word boundaries. The missing-model output is conditional on the language assigned to the span. A Lingala string in the input does not by itself guarantee an ln lookup.

Treebank availability and the unmeasured parser baseline

Mova holds no annotated Lingala corpus. The supplied Wikipedia material has text and sentence identifiers. Those identifiers let a reader trace an example to its source. A treebank must also supply reference analyses, including the syntactic words and their heads and dependency relations. Without those analyses, the corpus cannot supply the reference trees used to score a dependency parser.

The baseline specified in What every language gets trains on a language’s UD training split and evaluates on its development split. Mova’s parser and tagger are in the en crate. English and French have models, en.bin and fr.bin. Their availability establishes which models exist. It supplies no estimate of attachment accuracy for Lingala.

MeasureWhat counts as a correct attachmentLingala result
Unlabeled attachment score (UAS)The predicted head agrees with the reference head.Unmeasured
Labeled attachment score (LAS)Both the predicted head and the dependency relation agree with the reference analysis.Unmeasured

A baseline can be reported only after evaluation against an annotated development split. Rows carrying Parse=None record missing analyses. They yield no Lingala attachment score.

Training and evaluation requirements for a future baseline

A Lingala baseline requires a UD training split and a separate UD development split. The annotation must establish the sentence boundaries and the units used as syntactic words, then consistently supply the categories and dependency analyses used in training and evaluation. The training material must cover the constructions the model is expected to encounter. The development split must provide held-out reference analyses so the scores measure performance on material outside the training split.

The examples show some of the decisions the annotation would need to address. These short excerpts have Latin-script forms.

FormGlossTranslationCorpus sentence id
“Lisakoli lya molɔ́ngɔ́”declaration of world“universal declaration”wiki:ln:Lisakoli ya molongo ya makoki ya moto
“Lisakoli ya molongo”declaration of world“universal declaration”wiki:ln:Lisakoli ya molongo ya makoki ya moto

The two excerpts preserve the spellings in the source. The spelling, the choice of connective, and the syntactic analysis are separate annotation decisions. Guidelines would need to specify how forms with different vowel letters or tone marking are represented and how the form used as a connective is analyzed in context. An English translation shared by two expressions cannot settle their word boundaries, lemmas, or dependency labels.

With the reference splits in place, en xpos-fill precedes en train, which trains the tree parser and tagger on the training split. Then en parse-eval measures UAS and LAS on the development split. A reported result needs to identify the splits and the annotation conventions behind them, especially where those conventions affect the units whose attachments are scored.

This evaluation would measure the tree parser under the baseline conditions. A multilingual input also has to reach the right parser. The Latin-script lexicon and Lang code address language identification, while the trained model must be available under the corresponding code for lookup. Attachment scores from a UD development split do not measure whether the multilingual pipeline assigned a passage the intended language.

Dependencies of frame and pragmatic analysis

Mova’s frame, pragmatic, and world components read English trees. For Lingala, dependency parsing is a prerequisite for giving those components syntactic input. A language label tells the pipeline which model to seek. It supplies no predicate, argument, or modifier analysis for a downstream component to read. The same applies to the fields in an unannotated row, where grammatical categories, heads, and dependency relations are unspecified.

A future Lingala model would provide a tree that could represent syntactic relations. The current description of the downstream components establishes English trees as their input. A Lingala parser baseline would measure attachment accuracy only. It would supply no evaluation of how frames are assigned, how an utterance is interpreted in context, or how a world representation is updated. The existence of a grammar description also supplies no such analysis for an individual input sentence.

Grammar claims in Squid and the implementation queue

Squid reads the grammar manual and turns each grammatical point into a claim. Formalizable points, including rules, closed lists, and statistics, enter its implementation queue. A claim there is pending until it has a place in Mova’s code. Publishing a rule in the manual or illustrating it with a corpus passage records a grammatical description. The claim’s presence in the queue gives no evidence that parsing applies the rule.

For Lingala, the first points needed are those that support tokenization, tagging, and a UD treebank baseline. A word-boundary claim can specify the forms and contexts in which a tokenizer would split or retain a sequence. A tagging claim can specify the category evidence for a form and the contexts in which the evidence is ambiguous. A treebank convention can specify how an analysis is recorded and give the evaluation a consistent reference. In each case the conditions on a claim matter. A spelling variant in the corpus is evidence that the spelling occurs there. Further evidence is needed to decide the contexts in which it is equivalent to another variant for lemmatization or tagging.

The queue and the baseline answer different questions. The queue records points that can be formalized for implementation. The baseline records how a trained parser attaches words in a particular annotated development split. Raw examples can support the wording of a claim, and an annotated example can supply a reference analysis. Neither supplies a baseline measurement on its own.

How Mova handles Lingala at the current package boundary

tools/mova-parse gets sentence and span language labels from tools/langseg, then looks up each span’s language model. tools/langseg distinguishes English and French in Latin script using a Latin table, language lexicons, and a character 4-gram model. It also handles Hebrew-script varieties and scholarly transliteration of Hebrew or Aramaic. Other scripts are labeled other. An additional Latin-script language requires a lexicon from an open UD training split through langseg latin-lexicon and a Lang code. For a language without its own model, span identification extends only to what the segmenter knows from the script or lexicon.

Lingala has no level-2 model. For spans labeled ln, tools/mova-parse reports the missing model in the # parse comment and leaves LEMMA, UPOS, XPOS, FEATS, HEAD, and DEPREL as _, with Parse=None in MISC. Mova provides no Lingala tokenization, tagging, lemmatization, or dependency parsing at this boundary.

Mova also holds no Lingala treebank, so no baseline has been measured. What every language gets calls for the same baseline for each language. The en crate trains the tree parser and tagger with en train on the UD training split after en xpos-fill. en parse-eval measures UAS and LAS on the development split. The existing models are en.bin and fr.bin.

The frame, pragmatic, and world components read English trees. Lingala supplies no parsed input to prag or world. Squid turns the manual’s grammatical points into claims and queues those that can be formalized. None of the chapter’s rules is implemented for Lingala. The first points needed are those that support a tokenizer, a tagger, and a UD treebank baseline.

Sources for this chapter

This page in Markdown https://md.mova.elamur.ai/free/en/docs/languages/ln/30-mova-tools/