{"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/extrapolating-paths-with-graph-neural","title":"Extrapolating paths with graph neural networks","arxiv_id":"1903.07518","date":"2019-03-18","proceeding":null,"authors":["Jean-Baptiste Cordonnier","Andreas Loukas"],"abstract":"We consider the problem of path inference: given a path prefix, i.e., a\npartially observed sequence of nodes in a graph, we want to predict which nodes\nare in the missing suffix. In particular, we focus on natural paths occurring\nas a by-product of the interaction of an agent with a network---a driver on the\ntransportation network, an information seeker in Wikipedia, or a client in an\nonline shop. Our interest is sparked by the realization that, in contrast to\nshortest-path problems, natural paths are usually not optimal in any\ngraph-theoretic sense, but might still follow predictable patterns.\n  Our main contribution is a graph neural network called Gretel. Conditioned on\na path prefix, this network can efficiently extrapolate path suffixes, evaluate\npath likelihood, and sample from the future path distribution. Our experiments\nwith GPS traces on a road network and user-navigation paths in Wikipedia\nconfirm that Gretel is able to adapt to graphs with very different properties,\nwhile also comparing favorably to previous solutions.","url_abs":"http://arxiv.org/abs/1903.07518v1","url_pdf":"http://arxiv.org/pdf/1903.07518v1.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":"extrapolating-paths-with-graph-neural","repo_url":"https://github.com/jbcdnr/gretel-path-extrapolation","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok","spdx":"Apache-2.0"}},{"paper_slug":"extrapolating-paths-with-graph-neural","repo_url":"https://github.com/asrtoufa/wikispeedia-paths-dual-hypergraph-features","is_official":0,"mentioned_in_paper":0,"mentioned_in_github":1,"framework":"pytorch","reach":{"status":"ok"}}],"tasks":[{"task_slug":"graph-neural-network","task_name":"Graph Neural Network"}],"methods":[{"method_slug":"graph-neural-network","method_name":"Graph Neural Network"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=1903.07518","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"1903.07518"}},"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/asrtoufa/wikispeedia-paths-dual-hypergraph-features","reach":{"status":"ok"}},{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/jbcdnr/gretel-path-extrapolation","reach":{"status":"ok","spdx":"Apache-2.0"}}],"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":"700fccceb32ddcd2","entry":"any_nan","repo":"jbcdnr/gretel-path-extrapolation","repo_kind":"official","path":"debug.py","file_url":"https://github.com/jbcdnr/gretel-path-extrapolation/blob/HEAD/debug.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"700fccceb32ddcd2"}},{"code_sha256_prefix":"3d7f7f7d5d7b1ee1","entry":"color_scale","repo":"jbcdnr/gretel-path-extrapolation","repo_kind":"official","path":"plot.py","file_url":"https://github.com/jbcdnr/gretel-path-extrapolation/blob/HEAD/plot.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"3d7f7f7d5d7b1ee1"}},{"code_sha256_prefix":"ef21410f2d33eeaf","entry":"compute_target_probability","repo":"jbcdnr/gretel-path-extrapolation","repo_kind":"official","path":"metrics.py","file_url":"https://github.com/jbcdnr/gretel-path-extrapolation/blob/HEAD/metrics.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"ef21410f2d33eeaf"}},{"code_sha256_prefix":"933332759cb2c562","entry":"compute_topk_contains_target","repo":"jbcdnr/gretel-path-extrapolation","repo_kind":"official","path":"metrics.py","file_url":"https://github.com/jbcdnr/gretel-path-extrapolation/blob/HEAD/metrics.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"933332759cb2c562"}},{"code_sha256_prefix":"4c4cbdaf193ffcfa","entry":"numpify","repo":"jbcdnr/gretel-path-extrapolation","repo_kind":"official","path":"utils.py","file_url":"https://github.com/jbcdnr/gretel-path-extrapolation/blob/HEAD/utils.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"4c4cbdaf193ffcfa"}},{"code_sha256_prefix":"566eaa08f759a8b9","entry":"sample","repo":"jbcdnr/gretel-path-extrapolation","repo_kind":"official","path":"utils.py","file_url":"https://github.com/jbcdnr/gretel-path-extrapolation/blob/HEAD/utils.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"566eaa08f759a8b9"}},{"code_sha256_prefix":"3dbfe6865686ce1c","entry":"start_idx_from_lengths","repo":"jbcdnr/gretel-path-extrapolation","repo_kind":"official","path":"utils.py","file_url":"https://github.com/jbcdnr/gretel-path-extrapolation/blob/HEAD/utils.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"3dbfe6865686ce1c"}},{"code_sha256_prefix":"2b5859ad30a75540","entry":"target2_accuracy","repo":"jbcdnr/gretel-path-extrapolation","repo_kind":"official","path":"metrics.py","file_url":"https://github.com/jbcdnr/gretel-path-extrapolation/blob/HEAD/metrics.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"2b5859ad30a75540"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}