Injecting Logical Constraints into Neural Networks via Straight-Through Estimators
Zhun Yang, Joohyung Lee, Chiyoun Park
Abstract
Injecting discrete logical constraints into neural network learning is one of the main challenges in neuro-symbolic AI. We find that a straight-through-estimator, a method introduced to train binary neural networks, could effectively be applied to incorporate logical constraints into neural network learning. More specifically, we design a systematic way to represent discrete logical constraints as a loss function; minimizing this loss using gradient descent via a straight-through-estimator updates the neural network's weights in the direction that the binarized outputs satisfy the logical constraints. The experimental results show that by leveraging GPUs and batch training, this method scales significantly better than existing neuro-symbolic methods that require heavy symbolic computation for computing gradients. Also, we demonstrate that our method applies to different types of neural networks, such as MLP, CNN, and GNN, making them learn with no or fewer labeled data by learning directly from known constraints.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Cited by top-tier papers12
- Efficient Rectification of Neuro-Symbolic Reasoning Inconsistencies by Abductive ReflectionWen-Chao Hu, Wang-Zhou Dai, Yuan Jiang, Zhi-Hua ZhouAAAI 2025 · 14 citations
- CuTS: Customizable Tabular Synthetic Data GenerationMark Vero, Mislav Balunovic, Martin T. VechevICML 2024 · 13 citations
- Analysis for Abductive Learning and Neural-Symbolic Reasoning ShortcutsXiaowen Yang, Wenda Wei, Jie-Jing Shao, Yufeng Li et al.ICML 2024 · 11 citations
- Grounding Neural Inference with Satisfiability Modulo TheoriesZifan Wang, Saranya Vijayakumar, Kaiji Lu, Vijay Ganesh et al.NeurIPS 2023 · 8 citations
- Knowledge-Enhanced Historical Document Segmentation and RecognitionEn-Hao Gao, Yu-Xuan Huang, Wen-Chao Hu, Xin-Hao Zhu et al.AAAI 2024 · 7 citations
Builds on3
- Differentiation of Blackbox Combinatorial SolversMarin Vlastelica Pogancic, Anselm Paulus, Vít Musil, Georg Martius et al.ICLR 2020 · 341 citations
- Complex Query Answering with Neural Link PredictorsErik Arakelyan, Daniel Daza, Pasquale Minervini, Michael CochezICLR 2021 · 29 citations
- Plug-in, Trainable Gate for Streamlining Arbitrary Neural NetworksJaedeok Kim, Chiyoun Park, Hyun-Joo Jung, Yoonsuck ChoeAAAI 2020 · 19 citations
Related papers
- Training Binary Neural Networks using the Bayesian Learning RuleXiangming Meng, Roman Bachmann, Mohammad Emtiyaz KhanICML 2020 · 47 citations
- KLay: Accelerating Arithmetic Circuits for Neurosymbolic AIJaron Maene, Vincent Derkinderen, Pedro Zuidberg Dos MartiresICLR 2025
- Neurosymbolic Reasoning and Learning with Restricted Boltzmann MachinesSon N. Tran, Artur S. d'Avila GarcezAAAI 2023 · 2 citations
- AdaSTE: An Adaptive Straight-Through Estimator to Train Binary Neural NetworksHuu Le, Rasmus Kjær Høier, Che-Tsung Lin, Christopher ZachCVPR 2022
- DisjunctiveNet: Neural Symbolic Learning via Differentiable Convexified Optimization LayersShraman Pal, Can LiICML 2026
