Abstract
Neural approaches to sequence labeling often use a Conditional Random Field (CRF) to model their output dependencies, while Recurrent Neural Networks (RNN) are used for the same purpose in other tasks. We set out to establish RNNs as an attractive alternative to CRFs for sequence labeling. To do so, we address one of the RNN's most prominent shortcomings, the fact that it is not exposed to its own errors with the maximum-likelihood training. We frame the prediction of the output sequence as a sequential decision-making process, where we train the network with an adjusted actor-critic algorithm (AC-RNN). We comprehensively compare this strategy with maximum-likelihood training for both RNNs and CRFs on three structured-output tasks. The proposed AC-RNN efficiently matches the performance of the CRF on NER and CCG tagging, and outperforms it on Machine Transliteration. We also show that our training strategy is significantly better than other techniques for addressing RNN's exposure bias, such as Scheduled Sampling, and Self-Critical policy training.
Introduction
Sequence labeling is a fundamental task in natural language processing, involving the assignment of a tag to every token in a sequence. Traditional state-of-the-art models typically employ Conditional Random Fields (CRFs) to capture global dependencies between labels. While effective, CRFs suffer from high computational complexity and memory requirements, particularly as the label vocabulary grows.
Recurrent Neural Networks (RNNs) offer a more flexible alternative with the ability to track long-range dependencies. However, they are plagued by "exposure bias." During standard maximum-likelihood training (Teacher Forcing), the model is conditioned on ground-truth previous tags. At inference, it must rely on its own potentially erroneous predictions, leading to a cascade of errors. This paper introduces the AC-RNN, a framework that leverages an adjusted actor-critic reinforcement learning approach to mitigate exposure bias and establish RNNs as a viable, efficient alternative to CRFs.
The AC-RNN Framework
The proposed AC-RNN replaces the CRF output layer with a decoder RNN trained via a reinforcement learning objective. The system consists of two primary components:
- The Actor: The decoder RNN itself, which learns a policy to select the optimal tag at each time step.
- The Critic: A secondary neural network that estimates the value (expected future reward) of the current state.
Unlike standard RL tasks where rewards are sparse, the AC-RNN receives a binary reward (+1 for correct, 0 for incorrect) at every step. To ensure training stability, the authors introduce an "adjusted" mechanism. Standard RL can be unstable if the critic provides feedback that contradicts the ground truth. The adjustment involves a clipping mechanism that ignores updates when the critic's advantage score would discourage a correct prediction.
As shown in Figure 1, the output-adjusted actor-critic method maintains superior and more stable performance compared to standard REINFORCE-based methods, which often suffer from high variance and performance degradation over epochs.
Experimental Results
The AC-RNN was evaluated across three structured-output tasks: Named Entity Recognition (NER), CCG Supertagging, and Machine Transliteration.
Performance and Efficiency
In NER tasks (CoNLL-2003), the AC-RNN achieved an F1-score of 90.96 on English, surpassing both the CRF (90.80) and the standard RNN (90.75). The most significant gains were observed in Machine Transliteration, where the AC-RNN scored 72.3% accuracy on English-to-Chinese, significantly outperforming the CRF's 67.6%.
The efficiency of the AC-RNN is particularly evident in high-complexity tasks like CCG Supertagging, which involves a vocabulary of 1,284 tags.
As detailed in Figure 2, the AC-RNN matches or exceeds the accuracy of the CRF while being approximately 5x faster to train and using 6x less GPU memory. This makes it a highly scalable solution for tasks with large label sets where CRFs become computationally prohibitive.
Conclusion
The AC-RNN demonstrates that the perceived superiority of CRFs in sequence labeling is largely a function of training objectives rather than architecture. By addressing exposure bias through an adjusted actor-critic approach, RNNs can match the global modeling capabilities of CRFs while offering superior flexibility and efficiency. Future work will explore the application of this framework to more complex many-to-many transduction tasks.
Summary updated