# Efficient NPN Classification for Large Functions using Graph Neural Network

DevFeed: [Efficient NPN Classification for Large Functions using Graph Neural Network](<https://devfeed.tech/articles/efficient-npn-classification-for-large-functions-using-graph-neural-network-115015.md>)

Original publisher: [Read original article](<https://arxiv.org/abs/2611.00339>)

Author: Chengdi Cao, Hanyu Wang, Wan-Hsuan Lin, Jason Cong

Published: 2026-11-03T05:00:00Z

Content type: article

Language: en

Sources: [arXiv: Artificial Intelligence](<https://devfeed.tech/sources/arxiv-artificial-intelligence.md>)

Topics: [Artificial Intelligence](<https://devfeed.tech/topics/ai.md>), [Neural Network](<https://devfeed.tech/topics/neural-network.md>)

Tags: [canonicalization](<https://devfeed.tech/tags/canonicalization.md>), [classification](<https://devfeed.tech/tags/classification.md>), [cs-ai](<https://devfeed.tech/tags/cs-ai.md>), [functions](<https://devfeed.tech/tags/functions.md>), [graph](<https://devfeed.tech/tags/graph.md>), [information-theory](<https://devfeed.tech/tags/information-theory.md>), [learning](<https://devfeed.tech/tags/learning.md>), [logic-synthesis](<https://devfeed.tech/tags/logic-synthesis.md>), [neural-network](<https://devfeed.tech/tags/neural-network.md>), [npn](<https://devfeed.tech/tags/npn.md>), [prediction](<https://devfeed.tech/tags/prediction.md>), [quantum-computing](<https://devfeed.tech/tags/quantum-computing.md>)

## AI overview

The paper frames NPN classification as predicting the transformations that relate Boolean functions: input negations, output negation, and input permutations. It represents functions as AND-Inverter Graphs and uses a bidirectional heterogeneous graph neural network; graph rewriting reduces structural ambiguity and recovers symmetries before prediction. The abstract reports better canonicalization quality than heuristic baselines, performance approaching exact methods on tractable practical cases, and scaling to functions with up to 16 inputs. Exact classification remains impractical for larger functions because exhaustive search grows exponentially.

## Source excerpt

arXiv:2611.00339v1 Announce Type: new Abstract: Two Boolean functions are considered NPN equivalent if one can be transformed into the other by negating inputs, permuting inputs, or negating the output. Efficient NPN classification is valuable in fields such as logic synthesis, quantum computing, and information theory. However, exact NPN classification demands exhaustive enumeration of all possible input permutations and negations. Its complexity grows exponentially, making it impractical for larger functions with more inputs. In this paper, we introduce the first learning-based formulation for NPN classification by recasting it as NPN action prediction. Our method represents Boolean functions as AND-Inverter Graphs (AIGs) and applies a bidirectional heterogeneous graph neural network to predict input negations, output negation, and input permutations. To mitigate the non-canonicity of logic networks, we further introduce graph rewriting techniques that reduce structural ambiguity and recover useful symmetries before prediction. Experimental results show that NPN action prediction is learnable, that the resulting canonicalization quality improves over heuristic baselines, and that on practical benchmarks our method approaches exact methods on tractable cases while scaling to functions with up to 16 inputs.