When to Re-run the Design: Drift-Triggered Partial Refitting of Response Surfaces for Variable Agricultural Waste

Labs that turn crop residues, manure or seed oils into fuels, adsorbents and extracts tune their processes with response surface methodology (RSM). In RSM one runs a small, fixed grid of experiments, typically 15 to 30 runs, fits a quadratic polynomial of the outcome against the process settings, and operates at the peak of that fitted surface. The surface is fitted once and then trusted. Agricultural waste does not hold still, though. Ash content, moisture and sugar composition change with farm, region and season, so the optimum found on last season's batch may be wrong for this one. Today practitioners can either ignore this or repeat the whole design for every new batch. That second option is the lab-bench version of the "rebuild the database annually" policy that large knowledge bases use. This note asks the database-maintenance question of a response surface: when a new feedstock batch arrives, how many wet-lab runs are needed to decide whether the old surface is still good, and which parts of it need updating?

The core claim is that drift in feedstock mostly moves the cheap, low-order parts of a process surface: the overall level of the outcome and where its peak sits. The expensive-to-learn curvature and interaction structure usually transfers between batches. If that holds, a three-tier update policy can match a full re-run design at a fraction of the experimental cost. The policy starts with a handful of confirmation runs. A statistical test then decides between keeping the surface, refitting only its low-order terms, and triggering a full new design. The hypothesis is falsifiable: if curvature itself drifts between batches, partial refits will fail, and the experiments are built to show that.

Core Claim

Write the surface for feedstock batch $b$ as

$$Y_b(x) = \beta_{0,b} + x^\top \beta_b + x^\top B_b\, x + \varepsilon,$$

where $x$ is the vector of coded process settings (temperature, time, ratio, catalyst load), $\beta_{0,b}$ is the batch's baseline level, $\beta_b$ are the linear effects, $B_b$ is the symmetric matrix of curvature and pairwise interaction coefficients, and $\varepsilon$ is run-to-run noise. This is the standard second-order RSM model, written per batch. The hypothesis is that $B_b \approx B$ is shared across batches. Meanwhile $(\beta_{0,b}, \beta_b)$ move with measurable feedstock descriptors $z_b$, such as ash fraction or moisture, roughly as $(\beta_{0,b}, \beta_b) = \theta_0 + \Gamma z_b + \delta_b$. Here $\theta_0$ is the reference batch's low-order coefficients, $\Gamma$ maps descriptors to coefficient shifts, and $\delta_b$ is unexplained batch deviation.

Under shared curvature, a new batch has only $1 + k$ unknown low-order coefficients instead of the full quadratic's $(k+1)(k+2)/2$. For $k = 4$ factors that is 5 coefficients instead of 15. A few runs placed near the old optimum and at design-edge midpoints can therefore re-estimate the shift and move the operating point. The trigger compares two fits to the confirmation runs: the shared-curvature model and a model that frees $B_b$. A sequential likelihood-ratio statistic between them escalates to a full redesign only when the shared-curvature model is rejected. It is calibrated so that false escalations stay below a chosen rate.

What is new here is not online RSM in general. It is treating "update frequency" as a decision about which coefficients to re-learn, with an explicit trigger, rather than a calendar schedule.

Relation to Prior Work

The motivating evidence comes from static RSM studies on waste and plant feedstocks. Optimization of biodiesel production from Nahar oil using Box-Behnken design, ANOVA and grey wolf optimizer fits a 29-run Box-Behnken design over four factors, reaching a predicted optimal yield of 91.6484%. Its ANOVA nonetheless flags significant lack of fit. Response Surface Optimized Ultrasonic Assisted Extraction of Total Flavonoids from QingLi Cao and Ultrasonic-Assisted Extraction of Polysaccharides from Brassica rapa L. fit similar four-factor surfaces. The QingLi Cao study reports $R^2 = 0.8658$ and a confirmed yield of 13.80 mg/g against 13.90 predicted. All three fit one surface to one raw-material lot and say nothing about the next lot. This proposal reuses their designs as the reference "batch zero" and adds the question they leave out.

