Mastering Symbolic Operations: Augmenting Language Models with Compiled Neural Networks

Yixuan Weng, Minjun Zhu, Fei Xia, Bin Li, Shizhu He +2 more
2/12/2026

No official code found. Best implementation: WENGSYX/Neural-Comprehension (11 stars, MIT, last commit 2025-07-07).

Abstract

Language models' (LMs) proficiency in handling deterministic symbolic reasoning and rule-based tasks remains limited due to their dependency implicit learning on textual data. To endow LMs with genuine rule comprehension abilities, we propose"Neural Comprehension"- a framework that synergistically integrates compiled neural networks (CoNNs) into the standard transformer architecture. CoNNs are neural modules designed to explicitly encode rules through artificially generated attention weights. By incorporating CoNN modules, the Neural Comprehension framework enables LMs to accurately and robustly execute rule-intensive symbolic tasks. Extensive experiments demonstrate the superiority of our approach over existing techniques in terms of length generalization, efficiency, and interpretability for symbolic operations. Furthermore, it can be applied to LMs across different model scales, outperforming tool-calling methods in arithmetic reasoning tasks while maintaining superior inference efficiency. Our work highlights the potential of seamlessly unifying explicit rule learning via CoNNs and implicit pattern learning in LMs, paving the way for true symbolic comprehension capabilities.

View on arXivView PDF

Code Implementations(1)

MIT

[ICLR 2024] We have enabled language models to more fundamental comprehension of the concepts, to achieve completely absolute accuracy in symbolic reasoning without additional tools.

112PythonMar 26, 20231 years agoMIT

Similar Papers

Cite this paper

@article{weng2026mastering,
  title  = {Mastering Symbolic Operations: Augmenting Language Models with Compiled Neural Networks},
  author = {Yixuan Weng and Minjun Zhu and Fei Xia and Bin Li and Shizhu He and Kang Liu and Jun Zhao},
  year   = {2026},
  eprint = {2304.01665},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2304.01665},
  journal = {ICLR 2023 2023}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2304.01665.svg)](https://codeofpaper.com/paper/2304.01665)

Discussion