# Named Entity Recognition Networks Based on Syntactically Constrained Attention
## 4 Materials and Methods
### Analysis and Discussion
#### 4.4.2 The Impact of Semantic Dependencies on NER  
Syntactic information, in particular, that contained in dependency trees, is helpful in conducting information extraction tasks in existing studies. Most approaches construct the dependency trees as adjacency matrices and then encode the information in the graph through graph convolutional neural networks, where the information in each node communicates with its neighbors through the connections between them in each GCN layer. In this work, different models were compared against syntactic information to verify the effectiveness of our approach. (1) BiGCN: to capture features between front-to-back and back-to-front word pairs, a bi-directional GCN is used in this paper. (2) AGGCN: since dependency trees are obtained using complex feature engineering, an attention matrix formed by multi-headed self-attention mechanisms is used to represent the semantic associations between words, and then GCN is used to extract features. (3) SCAN-Net: Our model. (4) BAGCN: We use BiGCN and AGGCN to aggregate dual-channel syntactic features. (5) BAAGCN: We use the three-channel methods of BiGCN, AGGCN and syntactic constraints. The experimental results are shown in Figure 4.  
\begin{table}
\begin{tabular}{c c c c} \hline
**Model** & **P** & **R** & **F1** \\ \hline Baseline & 85.48 & 84.36 & 84.92 \\ +Attention & 84.97 & 85.08 & 85.03 \\ +Syntax Attention \(\uparrow\) & 84.91 & **85.78** & 85.34 \\ +Syntax Attention \(\downarrow\) & **85.98** & 85.45 & **85.71** \\ \hline \end{tabular}
\end{table}
Table 5: Ablation trials on the ACE2005 dataset. \(\uparrow\) indicates the use of a soft-pruning strategy and \(\downarrow\) indicates the use of a hard-pruning strategy.  
As can be seen from Figure 4, the SCAN-Net model achieved the best results when compared to the model using GCN, with BiGCN improving the F1 score by 0.22% compared to baseline, AGGCN improving the F1 score by 0.39% compared to baseline, and the two-channel model and three-channel model improving the F1 score by 0.67% and 0.7% respectively. Clearly, SCAN-Net shows a more significant improvement than the BiGCN and AGGCN models. For the three-channel model, although there is an improvement when compared to the baseline model, a slight decrease in performance was observed when compared to SCAN-Net, i.e., BiGCN and AGGCN suppress the performance of SCAN-Net. We speculate that the model can reduce noisy information under the effect of SCAN-Net constraint information, thus extracting more important information. In contrast, although the features extracted by BiGCN and AGGCN also allow the model to focus more on important information, with strong task relevance, they cannot eliminate the noisy information of weak words as SCNA-Net does, resulting in the overall effect being inferior to SCNA-Net. It is worth noting that although the SCAN-Net model has a slightly lower recall rate when compared to other non-baseline models, it has the highest F1 score and P values, which could also validate the speculation in Section 4.4.1, in that although the SCNA-Net model using the hard-pruning strategy may ignore some strong words, resulting in the model failing to recognize some named entities, it can still achieve good results due, to its excellent performance in rejecting weak words. The above experiments demonstrated that the syntactically constrained attention mechanism has a better performance than the graph convolutional network in the named entity recognition task, based on the reading comprehension approach.