A general-purpose framework for scientific modeling

Behavior Learning (BL)Learning Hierarchical Optimization Structures from Data

Zhenyao Ma1 Yue Liang2 Dongxu Li3

1 Xiamen University2 University of Tübingen3 Xi'an Jiaotong University

The idea in one sentence

Learn the optimization structure behind the data. BL models observed responses through learnable utility-maximization problems, combining predictive performance with intrinsic interpretability and, in its identifiable variant, principled statistical inference.

Original BL overview figure: human behavior as a utility maximization problem; data and compositional utility yield a conditional distribution; optimization modules enable symbolic interpretation, prediction and generation; Single, Shallow and Deep architectures.
Figure 1.Behavior Learning (BL). (a) Behavior as a utility maximization problem. (b) Learning a compositional utility function from data. (c) Intrinsic interpretability and inference. (d) Architectures spanning a single optimization problem to hierarchical compositions. All figures are reproduced from the BL paper. Click any figure to enlarge.

Abstract

Inspired by behavioral science, we propose Behavior Learning (BL), a novel general-purpose machine learning framework that learns interpretable and identifiable optimization structures from data, ranging from single optimization problems to hierarchical compositions. It unifies predictive performance, intrinsic interpretability, and identifiability, with broad applicability to scientific domains involving optimization. BL parameterizes a compositional utility function built from intrinsically interpretable modular blocks, which induces a data distribution for prediction and generation. Each block represents and can be written in symbolic form as a utility maximization problem (UMP), a foundational paradigm in behavioral science and a universal framework of optimization. BL supports architectures ranging from a single UMP to hierarchical compositions, the latter modeling hierarchical optimization structures. Its smooth and monotone variant (IBL) guarantees identifiability. Theoretically, we establish the universal approximation property of BL, and analyze the M-estimation properties of IBL. Empirically, BL demonstrates strong predictive performance, intrinsic interpretability and scalability to high-dimensional data. Code: MoonYLiang/Behavior-Learning on GitHub; install via pip install blnetwork.

Why do we need Behavior Learning?

Scientific research often grapples with phenomena that resist precise formalization, including human and social domains. Such phenomena are difficult to predict and even harder to falsify through theory alone. Interpretable machine learning offers a promising alternative, yet a long-standing tension remains: predictive performance and intrinsic interpretability often trade off.

Existing efforts to reconcile these goals have made progress. But the BL paper identifies two further limitations that restrict their scientific applicability.

Limitation 01

Insufficient alignment with scientific theories

Interpretability is often added to existing ML methods rather than grounded in scientific structures, such as optimization problems or differential equations.

Limitation 02

Non-uniqueness of interpretations

Non-identifiable models may admit distinct internal explanations for the same observable predictions, complicating ground-truth parameter estimation.

Can we design an interpretable ML framework that mitigates the performance–interpretability trade-off while being scientifically grounded and identifiable?

BL answers this question by returning to a foundational paradigm of behavioral science: utility maximization.

From behavior to optimization

In behavioral science and decision theory, observed outcomes are often modeled as arising from a latent optimization process. Given contextual features \(\mathbf{x}\), an agent chooses a response \(\mathbf{y}\) by solving a utility maximization problem (UMP):

The utility maximization problem
\[\max_{\mathbf y\in\mathcal Y}\; U(\mathbf x,\mathbf y)\qquad\text{s.t.}\quad \mathcal C(\mathbf x,\mathbf y)\leq 0,\quad \mathcal T(\mathbf x,\mathbf y)=0.\]
Utility · \(U\)

The agent's internal preferences or goals.

Inequality · \(\mathcal C\)

Constraints such as limited resources or budgets.

Equality · \(\mathcal T\)

Endogenous belief consistency or exogenous conservation laws.

Although BL is inspired by human behavior, the UMP is not domain-specific. The paper shows that constrained maximization and minimization problems can be equivalently expressed as UMPs, opening the door to applications in economics, statistical physics, evolutionary biology, and other domains involving optimization.

Learning a compositional utility function

BL models responses as sampled from a distribution induced by one UMP or a composition of interacting UMPs. Instead of fitting only a direct mapping from inputs to predictions, it learns the compositional utility \(\mathrm{BL}_{\Theta}(\mathbf{x},\mathbf{y})\), which parameterizes a conditional Gibbs distribution.

Prediction and generation
\[p_{\tau}(\mathbf y\mid\mathbf x;\Theta)=\frac{\exp\!\left(\mathrm{BL}_{\Theta}(\mathbf x,\mathbf y)/\tau\right)}{Z_{\tau}(\mathbf x;\Theta)}.\]

The temperature \(\tau>0\) controls response randomness. As \(\tau\to0\), the distribution concentrates on utility-maximizing responses. This makes the same learned structure useful for both prediction and generation.

