Paper: Boolformer: Symbolic Regression of Logic Functions with Transformers (ICLR-2024)

Reviewer comment (Novelty):
The major weakness of the paper is the positioning w.r.t. the state of the art. Being the method very simple, clearly highlighting the novelty should have been a priority.

Author response:
We thank the reviewer for their constructive feedback. 

Concerning the novelty of this paper and comparisons, we refer to our introductory comments. 
Similarly, the idea of generating synthetic datasets has been explored for symbolic regression of real-valued functions, but never in the Boolean setting.

Reviewer comment (Novelty):
While the paper discusses many related areas, it is very unclear what is new in the proposed approach. For example, the section on "symbolic regression" in the related work, which is the closest area to the proposed approach ("Symbolic regression of logic functions"), is simply a list of papers. The approach is not compared with these approaches neither experimentally nor even theoretically.

Author response:
We thank the reviewer for their constructive feedback. 

Concerning the novelty of this paper and comparisons, we refer to our introductory comments. 
Similarly, the idea of generating synthetic datasets has been explored for symbolic regression of real-valued functions, but never in the Boolean setting.

Reviewer comment (Experiments):
Experiments in the noiseless regime do not compare Boolformer with any baseline, making it quite hard to understand how hard the task is overall.

Author response:
We thank the reviewer for their constructive feedback. 

We would also like to emphasize that the problem studied in the noiseless setting, also known as the Minimum Circuit Size Problem, is an NP-hard problem which no existing methods can currently solve, including ours. This section is more theoretical in nature, and was precisely designed to probe the ability of our model to generalize (i.e., prove that memorization does not occur, as discussed more in App. B) as well as its limitations of our model – we will clarify this in the revised manuscript.

Reviewer comment (Experiments):
Experiments in the noisy regime have comparisons but only with very unrelated approaches (generic ML models or specific to the dataset).

Author response:
We thank the reviewer for their constructive feedback. 

Crucially, the core contribution of this work in terms of practical relevance lies in the noisy setting, where we provide extensive comparisons.
See more details in the introductory comments.

Reviewer comment (Novelty):
The problem statement in the introduction does not match the solution. In Section 1, citing (Abbe et al., 2022), the authors point out that Transformer learns complex models in terms of the Fourier spectrum, resulting in poor generalization performance when samples are insufficient. As a contribution, Section 1.1 claims that it is robust to noisy and incomplete observations. However, the Boolformer proposed in this paper is a relatively natural application of the Transformer, and there is no redesign from a Fourier spectrum perspective or other robustness innovations.

Author response:
W1-W2: We expand our responses to clarify - sorry if the previous responses were limited. 
The reviewer's comment "In Section 1, citing (Abbe et al., 2022), the authors point out that Transformer learns complex models in terms of the Fourier spectrum, resulting in poor generalization performance when samples are insufficient. As a contribution, Section 1.1 claims that it is robust to noisy and incomplete observations. However, the Boolformer proposed in this paper is a relatively natural application of the Transformer, and there is no redesign from a Fourier spectrum perspective or other robustness innovations." is not quite an accurate re-transcription of the paper's referencing to Abbe et al. nor the current paper's contributions. Let us try to clarify these:

1. Abbe et al. shows (experimentally for Transformers and provably for simpler models) that if you train a classic Transformer on a sparse Boolean function, with incomplete data in the sense that you do not sample part of the distribution domain (unseen domain) while you sample heavily the complement (seen domain), then the model tends to learn a function that interpolates correctly the data on the seen domain, and on the unseen domain, the paper characterizes which function the Transformer learns after l2-loss training: the function that has least degree profile in the Fourier spectrum (i.e., least Fourier L2 norm on the high-degree coefficients). This is not necessarily a complex function in the Fourier domain in terms of having for instance large noise sensitivity, as in fact the Transformer minimizes the energy or high degree monomials, but it can produce a complex function in the following sense: 

