Manuscript Offprint
arXiv:2610.32584Contextual Decision Making: Predictive or Generative
L. Jeff Hong
Department of Industrial and Systems Engineering, University of Minnesota, Minneapolis, MN 55455, U.S., lhong@umn.edu
Weihuan Huang
School of Management & Engineering, Nanjing University, Nanjing 210093, China, hwh@nju.edu.cn
Xinyao Li
Department of Industrial and Systems Engineering, University of Minnesota, Minneapolis, MN 55455, U.S., li003784@umn.edu
Abstract. Contextual decision making uses observed covariates to guide decisions under uncertainty. Two natural approaches are predict-then-optimize (PtO), which learns the conditional expected objective, and generate-then-optimize (GtO), which learns conditional uncertainty and optimizes using generated scenarios. We study when each approach is preferable by examining how the choice of learning target affects statistical accuracy and optimization tractability. Although PtO learns a narrower target, our regret bounds show how differences in smoothness can offset GtO's additional dimensional burden. Exploiting smoothness also raises an optimization tradeoff: within the class of nonnegative-weight PtO methods studied, a lower bound limits the gains from additional smoothness, while more flexible methods may introduce signed weights and lose the guarantee of preserving convexity. GtO preserves scenario-wise convexity, but requires learning a richer object and generating scenarios for optimization. Synthetic experiments and a real case study illustrate how these tradeoffs vary with data availability and problem structure. Together with the scope for reusing a model across tasks, our findings provide practical guidance for choosing between the approaches without identifying a universal winner.
Key words: contextual stochastic optimization; predict-then-optimize; generate-then-optimize; conditional generative models; statistical efficiency; convexity preservation.
1. Introduction
Modern operating environments provide decision makers with rich contextual information. Retailers observe promotions, recent sales, and local market conditions before replenishing inventory. Logistics providers use congestion and demand signals to plan deliveries and reserve capacity. Service systems use workload forecasts and current operating conditions to make staffing decisions, as illustrated by feature-based approaches to hospital nurse staffing (Ban and Rudin 2019). Healthcare providers use patient characteristics and clinical information to personalize treatment and allocate care resources (Shen et al. 2021). In each setting, the challenge is to turn information available before a decision into an effective response to an uncertain outcome. Contextual stochastic optimization (CSO) provides a framework for doing so by minimizing expected cost conditional on the observed context (Bertsimas and Kallus 2020, Sadana et al. 2025).
Let X denote the context, Y the uncertain outcome, z the decision, and the cost. After observing , the decision maker seeks to minimize the conditional expected objective
We focus on convex CSO: the feasible decision set is convex, and the cost is convex in z for each context and outcome. The conditional expected objective is consequently convex as well. The difficulty is that this objective is unknown and must be learned from historical observations of contexts and outcomes.
Two approaches arise naturally. A predictive approach learns the conditional expected objective and optimizes the fitted objective when a new context is observed (Bertsimas and Kallus 2020). We refer to this approach as Predict-then-Optimize (PtO). A generative approach learns the conditional distribution of Y given X, generates scenarios for the observed context, and optimizes their average cost (Gong et al. 2024). We refer to this approach as Generate-then-Optimize (GtO). For instance, in a retail inventory problem, PtO estimates expected inventory cost, whereas GtO generates demand scenarios under which inventory decisions can be evaluated. PtO concentrates learning on the objective of interest. GtO learns a conditional distribution that can support different objectives involving the same uncertain outcome.
The rise of generative AI makes the generative approach increasingly appealing. Advances in generative modeling provide flexible tools for learning conditional distributions and producing scenarios (Bond-Taylor et al. 2022, Yang et al. 2024). Further progress may make these tools easier to develop and use, while creating opportunities to incorporate qualitative context, such as descriptions of operating conditions or expert judgments expressed in language. As these capabilities develop, more organizations may be able to use generative models in operational decision making. Yet the ability to generate realistic scenarios does not by itself establish that learning a conditional distribution is preferable to learning the expected objective. The choice still depends on the data available, the optimization problem to be solved, and the decisions the model is intended to support.
This motivates our central question: When should contextual decision making be predictive, and when should it be generative? Both approaches can be applied to many of the same decision problems, but their relative appeal is not immediately clear. Learning the expected objective focuses on what a particular task requires, while learning the conditional distribution provides scenarios that can be used to evaluate decisions. We seek to understand when each approach is useful and to develop practical guidance for choosing between them. As generative AI makes scenario generation more accessible, this choice will become increasingly important.
The first consideration is statistical: how difficult is it to learn the expected objective or the conditional distribution from the available data? PtO avoids estimating how probability is distributed across outcomes, which can be valuable when data are limited or the uncertain outcome is high-dimensional. GtO must account for both the context and the uncertain outcome when learning the conditional distribution. Dimension alone, however, does not determine the difficulty of learning. Smoothness also matters because it allows observations at nearby contexts to inform one another, a central principle in nonparametric regression and conditional-density estimation (Stone 1982, Li et al. 2022). The conditional distribution may vary smoothly with the context even when the expected objective changes abruptly because costs depend on thresholds or operating rules. Learning the expected objective can therefore involve fewer dimensions without necessarily being easier.
We examine this tradeoff through bounds on regret, defined as the excess expected cost relative to an optimal decision. For PtO, our bound for kernel ridge regression (KRR) describes how greater objective smoothness can mitigate the effect of context dimension. For GtO, the corresponding analysis accounts for the dimension and smoothness of the conditional distribution, with conditional diffusion models providing a concrete instance (Fu et al. 2024). These results suggest assessing dimension and smoothness together when choosing an approach. PtO is attractive when the expected objective is sufficiently smooth to be learned accurately from the available data. GtO becomes more attractive when the conditional distribution is easier to learn because its greater smoothness compensates for the additional outcome dimension. The bounds explain these competing effects and inform the choice.
The second consideration is computational: how does learning affect the optimization problem that must ultimately be solved? Although the original decision problem is convex, an approximation learned from data need not preserve that property. A broad class of PtO methods fits the expected objective as a weighted sum of observed costs,
where are historical observations (Bertsimas and Kallus 2020, Bertsimas and Koduri 2022). Nonnegative weights preserve convexity. Methods such as KRR can exploit higher-order smoothness but may assign negative weights, so their fitted objectives are no longer guaranteed to be convex. GtO preserves convexity by averaging scenario costs with equal positive weights, but must generate the scenarios and solve the resulting sample average approximation (SAA) problem (Shapiro et al. 2009). The choice of learning method thus affects both statistical accuracy and the computation needed to obtain a decision.
Our analysis makes this connection precise. For the class of nonnegative, covariate-based PtO weighting rules considered, we establish a lower bound of order on worst-case expected regret, where is the context dimension. The bound holds even for arbitrarily smooth objectives in the constructed problem class. Within this class, the nonnegative weights that preserve convexity limit the benefit that additional smoothness can provide. KRR can benefit from higher-order smoothness, but its negative weights may complicate optimization. The extent of that difficulty depends on the cost function: negative weights do not invariably produce a nonconvex or difficult problem. A predictive method should therefore be assessed together with the optimization problem induced by its fitted objective.
For GtO, our regret bound separates the error in learning the conditional distribution from the error caused by using finitely many generated scenarios. Under the stated assumptions, the bound consists of a term proportional to the conditional-distribution learning error and an SAA term of order , where m is the number of generated scenarios. Improving the learned distribution reduces the first error, whereas generating more scenarios reduces the second at additional computational cost. Preserving convexity therefore does not by itself imply faster decisions. PtO is attractive when its fitted objective remains easy to optimize and rapid responses are important. GtO is attractive when retaining the convex structure is valuable and the time available permits scenario generation and optimization. This distinction is particularly relevant when decisions must be made repeatedly under tight response-time requirements.
The third consideration is how broadly the learned model will be used. A model serving one objective can concentrate its learning effort on that task. In practice, however, several operational teams may face the same conditional distribution while making decisions with different objectives or constraints. When data analysis and operations reside in different departments, adapting a model to each objective can also require substantial coordination. GtO offers one way to organize this work: a data team develops a common generative model, and operational teams use its scenarios in their own decision problems. PtO can also support reuse through shared weights, features, or estimated objective components. The relevant question is how much adaptation and coordination each additional use requires. A stable, specialized task makes objective learning appealing, whereas a range of tasks sharing the same conditional distribution increases the value of a reusable generative model. The latter may be worth developing even when it offers no advantage for an individual task.
Taken together, these three considerations provide practical guidance on choosing between PtO and GtO. The choice involves balancing what can be learned reliably, what can be optimized within the available time, and how the model will serve the organization's decisions. Neither approach is preferred in all settings, and an advantage along one of these dimensions may be offset by a disadvantage along another. We draw on the theoretical results and these practical considerations to develop rules of thumb that help decision makers assess that balance.
We use two numerical examples, a contextual newsvendor problem and a product placement problem, to examine the tradeoffs and provide evidence supporting this guidance. We then extend the comparison through a real case study of fresh-retail inventory using operational data from a retail chain. With both continuous and categorical features, this case goes beyond the setting of our theoretical analysis and provides further evidence of the usefulness of our managerial insights in practice.
A related stream of research studies how training can account for the decisions that a learned model will support. Donti et al. (2017) incorporate optimization into task-based and decision-focused learning, while Elmachtoub and Grigas (2022) develop the Smart Predict-then-Optimize framework and the SPO+ surrogate loss. Broader accounts are provided by Mandi et al. (2024) and Sadana et al. (2025). In this paper, PtO refers specifically to learning the conditional expected objective; elsewhere, the term also describes predicting inputs to an optimization model. Our comparison concerns what is learned, while decision-focused training concerns how learning is aligned with decision quality. These questions are complementary, since either an objective model or a generative model can, in principle, be trained using decision-focused criteria. We study the choice of learning target within a framework that separates learning from optimization.
The statistical foundations of our comparison come from nonparametric regression and conditional-density estimation, where smoothness and dimension govern estimation difficulty (Stone 1982, Li et al. 2022). Generative models provide practical methods for learning distributions, including variational autoencoders, adversarial models, normalizing flows, and diffusion models; Bond-Taylor et al. (2022) and Yang et al. (2024) provide reviews. Our conditional-diffusion analysis uses the learning guarantees of Fu et al. (2024), and our retail implementation uses TabCSDI (Zheng and Charoenphakdee 2022). We use these existing methods to study the decision consequences of learning a conditional distribution.
The use of generated scenarios also connects our work to stochastic programming. Scenario construction and reduction have long been used to approximate stochastic optimization problems (Høyland and Wallace 2001, Dupačová et al. 2003). Recent studies use deep generative models to construct decision-relevant scenarios or incorporate optimization objectives into generative training (Pisinger and Hemmati Golsefidi 2026, Wang et al. 2026, Zhao et al. 2026). Our contribution is a comparative analysis of PtO and GtO that connects regret guarantees with preservation of optimization structure and computational requirements. This analysis supports practical guidance for choosing between the approaches and complements research on improving the performance of either one.
The remainder of the paper is organized as follows. Section 2 formulates the problem and performance criteria. Section 3 analyzes weighted PtO methods, and Section 4 develops the GtO regret analysis. Section 5 draws practical guidance from the comparison. Section 6 presents the numerical and empirical studies, and Section 7 concludes. The appendix contains the proofs, implementation details, and supplementary numerical results.
2. Problem Formulation
We consider a convex contextual stochastic optimization (CSO) problem of the form
where is a random vector of covariates taking values in , is a vector of uncertain parameters taking values in and potentially correlated with , is the vector of decision variables with the feasible set , and is a given cost function that is convex in the decision variable . In the offline stage, we have access only to historical data , consisting of observations of . In the online stage, upon observing a new covariate realization , we make an online decision via solving Problem (1). We assume that the offline observations are independent and identical distributed (i.i.d.) copies of , and that the online covariate observed at the decision epoch is an independent draw from the same distribution as the training covariates. We impose the following structural assumptions on the feasible set and the cost function.
Assumption 1. The feasible set is nonempty, convex, and compact. We denote its diameter by . For every , the cost function is convex on , uniformly Lipschitz with respect to , i.e., there exists a constant such that for all and all , we have , and uniformly bounded, i.e., there exists a constant such that for all and , we have .
The assumptions for the feasible set in Assumption 1 is standard in stochastic programming and contextual stochastic optimization to guarantee the existence of minimizers, see, e.g., Shapiro et al. (2009), Bertsimas and Kallus (2020), Bertsimas and Koduri (2022). The convexity assumption for the cost function in Assumption 1 restricts our focus for the convex CSO problem. Assumption 1 also imposes a uniform Lipschitz and bounded condition on the cost function; such conditions are reasonable technical assumptions and used in the literature of contextual stochastic optimization, see, e.g., Bertsimas and Kallus (2020), Bertsimas and Koduri (2022).
Under Assumption 1, the conditional objective is convex for every , uniformly G-Lipschitz continuous in over , and uniformly bounded. Consequently, is continuous on . Since is compact, the set of optimal solutions in Problem (1) is nonempty, compact, and convex for every . We do not require the optimal solution to be unique. Moreover, we impose the following regularity conditions on the conditional objective and the covariate distribution.
Assumption 2. There exists a constant such that is -Lipschitz in , uniformly in , i.e., holds for all and for all .
Assumption 3. The covariates are supported on the hypercube and admit a density with respect to the Lebesgue measure satisfying for all .
For a data-driven decision rule constructed from , we evaluate its performance through the conditional optimality gap (regret)
and, when appropriate, its expected counterpart . For ease of interpretation and comparison across problem instances, we also consider a normalized performance measure based on the regret. Let denote a benchmark decision rule and define its expected regret by . Provided that , we define the relative cost of as
Thus, the relative cost measures the fraction of the benchmark’s optimality gap eliminated by the data-driven decision rule: indicates performance identical to the benchmark, whereas corresponds to the optimal decision. A value of RC closer to 1 indicates that the decision rule performs better than the benchmark, while a negative value of RC indicates that the decision rule performs worse than the benchmark. In the numerical experiments, we use an unconditional SAA — an SAA method for Problem (1) without the condition — as the benchmark and an oracle solution as the proxy for the optimal decision, yielding the equivalent empirical definition reported in Section 6. This relative-cost measure has been widely used as a normalized performance metric for evaluating data-driven decision rules in Problem (1); see, e.g., Bertsimas and Kallus (2020) and Bertsimas and Koduri (2022).
Let denote the conditional distribution function of Y given . The conditional objective can then be written as
Thus, the conditional distribution determines the stochastic information relevant to the decision problem, while data-driven methods may extract and utilize this information at different levels. In particular, one may directly estimate the induced conditional objective , or instead learn the underlying conditional distribution and subsequently construct the objective through generated samples.
These two strategies give rise to two broad paradigms for contextual decision making: a predictive approach, which learns the conditional objective and then optimizes it, and a generative approach, which learns the conditional distribution (or a conditional simulator) and then optimizes using generated scenarios. This distinction raises a fundamental question: How should we choose between the two paradigms? In general, neither is uniformly preferable. Their relative pros and cons depend on both the statistical structure of the underlying problem and the computational properties of the resulting optimization problem. Accordingly, in the following sections, we study the predictive and generative paradigms separately and compare them along two central dimensions: convexity preservation, which concerns whether the learned representation preserves convexity that facilitate the downstream optimization, and statistical efficiency, which concerns how effectively each paradigm exploits the available offline data. Our analysis is intended to identify the problem characteristics under which each paradigm is particularly well suited and thereby provide insightful guidance on the choice between predictive and generative approaches.
3. Predict-then-Optimize
Predict-then-optimize (PtO) is a widely used framework for contextual stochastic optimization (Bertsimas and Kallus 2020, Bertsimas and Koduri 2022, Sadana et al. 2025). Under this paradigm, the conditional objective function is first estimated from historical data and then optimized for a realized covariate . Most PtO methods approximate the conditional objective using a weighted empirical average of the observed costs. Specifically, the estimated objective takes the form
where the weights are determined by the statistical procedure used to estimate the conditional expectation , and the decision rule is obtained by solving .
The estimator in Equation (3) is linear in the observed responses and encompasses a broad class of classical regression methods, both parametric and nonparametric. Examples include ordinary least squares and ridge regression on the parametric side (Hastie et al. 2009), and k-nearest-neighbor regression, kernel and local polynomial regression, smoothing splines, and kernel ridge regression on the nonparametric side (Wahba 1990, Hastie et al. 2009). Within this broad class, we focus on nonparametric methods and, following Bertsimas and Koduri (2022), distinguish between local and global methods.
3.1. Local Methods: Convexity Preservation at the Cost of Statistical Efficiency
Traditional local approximation methods, such as k-nearest neighbors, Nadaraya–Watson kernel smoothing, local averaging, classification and regression trees, and random forests, determines the weights according to the proximity between the historical covariates and the realized covariate ; see Wahba (1990), Hastie et al. (2009). They estimate the conditional objective primarily by pooling information from observations that are locally relevant to . Many commonly used local methods naturally generate nonnegative weights. Some exceptions, such as local linear methods, may produce signed weights, but can be modified to enforce nonnegativity (Bertsimas and Kallus 2020). From an optimization perspective, the property of nonnegative weights is important because it preserves the convexity of estimated objective whenever the cost is convex.
Although local methods therefore preserve convexity of the downstream optimization problem, their statistical efficiency is inherently limited by the curse of dimensionality. These methods rely on locality, assigning substantial weights only to observations close to . As the covariate dimension increases, observations become increasingly sparse in local neighborhoods, making accurate local estimation progressively more difficult. For example, the PtO formulation based on Nadaraya–Watson kernel smoothing estimation with a spherical kernel achieves a decision regret rate of
which deteriorates as the covariate dimension increases; see Wang et al. (2024).
The curse of dimensionality underlying local methods can be understood through the usual bias–variance tradeoff. In high-dimensional covariate spaces, a small neighborhood around typically contains few observations, leading to high variance in the estimated conditional objective. Enlarging the neighborhood increases the effective sample size and reduces variance, but at the cost of incorporating observations farther from , thereby increasing approximation bias when the conditional objective varies with the covariates. As increases, balancing these two sources of error becomes progressively more difficult, which leads to slower estimation of and, consequently, slower convergence of the resulting decision regret.
3.2. Global Methods: Statistical Efficiency at the Cost of Convexity Preservation
To improve performance in high-dimensional settings, global regression methods based on reproducing kernel Hilbert spaces (RKHS) have been employed (Bertsimas and Koduri 2022). Unlike local methods, RKHS-based approaches determine the weights by solving a regularized optimization problem over a function space, which leads to a kernel ridge regression (KRR) estimator under squared loss. Specifically, for each fixed and a given kernel function , KRR estimates by
where is the regularization parameter and is the RKHS induced by the kernel function . By the representer theorem (Wahba 1990, Schölkopf et al. 2001), the resulting estimator can be written as
where the KRR weights , , and . Thus, controls the tradeoff between goodness of fit and regularization, while the resulting KRR weights are generally not restricted to be nonnegative.
This global approach allows the estimator to exploit information from the entire training sample rather than only observations in a local neighborhood. Consequently, it can leverage the smoothness of the conditional objective with respect to the covariates x for each fixed decision z. When exhibits sufficiently high-order smoothness, RKHS-based methods can translate this regularity into faster convergence rates with substantially weaker dependence on the covariate dimension than local methods.
We instantiate the RKHS approach using the Matérn kernel with smoothness parameter , and set . To express the smoothness condition in terms of classical derivatives, we restrict attention to values of for which is an integer. It is well known that the RKHS induced by is norm-equivalent to the Sobolev space (Wendland 2005), equipped with the norm
where is a multi-index with . On the compact domain , any function that is times continuously differentiable belongs to . The regularity required by the RKHS approach can therefore be interpreted as requiring sufficient smoothness of with respect to .
Assumption 4. There exists such that for every , with .
The smoothness index s in Assumption 4 determines the extent to which KRR can exploit the regularity of to improve statistical efficiency. The following result quantifies this effect for the weighted empirical PtO objective constructed using KRR weights, and the proof is provided in Appendix EC.1.1.
Proposition 1. Suppose Assumptions 1–4 hold with and . Let be the weighted empirical PtO objective in Equation (4) constructed using the KRR weights associated with the Matérn kernel . Choosing the regularization parameter , we have
The convergence rate established in Proposition 1 formalizes the statistical efficiency of KRR. As the Sobolev smoothness of the conditional expectation increases, i.e., as grows, the exponent approaches 1/2, thereby progressively weakening the effect of the ambient dimension on the convergence rate. In this sense, KRR-based PtO translates the smoothness of into improved statistical efficiency and mitigates the curse of dimensionality associated with local methods.
However, this gain in statistical efficiency comes at the cost of convexity preservation. Because KRR weights in Equation (4) are obtained through kernel matrix inversion, they are generally sign-indefinite. The presence of negative weights implies that is no longer a nonnegative combination of the per-sample cost . Consequently, even when each is convex in z, the resulting empirical PtO objective in Equation (4) need not remain convex, potentially complicating downstream optimization and increasing its computational burden (see Section 6.3.2 for an example).
Bertsimas and Koduri (2022) observe that the negative KRR weights are typically small in magnitude and propose clipping them at zero to restore convexity. Specifically, each negative weight is replaced by zero, thereby converting the estimated objective into a nonnegative combination of the per-sample cost functions. However, they do not establish theoretical guarantees for the statistical performance of the resulting clipped KRR estimator. In the next subsection, we show that although this clipped KRR method restores convexity, it also reintroduces the curse of dimensionality.
3.3. The Convexity–Efficiency Dilemma
The complementary strengths and limitations of local and global methods naturally raises a question: is it possible to design a prediction scheme for PtO that simultaneously preserve convexity and achieve statistical efficiency by overcoming the curse of dimensionality? Equivalently, can we construct a weighting scheme in Equation (3) that guarantees nonnegativity throughout the covariate space while exploiting high-order smoothness to achieve statistical efficiency in high-dimensional settings?
Our theoretical analysis in this subsection reveals that these two objectives are fundamentally mutually exclusive. To state the result formally, we adopt a minimax formulation over a class of smooth problem instances and a broad class of PtO procedures characterized only through their weighting rules.
Assumption 5 (Problem Class for Minimax Lower Bound). Fix a nonnegative integer . Let denote a class of problem instances , where is a joint distribution of supported on and is a measurable cost function. For each , define the induced conditional objective . We assume the following conditions hold:
(i) For every fixed , the map is -times continuously differentiable on , with all partial derivatives up to order uniformly bounded over , where means continuity.
(ii) The covariates are supported on the hypercube and admit a density such that for all .
(iii) The conditional variance of Y given X = x is uniformly lower bounded, i.e., for all and some constant .
Assumption 6 (Admissible PtO Weights). A PtO algorithm is said to use admissible weights if, for every sample size n, every query point , and every realization of , it assigns weights satisfying:
(i) Each depends only on , and does not depend on .
(ii) for all .
(iii) for all .
Theorem 1 (Minimax Lower Bound for Convexity-Preserving PtO). Consider the setting with for some sufficiently large . Fix a nonnegative integer , let be the problem class in Assumption 5. Consider any PtO algorithm that, given data and a query covariate , constructs the empirical objective as Equation (3), where the weights satisfy Assumption 6, and outputs a decision . Then there exists a constant , independent of , such that
Theorem 1 establishes a formal “no-free-lunch” result for PtO procedures using nonnegative, covariate-based weights satisfying Assumption 6. Even when the conditional objective is -times continuously differentiable for arbitrarily large , the worst-case expected regret of any such procedure cannot decay faster than . This limitation already arises with a one-dimensional outcome and decision, demonstrating that these weighting schemes can fail to fully exploit high-order smoothness even in this simple setting. This lower-bound rate coincides with that of second-order local methods and deteriorates rapidly as the covariate dimension increases. Thus, nonnegativity constitutes a fundamental statistical bottleneck: although it preserves convexity, it prevents the estimator from attaining the faster convergence rates associated with global smoothers over highly smooth function classes.
The proof constructs a finite adversarial subclass of , consisting of instances whose conditional objectives are quadratic and strongly convex in the decision variable, such that, for any PtO algorithm whose weights satisfy Assumption 6, at least one instance in this subclass incurs expected regret at least of order . Taking the maximum over this finite subclass and subsequently the supremum over yields Equation (5). When , the exponent in Proposition 1's upper bound is half that in Theorem 1's lower bound. This difference may be explained by the different proof arguments. Proposition 1 bounds regret by the uniform objective-estimation error without exploiting curvature, whereas Theorem 1 uses a quadratic construction in which regret is proportional to the squared decision error. Neither bound is guaranteed to be tight, and considering a more general adversarial subclass may yield a sharper lower bound. The complete proof of Theorem 1 is provided in Appendix EC.1.2.
To illustrate this dilemma, we consider a contextual newsvendor problem in which a retailer decides how much inventory to order each day. The resulting cost depends on both the order quantity z and the realized demand Y. Specifically, the retailer incurs an overage cost when the order quantity exceeds demand and a shortage cost when demand exceeds the order quantity. At the time of ordering, the retailer does not observe demand Y, but has access to some covariates X, such as seasonal conditions, promotional activities, and weather, that may help predict demand. The detailed experimental setting, including the cost parameters, conditional demand distribution is provided in Section 6.2. Here, we use the structure-aware formulation established in Section 6.2, under which the objective function is infinitely differentiable in x. We fix the training sample size at n = 2,000 and vary the covariate dimension . We evaluate decision performance using the relative cost defined in Equation (2), with unconditional SAA as the benchmark.
Figure 1 compares traditional local PtO methods with two variants of KRR-based PtO. PtO-KRR uses the original KRR weights, which can be negative, while PtO-KRR truncates negative weights to zero and renormalizes the remaining weights to sum to one, following Bertsimas and Koduri (2022). Traditional local methods, including k-nearest neighbors and kernel smoothing, use nonnegative weights and therefore preserve convexity. Their performance, however, deteriorates substantially as increases, illustrating the severe effect of the curse of dimensionality on local PtO methods. By contrast, PtO-KRR exploits the
Figure 1 An illustrative example showing the performance of predictive approaches