Each learnable block is an optimization problem

The compositional utility is constructed from interpretable modular blocks \(\mathcal B\). Each block represents a penalty-based UMP: an objective, reduced by penalties for violating its constraints.

An interpretable BL block
\[\begin{aligned}\mathcal B(\mathbf x,\mathbf y;\theta)={}&\;\lambda_0^\top\phi\!\left(U_{\theta_U}(\mathbf x,\mathbf y)\right)\\[-1pt]&-\lambda_1^\top\rho\!\left(\mathcal C_{\theta_C}(\mathbf x,\mathbf y)\right)\\[-1pt]&-\lambda_2^\top\psi\!\left(\mathcal T_{\theta_T}(\mathbf x,\mathbf y)\right).\end{aligned}\]

The implementation uses polynomial feature maps, with tanh for utility, ReLU for inequality penalties, and absolute value for equality penalties. Polynomial terms make objectives and constraints traceable and expressible symbolically.

One problem, or an entire hierarchy

BL composes these blocks into increasingly expressive optimization structures while preserving a clear interpretation of the underlying modules.

BL(Single)

One learnable block. A single UMP with maximal structural transparency.

BL(Shallow)

A modest composition of interacting UMPs, with one or two intermediate layers.

BL(Deep)

Multiple layers of UMP blocks. Their composition forms a hierarchical optimization structure.

Original paper diagram illustrating BL Single, Shallow, and Deep compositions of optimization modules.
The three BL variants, adapted by cropping Figure 1(d).
Interpretation in BL(Deep): bottom-layer modules encode local objectives; higher layers aggregate and coordinate them into coarse-grained optimization structures.
An original paper illustration: micro-level agents interact beneath higher-level agents; each agent is a UMP, with layers describing hierarchical coordination.
Figure 2.Hierarchical interpretation. Each block is an interpretable agent solving a UMP; upper layers aggregate and coordinate lower-level structures.

Expressivity, interpretability, and identifiability

BL is designed to unify three objectives: predictive performance, intrinsic interpretability, and statistically meaningful identification. Its theoretical results clarify what each guarantee requires.

Universal approximation of BL

For compact input and output domains and a strictly positive continuous conditional density, a sufficiently expressive finite BL architecture can approximate the target conditional distribution arbitrarily closely in uniform conditional KL divergence.

\[\sup_{\mathbf{x}\in\mathcal X}\mathrm{KL}\!\left(p^\star(\cdot\mid\mathbf{x})\,\|\,p_\tau(\cdot\mid\mathbf{x};\theta^\star)\right)<\varepsilon.\]

Theorem: Universal Approximation of BL. Required depth and width may depend on the approximation tolerance.

Identifiable Behavior Learning (IBL)

Interpretability alone is not identification. To address non-unique parameter explanations, the paper introduces IBL, a smooth, monotone variant of BL. IBL replaces the standard penalty nonlinearities with differentiable alternatives, including softplus and a squared equality penalty.

A practical IBL block
\[\begin{aligned}\mathcal B^{\mathrm{id}}(\mathbf x,\mathbf y)={}&\lambda_0^\top\tanh\!\left(\mathbf p_u(\mathbf x,\mathbf y)\right)\\&-\lambda_1^\top\operatorname{softplus}\!\left(\mathbf p_c(\mathbf x,\mathbf y)\right)\\&-\lambda_2^\top\mathbf p_t(\mathbf x,\mathbf y)^{\odot2}.\end{aligned}\]

Identifiability of IBL

Under the paper's atomic injectivity, linear-independence, and minimal-representation assumption, IBL(Single), IBL(Shallow), and IBL(Deep) are identifiable in the parameter quotient space: parameters are determined up to the specified equivalence class.

Under additional conditions, the paper establishes consistency, universal consistency of the learned conditional distribution, asymptotic normality, and asymptotic efficiency.

These guarantees are conditional theoretical statements, not claims that an arbitrary deep BL parameterization is uniquely recovered from every finite dataset. See the paper for exact assumptions and proofs.

What does BL learn in practice?

The paper examines prediction, symbolic and hierarchical interpretation, scalability to high-dimensional inputs, and penalty-based constraint enforcement.

1. Predictive performance on tabular data

Across 10 datasets and 10 baseline models, BL reaches first-tier predictive performance. In the paper's comparison, it achieves the strongest results among the intrinsically interpretable methods, and BL(Shallow) surpasses the MLP baseline.

BL and baseline box-and-whisker plots of relative AUC, F1-Macro improvement, and average F1-Macro ranks on ten datasets.
Figure 3.Performance on standard prediction tasks. Relative AUC and F1-Macro gains, and mean F1-Macro ranks, against the baselines from the original paper.

2. From a learned model to a symbolic UMP

