Abstract
Chinese Word Segmentation (CWS) has traditionally relied on complex decoding algorithms like Viterbi or Beam Search to ensure global consistency. This paper proposes a paradigm shift by focusing on a powerful attention-based encoder, the Gaussian-masked Directional (GD) Transformer. By leveraging a biaffine scorer and local-bias attention, the model achieves state-of-the-art performance using simple greedy decoding. This approach significantly reduces computational overhead, achieving a 25x speedup over existing neural models while maintaining high accuracy across standard benchmarks.
Introduction
Chinese Word Segmentation is a foundational task in Chinese natural language processing, involving the identification of word boundaries in unspaced character sequences. Historically, the field has been divided between traditional models (e.g., CRFs) and neural models (e.g., BiLSTMs), both of which often require sophisticated decoding strategies to resolve structural ambiguities.
As shown in the comparison above, most high-performing models utilize Viterbi or Beam Search. The authors argue that a sufficiently rich character representation can eliminate the need for these expensive search algorithms, allowing for efficient greedy decoding without sacrificing precision.
Methodology: The GD-Transformer Architecture
The core of the proposed system is an "attention-only" architecture designed to capture local dependencies and directional information, which are crucial for identifying word boundaries.
Gaussian-masked Directional (GD) Transformer
Standard Transformers lack an inherent bias for local context, which is critical for CWS where a character's immediate neighbors provide the most relevant information. The authors introduce a Gaussian mask to the attention weights, forcing the model to prioritize local context. Furthermore, the encoder employs three parallel pipelines—Forward, Backward, and Center—to explicitly model how a character relates to its preceding and succeeding context.
Biaffine Attention Scorer and HiRED
Instead of standard linear classification, a biaffine scorer predicts the probability of word boundaries. This is complemented by Hidden Representations for Early Decoding (HiRED), which are "highway" connections that allow the model to utilize intermediate features from the Transformer stack, smoothing the training process and enhancing the final representation.
Experimental Results
The model was evaluated on the SIGHAN Bakeoff 2005 benchmarks, including the PKU, MSR, AS, and CITYU datasets.
- Efficiency: The model achieved a dramatic 25x speedup on the PKU dataset, completing inference in just 4 seconds compared to 105 seconds for previous neural baselines.
- Accuracy: In closed test settings, the model set new state-of-the-art F1 scores on the MSR (97.6) and AS (95.7) datasets.
- Ablation Studies: Results confirmed that the Gaussian mask and directional pipelines are essential; removing these components led to a significant drop in performance, proving that local-bias is key to the model's success.
Conclusion
The success of the GD-Transformer demonstrates that structural search is often a compensation for weak representations. By re-introducing local bias into the Transformer architecture, the authors show that a powerful encoder can make the decoding step trivial. This paves the way for ultra-fast, high-accuracy sequence labeling in Chinese NLP and potentially other local-heavy tasks like NER or POS tagging.
Summary updated