existing global smoothness and maintains relatively stable performance as increases. PtO-KRR restores convexity through nonnegative weights but exhibits a similarly pronounced deterioration, indicating that clipping eliminates much of the high-dimensional advantage of the original KRR estimator. In summary, the theoretical and numerical results reveal a fundamental dilemma within standard PtO frameworks: preserving convexity through nonnegative weights and attaining high-dimensional statistical efficiency through high-order smoothness cannot, in general, be achieved simultaneously.
4. Generate-then-Optimize
We next introduce an alternative paradigm, Generate-then-Optimize (GtO), for solving the CSO problem (1). GtO is a standard simulation-based method for solving stochastic optimization problems, which can be naturally extended to the CSO problem (1). Denote as the conditional distribution of Y conditioned on . On the offline stage, we use the historical data to learn the conditional distribution or a simulator for , denoted as . On the online stage, when a new covariate arrives, we generate i.i.d. samples from , denoted as . Then, we can use SAA to construct a sample objective function and solve the simulation-based CSO problem accordingly as
4.1. Convexity Preservation
Assumption 1 supposes that the cost function is convex in for each fixed . The following proposition shows that GtO preserve the convexity structure of the cost function.
Proposition 2. If is convex on for all , then for any realized simulator , the SAA objective , where , is convex on .
The proof of Proposition 2 is immediate from the fact that nonnegative linear combinations of convex functions are convex. Proposition 2 shows that, under GtO, the optimization problem (6) solved online is exactly a convex program with being convex. Thus, the powerful machinery of convex optimization can be used without modification and classical stability results for convex stochastic programming apply; see, e.g., Shapiro et al. (2009).
4.2. Conditional Generative Models for GtO
The GtO framework is agnostic to the particular generative architecture used to construct . Its essential requirement is a learned conditional distribution from which scenarios can be generated at a given covariate value. A conditional generator may be represented abstractly as , where , is learned from , and the exogenous random variable supplies the randomness required for scenario generation. The distribution induced by defines . This formulation encompasses both classical conditional distribution estimators that permit sampling and modern deep generative models. We focus on the latter.
A variety of conditional generative models can be incorporated into GtO. Representative examples include conditional variational autoencoders, which use latent variables to represent complex conditional distributions; conditional generative adversarial networks, which learn a conditional sampler through adversarial training; and conditional normalizing flows, which construct flexible conditional densities through invertible transformations. Autoregressive models can generate outcomes sequentially and are particularly useful for discrete, sequential, or otherwise structured outcomes. Transformer-based language models also belong to this class when outcomes are represented as sequences. We refer to Bond-Taylor et al. (2022) for a review of these model families. Conditional diffusion models provide another approach, generating scenarios through a learned reverse diffusion process (Yang et al. 2024). Related flow-matching models learn continuous transformations from a reference distribution to the target distribution through a vector-field regression objective.
We use conditional diffusion models (CDMs) as a benchmark implementation of GtO. They can flexibly represent high-dimensional and multimodal conditional distributions, and their denoising-based training avoids the adversarial minimax optimization used by conditional GANs. Recent studies also provide explicit statistical guarantees for conditional distribution estimation, making CDMs suitable for connecting our theoretical analysis with an implementable generative model (Fu et al. 2024, Tang et al. 2025). A potential limitation is the cost of generating samples through a discretized reverse-time process. Accelerated samplers and distillation methods can reduce this burden, although sampling cost remains an important consideration in downstream optimization; see Yang et al. (2024) for a review. Accordingly, we use CDMs in the subsequent theoretical and numerical analyses, while other conditional generative models can be incorporated into the same GtO framework.
We briefly describe the CDM. Fix a covariate value x, and let denote a forward Ornstein–Uhlenbeck process initialized from the target conditional distribution:
where is a standard Brownian motion. Equivalently, , , , . Let denote the conditional density of given . The key object is the time-dependent conditional score , which is estimated from by denoising score matching. The conditional and unconditional score functions can be estimated jointly by minimizing the empirical denoising score-matching risk , where
where , , when and when , and denotes the Gaussian transition density . Notice that, since , writing with yields the equivalent regression target ; The lower endpoint is an early-stopping time introduced to avoid the singular behavior of the score near , and is a unified class consisting of conditional and unconditional ReLU score networks; See Yang et al. (2024) and Fu et al. (2024) for more learning details. Given the estimated conditional score, scenarios are generated from the reverse-time stochastic differential equation
where is another Brownian motion independent of and with a guidance strength . For the distribution-estimation interpretation and the theoretical guarantees below, we take ; positive values of correspond to an optional classifier-free guidance heuristic. At the population level, with the exact conditional score , the output distribution of the reverse-time process (7) approaches as the terminal time becomes large and the early-stopping time becomes small. In practice, using a finite and a positive , replacing the exact score with an estimated score , and numerically discretizing the reverse process yield the learned conditional distribution from which GtO scenarios are generated. Under suitable assumptions and parameter choices, Fu et al. (2024) and Tang et al. (2025) establish convergence guarantees for such CDM estimators.
The regret analysis developed below deliberately abstracts away from these architectural details. It requires only that the learned model support conditionally independent scenario generation and that the discrepancy between and admit an appropriate statistical bound. The specific generative architecture affects the resulting regret bound only through the offline model error, while the online SAA error is governed by the number m of generated scenarios. CDMs provide one concrete implementation for which theoretical distributional learning rates are available, but the GtO framework and the regret decomposition are not restricted to this particular model class.
4.3. Statistical Efficiency of GtO
Now, we analyze the regret
To isolate the impact of the model error from the SAA error, we define an auxiliary decision rule as
where . Then we have the basic decomposition
The first term in Equation (9) is the error induced by the SAA under the distribution , while the second term in Equation (9) is the model error caused by the difference between and . We will discuss the two terms in Equation (9) separately, and then summarize their combined impact on the regret .
4.3.1. The SAA Error. We first analyze the contribution of the SAA approximation to the regret in Equation (9). Fix the covariate value , and treat the offline data and the learned distribution or simulator as given. All expectations in this subsection are taken with respect to the simulation draws conditional on and .
Lemma 1. Suppose Assumption 1 holds. Fix a covariate value and a realization of the learned conditional distribution or simulator . Then there exists a constant , depending only on , such that for all ,
Lemma 1 shows that, once the learned distribution or simulator is fixed, the SAA-based decision is nearly optimal for the population objective , with regret decaying at the typical rate which comes from the fact that is an empirical average of i.i.d. samples. The proof follows the standard SAA/M-estimation pattern: obtain a uniform bound on the empirical objective and then transfer it to the regret; see, e.g., van der Vaart (1998, Chapter 5) and Shapiro et al. (2009, Chapter 5). The existing SAA results typically provide almost-sure or in-probability convergence of regrets and solutions, and asymptotic distributions; see, e.g., Shapiro et al. (2009), Banholzer et al. (2022). Our result here is a non-asymptotic -error bound for the SAA regret with explicit dependence. We provide the proof in Appendix EC.2.1.
4.3.2. The Model Error. We now turn to the contribution of model misspecification, i.e., the error caused by using the learned conditional distribution instead of the true distribution .
Assumption 7. There exist constants , , and such that for all ,
where TV denotes the total variation distance, the inner expectation is with respect to the covariate X, and the outer expectation is with respect to the training data .
Assumption 7 requires that the learned conditional distribution converges to the true conditional distribution in total variation, on average over the covariate distribution, at some explicit rate up to logarithmic factors. Such rates are available in both parametric and nonparametric settings. In parametric conditional density models with a finite-dimensional parameter estimated at the usual rate (van der Vaart 1998), one can show that Assumption 7 holds with and under some regularity conditions. In nonparametric conditional density estimation, minimax rates in integrated (and hence total variation) risk of the form with log factors are attainable under -Hölder smoothness assumptions; see, e.g., Tsybakov (2009), Li et al. (2022), Fu et al. (2024).
Remark 1. Recently, Fu et al. (2024) study the sample complexity of using CDMs to estimate the conditional distribution from data. Under their baseline conditions, the conditional density satisfies a uniform Gaussian-type upper-tail bound and -Hölder smooth (i.e., belongs to a -Hölder ball). Together with a uniform bound on its Kullback–Leibler divergence from the standard Gaussian distribution and appropriate choices of the early-stopping and terminal times, their result yields
Furthermore, under their stronger conditional-density condition, , where is -Hölder smooth and is uniformly bounded away from zero, the rate improves to
Consequently, for fixed and , the convergence rate approach as . Similarly, Tang et al. (2025) establish a related rate under compact-support and smooth conditional-density assumptions, while allowing the smoothness levels in the covariate and response directions to differ. Assumption 7 therefore summarizes the statistical accuracy of the offline conditional-distribution learning step in a form directly applicable to our regret analysis.
Lemma 2. Suppose Assumptions 1 and 7 hold. Then
where the inner expectation is with respect to X and the outer expectation is with respect to .
Lemma 2 shows that, under the average total variation convergence of Assumption 7, the regret due purely to model misspecification (i.e., optimizing under instead of ) decays at the same rate as the simulator itself in total variation, up to constants depending on the cost envelope M. We arrange the proof in Appendix EC.2.2.
Remark 2 (Alternative Distributional Discrepancies). Assumption 7 is stated in terms of total variation because, under the uniform boundedness condition , total variation directly controls the discrepancy between the true and learned conditional objectives as shown in Appendix EC.2.2. More generally, the same analysis applies to a probability metric or statistical divergence whenever there exist constants and such that
for all relevant distributions P and Q. Furthermore, if
then the proof of Lemma 2 and Jensen's inequality yield
For bounded costs, Condition (13) holds with for total variation, for the Hellinger distance, and for the Kullback–Leibler divergence. If is uniformly -Lipschitz, it also holds with for the p-Wasserstein distance with .
Distributional learning rates (14) under these discrepancies are available for several of the conditional generative models discussed in Section 4.2. In particular, explicit total-variation and Wasserstein rates have been established for CDMs (Fu et al. 2024, Tang et al. 2025). For adversarial generators, Liu et al. (2021) establish nonasymptotic distributional guarantees for a Wasserstein-based conditional generator, which can be viewed as a conditional WGAN-type approach. For latent-variable models, Kumar et al. (2025) derive Hellinger and Wasserstein convergence rates for a likelihood-based conditional deep generative model and implement the estimator using a conditional VAE architecture. Closely related to flow-matching models, Huang et al. (2023) establish nonasymptotic guarantees for conditional stochastic interpolation, which constructs conditional samplers through learned probability-flow ODEs or stochastic differential equations. Comparable distributional learning rates are, to our knowledge, less developed for general conditional normalizing flows and Transformer-based autoregressive generators. Importantly, these guarantees apply to the specific estimators and regularity conditions studied in the respective works, rather than uniformly to the corresponding generative-model architecture classes.
4.3.3. Regret Bound for GtO. We now combine the SAA regret bound (Lemma 1) and the model regret bound (Lemma 2) to obtain an overall bound on the regret of the GtO procedure. Taking expectations over the randomness in both the training data and the online covariate on both sides of Equation (9), and applying Lemmas 1 and 2, yields the desired regret bound.
Theorem 2. Suppose Assumptions 1 and 7 hold. Then there exists a constant , depending only on , such that for all integers ,
where, conditional on , the inner expectation is with respect to the online covariate X and the conditional simulation draws, and the outer expectation is with respect to .
Theorem 2 provides a clean decomposition of the average regret of the GtO procedure into: an offline learning error term, , which reflects how accurately the conditional distribution can be learned from samples in total variation, and an online SAA error term, , which reflects the Monte Carlo error from using simulated samples at decision time. In the situation where (Remark 1), this yields the canonical rate
Theorem 2 makes explicit the trade-off between investing in more training data (larger n) and using more simulation at decision time (larger m). In particular, if one balances the two error terms by choosing m as a suitable function of n, the overall regret can be minimized. We arrange the proof in Appendix EC.2.3.
Remark 3. Furthermore, if the cost function is strongly convex on Z, then we can improve the result (15) to
for some constant C depending on the setting of strongly convex cost function; See Appendix EC.2.4 for the detailed discussion.
5. Choosing Between Predictive and Generative Approaches
Our analysis yields three managerial insights for choosing between PtO and GtO, concerning the statistical difficulty of the learning target, the optimization structure retained after learning, and the range of decisions the learned model will support. These insights explain why neither approach is uniformly preferable and provide practical guidance on where an organization can invest to improve its decision process.
5.1. Learning Less Is Not Always Easier
PtO learns the conditional expected objective , whereas GtO learns the conditional uncertainty underlying that objective. Although the former is a narrower target, its statistical difficulty depends on its smoothness. To illustrate this distinction, consider the specific guarantees established earlier for KRR-based PtO and CDM-based GtO. Under suitable regularity conditions, suppressing logarithmic factors and the finite-scenario approximation error gives
Here, represents the expected-objective smoothness parameter in the KRR bound, and is the conditional-density smoothness parameter in the CDM bound.
These expressions reveal a tradeoff between dimension and smoothness. GtO bears the additional dimension , but its learning target can be smoother than the expected objective. PtO avoids that additional dimension, while its convergence rate also depends on the regularity of the expected objective. Thus, identifying the smaller learning target is not enough; one must also identify which target is easier to learn.
5.2. Statistical Flexibility Has an Optimization Consequence
Convexity is an important source of tractability in optimization, but whether it survives learning depends on how the estimated objective is constructed. Both PtO and GtO use weighted combinations of scenario costs:
When is convex for every , nonnegative weights preserve convexity. GtO uses equal positive weights and therefore inherits this property. PtO, however, faces the dilemma established by our earlier lower-bound result: within the class of nonnegative, covariate-based weighting rules studied there, worst-case expected regret cannot decay faster than , even for arbitrarily smooth objectives in the constructed problem class. Thus, nonnegative weighting preserves convexity but limits the statistical gains available from additional smoothness. More flexible regression can exploit that smoothness, but may introduce negative weights and lose the general convexity guarantee.
Negative weights do not necessarily make the fitted objective nonconvex, nor does nonconvexity necessarily make it difficult to optimize. Their computational effect depends on the problem's structure. The numerical study illustrates this distinction: the signed weighted newsvendor objective in Section 6.2 remains efficiently solvable, whereas signed weights can invalidate the usual linear programming reformulation of the product placement problem in Section 6.3. Thus, the relevant concern is whether the fitted objective retains the structure needed by the solution method.
Convexity alone also does not determine computational cost. For GtO, the bound highlights the role of scenario count: increasing reduces scenario approximation error but increases the scenario generation cost and enlarges the optimization problem, without eliminating model error . PtO's computational cost likewise depends on its fitted representation and the available solver. The two approaches should therefore be compared by the decision quality they deliver within the available computational budget.
5.3. The Appropriate Learning Target Depends on the Scope of Reuse
The preceding discussion focuses on a single decision problem. An organization may instead face a collection of tasks that share the same conditional uncertainty:
The costs and constraints may differ across tasks, even though the relevant uncertain outcomes are the same.
This distinction changes the value of what is learned. A model tailored to can focus its statistical capacity on one task. A conditional generator can support multiple tasks through . Once generated, the same scenarios can be evaluated under different objectives and constraints. Learning a richer object can therefore have value beyond its performance on any single task.
This potential benefit is particularly relevant when data analysis and operations reside in different departments. A shared generator provides an interface through which the data team supplies conditional scenarios and operational teams formulate their own decision problems. Changes in an objective need not require redesigning the learning target, provided the modeled uncertainty remains appropriate. This can reduce the coordination required to adapt analytics to new uses.
Reuse is nevertheless not exclusive to GtO. PtO methods can share weights, features, or estimated components across tasks. Nor does a generator remain valid automatically when a new task changes the underlying uncertainty — for example, when a pricing decision changes demand. The practical question is how much additional learning, validation, and coordination each new use requires.
Accordingly, the comparison should reflect the intended scope of deployment. For a stable, specialized task, exploiting objective-specific structure may be especially valuable. For a collection of evolving tasks with common uncertainty, a reusable generative model may justify its greater statistical and computational demands. The single-task regret bounds clarify those demands; they do not quantify the organizational benefits of reuse.
5.4. Practical Rules of Thumb
Taken together, these insights suggest choosing between PtO and GtO by considering what must be learned, how the resulting decision problem will be solved, and how broadly the model will be used. PtO's specialization is valuable when it reduces the learning burden while retaining a tractable decision problem. GtO's broader representation is valuable when regularity in the uncertainty, preservation of optimization structure, or reuse across tasks compensates for its additional learning and computational demands. Table 1 summarizes these considerations as practical rules of thumb. When the factors point in different directions, the final choice should be guided by decision quality and computational cost in the intended application.
Table 1 Practical guidance for choosing between PtO and GtO.
| Factor | Low | High |
|---|---|---|
| Importance of convexity | No clear preference | GtO or convexity-preserving PtO |
| Objective smoothness | GtO | PtO |
| Distribution smoothness | PtO | GtO |
| Covariate dimension | No clear preference | Smoothness-dependent |
| Outcome dimension | No clear preference | PtO |
| Task diversity | PtO | GtO |
| Importance of online speed | No clear preference | PtO |
Note. Preferences indicate tendencies, all else equal, rather than guaranteed performance rankings. Objective smoothness refers to the components that must be learned; task diversity assumes shared underlying uncertainty. Smoothness and dimension comparisons are subject to the assumptions of the corresponding theoretical results. Online speed includes both conditional scenario generation and optimization.
6. Numerical Study
We compare PtO and GtO in three settings. A contextual newsvendor experiment examines the roles of training sample size, covariate dimension, and the structure of the learning target. A product placement experiment examines the computational consequences of signed prediction weights and the effect of outcome dimension. A fresh-retail inventory study evaluates the methods with real data at different levels of pooling. Together, the experiments compare decision quality and the computation required to obtain those decisions.
6.1. General Setup
The PtO benchmarks are -nearest neighbors (KNN), kernel smoothing (KS), kernel ridge regression (KRR), and clipped KRR (), which replaces negative weights by zero and renormalizes the remaining weights. For , KRR and clipped KRR use a Nyström approximation (Williams and Seeger 2001); the table headings retain the KRR designation. In the synthetic experiments, GtO uses a conditional diffusion model (GtO-CDM) (Fu et al. 2024). Unconditional SAA and an oracle based on the true data-generating process provide benchmarks. Hyperparameters are selected by validation decision cost and fixed before test evaluation.
Synthetic decision performance is measured by the relative cost in Section 2: . A larger value is better, with zero corresponding to SAA and one to the oracle. The retail study instead reports cost relative to SAA because the true conditional demand distribution is unavailable. Online time excludes model training and includes query-specific computations: prediction weights and optimization for PtO, and conditional scenario generation and optimization for GtO.
All experiments are implemented in Python 3.12.4 and run on the University of Minnesota Supercomputing Institute cluster with NVIDIA A40 GPUs and on Nanjing University servers with NVIDIA H100 GPUs. Gurobi 13.0.1 solves the product placement linear programs (LPs) and the convex subproblems in the difference-of-convex algorithm (DCA). Online time starts when a new context is observed and excludes model training. It includes computing prediction weights and solving the decision problem for PtO, and generating conditional scenarios and solving the decision problem for GtO.
6.2. Contextual Newsvendor Problem
We begin with a contextual newsvendor problem, in which a retailer uses observed covariates to determine an order quantity before demand is realized. A distinctive feature of our setting is a shortage penalty that changes discontinuously with the covariates, even though the conditional demand model varies smoothly. This allows us to examine how the comparison between PtO and GtO depends on whether PtO directly learns the objective or exploits its known structure. Details of the demand and cost construction are provided in Appendix EC.3.1.
6.2.1. Experimental Design. After observing covariates , the decision maker chooses an order quantity to solve
where . Conditional demand follows a three-component Gaussian mixture censored at zero. Covariates affect the component means, probabilities, and variances; average demand and signal-to-noise ratios are calibrated to remain comparable across dimensions. The known shortage penalty takes 11 levels between 30 and 120 and is a step function of a covariate-based priority score.
We vary and , holding . Each setting uses 100 test contexts and 30 independent replications. To distinguish direct objective fitting from exploitation of known structure, we implement PtO in two ways:
The direct formulation estimates the conditional expected objective from historical costs, including the discontinuities in . The structure-aware formulation estimates expected overage and shortage separately and applies the known penalty at the current context. The two learning targets of this formulation, and , are both smooth in under the demand model, whereas the overall objective learned by the direct formulation is discontinuous. This comparison therefore examines the value of learning a smoother objective in PtO by exploiting known cost structure while holding the underlying decision problem fixed.
6.2.2. Decision Quality and Computation. Figure 2 compares GtO with the best-performing PtO benchmark in each setting. Each cell reports the difference in relative cost, GtO minus the best PtO; positive values favor GtO. The best PtO score summarizes the benchmark results rather than specifying an additional method for deployment. Tables EC.1 and EC.2 in Appendix EC.3.1.2 report the individual methods' scores for the direct and structure-aware formulations, respectively. The GtO scores are identical across the two formulations.
Figure 2 Relative performance of PtO and GtO across and under the direct and structure-aware PtO formulations

