An attention score is an unnormalized learned value assigned to a connected node pair. In a graph attention network, it estimates how much node i should consider neighbor j when updating node i’s features. section 4.5.3
GATs use scores in a short message-passing pipeline:
- Transform the feature vectors of the connected nodes with a learnable weight matrix. section 4.5.3
- Apply a learned attention mechanism to the transformed node features to produce the raw score eᵢⱼ. section 4.5.3
- Normalize raw scores over node i’s neighbors with softmax, producing coefficients αᵢⱼ that sum to 1. section 4.5.3
- Use the normalized coefficients to weight and combine neighboring features; multiple heads can learn different relational patterns. section 4.5.3
Fraud-detection graph
For a transaction node i connected to neighbor j, the learned score eᵢⱼ determines how strongly j contributes to i’s updated representation. GATConv computes such scores for every edge and attention head, so large graphs can require mini-batch sampling with PyG’s NeighborLoader. section 4.4.1
(4.1)
Use the equation sequence to inspect raw-score and coefficient calculations before following attention-weighted aggregation. section 4.5.3



