{"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/ood-link-prediction-generalization","title":"OOD Link Prediction Generalization Capabilities of Message-Passing GNNs in Larger Test Graphs","arxiv_id":"2205.15117","date":"2022-05-30","proceeding":null,"authors":["Yangze Zhou","Gitta Kutyniok","Bruno Ribeiro"],"abstract":"This work provides the first theoretical study on the ability of graph Message Passing Neural Networks (gMPNNs) -- such as Graph Neural Networks (GNNs) -- to perform inductive out-of-distribution (OOD) link prediction tasks, where deployment (test) graph sizes are larger than training graphs. We first prove non-asymptotic bounds showing that link predictors based on permutation-equivariant (structural) node embeddings obtained by gMPNNs can converge to a random guess as test graphs get larger. We then propose a theoretically-sound gMPNN that outputs structural pairwise (2-node) embeddings and prove non-asymptotic bounds showing that, as test graphs grow, these embeddings converge to embeddings of a continuous function that retains its ability to predict links OOD. Empirical results on random graphs show agreement with our theoretical results.","url_abs":"https://arxiv.org/abs/2205.15117v5","url_pdf":"https://arxiv.org/pdf/2205.15117v5.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":"ood-link-prediction-generalization","repo_url":"https://github.com/yangzez/ood-link-prediction-generalization-mpnn","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":0,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"link-prediction","task_name":"Link Prediction"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2205.15117","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2205.15117"}},"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":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/yangzez/ood-link-prediction-generalization-mpnn","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"unverified":8},"by_repo_kind":{"official":{"samples":8,"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":"20cf368c078dca62","entry":"accuracy","repo":"yangzez/ood-link-prediction-generalization-mpnn","repo_kind":"official","path":"utils.py","file_url":"https://github.com/yangzez/ood-link-prediction-generalization-mpnn/blob/HEAD/utils.py","link_basis":"harvester_set","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":"20cf368c078dca62"}},{"code_sha256_prefix":"aa953169177cb0d3","entry":"bin_config","repo":"yangzez/ood-link-prediction-generalization-mpnn","repo_kind":"official","path":"utils.py","file_url":"https://github.com/yangzez/ood-link-prediction-generalization-mpnn/blob/HEAD/utils.py","link_basis":"harvester_set","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":"aa953169177cb0d3"}},{"code_sha256_prefix":"84489b1dfc1645d1","entry":"get_arguments","repo":"yangzez/ood-link-prediction-generalization-mpnn","repo_kind":"official","path":"link_prediction_new.py","file_url":"https://github.com/yangzez/ood-link-prediction-generalization-mpnn/blob/HEAD/link_prediction_new.py","link_basis":"harvester_set","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":"84489b1dfc1645d1"}},{"code_sha256_prefix":"7ba79e79c5b339f8","entry":"get_arguments","repo":"yangzez/ood-link-prediction-generalization-mpnn","repo_kind":"official","path":"link_prediction_new_ddi.py","file_url":"https://github.com/yangzez/ood-link-prediction-generalization-mpnn/blob/HEAD/link_prediction_new_ddi.py","link_basis":"harvester_set","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":"7ba79e79c5b339f8"}},{"code_sha256_prefix":"658016d2559f35ca","entry":"test","repo":"yangzez/ood-link-prediction-generalization-mpnn","repo_kind":"official","path":"link_prediction_new.py","file_url":"https://github.com/yangzez/ood-link-prediction-generalization-mpnn/blob/HEAD/link_prediction_new.py","link_basis":"harvester_set","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":"658016d2559f35ca"}},{"code_sha256_prefix":"ede9af5ea21e6847","entry":"train","repo":"yangzez/ood-link-prediction-generalization-mpnn","repo_kind":"official","path":"link_prediction_new.py","file_url":"https://github.com/yangzez/ood-link-prediction-generalization-mpnn/blob/HEAD/link_prediction_new.py","link_basis":"harvester_set","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":"ede9af5ea21e6847"}},{"code_sha256_prefix":"12ff34677ab9312e","entry":"train","repo":"yangzez/ood-link-prediction-generalization-mpnn","repo_kind":"official","path":"link_prediction_new_ddi.py","file_url":"https://github.com/yangzez/ood-link-prediction-generalization-mpnn/blob/HEAD/link_prediction_new_ddi.py","link_basis":"harvester_set","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":"12ff34677ab9312e"}},{"code_sha256_prefix":"f8162f450d1f0f1e","entry":"transform_labels","repo":"yangzez/ood-link-prediction-generalization-mpnn","repo_kind":"official","path":"utils.py","file_url":"https://github.com/yangzez/ood-link-prediction-generalization-mpnn/blob/HEAD/utils.py","link_basis":"harvester_set","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":"f8162f450d1f0f1e"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}