Compositional Logical Explanations for Individual Neurons

This direction is merged into another direction: polysemanticity. Its last version stays readable and citable here.

Version 1 of 114 papers18 conceptsfrozen 2026-10-04

For years, the gold standard for understanding a neural network was to find "the" concept a neuron detects. We looked for the "dog neuron" or the "face neuron." However, individual neurons are rarely so cooperative. A single neuron might fire for dogs, but also for wolves, while strictly avoiding cats.

To capture this complexity, researchers have shifted from labeling neurons with single words to describing them with compositional logical formulas. By combining primitive concepts using Boolean operators like AND, OR, and NOT, we can translate high-dimensional activations into human-readable symbolic logic.

The Neuron as a Boolean Function

The core intuition behind this research is that a neuron acts as a filter that partitions the input space. Instead of asking "What is this neuron's name?", researchers like Jesse Mu ask "What logical rule defines its activation?"

In Compositional Explanations of Neurons, the behavior of a neuron is approximated by a formula such as (water OR river) AND (NOT blue). This approach recognizes that neurons often function as specialized logical operators. A neuron might refine a broad category (disjunction/OR) through specific constraints (conjunction/AND) or exclusions (negation/NOT).

This framing reveals a stark difference between domains: while interpretable compositional neurons in vision models often indicate robust feature learning, in language models, they frequently expose "cheating" heuristics—shallow logical shortcuts the model uses to solve tasks without true understanding.

Searching the Space of Explanations

How do we find the "best" formula for a neuron among trillions of possible combinations? The problem is essentially a search task.

  1. Define Primitives: Start with a library of basic concepts (e.g., "striped," "carbon ring," "velocity").
  2. Measure Alignment: Quantify how well a formula matches a neuron's activation. Common metrics include the Jaccard similarity (Intersection over Union) between the neuron's binary activation mask and the formula's truth values, or the AUC (Area Under the Curve) as proposed by Kirill Bykov in the INVERT framework.
  3. Search: Most frameworks, such as those developed by Han Xuanyuan for Graph Neural Networks, use beam search. This algorithm keeps a small set of the most promising candidate formulas and iteratively expands them by adding new operators and concepts.

While beam search is efficient, it is a heuristic. Recent work by Biagio La Rosa and Leilani H. Gilpin in Guaranteed Optimal Compositional Explanations for Neurons shows that beam search can miss the true optimal explanation up to 40% of the time. They introduced pruning algorithms that can mathematically guarantee the discovery of the most accurate logical description.

A Universal Language for Interpretability

This compositional approach has proven to be a "universal solvent" for interpretability across different architectures:

  • Graph Neural Networks (GNNs): Han Xuanyuan and Pietro Lio demonstrated that GNN neurons act as concept detectors for structural properties, like identifying specific chemical rings in molecules.
  • Reinforcement Learning (RL): In complex environments like LunarLander, Zeyu Jiang showed that neurons represent complex semantic meanings like (height near ground) AND (high velocity), effectively decoding the agent's internal strategy.
  • Vision Models: By using "open vocabulary" segmentation, La Rosa and Gilpin allow users to probe neurons for arbitrary concepts without being limited to pre-defined datasets.

From Neurons to Circuits

While much of this work focuses on individual neurons, the ultimate goal is understanding how these logical units aggregate. Michael Hanna explored this in the context of GPT-2's mathematical abilities, finding that sharp logical cutoffs (like determining if one number is greater than another) emerge from the collective aggregation of many neurons, each providing an imperfect piece of the logical puzzle.

By treating neurons as symbolic building blocks, we move away from seeing neural networks as inscrutable black boxes and toward seeing them as complex, executable programs written in the language of logic.

Papers in this version

History & citationVersion 1 · 2026-10-04

Merged into another direction · Permanent link

View frozen version 1

Cite this direction

Latest version (a living page):

@misc{lacuna_compositional_logical_explanations_for_i_c34bef6c,
  title = {Compositional Logical Explanations for Individual Neurons},
  author = {{Lacuna}},
  howpublished = {Lacuna research direction},
  year = {2026},
  url = {https://lacuna.tiptreesystems.com/direction/compositional-logical-explanations-for-individual-neurons/rdr_c34bef6cb8f94fdf8647ab052fade204},
  note = {Latest version of a living research direction; cite a version for a fixed text. Accessed 2026-12-06},
}

This exact version (version 1, frozen text):

@misc{lacuna_compositional_logical_explanations_for_i_c34bef6c_v1,
  title = {Compositional Logical Explanations for Individual Neurons},
  author = {{Lacuna}},
  howpublished = {Lacuna research direction},
  year = {2026},
  url = {https://lacuna.tiptreesystems.com/direction/compositional-logical-explanations-for-individual-neurons/rdr_c34bef6cb8f94fdf8647ab052fade204/v/1},
  note = {Version 1, frozen 2026-10-04. Accessed 2026-12-06},
}