In natural language processing, the biaffine model can effectively captures sentence structure and word relationships for tasks like text classification and relation extraction. However, it struggles with entity pair relation classification, particularly in overlapping or complex scenarios. To address this, this paper proposes BERT-CL-Biaffine, an improved relation classification model integrating bidirectional entity contrastive learning and a global pointer network. The model enhances the biaffine architecture by training it to identify entity boundaries and leveraging contrastive learning to strengthen semantic associations between overlapping entity pairs. Experiments on the NYT and WebNLG datasets demonstrate that BERT-CL-Biaffine outperforms baseline models, achieving F1 score improvements of 1% and 1.2%, respectively. The model excels in classifying overlapping entity pairs and handles challenges like imbalanced relation types and ambiguous entity features, particularly in complex scenarios. The results validate that bidirectional entity contrastive learning and global pointer networks significantly enhance the biaffine model’s feature representation and classification performance. This approach offers a robust solution for relation extraction in intricate textual contexts.
1 December 2025 in International Journal of Wireless Information Networks
In the field of natural language processing, Biaffine model is a typical neural network structure based on double affine transformation, which helps to understand sentence structure and the relationships between words, which can be used for tasks such as text classification and relation extraction. However, this model faces challenges in entity pair relation classification tasks, such as imbalanced relation types and unclear entity pair feature information. Therefore, this paper proposes an improved relation classification model named Bert-CL-Biaffine, which is based on bidirectional entity and contrastive learning, combining a global pointer network with contrastive learning to enhance the Biaffine model for relation classification tasks. By training the model to identify the start and end positions of entities in sentences, it performs better in classifying overlapping entity pairs in complex scenarios. Experimental results show that on the NYT and WebNLG datasets, the F1 score of Bert-CL-Biaffine model improves by 1% and 1.2%, respectively, compared to baseline models, indicating that the improved relation classification model effectively enhances performance in complex scenarios.