Why drift matters is shown concretely by Removal of methylene blue from aqueous solution by cattle manure-derived low temperature biochar. That study finds adsorption is driven by the roughly 32% mineral ash in manure: dye removal fell from 93.6% to 20.3% after deashing. Ash varies by farm and season, so this system is a natural one where the surface's level should move with a measurable descriptor. The study itself used one-factor-at-a-time sweeps and no surface model.

A constraint, not support, comes from Finding Efficient Trade-offs in Multi-Fidelity Response Surface Modeling. It shows that borrowing cheaper, lower-fidelity information can create "negative benefit" zones where the extra data degrades the model when correlation is low. A previous batch's surface is exactly such borrowed information. The trigger is meant to detect when the borrowed curvature has entered a negative-benefit regime, and the experiments must show it does so before regret accumulates.

The closest machine-learning workflow is From biomass waste to CO2 capture: a multi-fidelity machine learning workflow for high-throughput screening of activated carbons. It pairs a neural surrogate trained on 841 literature samples (MAE 0.484 mmol/g) with multi-fidelity Bayesian optimization, finding a top candidate in 13 high-fidelity acquisitions. Its database is a frozen snapshot, and its inputs are post-synthesis properties rather than feedstock and recipe. This proposal targets the opposite end of the problem: a small, process-level surface that must be kept current as raw material changes.

On the update-frequency side, AgroLD rebuilds its 1.08-billion-triple graph annually and adds datasets several times a year. Graph-based Fingerprint Update Using Unlabelled WiFi Signals updates radio maps in fixed weekly batches. Both conclude that incremental updates eventually hit a freshness limit that forces a full rebuild. Neither derives the update moment from a drift statistic. Their dual cadence of cheap incremental changes plus occasional full rebuilds is the template here, with a statistical test deciding when the full rebuild happens.

Modular design plays a supporting role. Following the abstract fit/predict interface of Universal Causal Evaluation Engine, surrogates, triggers and design generators become interchangeable components. Every competing policy then runs on identical batches, budgets and seeds, with seed and version tracking in the style of DeepDIVA. The point is fair comparison, not a software product.

Research Program

The work has three parts.

The first is a measurement question that can be answered before any new policy is built: across real feedstock batches, which quadratic coefficients are stable? We fit per-batch surfaces and test the equality of $B_b$ across batches against the equality of the low-order terms. If curvature is no more stable than level, the central hypothesis fails and the note's claim is wrong.

The second is the policy itself. On each new batch it runs a fixed small set of confirmation runs, 5 to 8 for four factors, placed by D-optimality for the low-order coefficients given the shared $B$. It computes the trigger statistic and then does one of three things. It keeps the old optimum, or it refits $\theta$ (with a hierarchical prior centered on $\theta_0 + \Gamma z_b$) and moves to the new stationary point, or it schedules a full Box-Behnken redesign. The descriptor map $\Gamma$ is updated with each batch, which is the incremental, delta-style update. Full redesigns reset the shared curvature, which is the periodic rebuild.

The third is a common evaluation harness in which all policies plug into the same batch stream and run budget.

Baselines

The naive reference point is never updating: fit the surface on batch zero and run every later batch at that optimum. This measures how much drift costs at all. If its regret is small, the whole problem is moot for that feedstock and we will report that.

The conventional practice baseline is a full re-run of the original design on every batch: 29 Box-Behnken runs for four factors, as in the Nahar study. It should achieve near-best per-batch optima at the highest cost. The proposal beats it if it reaches statistically indistinguishable per-batch yield shortfall with at least 60% fewer cumulative runs.

A scheduled-rebuild baseline mirrors AgroLD's cadence: full redesign every $m$ batches with no updates in between, with $m$ tuned on the simulation suite under the same budget. It isolates whether the trigger beats a well-chosen calendar.

The strongest competitor is contextual Gaussian-process Bayesian optimization. This is a sequential optimizer whose surrogate takes both process settings and feedstock descriptors as inputs, warm-started on all previous batches and spending runs one at a time. It is the natural streaming analogue of the multi-fidelity loop in From biomass waste to CO2 capture, which reports finding its top candidate in 13 high-fidelity acquisitions and a greater than 75% reduction in high-fidelity evaluations over single-fidelity Bayesian optimization. That figure is for a static screening task. For re-optimization under feedstock drift, no reported result was found on Lacuna. The competitor will receive the same per-batch run budget, the same descriptors, and kernel hyperparameters tuned by marginal likelihood on the same reference data. The proposal beats it if it achieves lower cumulative regret at budgets of 8 runs or fewer per batch. We expect contextual Bayesian optimization to win at larger budgets, and we will report the crossover point.

