Multi-hop Attention Graph Neural Networks
Abstract
Self-attention mechanism in graph neural networks (GNNs) led to state-of-the-art performance on many graph representation learning tasks. Currently, at every layer, a node computes attention independently for each of its graph neighbors. However, such attention mechanism is limited as it does not consider nodes that are not connected by an edge but can provide important network context information. Here we propose Multi-hop Attention Graph Neural Network (MAGNA), a principled way to incorporate multi-hop context information into every layer of GNN attention computation. MAGNA diffuses the attention scores across the network, which increases the ``receptive field'' for every layer of the GNN. Unlike previous approaches, MAGNA uses a diffusion prior on attention values, to efficiently account for all paths between the pair of not-connected nodes. We demonstrate theoretically and experimentally that MAGNA captures large-scale structural information in every layer, and has a low-pass effect that eliminates noisy high-frequency information from the graph. Experimental results on node classification as well as knowledge graph completion benchmarks show that MAGNA achieves state-of-the-art results: MAGNA achieves up to $5.7\
Benchmark Results
Tested on 5 datasets 8 baseline values reported too low
Tables show presented results in global context (best 3 papers + GCN + MLP).
Classic
| # | Model | Accuracy ↑ | Paper |
|---|---|---|---|
| 1 | GraphSAGE+CNA | 0.9418
±0.0033 | |
| 2 | GCN+CNA | 0.9366
±0.0048 | |
| 3 | TransformerConv | 0.9350
±0.0058 | |
| 21 | GCN | 0.9004 | |
| 55 | JKNet | 0.8870 best reported | best at pub: Learned Low Precision Graph Neural Networks (2020) |
| 108 | APPNP | 0.8787 best reported | best at pub: Tackling Over-Smoothing for General Graph Convolutional Networks (2020) best today: Feature Transportation Improves Graph Neural Networks (AAAI 2023) |
| 208 | MAGNA | 0.8540
±0.0060 | This paper |
| 347 | Diff-GCN | 0.8360
±0.0020 | This paper |
| 356 | Diffusion-GCN (PPR) | 0.8360
±0.0020 | This paper |
| 367 | DualGCN | 0.8350 | This paper |
| 422 | GAT (hidden dimension = 512) | 0.8310
±0.0050 | This paper |
| 592 | Cheby | 0.8120 | This paper |
| 724 | MLP | 0.7768 |
| # | Model | Accuracy ↑ | Paper |
|---|---|---|---|
| 1 | CNA | 0.9575
±0.0058 | |
| 2 | IS-GIB | 0.9390
±0.0187 | |
| 3 | EERM | 0.9112
±0.0145 | |
| 20 | APPNP | 0.8142
±0.0026 best reported | best at pub: Tackling Over-Smoothing for General Graph Convolutional Networks (2020) best today: Feature Expansion for Graph Neural Networks (ICML 2023) |
| 44 | GCN | 0.8033
±0.0088 | |
| 62 | JKNet | 0.7920 best reported | best at pub: Tackling Over-Smoothing for General Graph Convolutional Networks (2020) |
| 254 | MAGNA | 0.7370
±0.0050 | This paper |
| 284 | Diff-GCN | 0.7340
±0.0030 | This paper |
| 288 | Diffusion-GCN (PPR) | 0.7340
±0.0030 | This paper |
| 350 | MLP | 0.7289
±0.0010 | |
| 377 | DualGCN | 0.7260 | This paper |
| 612 | Cheby | 0.7020
±0.0100 best reported | best at pub: Fast Graph Representation Learning with PyTorch Geometric (ICLR 2019) |
| # | Model | Accuracy ↑ | Paper |
|---|---|---|---|
| 1 | LGTL | 0.9518
±0.0011 | |
| 2 | MixHop (LO) | 0.9513
±0.0038 | |
| 3 | GraphSAGE (LO) | 0.9511
±0.0036 | |
| 17 | APPNP | 0.9355
±0.0060 best reported | best at pub: Tackling Over-Smoothing for General Graph Convolutional Networks (2020) |
| 18 | GCN | 0.9296
±0.0015 | |
| 24 | JKNet | 0.9160 best reported | best at pub: Tackling Over-Smoothing for General Graph Convolutional Networks (2020) |
| 210 | MLP | 0.8690
±0.0074 | |
| 351 | MAGNA | 0.8140
±0.0020 | This paper |
| 451 | DualGCN | 0.8000 | This paper |
| 492 | Diff-GCN | 0.7960
±0.0040 | This paper |
| 650 | Cheby | 0.7840
±0.0040 best reported | best at pub: Fast Graph Representation Learning with PyTorch Geometric (ICLR 2019) |
Knowledge Graphs
| # | Model | MRR ↑ | Paper |
|---|---|---|---|
| 1 | FedSage | 0.8426
±0.0026 | |
| 2 | FED-PUB | 0.8348
±0.0025 | |
| 3 | FedAvg | 0.8252
±0.0023 | |
| 7 | GCN | 0.8171
±0.0030 | |
| 39 | MAGNA + DistMult | 0.5020 | This paper |
| 42 | ROTH | 0.4960 | This paper |
| 44 | OTE | 0.4910 | This paper |
| 46 | AutoSF | 0.4900 | This paper |
| 48 | QuatE | 0.4880 | This paper |
| 62 | RotatE | 0.4770 best reported | best at pub: RotatE: Knowledge Graph Embedding by Relational Rotation in Complex Space (ICLR 2018) best today: KnowFormer: Revisiting Transformers for Knowledge Graph Reasoning (ICML 2024) |
| 64 | CoKE | 0.4750 | This paper |
| 68 | TuckER | 0.4700 | This paper |
| 69 | SACN | 0.4700 | This paper |
| 79 | DistMult | 0.4550 best reported | best at pub: Knowledge Graphs (AAAI 2017) best today: KnowFormer: Revisiting Transformers for Knowledge Graph Reasoning (ICML 2024) |
| 81 | A2N | 0.4500 | This paper |
| 84 | ComplEx | 0.4400 | This paper |
| 89 | ConvE | 0.4300 | This paper |
| 100 | TransE | 0.2310 best reported | best at pub: RotatE: Knowledge Graph Embedding by Relational Rotation in Complex Space (ICLR 2018) |
| # | Model | MRR ↑ | Paper |
|---|---|---|---|
| 1 | sum, Msg_r^3, f(t)=0 | 0.8500 | |
| 2 | sum, Msg_r^3, f(t)=t | 0.8440 | |
| 3 | PNA, Msg_r^1, f(t)=0 | 0.8010 | |
| 21 | MAGNA + DistMult | 0.3690 | This paper |
| 23 | QuatE | 0.3660 | This paper |
| 27 | OTE | 0.3610 | This paper |
| 28 | CoKE | 0.3610 | This paper |
| 30 | AutoSF | 0.3600 | This paper |
| 33 | DistMult | 0.3580 best reported | best at pub: Knowledge Graphs (AAAI 2017) best today: KnowFormer: Revisiting Transformers for Knowledge Graph Reasoning (ICML 2024) |
| 32 | TuckER | 0.3580 | This paper |
| 45 | SACN | 0.3500 | This paper |
| 47 | ComplEx | 0.3460 best reported | best at pub: Knowledge Graphs (AAAI 2017) |
| 51 | ROTH | 0.3440 | This paper |
| 58 | RotatE | 0.3380 | This paper |
| 67 | TransE | 0.3300 best reported | best at pub: Composition-based Multi-Relational Graph Convolutional Networks (ICLR 2019) best today: KnowFormer: Revisiting Transformers for Knowledge Graph Reasoning (ICML 2024) |
| 71 | ConvE | 0.3250 | This paper |
| 78 | A2N | 0.3170 | This paper |
| 89 | R-GCN | 0.2490 | prev best: Knowledge Graphs (AAAI 2017) |