Consider as an example a target function on many variables but simple in the sense that it is a symmetric decision tree of low depth on few active variables, such as the majority on the first 3 coordinates x1x2+x2x3+x1x3 (or (z1+z2+z3-z1z2z3)/2 in Fourier domain, where zi=(-1)^xi). Assume now that the unseen domain is captured by the condition that we never see x1,x2 to be both 1. Then the transformer will learn a function close this: z1/2+z2/2+z3-z1z3/2-z2z3/2 . The explanation? The paper shows the latter function has least Fourier degree profile and still interpolates the seen data correctly. However this function is more "complex" than the original target function in the sense the Transformer want to both interpolate the seen data and minimize the Fourier degree profile with the unseen "holes", producing weird coefficient mixtures like above that break for instance the symmetry of the function and also loose for instance the Boolean nature of the function output in this case.

2. The Boolformer can indeed mitigate this issue; so the introduction gives a valid motivation, but the reviewer is also correct that this first paper about Boolformer does not investigate this specifically and in fact our contributions do not list this; this is listed in our future directions. Instead this paper focuses on more classic noise setting such as limited sample complexity or label noise. This is not the same type of "noise" setting captured by Abbe et al (with the above "generalization on the unseen (GOTU)" setting, that is more about OOD. In this paper we focus on showing that Boolformers do fairly well on specific benchmarks and concrete applications, with a valuable tradeoff in accuracy/time complexity. However the two problems are also not completely unrelated, as the reasons for which Boolformers perform fairly well on these specific tasks and why they would help on GOTU is expected to be the same: the power of Boolformer is that we can better "control" the implicit bias of the model through the data generation process. Let us clarify this:

In the Boolformer setting, we *first sample an analytical function that has structurel properties that we believe are useful for the task at end*. For instance, we sample low-depth or low-width formula trees, possibly with other features such balanced degrees. By doing so, we can "engineer" the types of analytical formula that we want the model to have biases towards. Then we produce samples from such functions (to create the training set) and then we ask the Boolformer to produce a *token sequence that describes directly the analytical formula*. First one can see that this forces the function learned by the Boolformer to have Boolean output for instance, avoiding already that holes in the sampling domain could break this. Second, we can hope that the "simplicity" here is no longer with respect to the "least Fourier degree profile" (as described above) but w.r. to the generative model bias, which can be completely different (hopefully better but also possibly bad if the generative model is bad). 

So in that sense it is not accurate to say that "there is no redesign from a Fourier spectrum perspective or other robustness innovations"; there is indeed due to the above reason.

Reviewer comment (Experiments):
Due to the design of the method, it can only accept datasets with relatively few variables or small scale. This is acknowledged by the authors in section 5, but since there are currently proposals such as Transformer that can accept long series, it would have been easy to consider improving the limitation.

Author response:
Thank you for bringing up this important question, which indeed deserves clarifications. To extend our discussion on this: even if we were to use a linear attention method (which would likely be very detrimental as the attention maps shown in the appendix are particularly non-local and dense), the scaling would be nontrivial as the number of input points remains in the worst-case exponential in D. More generally, the design choice for improving long context prediction is not critical to our contribution since our contribution is intended to show the promise of symbolic regression for boolean circuits rather than to exhaustively search the right architecture for scaling.

Reviewer comment (Theory):
For example, if the correct answer is [AND, X_1, NOT, X_2], then [AND, NOT, X_2, X_1] is also equivalent. The fact that the system is learned by cross-entropy means that it is unclear how a valid cross-entropy can be calculated when there are multiple correct answers in this way.

Author response:
This is an interesting point which we will also discuss more. In fact, it turns out that the fact that multiple expressions can evaluate to the same function is not a problem in our setup, and can in fact be beneficial as a form of data augmentation. Indeed, our model learns these invariances, as evidenced by Appendix G, which shows the candidates obtained via beam search : the first eight candidates are all valid formulas, written in different ways (and in all cases, very compact).
In the context of symbolic regression, this aligns with the observation made in the Appendix of [1] that removing this equivalence via deterministic simplification rules does not yield any performance improvements.
The fact that cross-entropy can handle expressions with multiple possible formulations is also observed in many other fields, e.g. in machine translation, where beam search also reveals the equivalent translations of a given sentence.

Reviewer comment (Presentation):
In the radar charts in Figure 7(a), the different methods are plotted among different axes, making it difficult to understand the comparison between those methods. If the radar chart is used to make comparisons between methods, it would be better to have as many axes as the number of experimental settings, such as the number of genes, and plot entities for each method. Alternatively, a table or a bar chart like Figure 7(b) is easier to compare methods.

Author response:
We thank the reviewer for these very valuable remarks. For the radar plots, we reused the formatting of the authors of the benchmark [2] for maximal consistency, but will also add some bar charts.

[1] d’Ascoli et al., Deep Symbolic Regression for Recurrent Sequences, ICML 2021

[2] Žiga Pušnik, Miha Mraz, Nikolaj Zimic, and Miha Moškon. Review and assessment of boolean approaches for inference of gene regulatory networks. Heliyon, pp. e10222, 2022.

Reviewer comment (Evaluation):
It would be good to have some analysis on which type of tasks is solvable by this method vs. others.

Author response:
About the type of tasks solvable by this method : we agree that the paper can benefit from further clarifications. Generally speaking, our method is well-suited for tasks which (i) concern tabular data (structured features) and (ii) where the mapping from input to target can be expressed by a Boolean formula of reasonable complexity. This is the reason we considered the PMLB database, which is arguably the most extensive set of problems with tabular data. As briefly discussed in the results paragraph of Sec 4.2, we see that our method shines particularly in logical tasks, and is less good for other types of datasets. We will extend the discussion on this.

Reviewer comment (Presentation):
Can you explain better Figure 17 from Supplementary Material which displays embeddings?

Author response:
- "Figure 17, embeddings, seem not to be grouped by the number value; as within a cluster there's many points with a different color. What do you think clusters represent?"  

Thank you for bringing up this interesting question and reading all the way to the end of the appendix! Given how challenging it is to interpret a 16-dimensional hypercube simply with a t-SNE representation, we preferred not to speculate too much about this figure. But indeed, there are some very interesting trends: the points of the hypercube are hierarchically organized into 4 clusters, each containing 4 subclusters, each containing 4 subclusters... at which point the points are superimposed and indistinguishable. Motivated by the reviewer's question, we looked into this in more detail by investigating what happens in the 5-dimensional hypercube, but were unable to extract a more detailed logic. Here is a figure of what we obtain, in case the reviewer has an idea for an interpretation: https://www.dropbox.com/scl/fi/feb20b9mn1oukhn7ki3ov/embeddings.pdf?rlkey=ly44fylgluytsfz8x8fciy0cw&dl=0.

Reviewer comment (Reproducibility):
Which part of transformer do you extract for the shown embedding vectors (is it only the last token state, or all tokens, etc.)?

Author response:
Concerning the question on the embeddings: thanks for noticing that this deserves clarifications. We display the outputs of the “embedder” module, which is a fully-connected network which maps D-dimensional vectors to a single embedding. The inputs are all the points in the 10-dimensional hypercube, sorted by color from 0000000000, 0000000001, 0000000010… 1111111111.

Reviewer comment (Reproducibility):
What exactly are the inputs that you use to construct the shown embedding, and why do you make such choice?

Author response:
Concerning the question on the embeddings: thanks for noticing that this deserves clarifications. We display the outputs of the “embedder” module, which is a fully-connected network which maps D-dimensional vectors to a single embedding. The inputs are all the points in the 10-dimensional hypercube, sorted by color from 0000000000, 0000000001, 0000000010… 1111111111.

Reviewer comment (Experiments):
It might not be that surprising that Boolformer is faster on GRNs tasks. After all, it has been trained for a long time and the training data could have covered what it needed in these tasks. I am curious, however, is there a similar comparison of efficiency in the noiseless regime?

Author response:
We thank the reviewer for their positive feedback.  
Concerning the comparisons in the noiseless regime, we would like to defer the reviewer to the general comments.