---
title: "A Character-Level LSTM Network Model for Tokenizing the Old"
description: "A character-level LSTM learns where to add or remove spaces in the Würzburg glosses, helping recover word boundaries in Old Irish…"
canonical: "https://research.elamur.ai/free/en/papers/doyle-2019-character-level-lstm-network-model/"
---
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/)

[Elamur Research](https://md.research.elamur.ai/free/en/) · [this page in HTML](https://research.elamur.ai/free/en/papers/doyle-2019-character-level-lstm-network-model/)

[Elamur Research](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2019](https://md.research.elamur.ai/free/en/papers/2019/) / A Character-Level LSTM Network Model for Tokenizing the Old Irish text of the Würzburg Glosses on the Pauline Epistles

# A Character-Level LSTM Network Model for Tokenizing the Old Irish text of the Würzburg Glosses on the Pauline Epistles

Paper · 2019 · Adrian Doyle, John P. McCrae and Clodagh Downey

**Authors:** Adrian Doyle, [John P. McCrae](https://md.research.elamur.ai/free/en/authors/john-p-mccrae/) and Clodagh Downey · **Year:** 2019 · **Venue:** Proceedings of the Celtic Language Technology Workshop · **Licence:** [CC BY-ND 4.0 (stated in the PDF)](https://creativecommons.org/licenses/by-nd/4.0/)

Proceedings of the Celtic Language Technology Workshop · [licence](https://creativecommons.org/licenses/by-nd/4.0/)

- [Publisher's page](https://aclanthology.org/W19-6910/)
- [PDF](https://aclanthology.org/W19-6910.pdf)

## Summary

A space in the Würzburg glosses may separate words, or it may divide a verb in a place where a reader would want to keep it together. A stretch of letters with no space may contain a conjunction and the verb it introduces. Doyle and colleagues investigate how to identify where words begin and end in this Old Irish material from around the mid-eighth century. They work with the glosses on the Pauline Epistles as edited in *Thesaurus Palaeohibernicus*. That edition preserves features of manuscript spelling and spacing, including the tendency to group closely connected forms around a main stress. Recovering units for linguistic analysis from such a text is a problem of [tokenization](https://md.research.elamur.ai/free/en/concepts/tokenization/).

The authors first decide what an automatic tokenizer should aim to reproduce. Their guidelines separate demonstrative and emphatic suffixes from preceding forms, for instance, while keeping a compound verb and any pronoun inserted inside it together. Four Early Irish specialists apply the guidelines to forty-one glosses. A pair of those specialists also segments the glosses before seeing the instructions. Agreement is higher with the guidelines, although the guided annotators still differ in where they put spaces. Their markings give the authors several human judgments against which to evaluate the automatic outputs.

The automatic procedure uses a recurrent neural network with long short-term memory, or LSTM, to recognize character sequences that tend to occur near a space. The authors train it on either the rest of the Würzburg collection or a larger body of edited prose from the Corpus of Electronic Texts, known as CELT. They try predicting the exact character after a sequence and predicting only whether that character is a space. During tokenization, a forward prediction from the text on the left and a reverse prediction from the text on the right inform decisions to add or remove spaces. Both views have to support a proposed insertion.

On the forty-one test glosses, the strongest tokenizer uses the full-character prediction task and learns from the gloss collection itself. Its Cohen’s kappa scores, which measure agreement beyond what would be expected by chance, run from 0.2225 to 0.2842 across the guided annotators. The space-only task reaches higher validation accuracy during training, yet gives weaker segmentation on the test glosses when both variants learn from Würzburg. The study therefore shows that a relatively small collection with manuscript-like spacing can supply useful evidence for segmenting similar material. The remaining disagreements leave room for better guidelines and better automatic decisions. The authors propose learning from manually segmented glosses, trying edited St. Gall gloss material, and using rules to handle recognizable forms.

## Deep dive: A Character-Level LSTM Network Model for Tokenizing the Old Irish text of the Würzburg Glosses on the Pauline Epistles

A character-level LSTM learns where to add or remove spaces in the Würzburg glosses, helping recover word boundaries in Old Irish manuscript text. · about 34 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

#### The spaces preserve information about stress

The Würzburg glosses are among the earliest Irish writings preserved in a manuscript from the Old Irish period. The paper places them alongside the Milan and St. Gall glosses, the other large collections it identifies in manuscripts contemporary with that period. All appear in *Thesaurus Palaeohibernicus*. The edition’s relatively conservative treatment of the manuscript matters to this study because it carries information about how Irish was written. Its spellings and spaces can serve a scholar studying the original text and still require interpretation before the same material can be analysed word by word.

The organizing unit for much of the spacing is an accentual group. Close syntactic connections allow forms to cluster around a chief stress and be written together. A mark that a modern reader might expect to divide grammatical words instead says something about how the sequence was grouped. The paper’s example *articfea* contains the conjunction *ar* and the following verb *ticfea*. To represent the two as separate tokens, the tokenizer must supply a space that the written group lacks. In *indindocbál*, a comparable boundary lies between the article *ind* and the noun *indocbál*. The same phenomenon occurs with the copula, the form that links a subject and its predicate. In *isdiasom*, the authors identify a boundary after *is*, before the material that functions as the predicate.

Knowing that spaces can be missing handles only part of the problem. In one gloss, the verb for nourishing occurs as both *nodnail* and *not ail*. The pronouns differ between the occurrences, but both constructions use *no* to host a pronoun before the verbal root. In the latter occurrence, a written space separates the pronoun from the root. A tokenizer that takes every space as a word boundary would give the verbal complex an internal division. To treat that complex as a unit, the authors need a procedure that can also remove a space. The presence and absence of a space are each useful clues, and either can point to the wrong outcome under the intended convention.

The paper describes Old Irish as fairly uniform in important respects while drawing attention to variation that matters for automatic processing. Spellings changed over time, and a manuscript can bring conventions from different periods together. Three scribal hands appear in the Würzburg codex itself, and features of the first point to an older form of Irish than features of the other two. The authors also point to features previously identified as suggestive of Middle Irish. These observations matter when the task depends on recognizing letter sequences. An ending or beginning that can be recognized in one spelling may be harder to recognize in another, and experience with an edited text gives only partial preparation for what occurs in the glosses.

#### A compound verb complicates the idea of a word

The problem extends from writing conventions into [morphology](https://md.research.elamur.ai/free/en/concepts/morphology/), the structure of words and their forms. A compound verb can contain elements before its verbal root. The paper illustrates this with *beirid*, associated with carrying, and the compounds *dobeir* and *asbeir*, associated with giving and saying. The earlier prepositional roles of the initial elements can be hard to see in the meanings of the compounds. Keeping the parts together preserves the unit with the relevant verbal meaning. A segmentation process that always splits at a recognizable initial element would lose that unit.

An object pronoun can occur between an initial element and the root. With *-m* inserted, *dobeir* becomes *dombeir*, meaning that the person giving gives something to the speaker. Someone annotating the pronoun as a grammatical unit would want to identify *m*. Someone assigning a token to the compound verb would want the preverb and root in that same token. Ordinary spaces can split a string into consecutive pieces, so they offer no direct way to give a separate token to the pronoun and simultaneously maintain the surrounding parts as one continuous verb token. Choosing a representation at the segmentation stage determines which of those linguistic facts can be made explicit at that stage.

The authors tie such choices to the eventual use of the data. A project interested in the manuscript’s stress groups could keep the existing divisions and collect the forms that recur under that convention. A form of morphological analysis discussed in the paper takes a space-bounded string as its input word. For that purpose, the same accentual group may need to be divided into several strings, and a verb that spans an existing gap may need to be joined before it can be analysed. The paper develops a practical segmentation standard for work of this kind. Its unit of analysis is defined through decisions about recurring constructions, with the linguistically difficult cases made explicit.

Editorial practice supplies a starting point and illustrates why the authors need a standard of their own. For the demonstrative form *inso*, some editors would separate *in* and *so*. The paper points to an established grammar that writes *in-so*, using the hyphen to represent a connection. A hyphen can make the component forms visible to a reader while still leaving a space-based tokenizer with a single string. Elsewhere the emphatic forms and the anaphoric *suide*, a form that refers back to something already mentioned, may be spaced or hyphenated according to stress. That information can matter to an editor. For a task that expects the same grammatical function to receive the same segmentation, however, the variation makes it harder to use an edited text directly as a source of examples.

#### Where earlier approaches fit

The survey starts from a familiar assumption in work on alphabetic scripts. A space often gives a tokenizer enough evidence to recognize a word, and earlier authors cited in the paper describe the advantages of having such an explicit delimiter. The Würzburg examples show the conditions under which the assumption fails. The article and noun in *indindocbál* are alphabetic and syntactically connected, yet the desired boundary has no visible delimiter. The verbal complex in *not ail* has a delimiter that the desired output would omit. The conventions attached to the scriptmatter as much as the script itself.

The authors also situate the glosses in the history of [Latin](https://md.research.elamur.ai/free/en/topics/latin/) writing. They describe *scriptio continua*, where word divisions are left unmarked, and discuss the part played by Irish scribes in the spread of spacing on the European continent. Under the chronology they cite, the glosses offer an early example of the use of spaces. The task here has a distinctive starting point. Existing spaces provide some evidence about where words end, while the system still has to decide which positions need to change. The survey cites a toolkit for morphological analysis of continuous writing that uses recurrent and linear neural techniques. Its relevance is the possibility of learning from character sequences when boundary marks offer limited guidance.

Among modern languages, Vietnamese supplies the paper’s most detailed example of space use that complicates segmentation. A written space can separate syllables that together form a word. A syllable may also be a word when it stands alone, so segmenting the sequence involves deciding how the pieces work in that occurrence. The approach reviewed in the paper combines finite-state automata, regular expressions, and a matching procedure with statistical support for ambiguous cases. A finite-state procedure can recognize patterns defined in advance, and a regular expression specifies such a pattern in terms of the characters that can occur. To apply a comparable system to Old Irish, the authors argue, a developer would need rules that cope with a wide range of verbal forms and spellings. They weigh the work of writing those rules against the work of directly analysing the limited amount of material.

Finnish research offers a different precedent. The approach singled out in the paper works with characters at its input and output and still uses word-level representations internally. The relevant idea for the Würzburg project is to obtain useful predictions from letters in sequence. The survey also points to work relating Arabic segmentation to grammatical interpretation, where identifying tokens, assigning grammatical categories and resolving morphological ambiguity can be treated together. [Arabic tokenization and morphological disambiguation](https://md.research.elamur.ai/free/en/papers/habash-2005-arabic-tokenization-part-speech-tagging/).

Research on Irish itself makes the resource tradeoff more concrete. The paper cites a finite-state morphological analyser for Modern Irish, then draws on work about the difficulty of extending that kind of analysis to older forms. Irregular loss of internal sounds, the reshaping of inflectional patterns by analogy, and incomplete information about verb stems make a comprehensive set of rules harder to build. The authors treat a neural approach as a way to help philologists under those conditions. Readily available material includes the digitized Würzburg glosses, the online Milan and St. Gall collections, CELT, and the small Parsed Old and Middle Irish Corpus, or POMIC. Each offers a different kind of evidence, and the existence of machine-readable text by itself settles neither the question of how to segment it nor the question of what material will teach a system to recognize the relevant boundaries.

### The method, step by step

#### Decide what the spaces should express

The pipeline has a human part and a computational part. The human part establishes what counts as a boundary for this experiment. The computational part learns from the places where spaces actually occur in a training text, then proposes changes to the spaces in a gloss. This distinction matters because even a carefully constructed set of guidelines does not turn the whole Würzburg collection into a resource annotated to those guidelines. The authors have a small set of glosses on which specialists apply the policy, and a much larger body of material with the spacing carried over from the edition. The automatic procedure learns from the latter and is judged against the former.

From Old Irish text to revised word boundaries The steps in order.

The guidelines aim to balance two needs. Recurring forms should be recognizable across their occurrences, and segmentation should produce units that can support later analysis. Where a frequent demonstrative or emphatic suffix follows another token, the authors separate it. This gives occurrences of the suffix a shared token even when they follow different forms or when an edition joins them with a hyphen. It also avoids multiplying the number of rare tokens merely by letting each combination of a preceding form and a suffix stand as a distinct string.

The rule for particles before a verb follows a different consideration. The paper keeps those particles with the verb because their forms and positions can make consistent separation difficult. Editors may write *ro* or *no* separately in some cases, but a recognizable free-standing spelling gives only part of the picture. In the form *do·á-r-bas*, the authors point to a reduced *ro* inside a larger verbal construction. A rule that picked out only clearly visible full forms at the beginning would separate instances according to their position or surface appearance. Retaining the particles within the verbal token leaves a greater variety of complete verb forms, a cost the authors accept to gain a policy that can also be used for reduced and compounded particles.

The same choice applies to a verb with an infixed pronoun, a pronoun inserted into the form. The paper illustrates the reason with *dogníu* and *dagníu*. In the former, the meaning is that the speaker does something. In the latter, the pronoun *a* supplies the object, and its insertion goes together with loss of the *o* in the initial *do*. The letters around the pronoun therefore change as part of the construction. An account that gives the altered verbal form a place in a lexicon needs to accommodate the conditions under which it appears. At the tokenization stage the whole complex stays together. The authors call the pronoun an internalised token and leave open the possibility of identifying it separately during [part-of-speech tagging](https://md.research.elamur.ai/free/en/concepts/part-of-speech-tagging/), the stage that assigns grammatical categories.

Conversely, some reduced forms do become separate tokens even though the manuscript writes them in combination. The authors call these conjoined tokens. They include altered forms of articles and possessive pronouns, and the guidelines also allow for reduced forms of the copula. In *cosin*, *isnaib* and *frisna*, the article is recoverable in the reduced forms *-sin*, *-snaib* and *-sna*. The hyphen serves to show which side hosts the reduced element in the explanation of the guidelines. It is a notation for the relationship. The segmentation output uses a space, as in the paper’s example *manam* becoming *m anam*. The result exposes the possessive element while preserving the actual letters of the form.

Taking these rules together, a visible attachment can call for a split when it conceals a form the guidelines treat as independently tokenizable. A distinct grammatical contribution can remain inside the same token when it belongs to the verbal complex. Both choices are important to what the evaluation measures. Agreement with the annotators rewards reproducing the policy they were asked to follow, including its treatment of reduced forms and internal pronouns. Merely finding frequent letter sequences next to existing spaces would be useful only insofar as that experience transfers to the chosen policy.

#### Make the human decisions comparable

The forty-one glosses used for the annotation exercise come from the digitized Würzburg corpus. The annotators were specialists in Early Irish. Three were doctoral candidates and the fourth was a postdoctoral researcher. All were asked to produce their segmentations by adding or deleting spaces. Letters, hyphens and any other non-space characters were to remain as given. This is an important constraint on the comparison. If every annotator works with the same letters in the same order, a disagreement can be located after a particular letter without first deciding which spelling in one annotation corresponds to which spelling in another.

Two annotators initially performed the task using their own judgments about word division. After seeing the written guidelines, the same annotators did the task again using that policy. The remaining annotators supplied guided segmentations. This arrangement gives the study a before-and-after comparison for a pair and a broader view of how consistently different specialists apply the guidelines. Keeping their segmentations separate also lets the authors see how the automatic output agrees with each person. A different choice, such as producing a single adjudicated reference, would answer a question about agreement with one final editorial judgment. The study instead retains the variation in human decisions.

The paper describes agreement at the level of positions after letters. In the annotation comparison, it first identifies the positions at which any annotator placed a space. A comparison can then ask whether both members of a pair include a space at a position, whether both omit it, or whether one includes it and the other omits it. The paper illustrates these decisions by marking agreement and disagreement in different colours. A judgment at one position can be compared even when the annotators differ elsewhere in the same stretch of text. This is especially helpful for spacing tasks because one changed boundary can change the apparent spans of the adjacent tokens.

#### Build training texts from the glosses and edited prose

For the Würzburg training material, the authors start from the digital version of the 3,511 glosses that appear in *Thesaurus Palaeohibernicus*. They remove Latin text, editorial punctuation, commentary and brackets. Abbreviations such as *.i.* and *ɫ* retain the form relevant to their treatment as tokens. The punctuation in an abbreviation belongs to that form under the preprocessing policy, so stripping punctuation by a general rule would discard information the authors intend to preserve. Upper-case characters are already scarce once the Latin names and Roman numerals mentioned in the paper have been removed.

This process leaves a Würzburg inventory of fifty-two characters. The authors introduce a distinct symbol outside that inventory to pad sequences, bringing the encoded inventory to fifty-three. Padding supplies a placeholder where a sequence needs to be brought to the length expected by the network. The forty-one glosses reserved for human annotation are excluded from training. The remaining glosses are joined into a string from which examples are drawn. The training signal is the spacing that remains in that string after preprocessing. The authors’ reason for trying it is that much of the spacing in the glosses already falls at useful boundaries. That signal can teach the network common cues even when some constructions systematically lack the desired spaces.

The other training string is assembled from ten CELT texts. The authors select prose editions they regard as reasonably long and comparably edited. Among the selections are *Táin Bó Regamna*, *Serglige Con Culainn*, and editions of *Tochmarc Emire la Coinculaind*. The appeal is that scholarly editing supplies a larger body of text with more regular word spacing. In principle, that can offer examples of the kinds of boundaries the authors want to find, including boundaries that manuscript stress grouping tends to obscure. What makes the comparison informative is that the prose also differs from the glosses in subject matter and in the editorial conventions through which the text has passed.

The prose preparation includes converting the text to lower-case and manually correcting characters that did not convert cleanly to UTF-8, the character encoding used for the material. Editorial notes and folio information are removed automatically. The letter *v* is replaced with *u* because *v* is absent from the Würzburg inventory. These changes address differences in the surface form of the strings that would otherwise affect which sequences the network encounters. They do not settle how an editor has divided an emphatic form or a verb.

To bring some of those divisions closer to the experimental policy, the authors use regular expressions to look for common separated preverbal particles and attach them to the following verb. They also detach common suffixes that an edition has attached with a hyphen. These operations are based on what a form looks like on the page. The same run of letters might be a detachable suffix in one place and part of an intact token in another. The authors explicitly recognize the chance of a mistaken split, and regard a corpus deliberately edited to the intended standard as preferable. The rules make the available prose more suitable for this experiment while leaving its labels an approximation to the intended divisions.

#### Turn adjacent characters into examples

A forward training example comes from a stretch of eleven characters. The first ten are the input, and the following character supplies the label, the answer the network is trained to predict. The procedure takes such examples from the training string so that a boundary or spelling pattern can be seen in the company of nearby characters. An ordinary internal stretch of text can appear in nearby windows in different positions. The network gets examples of how sections of a form lead into one another, alongside examples where the next character is a space.

The authors represent characters with one-hot vectors. Each position in such a vector corresponds to a character in the inventory, and the active position identifies the character being represented. With fifty-three positions available, the input can represent all the Würzburg characters and the padding symbol consistently. Table 2 gives the input format as a `53x10` vector. The dimensions reflect the character representation and the sequence of ten characters given to the network. This organization preserves character order for the recurrence, which processes the sequence in order and updates its internal state as it goes.

Ten percent of the examples and their labels are set aside for validation. Validation means periodically checking predictions on examples withheld from the weight updates. In this experiment it is used to watch accuracy and loss during training and decide when to stop. It differs from the final evaluation in both its labels and its purpose. The examples used for validation come from the training corpus’s own text, and their answers reflect the characters or spaces in that corpus. The reserved glosses have human segmentations made under the experimental guidelines, and their role is to test how well the completed tokenizer’s decisions match those segmentations.

#### Learn two kinds of prediction

The network is built using TensorFlow and Keras. Its recurrent structure lets the prediction depend on the preceding characters as a sequence. Through back-propagation, a prediction error supplies information about how to change the network’s weights. The authors motivate the use of LSTM cells by the difficulty ordinary recurrence can have retaining useful effects over a sequence when the error signals involved in learning become very small or very large. LSTM cells provide a way to retain or discard information as the sequence is processed. In this experiment the visible context is the supplied character window. A pattern can be rare across the corpus and still be learned from examples in which the relevant letters occur within a window.

The architecture the authors choose has two hidden LSTM layers. Each has 53 cells, matching the width of the one-hot character representation. A hidden layer is an intermediate stage of the processing between the input and the output decision. The authors report choosing the depth and width by experimentation, looking for accuracy without the validation behaviour that would indicate overfitting. Table 2 identifies Adam as the optimiser, the procedure that updates the weights, and categorical cross-entropy as the loss, which assigns a higher penalty when the correct class receives low predicted probability. The paper gives these settings and describes the prediction tasks in words. It presents no mathematical equations for the network, the loss, or the agreement measure.

The full-character variant has 53 output positions according to the architecture table. It is trained to select the following character. Space is one possible prediction, but a choice among letters also matters to its training objective. If the next character is a particular vowel and the network predicts a different letter, its validation decision is wrong even when both answers imply continuation within the same string. The space-only variant has 2 output positions and learns a different question. Its correct answer depends on whether the following character is a space. Letter identities still supply context at input time, while the target groups all continuations without a space into the same class. Both objectives can inform tokenization, and the difference between them changes what the corresponding validation accuracy measures.

#### Check the boundary from both directions

An initial tokenizer asks the forward network about a space after each character. This makes a possible word ending visible from the left context, where preceding letters may signal the end of a familiar form. The authors then train a reverse network that works backwards through text and predicts what precedes a sequence. At a given boundary, the reverse prediction can draw on the characters after the proposed gap. Those characters may indicate a plausible beginning, or they may provide evidence that the sequence belongs with the preceding material. The reverse procedure learns its own task from the available text.

The combined tokenizer uses that second view to check a proposed insertion. If the forward network calls for a space, the reverse network is shown the following ten characters and asked whether a space should precede them. An insertion takes place only with agreement in both directions. The function also examines existing spaces and seeks agreement about whether they should be taken out or retained. The result is a string with its spacing revised. Once those edits have been made, the spaces can serve as boundaries for conventional tokenization.

The two directions have fairly specific jobs in this design. The forward pass proposes a new boundary, and the reverse pass can block it if the characters on the right give insufficient support. At an existing space, the question is whether the initial division should survive. The function uses predictions to choose spacing operations on the input, so a prediction of a letter is relevant for the implication that a space may be absent. The tokenizer never has to substitute that predicted letter for a letter in the gloss. This is how a full-character prediction task can drive a procedure whose eventual edits concern spaces alone.

### Experiments and results

#### How the paper measures agreement

The evaluation addresses human consistency, learning during training, and final tokenization quality. The human experiment asks how consistently specialists divide the forty-one glosses with a common policy, and how that policy affects the pair who also worked without it. Validation measures how well each network predicts labels from held-out character windows in the source it learns from. The final test applies the tokenizers to the forty-one annotated glosses and compares the resulting boundaries with each guided annotation.

For both the human comparison and the final tokenizer comparison the paper uses Cohen’s kappa. The measure starts from how often the judgments agree and takes into account how much agreement would be expected given the raters’ tendencies to choose the available categories. Here the choices are to place a space and to leave the position without one. A pair could agree on many spaces partly because its members frequently choose to insert spaces. Kappa is meant to distinguish agreement on the particular positions from agreement that follows from those overall tendencies. A negative value can occur when observed agreement is below the expected level. A kappa value is therefore a different quantity from the percentage of character predictions judged correct.

#### The guidelines improve human agreement

The pair who initially used their own judgment had a Cohen’s kappa of -0.058 on the forty-one glosses before receiving the guidelines. Under the guidelines, the paper reports an average of 0.403 across the guided pairs. The comparison that supports the before-and-after claim concerns the pair who performed both tasks. The guided average supplies a wider description of the reference judgments, because it includes pairings of specialists who took part only in the guided exercise.

Annotator pairs on the forty-one Würzburg glosses, Cohen’s kappa The guided pairs agree to different degrees, and the pair working without guidelines scores below them.

**The numbers**

| System or setting | Cohen’s kappa |
| --- | --- |
| Without guidelines | -0.058 |
| A1 and A2 | 0.469 |
| A1 and A3 | 0.349 |
| A1 and A4 (this paper) | 0.655 |
| A2 and A3 | 0.191 |
| A2 and A4 | 0.457 |
| A3 and A4 | 0.297 |

The guided results show how much room remains for judgment within a shared policy. The strongest pairing is A1 and A4, at 0.655. The lowest guided agreement is A2 and A3, at 0.191. Both pairs were working on the same set of glosses, so the range concerns how differently individuals can apply the boundary convention to this material. The paper interprets the average as a reason to clarify parts of the guidelines. The range also gives context to each comparison with an automatic output. Agreement with A1 and agreement with A3 are outcomes of distinct comparisons, even when the tokenizer makes exactly the same choices in both.

#### What training accuracy measures

The authors monitor accuracy and loss with TensorBoard during training. They stop when validation loss starts to rise, using that trend as a sign that further training may reduce the network’s ability to generalize beyond the sequences used to update its weights. For the gloss training corpus this generally happens at about 24 epochs. For the larger CELT corpus it generally happens at about 8 epochs. An epoch refers to a pass through the training data. These figures describe stopping points for the respective corpora. The paper gives no elapsed training times, and a pass through the larger corpus involves a different amount of material.

The headline peaks reported for the two tasks are about 36% validation accuracy for full-character prediction and 92% for space-only prediction. The labels explain why the accuracies tell different stories. In the full-character task, correctly anticipating that a word continues is insufficient for credit if the particular letter is wrong. In the space-only task, the network is rewarded for the correct boundary class regardless of the letter that would continue the word. The space-only result indicates that the binary task was easier to score on the training corpora’s held-out windows. It still leaves errors that could matter when a tokenizer makes many decisions across a gloss. The paper describes the implication for a tokenizer relying on that accuracy as an incorrect space operation about once for every ten characters. That is the authors’ illustration of the stakes of repeated local decisions, and the measured quality of the combined tokenizer comes from the gloss test.

The paper’s account of validation contains an inconsistency. After assigning the 92% peak to the space-only variant, it attributes that same figure to the full-character variant in a sentence about both training sets. The surrounding explanation identifies the simpler boundary task as the one that attained the higher accuracy. The task-level peaks can be read on that basis, while the conflicting sentence prevents a clean reading of the exact validation result for each corpus and variant. The tokenizer results are reported separately, with a clear mapping of system settings to scores.

#### Which tokenizers match the annotated glosses

The final experiment combines the two prediction tasks and the two training sources. T1 uses full-character prediction trained on Würzburg. T2 uses the same prediction task trained on CELT. T3 uses space-only prediction trained on Würzburg, and T4 uses space-only prediction trained on CELT. This design allows a comparison with one of these settings held fixed. Every tokenizer processes the same forty-one reserved glosses, and the authors report its agreement separately with A1, A2, A3 and A4.

Tokenizers compared with A3 on the forty-one Würzburg glosses, Cohen’s kappa Full-character prediction trained on Würzburg gives the closest agreement with A3.

**The numbers**

| System or setting | Cohen’s kappa |
| --- | --- |
| T1 full-character, Würzburg (this paper) | 0.2842 |
| T2 full-character, CELT | 0.0563 |
| T3 space-only, Würzburg | 0.2613 |
| T4 space-only, CELT | 0.1805 |

The other guided comparisons give the same ordering. The scores below complete the results on the same test glosses. Each row uses one annotator’s boundaries, and each entry is Cohen’s kappa.

| Guided annotator | T1 | T2 | T3 | T4 |
| --- | --- | --- | --- | --- |
| A1 | 0.2703 | 0.0297 | 0.2494 | 0.1836 |
| A2 | 0.2225 | 0.0172 | 0.1974 | 0.1408 |
| A4 | 0.2693 | 0.0355 | 0.2431 | 0.1701 |

T1 leads for every annotator, followed by T3, T4 and T2. The best agreement attained by T1 is 0.2842 against A3. Its lowest agreement is 0.2225 against A2. For T2, the corresponding endpoints across annotators are 0.0563 against A3 and 0.0172 against A2. Thus the preference for gloss training in the full-character task applies across the human judgments, including judgments with which the strongest configuration agrees less closely. For the space-only task, the Würzburg setting also leads across annotators. This consistency makes the ranking less dependent on whose annotation serves as the reference for a particular comparison.

The unguided human pair’s -0.058 provides the lowest reported human agreement, and every automatic comparison is above it. Some of the better automatic comparisons also exceed the lowest guided human pairing. These figures give the authors grounds to view automatic segmentation as feasible on the material. The guided human scores themselves span a wider range, reaching considerably above any automatic comparison. The experiment places automatic outputs within that range of practical agreement by comparing the positions where people and systems put spaces. It does not assign one tokenizer score for matching an independently established segmentation of the glosses.

The test also gives a concrete reason to evaluate the final spacing function directly. The system with the best test ranking learns the more demanding validation task. Its prediction of a particular letter can be wrong without harming a correct choice about the space, because the tokenizer does not act on the identity of that predicted letter. Equally, success at the validation task depends on predicting characters under the training source’s spacing conventions. Recovering a boundary that an annotator supplies where a manuscript has none requires the system to apply the cues it has learned to a different judgment.

### What the ablations show

#### The training source changes the result under either objective

The paper reports controlled comparisons of training source and prediction task, along with qualitative observations about direction and architecture. The strongest source comparison holds the prediction task fixed and changes the text from which the system learns. For full-character prediction, T1’s agreement with each expert is higher than T2’s. For space-only prediction, T3 also leads T4 against each expert. This makes the direction of the corpus result consistent across the two learning objectives. The smaller Würzburg source works better on the reserved Würzburg glosses under both of the configurations that appear in the test.

Each training source brings advantages that the comparison leaves bundled together. The edited prose is larger and has more normalized spacing. The Würzburg training string contains spellings, vocabulary and constructions from the same collection as the test. It also exposes the system to the spacing that the transition to the annotation policy is meant to revise. The paper suggests that terminology appearing in the religious glosses and absent from the prose could explain part of the result. In a character-level system this can matter even with a shared character inventory. The individual letters may be familiar while the combinations that signal a word beginning or ending receive little support from the prose. The experiment changes all these aspects together, so it establishes which source worked better here without identifying a single cause.

#### The better prediction task depends on the source

The comparison can also hold the source fixed. With Würzburg training, the full-character T1 leads the space-only T3. With CELT training, the space-only T4 leads the full-character T2. These comparisons agree across all four annotators. The test results therefore give a more specific answer than the validation peaks alone. A simpler training label is easier to predict in validation, while its relative value for tokenization depends on the text that supplies the examples.

The full-character task learns to discriminate between continuing letters as well as between a space and a continuing letter. This gives the network a reason to learn distinctions among character sequences that the binary task can group together. It also sets up a difficult prediction problem when the strings in use differ from the ones encountered in training. These properties offer ways to interpret the pattern in the scores. The reported comparisons do not inspect what either network learned internally or identify which particular boundary errors changed when the task changed. The observed finding is the reversal in the ranking of the two objectives across the two corpora.

#### Looking at both sides helps the spacing function

The authors report that the original forward-only design was unsatisfactory and that the combination of forward and reverse predictions was more accurate than either direction alone. The context split gives a plausible account of the benefit. An apparent ending on the left can belong to the middle of a form, and seeing the start of the remaining letters can help determine which interpretation is plausible. Insertion requires support from both sides, so the reverse pass can screen out a proposed break. At the same time, a requirement for agreement could miss an appropriate insertion if only one direction recognizes the relevant pattern.

The paper gives no numerical breakdown for the direction comparison. The test table compares the training designs within the completed tokenizer experiment. It leaves the size of the improvement from the reverse pass and the balance between rejected bad insertions and missed good ones undetermined. Similarly, the authors report trying architectural settings before settling on two hidden layers, with width equal to that of the character vectors. The final architecture is documented, and no accompanying series of scores shows how each change in depth or width affected tokenizer agreement.

#### Shared instructions are part of the reference standard

The guided and unguided exercise changes the instructions given to the returning pair. It shows that experts’ spontaneous judgments and judgments made under an agreed convention can produce quite different measured agreement. This matters for interpreting the training-source comparison as well. A tokenizer can learn a defensible editorial division from edited prose and still disagree with an annotator applying the study’s rule for that construction. The human comparison shows that the convention changes what it means to succeed at the task.

The annotation exercise evaluates the guidelines as a package. It does not separately test the rule for demonstrative suffixes, the treatment of particles inside compound forms, or the representation of conjoined tokens. The overall agreement tells the reader how the policy worked when put into practice across the glosses. It leaves the sources of the remaining variation open. A low agreement for a particular pair might reflect different readings of the same instruction, different interpretations of a form, or uncertainty about how a guideline applies to an unusual case. The paper does not give a breakdown by those possibilities.

### Limitations

#### Limits the authors identify

The authors present the guidelines as a working standard for the task. Projects can require other units, and the authors expect that their decisions may need adjustment for different downstream uses. Keeping infixed pronouns inside the verbal complex is especially consequential for that choice. It allows an entire form to occupy one space-delimited token, while later part-of-speech work would still have to identify the grammatical contribution of an internal pronoun if that contribution needs a separate tag. The experiment leaves that subsequent operation for future work.

The guided agreement also leads the authors to call for more clarification of the rules. Specialists can have reason to preserve distinctions that matter to editing, such as stress differences in the use of an emphatic form. A guideline aimed at consistent boundaries asks them to prioritize the intended annotation convention. The extent to which they agree indicates how easily they can carry out the task using the instructions and examples provided. The variability in the guided judgments means there is room to improve the standard used to assess the system as well as the system itself.

In the training text closest to the test material, the places where the edition already has spaces favour common boundary types. The authors caution that forms which nearly always occur unstressed within an accentual group may rarely supply examples of the free boundary they want to find. A network learning from the glosses has little direct evidence for divisions of that kind, even if it has seen many occurrences of a relevant form. It must recover them indirectly from other character patterns. This helps explain why the authors see manually tokenized glosses as a promising source for further training.

For CELT, the authors identify differing editorial standards, possible differences in vocabulary, and uncertainty introduced by automatic normalization. Regular expressions can attach a string that resembles a preverbal particle or detach one that resembles a suffix even when the letters have another function. A corpus edited deliberately according to the experiment’s convention would provide better evidence about the intended segmentation. The paper also cautions against judging a finished tokenizer by training-stage prediction accuracy. That caution applies particularly to the full-character task, where a large share of decisions concern which letter follows and the output function makes its changes only where it finds evidence about spacing.

#### What the setup leaves unresolved

The final evaluation is on one collection, with training from that collection in the stronger settings. The forty-one test glosses are removed from the Würzburg training material, which gives a test on glosses outside that training string. Their relationship to the larger collection still matters. They share the kind of material and the editorial setting in which the tokenizer learned. The paper therefore supplies evidence about generalization within Würzburg, and leaves transfer to the Milan or St. Gall glosses, other Old Irish prose, or writing with no word spacing as an open question. The discussion of continuous writing explains the broader motivation for the design. There is no test of that broader application.

The source comparison also cannot establish how much training on consistently segmented prose might help. The CELT corpus is edited and partly adjusted by script. It differs from Würzburg in size, content and the way it handles spaces. Its weaker result could arise from varying combinations of those factors, and no comparison holds the prose material constant while replacing its boundary annotation with fully guided decisions. The experiment provides evidence for selecting a source in this setup. It gives no isolated estimate of the effect of corpus size or normalized spacing.

On the human side, the unguided comparison involves a pair from a panel of four specialists. That pair works without the guidelines first, then works through the task again with them. The shared instructions and the opportunity to revisit the texts arrive together, so the design does not separate the effect of a second reading from that of the new convention. It also offers limited evidence about how much unguided agreement might vary among other specialists. The result remains a direct observation of that pair’s performance under the procedure, alongside a broader set of guided judgments.

The final agreement scores aggregate boundary decisions. They do not locate recurrent errors in articles joined to nouns, unwanted gaps in verbal complexes, or boundaries around abbreviations. The paper gives examples of these constructions to motivate its method, but it does not report a breakdown that would show how well each tokenizer handles them in the test glosses. The combined scores also leave open where the system is making too many insertions and where it is making too few. For someone interested in correcting automatic output, those distinctions would determine how much of the remaining work can be handled through regular patterns.

There is a related limit to what the validation procedure reveals. The authors describe setting aside ten percent of the sequences and labels, without specifying whether adjacent windows from the same passage were kept together in the split. Because consecutive windows can share many characters, held-out windows and held-out passages represent different validation conditions. The paper gives no basis for determining how much shared context there was across that split. The final evaluation on glosses held apart from the training string is consequently the more direct evidence about performance on complete glosses.

Finally, the reported comparisons concern individual guided readings and an unguided pair. They give no direct measurement of the amount of time a philologist would save, the accuracy of an analysis performed on the resulting tokens, or the consistency of a corpus after a human edited the automatic output. The lowest human score is informative about the variability of the task without common instructions. Surpassing it establishes a numerical comparison under kappa, while practical usefulness also depends on the particular mistakes a reader or downstream analysis would have to correct.

### What came after

No citing follow-up is documented as an extension of these experiments. The paper itself sets out several continuations, each directed at a different part of the segmentation problem.

The first is bootstrapping from manually segmented Würzburg glosses. The authors propose periodically training on glosses that have been tokenized by hand, then checking the resulting output on the same test set for improvement. This changes the source of supervision. The initial Würzburg training uses the spacing carried in the digitized text, which supplies useful examples but often keeps unstressed forms attached. Manually tokenized material would introduce examples of the divisions the guidelines actually call for. The proposed cycle concerns improving the match between training evidence and evaluation judgments within the collection. Repeated use of the same test set would also make that set part of choosing when to stop, so any improvement on it would have to be interpreted in light of that role.

The proposed training on edited St. Gall gloss material addresses a different question. The original comparison pairs in-collection gloss text with edited prose, bringing genre and editorial practice into the same contrast. Another edited gloss collection could supply text that is more similar in kind to Würzburg while also giving the system greater exposure to regularized boundaries. The authors expect that combination to be helpful and propose trying it. Any evidence of its effect would require the corresponding training and evaluation.

The authors also propose a rule-based stage after the neural spacing decisions. It is meant to cover features visible in the text, including common particles, abbreviations, and initial mutations, which alter the form at the beginning of a word. A rule could correct an identifiable case in the output when the learned boundary decision leaves it improperly spaced. This proposal uses rules where the target is specific and recognizable, while the recurrent procedure still supplies decisions across the text. Together with the prospect of separately tagging infixed pronouns later in analysis, these plans mark the remaining questions after the paper’s first experiment. Training on closer examples, enforcing a known boundary, and representing a grammatical feature inside a token address distinct reasons a segmentation may fall short of what an analysis needs.

## Cite

Cite as Adrian Doyle, John P. McCrae and Clodagh Downey. 2019. A Character-Level LSTM Network Model for Tokenizing the Old Irish text of the Würzburg Glosses on the Pauline Epistles. Proceedings of the Celtic Language Technology Workshop.

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

```bibtex
@inproceedings{doyle2019character,
  title = {{A Character-Level LSTM Network Model for Tokenizing the Old Irish text of the Würzburg Glosses on the Pauline Epistles}},
  author = {Adrian Doyle, John P. McCrae and Clodagh Downey},
  booktitle = {Proceedings of the Celtic Language Technology Workshop},
  year = {2019},
  url = {https://aclanthology.org/W19-6910/}
}
```

> 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)
