PhoNLP: A joint multi-task learning model for Vietnamese part-of-speech tagging, named entity recognition and dependency parsing
Paper · 2021 · Linh The Nguyen and Dat Quoc Nguyen
Summary
A sentence can be annotated in several ways. A grammatical tag tells us what kind of word we are looking at. An entity label tells us whether it belongs to a name, such as the name of an organization. A dependency link tells us which other word it is grammatically attached to. PhoNLP learns to produce these annotations for Vietnamese in a single system. The authors ask whether the tasks benefit from sharing what they learn about a sentence, and whether the system can produce all the annotations without carrying a separate copy of a large pretrained encoder for each task. Part-of-speech tagging · Named entity recognition · Dependency parsing
PhoNLP starts with PhoBERT, a pretrained Vietnamese encoder that represents each word in light of the surrounding sentence. A tagging layer turns those representations into probabilities over grammatical categories. The entity recognizer and parser each receive their own learned representation of those probabilities alongside the original word features. This gives them access to grammatical evidence even when the tagger is uncertain. The tasks have separate prediction mechanisms and are trained together, with a weighted objective that includes errors from all of them. PhoBERT
The authors also uncover an overlap in the benchmarks. The original grammatical tagging training set contains 90+% of the sentences in the validation and test material for entity recognition and parsing. That overlap matters when a system learns to assign grammatical tags to a sentence during training and then supplies those tags, or related features, when the same sentence is evaluated on another task. The authors redistribute the tagging data and remove duplicate tagging sentences. They report results for both the original arrangement and the revised one, so the comparison between joint and separate training can be read under either condition.
On the revised split, PhoNLP reaches 93.88% tagging accuracy on VLSP 2013 and 94.51% entity F1 on VLSP 2016. On the VnDT v1.1 parsing test set, it reaches 78.17% labeled and 84.95% unlabeled attachment. The corresponding results for the separately trained PhoBERT-based baseline are 93.68%, 93.69%, 77.89% and 84.78%. PhoNLP also leads on the reported metrics under the original split. The authors release the system as an open-source toolkit with command-line and Python interfaces. Its training and evaluation scripts are designed to work with other languages that have the necessary annotated data and a compatible pretrained encoder. The reported evaluations concern Vietnamese.
Deep dive: PhoNLP: A joint multi-task learning model for Vietnamese part-of-speech tagging, named entity recognition and dependency parsing
PhoNLP shares a Vietnamese text encoder across tagging, entity recognition and parsing, and tests the approach after correcting data leakage. · about 34 minutes to read
The problem and its context
Different questions about the same words
The annotations in PhoNLP answer different questions. A part-of-speech tag identifies a grammatical category for a word in its sentence. An entity annotation identifies a stretch of text that names something and specifies its type. A dependency analysis selects a grammatical head for each word and labels the relation between them. A head is the word on which another word depends. The different annotations can describe the same word without duplicating one another. The name of an organization can occupy a position in a grammatical phrase, and its dependency identifies how it participates in that phrase.
In the paper's example, the sentence describes someone working at VinAI. The annotation identifies VinAI as an organization, while the dependency structure connects it to the preceding word that expresses the location. The word for working is the root of the sentence's dependency tree. Each annotation picks out a different property. An entity label records the type of the name. A grammatical tag describes the word's category. The tree shows which words fit together and how the location connects to the action. An application that needs to extract the organization and understand its connection to the action can draw on both kinds of evidence.
The paper places these tasks in a Vietnamese research community that had developed benchmarks and applications through the national Vietnamese language and speech processing project and the VLSP workshops. The workshops had been running shared tasks since 2013. The authors point to work on tasks such as translation, sentiment analysis, relation extraction and question answering as reasons to make linguistic annotations easy to obtain. Their examples have a common thread. An application can benefit from knowing the kind of expression it has encountered or how that expression attaches to the rest of a sentence. PhoNLP evaluates the annotations themselves. It does not evaluate those applications. Question answering
Before PhoNLP, the public VnCoreNLP toolkit already brought these types of Vietnamese annotation together. It used traditional feature-based learning, meaning that its predictors learned from features supplied to them. The arrival of PhoBERT offered a different source of features. Its pretrained encoder could represent a word in context and then be adapted to one annotated task at a time. In this setting, fine-tuning means updating the pretrained encoder as part of training it to make a particular kind of prediction. The authors describe the earlier toolkit as the point of comparison for the benchmark setup and PhoBERT as the stronger starting point for their own experiments.
Why share a pretrained encoder?
A straightforward way to package the newer approach would be to train a PhoBERT-based tagger, a separate entity recognizer and a separate parser, then distribute the resulting predictors together. The authors say that publicly available fine-tuned BERT-based predictors for the full set of Vietnamese tasks were lacking at the time. They also identify a potential drawback of such a package. Each independently fine-tuned predictor would carry its own adapted encoder. Their storage argument compares the encoder copies that this arrangement would require with the shared encoder in PhoNLP. It motivates the architecture even before considering prediction quality. BERT
There is a second reason to share computation. The paper treats grammatical tags as features that can help with parsing and can also give the entity recognizer additional evidence. The parser has to choose among possible heads and relations. Information about grammatical categories may help it judge these candidates. The entity recognizer has to decide where a name begins, where it continues and which type it expresses. Grammatical information can supplement the evidence in the words themselves. These are reasons to test a shared system. They leave open whether the shared training helps each task and how much of any benefit comes from the tag signal.
The tasks can share information at different points. They can all learn from a common encoder, which changes the word representations available to every predictor. Tagging can also supply an explicit feature to the other tasks after the encoder has represented each word. PhoNLP does both. This distinction matters because a comparison between joint and separate training changes more than the number of encoder copies. It can also change what one task receives from another and how the training errors affect the components that produce those features.
The authors situate PhoNLP alongside earlier systems that learned grammatical tagging and dependency parsing together. Several of those used bidirectional recurrent encoders to create features from the words on both sides of a position. PhoNLP replaces that kind of encoder with a pretrained BERT-based one and adds an entity recognizer. It also adopts the idea of passing probabilities over grammatical categories through a learned embedding. This continues a line of work in which an earlier task supplies features to a later one. A Joint Many-Task Model
The paper also discusses the earlier BERT-based parsing system of Kondratyuk and Straka. In the authors' comparison, it shares the use of a BERT-based encoder, while PhoNLP explicitly passes a grammatical tag embedding into the parser. The difference helps locate the contribution. Pretrained contextual representations and joint training were part of the existing field. The question here is what happens when those pieces are combined with explicit grammatical features and a separate entity recognition layer for Vietnamese. Parsing Universal Dependencies Universally
Why the benchmark split matters
Separate annotations can make distinct datasets look independent even when they describe the same sentences. A corpus may contain a tag for each word, while another record of that sentence contains entity boundaries or grammatical links. These are distinct collections of labels, but they offer supervision on identical input. If the tagging version of a sentence is used for training and the parsing version for testing, the parser's evaluation can involve a sentence the tagger and encoder have already encountered in supervised training. The importance of that exposure depends on how the tasks are connected.
This is especially relevant when grammatical tags are inputs to another predictor. The system can be asked to parse a sentence whose dependency links it has never seen, yet still receive features from a tagger trained on that very sentence. In PhoNLP, training on the sentence for tagging may also affect the common encoder used by the other tasks. The paper contrasts this arrangement with an evaluation in which the relevant sentences are held out from tagging training as well.
The benchmark issue is therefore part of the research problem. The authors want to know whether sharing supervision across tasks helps on held-out examples. To make that comparison meaningful, they must distinguish learning from related training examples from gaining exposure to particular evaluation sentences through a different task. The revised tagging split is their way of addressing that distinction. It changes which sentences can shape the tagger before evaluation and, for the joint system, which sentences can shape the shared encoder through the tagging objective.
The method, step by step
From a sentence to grammatical evidence
PhoNLP begins with a sentence that is already divided into words. Its encoder creates a representation for each word using the surrounding text. A tagging layer then estimates which grammatical category fits each position. The system keeps the full set of estimated probabilities available to the two other tasks. A prediction can therefore convey that one tag is strongly preferred, or that several tags remain plausible.
The entity recognizer and parser each translate those probabilities into their own feature vector. They join that vector to the word's contextual representation and use the combined features for their respective prediction problems. The entity recognizer judges entire label sequences. The parser scores possible connections between words, builds a tree and supplies a relation for each connection. The two branches receive information from the same tagger, but neither requires the other branch's predictions.
How PhoNLP annotates a word-segmented sentence
The steps in order.
The distinction between an input word and an encoder unit is important here. The labels in the task data belong to words. PhoBERT processes sub-word units, which means a word can occupy more than one position in the encoder's input. PhoNLP needs a rule for mapping those positions back to the annotated words. It uses the first sub-word of each word as the position to read. The word-level predictors then operate on a sequence aligned with the original word boundaries. Subword tokenization
Encoding the words
The encoder is PhoBERT base. Its sub-word segmentation uses byte pair encoding, or BPE. In PhoNLP, the sub-word's position determines which output vector is retained, while PhoBERT supplies the contextual information in that vector. The first sub-word is therefore an alignment choice. The selected representation is still obtained by encoding the sentence, so the features available to the downstream layers can depend on the surrounding input. Byte pair encoding for subword units
The paper expresses the word-level encoding as follows.
eᵢ = PhoBERT_base(w₁:ₙ, i)
Here, w₁:ₙ denotes the sequence of input words from the first position through position n, the length of the sentence in words. The symbol i identifies a word position, and eᵢ is the contextual feature vector for the word at that position. PhoBERT_base is the base version of the encoder. Its output for position i is the representation at that word's first sub-word after the sentence has been encoded.
A contextual feature vector is a list of learned numerical features. The same written word can receive different vectors in different settings because the encoder is applied to the sentence containing it. This lets a task predictor use evidence from the word and its context together. PhoNLP reuses that vector in all its annotation branches. The tagging layer reads it directly, and the other branches retain it when they add grammatical information. The annotation decisions thus remain grounded in the contextual features even when the tagger's distribution is uncertain.
Predicting the grammatical tags
The authors append a linear prediction layer to the encoder for part-of-speech tagging. At each word position, this layer produces a score for every tag in the inventory. A softmax converts the scores into a probability distribution. The distribution represents the layer's relative preference over the tags. It supplies both the information needed for the tagging prediction and the input from which the other branches obtain their grammatical features.
pᵢ = softmax(FFNN_POS(eᵢ))
The vector eᵢ is the encoder representation at word position i. FFNN_POS is the feed-forward prediction layer for part-of-speech tags, with an output slot for every tag. softmax maps the scores in those slots to normalized probabilities. Its result, pᵢ, contains the probability assigned to each possible tag for that word.
During training, the tagging objective uses cross-entropy, which penalizes assigning low probability to the annotated tag. That objective acts on the full probability vector. Retaining the vector is useful even though the final tag annotation names a category. Two words can receive the same most likely tag while having different distributions over alternatives. The downstream branches can receive different features for those words because the conversion uses the entire distribution.
This is the meaning of a soft tag embedding in the paper. A tag embedding is a vector of learned features associated with a grammatical label. A soft embedding uses the probabilities as weights on the features for the available labels. When the distribution is concentrated, the result emphasizes the features associated with the favored tag. When probability is spread across candidates, their features contribute to the result. The entity recognizer and the parser each learn their own mapping from these probabilities.
Recognizing names in a sentence
The NER branch builds its grammatical feature by applying a learned matrix to the probability vector. Each column of the matrix corresponds to a tag. Matrix multiplication gives a weighted combination of the columns, with weights taken from the tagger's probabilities for the current word.
tᵢ⁽¹⁾ = W⁽¹⁾pᵢ
The result tᵢ⁽¹⁾ is the soft grammatical feature for word position i in the entity recognition branch. W⁽¹⁾ is that branch's learned matrix of tag features. The superscript (1) identifies the matrix and feature used for entity recognition. The vector pᵢ contains the tag probabilities. The notation W⁽¹⁾pᵢ denotes multiplication of the matrix by that vector.
PhoNLP attaches the soft feature to the contextual representation by concatenation, which means placing the entries of one vector after the entries of the other. This keeps both sources of information available to the recognition layer. The operation preserves the contextual features as a distinct part of the input and gives the recognizer additional coordinates through which to use grammatical evidence.
vᵢ = eᵢ ◦ tᵢ⁽¹⁾
The vector vᵢ is the resulting input to the entity recognizer for word position i. eᵢ is the encoder's contextual word vector, and tᵢ⁽¹⁾ is the soft grammatical feature prepared for entity recognition. The operator ◦ means concatenation.
The recognizer uses a feed-forward layer to score entity labels at each word. Its inventory uses BIO labels. A beginning label marks the start of a mention, an inside label marks a continuation and an outside label marks a word outside an entity. Beginning and inside labels can carry an entity type. The paper's sample output assigns B-ORG to VinAI, marking the beginning of an organization mention. The surrounding words in the example are marked O.
hᵢ = FFNN_NER(vᵢ)
Here, vᵢ is the combined input at word position i. FFNN_NER is the feed-forward layer for entity recognition, with an output slot for each BIO-based label in the inventory. hᵢ is the resulting vector of label scores for that word.
The local scores feed a linear-chain conditional random field, or CRF. In a linear chain, each label is considered alongside its neighbors in sentence order. The CRF can score a proposed sequence using both the evidence for individual labels and the way consecutive labels fit together. For example, the evidence that a word continues an organization name makes different sense after the start of an organization mention than it does in isolation. Giving the recognizer a sequence score lets it choose labels with these interactions in view.
The paper describes a cross-entropy objective for the NER branch during training. Inference uses the Viterbi algorithm to find the highest-scoring label sequence under the chain. The design separates the local evidence from the final output. Each hᵢ says how the recognizer scores labels at a particular word. The CRF and its decoder use those vectors together to choose the sentence's annotations.
Building and labeling the dependency tree
Parsing has a related starting point and a different output structure. It needs to find the head of each word, then identify the relation between the head and its dependent. The grammatical evidence enters through a soft embedding like the one in the entity branch. The parser learns a separate matrix, which gives it the freedom to use different features of the same probability distribution.
tᵢ⁽²⁾ = W⁽²⁾pᵢ
The vector tᵢ⁽²⁾ is the parser's soft grammatical feature at word position i. W⁽²⁾ is the parser's learned matrix of tag features, and pᵢ is the shared tagger's probability vector for that word. The superscript (2) distinguishes the parser's matrix and feature from their entity recognition counterparts. Multiplication combines the parser's tag features according to the probabilities.
zᵢ = eᵢ ◦ tᵢ⁽²⁾
The vector zᵢ is the parser input for word position i. It joins eᵢ, the contextual word representation, to tᵢ⁽²⁾, the parser's soft grammatical feature. The operator ◦ denotes concatenation.
A word participates in potential dependencies in two roles. It can be evaluated as a possible head for other words or as a dependent looking for a head. There are also distinct decisions about whether a link belongs in the tree and which label the link should carry. The design follows the use of separate representations for these roles and decisions in deep biaffine parsing. Feed-forward projections let the parser emphasize different aspects of the same input vector for each purpose. Deep Biaffine Attention for Neural Dependency Parsing
hᵢ⁽ᴬ⁻ᴴ⁾ = FFNN_Arc-Head(zᵢ)
zᵢ is the combined parser input at word position i. FFNN_Arc-Head is the feed-forward projection used when scoring that word as a possible head of an arc. An arc is a directed dependency link. hᵢ⁽ᴬ⁻ᴴ⁾ denotes the resulting representation, with A marking arc selection and H marking the head role.
hᵢ⁽ᴬ⁻ᴰ⁾ = FFNN_Arc-Dep(zᵢ)
FFNN_Arc-Dep is the projection used when the word is considered as the dependent in arc selection. It takes zᵢ, the same combined parser input for position i, and yields hᵢ⁽ᴬ⁻ᴰ⁾. In the superscript, A again refers to arc selection and D refers to the dependent role.
hᵢ⁽ᴸ⁻ᴴ⁾ = FFNN_Label-Head(zᵢ)
FFNN_Label-Head projects the parser input zᵢ into the representation hᵢ⁽ᴸ⁻ᴴ⁾ at word position i. The L refers to relation labeling and H to the head role. This vector is used when scoring relation labels for a link whose head is that word.
hᵢ⁽ᴸ⁻ᴰ⁾ = FFNN_Label-Dep(zᵢ)
FFNN_Label-Dep is the relation-label projection for the dependent role. Its input zᵢ is the combined vector at position i, and its output is hᵢ⁽ᴸ⁻ᴰ⁾. The superscript pairs L for relation labeling with D for the dependent.
The arc classifier compares a candidate head's arc representation with a candidate dependent's arc representation. A biaffine classifier can learn which features of the two vectors are informative in combination as well as features that contribute on either side. The variant used for arc scoring also takes into account how far apart the words are and which comes first. This gives the parser direct evidence about position alongside the learned features. For each word, it produces a distribution over possible heads.
These distributions describe local preferences. A valid dependency tree requires the preferences to fit together across the sentence. Choosing the most preferred head independently at every word could, for example, make words point to one another in a cycle. At inference, PhoNLP uses the Chu–Liu/Edmonds algorithm to select a maximum spanning tree from the scored arcs. This imposes a sentence-wide structure on the attachment decisions. The relation classifier then uses the separate label projections of the selected heads and dependents to assign dependency labels.
Parsing training uses the annotated arcs and their labels. The loss combines cross-entropy for choosing the head and cross-entropy for predicting the relation. A parser can identify the correct head and still assign the wrong label, so the two losses supervise different parts of the output. The evaluation metrics preserve this distinction. Unlabeled attachment checks the link, while labeled attachment also checks the relation on that link.
Sharing the training objective
Each task has training examples with its own target annotations. PhoNLP combines the losses from the tasks while updating the shared architecture. Grammatical tagging supplies direct supervision for the predicted tag distribution. Entity and parsing supervision can also influence the features they receive, because their input embeddings are computed by multiplying learned matrices by those probabilities. These operations give a differentiable path back through the tagger. The shared encoder also receives supervision through the contextual word features used directly in the task branches.
L = λ₁ L_POS + λ₂ L_NER + (1 − λ₁ − λ₂)L_DEP
L is the total training loss. L_POS is the cross-entropy loss for grammatical tags, L_NER is the entity recognition loss, and L_DEP is the combined loss for dependency heads and relations. The weights λ₁ and λ₂ control the tagging and entity terms, respectively. The coefficient (1 − λ₁ − λ₂) is the remaining weight assigned to parsing. The 1 denotes the whole weight available, − subtracts the stated shares, and + adds the resulting weighted loss terms.
The weights determine how strongly the losses enter this objective. They do not specify the size of the eventual change in any task's score. The losses come from different prediction problems, and the system's response to their combination depends on the data and learned parameters. The authors therefore select the weights by searching over candidate settings and measuring validation performance.
The training sets are unequal in size. In the revised setup, the largest is the grammatical tagging set, with 23,906 sentences. For each epoch, the authors repeatedly sample from the smaller entity and parsing training sets to make up the shortfall. An epoch is a cycle of training under this sampling schedule. Resampling gives the smaller corpora repeated opportunities to contribute supervision without treating their annotations as if they were available for every tagging sentence.
The implementation uses PyTorch and obtains its PhoBERT encoder from the Transformers library. The biaffine implementation comes from work by Qi and colleagues. Both tag matrices have 100 rows, yielding 100-dimensional soft embeddings. Each of the feed-forward projections for arc and label roles has a 400-dimensional output. These are different choices about capacity. The tag matrices define the additional grammatical features attached to each word, while the parser projections define the vectors that enter the arc and label classifiers. PyTorch · Transformers
Training uses a fixed batch size of 32 and runs for 40 epochs. The authors tune the initial AdamW learning rate and the task weights with a grid search, which compares a set of candidate settings. They report selecting an initial learning rate of 1e-5, with λ₁ set to 0.4 and λ₂ set to 0.2. The learning rate controls the scale of updates made by the optimizer. The task weights control how the supervised objectives enter the combined loss. AdamW and decoupled weight decay
After each epoch, the authors average tagging accuracy, entity F1 and labeled attachment on their respective validation sets. Those measures collectively determine which saved version of the system, or checkpoint, goes to the test sets. This is a different combination from the weighted loss used to update the parameters. The loss determines the training signal, while the validation average determines the chosen checkpoint. A gain on one validation task can contribute to the checkpoint choice even if another task would favor a different epoch. The reported test scores are averages over 5 runs with different random seeds.
Experiments and results
The benchmarks and their overlap
The paper follows the broad Vietnamese evaluation setup used for VnCoreNLP. It uses VLSP 2013 for grammatical tagging and VLSP 2016 for named entities. For parsing it uses VnDT v1.1, a Vietnamese dependency treebank converted from a constituent treebank. A treebank is a corpus with annotated syntactic structure. Constituent structure groups words into phrases, while dependency structure represents relations between words. VnDT provides the head and relation annotations needed to train and test the parser. Treebanks
The split sizes are counts of sentences. Before the correction, VLSP 2013 had 27,000 training, 870 validation and 2120 test sentences. The revised tagging split has 23,906 training, 2009 validation and 3481 test sentences. VLSP 2016 has 14,861 training, 2000 validation and 2831 test sentences. VnDT v1.1 has 8977 training, 200 validation and 1020 test sentences. The changes in the paper's comparison concern the tagging dataset. Its entity and dependency evaluations retain their own splits.
The authors find that every sentence from the entity dataset and the dependency treebank occurs in the tagging corpus. More importantly, the original tagging training split contains 90+% of the validation and test sentences for the other tasks. This is more specific than saying that the datasets were drawn from similar text. It means that almost all of the held-out examples for those evaluations already appear as input sentences with supervised grammatical tags in the original training arrangement.
Grammatical labels and dependency links are different targets. Nevertheless, training a tagger on an evaluation sentence changes the condition under which the parser is tested. In the separately trained parsing approach, the parser receives embeddings of grammatical tags produced by the separately trained tagger. Those tags can be produced for sentences the tagger has already seen with their correct tags during training. In PhoNLP, the predictions in both downstream branches can also depend on a common encoder trained on those sentences through tagging. The paper treats this exposure as leakage across tasks.
To address it, the authors build a new tagging split around the pooled validation and test sentences from entity recognition and parsing. The relevant sentences are held out of tagging training and appear on the validation and test side of the new tagging split. This description concerns the combined held-out material. It does not require interpreting the new tagging validation set as a sentence-for-sentence copy of either other task's validation set. The authors also remove duplicates from the tagging data. They report 594 duplicated sentences there and report finding no sentence duplication in the union of the entity and parsing sentence collections.
Changing both the split and duplicate handling changes the tagging benchmark itself. In parsing, the evaluation set stays in place, but the sources of training exposure change. The two conditions therefore serve different purposes. The original condition connects the results to the earlier setup. The revised condition tests whether joint training still helps when the targeted overlap has been removed from tagging training.
The baseline and the scoring rules
The main baseline uses the same PhoBERT base starting point and trains predictors separately for the tasks. For grammatical tagging, a linear prediction layer sits above the encoder. For NER, a CRF prediction layer sits above its own encoder. In separate parsing, the tagger first generates predicted tags. Embeddings of those tags are concatenated with the parser's contextual word vectors and passed into biaffine parsing classifiers. This baseline already uses grammatical input in parsing. The comparison is between separate and joint approaches that both have access to useful pretrained features and that both use grammatical information for parsing.
The paper describes comparable hyper-parameter tuning and checkpoint selection strategies for its single-task approach and PhoNLP. Some scores in the original setting come from the earlier PhoBERT paper. The authors explicitly mark the source of those scores in their table. The single-task results for the revised setting provide a comparison with PhoBERT when the tagging split and duplicate handling have been corrected. The older VnCoreNLP results give historical context, but the main numerical comparison in this paper is with the separately trained PhoBERT-based baseline.
Grammatical tagging is scored by accuracy, the share of evaluated word tags that match the annotations. For entity recognition the paper uses F1, which combines precision and recall. Precision concerns how much of the system's identified entity material is correct. Recall concerns how much of the annotated entity material the system recovers. F1 summarizes both, so the reported score is a different measure from accuracy over individual words.
Dependency parsing uses labeled attachment score, or LAS, and unlabeled attachment score, or UAS. Both ask whether the parser has selected the correct head. LAS also requires the correct relation label. A predicted arc with the right endpoints but the wrong relation can satisfy the unlabeled metric without satisfying the labeled one. The metrics therefore show performance under different criteria. The paper reports the scores for all the tasks as percentages.
Results after correcting the split
On the revised VLSP 2013 tagging test, the independently fine-tuned system reaches 93.68% accuracy and PhoNLP reaches 93.88%. The corrected test differs from the original tagging test in which sentences it covers. The direct comparison is between the systems on this revised test. It shows an advantage for the jointly trained approach under the data arrangement intended to avoid leakage across tasks.
On the VLSP 2016 entity test, the separate recognizer reaches 93.69% F1. PhoNLP reaches 94.51% F1 with the revised tagging setup. Both systems use a CRF for recognizing sequences of entity labels. PhoNLP also uses a shared encoder and a dedicated feature derived from the tag distribution. The result compares those complete approaches on the same entity test set.
Named entity recognition on the VLSP 2016 test set after the tagging re-split
PhoNLP achieves higher entity F1 than the separately trained recognizer.
The numbers
| System or setting | F1 % |
|---|---|
| Single-task PhoBERT | 93.69 |
| PhoNLP (this paper) | 94.51 |
On the VnDT v1.1 test set, the separate parser achieves 77.89% LAS and 84.78% UAS in the revised setting. PhoNLP achieves 78.17% LAS and 84.95% UAS. The direction agrees across both criteria. More of PhoNLP's head selections match the annotations under UAS, and more of its head-and-relation predictions match under LAS. Because the separately trained parser already receives grammatical tags, the advantage is evidence for the joint system as implemented. It does not by itself distinguish the contributions of sharing the encoder, sharing supervision through training, and passing a soft tag feature.
Labeled attachment on the VnDT v1.1 test set after the tagging re-split
PhoNLP obtains the higher labeled attachment score after the overlap correction.
The numbers
| System or setting | LAS % |
|---|---|
| Single-task PhoBERT | 77.89 |
| PhoNLP (this paper) | 78.17 |
The revised setting supports the main comparison on all the reported measures. It matters most as an answer to a specific alternative explanation. If the joint approach had led only in the original setup, its advantage could have depended on giving the shared system supervised tagging access to evaluation sentences from the other tasks. The lead persists after the tagging data are changed to remove that exposure. This comparison leaves open how the joint system would perform on independently collected corpora or on inputs from other domains.
Results with the original tagging split
With the original setup, tagging accuracy on the VLSP 2013 test is 96.7% for the separate PhoBERT tagger and 96.76% for PhoNLP. The single-task value comes from the earlier PhoBERT work. Both scores exceed the corresponding tagging accuracy on the revised test. Because the test sentences, training membership and duplicate handling change together, the accuracy levels across setups cannot be interpreted as scores on a fixed test with one variable altered.
On the VLSP 2016 entity test, the separate recognizer reaches 93.69% F1 in the original arrangement, and PhoNLP reaches 94.41%. The separate recognizer uses its own NER training and does not draw on tags learned from VLSP 2013. The paper therefore reports the same baseline F1 in both settings. PhoNLP's entity score is slightly higher with the revised tagging split than with the original one. This is a case where removing the targeted overlap does not accompany a decrease in the reported test score.
For the VnDT v1.1 test under the original arrangement, the separate parser reaches 78.77% LAS and 85.22% UAS. These scores are also taken from the earlier PhoBERT work. PhoNLP reaches 79.11% LAS and 85.47% UAS. Both systems have higher attachment scores in this condition than in the revised one. On the parser's fixed test, the comparison shows that results depend on how the tagger's training data are arranged. The paper's correction changes more than the presence of particular repeated evaluation sentences, so the comparison does not measure a pure effect of leakage alone.
Unlabeled attachment on the VnDT v1.1 test set with the original tagging split
PhoNLP also leads in unlabeled attachment under the original training arrangement.
The numbers
| System or setting | UAS % |
|---|---|
| Single-task PhoBERT | 85.22 |
| PhoNLP (this paper) | 85.47 |
The authors describe the joint results as state of the art for these Vietnamese tasks. The table shows how that claim is grounded in the paper's comparison. PhoNLP exceeds the reported strong PhoBERT-based baseline across the tasks under both arrangements. The older published parsing and tagging results were obtained under the original arrangement. For a reader interested in performance after the targeted leakage correction, the scores under the revised split are the appropriate comparison within the paper.
Running the toolkit
The authors publish PhoNLP under the Apache License 2.0 and demonstrate corpus annotation through a command-line interface and a Python interface. Both expose the annotation tasks through one toolkit. The sample output lines up the word position and form with the grammatical tag, entity label, head position and relation. For the sentence about working at VinAI, that layout makes it possible to see the organization label and the grammatical attachment on the same row. It shows what sharing an input sentence and a word alignment means for someone reading the output.
The speed test measures throughput while running all the annotation tasks. On the reported Intel Core i5 8265U CPU at 1.6GHz with 8GB of memory, the toolkit processes 15 sentences per second. On the reported NVIDIA RTX 2080Ti GPU, it processes 129 sentences per second. The test uses sentences averaging 23 word tokens and an inference batch size of 8. The size of these batches is distinct from the batch size used during training. These are measurements for the specified machines and input conditions. The paper does not provide a matching speed comparison against running the separately trained predictors.
What the ablations show
Removing the parser's grammatical feature
The paper describes a preliminary comparison in which the parser is deprived of the soft grammatical tag embeddings. The authors report that parsing performance decreases. They give no scores for that comparison and do not specify a magnitude for the decline. The observation supports the claim that the explicit grammatical input can help the parser in PhoNLP. The shared contextual representation already contains features learned for the tasks. The preliminary result suggests that giving the parser direct access to the tag distribution adds information it can use.
This is narrower evidence than the comparison with the separately trained baseline. The baseline parser uses predicted grammatical tags as inputs, while the removed-feature version drops the explicit grammatical input to PhoNLP's parser. The preliminary comparison consequently addresses the value of including that feature in the joint parser. It does not compare using tag probabilities with using a single predicted tag under otherwise matched conditions. It also does not show whether dedicating separate embedding matrices to entity recognition and parsing is better than sharing one matrix.
There is no corresponding reported removal of the grammatical input to the NER branch. The entity result is compatible with benefits from the soft feature, a shared encoder trained with additional supervision, or an interaction between the two. A CRF remains present in both the joint and separate recognizers, so the results do not estimate what the CRF contributes by itself. The paper describes the moving parts of the recognizer precisely enough to see these distinctions, but the comparisons reported for NER concern the full systems.
Separate training versus joint training
The baseline comparison holds the pretrained starting point constant and gives each task a predictor suited to its output. Tagging is handled by a linear layer, the recognizer uses a CRF, and the parsers use biaffine scoring. This makes the baseline more informative than a comparison with a system that lacks contextual features or that treats entity recognition as independent word decisions. The question it answers is whether PhoNLP's combined training and feature sharing improve on strong separate training.
Inside that comparison, several factors change. The separate predictors adapt their encoders to their own objectives, while PhoNLP updates a common encoder. The parser in the baseline consumes embeddings of predicted tags, while in PhoNLP it consumes a learned transform of the probability distribution. The baseline NER branch receives contextual word features without the tag-derived input used in PhoNLP. The joint losses can also influence the components that supply shared features. A higher score for PhoNLP therefore establishes an advantage for the design as a whole on these benchmarks. The preliminary parser comparison is the only reported component removal that directly supports one part of the mechanism.
The consistent direction of the main results is still informative. A weighted joint objective could favor one task while reducing performance on another. In the paper's comparison, the joint checkpoint strategy yields higher tagging accuracy, entity F1 and both attachment metrics under either split. That observation describes the means reported for the chosen training and selection procedure. The paper does not show whether each run improves every task or whether the ranking is stable across other weights or checkpoint rules.
Comparing the original and revised data arrangements
The original and revised setups furnish a check on the role of training exposure. The joint system remains ahead of the separately trained baseline after the tagging split changes. This indicates that the lead is not confined to the original overlapping setup. The unchanged NER baseline also clarifies which scores can be affected by the revised tagging data. Its entity training and evaluation are unchanged, while the joint NER branch can be affected because it shares the encoder and uses tag-derived features.
The parsing results show lower attachment scores for both systems after the change. This is compatible with the original arrangement making parsing easier through prior supervised exposure to the sentences in the tagger. It is also compatible with the revised tagger learning from a different distribution of training material. The paper changes overlap, set membership and duplication together. The aggregate scores cannot assign an amount of the change to each cause.
The tagging results need a different reading because their test set also changes. The original and revised accuracies answer questions about different collections of test sentences. The entity test remains fixed, and the joint entity score rises under the revision. These patterns make it important to keep the comparisons at the level of each task and its data. The revised experiment tests the joint design under a better-separated arrangement, while the preliminary removal addresses one architectural feature. The paper offers no quantitative breakdown of the losses, sampling schedule, position features or decoding choices.
Limitations
The scope stated by the authors
The demonstrated results are for Vietnamese. The authors explain that the training and evaluation scripts can be used with other languages given a compatible pretrained BERT-based encoder and annotated corpora for each task. The statement concerns the requirements for using the scripts. In the conclusion, they describe applying PhoNLP to other languages as future work. The paper provides no cross-language tests of whether joint training will help or whether the same weighting and sampling choices will work.
The authors present storage as a practical reason to share the encoder. A joint toolkit can use a single adapted encoder for the annotations demonstrated in the paper. The argument is architectural. The experiments give throughput measurements under specified conditions, but the paper provides no measurement of total storage for the joint toolkit against a package of separately fine-tuned systems. The classifier parameters and any other package contents would matter in such a comparison. Likewise, the timed example establishes the throughput of PhoNLP on the tested input and hardware. It does not establish relative latency or memory use.
The paper also identifies a boundary around its comparison with earlier Vietnamese results. The older PhoBERT and VnCoreNLP tagging and parsing scores used the overlapping arrangement. The authors supply revised comparisons for their PhoBERT-based baseline and PhoNLP. This lets a reader evaluate those systems within the corrected setup. It does not provide revised results for every earlier system or establish how the full historical ranking would look if all of them were evaluated with the same held-out sentences and deduplication.
Limits of the evaluation and data correction
The reported correction addresses the overlap the authors discovered between the tagging training set and the held-out entity and parsing material. This makes the cross-task evaluation more credible for those sentences. The paper does not trace the same sentences through every earlier stage of data collection, or through PhoBERT's pretraining. No conclusion about such exposure follows from this change to the supervised tagging split. The supported claim is that the specific path the authors identified has been addressed in the revised experiment.
The tagging test after the correction also has a different relationship to the other tasks. Its held-out sentences are drawn from the pooled entity and parsing validation and test material. That is useful for avoiding the reported leakage. It can also give the revised tagging test a different composition from the original one. Since the study changes sentence membership and removes duplicates together, its results cannot tell how much the composition of the test, the change in training examples or the removed duplicates contribute to the shift in tagging accuracy.
The experiments concern the chosen benchmarks and their overall metrics. The paper shows a labeled example sentence but provides no breakdown of errors by word category, entity type or relation label. The aggregate results cannot tell whether gains occur across many categories or are concentrated in a few. They also cannot show which types of sentences benefit from soft grammatical information, when the tagger misleads another branch, or how the results would change if the input differed substantially from the benchmark texts.
PhoNLP starts from words that are already segmented. Its use of BPE and the first sub-word establishes an alignment between encoder representations and those words. It does not evaluate recovery of word boundaries from raw text. If the supplied boundaries are wrong, the task branches operate on those units and their representations. The paper gives no test of how errors in segmentation affect entity spans or dependency trees. The demonstrated pipeline should therefore be understood in terms of the word-level input the authors specify.
Limits of the evidence about why it works
The table reports averages over 5 runs with different seeds. It does not report individual runs, dispersion or a significance test for the comparisons. Averaging gives a result that depends on several starts, but the reader cannot use the table to see how frequently the same ranking occurs across those runs. This matters for small separations between the scores. The evidence supports reporting the means and their ordering. It does not establish the uncertainty around the size of the advantage.
The validation rule also shapes the meaning of the reported scores. A single checkpoint is chosen using an average of the validation measures for the tasks. This supports selecting a system that can provide all the outputs together. The paper does not show what would happen if the joint system selected different checkpoints for each task, or if a particular task were given priority in the selection rule. Likewise, the tuned loss weights and resampling schedule describe the winning configuration the authors report. Their separate effects on the tasks have not been isolated.
The main causal ambiguity is between improvements from shared representation learning and improvements from the explicit transfer of tag information. The preliminary parser result favors keeping the explicit tag feature in that branch. It does not settle which part of the architecture explains the overall gap with the baseline. In particular, the study provides neither a full quantitative ablation of soft versus discrete grammatical features nor a comparison of joint training with and without the feature in each downstream branch. The strongest mechanistic claim is that the system provides these paths for information to flow and that removing one of them was reported to harm parsing.
The application examples motivate the work, while the evidence concerns the annotations. A more accurate dependency tree or entity span could be useful when it supplies a feature to a subsequent stage. How frequently that changes a downstream decision depends on how the application uses the annotation and where it makes errors. The paper does not measure effects on translation, extraction or question answering. Its contribution is the shared annotation system and the benchmark comparison.
What came after
The later citations place PhoNLP alongside work with different research aims. One concerns the selection of data for multiple tasks, one builds a Vietnamese inference corpus, and one concerns a parallel corpus for Vietnamese varieties. The citations establish that these works refer to PhoNLP. Their stated topics establish the connection that can be described without assuming that any of them used its code, retrained its encoder or adopted its grammatical features.
Choosing examples for multiple tasks
The active learning work studies the selection of examples for annotation in a setting with pretrained transformers and multiple tasks. Active learning concerns which examples to label when one can choose the data to annotate. PhoNLP's training procedure starts from existing annotated corpora and deals with their unequal sizes by sampling again from smaller training sets. The later work's stated subject places the decision earlier. It concerns which supervision to acquire when more than one task is involved. The citation links that research question to PhoNLP's multitask setting, but it does not establish any reuse of the tag probability features or parsing architecture. Multi-task Active Learning for Pre-trained Transformers
A Vietnamese corpus for inference
ViNLI introduces a corpus for the study of Vietnamese open-domain natural language inference. Inference concerns the relationship between statements, such as whether one supports a conclusion expressed by another. This shifts the target of annotation from words and their grammatical links to relations between statements. PhoNLP and ViNLI both concern Vietnamese resources with defined targets for training and evaluation. The citation does not establish whether ViNLI used PhoNLP to annotate its corpus, evaluate a baseline or generate any part of its data. ViNLI
Parallel data for Vietnamese varieties
The parallel-corpus work concerns corresponding material from Central and Northern Vietnamese. Parallel data align material between varieties, while PhoNLP's benchmarks attach different kinds of labels to individual sentences. The connection that can be established is a citation from a study of Vietnamese parallel resources to a Vietnamese annotation system. There is no basis here for assigning PhoNLP a role in the corpus alignment or for drawing conclusions about its accuracy on either variety. Parallel corpus for Central and Northern Vietnamese
Cite
Cite as Linh The Nguyen and Dat Quoc Nguyen. 2021. PhoNLP: A joint multi-task learning model for Vietnamese part-of-speech tagging, named entity recognition and dependency parsing. Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies: Demonstrations.
@inproceedings{nguyen2021phonlp,
title = {{PhoNLP: A joint multi-task learning model for Vietnamese part-of-speech tagging, named entity recognition and dependency parsing}},
author = {Linh The Nguyen and Dat Quoc Nguyen},
booktitle = {Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies: Demonstrations},
year = {2021},
doi = {10.18653/v1/2021.naacl-demos.1},
url = {https://doi.org/10.18653/v1/2021.naacl-demos.1}
}This page in Markdown https://md.research.elamur.ai/free/en/papers/nguyen-2021-phonlp-joint-multi-task-learning/