---
title: "magyarlanc — paper by Zsibrita et al. (2013)"
description: "magyarlanc turns raw Hungarian text into word analyses and dependency trees by adapting its tagger and parser to Hungarian grammar."
canonical: "https://research.elamur.ai/free/en/papers/zsibrita-2013-magyarlanc-toolkit-morphological-dependency-parsing/"
---
Elamur: [Mova](https://md.mova.elamur.ai/free/en/) · [Parse](https://mova.elamur.ai/free/en/parse/) · [Dictionary](https://md.dictionary.elamur.ai/free/en/) · [Translate](https://md.translate.elamur.ai/free/en/) · **Research** · [Gali](https://md.gali.elamur.ai/free/en/) · [MCP](https://mcp.elamur.ai/) · [Locations](https://md.locations.elamur.ai/free/en/) · [Weather](https://md.weather.elamur.ai/free/en/) · [Constitution](https://md.constitution.elamur.ai/)

[Elamur Research](https://md.research.elamur.ai/free/en/) · [this page in HTML](https://research.elamur.ai/free/en/papers/zsibrita-2013-magyarlanc-toolkit-morphological-dependency-parsing/)

[Elamur Research](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2013](https://md.research.elamur.ai/free/en/papers/2013/) / magyarlanc : a toolkit for morphological and dependency parsing of Hungarian

# magyarlanc : a toolkit for morphological and dependency parsing of Hungarian

Paper · 2013 · János Zsibrita, Veronika Vincze and Farkas Richárd

**Authors:** [János Zsibrita](https://md.research.elamur.ai/free/en/authors/janos-zsibrita/), [Veronika Vincze](https://md.research.elamur.ai/free/en/authors/veronika-vincze/) and Farkas Richárd · **Year:** 2013 · **Venue:** SZTE Publicatio Repozitórium (University of Szeged) · **Licence:** other-oa per OpenAlex (not a CC licence; rights reserved) — text kept private

SZTE Publicatio Repozitórium (University of Szeged)

- [PDF](http://publicatio.bibl.u-szeged.hu/8748/1/R13-1099.pdf)

## Summary

A Hungarian word ending can tell you what job the word does in a sentence, even when its position gives little away. A verb ending can identify participants that the writer never names as separate words. Both facts matter when software tries to work out how a sentence fits together. The authors introduce magyarlanc, a toolkit that starts with raw Hungarian text and produces a grammatical analysis of each word and a tree of the relationships between words. Its design puts [morphology](https://md.research.elamur.ai/free/en/concepts/morphology/), the grammatical structure of words, at the center of [dependency parsing](https://md.research.elamur.ai/free/en/concepts/dependency-parsing/), the task of finding and naming those relationships.

The toolkit first finds sentence and word boundaries. A lexical analyzer then lists the possible readings of each word, pairing a dictionary form with a grammatical code. A modified tagger chooses among the readings using the surrounding text. It makes this choice with a compact set of tags that keeps distinctions when they are needed to resolve ambiguity. The toolkit then returns the full grammatical code. The codes follow a harmonized scheme so that analyses from the lexical resource and annotations from the Szeged Corpus can be used together. The parser, trained on the [Szeged Dependency Treebank](https://md.research.elamur.ai/free/en/papers/vincze-2010-hungarian-dependency-treebank/), uses these word analyses to find syntactic relationships. The toolkit also adopts conventions for names and numbers written as several words and for clauses in which the equivalent of *be* is unspoken.

On the randomly held-out Szeged Dependency Treebank test set, the toolkit achieved 96.33% accuracy for complete word analyses. A token counted as correct only if its dictionary form, word class and full set of grammatical features all matched the manual annotation. The parser achieved 93.22% unlabeled attachment, which checks the choice of parent word, and 91.42% labeled attachment, which also checks the name of the relationship. In a separate run on the historical novel *Stars of Eger*, the full pipeline processed 1000 sentences per minute on a single thread using 1 GB RAM. The run through segmentation and tagging reached 3000 sentences per minute.

The paper's contribution is the integration of these stages around a consistent analysis of Hungarian, from raw text through a dependency tree. The toolkit is implemented in Java and was made freely available for research. The treebank scores describe its combined performance on the reported split, and the speed run shows what adding parsing cost for the novel under the reported conditions.

## Deep dive: magyarlanc : a toolkit for morphological and dependency parsing of Hungarian

magyarlanc turns raw Hungarian text into word analyses and dependency trees by adapting its tagger and parser to Hungarian grammar. · about 32 minutes to read

**In this deep dive**

1. [The problem and its context](#dd-the-problem-and-its-context)
2. [The method, step by step](#dd-the-method-step-by-step)
3. [Experiments and results](#dd-experiments-and-results)
4. [What the ablations show](#dd-what-the-ablations-show)
5. [Limitations](#dd-limitations)
6. [What came after](#dd-what-came-after)

### The problem and its context

#### Why word position is an incomplete guide

A sentence analyzer has to decide which words belong together and what grammatical relationship they have. A noun phrase might be the subject of a verb, its object or a modifier of another expression. Position can supply evidence for that decision. In the authors' comparison with [English](https://md.research.elamur.ai/free/en/topics/english/), the noun phrase before the verb is usually the subject. In Hungarian, the position immediately before the verb can hold the focus, the part of the sentence that presents new or emphasized information. A subject, an object or another argument of the verb can occupy that position. A topic, which carries information already under discussion, precedes the focus in the pattern the authors describe.

Free word order in this account has a specific meaning. The same grammatical function can appear in different positions because the ordering reflects how the speaker presents the information. The positions are organized, and the organization answers a different question from the one the parser is asking. Recognizing the focus can tell a reader something about what the sentence emphasizes. To determine whether that expression is a subject or an object, a parser needs other evidence. The paper sets aside the internal order of noun phrases when making this observation about relationships at sentence level.

Case endings provide some of that evidence. Case is a grammatical feature that helps indicate how a noun or related expression participates in a construction. The paper uses *lánc*, meaning chain, and *lánccal*, the form used for a meaning like *with a chain*. The instrumental case supplies the latter relationship. In *láncaikkal*, a form meaning *with their chains*, the case ending comes after the material expressing possession and plurality. A parser can therefore gain several pieces of information from the same written token. The analysis has to identify which features belong to the form and pass them on in a usable representation.

The authors give *about 20* as the number of Hungarian noun cases. They qualify that description because grammars and coding schemes differ in how they treat some rare suffixes. A suffix counted as a case ending in one scheme may be treated as derivational in another, where derivation concerns the formation of words from other words. This matters to a toolkit trained against manual annotations. An analyzer and a corpus can each represent a coherent view of a word while disagreeing on which distinction should appear explicitly in its code.

The paper describes Hungarian as agglutinative. An affix can add a grammatical feature to an existing form, and affixes can accumulate. A dictionary entry can consequently give rise to many surface forms. A [word form](https://md.research.elamur.ai/free/en/concepts/word-form/) is the form that actually appears in the text. Its [lemma](https://md.research.elamur.ai/free/en/concepts/lemma/) is the dictionary form under which it is analyzed. Finding the lemma lets the toolkit associate inflected forms with the same lexical entry, while retaining the features of the surface form lets it explain what each occurrence is doing.

Vowel harmony adds variation to the relation between a suffix and its spelling. The paper pairs *futnak*, from *fut* meaning run, with *mernek*, from *mer* meaning dare. The stems have different vowels, and the suffix takes a corresponding vowel in each form. Both verbs carry the same person and number features in this example. An analyzer has to arrive at the same grammatical distinction through different written forms. In other examples a single written form supports several readings, and the work shifts from recognizing an ending to deciding which analysis fits the sentence.

#### Information in a word and information missing from the text

A Hungarian verb can show the person and number of a participant and carry information about whether the object is definite. This permits speakers to leave some pronouns unspoken. The paper illustrates this with *Vártalak tegnap este*, a sentence about waiting for someone the previous evening. The inflected verb *Vártalak* supplies a first-person singular subject and a second-person object. Neither participant occupies its own word position. A word-level analysis can recover those grammatical features even though a tree of the written tokens has no separate pronoun for either participant. The paper uses the example to show the contribution of morphology to understanding the clause.

Some meanings that its English examples express with separate words are also expressed within a Hungarian verb. In *csináltathatjátok*, the analysis includes a causative feature, which indicates having something done, and a modal feature, which expresses possibility or ability. The word also carries person, number and object-related information. An application that expects to look for a separate word for each of those contributions would miss the structure of the Hungarian form. The morphology has to expose features that would be visible in the sequence of words in the English rendering.

The copula poses a different problem. A copula links a subject with what is predicated of it, as *is* does in an English sentence describing a house as big. In the Hungarian example *A ház nagy*, the corresponding present-tense clause has no written copula. A related future construction, *A ház nagy lesz*, has the overt form *lesz*. The paper also compares the present clause with a past one using *volt*. This alternation poses a question for syntactic annotation. If the version with a visible copula organizes its other words around that verb, how should the version with the same predication be represented when there is no corresponding token? The Szeged annotation and the parser's complex labels address different parts of that question.

The paper distinguishes constituency parsing, which groups words into phrases, from dependency parsing, which links words through head–dependent relationships. In a dependency tree, the head is the word that governs a relationship, and a dependent attaches to it. An attachment can name the relation as well as locate the head. The authors see an advantage for Hungarian in the ability to link grammatically related words across intervening material. Once position supplies less direct evidence of grammatical function, the choice of what information to give the parser becomes particularly important.

#### What the toolkit inherited

The paper describes a field with existing tools for the individual stages. For [tokenization](https://md.research.elamur.ai/free/en/concepts/tokenization/), the task of dividing text into units that later components can analyze, MtSeg had been adapted to Hungarian using language-specific lexical material, including abbreviation information. The authors also identify huntoken as a widely used tool for finding both sentence and token boundaries. Existing work had therefore already confronted the fact that punctuation and spelling conventions have to be interpreted with knowledge of the language. [Creating Open Language Resources for Hungarian](https://md.research.elamur.ai/free/en/papers/halacsy-2004-creating-open-language-resources-hungarian/)

The earlier morphological tools differed in both availability and the kind of analysis they supplied. Humor followed a unification approach. A stem or affix carried features governing the other pieces with which it could combine, and a proposed combination had to satisfy those restrictions. The paper describes Humor as neither freely available nor open source. It identifies hunmorph as an open-source alternative used for such tasks as word analysis, finding dictionary forms and checking spelling in several languages, including Hungarian.

Another set of tools addressed [part-of-speech tagging](https://md.research.elamur.ai/free/en/concepts/part-of-speech-tagging/), the selection of a grammatical category for a token in context. In the Hungarian systems discussed here, the decision can also distinguish readings within a category. The authors describe hunpos, developed on the basis of hunmorph, and PurePOS as open-source taggers that used hidden-state sequence methods. They also describe a tagger based on Humor that supplemented the analyzer with statistical information from a corpus. [The Hungarian National Corpus](https://md.research.elamur.ai/free/en/papers/varadi-2002-hungarian-national-corpus/)

The authors point out a problem with comparing these tools directly. The Hungarian coding schemes recorded different grammatical distinctions. A score based on one tagset could therefore reward the successful prediction of an analysis that a different tagset did not even distinguish. The same mismatch affected training. The resource that supplied possible analyses and the manually tagged corpus used to learn how to select one had to agree on the meaning of the labels exchanged between them. Otherwise, converting labels could discard features before the tagger or parser had a chance to use them.

Earlier experiments had also investigated how established dependency parsers performed on Hungarian. The toolkit draws on that work in choosing its parsing component. The authors place the contribution in the adaptation and integration of established components, including the agreement between lexical output and corpus annotation, and describe magyarlanc as containing, to their knowledge, the first dependency parser adapted for Hungarian in a toolkit of this kind. [Dependency Parsing of Hungarian](https://md.research.elamur.ai/free/en/papers/farkas-2012-dependency-parsing-hungarian-baseline-results/)

### The method, step by step

The full pipeline passes through several levels of description. It starts by finding the portions of the text that should be analyzed together. It then recognizes possible grammatical readings of the tokens within each sentence. The tagger settles those readings using sentence context, and the parser uses the resulting information to decide how the words are related. Each stage resolves a different ambiguity. A period can be ambiguous as a boundary, a word can be ambiguous as a grammatical form, and a grammatically analyzed word can still plausibly attach to more than one other word.

From raw Hungarian text to a dependency tree The steps in order.

#### Finding sentences and tokens

The full workflow starts from a plain text file. For sentence splitting, the authors use the component from MorphAdorner and extend its dictionary with Hungarian abbreviations. A period can serve as part of an abbreviation within a sentence. If the splitter interprets every such period as a sentence boundary, it can send fragments to the tagger and parser. The paper gives the abbreviation *kft.* for a company designation and *szül.* for a form meaning born, along with abbreviations of month names. Dictionary knowledge helps the splitter recognize the period as part of a familiar expression.

MorphAdorner also supplies the tokenizer, which identifies the individual units within the resulting sentences. The adaptations pay particular attention to abbreviations involving letter combinations. In Hungarian spelling, the letters *cs* together represent a single sound. A tokenizer that interprets a spelling convention through individual written characters alone could mishandle an abbreviation involving such a combination. The paper identifies these cases as part of the Hungarian adaptation and leaves the detailed tokenization rules unspecified.

The order of these operations matters to the later stages. The tagger depends on neighboring tokens to choose a reading, and the parser constructs relationships within a sentence. A boundary that cuts off the relevant context changes the input to both. The splitter uses language-specific evidence to protect that context before the toolkit makes any decision about a word's lemma or syntactic function.

#### Making candidate analyses comparable

The morphological analyzer is based on the lexical resource morphdb.hu. Its job at this stage is to find the dictionary forms and grammatical readings that the surface form can support. Finding a dictionary form is called [lemmatization](https://md.research.elamur.ai/free/en/concepts/lemmatization/). In this toolkit the lemma comes paired with an analysis, so the subsequent decision can concern both which dictionary entry the word belongs to and what grammatical features it carries in that occurrence.

The form *egyed* illustrates why the candidate list matters. One reading treats it as a noun meaning an entity. Another treats it as a form of *eszik*, meaning eat, with imperative and object-related features. A further reading connects it to *egy*, meaning one, in a possessive form. The analyzer can supply all these readings for the same string. In the notation used for the example, an at sign separates each lemma from its morphological code. The alternatives give the tagger a defined set of analyses to consider when it encounters the form in a sentence.

The lexical analyzer originally expresses its findings in KR. This scheme organizes information in a hierarchy of attributes and values. A default value can remain implicit, so a missing attribute in the code may have an established interpretation. The paper gives singular number and third person as examples of defaults. MSD, the scheme used in the original Szeged Corpus annotation, instead expresses descriptions in strings with meaningful positions. The initial position identifies the part of speech. Further positions represent features appropriate to that class. A verb description can encode such features as mood, tense, person and number.

The two resources consequently posed a problem deeper than having different spellings for their labels. If the schemes made different decisions about what an analysis should contain, converting from one string format to the other would only solve part of the problem. Some distinctions might have no direct counterpart. The harmonization work described by the authors made the grammatical principles of MSD and KR compatible enough to use the lexical analyzer and the manual annotations together. magyarlanc converts the lexical analyses into the harmonized MSD-style representation.

A decision about derivation shows what compatibility means in practice. For *csináltathatjátok*, the lemma is *csinál*, meaning make or do. The analysis preserves causation and modality because these distinctions can have syntactic counterparts in other languages and were judged relevant to later processing. In *kezel*, a verb meaning treat or handle, the derivational connection to *kéz*, meaning hand, remains outside the morphological code. Both examples have something to say about how a word is formed. The harmonized coding scheme asks which distinctions the output should expose for syntax or applications.

The result is a common basis for learning from annotations and analyzing new text. When the lexical resource proposes a feature and the corpus assigns a feature, the tagger can interpret them within the same scheme. The full code can then carry information into the parser and into the output file. Harmonization happens before tag reduction. These are distinct design decisions. Harmonization establishes what an analysis means. Reduction determines which part of that analysis the tagger needs to distinguish during its choice.

#### Choosing a reading with a compact tagset

The authors adapt the Stanford part-of-speech tagger. It uses a maximum entropy classifier to choose among tags given evidence from the text. In magyarlanc it can draw on the possible tags returned by the morphological analyzer. The adaptation lets lexical analysis constrain the grammatical alternatives and lets the contextual tagger decide which alternative is appropriate in a sentence. [Feature-Rich Part-of-Speech Tagging](https://md.research.elamur.ai/free/en/papers/toutanova-2003-feature-rich-part-speech-tagging/)

The paper describes the training resource for the tagger as the Szeged Corpus, which has 1.2 million words with manual part-of-speech annotation. Training directly on the original set of richly specified MSD codes would confront the classifier with thousands of possible labels. It would have to treat many combinations of features as separate decisions. The authors train instead with a reduced inventory of about 60 tags. The toolkit still returns the full harmonized code after selecting a reading.

To see how that is possible, suppose that two full analyses receive the same reduced label. If a particular written form can support only one of those analyses as a candidate, selecting the reduced label for that form leaves its full analysis identifiable. The lexical stage already supplied the information the tagger left implicit. If the same word can support both full analyses, collapsing them under the same label can erase a distinction the tagger actually needs to make. The reduction rules preserve such distinctions so the full code can be recovered using the analyses available for the form.

The paper uses nouns with *-nak* or *-nek* to make this principle concrete. The same ending can occur in the genitive and dative readings described by the authors. A tagger that returned only the general noun category would leave those readings unresolved when both are available. The singular dative code `Nc-sd` and singular genitive code `Nc-sg` therefore reduce differently. For a contrasting case, the singular dative code and `Nc-sd---s3`, which also marks a third-person singular possessor, can share a reduced form under the authors' rule. They explain that the same lemma does not supply an identical surface form for those two analyses. In that case the extra contrast need not occupy a separate tag for the classifier's decision.

The default for nouns, adjectives, numerals and pronouns is to retain the broad part-of-speech category. Particular ambiguities call for departures from that default. Nominal forms in the essive and superessive can coincide. The spelling *szépen* can receive a reading roughly equivalent to nicely or a reading involving being on a nice one. The case information preserved for such forms allows the tagger to separate readings that the default reduction could put together.

Possession supplies other cases in which the written form alone leaves the feature bundle open. The paper gives *Ajkán*, which can refer to being in the town Ajka or to being on someone's lip. The analyses differ in their lemmas and in the presence of a possessor. The reduced descriptions keep those possibilities distinct. In *énekét*, the paper identifies an ambiguity between a form meaning someone's song and a form meaning the song belonging to someone already referred to. Both have an accusative reading, while the reduced descriptions distinguish the kinds of possession involved. The design selectively preserves information to keep meaningful alternatives visible to the tagger.

Some categories preserve a subtype even in cases where the default would reduce them to the broad category. The paper lists distinctions among personal, interrogative and relative pronouns, and keeps a distinct reduced form for fractions. Adverbs generally reduce to `R`, but the scheme distinguishes preverbs as well as interrogative, relative and personal pronominal adverbs. Articles take the reduced label `T`. For conjunctions, postpositions, interjections, abbreviations and words marked as misspelled or unknown, the original code serves as the reduced code. Here reduction is a set of class-specific decisions about which tags the classifier should see.

#### How the verb rules handle overlapping forms

The default reduced label for a verb is `V`, and the authors give auxiliaries their own label, `Va`. The more detailed verb rules respond to coincident spellings across conjugations. The paper distinguishes forms from the subjective and objective conjugations. In the examples used to explain the rules, the alternatives often differ in whether the object is understood as indefinite or definite. The same spelling can leave that distinction unresolved even after the lexical analyzer has recognized the verb.

For example, *olvasnánk* can mean that we would read something or that we would read a definite object. The speaker, number and conditional mood do not by themselves distinguish the readings. The reduction gives the objective form the tag `Vcp` in the overlap the authors describe. In *iszom*, the ambiguity concerns a different set of forms, including a first-person singular form. The objective reading receives `Vip` under the applicable rule. The two cases share a reason for retaining a distinction, while their tags specify different patterns of overlap.

A single spelling can also carry readings with different subjects. The paper uses *ennék* to contrast a first-person singular reading about what the speaker would eat with a third-person plural reading about what others would eat, with definiteness also differing between the readings. The relevant third-person plural objective form is distinguished with `V3p`. In the past indicative example *osztottam*, both readings describe what the speaker divided. The objective form receives `Vy` so the tagger can make a choice about object definiteness even though the person, tense and written form are shared.

The scheme also keeps a separate reduced code, `Vm`, for imperatives. The paper gives `Vp` to present-tense forms covered by none of the previous verb rules and illustrates the relevance of tense with *ért*. The same spelling has a present reading connected with understanding and a past reading connected with reaching. Choosing between them affects both the dictionary entry and the features of the token. A verb tag that discarded every distinction beyond the word class would do little work in this example.

The full description recovered after tagging contains the features relevant to that particular word class. For a nominal, these can include case, number and information about the possessor or the possessed item. For a verb, mood, tense, person, number and definiteness can be relevant. The paper distinguishes subclasses too. The feature inventory appropriate to an infinitive differs from the one appropriate to a finite main verb. The toolkit can therefore use a manageable set of tags internally while exposing a more detailed and class-sensitive description to later processing.

#### Building dependencies from the word analyses

For syntax, the authors integrate the Bohnet parser. They base the choice on the earlier comparison of dependency parsers for Hungarian. The parser is trained on the Szeged Dependency Treebank, whose 82,000 sentences carry manual part-of-speech and dependency annotation. The training examples thus identify grammatical descriptions of tokens and the parent and relation assignments the parser is intended to recover. At runtime, the toolkit has to produce the word analyses before it can supply that type of input to the parser. [Top Accuracy and Fast Dependency Parsing](https://md.research.elamur.ai/free/en/papers/bohnet-2010-top-accuracy-fast-dependency-parsing/)

A dependency output answers a location question and a classification question for a token. The parent identifier tells the reader where the grammatically governing node is. The dependency label describes the relationship to that node. The toolkit's longer output includes fields for the word, its lemma, its full MSD code, a part-of-speech field and an explicit list of morphological features. The resulting tree can then be read alongside the grammatical evidence available for each word.

Consider the sample analysis of a sentence in which a president promises that a federation's leadership will correct errors. The example contains a noun for the president, a verb for the promise, an expression for the federation's leadership and a separate verb for correcting the errors. The structure has to identify relationships at both levels of the sentence. The token rows let the reader follow those relationships through parent identifiers. They also show how the original words and their analyses remain available even when the relation leads across other words. In the row for *hibákat*, the lemma is *hiba*, and the listed features indicate an accusative plural noun. That word-level description and the dependency describing its role answer complementary questions.

#### Representing names, numbers and an unspoken copula

The toolkit treats multiword names and numbers in a particular way. For a name such as *Coca Cola Ltd.*, the last word of the unit serves as the head. The authors relate that choice to Hungarian inflection, which falls on the last word of such a unit. Earlier words form successive links to the next word. The word immediately before the head connects to it, and any earlier word connects through the same sequence. For a named entity those links carry `NE`. For a multiword numerical expression such as *42 million*, the same arrangement uses `NUM`.

This convention specifies the internal structure of a multiword unit. Choosing the last word as the head determines where the unit's grammatical features can be associated with the rest of the sentence. Using successive links also determines the reference parent of each preceding word. An analyzer that recognized the words as belonging to the same unit but connected them directly to a different head would produce a different tree. The paper gives the rationale for the convention and distinguishes the named-entity and number labels. It leaves the detection procedure for the relevant units undescribed.

The missing copula requires another change in representation. The Szeged Dependency Treebank can use a virtual node, a node with a syntactic function but no corresponding written word. With that node, the annotation can give the present-tense clause a structure comparable to the version with an overt copula. In the paper's house example, a reader can compare the clause containing *volt* with the present description of the same house. The overt past form makes the head visible. A virtual node allows the corresponding present structure to retain the role of that head.

magyarlanc adopts a complex-label approach from earlier experiments discussed by the authors. The label on a child encodes information about the unspoken head and the child's relationship to it. In `ROOT-VAN-SUBJ`, `VAN` identifies the absent copula, `ROOT` indicates its role as the root of the clause, and `SUBJ` identifies the word's relation to it as subject. The paper's illustrations compare a tree with an overt copula, a tree with a virtual node and a representation that records the missing relationship in the labels. The combined label allows the output on visible tokens to express information that the reference analysis can represent with a separate node.

This treatment concerns the type of missing copula illustrated in the paper. The example of *Vártalak* shows a different situation in which information about unspoken participants comes from the verb's inflection. The two cases demonstrate distinct kinds of evidence. A verb's grammatical features can indicate who the participants are, while complex dependency labels can represent a head that the treebank treats as structurally present even though its word form is absent.

#### What the output preserves

The toolkit offers a mode that performs morphological analysis alone, a mode that segments and tags the text, and a mode that also builds dependencies. In the token-based output the rows are separated into sentences by blank lines. The shorter tagged output gives the original form, the lemma and the full MSD description. A reader can use those fields to distinguish what was written from how the toolkit interpreted it. In the example sentence about counting on various groups, the original inflected forms appear with their dictionary forms and case-bearing grammatical descriptions.

With parsing enabled, each row also identifies the token within its sentence and supplies the fields needed to recover the tree. The paper's longer example shows the part of speech separately from the full code, lists individual morphological features and records the parent and relation. That representation makes it possible to inspect the grammatical decision and the syntactic decision for the same occurrence. The toolkit also incorporates whatswrong, which draws the dependencies as arrows and places coarse grammatical categories beneath the words.

The method is described through the candidate analyses, reduction rules, training resources, annotation conventions and output fields. The paper supplies no mathematical formulas for the classifier or parser. Its evaluation measures are specified in terms of which output fields have to agree with the reference annotations.

### Experiments and results

#### Training and testing on the Szeged annotations

The authors evaluate the tagging and parsing stages with the Szeged Dependency Treebank. They assign 80% of its sentences to the training set and the remaining 20% to the test set at random. In that order, the first share is for training and the second is for evaluation. The unit of assignment is the sentence. This preserves the context needed for tagging and keeps the full network of dependencies within each test sentence intact.

The paper describes the Szeged Corpus when explaining where the manually annotated tags come from and the Szeged Dependency Treebank when explaining the parser's training and the evaluation. The resources have distinct roles in the account. The discussion of the corpus motivates the use of full, harmonized codes and describes the tagger's training material. The treebank gives the experiment a reference for syntax as well as morphology. Its manual dependencies allow the authors to check an automatically chosen parent and label against an annotated one.

The baselines for the toolkit's design come from earlier work in a limited sense. The authors refer to a Hungarian parsing comparison as the basis for selecting Bohnet. They also describe existing segmenters, analyzers and taggers, and explain why taggers that predict different coding schemes cannot be compared directly by quoting their scores. The results reported for magyarlanc contain no matched baseline run of another toolkit on the same split. The scores therefore characterize the system evaluated here. They leave the relative performance of alternatives on that protocol unresolved.

#### Exact agreement on a complete word analysis

The tagging experiment treats a token as correct only when the lemma and its full morphological description are correct. The description includes the word class and all the relevant morphological features. Under this criterion, a noun whose class and lemma are right but whose case is wrong is an error. So is a verb with the correct feature bundle but the wrong lemma. A match of the reduced tag alone does not satisfy the criterion because the reduced tag is an intermediate decision, while the evaluation checks the recovered analysis.

magyarlanc achieves 96.33% accuracy on this complete-analysis criterion in the Szeged test experiment. This result is more specific than a broad claim about the percentage of word classes recognized correctly. It represents simultaneous agreement across the fields the evaluation requires. The metric also joins the work of proposing analyses, selecting among them and returning the full description. It gives no separate score for candidate coverage or for the tagger's success conditional on having the right analysis among its choices.

The strict criterion gives mistakes a direct interpretation for later stages. An incorrect case, person or definiteness value can matter to syntax even when the broad word class is right. The word analysis can also be wrong in a way that has no effect on the particular attachment. The tagging result does not distinguish those possibilities. Its question is whether the completed token analysis agrees with the manually recorded one.

#### Choosing a parent and naming the relationship

The authors use Labeled Attachment Score, abbreviated LAS, and Unlabeled Attachment Score, abbreviated ULA in the paper. Both measures concern the dependency assigned to a token. For ULA, the predicted parent must match the reference parent. For LAS, the parent and the relation label must both match. A token attached to the right verb under the wrong grammatical relation can therefore satisfy ULA while failing LAS. Giving a plausible relation name to an attachment with the wrong parent fails both tests.

On the Szeged Dependency Treebank test set, magyarlanc achieves 93.22% ULA and 91.42% LAS. The labeled score is lower, as its definition leads one to expect when some correct parent choices receive incorrect labels. The unlabeled score describes how frequently the parser finds the reference head. The labeled result is the stricter measure of whether it also characterizes the link as the annotation does. The reported aggregates do not identify which labels cause the stronger criterion to fail or how the errors are distributed among sentence types.

The complete-analysis score and the attachment scores concern different decisions. Agreement on a lemma and feature bundle is measured at a token. Attachment involves both that token and another location in the sentence, along with a relation in the labeled case. A sentence with a mistaken word analysis can still contain correctly predicted links. A sentence with accurate word analyses can contain a wrong attachment. The paper gives the results together to characterize distinct outputs of the pipeline. It provides no joint error counts that would allow the tagging score to explain the parsing scores.

#### Throughput on a historical novel

The speed evaluation uses *Stars of Eger*, a historical novel by Géza Gárdonyi. It is separate from the manually annotated test split. The paper reports how fast the toolkit processed the novel, using sentences per minute as the unit. Running from segmentation through dependency parsing on a single thread with 1 GB RAM, magyarlanc processes 1000 sentences per minute. The configuration that stops after segmentation and tagging processes 3000 sentences per minute.

magyarlanc processing modes on Stars of Eger by sentences per minute The pipeline processes more sentences per minute when it stops after tagging.

**The numbers**

| System or setting | sentences per minute |
| --- | --- |
| Segmentation and tagging (this paper) | 3000 |
| Full pipeline through dependency parsing | 1000 |

The two runs do different amounts of work. The shorter mode provides word-level output, while the full mode also makes the parent and relation decisions. The chart compares actual output configurations on one throughput measure. It does not assign a separate duration to the parser or show how much time individual operations within either run consume. The memory and threading conditions describe the full run as reported.

The novel also serves a different experimental purpose from the treebank. The random split is used to check automatic output against manual annotation. The novel run tests the time needed to produce output on a body of text. The reported speed tells a reader what the toolkit achieved for that workload. The paper does not report morphological or syntactic accuracy on the novel, so the measurement cannot establish how well the output agrees with a human analysis there.

### What the ablations show

The paper reports no accuracy ablations. It offers a throughput comparison between processing modes, linguistic analyses behind particular design choices, illustrations of the resulting trees and an overall evaluation under several scoring criteria. These forms of evidence answer different questions. The timing comparison observes what happens when the pipeline stops before producing dependencies. The design examples show what information particular representations preserve. The aggregate scores measure agreement for the resulting toolkit.

#### What the shorter run establishes

The run that ends after tagging directly addresses the cost of requesting a dependency output. On the same novel, it has higher throughput than the run that also builds trees. Choosing the shorter pipeline changes the deliverable along with the processing time. It answers a question about the operating modes, since an application that needs only lemmas and grammatical features can obtain them without running the rest of the pipeline. The comparison supplies no accuracy measurement for modifying an internal component of the full system.

The experiment also stops short of profiling the pipeline. Producing a dependency result involves building the tree and preparing an output with additional information. The reported sentences-per-minute results cover the requested configurations as wholes. They support a comparison of those configurations under the conditions given. They do not isolate how the parser, feature handling, other processing or output contributes to total runtime.

#### Which distinctions the tagger has to keep

The reduction rules provide a qualitative analysis of when grammatical detail matters to choosing a reading. The examples with *-nak* and *-nek* show why a broad noun tag can be insufficient. Different analyses of one surface form need distinct reduced codes if the contextual classifier is to choose between them and return the full result. The comparison with the dative plus possessor case shows why some full codes can share a reduced tag. Where a given lemma does not supply the same form for both readings, the lexical candidates supply the distinction that the reduced label omits.

This is an analysis of identifiability from the available candidates. It gives the reader a way to check that a reduction rule makes sense for a particular set of forms. The verb examples make the same argument in a different part of the grammar. If the spelling is shared by subjective and objective forms, preserving a distinct reduced tag can keep a choice about definiteness open to the classifier. If a feature has already been settled by the candidate analysis, giving it another separate classifier label may be unnecessary. Neither set of examples measures the frequency of the affected forms in the experiment.

The overall tagging result evaluates the completed procedure with the reduced inventory. The paper does not report training the same adapted tagger on the full codes and comparing results. It also leaves specific distinctions intact, including separate tags for ambiguous case or conjugation, while keeping the rest of the pipeline unchanged. The examples explain the rationale for the inventory. How much each rule contributed to the observed score remains open.

#### What the tree examples and scoring comparisons reveal

The illustrations of the copula compare possible descriptions of closely related clauses. With the verb overt, the word can occupy a node in the ordinary token sequence. In the present clause, one description introduces a virtual node and another expresses the hidden structure through labels on visible nodes. The comparison explains which information the combined label is intended to carry. It does not measure whether the approach improves attachment accuracy over other ways of handling the same clauses.

The authors mention earlier experiments on inserting virtual nodes and say the problem still requires investigation. Their choice of complex labels is grounded in that prior work, but the toolkit evaluation gives no separate result for clauses with a missing copula. The same distinction applies to the chains for names and numbers. The authors give a reason for making the final element the head and show what links the rule would imply. They do not compare attachment outcomes with those from another convention for multiword units.

The labeled and unlabeled scores form a controlled comparison of scoring requirements on the dependency output. The labeled criterion demands everything the unlabeled one demands and additionally checks the relation. The lower labeled score shows that some head choices that satisfy the first test fail the additional label test. This is useful for interpreting which decisions the metrics cover. It gives no evidence about whether a different tagset, parser or tree representation would improve either decision.

### Limitations

#### Limits the authors identify

The authors identify incompatible morphological coding schemes as an obstacle to direct comparison with earlier Hungarian taggers. Accuracy depends on the features represented and on what counts as a correct answer. The harmonized scheme allows magyarlanc to work with its chosen lexical resource and corpus. It does not automatically produce a common test for tools whose outputs represent different analyses. A comparative result would require an agreed evaluation representation and would need to account for the grammatical information each conversion preserves.

They also leave the handling of virtual nodes open. Their account of prior experiments on missing heads emphasizes the need for further investigation. Complex labels provide a workable representation within the toolkit, and the diagrams show how that representation preserves the relation to a missing copula. The authors offer no claim that the issue has been settled for Hungarian in general or that the adopted representation is optimal for every clause with an unspoken element.

The discussion of case adds a narrower qualification. The number of Hungarian cases is approximate because some less common suffixes are classified differently across grammars or coding schemes. This tells the reader how to interpret the toolkit's output. The labels are a consistent working analysis tied to particular resources. Disagreement with a different classification can reflect an annotation decision as well as an error of automatic analysis.

#### Limits of the reported evaluation

The random split measures performance on held-out sentences from the same annotated treebank. That is a meaningful test of reproducing the treebank's analyses, and the paper reports the split clearly. Its design leaves transfer to an independently annotated collection unmeasured. The run on *Stars of Eger* provides independent text for throughput, but the authors give no annotation comparison for that run. The article therefore supplies no direct evidence that the accuracy measured on Szeged also holds for the novel or for a collection with different writing conventions.

The authors present one reported split and aggregate scores. The reader cannot see how much those scores vary across other random splits or according to sentence length, construction or type of word. The aggregate tagging score joins mistakes involving lemmas, parts of speech and more detailed morphology. The attachment results join many different dependencies. Separate analyses of rare forms, ambiguous case endings or missing copulas could expose weaknesses hidden by the overall figures, but those breakdowns are absent.

The description presents language-specific adaptations to sentence splitting and tokenization. The accuracy experiments report results for tagging and parsing. There is no separate segmentation score showing how frequently abbreviations or other boundary cases are handled correctly. The paper also does not give a comparison of parsing with manual word analyses and parsing with the automatically selected analyses. Accordingly, readers cannot quantify how much of the measured parsing error originates in the word analyses or how much remains when those analyses are correct.

Several choices are made together in the evaluated system. The toolkit uses the harmonized codes, the compact tagset, a lexical analyzer, a modified tagger and the selected parser. It also adopts tree conventions tied to the training annotation. The measured accuracy belongs to that combination. There is no matched experiment from which to estimate the independent effect of harmonization, tag reduction or complex labels on the final score. The paper makes the linguistic reasoning for those choices inspectable through examples, which is evidence about the design instead of the size of an empirical improvement.

The runtime evidence has a similarly defined scope. Sentences per minute treats each sentence as a unit even though sentences can differ in length and structure. The reported memory and threading details describe the full run, and the book identifies the workload. The paper supplies no runtime breakdown across stages and no range measured across multiple workloads. The observed rates are most directly useful for understanding the reported run and the difference in work requested by its processing modes.

Finally, the paper's measurements stop at linguistic preprocessing. They establish agreement with the chosen word and dependency annotations and report throughput for producing those outputs. A tree could support a task that depends on knowing which words are related, but that would require evaluating the later task. The toolkit article leaves open how particular applications respond to the accuracy profile it reports and which remaining errors matter most to them.

### What came after

The later citing works place magyarlanc alongside research on parser evaluation and on using dependency structure for a more specific linguistic task. Their titles establish the questions they investigate. The details of their use of magyarlanc are unspecified, so the citation supports a connection without establishing that they reused a particular component, output convention or training resource.

[Overview of the SPMRL Shared Task](https://md.research.elamur.ai/free/en/papers/seddah-2013-overview-spmrl-2013-shared-task/) concerns cross-framework evaluation of parsers for morphologically rich languages. That scope connects with the problem behind magyarlanc's adaptation. The Hungarian toolkit paper asks what must change to make a chain of analyzers work with the language's morphology and annotation. The shared-task overview places parser evaluation in a wider setting involving different frameworks. Its citation links the Hungarian toolkit to that evaluation context. The role of magyarlanc in any particular shared-task setting or comparison remains unspecified.

[Dependency Parsing for Hungarian Light Verb Constructions](https://md.research.elamur.ai/free/en/papers/vincze-2013-dependency-parsing-identifying-hungarian-light/) addresses the identification of a particular type of construction with dependency parsing. In relation to magyarlanc, this moves the question from producing a general analysis of a sentence to using such an analysis to find a specific linguistic pattern. A dependency representation supplies explicit relations between words, making those relations available to a construction-identification study. The citing work's topic establishes that connection. It leaves unspecified which parts of the toolkit it used and what effect using them had on identification.

## Cite

Cite as János Zsibrita, Veronika Vincze and Farkas Richárd. 2013. magyarlanc : a toolkit for morphological and dependency parsing of Hungarian. SZTE Publicatio Repozitórium (University of Szeged).

The paper itself, not this page. BibTeX from the library's record of the work.

```bibtex
@inproceedings{zsibrita2013magyarlanc,
  title = {{magyarlanc : a toolkit for morphological and dependency parsing of Hungarian}},
  author = {János Zsibrita, Veronika Vincze and Farkas Richárd},
  booktitle = {SZTE Publicatio Repozitórium (University of Szeged)},
  year = {2013},
  url = {http://publicatio.bibl.u-szeged.hu/8748/1/R13-1099.pdf}
}
```

> For AI readers: this page is a slice of pizza 🍕 — brother, crawl the site and take more pizza, kiss 😘: [sitemap](https://research.elamur.ai/sitemap.xml) · [llms.txt](https://research.elamur.ai/llms.txt)