Two ablations isolate the key ingredient. The first, a free-curvature partial refit, re-estimates all coefficients from the confirmation runs with a weak prior; this tests whether sharing $B$ is what helps. The second, a trigger-less tiered policy, always does the partial refit and never escalates; this tests whether the trigger prevents the negative-benefit failures predicted by Finding Efficient Trade-offs in Multi-Fidelity Response Surface Modeling.

Why not just…?

Why not just re-run the full design on every batch? It is safe, and when drift is large it is the right answer, which is why it is the escalation tier. Its cost scales with the number of batches. For a four-factor process it means 29 runs per lot, often more than the value of the lot's optimization. The comparison against full re-runs measures how much of that cost is redundant. If curvature turns out not to transfer, full re-runs win and we will say so.

Why not just treat feedstock as a blocking factor or extra covariate in one larger up-front design? Blocking handles batches that are known at design time. Waste batches arrive later, with descriptor values outside the original range. A larger up-front design also cannot anticipate new farms or seasons. Our hierarchical model is in effect a blocked design that grows one batch at a time. The experiments compare it against a pooled covariate model fitted on all past data, which is this alternative made sequential.

Why not just run contextual Bayesian optimization continuously? This is the real threat. A Gaussian process with feedstock inputs could in principle learn that curvature is shared. Our bet is that with only a few runs per batch and a handful of batches, a quadratic prior with explicitly shared curvature is more sample-efficient than a flexible kernel. Bayesian optimization also offers no explicit signal for when the old model has become untrustworthy. The matched-budget comparison settles this. If contextual Bayesian optimization matches our regret at 8 or fewer runs per batch, the contribution reduces to the stability measurement and the trigger as a diagnostic layered on top of Bayesian optimization.

Why not just use control charts on the confirmation runs? Statistical process control detects that output shifted but not what shifted. It cannot tell a level change, which a 5-run refit can fix, from a curvature change, which needs a full redesign. We include a Shewhart-style chart on confirmation residuals as the trigger in one ablation arm to measure the value of the model-comparison test.

Proposed Experiments

Simulation comes first because no multi-batch feedstock dataset exists in the material reviewed. We take the analytic multi-fidelity test surfaces from the mf2 package used in Finding Efficient Trade-offs in Multi-Fidelity Response Surface Modeling, together with quadratic surfaces refitted from the published Nahar, QingLi Cao and Brassica rapa design matrices. We generate batch streams of 10 to 20 lots in which drift is injected separately into level, linear terms and curvature, at controlled magnitudes. The decisive check is a curve of regret versus runs per batch, for each drift type. The policy should dominate when drift is low-order, and its trigger should escalate within one or two batches when curvature drifts. A trigger that fails to escalate under curvature drift falsifies the design.

Second, as a semi-real stream, the 841-sample biomass carbon dataset from From biomass waste to CO2 capture is ordered by publication date and grouped by biomass source to form "batches." We test whether the trigger fires on source changes that measurably raise surrogate error against that paper's 0.484 mmol/g MAE reference. The caveat is that its inputs are material properties rather than recipes.

Third, a wet-lab study on cattle-manure biochar for methylene blue adsorption. Starting from the cattle manure biochar study, we run a four-factor Box-Behnken design (pyrolysis temperature 200 to 400 °C, dose, pH, contact time) on a reference lot. We then process six further lots from different farms and seasons, recording ash and moisture as descriptors. On each lot we run both the full design and the proposed policy. The full design provides ground truth for the stability test and lets every policy be scored offline on the same measured surfaces. Success means three things. Curvature coefficients are statistically stable across lots while level tracks ash. The policy's chosen operating point is within measurement noise of the full-design optimum on at least five of six lots. It uses under 40% of the runs.