On the Boston Housing dataset, BL(Single) is interpreted as a representative buyer's optimization problem, with explicit preference, budget, and belief terms. A shallow BL[2,1] recovers economic-sensitive and location-sensitive preference types; BL[5,3,1] reveals a deeper micro-to-macro hierarchy.

Original paper multi-panel case study: BL Single yields polynomial contributions and symbolic utility, constraints and beliefs; shallow and deep models illustrate hierarchical representative buyers.
Figure 4.Interpreting BL on Boston Housing. A symbolic single-UMP interpretation, two-layer preference aggregation, and a three-layer micro-to-macro hierarchy; applications to other scientific hierarchies are also illustrated.

For instance, the paper reports a simplified utility polynomial containing the interaction between housing price and room count:

Example: recovered symbolic preference terms
\[\mathbf p_u\approx-0.56P^2-0.6\mathrm{RM}+0.57\mathrm{RM}\cdot P+\widetilde{R}_u.\]

The omitted terms are absorbed into \(\widetilde{R}_u\); this is an approximate extracted expression, not a claim of exact structural identification.

3. Scaling to image and text inputs

With parameter-matched energy-based MLP (E-MLP) comparisons, BL shows comparable in-distribution accuracy on image tasks and improved in-distribution accuracy across the tested text tasks. Out-of-distribution detection is dataset-dependent: BL does better on Yelp, while E-MLP performs better on AG News. BL also reports favorable calibration; training time is generally somewhat higher.

Original paper BL vs energy-based MLP results for in-distribution accuracy and out-of-distribution AUROC, for image and text datasets at different depths.
Figure 5.High-dimensional inputs. Accuracy and OOD AUROC trade-offs at network depths 1–3 on image and text tasks.

4. Does the learned penalty enforce constraints?

In a 64-dimensional energy-conservation diagnostic, the paper isolates BL's equality-penalty mechanism. At the tested finite temperatures, conservation violations generally decline with decreasing temperature or increasing penalty weight.

Four plots: mean and 95th-percentile violations, and near-feasible fractions, varying temperature and penalty coefficient in the energy conservation experiment.
Figure 6.Penalty-based constraint enforcement. Constraint violations and near-feasible sample fractions as the temperature and penalty scale change.

Reading a learned hierarchy as science

The paper describes a bottom-up interpretation of BL(Deep). Each block is a local optimization problem; higher layers summarize, reorganize, and coordinate the structures learned by lower layers. Analogies include organizational hierarchies, representative agents, and coarse-graining in statistical physics.

Raw input features→Micro-level UMP blocks→Coarse-grained constructs→Macro-level systems

In this view, BL is not merely a predictor with post-hoc explanations: its interpretable optimization blocks are the model itself. The resulting hierarchies offer candidate scientific descriptions to inspect, compare, and test.

Code and installation

The authors provide the implementation on GitHub. The package can be installed from PyPI with the command given in the paper:

Terminal
pip install blnetwork

For training examples, configurations, and updates, see the official repository. The paper PDF is available on arXiv.

Optimization as a Common Language Across Sciences

The framework developed in the paper raises a broader scientific question: how can models learned from observations be connected to the principles used to explain those observations? Across behavioral science, economics, and physics, objectives and constraints provide a common mathematical language, even when the phenomena and interpretations differ. Specifying these structures in advance can be difficult; learning only an input–output mapping leaves their scientific meaning unresolved. Behavior Learning approaches this difficulty by learning interpretable optimization structures through a compositional utility function. The following research questions connect this modeling perspective to disciplinary concerns, while distinguishing mathematical representation, statistical identification, and empirical evidence.

Can latent objectives and constraints underlying human behavior be learned from data?

Behavioral science often represents actions as solutions to a utility maximization problem (UMP), conditional on an environment. BL makes the objective and constraint terms learnable, allowing observed responses to inform a symbolic optimization structure. This provides a model of behavior whose components can be inspected and tested. Its interpretation remains a modeling hypothesis: fitting a UMP does not establish that every observed action results from an actual optimization process.

How can decision-making be modeled through interpretable utility-based mechanisms?

Decisions may vary even under similar observed conditions. In BL, a conditional Gibbs distribution assigns greater probability to responses with higher compositional utility, while temperature controls stochasticity. This connects utility-based representations with probabilistic choice and preference learning. The learned utility describes response probabilities within the model; interpreting its terms as psychological preferences requires evidence beyond predictive agreement.

Can economic utility functions and constraints be learned without fully specifying them in advance?

Economic structural modeling connects observations to objectives, resource limits, and beliefs. BL retains these optimization roles while learning their parameterized expressions within a chosen basis and architecture. The Boston Housing case study illustrates a representative-buyer interpretation and hierarchical preference aggregation. It demonstrates how a fitted model can be read economically.

