[Paper Review] Hybrid Self-Attention Network for Machine Translation
This paper proposes Hybrid Self-Attention Network (HySAN), a novel self-attention mechanism that enhances Transformer-based machine translation by integrating global, local, left-, and right-context attention via task-specific masks and a squeeze gate for feature fusion. The method achieves state-of-the-art performance with gains of up to 1.07 BLEU on WMT17 Chinese-English and 1.0 BLEU on IWSLT14 German-English, using minimal additional parameters.
The encoder-decoder is the typical framework for Neural Machine Translation (NMT), and different structures have been developed for improving the translation performance. Transformer is one of the most promising structures, which can leverage the self-attention mechanism to capture the semantic dependency from global view. However, it cannot distinguish the relative position of different tokens very well, such as the tokens located at the left or right of the current token, and cannot focus on the local information around the current token either. To alleviate these problems, we propose a novel attention mechanism named Hybrid Self-Attention Network (HySAN) which accommodates some specific-designed masks for self-attention network to extract various semantic, such as the global/local information, the left/right part context. Finally, a squeeze gate is introduced to combine different kinds of SANs for fusion. Experimental results on three machine translation tasks show that our proposed framework outperforms the Transformer baseline significantly and achieves superior results over state-of-the-art NMT systems.
Motivation & Objective
- To address the limitations of standard self-attention in capturing relative positional order and local context in sequence modeling.
- To improve Transformer’s inability to distinguish between left and right context of a token, especially in ambiguous sentence structures.
- To enhance representation learning by extracting multi-scale semantic information—global, local, and directional—without significantly increasing model complexity.
- To design an efficient, parameter-light mechanism that integrates multiple attention branches while maintaining computational efficiency.
- To achieve superior translation performance across diverse language pairs and model scales.
Proposed method
- The HySAN module introduces multiple parallel attention branches, each applying a distinct mask to the scaled dot-product attention to extract specific contextual information: global, local, left-context, and right-context representations.
- Each attention branch uses a learnable mask to restrict the attention computation to a specific spatial or sequential context, enabling the model to capture both long-range dependencies and local patterns.
- A squeeze gate mechanism dynamically combines the outputs of the different attention branches using a learnable weighting mechanism based on input features, improving fusion relevance.
- The method is plug-and-play, requiring only minor modifications to the standard Transformer encoder-decoder architecture, with minimal parameter overhead (less than 1% additional parameters).
- The attention mechanism is applied in both encoder and decoder, with positional embeddings preserved to maintain relative position awareness.
- The model is trained end-to-end using standard cross-entropy loss and optimized via standard backpropagation with Adam optimizer.
Experimental results
Research questions
- RQ1Can a hybrid attention mechanism that combines global, local, and directional context improve sequence modeling in neural machine translation?
- RQ2How effectively can masked self-attention branches capture relative positional and local dependency information compared to standard self-attention?
- RQ3Does the squeeze gate mechanism enhance feature fusion across diverse attention branches in a parameter-efficient manner?
- RQ4To what extent does HySAN improve translation performance across diverse language pairs and model scales?
- RQ5Can the proposed method achieve state-of-the-art results while maintaining low computational overhead and minimal parameter increase?
Key findings
- HySAN achieves a 1.0 BLEU point improvement over the Transformer baseline on the IWSLT14 German-English translation task in the small model setting.
- On the WMT14 English-German task, HySAN improves performance by 0.6 BLEU points in the base model setting and 0.4 BLEU points in the large model setting.
- On the WMT17 Chinese-English translation task, HySAN achieves a 1.07 BLEU point improvement over the Transformer baseline, even surpassing more complex ensemble systems.
- The model converges faster than the baseline after 20,000 training steps and reaches peak performance around 85,000 steps, indicating improved training dynamics.
- Attention visualization confirms that the local and directional attention branches learn focused, non-uniform attention patterns, validating their ability to extract partial and directional context.
- The method increases model parameters by less than 1% and introduces negligible computational overhead, demonstrating high efficiency and scalability.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.