LogicCBMs: Logic-Enhanced Concept-Based Learning

WACV 2026

1IIT Hyderabad, 2Microsoft Research, 3KLA
LogicCBMs teaser

LogicCBMs introduce differentiable logic gates into concept-based models.

Abstract

Concept Bottleneck Models (CBMs) provide a basis for semantic abstractions within a neural network architecture. Such models have primarily been seen through the lens of interpretability so far, wherein they offer transparency by inferring predictions as a linear combination of semantic concepts. However, a linear combination is inherently limiting. So we propose the enhancement of concept-based learning models through propositional logic. We introduce a logic module that is carefully designed to connect the learned concepts from CBMs through differentiable logic operations, such that our proposed LogicCBM can go beyond simple weighted combinations of concepts to leverage various logical operations to yield the final predictions, while maintaining end-to-end learnability. Composing concepts using a set of logic operators enables the model to capture inter-concept relations, while simultaneously improving the expressivity of the model in terms of logic operations. Our empirical studies on well-known benchmarks and synthetic datasets demonstrate that these models have better accuracy, perform effective interventions and are highly interpretable.

Approach

We introduce LogicCBMs, a technique to introduce logic operations into concept-based learning models in an end-to-end differentiable manner. As shown in the below figure, we introduce a logic module (which can consist of multiple logic gate layers) following the concept encoder to extract logical predicates, which are then sent to a classifier. There are two steps involved to learn predicates: (i) Concept pairing, and (ii) Differentiable logic learning. We introduce two weight matrices for this: a concept pair matrix \( CP_{p×k} \) and a logic gate matrix \( G_{p×q} \).


LogicCBMs architecture


In order to determine the concept pairs, we extract the two concepts with the highest weight per row, which gives us a set of \( p \) concept pairs. Since logic gates are by themselves non-differentiable operations, they pose a constraint in incorporating them into end-to-end learnable architectures. In order to overcome this constraint, we use t-norms, which are the fuzzy versions of logic gates to allow differentiability and backpropagation while passing the pairwise activations of the concept encoder through the logic layer. For each of the p logic neurons, we compute all \( q \) fuzzy logic operations on the concept pair assigned to it and learn a probability distribution to represent how important a logic gate is for that concept pair. The probability distribution for each logic neuron is learned by the G matrix.




CLEVR-Logic Dataset

Real-world datasets do not have explicit logic supervision, so it is not straightforward to assess the correctness of the logic. So, we propose a new variant of CLEVR: CLEVR-Logic, where we specify the class-level logic and use it to generate each image. In CLEVR-Logic, concepts are CLEVR objects (sphere, cone, cube, cylinder) and classes are specified as logical operations among these objects. For example, sphere \( \oplus \) cone could be one class which has images that exclusively contain either a sphere or a cone. CLEVR images are then generated per class following the class-specific logic.

CLEVR-Logic dataset visualization

CCG Metric

Concept-based interpretable models are especially of importance in high-risk scenarios where there may be a high cost associated with an erroneous decision. We hence propose a metric to study CBM-related models in such a worst-case setting. Our evaluation is based on test-time corrections of concepts (or predicates). For each sample, we identify the most misleading concept (or predicate) and turn it off (or on, depending on ground truth for a given example). We then measure the resulting change in the model’s prediction confidence. We term this quantity as the Concept Correction Gain (CCG).

CCG qualitative results

BibTeX

@article{logiccbms,
  author    = {Deepika SN Vemuri and Gautham Bellamkonda and Aditya Pola and Vineeth N Balasubramanian},
  title     = {LogicCBMs: Logic-Enhanced Concept-Based Learning},
  journal   = {Winter Conference on Applications of Computer Vision (WACV)},
  year      = {2026}
}