{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/extending-the-design-space-of-graph-neural-1","title":"Extending the Design Space of Graph Neural Networks by Rethinking Folklore Weisfeiler-Lehman","arxiv_id":"2306.03266","date":"2023-06-05","proceeding":"NeurIPS 2023 11","authors":["Jiarui Feng","Lecheng Kong","Hao liu","DaCheng Tao","Fuhai Li","Muhan Zhang","Yixin Chen"],"abstract":"Message passing neural networks (MPNNs) have emerged as the most popular framework of graph neural networks (GNNs) in recent years. However, their expressive power is limited by the 1-dimensional Weisfeiler-Lehman (1-WL) test. Some works are inspired by $k$-WL/FWL (Folklore WL) and design the corresponding neural versions. Despite the high expressive power, there are serious limitations in this line of research. In particular, (1) $k$-WL/FWL requires at least $O(n^k)$ space complexity, which is impractical for large graphs even when $k=3$; (2) The design space of $k$-WL/FWL is rigid, with the only adjustable hyper-parameter being $k$. To tackle the first limitation, we propose an extension, $(k,t)$-FWL. We theoretically prove that even if we fix the space complexity to $O(n^k)$ (for any $k\\geq 2$) in $(k,t)$-FWL, we can construct an expressiveness hierarchy up to solving the graph isomorphism problem. To tackle the second problem, we propose $k$-FWL+, which considers any equivariant set as neighbors instead of all nodes, thereby greatly expanding the design space of $k$-FWL. Combining these two modifications results in a flexible and powerful framework $(k,t)$-FWL+. We demonstrate $(k,t)$-FWL+ can implement most existing models with matching expressiveness. We then introduce an instance of $(k,t)$-FWL+ called Neighborhood$^2$-FWL (N$^2$-FWL), which is practically and theoretically sound. We prove that N$^2$-FWL is no less powerful than 3-WL, and can encode many substructures while only requiring $O(n^2)$ space. Finally, we design its neural version named N$^2$-GNN and evaluate its performance on various tasks. N$^2$-GNN achieves record-breaking results on ZINC-Subset (0.059), outperforming previous SOTA results by 10.6%. Moreover, N$^2$-GNN achieves new SOTA results on the BREC dataset (71.8%) among all existing high-expressive GNN methods.","url_abs":"https://arxiv.org/abs/2306.03266v3","url_pdf":"https://arxiv.org/pdf/2306.03266v3.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"extending-the-design-space-of-graph-neural-1","repo_url":"https://github.com/jiaruifeng/n2gnn","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"graph-regression","task_name":"Graph Regression"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/graph-regression-on-zinc","task":"Graph Regression","dataset":"ZINC","model":"N2-GNN","rank_in_archive_order":5,"of":27,"metrics":{"MAE":"0.059"},"uses_additional_data":false},{"leaderboard":"/sota/graph-regression-on-zinc-500k","task":"Graph Regression","dataset":"ZINC-500k","model":"N2-GNN","rank_in_archive_order":3,"of":36,"metrics":{"MAE":"0.059"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2306.03266","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2306.03266"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-24T18:15:14+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"deterministic:regex_extraction","url":"https://github.com/JiaruiFeng/N2GNN","reach":{"status":"ok","spdx":"MIT"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/jiaruifeng/n2gnn","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"unverified":6},"by_repo_kind":{"official":{"samples":6,"ran":0,"repositories":1}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":0,"samples":[{"code_sha256_prefix":"5a6d344e0d997173","entry":"clones","repo":"JiaruiFeng/N2GNN","repo_kind":"official","path":"models/utils.py","file_url":"https://github.com/JiaruiFeng/N2GNN/blob/HEAD/models/utils.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"5a6d344e0d997173"}},{"code_sha256_prefix":"13692dffae367fac","entry":"edge_list_to_sparse_adj","repo":"JiaruiFeng/N2GNN","repo_kind":"official","path":"data_utils.py","file_url":"https://github.com/JiaruiFeng/N2GNN/blob/HEAD/data_utils.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"13692dffae367fac"}},{"code_sha256_prefix":"2cc9de52cab58024","entry":"extract_spd_feature","repo":"JiaruiFeng/N2GNN","repo_kind":"official","path":"data_utils.py","file_url":"https://github.com/JiaruiFeng/N2GNN/blob/HEAD/data_utils.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"2cc9de52cab58024"}},{"code_sha256_prefix":"af687803b3797fc0","entry":"gaussian","repo":"JiaruiFeng/N2GNN","repo_kind":"official","path":"models/input_encoder.py","file_url":"https://github.com/JiaruiFeng/N2GNN/blob/HEAD/models/input_encoder.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"af687803b3797fc0"}},{"code_sha256_prefix":"156d188d22f0d901","entry":"get_pyg_attr","repo":"JiaruiFeng/N2GNN","repo_kind":"official","path":"models/utils.py","file_url":"https://github.com/JiaruiFeng/N2GNN/blob/HEAD/models/utils.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"156d188d22f0d901"}},{"code_sha256_prefix":"16a6d20b36863bbb","entry":"shortest_dist_sparse_mult","repo":"JiaruiFeng/N2GNN","repo_kind":"official","path":"data_utils.py","file_url":"https://github.com/JiaruiFeng/N2GNN/blob/HEAD/data_utils.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"MIT","inline_ok":true,"mcp_get_code":{"code_sha256":"16a6d20b36863bbb"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}