{"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/electron-flow-matching-for-generative","title":"Electron flow matching for generative reaction mechanism prediction obeying conservation laws","arxiv_id":"2502.12979","date":"2025-02-18","proceeding":null,"authors":["Joonyoung F. Joung","Mun Hong Fong","Nicholas Casetti","Jordan P. Liles","Ne S. Dassanayake","Connor W. Coley"],"abstract":"Central to our understanding of chemical reactivity is the principle of mass conservation, which is fundamental for ensuring physical consistency, balancing equations, and guiding reaction design. However, data-driven computational models for tasks such as reaction product prediction rarely abide by this most basic constraint. In this work, we recast the problem of reaction prediction as a problem of electron redistribution using the modern deep generative framework of flow matching. Our model, FlowER, overcomes limitations inherent in previous approaches by enforcing exact mass conservation, thereby resolving hallucinatory failure modes, recovering mechanistic reaction sequences for unseen substrate scaffolds, and generalizing effectively to out-of-domain reaction classes with extremely data-efficient fine-tuning. FlowER additionally enables estimation of thermodynamic or kinetic feasibility and manifests a degree of chemical intuition in reaction prediction tasks. This inherently interpretable framework represents a significant step in bridging the gap between predictive accuracy and mechanistic understanding in data-driven reaction outcome prediction.","url_abs":"https://arxiv.org/abs/2502.12979v1","url_pdf":"https://arxiv.org/pdf/2502.12979v1.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":"electron-flow-matching-for-generative","repo_url":"https://github.com/FongMunHong/FlowER","is_official":1,"mentioned_in_paper":0,"mentioned_in_github":0,"framework":"pytorch","reach":{"status":"ok","spdx":"MIT"}}],"tasks":[{"task_slug":"prediction","task_name":"Prediction"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2502.12979","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2502.12979"}},"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/FongMunHong/FlowER","reach":{"status":"ok","spdx":"MIT"}}],"summary":{"unverified":11},"by_repo_kind":{"official":{"samples":11,"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":"3b7642c4790fea19","entry":"assign_rank","repo":"FongMunHong/FlowER","repo_kind":"official","path":"sequence_evaluation.py","file_url":"https://github.com/FongMunHong/FlowER/blob/HEAD/sequence_evaluation.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":"3b7642c4790fea19"}},{"code_sha256_prefix":"4ac7d304cf608454","entry":"grad_norm","repo":"FongMunHong/FlowER","repo_kind":"official","path":"utils/train_utils.py","file_url":"https://github.com/FongMunHong/FlowER/blob/HEAD/utils/train_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":"4ac7d304cf608454"}},{"code_sha256_prefix":"2e5b3953b2e46f24","entry":"is_sym","repo":"FongMunHong/FlowER","repo_kind":"official","path":"eval_multiGPU.py","file_url":"https://github.com/FongMunHong/FlowER/blob/HEAD/eval_multiGPU.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":"2e5b3953b2e46f24"}},{"code_sha256_prefix":"4715ff4556d439a4","entry":"param_count","repo":"FongMunHong/FlowER","repo_kind":"official","path":"utils/train_utils.py","file_url":"https://github.com/FongMunHong/FlowER/blob/HEAD/utils/train_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":"4715ff4556d439a4"}},{"code_sha256_prefix":"096130b325d34825","entry":"param_norm","repo":"FongMunHong/FlowER","repo_kind":"official","path":"utils/train_utils.py","file_url":"https://github.com/FongMunHong/FlowER/blob/HEAD/utils/train_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":"096130b325d34825"}},{"code_sha256_prefix":"dacb778430d75e04","entry":"redist_fix","repo":"FongMunHong/FlowER","repo_kind":"official","path":"eval_multiGPU.py","file_url":"https://github.com/FongMunHong/FlowER/blob/HEAD/eval_multiGPU.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":"dacb778430d75e04"}},{"code_sha256_prefix":"4f13717ec99ad053","entry":"saferound_tensor","repo":"FongMunHong/FlowER","repo_kind":"official","path":"utils/rounding.py","file_url":"https://github.com/FongMunHong/FlowER/blob/HEAD/utils/rounding.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":"4f13717ec99ad053"}},{"code_sha256_prefix":"c59855935d005e02","entry":"select","repo":"FongMunHong/FlowER","repo_kind":"official","path":"beam_predict.py","file_url":"https://github.com/FongMunHong/FlowER/blob/HEAD/beam_predict.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":"c59855935d005e02"}},{"code_sha256_prefix":"034e5b1de6cfd0af","entry":"sequence_mask","repo":"FongMunHong/FlowER","repo_kind":"official","path":"utils/attn_utils.py","file_url":"https://github.com/FongMunHong/FlowER/blob/HEAD/utils/attn_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":"034e5b1de6cfd0af"}},{"code_sha256_prefix":"b949347f464e1efb","entry":"timestep_embedding","repo":"FongMunHong/FlowER","repo_kind":"official","path":"model/attn_encoder.py","file_url":"https://github.com/FongMunHong/FlowER/blob/HEAD/model/attn_encoder.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":"b949347f464e1efb"}},{"code_sha256_prefix":"b0e3200d6feec213","entry":"zero_center_func","repo":"FongMunHong/FlowER","repo_kind":"official","path":"model/flow_matching.py","file_url":"https://github.com/FongMunHong/FlowER/blob/HEAD/model/flow_matching.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":"b0e3200d6feec213"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}