(a) Direct objective learning
(b) Structure-aware objective learning
Three patterns emerge. First, PtO is competitive with limited training data, while GtO's relative performance improves as increases. At , the best PtO benchmark outperforms GtO in three of the seven covariate dimensions under each formulation; at , it does so in four of seven. At , GtO performs better in all seven dimensions under direct learning and six of seven under structure-aware learning. At , GtO performs better throughout. Thus, the larger-sample results favor GtO, although the ranking at smaller sample sizes depends on the context dimension and formulation.
Second, increasing the covariate dimension generally reduces decision performance, with a larger decline for PtO in several settings. At , increasing from 3 to 100 reduces the best direct PtO score from 0.9899 to 0.6564 and the best structure-aware PtO score from 0.9804 to 0.7060, compared with a decline from 0.9943 to 0.8665 for GtO. The pattern is not monotonic in every setting, but these results illustrate the difficulty of high-dimensional objective fitting even when known cost structure is incorporated. They do not imply that high covariate dimension intrinsically favors GtO.
Third, incorporating objective structure changes the comparison, but does not uniformly improve finite-sample performance. At and , KRR's relative cost increases from 0.7670 under direct learning to 0.8404 under structure-aware learning, reversing its ranking against GtO's 0.7723. A similar reversal occurs at , where KRR increases from 0.6402 to 0.8048, compared with GtO's 0.7935. Across all seven dimensions at this sample size, PtO leads in two settings under direct learning and four under structure-aware learning. However, at and , KRR's score falls from 0.8993 to 0.8062.
Exploiting the smoothness of the learning targets therefore provides an opportunity to improve PtO, rather than a guarantee of better decisions in every setting.
The gains in decision quality can require substantially more online computation. Table 2 reports the structure-aware results at : PtO takes approximately 0.013 to 0.042 seconds per decision, whereas GtO takes 0.76 to 2.80 seconds. The empirical objectives are one-dimensional and piecewise linear, allowing breakpoint-based optimization even with signed weights when the objective is bounded below. Conditional scenario generation adds computation for GtO. The complete timing grids in Tables EC.3 and EC.4 show that this latency difference persists under both formulations. Thus, the more favorable GtO decision performance in many settings comes with a higher online computational cost.
Table 2 Online time for the structure-aware newsvendor formulation at (seconds).
| SAA | PtO-KNN | PtO-KS | PtO-KRR | GtO-CDM | ||
|---|---|---|---|---|---|---|
| 3 | 0.0214 | 0.0392 | 0.0331 | 0.0338 | 0.0251 | 0.7556 |
| 6 | 0.0136 | 0.0268 | 0.0208 | 0.0294 | 0.0199 | 1.0644 |
| 10 | 0.0221 | 0.0350 | 0.0373 | 0.0405 | 0.0285 | 1.3747 |
| 20 | 0.0139 | 0.0218 | 0.0206 | 0.0146 | 0.0150 | 1.6678 |
| 40 | 0.0224 | 0.0250 | 0.0420 | 0.0207 | 0.0202 | 2.6496 |
| 60 | 0.0134 | 0.0211 | 0.0235 | 0.0214 | 0.0125 | 2.7344 |
| 100 | 0.0216 | 0.0301 | 0.0298 | 0.0210 | 0.0314 | 2.7950 |
Note. Entries are taken from Table EC.4. Online time includes conditional scenario generation for GtO.
6.3. Product Placement Problem
We next consider a product placement problem, in which a retailer allocates inventory across stores before demand is realized and subsequently transfers stock among stores to meet demand (Bertsimas and Koduri 2022). This setting introduces multivariate uncertainty, with the initial inventory decision having the same dimension as the demand vector. More importantly, this setting allows us to examine the computational consequences of signed PtO weights as the decision dimension increases. In the newsvendor problem, the decision is one-dimensional, so even when KRR produces negative weights, the piecewise-linear objective can be globally minimized by evaluating its breakpoints. In contrast, the product placement problem also has a piecewise-linear objective, but with a higher decision dimension, the number of candidate vertices can grow rapidly. Enumerating these candidates therefore becomes computationally impractical as increases. We therefore need to exploit the structure of the optimization problem to using specific optimization algorithm to solve it.
The product placement problem has a two-stage linear structure. With nonnegative scenario weights, the second-stage optimization problems can be incorporated into the first-stage optimization, yielding a single linear program (LP) that can be efficiently solved even in higher dimensions. However, signed KRR weights invalidate this reformulation and may result in a nonconvex optimization problem. We therefore use a difference-of-convex algorithm (DCA) with linear programming subproblems; the derivation is provided in Appendix EC.3.2.2. Since DCA does not generally guarantee global optimality, the reported KRR results may also be affected by optimization error. Unlike the one-dimensional newsvendor problem, the computational cost of handling signed weights can become substantial as the decision dimension increases. Details of the network, demand model, and optimization formulations are provided in Appendix EC.3.2.
6.3.1. Experimental Design. Let z denote initial inventory at the stores and y the realized demand vector. The recourse cost is
where denotes transfers, unmet demand, the network incidence matrix, and and the transportation and shortage cost vectors. The retailer minimizes over , where denotes placement costs and inventory upper bounds. Placement, transportation, and shortage costs are 2, 1, and 10 per unit, respectively. We extend the newsvendor demand model to correlated multivariate demand, fix and , and vary .
6.3.2. Decision Quality and Solution Time. Table 3 reports decision performance and online time together. We first compare the PtO methods. KRR consistently improves on clipped KRR: its relative cost lies between approximately 0.65 and 0.70, compared with 0.42–0.65 for clipped KRR. The improvement comes with longer solution times in every setting. At , KRR achieves a relative cost of 0.6602 in 272.54 seconds, whereas clipped KRR achieves 0.4227 in 22.50 seconds. KNN and KS are faster still, but provide lower decision quality than raw KRR. These comparisons among PtO methods expose a clear tradeoff between decision quality and solution time.
Now we compare GtO with PtO algorithms in Table 3, in particular, we look at GtO-CDM. It achieves the highest relative cost in every tested setting, approximately 0.91–0.93, but is not uniformly the fastest approach. Its online times are comparable to raw PtO-KRR in several settings, and their ordering changes with dimension. At , PtO-KRR takes 1.23 seconds compared with 2.95 seconds for GtO-CDM; at , GtO-CDM takes 180.93 seconds compared with PtO-KRR's 272.54 seconds. Nonnegative-weight PtO remains faster than either at the latter dimension. Even with the increased computational cost associated with signed weights, PtO-KRR achieves substantially lower decision quality than GtO-CDM despite their comparable online times in several settings. This comparison further highlights the computational consequences of losing convexity in PtO. Further specialization of the PtO-KRR solver might improve its computational efficiency, but would require additional algorithmic effort.
As shown in Table 3, increasing substantially raises online computation, whereas relative decision performance varies comparatively little over the tested range. In particular, GtO's relative cost stays above
Table 3 Decision performance and online time for product placement. Panel A: Relative cost (higher is better).
| SAA | PtO-KNN | PtO-KS | PtO-KRR | GtO-CDM | ||
|---|---|---|---|---|---|---|
| 1 | 0.0000 | 0.5913 | 0.1154 | 0.6618 | 0.4476 | 0.9268 |
| 2 | 0.0000 | 0.5802 | 0.2294 | 0.6807 | 0.6129 | 0.9104 |
| 5 | 0.0000 | 0.5750 | 0.1979 | 0.6983 | 0.6454 | 0.9243 |
| 10 | 0.0000 | 0.5632 | 0.1432 | 0.6454 | 0.5623 | 0.9263 |
| 15 | 0.0000 | 0.5391 | 0.1537 | 0.6602 | 0.4227 | 0.9182 |
Panel B: Online time in seconds (lower is better).
| SAA | PtO-KNN | PtO-KS | PtO-KRR | GtO-CDM | ||
|---|---|---|---|---|---|---|
| 1 | 0.0048 | 0.0914 | 0.0915 | 1.2329 | 0.1333 | 2.9496 |
| 2 | 0.1872 | 0.4537 | 0.3212 | 4.8291 | 0.4981 | 3.8220 |
| 5 | 0.2524 | 0.9574 | 1.2131 | 29.9059 | 2.6315 | 14.6501 |
| 10 | 1.1088 | 2.1841 | 2.9841 | 57.9449 | 9.0928 | 75.1714 |
| 15 | 3.8801 | 3.9280 | 3.9460 | 272.5360 | 22.5041 | 180.9274 |
Note. KRR uses DCA; the other methods use a LP formulation. Online time excludes training and includes query-specific computations.
0.91 as increases from 1 to 15; the experiment does not exhibit a crossover favoring PtO. Similar stability of PtO performance with respect to outcome dimension has been reported by Bertsimas and Koduri (2022). Here, increasing also enlarges the placement and recourse problems, so the runtime changes capture more than the cost of learning higher-dimensional uncertainty. Over the tested range, outcome dimension has a more pronounced effect on computation than on the relative decision-performance ranking.
6.4. Real Case Study: Fresh Retail Inventory
We compare PtO and GtO in a fresh-retail inventory setting using the FreshRetailNet-LT dataset released by Dingdong Fresh (Wang et al. 2025). The application combines several features common in operational decision making: demand varies across locations and operating conditions, stockouts censor observed sales, and contextual information includes both continuous and categorical variables. It therefore provides an opportunity to examine the usefulness of the two approaches beyond the setting of our theoretical analysis and to assess whether similar insights emerge with real operational data.
6.4.1. Data and Experimental Design. FreshRetailNet-LT contains daily sales records for 576 perishable products across 1,057 stores in 18 major Chinese cities. We focus on product 156 because of its broad store coverage and long sales history, and select the 50 stores with the longest common observation period. These stores span 11 cities and are observed from June 5, 2023 to July 20, 2025, yielding a balanced panel of 777 days and 38,850 store-day observations.
Stockouts occur in approximately 20% of the observations and may censor sales. We apply the TimesNet-based demand recovery procedure described by Wang et al. (2025) to the hourly sales and stock-status data, then aggregate recovered demand to daily totals for training and evaluation. Since procurement costs and
https://huggingface.co/datasets/Dingdong-Inc/FreshRetailNet-LT actual selling prices are unavailable, we normalize the unit overage cost to one and specify the shortage penalty as , where denotes the ratio of the discounted selling price to the regular price, which is included as a covariate in the dataset. The resulting inventory problem is
This penalty makes shortages more costly when the product sells closer to its regular price. The evaluation therefore measures decision performance using recovered demand and a specified cost function.
We construct 37 exogenous features from store location, calendar effects, promotions, discounts, and weather. City, weekday, and month use one-hot encoding; holidays and promotional activity use binary indicators; the remaining features are continuous. Following Ban and Rudin (2019), we also incorporate the preceding 14 days of demand, summarized by their sample mean and the 13 differences between consecutive order statistics (Liyanage and Shanthikumar 2005). The resulting covariate vector has 51 components: 32 binary or one-hot indicators and 19 continuous variables.
All settings use the same chronological split. After the initial 14-day history window, training runs from June 19, 2023 to March 22, 2025, validation covers March 23–April 13, 2025, and testing covers April 14–July 20, 2025. Each store contributes 643 training days, 22 validation days, and 98 test days.
We consider three store settings to examine how the comparison changes as learning expands from a single location to a broader network. This reflects a practical modeling choice for retailers: whether to build a model using one store's history or pool observations across stores. Pooling provides more training data but also introduces greater heterogeneity. The one-store setting uses the highest-sales store among the 50 selected stores; the 11-store setting uses the highest-sales store in each city; and the 50-store setting uses all selected stores. Their respective training samples contain 643, 7,073, and 32,150 observations. These settings allow us to examine the joint effects of data availability and pooling scope, rather than isolate a sample-size effect.
This application extends beyond the continuous-covariate setting of our theoretical analysis because the contextual features include both continuous and categorical variables. We therefore use learning models that accommodate these mixed feature types. For GtO, we use TabCSDI (Zheng and Charoenphakdee 2022), a diffusion model for mixed-type tabular data, to generate conditional demand scenarios. For PtO, we add random forests (RF) to the existing surface-fitting benchmarks. For KRR, details of incorporating one-hot-encoded categorical variables into the kernel are provided in Appendix EC.3.3. The subsequent optimization steps remain unchanged. The purpose is to examine whether the two approaches remain useful with learning models suited to the application and whether the tradeoffs identified earlier persist beyond the assumptions of the theory. Hyperparameters are selected using validation decision cost, as in the preceding experiments.
Because the true conditional demand distribution is unavailable, we evaluate each method using its average realized cost on the test set, computed from recovered demand. For method M and store setting s, we report normalized cost . SAA consequently has normalized cost one, and lower values indicate better performance.
6.4.2. Decision Quality and Online Computation. Panel A of Table 4 shows that the relative performance of PtO and GtO changes across the pooling settings. With one store, PtO-RF achieves the lowest normalized cost, 0.4134, followed by PtO-KRR at 0.4509. GtO improves on SAA but performs worse than every PtO benchmark, with a normalized cost of 0.8324. With 11 stores, GtO achieves 0.4752 compared with 0.5106 for RF, the best PtO benchmark, reducing cost by approximately 6.9%. With 50 stores, GtO achieves 0.5006 compared with 0.5512 for PtO-KRR, a reduction of approximately 9.2%.
Table 4 Decision performance and online time for fresh-retail inventory. Panel A: Normalized test cost (lower is better).
| Stores | SAA | PtO-KNN | PtO-KS | PtO-KRR | PtO-RF | GtO-TabCSDI | |
|---|---|---|---|---|---|---|---|
| 1 | 1.000000 | 0.733880 | 0.703226 | 0.450895 | 0.652547 | 0.413442 | 0.832392 |
| 11 | 1.000000 | 0.726613 | 0.930284 | 0.522770 | 0.667793 | 0.510626 | 0.475210 |
| 50 | 1.000000 | 0.688577 | 0.890121 | 0.551178 | 0.716294 | 0.563453 | 0.500594 |
Panel B: Online time in seconds (lower is better).
| Stores | SAA | PtO-KNN | PtO-KS | PtO-KRR | PtO-RF | GtO-TabCSDI | |
|---|---|---|---|---|---|---|---|
| 1 | 0.0002 | 0.0028 | 0.0008 | 0.0115 | 0.0072 | 0.0121 | 1.0461 |
| 11 | 0.0011 | 0.0048 | 0.0013 | 0.0149 | 0.0155 | 0.0962 | 7.1255 |
| 50 | 0.0203 | 0.0189 | 0.0397 | 0.0297 | 0.0284 | 0.1063 | 18.0873 |
Note. Boldface identifies the lowest normalized cost in each store setting. Online times exclude model training, include query-specific computation, and are averaged over all test points.
The shift toward GtO with broader pooling resembles the sample-size pattern in the synthetic experiments. However, because pooling changes both the training sample and the store population, the performance differences across settings cannot be attributed to sample size alone.
Panel B reports the computational tradeoff. GtO's online time increases from 1.05 seconds in the one-store setting to 7.13 seconds with 11 stores and 18.09 seconds with 50 stores. All PtO methods remain below 0.11 seconds in the three settings. With 50 stores, for example, GtO's cost reduction relative to PtO-KRR accompanies an online time of 18.09 seconds, compared with 0.030 seconds for PtO-KRR. Thus, PtO performs better in the smallest setting on both decision quality and latency, while broader pooling introduces a tradeoff between GtO's lower decision cost and PtO's faster response. These findings extend the empirical comparison to mixed contextual features and recovered demand, while illustrating similar tradeoffs between data availability, decision quality, and computation.
7. Conclusion
In this paper, we study a fundamental representation choice in contextual stochastic optimization: should one learn the conditional objective needed for a particular decision problem, or learn the underlying conditional distribution and generate scenarios for subsequent optimization? We formalize these two approaches as Predict-then-Optimize (PtO) and Generate-then-Optimize (GtO). Our main message is that neither paradigm is uniformly preferable. PtO benefits from statistical parsimony and avoids online scenario generation, whereas GtO learns a richer stochastic representation that can preserve the structure of the downstream optimization problem and be reused across decision tasks. The appropriate choice therefore depends on the statistical, computational, and operational characteristics of the problem.
Our theoretical analysis makes this trade-off explicit for convex contextual stochastic optimization. For a broad class of local PtO methods, nonnegative weighting preserves the convexity of the original problem but limits the ability of the estimator to exploit high-order smoothness in high-dimensional contexts. Global PtO methods such as KRR can achieve greater statistical efficiency by exploiting smoothness, but their signed weights need not preserve convexity. GtO avoids this tension because its downstream problem is an ordinary sample average approximation with nonnegative scenario weights and therefore inherits the convexity of the primitive stochastic program. Its statistical performance, however, depends on learning the richer conditional distribution. We then decompose the regret of GtO into an offline learning error and an online optimization error, providing a framework for directly comparing its statistical efficiency with that of PtO.
These results lead to a practical characterization of when each paradigm is attractive. PtO tends to be preferable when the conditional objective is sufficiently smooth, the uncertainty dimension is large, offline data are limited, the downstream task is stable, or online computation is particularly costly. GtO becomes more attractive when the conditional distribution is substantially smoother than the induced objective, the context dimension is large relative to the uncertainty dimension, preserving the structure of downstream optimization is important, sufficient training data are available, or the learned uncertainty model is intended to support multiple decision problems. Our numerical and empirical studies complement the theoretical analysis by illustrating how data availability, covariate dimension, learning formulation, and downstream problem structure affect the relative decision quality and online computational costs of PtO and GtO.
This study leaves several directions for future research. First, our analysis focuses on convex contextual stochastic optimization; extending the comparison to nonconvex, discrete, and multistage decision problems may reveal different trade-offs between statistical representation and optimization structure. Second, both PtO and GtO in this paper follow a sequential learning and optimization paradigm. An important direction is to study the predictive vs. generative representation choice within integrated or decision-focused learning frameworks. Third, reducing the online computational cost of GtO through faster conditional generators, more efficient scenario construction, or adaptive sampling may further expand the range of settings in which generative decision making is practically attractive. More broadly, this paper hopes that viewing contextual decision making through the choice of what statistical object to learn provides a useful perspective for designing data-driven optimization methods.
References
Ban GY, Rudin C (2019) The big data newsvendor: Practical insights from machine learning. Oper. Res. 67(1):90–108.
Banholzer D, Fliege J, Werner R (2022) On rates of convergence for sample average approximations in the almost sure sense and in mean. Math. Programming 191(1):307–345.
Bertsimas D, Kallus N (2020) From predictive to prescriptive analytics. Management Sci. 66(3):1025–1044.
Bertsimas D, Koduri N (2022) Data-driven optimization: A reproducing kernel Hilbert space approach. Oper. Res. 70(1):454–471.
Bertsimas D, McCord C, Sturt B (2023) Dynamic optimization with side information. Eur. J. Oper. Res. 304(2):634–651.
Bond-Taylor S, Leach A, Long Y, Willcocks CG (2022) Deep generative modelling: A comparative review of VAEs, GANs, normalizing flows, energy-based and autoregressive models. IEEE Trans. Pattern Anal. Mach. Intell. 44(11):7327–7347.
Donti P, Amos B, Kolter JZ (2017) Task-based end-to-end model learning in stochastic optimization. Guyon I, von Luxburg U, Bengio S, Wallach H, Fergus R, Vishwanathan SVN, Garnett R, eds., Adv. Neural Inform. Proc. Systems 30 (Curran Associates, New York), 5484–5494.
Dupačová J, Gröwe-Kuska N, Römisch W (2003) Scenario reduction in stochastic programming. Math. Programming 95(3):493–511.
Elmachtoub AN, Grigas P (2022) Smart “predict, then optimize”. Management Sci. 68(1):9–26.
Fu H, Yang Z, Wang M, Chen M (2024) Unveil conditional diffusion models with classifier-free guidance: A sharp statistical theory. Preprint, submitted March 18, arXiv:2403.11968.
Gong S, Liu H, Zhang X (2024) Deep generative demand learning for newsvendor and pricing. Preprint, submitted November 13, arXiv:2411.08631.
Hannah L, Powell WB, Blei DM (2010) Nonparametric density estimation for stochastic optimization with an observable state variable. Lafferty JD, Williams CKI, Shawe-Taylor J, Zemel RS, Culotta A, eds., Adv. Neural Inform. Proc. Systems 23 (Curran Associates, New York), 820–828.
Hastie T, Tibshirani R, Friedman J (2009) The Elements of Statistical Learning: Data Mining, Inference, and Prediction, 2nd ed. (Springer, New York).
Høyland K, Wallace SW (2001) Generating scenario trees for multistage decision problems. Management Sci. 47(2):295–307.
Huang D, Huang J, Li T, Shen G (2023) Conditional stochastic interpolation for generative learning. Preprint, submitted December 9, arXiv:2312.05579.
Kumar S, Yang Y, Lin L (2025) A likelihood based approach to distribution regression using conditional deep generative models. Singh A, Fazel M, Hsu D, Lacoste-Julien S, Berkenkamp F, Maharaj T, Wagstaff K, Zhu J, eds., Proc. 42nd Internat. Conf. Machine Learn., volume 267 of Proc. Machine Learn. Res. (PMLR), 31964–31990.
Li M, Neykov M, Balakrishnan S (2022) Minimax optimal conditional density estimation under total variation smoothness. Electron. J. Stat. 16(2):3937–3972.
Liu S, Zhou X, Jiao Y, Huang J (2021) Wasserstein generative learning of conditional distribution. Preprint, submitted December 19, arXiv:2112.10039.
Liyanage LH, Shanthikumar JG (2005) A practical inventory control policy using operational statistics. Oper. Res. Lett. 33(4):341–348.
Mandi J, Kotary J, Berden S, Mulamba M, Bucarey V, Guns T, Fioretto F (2024) Decision-focused learning: Foundations, state of the art, benchmark and future opportunities. J. Artif. Intell. Res. 80:1623–1701.
Pisinger D, Hemmati Golsefidi A (2026) Deep generative scenario search for stochastic optimization. Eur. J. Oper. Res. 335(3):1008–1038.
Sadana U, Chenreddy A, Delage E, Forel A, Frejinger E, Vidal T (2025) A survey of contextual optimization methods for decision-making under uncertainty. Eur. J. Oper. Res. 320(2):271–289.
Schölkopf B, Herbrich R, Smola AJ (2001) A generalized representer theorem. Helmbold DP, Williamson B, eds., Computational Learning Theory (Springer, Berlin, Germany), 416–426.
Shapiro A, Dentcheva D, Ruszczyński A (2009) Lectures on Stochastic Programming: Modeling and Theory (SIAM, Philadelphia, PA).
Shen H, Hong LJ, Zhang X (2021) Ranking and selection with covariates for personalized decision making. INFORMS J. Comput. 33(4):1500–1519.
Stone CJ (1982) Optimal global rates of convergence for nonparametric regression. Ann. Statist. 10(4):1040–1053.
Tang R, Lin L, Yang Y (2025) Conditional diffusion models are minimax-optimal and manifold-adaptive for conditional distribution estimation. Yue Y, Garg A, Peng N, Sha F, Yu R, eds., Proc. 13th Internat. Conf. Learn. Representations.
Tsybakov AB (2009) Introduction to Nonparametric Estimation (Springer, New York).
van der Vaart AW (1998) Asymptotic Statistics (Cambridge University Press, Cambridge, UK).
Wahba G (1990) Spline Models for Observational Data (SIAM, Philadelphia, PA).
Wang PZ, Chen S, Liang J, Fioretto F, Zhu S (2026) Gen-DFL: Decision-focused generative learning for robust decision making. Vondrick C, Hariharan B, Raffel C, Pinto L, Yang D, Faust A, eds., Proc. 14th Internat. Conf. Learn. Representations.
Wang Y, Gu J, Long L, Li X, Shen L, Fu Z, Zhou X, Jiang X (2025) FreshRetailNet-50K: A stockout-annotated censored demand dataset for latent demand recovery and forecasting in fresh retail. Preprint, submitted May 22, arXiv:2505.16319.
Wang Y, Hanasusanto GA, Ho CP (2024) Generalization bounds for contextual stochastic optimization using kernel regression. Preprint, submitted July 15, arXiv:2407.10764.
Wendland H (2005) Scattered Data Approximation (Cambridge University Press, Cambridge, UK).
Williams CKI, Seeger M (2001) Using the Nyström method to speed up kernel machines. Leen TK, Dietterich TG, Tresp V, eds., Adv. Neural Inform. Proc. Systems 13 (Cambridge, MA: MIT Press), 682–688.
Yang L, Zhang Z, Song Y, Hong S, Xu R, Zhao Y, Zhang W, Cui B, Yang MH (2024) Diffusion models: A comprehensive survey of methods and applications. ACM Comput. Surv. 56(4):105:1–105:39.
Zhao Z, Yeh C, Kong L, Wang K (2026) Diffusion-DFL: Decision-focused diffusion models for stochastic optimization. Vondrick C, Hariharan B, Raffel C, Pinto L, Yang D, Faust A, eds., Proc. 14th Internat. Conf. Learn. Representations.
Zheng S, Charoenphakdee N (2022) Diffusion models for missing value imputation in tabular data. Preprint, submitted October 31, arXiv:2210.17128.
ec1
Appendix
EC.1. Proofs in Section 3
In this section, we prove Proposition 1 and Theorem 1 respectively.
EC.1.1. Proof of Proposition 1
To analyze the regret , we adopt the decomposition
(EC.1)
Equation (EC.1) shows that controlling the regret of the weighted PtO procedure reduces to bounding the approximation error between the estimated conditional objective and the true conditional objective , uniformly over . For each fixed decision , is the KRR estimator of , constructed using the observed costs as regression responses. We therefore begin by analyzing the KRR estimation error for a fixed decision and then extend the resulting bound uniformly over the decision set.
For a fixed decision , define the observed cost, its conditional mean, and the centered observation noise by
Then, and . Moreover, Assumption 1 gives and , and hence . Therefore, by Hoeffding's lemma,
(EC.2)
Thus, conditional on , the noise variables are independent, mean-zero, and sub-Gaussian with a sub-Gaussian bound independent of z.
To separate the effect of observation noise from the remaining estimation error, we consider the conditional expectation of the KRR estimator given the observed covariates. Define . Let denote the vector of observed responses. By Equation (4), the KRR estimator admits the closed-form expression
Since and are determined by and , taking the conditional expectation gives
ec2
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
Thus, coincides with the KRR estimator fitted to the noiseless responses . We therefore decompose the objective approximation error as
(EC.3)
The first term is the stochastic error arising from the observation noise, while the second term is the conditional bias. We first establish a bound for on a high-probability event for the random design in Lemma EC.1. We then bound on the same event and combine the two bounds to obtain a fixed-decision sup-norm error bound in Lemma EC.3. Finally, Lemma EC.4 extends this result uniformly over Z and establishes the expected uniform approximation error needed to control the regret.
Let . For a given realization , define the empirical norm . For a , define the event
where and are the constants in Theorem S4.1 in the Supplementary Material of Tuo and Zou (2026).
Lemma EC.1 ( bound on a good-design event). Suppose the conditions of Proposition 1 hold. Then, for any fixed , there exist constants , , and an integer , all independent of and , such that the following two statements hold for every . (i) Let . The event holds with a large probability,
(EC.4)
(ii) For every and every realization ,
(EC.5)
The proof of Lemma EC.1 relies on the smoothing-regime bound in Lemma S5.1 in the Supplementary Material of Tuo and Zou (2026). Applying this bound in our setting requires verifying several conditions. To make these conditions explicit and the subsequent argument easier to follow, we first restate Lemma S5.1 of Tuo and Zou (2026) in our notation as Lemma EC.2.
Lemma EC.2 (Lemma S5.1 of Tuo and Zou 2026). Let and be the KRR estimator fitted to the responses with regularization parameter . Suppose there exist constants and such that
(EC.6)
Suppose further that the design satisfies for all and for some constants satisfying . Then
(EC.7) ec3
With Lemma EC.2 in place, we now prove Lemma EC.1.
Proof of Lemma EC.1 Under Assumption 3, Theorem S4.1 of Tuo and Zou (2026) implies that there exist constants , independent of and the design points, such that for every , . For the prescribed , let , where is chosen sufficiently large so that . Then . Since , there exists an integer such that for all . Consequently, for every , . Therefore, , which establishes Equation (EC.4) for all .
We next prove Equation (EC.5). We follow the argument in the proof of Theorem S2.3 of Tuo and Zou (2026), particularly their Equations (S5.61)–(S5.62), to bound the stochastic error . For each fixed , define the stochastic process , indexed by . Then . Fix any . By the triangle inequality,
(EC.8)
In the following, we bound the two terms in the right hand side of Equation (EC.8) separately. For the first term, we equip with a semimetric that controls the increments of and apply a generic chaining inequality of Dirksen (2015). The second term is controlled directly using a sub-Gaussian tail bound.
Now we bound the first term in Equation (EC.8). Conditional on , the process is centered. Let denote the noise vector defined above. By the closed-form KRR representation and , we have . We now construct a semimetric using the KRR representation. For each , define the kernel section , and let denote the KRR estimator fitted to the responses . Since , the closed-form KRR representation gives . Evaluating at the training points and subtracting yields
Consequently, . For , define and . Then
(EC.9)
Since the noise variables are conditionally independent and sub-Gaussian, the conditional fluctuations of these increments in Equation (EC.9) are controlled by . We therefore define the following semimetric on to control the increments of :
(EC.10) ec4
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
This is a semimetric on X. By Equation (EC.2) and the conditional independence of ,
A Chernoff bound therefore yields
In the terminology of Dirksen (2015), a stochastic process is a -process with respect to a semimetric if its increments satisfy for all . Thus, conditional on , is a -process with respect to , and the semimetric is independent of . This verifies the conditions required for Theorem 3.2 of Dirksen (2015). Applying that theorem, we get a generic chaining inequality for the increment of the stochastic process . That is, for any fixed and every ,
\mathbb{P}\left(\sup_{x\in\mathcal{X}}\left|\mathbb{G}_{n,z}(x)-\mathbb{G}_{n,z}(x_{0})\right|\geq e^{1/2}\left\{C_{D}\gamma_{2}(\mathcal{X},\mathfrak{d}_{n})+u D_{D}\Delta_{\mathfrak{d}_{n}}(\mathcal{X})\right\}\right|X_{1:n}\right)\leq\exp\left(-u^{2}/2\right),(EC.11)
where are universal constants. Here is the diameter of under the semimetric , and is the generic-chaining functional, which admits the standard entropy bound
(EC.12)
where is a universal constant and denotes the covering number of under at radius . We next bound these two quantities on .
We first bound the diameter . Recall that . By the reproducing property, for every , . Since , the Sobolev interpolation inequality and the norm equivalence between and imply
where is independent of . Thus, condition (EC.6) holds for with and , uniformly over . Moreover, on , the norm equivalence between and gives
for some constant . Since , we have for all sufficiently large . Hence, the conditions of Lemma EC.2 are satisfied. Applying that lemma, we obtain
(EC.13) ec5
uniformly over . For any , , and hence, by Equation (EC.13),
(EC.14)
Substituting this bound into Equation (EC.10) yields uniformly over . Therefore,
(EC.15)
We next bound . Fix any . Since , the Sobolev embedding and the norm equivalence between and imply that
By the reproducing property,
Since is the KRR estimator fitted to the responses , comparing its regularized empirical objective with that of gives \|\hat{\phi}_{x,x'} - \phi_{x,x'}\|_n^2 + \lambda_n \|\hat{\phi}_{x,x'}\|_H_\nu^2 \leq \lambda_n \|\phi_{x,x'}\|_H_\nu^2. Consequently, . Substituting this bound into Equation (EC.10) yields
(EC.16)
By Equation (EC.16), any Euclidean cover of with radius is also an -cover under . Hence, . Since is a bounded subset of , the standard Euclidean covering number bound gives
(EC.17)
For convenience, let and . Combining Equations (EC.12), (EC.15), and (EC.17), we obtain
ec6
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
In the preceding inequalities, denotes a generic constant that may differ from one occurrence to another but is independent of , , and the design points. The last inequality holds for all sufficiently large , since and is fixed. Therefore,
(EC.18)
Fix any . Substituting Equations (EC.15) and (EC.18) into Equation (EC.11), we obtain, for every realization and every ,
(EC.19)
where c, C > 0 are independent of z.
Now we bound the second term in Equation (EC.8). From , Equation (EC.2) implies, conditional on ,
Using Equation (EC.13), for every , . Therefore, the standard sub-Gaussian tail bound gives, for every ,
(EC.20)
Equations (EC.8), (EC.19) and (EC.20), together with a union bound, imply that for every realization and every ,
(EC.21)
Choose , where is sufficiently large. Since , , and can be chosen so that for all sufficiently large . Hence, after enlarging if necessary, Equation (EC.21) yields
for every realization and all sufficiently large . Together with Equation (EC.4), this proves the two assertions of Lemma EC.1.
Having established a bound for the stochastic error on the good-design event , we next control the conditional bias on the same event and combine the two bounds to yield the fixed-decision sup-norm result in Lemma EC.3.
ec7
Lemma EC.3 (Fixed-decision sup-norm bound for KRR). Suppose the conditions of Proposition 1 hold. Then, for every fixed A > 0, there exist constants and , independent of z, such that for all and all ,
(EC.22)
Proof of Lemma EC.3 Recall that and . By Assumption 4 and the norm equivalence between and , there exists a constant , independent of , such that
(EC.23)
Conditional on , is the KRR estimator based on the responses . By the defining optimality inequality for KRR,
(EC.24)
and hence , and . Since , the definition of and the norm equivalence between and imply, on ,
Applying the Sobolev interpolation inequality and Equation (EC.23), we obtain the following bound for on :
(EC.25)
where C is independent of z.
We now compare and . Since , we know
Furthermore, because , we have
(EC.26)
It follows from Equations (EC.25), (EC.5), (EC.3) and (EC.26) that, for every realization of belonging to ,
(EC.27) ec8
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
Combining Equation (EC.27) with the design-event probability bound (EC.4) yields
(EC.28)
Recalling that , Equation (EC.28) is exactly Equation (EC.22). All constants above depend only on A, M, the uniform Sobolev bound in Assumption 4, the density bounds in Assumption 3, and the kernel and domain parameters, and therefore can be chosen independently of z. This completes the proof.
Lemma EC.3 establishes a high-probability sup-norm error bound for the estimated objective function at each fixed , with constants independent of . To control the supremum over in Equation (EC.1), we need to establish a bound that holds simultaneously for all . We therefore use a covering-number argument to extend the fixed-decision result and obtain the expected uniform approximation error in Lemma EC.4.
Lemma EC.4 (Uniform approximation error for KRR). Suppose the conditions of Proposition 1 hold. Then, the KRR-weighted objective in Equation (4) satisfies
(EC.29)
Proof of Lemma EC.4 Fix . By the compactness of in Assumption 1, there exists an -net with for all sufficiently small , where is independent of (Chapter 4.2 of Vershynin 2018). For any , choose such that . By the uniform Lipschitz condition in Assumption 1, we have for all . Moreover, by Equation (4),
We next bound the -norm of the KRR weights. Since and , we have , where denotes the operator norm induced by the Euclidean norm. Moreover, the boundedness of on implies . By the Cauchy–Schwarz inequality, we have . Using the closed-form representation of the KRR weights and the definition of the operator norm, we obtain
For any , choose such that . By the triangle inequality and the preceding bounds, for every ,
ec9
Taking the supremum over and , we obtain
(EC.30)
Choose . Since , the discretization term in Equation (EC.30) satisfies . Moreover, since , we have
Therefore, the covering-number bound gives . Applying the fixed-decision bound (EC.22) to all points in and using the union bound, we obtain
Combining this bound with Equation (EC.30) and the choice of , we obtain
(EC.31)
Since Equation (EC.22) holds for any fixed , we choose . Then, for some , the right-hand side of Equation (EC.31) is bounded by .
We next derive the expected uniform approximation error. By Assumption 1, we have and uniformly over and . Together with the preceding bound on the KRR weights, this gives . Combining this deterministic bound with Equation (EC.31), we obtain
where the last equality follows from and
Finally, because , we have
Since , we obtain Equation (EC.29). Therefore, we complete the proof.
It remains to combine the uniform approximation bound in Lemma EC.4 with the regret decomposition in Equation (EC.1) to prove Proposition 1.
ec10
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
Proof of Proposition 1 For each , let . Such a minimizer exists because is compact and is continuous. Similarly, exists because is continuous on compact . By Equation (EC.1), we have . Taking expectations over on the both sides yields
Applying Lemma EC.4 to the right-hand side of the above inequality, we complete the proof. ☐
EC.1.2. Proof of Theorem 1
We prove Theorem 1 by constructing a finite subclass of problem instances in . The subclass consists of a common quadratic cost function and a finite collection of data-generating models for , whose induced conditional objectives are infinitely differentiable in . We show that, for any PtO procedure satisfying Assumption 6, the expected regret averaged over this subclass is bounded below by a constant multiple of . Since the worst-case expected regret over is at least this average, the desired lower bound follows.
Proof of Theorem 1 For notational simplicity, write . To construct the finite subclass of problem instances we consider the following collection of conditional mean functions: , where, for , for all , and .
For each , we construct a problem instance by specifying the joint distribution of . Let . Fix a constant , which determines the noise level in the outcome. Let be independent of and satisfy . For each , define , and let denote the resulting joint distribution of . Since has mean zero and variance ,
for every . Let and . Since for every and , and with , the support of under every is contained in . We therefore define as the outcome space for .
For the problem instances constructed here, we take the feasible set to be . For all instances in the subclass, use the same cost function
The cost does not depend explicitly on x. It is convex in z, and for and ,
ec11
which is uniformly Lipschitz in . Moreover, . Hence all instances satisfy Assumption 1 with fixed constants , , and .
The induced conditional objective under is . Since every is a polynomial of degree at most two, is -times continuously differentiable for every nonnegative integer , with all derivatives up to order uniformly bounded over and . In addition, the covariate density is identically one on , and the conditional variance of is exactly . Therefore, . It is therefore sufficient to lower bound the average regret over this finite subclass. In particular,
(EC.32)
We next lower bound the last quantity. The analysis is divided into four steps.
Step 1: We first show that, under the constructed quadratic objective, the decision regret is proportional to the squared estimation error. We then apply the standard bias–variance decomposition to express the expected regret in terms of the squared bias and variance of the weighted estimator.
Fix a query point and training covariates . By Assumption 6, the weights depend only on and are then deterministic after conditioning on and . Define the normalized weights . Assumption 6 implies and .
Under , the empirical PtO objective can be written as
Since every and the normalized weights form a convex combination, . Hence the minimizer over the compact feasible set is exactly . Similarly, since , . Consequently,
Define the conditional bias
(EC.33)
and the variance proxy . Since , where are conditionally independent, mean zero, and have variance , we have . Therefore, we have the decomposition,
(EC.34) ec12
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
Step 2: To establish a lower bound on the average squared bias over the finite subclass, we exploit its construction to relate this average to a geometric quantity that depends only on the training covariates and the PtO weights, rather than on the individual problem instances. Specifically, define the spatial dispersion of the weights around the query point by
A smaller indicates that the weights are concentrated on observations close to the query point, whereas a larger indicates that more weight is assigned to observations farther away.
For the quadratic function , the conditional bias is , whereas for , the conditional bias is . Expanding and using gives the exact identity . Since , we have , and hence . By the Cauchy–Schwarz inequality,
Therefore,
(EC.35)
Define the average conditional regret over the finite subclass by
Combining Equations (EC.34) and (EC.35), we obtain
(EC.36)
Step 3: In this step, we give a lower bound on by establishing a tradeoff between the spatial dispersion and the variance proxy . By the Cauchy–Schwarz inequality, reducing requires spreading the weights across more observations, which, combined with the spatial distribution of the training covariates, forces a larger on a suitable event. This tradeoff yields a lower bound on .
For a fixed query point , let and define . Let denote the volume of the Euclidean unit ball in . Since is uniform on , uniformly over . For , define . Then . Since , it is stochastically dominated by . Writing and applying the standard Chernoff bound,
ec13
Define the event . By the union bound, and
(EC.37)
Let denote the distance from x to its kth nearest training covariate. Then, . This event ensures that the kth nearest training covariate cannot be too close to the query point x, preventing the training covariates from being excessively concentrated around x. Consequently, spreading the weights across more observations to reduce necessarily assigns substantial weight to observations farther from x, providing a lower bound on the spatial dispersion . We now formalize this intuition by considering two cases according to the value of .
Case 1: . By Cauchy–Schwarz inequality, , so . Define . On , we have , while ensures . Let denote the indices of the nearest training covariates to . By Cauchy–Schwarz inequality,
(EC.38)
Hence the total weight outside the nearest neighbors satisfies . On the event , every point outside is at distance at least from . Therefore,
(EC.39)
Since , the inequality for gives . Substituting this into Equation (EC.39) yields
(EC.40)
where . Combining Equations (EC.36) and (EC.40), on we have
where , and . Let . For , define . Elementary calculus gives the minimizer , and hence
(EC.41)
where . Thus, on , .
Case 2: . In this case, the variance term in Equation (EC.36) alone gives . Since for , . The two cases partition the sample space. Therefore, with , we obtain, on , .
ec14
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
Step 4: We finally complete the minimax lower bound. Taking expectation with respect to the common training-covariate law and using together with Equation (EC.37),
(EC.42)
The bound is uniform in . Let be an independent test covariate drawn from the same uniform distribution. Integrating Equation (EC.42) with respect to gives
Consequently,
Since , we conclude that
where . Finally, by the tower property,
Therefore,
Therefore, we complete the proof.
EC.2. Proofs in Section 4
In this section, we prove Lemmas 1–2, Theorem 2, and Remark 3 respectively.
EC.2.1. Proof of Lemma 1
Proof. We suppress the conditioning on and in the notation and write expectations and probabilities with respect to the simulation draws . For any , we have and . Then,
which implies
(EC.43) ec15
Define the empirical objective error process , where are i.i.d. Taking expectations on both sides of Equation (EC.43),
(EC.44)
Thus it remains to bound .
We bound the expected supremum by a multiscale covering argument. Fix a reference point and define for , set . Without loss of generality, we assume . For each , choose an -net , and write . The volumetric covering bound (see Proposition 4.2.12 of Vershynin 2018) gives
For every , choose such that , and set . Then
Define the nonempty finite set . In particular, .
We first control the empirical increments on . For , define , . By Assumption 1, . Moreover,
Hoeffding’s lemma and independence of the simulation draws imply that, for every ,
Thus every increment is centered and sub-Gaussian with parameter . For every ,
where the first inequality holds by Jensen’s inequality and the second inequality holds by applying the exponential bound to both signs of all increments. Optimizing over yields
Since and for , we have . Consequently,
ec16
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
We next sum these increments across scales. Because both and are G-Lipschitz on , we have . For any integer , the telescoping identity
therefore gives
At the fixed reference point , independence and the bounded-cost assumption give
Taking expectations in the supremum bound yields
Since for and . Letting , we conclude that
Finally, applying the regret comparison established above gives
Thus we may take . Therefore, we complete the proof.
EC.2.2. Proof of Lemma 2
Proof. By Assumption 1, we have for all , so a standard characterization of total variation distance (via test functions with bounded range) yields
(EC.45)
Taking expectations with respect to X and then with respect to yields
Applying Assumption 7, we have Equation (12). Therefore, we complete the proof. ☐
EC.2.3. Proof of Theorem 2
Proof. Taking expectations with respect to X and then with respect to on both sides of Equation (9), and applying Lemmas 1 and 2 yields
Setting gives Equation (15). Therefore, we complete the proof. ☐ ec17
EC.2.4. Proof of Remark 3
In this section, we prove Equation (16) in Remark 3. We continue to use the notations in Section 4. Specifically, we denote as the conditional distribution of conditioned on . On the offline stage, we use the historical data to learn the conditional distribution or a simulator for , denoted as . On the online stage, when a new covariate arrives, we generate i.i.d. samples from , denoted as . Then, we can use SAA to construct a sample objective function and solve the simulation-based CSO problem accordingly as
(EC.46)
To isolate the impact of the model error from the SAA error, we define an auxiliary decision rule as
(EC.47)
where . Then we have the basic decomposition
(EC.48)
We discuss the SAA error and model error separately, and then summarize their combined impact on the decision error. Throughout this subsection, Assumption 1 remains in force. We additionally impose the following differentiability, smoothness, and strong-convexity conditions.
Assumption EC.1. Suppose that
(a) The feasible set is nonempty, convex, and compact, with diameter
(b) For every , the cost function is continuously differentiable on , and there exists a constant such that for all and all ,
(c) The cost function is uniformly -strongly convex and has uniform L-Lipschitz gradient on , i.e., there exist constants and such that for all and all ,
ec18
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
Assumption EC.1(a) is standard in stochastic programming and guarantees that minimizers exist, see, e.g., Shapiro et al. (2009, Chapter 5). Assumptions EC.1(b)–(c) impose uniform smoothness and strong convexity of the cost function with respect to z, uniformly over ; such conditions are routinely used in the analysis of M-estimators and SAA problems to obtain stability and convergence rates for the minimizers; see, e.g., Shapiro et al. (2009, Chapter 5) and van der Vaart (1998, Chapter 5); they are also used in the literature of CSO problem, see, e.g., Hu et al. (2020a,b) and some references in the survey paper Sadana et al. (2025).
EC.2.4.1. The SAA Error. We analyze the first term in the right-hand side of Equation (EC.48), i.e., the term . We fix the covariate value , and treat the offline data and the learned distribution or simulator as given. All expectations are taken with respect to the simulation draws conditional on and .
Lemma EC.5. Suppose Assumption EC.1 holds. Fix a covariate value and a realization of the learned conditional distribution or simulator . Then there exists a constant , depending only on , such that for all ,
(EC.49)
Lemma EC.5 shows that, once the simulator is fixed, the SAA-based decision converges to the population decision at the usual Monte Carlo rate which reflects the fact that is an empirical average of i.i.d. samples. In the proof, we bound the gradient error and transfer it to decision error by using the strong monotonicity of the empirical objective’s gradient and the constrained optimality conditions.
Proof. We suppress the conditioning on and in the notation and write expectations with respect to the simulation draws . For brevity, write and . Assumption EC.1(b)–(c), together with the standing Assumption 1, implies that and are differentiable and -strongly convex on . Their minimizers are therefore unique. The constrained first-order optimality conditions are
Let . Taking in the first inequality and in the second gives
Combining with the strong monotonicity of the gradient of the empirical objective , the above constrained first-order optimality conditions, and Cauchy–Schwarz inequality, we have
ec19
If , the desired comparison is immediate. Otherwise, dividing by yields
Conditional on and , the population minimizer is fixed. Define and . The vectors are i.i.d., and almost surely. Furthermore,
For , independence and centering imply . Therefore,
Squaring the minimizer comparison and taking expectations gives . Finally, the Cauchy–Schwarz inequality yields
Restoring the conditioning and the original notation proves the claimed bound. Therefore, we complete the proof. □
EC.2.4.2. The Model Error. We now turn to the second term in Equation (EC.48), i.e., the term . We begin by quantifying how sensitive the optimal solution is to perturbations of the underlying conditional distribution, measured in total variation distance.
Lemma EC.6. Suppose Assumption EC.1 holds. Fix and let and be two probability measures on . Define
and let
Then both minimizers are unique, and
(EC.50)
where TV denotes the total variation distance. In particular, taking and yields
ec20
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
Lemma EC.6 states that the optimal solution is Lipschitz-continuous with respect to the underlying conditional distribution in total variation distance. Intuitively, if we change the distribution of only slightly (in total variation), then the expected gradient changes only slightly, and by strong convexity the minimizer cannot move far. This type of stability result is a direct consequence of the standard stability-of-argmin arguments used in M-estimation (see, e.g., van der Vaart 1998, Chapter 5) and in stochastic programming sensitivity analysis (see Shapiro et al. 2009, Chapter 5).
Proof. For brevity we write and for and , and and for the corresponding minimizers. By Assumption EC.1(c), for each the function is -strongly convex. Therefore, for any and ,
Taking expectations with respect to , we obtain
so is -strongly convex. Similarly is -strongly convex. Hence both have unique minimizers and . Because and are differentiable and convex, their constrained minimizers satisfy the variational inequalities
Taking in the first inequality and in the second gives
Let . Combining with the strong monotonicity of the gradient of the expected objective , the above constrained first-order optimality conditions, and Cauchy–Schwarz inequality, we have
If , the desired comparison is immediate. Otherwise, dividing by yields
(EC.51)
By the definitions of and , we have
For completeness, if a measurable vector-valued function satisfies , then
ec21
Applying this inequality with and using Assumption EC.1(b) gives
Combining this bound with Equation (EC.51) yields
which proves Equation (EC.50). Taking and gives the stated specialization. Therefore, we complete the proof.
To turn Lemma EC.6 into a quantitative bound on the average model error, we assume that the learned distribution or simulator is consistent in total variation on average over the covariate distribution.
Lemma EC.7. Suppose Assumptions EC.1 and 7 hold. Then
(EC.52)
where the inner expectation is with respect to X and the outer expectation is with respect to .
Lemma EC.7 shows that, under the stability result of Lemma EC.6 and the average total variation convergence of Assumption 7, the decision error due purely to model misspecification (i.e., using instead of ) decays at the same rate as the simulator itself in total variation. The constant is inflated by the inverse strong-convexity modulus and the gradient envelope , reflecting the sensitivity of the optimization problem to perturbations in the objective.
Proof. By Lemma EC.6 applied pointwise in and taking and , we have for every ,
Taking expectations with respect to X and then with respect to yields
Applying Assumption 7 to the right-hand side gives Equation (EC.52), and we complete the proof. ☐
EC.2.4.3. Decision Error Bound for GtO. We now combine the SAA error bound (Lemma EC.5) and the model error bound (Lemma EC.7) to obtain an overall bound on the decision error of the GtO procedure. Recall the decomposition (EC.48) for a fixed :
We now integrate this bound over the randomness in both the training data and the online covariate, and plug in the bounds obtained in the previous subsections.
ec22
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
Theorem EC.1. Suppose Assumptions EC.1 and 7 hold. Then there exists a constant , depending only on , such that for all integers ,
(EC.53)
where, conditional on , the inner expectation is with respect to the online covariate X and the conditional simulation draws, and the outer expectation is with respect to .
Theorem EC.1 provides a clean decomposition of the average decision error of the GtO procedure into: an offline learning error term, , which reflects how accurately the conditional distribution can be learned from samples, and an online SAA error term, , which reflects the Monte Carlo error from using simulated samples at decision time. In settings where , this yields the canonical rate
Theorem EC.1 makes explicit the trade-off between investing in more training data (larger n) and using more simulation at decision time (larger m). In particular, if one balances the two error terms by choosing m as a suitable function of n, the overall decision error can be minimized.
Proof. Taking expectations with respect to X and then with respect to to the result in Lemma EC.5 yields
(EC.54)
By Lemma EC.7, we have
By setting , we can rewrite the above bound and obtain Equation (EC.53). Therefore, we complete the proof.
EC.3. Numerical Study: Implementation and Supplementary Results
This section provides implementation details and supplementary results for Section 6.
EC.3.1. Contextual Newsvendor Problem
EC.3.1.1. Demand and Shortage-Cost Construction. Conditional demand follows a three-component Gaussian mixture representing low, regular, and high demand states. We divide the covariates into three groups according to their roles in the demand model. Seasonal factors are generated from a uniform distribution and transformed smoothly to determine the component means. Market and operational ec23
factors, such as traffic, discounts, and promotions, follow a lognormal distribution and determine the mixture probabilities. Risk-related factors, such as weather and recent demand history, follow a zero-mean multivariate normal distribution and determine the component variances. Given , demand is drawn from the resulting mixture and censored at zero. Across covariate dimensions, the parameters are calibrated to keep average demand and the signal-to-noise ratio comparable.
The shortage penalty reflects differences in service priorities and operating conditions. Let denote the risk-related covariates and define the priority score , with normalized so that is standard normal. We partition the score into 11 equal-probability intervals using for , where is the standard normal cumulative distribution function. Assigning increasing penalty levels from 30 to 120 gives
The penalty range produces different newsvendor critical fractiles. Because is a step function, the conditional objective can be discontinuous in x even though the conditional demand model varies smoothly.
We consider and . Each setting is evaluated on 100 test contexts over 30 independent replications. Direct PtO estimates the conditional objective, including the context-dependent penalty. Structure-aware PtO instead estimates and using the same prediction weights, and combines them as . This formulation incorporates the known penalty directly rather than estimating its discontinuities.
The empirical objective is piecewise linear in the one-dimensional order quantity. We optimize it by evaluating demand breakpoints. This approach also accommodates signed weights when the objective is bounded below. On the unrestricted domain , the terminal slope must be nonnegative, and the feasible endpoint must be included among the candidates. Thus, efficient optimization in this setting does not require convexity.
EC.3.1.2. Detailed Performance and Online Time. Tables EC.1 and EC.2 report the method-level relative costs for the direct and structure-aware formulations, respectively, corresponding to Panels (a) and (b) of Figure 2. Higher relative cost indicates better decision performance. The GtO results are identical across the two tables; the PtO columns report the respective formulations.
Tables EC.3 and EC.4 report online times for the two formulations. PtO generally requires hundredths of a second, whereas GtO takes approximately 0.49 to 6.57 seconds across the tested settings. At n = 10,000, structure-aware PtO takes approximately 0.013 to 0.042 seconds and GtO takes 0.76 to 2.80 seconds. These are the entries summarized in Table 2 in the main text.
ec24
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
Table EC.1 Relative cost for the newsvendor problem with the direct formulation.
| n | SAA | PtO-kNN | PtO-KS | PtO-KRR | GtO-CDM | ||
|---|---|---|---|---|---|---|---|
| 800 | 3 | 0.0000 | 0.9164 | 0.8912 | 0.9428 | 0.9331 | 0.7990 |
| 6 | 0.0000 | 0.7488 | 0.7006 | 0.8199 | 0.7847 | 0.7405 | |
| 10 | 0.0000 | 0.5462 | 0.5121 | 0.7477 | 0.5614 | 0.6948 | |
| 20 | 0.0000 | 0.3849 | 0.2462 | 0.6605 | 0.3887 | 0.6850 | |
| 40 | 0.0000 | 0.3578 | 0.0451 | 0.5754 | 0.3185 | 0.7452 | |
| 60 | 0.0000 | 0.1736 | 0.0321 | 0.3725 | 0.1759 | 0.5947 | |
| 100 | 0.0000 | 0.1473 | 0.0161 | 0.2473 | 0.1110 | 0.6070 | |
| 2000 | 3 | 0.0000 | 0.9519 | 0.9350 | 0.9647 | 0.9583 | 0.8378 |
| 6 | 0.0000 | 0.8157 | 0.7792 | 0.8609 | 0.8327 | 0.7714 | |
| 10 | 0.0000 | 0.6142 | 0.5520 | 0.7933 | 0.5948 | 0.7672 | |
| 20 | 0.0000 | 0.4641 | 0.3679 | 0.7148 | 0.4570 | 0.7074 | |
| 40 | 0.0000 | 0.4013 | 0.0476 | 0.6224 | 0.3836 | 0.7688 | |
| 60 | 0.0000 | 0.2353 | 0.0324 | 0.6418 | 0.1969 | 0.7202 | |
| 100 | 0.0000 | 0.1881 | 0.0159 | 0.4262 | 0.1071 | 0.7690 | |
| 5000 | 3 | 0.0000 | 0.9709 | 0.9550 | 0.9759 | 0.9576 | 0.9815 |
| 6 | 0.0000 | 0.8583 | 0.8376 | 0.9014 | 0.8778 | 0.8848 | |
| 10 | 0.0000 | 0.7040 | 0.5672 | 0.8488 | 0.7153 | 0.8128 | |
| 20 | 0.0000 | 0.5140 | 0.4227 | 0.7670 | 0.5101 | 0.7723 | |
| 40 | 0.0000 | 0.4722 | 0.1498 | 0.6402 | 0.4098 | 0.7935 | |
| 60 | 0.0000 | 0.2941 | 0.0315 | 0.6677 | 0.1978 | 0.7377 | |
| 100 | 0.0000 | 0.1915 | 0.0161 | 0.5654 | 0.1164 | 0.8012 | |
| 10000 | 3 | 0.0000 | 0.9800 | 0.9706 | 0.9826 | 0.9768 | 0.9916 |
| 6 | 0.0000 | 0.8794 | 0.8502 | 0.9117 | 0.8951 | 0.9213 | |
| 10 | 0.0000 | 0.7576 | 0.6897 | 0.8725 | 0.7584 | 0.8152 | |
| 20 | 0.0000 | 0.5548 | 0.4556 | 0.7931 | 0.5522 | 0.8191 | |
| 40 | 0.0000 | 0.4969 | 0.2449 | 0.8567 | 0.4427 | 0.8250 | |
| 60 | 0.0000 | 0.3178 | 0.0318 | 0.6878 | 0.2062 | 0.7550 | |
| 100 | 0.0000 | 0.2336 | 0.0159 | 0.6727 | 0.1209 | 0.7935 | |
| 20000 | 3 | 0.0000 | 0.9853 | 0.9776 | 0.9343 | 0.9717 | 0.9934 |
| 6 | 0.0000 | 0.8979 | 0.8754 | 0.7992 | 0.8891 | 0.9870 | |
| 10 | 0.0000 | 0.7534 | 0.7415 | 0.8040 | 0.7134 | 0.9122 | |
| 20 | 0.0000 | 0.6008 | 0.4711 | 0.8021 | 0.4864 | 0.8645 | |
| 40 | 0.0000 | 0.5450 | 0.3231 | 0.8389 | 0.4394 | 0.8859 | |
| 60 | 0.0000 | 0.3608 | 0.0316 | 0.6573 | 0.2587 | 0.7953 | |
| 100 | 0.0000 | 0.2553 | 0.0158 | 0.6004 | 0.1774 | 0.8447 | |
| 30000 | 3 | 0.0000 | 0.9856 | 0.9803 | 0.9899 | 0.9782 | 0.9943 |
| 6 | 0.0000 | 0.9127 | 0.8906 | 0.9152 | 0.8994 | 0.9911 | |
| 10 | 0.0000 | 0.8104 | 0.7713 | 0.8993 | 0.7105 | 0.9805 | |
| 20 | 0.0000 | 0.6185 | 0.4795 | 0.8435 | 0.4759 | 0.9619 | |
| 40 | 0.0000 | 0.5749 | 0.3705 | 0.8428 | 0.4340 | 0.9250 | |
| 60 | 0.0000 | 0.3631 | 0.0960 | 0.6566 | 0.2608 | 0.8590 | |
| 100 | 0.0000 | 0.2715 | 0.0161 | 0.6564 | 0.1741 | 0.8665 |
Note. Boldface indicates the method with the highest relative cost for each setting.
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
ec25
Table EC.2 Relative cost for the newsvendor problem with the structure-aware formulation.
| n | SAA | PtO-kNN | PtO-KS | PtO-KRR | GtO-CDM | ||
|---|---|---|---|---|---|---|---|
| 800 | 3 | 0.0000 | 0.8487 | 0.8682 | 0.9146 | 0.8923 | 0.7990 |
| 6 | 0.0000 | 0.7387 | 0.6762 | 0.8532 | 0.7643 | 0.7405 | |
| 10 | 0.0000 | 0.4599 | 0.4302 | 0.6594 | 0.4922 | 0.6948 | |
| 20 | 0.0000 | 0.4764 | 0.3474 | 0.7485 | 0.4409 | 0.6850 | |
| 40 | 0.0000 | 0.2879 | 0.0414 | 0.7113 | 0.2890 | 0.7452 | |
| 60 | 0.0000 | 0.3113 | 0.1251 | 0.5683 | 0.3208 | 0.5947 | |
| 100 | 0.0000 | 0.2091 | 0.0416 | 0.5503 | 0.1593 | 0.6070 | |
| 2000 | 3 | 0.0000 | 0.8486 | 0.9107 | 0.9429 | 0.9262 | 0.8378 |
| 6 | 0.0000 | 0.7784 | 0.7464 | 0.8753 | 0.8124 | 0.7714 | |
| 10 | 0.0000 | 0.5984 | 0.4822 | 0.7670 | 0.5954 | 0.7672 | |
| 20 | 0.0000 | 0.5242 | 0.4694 | 0.7902 | 0.5185 | 0.7074 | |
| 40 | 0.0000 | 0.3896 | 0.0410 | 0.7698 | 0.3431 | 0.7688 | |
| 60 | 0.0000 | 0.3443 | 0.1255 | 0.6429 | 0.3392 | 0.7202 | |
| 100 | 0.0000 | 0.2263 | 0.0407 | 0.6279 | 0.1670 | 0.7690 | |
| 5000 | 3 | 0.0000 | 0.9449 | 0.9335 | 0.9616 | 0.9396 | 0.9815 |
| 6 | 0.0000 | 0.8623 | 0.7966 | 0.8913 | 0.8612 | 0.8848 | |
| 10 | 0.0000 | 0.6538 | 0.6026 | 0.8196 | 0.6712 | 0.8128 | |
| 20 | 0.0000 | 0.5703 | 0.5049 | 0.8404 | 0.5982 | 0.7723 | |
| 40 | 0.0000 | 0.4445 | 0.1409 | 0.8048 | 0.3946 | 0.7935 | |
| 60 | 0.0000 | 0.4009 | 0.1300 | 0.6740 | 0.3760 | 0.7377 | |
| 100 | 0.0000 | 0.2104 | 0.0413 | 0.6608 | 0.1776 | 0.8012 | |
| 10000 | 3 | 0.0000 | 0.9600 | 0.9575 | 0.9740 | 0.9666 | 0.9916 |
| 6 | 0.0000 | 0.8892 | 0.8248 | 0.9211 | 0.8812 | 0.9213 | |
| 10 | 0.0000 | 0.6933 | 0.6273 | 0.8227 | 0.6804 | 0.8152 | |
| 20 | 0.0000 | 0.6128 | 0.5362 | 0.8457 | 0.6146 | 0.8191 | |
| 40 | 0.0000 | 0.4889 | 0.2519 | 0.8226 | 0.4128 | 0.8250 | |
| 60 | 0.0000 | 0.4249 | 0.1285 | 0.7012 | 0.3811 | 0.7550 | |
| 100 | 0.0000 | 0.2621 | 0.0406 | 0.6846 | 0.1880 | 0.7935 | |
| 20000 | 3 | 0.0000 | 0.9617 | 0.9571 | 0.9730 | 0.9653 | 0.9934 |
| 6 | 0.0000 | 0.9075 | 0.8282 | 0.9122 | 0.8868 | 0.9870 | |
| 10 | 0.0000 | 0.7177 | 0.6887 | 0.8156 | 0.6577 | 0.9122 | |
| 20 | 0.0000 | 0.6688 | 0.5594 | 0.8731 | 0.5333 | 0.8645 | |
| 40 | 0.0000 | 0.5194 | 0.2366 | 0.8194 | 0.3926 | 0.8859 | |
| 60 | 0.0000 | 0.4593 | 0.1279 | 0.7693 | 0.3761 | 0.7953 | |
| 100 | 0.0000 | 0.2992 | 0.0408 | 0.7065 | 0.2194 | 0.8447 | |
| 30000 | 3 | 0.0000 | 0.9754 | 0.9681 | 0.9804 | 0.9723 | 0.9943 |
| 6 | 0.0000 | 0.9177 | 0.8700 | 0.9065 | 0.8299 | 0.9911 | |
| 10 | 0.0000 | 0.7911 | 0.7149 | 0.8062 | 0.5109 | 0.9805 | |
| 20 | 0.0000 | 0.6579 | 0.5797 | 0.8004 | 0.4252 | 0.9619 | |
| 40 | 0.0000 | 0.5419 | 0.3121 | 0.7442 | 0.2221 | 0.9250 | |
| 60 | 0.0000 | 0.4958 | 0.1269 | 0.7814 | 0.2320 | 0.8590 | |
| 100 | 0.0000 | 0.3338 | 0.0401 | 0.7060 | 0.2195 | 0.8665 |
Note. Boldface indicates the method with the highest relative cost for each setting.
ec26
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
Table EC.3 Running time for the newsvendor problem with the direct formulation.
| n | SAA | PtO-KNN | PtO-KS | PtO-KRR | GtO-CDM | ||
|---|---|---|---|---|---|---|---|
| 800 | 3 | 0.0000 | 0.0248 | 0.0231 | 0.0276 | 0.0257 | 0.4937 |
| 6 | 0.0000 | 0.0285 | 0.0242 | 0.0337 | 0.0294 | 0.6161 | |
| 10 | 0.0000 | 0.0143 | 0.0109 | 0.0178 | 0.0131 | 0.7875 | |
| 20 | 0.0000 | 0.0176 | 0.0145 | 0.0298 | 0.0224 | 0.9506 | |
| 40 | 0.0000 | 0.0114 | 0.0107 | 0.0261 | 0.0068 | 1.4974 | |
| 60 | 0.0000 | 0.0098 | 0.0057 | 0.0256 | 0.0106 | 1.5247 | |
| 100 | 0.0000 | 0.0055 | 0.0018 | 0.0169 | 0.0064 | 1.5552 | |
| 2000 | 3 | 0.0067 | 0.0088 | 0.0092 | 0.0096 | 0.0099 | 0.4896 |
| 6 | 0.0112 | 0.0156 | 0.0147 | 0.0151 | 0.0159 | 0.6133 | |
| 10 | 0.0071 | 0.0093 | 0.0095 | 0.0098 | 0.0101 | 0.7868 | |
| 20 | 0.0157 | 0.0142 | 0.0146 | 0.0155 | 0.0163 | 0.9505 | |
| 40 | 0.0069 | 0.0090 | 0.0094 | 0.0097 | 0.0100 | 1.4969 | |
| 60 | 0.0106 | 0.0137 | 0.0141 | 0.0146 | 0.0150 | 1.5221 | |
| 100 | 0.0068 | 0.0089 | 0.0091 | 0.0096 | 0.0099 | 1.5556 | |
| 5000 | 3 | 0.0132 | 0.0174 | 0.0171 | 0.0195 | 0.0188 | 0.4875 |
| 6 | 0.0211 | 0.0286 | 0.0278 | 0.0294 | 0.0291 | 0.6135 | |
| 10 | 0.0129 | 0.0178 | 0.0174 | 0.0186 | 0.0182 | 0.7869 | |
| 20 | 0.0219 | 0.0291 | 0.0283 | 0.0297 | 0.0302 | 0.9508 | |
| 40 | 0.0127 | 0.0172 | 0.0168 | 0.0184 | 0.0181 | 1.4963 | |
| 60 | 0.0208 | 0.0275 | 0.0269 | 0.0287 | 0.0282 | 1.5193 | |
| 100 | 0.0131 | 0.0177 | 0.0173 | 0.0185 | 0.0180 | 1.5508 | |
| 10000 | 3 | 0.0214 | 0.0287 | 0.0276 | 0.0315 | 0.0308 | 0.7556 |
| 6 | 0.0136 | 0.0184 | 0.0177 | 0.0196 | 0.0192 | 1.0644 | |
| 10 | 0.0221 | 0.0289 | 0.0282 | 0.0305 | 0.0308 | 1.3747 | |
| 20 | 0.0139 | 0.0181 | 0.0174 | 0.0191 | 0.0190 | 1.6678 | |
| 40 | 0.0224 | 0.0292 | 0.0288 | 0.0312 | 0.0310 | 2.6496 | |
| 60 | 0.0134 | 0.0180 | 0.0171 | 0.0203 | 0.0197 | 2.7344 | |
| 100 | 0.0216 | 0.0281 | 0.0279 | 0.0301 | 0.0310 | 2.7950 | |
| 20000 | 3 | 0.0146 | 0.0191 | 0.0188 | 0.0217 | 0.0210 | 1.3742 |
| 6 | 0.0235 | 0.0301 | 0.0305 | 0.0332 | 0.0318 | 1.9059 | |
| 10 | 0.0143 | 0.0190 | 0.0184 | 0.0201 | 0.0207 | 2.5172 | |
| 20 | 0.0231 | 0.0306 | 0.0297 | 0.0314 | 0.0328 | 3.0537 | |
| 40 | 0.0145 | 0.0192 | 0.0186 | 0.0200 | 0.0197 | 4.9494 | |
| 60 | 0.0234 | 0.0298 | 0.0295 | 0.0311 | 0.0314 | 5.1321 | |
| 100 | 0.0141 | 0.0190 | 0.0185 | 0.0198 | 0.0196 | 5.2524 | |
| 30000 | 3 | 0.0247 | 0.0312 | 0.0317 | 0.0351 | 0.0354 | 1.6722 |
| 6 | 0.0152 | 0.0201 | 0.0196 | 0.0214 | 0.0208 | 2.3431 | |
| 10 | 0.0241 | 0.0320 | 0.0305 | 0.0332 | 0.0328 | 3.1093 | |
| 20 | 0.0156 | 0.0198 | 0.0193 | 0.0209 | 0.0211 | 3.7524 | |
| 40 | 0.0243 | 0.0310 | 0.0314 | 0.0325 | 0.0328 | 6.1713 | |
| 60 | 0.0151 | 0.0202 | 0.0192 | 0.0206 | 0.0207 | 6.3927 | |
| 100 | 0.0250 | 0.0313 | 0.0316 | 0.0324 | 0.0329 | 6.5674 |
Note. Running time is reported in seconds and averaged over 30 independent replications.
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
ec27
Table EC.4 Running time for the newsvendor problem with the structure-aware formulation.
| n | SAA | PtO-KNN | PtO-KS | PtO-KRR | GtO-CDM | ||
|---|---|---|---|---|---|---|---|
| 800 | 3 | 0.0000 | 0.0294 | 0.0257 | 0.0254 | 0.0309 | 0.4937 |
| 6 | 0.0000 | 0.0429 | 0.0239 | 0.0303 | 0.0354 | 0.6161 | |
| 10 | 0.0000 | 0.0149 | 0.0140 | 0.0126 | 0.0117 | 0.7875 | |
| 20 | 0.0000 | 0.0125 | 0.0220 | 0.0409 | 0.0149 | 0.9506 | |
| 40 | 0.0000 | 0.0100 | 0.0148 | 0.0388 | 0.0054 | 1.4974 | |
| 60 | 0.0000 | 0.0123 | 0.0084 | 0.0200 | 0.0122 | 1.5247 | |
| 100 | 0.0000 | 0.0076 | 0.0019 | 0.0137 | 0.0049 | 1.5552 | |
| 2000 | 3 | 0.0067 | 0.0057 | 0.0113 | 0.0096 | 0.0123 | 0.4896 |
| 6 | 0.0112 | 0.0230 | 0.0115 | 0.0102 | 0.0113 | 0.6133 | |
| 10 | 0.0071 | 0.0063 | 0.0139 | 0.0111 | 0.0082 | 0.7868 | |
| 20 | 0.0157 | 0.0178 | 0.0106 | 0.0202 | 0.0209 | 0.9505 | |
| 40 | 0.0069 | 0.0113 | 0.0088 | 0.0132 | 0.0082 | 1.4969 | |
| 60 | 0.0106 | 0.0112 | 0.0121 | 0.0176 | 0.0120 | 1.5221 | |
| 100 | 0.0068 | 0.0081 | 0.0079 | 0.0113 | 0.0141 | 1.5556 | |
| 5000 | 3 | 0.0132 | 0.0131 | 0.0154 | 0.0243 | 0.0162 | 0.4875 |
| 6 | 0.0211 | 0.0377 | 0.0193 | 0.0222 | 0.0183 | 0.6135 | |
| 10 | 0.0129 | 0.0227 | 0.0109 | 0.0248 | 0.0199 | 0.7869 | |
| 20 | 0.0219 | 0.0431 | 0.0298 | 0.0253 | 0.0339 | 0.9508 | |
| 40 | 0.0127 | 0.0110 | 0.0140 | 0.0221 | 0.0123 | 1.4963 | |
| 60 | 0.0208 | 0.0327 | 0.0324 | 0.0193 | 0.0352 | 1.5193 | |
| 100 | 0.0131 | 0.0130 | 0.0230 | 0.0127 | 0.0273 | 1.5508 | |
| 10000 | 3 | 0.0214 | 0.0392 | 0.0331 | 0.0338 | 0.0251 | 0.7556 |
| 6 | 0.0136 | 0.0268 | 0.0208 | 0.0294 | 0.0199 | 1.0644 | |
| 10 | 0.0221 | 0.0350 | 0.0373 | 0.0405 | 0.0285 | 1.3747 | |
| 20 | 0.0139 | 0.0218 | 0.0206 | 0.0146 | 0.0150 | 1.6678 | |
| 40 | 0.0224 | 0.0250 | 0.0420 | 0.0207 | 0.0202 | 2.6496 | |
| 60 | 0.0134 | 0.0211 | 0.0235 | 0.0214 | 0.0125 | 2.7344 | |
| 100 | 0.0216 | 0.0301 | 0.0298 | 0.0210 | 0.0314 | 2.7950 | |
| 20000 | 3 | 0.0146 | 0.0168 | 0.0285 | 0.0263 | 0.0142 | 1.3742 |
| 6 | 0.0235 | 0.0440 | 0.0318 | 0.0466 | 0.0251 | 1.9059 | |
| 10 | 0.0143 | 0.0223 | 0.0147 | 0.0174 | 0.0147 | 2.5172 | |
| 20 | 0.0231 | 0.0239 | 0.0364 | 0.0378 | 0.0475 | 3.0537 | |
| 40 | 0.0145 | 0.0288 | 0.0237 | 0.0167 | 0.0162 | 4.9494 | |
| 60 | 0.0234 | 0.0371 | 0.0352 | 0.0291 | 0.0200 | 5.1321 | |
| 100 | 0.0141 | 0.0119 | 0.0134 | 0.0148 | 0.0267 | 5.2524 | |
| 30000 | 3 | 0.0247 | 0.0228 | 0.0357 | 0.0292 | 0.0408 | 1.6722 |
| 6 | 0.0152 | 0.0220 | 0.0283 | 0.0279 | 0.0310 | 2.3431 | |
| 10 | 0.0241 | 0.0327 | 0.0336 | 0.0362 | 0.0373 | 3.1093 | |
| 20 | 0.0156 | 0.0245 | 0.0186 | 0.0130 | 0.0151 | 3.7524 | |
| 40 | 0.0243 | 0.0388 | 0.0252 | 0.0339 | 0.0459 | 6.1713 | |
| 60 | 0.0151 | 0.0251 | 0.0172 | 0.0247 | 0.0248 | 6.3927 | |
| 100 | 0.0250 | 0.0301 | 0.0427 | 0.0408 | 0.0297 | 6.5674 |
Note. Running time is reported in seconds and averaged over 30 independent replications.
ec28
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
EC.3.2. Product Placement Problem
EC.3.2.1. Network and Demand Construction. A retailer operates stores connected by a directed transportation network , where . After observing , the retailer chooses initial inventory at cost . Once demand is realized, inventory can be transferred between stores. Let denote transfers and unmet demand. The incidence matrix has entries 1 at an arc's origin and -1 at its destination, so is net outflow and is inventory after transfers.
Given z and demand y, the recourse problem minimizes transportation and shortage costs:
where and are unit transportation and shortage costs. The initial placement decision minimizes over , where specifies store-level inventory upper bounds.
We extend the newsvendor’s three-component Gaussian mixture to multivariate demand. Each store has the same marginal model specification, with dependence introduced so that stores closer in the network have stronger demand correlations. Demand is censored at zero coordinatewise. The network contains directed arcs: form a ring, and the remaining are generated randomly once per replication. We fix and and vary . Average demand and marginal variability at each store are calibrated to remain comparable across dimensions. Unit placement, transportation, and shortage costs are 2, 1, and 10, respectively.
EC.3.2.2. Optimization with Nonnegative and Signed Weights. The weighted problem minimizes over , where are observed or generated demand scenarios and their weights. With nonnegative weights, the scenario recourse problems can be incorporated into the outer minimization, yielding the linear program
(PP-LP)
This formulation applies to SAA, nonnegative-weight PtO methods, and GtO, which assigns equal weights to generated scenarios.
Signed KRR weights require a different treatment. The recourse problem has the dual representation , where . For , this implies ec29
. Define and . Using the primal representation for nonnegative weights and the dual representation for negative weights gives
(PP-KRR)
When is empty, (PP-KRR) reduces to (PP-LP). Otherwise, the products introduce bilinear terms, producing a generally nonconvex formulation. Gurobi's global optimization procedure can address this formulation, but may become computationally expensive as the number of scenarios and decision dimension increase.
We instead exploit the difference-of-convex decomposition
Both C and H are convex because is convex. At each DCA iteration, we replace by its affine approximation using a subgradient of H at the current iterate, then solve the resulting convex subproblem with Gurobi. DCA does not generally certify global optimality, so the reported decision quality and runtime reflect this implementation. Table 3 in the main paper reports the results for all five demand dimensions.
EC.3.3. Real Case Study: KRR with Categorical Covariates
In the real-case experiment, categorical variables are represented using one-hot encoding, resulting in binary indicators. For KRR, we use the Gaussian kernel
where is the kernel bandwidth parameter. Since the Gaussian kernel only depends on the squared Euclidean distance between covariate vectors, binary indicators can be treated in the same way as continuous covariates. Specifically, for each binary indicator , its multiplicative contribution to the kernel is
Thus, matching indicator values leave the kernel similarity unchanged, whereas differing values introduce a discount factor of , reducing the similarity between the two observations. Consequently, one-hot-encoded categorical variables can be naturally incorporated into the Gaussian kernel alongside continuous covariates by directly evaluating the kernel on the full covariate vectors and .
ec30
Hong, Huang, and Li: Contextual Decision Making: Predictive or Generative
References
Dirksen S (2015) Tail bounds via generic chaining. Electron. J. Probab. 20(53):1–29.
Hu Y, Chen X, He N (2020a) Sample complexity of sample average approximation for conditional stochastic optimization. SIAM J. Optim. 30(3):2103–2133.
Hu Y, Zhang S, Chen X, He N (2020b) Biased stochastic first-order methods for conditional stochastic optimization and applications in meta learning. Larochelle H, Ranzato M, Hadsell R, Balcan MF, Lin HT, eds., Adv. Neural Inform. Proc. Systems 33 (Curran Associates, New York), 2759–2770.
Sadana U, Chenreddy A, Delage E, Forel A, Frejinger E, Vidal T (2025) A survey of contextual optimization methods for decision-making under uncertainty. Eur. J. Oper. Res. 320(2):271–289.
Shapiro A, Dentcheva D, Ruszczyński A (2009) Lectures on Stochastic Programming: Modeling and Theory (SIAM, Philadelphia, PA).
Tuo R, Zou L (2026) Asymptotic theory for linear functionals of kernel ridge regression. Statist. Sinica Forthcoming.
van der Vaart AW (1998) Asymptotic Statistics (Cambridge University Press, Cambridge, UK).
Vershynin R (2018) High-Dimensional Probability: An Introduction with Applications in Data Science (Cambridge University Press, Cambridge, UK).