Can an underlying optimization problem be inferred from observed solutions?

Forward optimization computes solutions from a specified objective and feasible set; data-driven inverse optimization learns aspects of that problem from observations. BL approaches the inverse task through distributional modeling, jointly learning utility and constraint terms. BL(Single) represents one UMP, whereas shallow and deep architectures represent hierarchical compositions. The UMP formulation accommodates constrained maximization and minimization; recovering a fitted structure is distinct from identifying its generating mechanism.

Can a predictive model be intrinsically interpretable and statistically identifiable?

BL locates intrinsic interpretability in its symbolic optimization blocks. Identifiability requires further restrictions: the smooth, monotone variant IBL is identifiable in a parameter quotient space under atomic injectivity, linear independence, and minimal-representation assumptions. Its consistency results require additional conditions, with parameter recovery requiring correct specification. These theoretical guarantees distinguish uniqueness within a model class from unconditional recovery of a true scientific mechanism.

What connects utility maximization, energy minimization, and Gibbs distributions?

Taking energy as the negative of compositional utility makes utility maximization correspond to energy minimization, with the same conditional Gibbs distribution at a given temperature. BL shares Gibbs modeling and, for continuous responses, denoising score matching with energy-based models. Its structural distinction is an explicit composition of symbolic UMP blocks, giving the learned energy landscape an optimization-based interpretation.

How can learned objectives and constraints connect to variational formulations in physics?

Constrained optimization offers a conceptual connection to physical models expressed through objectives and admissibility conditions. BL represents these roles through utility and penalty terms, and its energy-conservation diagnostic examines constraint enforcement under finite-temperature Gibbs sampling. This motivates investigating suitable variational formulations; it does not establish equivalence to all physical variational principles or a general theory of variational free-energy learning.

How might local objectives and interactions be represented in hierarchical social systems?

Hierarchical composition allows lower-level UMP blocks to encode local objectives and higher-level blocks to aggregate their outputs. The paper interprets this organization through representative agents, coordination, and a coarse-graining analogy. Such multi-level descriptions suggest a modeling perspective for social organizations. The learned hierarchy is an inspectable feature of the model, whose correspondence to social agents or causal relationships requires independent validation.

Can optimization-based representations help model adaptation and evolutionary systems?

Where an adaptive process admits a useful optimization description, learnable objectives and constraints could provide a way to formulate and compare candidate models. The paper identifies evolutionary biology as a future research direction, without presenting biological validation. This potential application depends on the process and observational setting; it does not assume that evolution universally maximizes a single global fitness function.

Can one mathematical language connect behavioral, social, and physical systems?

The universality of the UMP formulation provides a shared representation for optimization problems, while BL supplies learnable hierarchical compositions and conditional distributions. Its approximation theory concerns representational capacity under stated assumptions. Together, these results support a common language for scientific modeling, but empirical adequacy must be assessed separately in each domain through observations, substantive interpretation, and tests of the proposed explanation.

Across these questions, the scientific opportunity is to express a learned model in terms of objectives, constraints, and their composition, so that its interpretation can be examined alongside its predictions. The manuscript establishes a framework and specific theoretical and experimental results; extending those results to new systems requires domain knowledge, appropriate statistical assumptions, and empirical tests.

Beyond Behavior Learning

Behavior Learning (BL) provides a general-purpose foundation for learning interpretable optimization structures from data. Building on this foundation, subsequent research explores new learning methods, scientific discovery frameworks, and applications across disciplines.

The following works trace a growing research lineage rooted in BL, where new ideas build upon existing foundations, branch into different directions, and open further possibilities for scientific modeling and discovery.

Citation

For the complete framework, proofs, experimental protocols, and discussion, please refer to the manuscript.

ICLR proceedings / arXiv
@inproceedings{ZhenyaoBehaviorICLR,
 author = {Ma, Zhenyao and Liang, Yue and Li, Dongxu},
 booktitle = {International Conference on Learning Representations},
 editor = {C. Vondrick and B. Hariharan and C. Raffel and L. Pinto and D. Yang and A. Faust},
 pages = {115378--115425},
 title = {Behavior Learning (BL)},
 url = {https://proceedings.iclr.cc/paper_files/paper/2026/file/bbb397739546de027bc81a2c2a8fb119-Paper-Conference.pdf},
 volume = {2026},
 year = {2026}
}

@misc{ma2026behaviorlearningbllearning,
      title={Behavior Learning (BL): Learning Hierarchical Optimization Structures from Data},
      author={Zhenyao Ma and Yue Liang and Dongxu Li},
      year={2026},
      eprint={2602.20152},
      archivePrefix={arXiv},
      primaryClass={cs.LG},
      url={https://arxiv.org/abs/2602.20152},
}
Paper figureOpen full image ↗  
Enlarged figure