A fresh food production scheduling method and system based on flow response quantification and batch shelf life hard constraint
By quantifying online delivery budgets to determine the incremental demand in different time periods and using hard constraints on the remaining shelf life of products to consumers to determine batch output, the problems of product destruction due to expiration and inconsistent freshness in fresh food production have been solved, and effective production scheduling optimization has been achieved.
Patent Information
- Application Number
- CN202611217140.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-12
- Publication Date
- 2026-11-03
AI Technical Summary
In fresh food production, existing technologies have failed to effectively differentiate production batches, resulting in inconsistent remaining shelf life of products when they reach consumers. Furthermore, the lack of online distribution budgets as input variables for production decisions has led to problems such as products being destroyed due to exceeding their shelf life or lacking freshness.
By quantifying the delivery response and using hard constraints on batch shelf life, the online delivery budget is quantified as the incremental demand in different time periods. With the remaining shelf life to consumers as a hard constraint, the output of each production batch is determined, a set of feasible delivery waves is constructed, and production scheduling is optimized.
Ensure that every product is delivered within its shelf life, reduce the number of products destroyed due to exceeding their shelf life, eliminate inconsistencies in product freshness within the same day, and achieve effective utilization of pre-production flow budget.
Smart Images

Figure CN123032073A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of intelligent food manufacturing and production process control technology, and in particular to a method and system for scheduling fresh food production by using the nonlinear response quantification results of online flow budget as demand input and the remaining shelf life to consumers at the production batch level as a hard constraint. Background Technology
[0002] The production scheduling of fresh and cooked food products is governed by two physical characteristics that distinguish it from the production scheduling of general industrial products.
[0003] The first physical characteristic is a short total shelf life and irreversible degradation. The total shelf life of such products typically does not exceed 72 hours. From the moment of production, the remaining shelf life of the product monotonically decreases over time, and this degradation is irreparable and irreversible. Products that have exceeded their shelf life can only be physically destroyed and cannot be recovered through price reductions, allocation, or delayed delivery.
[0004] The second physical characteristic is the existence of multiple production batches within a single day. The production cycle of a single batch is typically significantly shorter than the daily production window. For example, the braising cycle for a single batch is approximately 3 hours, while the daily production window is over 10 hours. Therefore, objectively, multiple production batches exist within a single calendar day. Since different batches are completed at different times, the remaining shelf life of the products when they reach the consumer can differ by several hours when shipped in the same wave.
[0005] Current production scheduling methods typically rely on management experience to determine the total daily output, without differentiating between production batches or considering the remaining shelf life upon consumer receipt. This results in two physical consequences: when daily output exceeds actual demand, the excess is physically destroyed due to exceeding its shelf life, with the applicant's current scrap rate being approximately 5%; when production batches and shipping waves are mismatched, some products arrive at consumers with insufficient remaining shelf life, leading to returns due to insufficient freshness.
[0006] The following prior technologies already exist in the direction of demand forecasting-driven production scheduling.
[0007] Prior art discloses a production control method based on food demand forecasting. It utilizes historical order quantities to construct a grey system theory forecasting model to generate predicted food order quantities, uses historical order average production quantities to construct an improved grey neural network model to generate average predicted production quantities, and uses an improved fuzzy comprehensive evaluation model constructed from planned order delivery quantities, raw material reserves, inventory costs, and the importance of food demand to generate a predicted quantity correction value. Based on this, it generates a food production line scheduling plan and adjusts production scheduling. This prior art has disclosed a technical path of driving food production line scheduling and dynamically adjusting based on demand forecast quantities. The difference between this prior art and the present invention is that: the correction factors of the prior art are inventory costs and demand importance, which is a weighted evaluation of cost and priority; its scheduling results are not constrained by the physical shelf life of the product; the prior art does not distinguish between production batches, and its scheduling plan quantity is a time-level total quantity rather than a batch-level allocation quantity; the prediction input of the prior art does not include the online flow budget, an intervention variable that can be actively set by the producer.
[0008] Prior art 2 discloses an intelligent inventory allocation method based on multi-platform sales forecasting. It acquires historical business data and external influencing factors of goods across multiple sales platforms, preprocesses and performs feature engineering, then inputs the data into a deep learning prediction model. The model outputs sales forecasts for each platform over future periods, generating an inventory allocation scheme based on these forecasts. Dynamic adjustments are triggered when the deviation between actual sales and forecasts meets preset conditions. This prior art has already disclosed the technique of multi-platform data fusion prediction and deviation-triggered dynamic adjustment. The difference between this prior art and the present invention is that the output of the prior art is an inventory allocation scheme across platforms, i.e., a spatial reallocation of existing stock without generating new materials, thus not changing the product's production time and being unrelated to the shelf-life decay start point; the output of the present invention is the output quantity of each production batch, directly determining the start time of the shelf-life for each product.
[0009] Prior art 3 discloses a method for joint budget allocation and ROI optimization of cross-platform advertising expenditure. It assesses the contribution of each channel through an attribution model, constructs a joint prediction model using a nonlinear saturated response function and cross-influence coefficients to quantify the synergy and crowding-out effects between channels, and performs global optimization using a nonlinear programming algorithm to output the budget allocation scheme for each channel. This prior art has disclosed a technique of using a nonlinear saturated response function to characterize the diminishing marginal relationship between advertising input and output and setting parameters separately for each channel. The difference between this prior art and the present invention is that the output of the prior art is the budget allocation amount for each channel, and its decision chain terminates at the placement stage; this type of solution only needs the total response of each channel over the entire placement period, without needing to know how this response is distributed over time within the period. Therefore, the prior art does not provide, nor does it need to provide, the time distribution of sales increments; while the present invention must obtain the time distribution of increments because the shelf life of a product is calculated from the moment of production, and there are multiple production moments within a single day.
[0010] Prior technology four is an academic paper that addresses the aggregation layer planning problem in the bottleneck packaging process of a perishable goods packaging production system. It introduces the target minimum remaining shelf life that the marketer expects to provide to consumers, with product demand decreasing from its maximum remaining shelf life to this target minimum remaining shelf life. The problem is solved using a two-stage stochastic integer nonlinear programming model. This paper has already disclosed the concept of using the minimum remaining shelf life received by consumers as a parameter for perishable goods production planning. The difference between this and the present invention is that the target minimum remaining shelf life in the prior technology is a target value set by the marketing side and participates in optimization as an independent variable of the demand function; that is, demand decreases with this value, making it a trade-off and optimizable decision variable. In contrast, the lower limit of the remaining shelf life received in the present invention is a hard constraint for production scheduling, not included in the objective function, and cannot be violated at any cost. Its function is to directly eliminate infeasible production plans before solving the problem. Furthermore, the time granularity of the prior technology is the planning cycle, and its decision object is the sequence of packaging processes, which cannot express the physical fact that two batches of products produced on the same day may have a difference of several hours in their remaining shelf life.
[0011] The prior art, technically termed "Technology 5," is an academic paper that studies the capacity-constrained production and delivery path problem in a multi-factory environment, involving batch scheduling and product shelf-life constraints. The model includes variables such as batch production time, batch departure time, and arrival time. When the planned delivery time exceeds the shelf-life threshold, the production time of that batch is rescheduled, with the goal of ensuring all products are delivered within their shelf life. This paper has disclosed a method combining batch scheduling with shelf-life constraints. The difference between this paper and the present invention is that the criterion in the prior art is that the delivery time does not exceed the shelf-life, meaning the product is considered feasible if it is not expired upon delivery. The criterion in the present invention is that the remaining shelf life upon consumer receipt must not be less than a set lower limit, meaning the product must have an edible period of at least that lower limit upon delivery. The latter's allowed feasible domain is strictly smaller than the former. Furthermore, the prior art checks for expiration after calculating the delivery time, which is a post-hoc feasibility check; while the present invention uses the inequality to solve for the feasible matching set from production batch to delivery wave, limiting the range of options before solving, thus constructing the solution space.
[0012] Furthermore, the following prior art is partially related to this invention. First, prior art discloses a method for storing hot data in a key-value model in-memory database and aggregating and retrieving data by dimension and time interval; this is a server-side caching solution and does not involve production scheduling. Second, prior art discloses a method for predicting sales of new products using sales data of similar products and determining production plans accordingly; this addresses the cold start problem when new products lack their own historical data, unlike this invention which processes the real-time data of mature products. Third, prior art discloses a method for obtaining combined prediction results by superimposing the prediction baseline output by a Long Short-Term Memory network and fitting its residuals with a gradient boosting decision tree; this model combination method has prior patents in multiple fields such as power and fault classification, and is a known model combination method in the art; this invention does not consider this combination itself as a distinguishing technical feature. Fourth, prior art discloses a product scheduling method based on locking events, which triggers a locking event and locks the machine or work-in-process when the work-in-process violates the restriction judgment rule. The object locked by the prior art is the physical resource entity of the machine or work-in-process, and the triggering condition is the violation of the restriction judgment rule, which is a punitive treatment of conflict. Moreover, the remaining dwell time limit is the upper limit of the time that the work-in-process can stay between processes, which is a process constraint. In contrast, the object locked by this invention is the value of the decision variable of the output of the batch that has started production. The triggering condition is that the batch has started production and its output is physically unchangeable, which is a true reflection of the established physical facts. Fifth, prior art discloses a profit forecasting and evaluation method for traffic generation business, which performs dynamic decay value assessment on advertising effectiveness. Brand advertising uses linear decay and performance advertising uses exponential decay to calculate the full life cycle revenue index. The decay of this prior art applies to the revenue that has already been generated, and evaluates the current value by weighting it according to its occurrence time. It belongs to the post-processing of existing results, and its output is revenue index and trend chart. In contrast, the decay of this invention applies to the future sales increment that has not yet occurred, predicts its distribution in subsequent periods, and belongs to forward forecasting. Its output is directly used as the demand-side input for production scheduling. The two are opposite in direction on the time axis.
[0013] In summary, existing technologies have the following two gaps. First, none of them use online advertising budgets as input variables for production scheduling. The predictive inputs of the aforementioned prior technologies are all passive observations such as historical sales, external influencing factors, costs, and priorities. In contrast, advertising budgets are intervention variables that can be actively set by the producer and are determined before production decisions are made. The output of prior advertising technologies ends at the advertising decision itself, and its decision chain does not extend to the production stage. Second, none of them construct a feasible matching relationship between production and delivery based on the remaining shelf life to consumers at the production batch time granularity. Existing solutions either include shelf life in the objective function as inventory holding costs or scrap costs, allowing for violations at cost, or treat it as a decision variable that can be optimized on the marketing side. Neither solution treats it as an inviolable hard constraint to directly eliminate infeasible solutions before solving the problem. Furthermore, the smallest time granularity of existing solutions is the planning cycle, and their models do not include a time index for production batches.
[0014] Therefore, a production scheduling scheme is needed that can quantify the pre-determined input budget into time-segmented demand increments and determine the output of each batch at the production batch level with the remaining shelf life to consumers as a hard constraint. Summary of the Invention
[0015] I. Technical problems to be solved The technical problem to be solved by this invention is: in the production of fresh food with a total shelf life of no more than 72 hours and multiple production batches per day, how to determine the output of each production batch so that each produced product has a physical delivery route that can be delivered within its shelf life and with the remaining shelf life at delivery not less than a set lower limit, thereby reducing the number of products physically destroyed due to exceeding the shelf life; and how to quantify the online delivery budget determined before production into time-segmented demand increments that can be used for the above batch output decision, through its nonlinear, platform heterogeneous and time-decreasing response characteristics. Technical solution
[0016] To address the aforementioned technical problems, this invention provides a fresh food production scheduling method based on flow response quantification and batch shelf life hard constraints, comprising the following steps.
[0017] Step S1: Obtain the traffic budget, time period, and platform identifier of each sales platform as determined for the day, as well as the historical and real-time sales data of each platform.
[0018] Step S2 involves cleaning, standardizing, and aligning the heterogeneous data from multiple platforms to obtain unified sales characteristics. This step employs methods known in the art.
[0019] Step S3 involves converting the traffic allocation budget into sales increment using the traffic allocation response quantification sub-model. This conversion includes two parts: first, applying a response function to each platform that causes the sales increment to decrease as the traffic allocation budget increases; second, for each time period after the campaign ends, applying the platform's decay coefficient to cause the sales increment for that period to decrease with the time remaining after the campaign ends. Therefore, the output of this conversion is a time-segmented sales increment curve, rather than a single daily total increment.
[0020] Step S4: Obtain the baseline demand by using the historical sales sequence and the prediction baseline model, and then superimpose the sales increment curves of the time periods onto it to obtain the total demand for the time periods.
[0021] Step S5: Using the completion time of each production batch as a time index, determine the feasible shipment wave set for each production batch. The feasible shipment wave set consists of all shipment waves that satisfy the following formula: the sum of the dispatch time of the shipment wave and the cold chain delivery time of the shipment wave, minus the completion time of the production batch, is not greater than the difference between the total shelf life and the lower limit of the remaining shelf life at hand.
[0022] Step S6: Using the output of each production batch as the decision variable, the total demand of the time period as the demand input, and the constraint that the output of each production batch does not exceed the sum of the demand of the time periods corresponding to each shipping wave in its feasible shipping wave set, solve for the batch output that minimizes the number of products that will be physically destroyed due to exceeding the shelf life.
[0023] Step S7: Organize production according to the solution results, record the actual output completion time of each production batch, and bind the products of each production batch to the shipping wave in its feasible shipping wave set.
[0024] Step S8: Compare actual sales with predicted values in real time. If the deviation exceeds a preset threshold, trigger production rescheduling and write the deviation sample back to the flow response quantification sub-model and the prediction baseline model.
[0025] III. Definitions of Terms and Parameters Total shelf life: refers to the time from the moment a product is produced until it is no longer available for consumption, denoted as L. In this invention, the typical value is 72 hours.
[0026] Remaining shelf life upon delivery: refers to the portion of a product's total shelf life that has not yet been consumed when it is delivered to the consumer.
[0027] Minimum remaining shelf life upon receipt: This refers to the minimum remaining shelf life that a consumer must reach when receiving the product, as set by this invention. It is denoted as R_min, and a typical value in this invention is 10 hours.
[0028] Production batch: refers to a production unit that is completed continuously in one day within a production window. The completion time of its output is denoted as T_b. The difference between the completion times of two adjacent batches is not less than the production cycle of a single batch.
[0029] Shipment wave: refers to a batch of orders that are shipped at a fixed time within a single day. The time of shipment is denoted as D_w, and the cold chain delivery time is denoted as τ_w.
[0030] Feasible shipment set: refers to the set of all shipments that can meet the lower limit of the remaining shelf life for a certain production batch, denoted as W(b).
[0031] Traffic budget: refers to the expenses that a manufacturer invests in promoting its products on a sales platform, the amount of which is determined before production decisions are made.
[0032] Physical destruction quantity: refers to the quantity of products that can no longer be consumed due to exceeding the total shelf life and can only be destroyed.
[0033] IV. Specific Implementation of the Quantization Sub-model for Flow Response The techniques used in this section are to convert the traffic budget into a sales increment curve for different time periods.
[0034] 4.1 Saturation Response The potential customer base that a single platform can reach within a single time period is limited. Once the advertising budget increases to a certain level, a large portion of new exposure falls on already reached customers, and the growth rate of sales increases slows down and tends towards a ceiling. Therefore, using a response function with a saturation ceiling for each platform, the sales increment for platform p is calculated using the following formula: ΔS_p = S_p_max × [1 − exp(−B_p / (k_p × S_p_max))] Where B_p is the traffic acquisition budget of platform p during this period; S_p_max is the upper limit of the saturation increment of platform p during this period, which physically means the maximum number of new orders that the platform can reach during this period; k_p is the response coefficient of platform p, with the dimension of yuan per order. The derivative of this function when B_p approaches zero is the reciprocal of k_p, that is, in the low budget range, it degenerates into the reciprocal of the unit customer acquisition cost.
[0035] In one implementation, the initial value of k_p is 10 yuan per order, and the initial value of S_p_max is 1.2 times the highest historical order volume of the platform during that period. The two are updated by rolling nonlinear fitting using the least squares method based on sample pairs of traffic investment budget and actual sales increment over the most recent 30 days, with the fitting window sliding once a day.
[0036] The purpose of this response function is to prevent the incremental output of the model from growing linearly with the budget when the budget has entered the saturation zone, thereby avoiding overproduction due to overestimating demand and thus preventing products from being physically destroyed due to exceeding their shelf life.
[0037] It should be noted that using a nonlinear saturated response function to characterize the diminishing marginal return relationship between advertising input and output is a known technique in the field, and this invention does not use the form of the function itself as a distinguishing technical feature. Alternative function forms include: the Hill function form, where the sales increment equals the saturation limit multiplied by the nth power of the advertising budget, then divided by the sum of the nth power of the half-saturation budget and the nth power of the advertising budget; the logarithmic form, where the sales increment equals the coefficient multiplied by the natural logarithm of the ratio of the advertising budget to the scaling parameter; and the piecewise linear form, where the budget interval is divided into several segments with monotonically decreasing slopes. All of these forms satisfy the common characteristic that the increment monotonically increases with the budget and the rate of increase decreases.
[0038] 4.2 Platform Heterogeneity Different sales platforms have different traffic structures. For example, conversions on live streaming platforms are concentrated during the live streaming period, while conversions on search platforms are more dispersed. Therefore, each platform maintains its own set of parameters, namely the response coefficient and the upper limit of saturation increment, and organizes them into a parameter matrix according to two dimensions: platform and time period, rather than sharing a single unit customer acquisition cost across platforms.
[0039] 4.3. Temporal decay of the streaming effect After the traffic boosting stops, the resulting sales increase will not immediately drop to zero, but will decay exponentially in subsequent periods, calculated using the following formula: ΔS_p(t + τ) = ΔS_p(t) × exp(−λ_p × τ) Where λ_p is the decay coefficient of platform p, and τ is the time remaining until the end of the campaign. λ_p is obtained by fitting the proportion of the increment in each hour after the end of the campaign to the increment during the campaign period in historical data.
[0040] This attenuation term makes the output of the flow response not a single daily total, but a time-segmented incremental curve, which constitutes the demand-side input for batch-level production scheduling, as described later.
[0041] It is important to explain why existing technologies do not have, and do not require, this attenuation term. Prior art aimed at optimizing advertising budget allocation focuses on distributing the total budget across channels. This solution only requires the total response from each channel over the entire campaign period, without needing to know how the increment is distributed over time. Therefore, there is no need to introduce a time-series attenuation term, and even if introduced, it would not change the budget allocation result. This invention, however, requires knowledge of the temporal distribution of the increment. This is due to physical reasons: a product's shelf life is calculated from its production time, and there are multiple production batches within a day. If only the total daily demand is known without knowing its distribution across different time periods, it is impossible to determine how much should be produced in the first batch and how much in subsequent batches, thus failing to guarantee that each batch of products will be delivered within its shelf life. Therefore, it is this physical constraint of shelf life being calculated from the production time that, in turn, requires the demand side to provide a time-segmented distribution. This reverse transmission from physical constraints to demand-side modeling requirements does not exist in solutions that end with campaign decisions.
[0042] 4.4 Coupling method with the prediction baseline model The results of the flow response quantification are used in forecasting in two ways. First, they are directly superimposed on the forecast baseline as an additive bias term, meaning that the demand for a given period equals the baseline demand for that period plus the sum of the sales increments of each platform during that period. Second, this sales increment and its first-order difference are input as components of the feature vector into the residual correction model, which then learns the systematic bias of the quantification model. The reason for using additive bias instead of just feature input is that the flow budget is a known and definite quantity at the point of production decision-making, and its contribution mechanism to demand is clear; direct superposition avoids its dilution by the data-driven model.
[0043] V. Predictive Baseline Model The prediction baseline can be implemented using any of the following methods, and this invention does not limit its implementation. One implementation uses a Long Short-Term Memory (LSTM) network with the daily sales sequence of each product category over the past N days as input, where N is 14, the hidden layer dimension is 128, and two layers are stacked. The output is the baseline prediction value, which is then fitted with a gradient boosting decision tree and the residuals are summed. Another implementation uses a seasonal difference autoregressive moving average model or an exponential smoothing model. A third implementation uses a gradient boosting decision tree direct regression.
[0044] It should be noted that the combination of using a long short-term memory network to output a baseline and then fitting its residuals with a gradient boosting decision tree and then superimposing them has been disclosed in prior patents in the fields of power and fault classification. It is a known model combination method in the field, and this invention does not regard this combination itself as a distinguishing technical feature.
[0045] VI. Production Scheduling Model with Batch-Level Shelf Life Hard Constraints 6.1. The decision variable is refined from daily output to batch output. Let b be the number of production batches within a single day, and T_b be the completion time of batch b. The difference in completion times between adjacent batches is no less than the production cycle of a single batch. The decision variable is q_i_b, representing the output quantity of product category i in batch b. Compared to a single decision variable with daily granularity, this refinement allows the model to express the physical fact that products produced sequentially within the same day have different shelf-life starting points.
[0046] 6.2. Hard constraints on the remaining shelf life upon receipt. Let L be the total shelf life, T_b be the production completion time of batch b, D_w be the dispatch time of shipment wave w, τ_w be the cold chain delivery time of that wave, and R_min be the lower limit of the remaining shelf life upon arrival. Then, for any batch b of products allocated to wave w, the following formula must be satisfied: (D_w + τ_w) − T_b ≤ L − R_min That is, the total time from the production of a product to its delivery to the consumer must not exceed the total shelf life minus the lower limit of the remaining shelf life upon receipt.
[0047] This equation is a hard constraint, not included in the objective function, and cannot be violated at any cost. It should be noted that the concept of using the minimum remaining shelf life to consumers as a parameter for perishable goods production planning has been disclosed in prior literature, and this invention does not use this concept itself as a distinguishing technical feature. The difference in this invention lies in three points: First, the way this quantity is used—as an inviolable hard constraint to directly eliminate infeasible output schemes before solving—rather than as a weighable and optimizable decision variable; second, the time index to which this constraint is attached is the completion time of the production batch within the day, not the planning cycle; only at the batch granularity can this inequality distinguish between two batches of products produced sequentially within the same day; third, the set of feasible delivery waves obtained by inversely solving this inequality.
[0048] 6.3 Construction of Feasible Shipment Wave Sets The feasible matching set of batches and waves can be directly solved from the above inequality, that is, W(b) consists of all shipping waves w that satisfy the following formula: D_w + τ_w ≤ T_b + L − R_min Accordingly, the output of batch b must not exceed the sum of the demand for the time period corresponding to its feasible waves.
[0049] The purpose of this structure is to limit the range of options before solving the problem, ensuring that each produced product has a physical delivery path that allows it to be delivered within its shelf life, with the remaining shelf life upon delivery not falling below the lower limit. Production that does not meet this condition is excluded during the scheduling phase. This differs from the post-production verification method that checks for overdue products one by one after calculating the delivery time.
[0050] 6.4 Handling the uncertainty of cold chain delivery time Cold chain delivery times fluctuate due to weather, traffic, and delivery location. If the average delivery time is taken, approximately half of the orders will have an actual delivery time exceeding this value, resulting in a remaining shelf life below the lower limit, rendering the hard constraint ineffective. This invention provides three solutions.
[0051] One method is the quantile method. Grouping by shipping wave and delivery region, the q-th quantile of the historical delivery time for that group is taken as the cold chain delivery time for that wave, with q set to 90. This means that, under historical distribution, approximately 90% of orders will not exceed this value in actual delivery time. The value of q represents an adjustable trade-off between the stringency of the constraint and the available output; a higher q results in a smaller set of feasible shipping waves and a lower allowable output, but a higher proportion of orders meeting shelf-life standards. For groups with fewer than 30 orders, the quantile is taken after merging with adjacent region groups.
[0052] The second method is the scenario method. For the same wave, take several sets of cold chain delivery time scenarios and their occurrence probabilities, solve for each scenario separately, and take the intersection of the feasible delivery wave sets obtained from each scenario to obtain a robust solution that is feasible under all scenarios.
[0053] The third method is the rolling correction method. After a shipment is actually dispatched, the estimated cold chain delivery time is updated based on the real-time delivery progress of that shipment, and then incorporated into the next production rescheduling.
[0054] 6.5 Objective Function and Other Constraints The objective function is to minimize the weighted sum of the physical destruction quantity and the stockout quantity for each batch and product category. Because the product shelf life is extremely short and physical destruction is the primary source of loss, the weight of the physical destruction quantity is greater than the weight of the stockout quantity. The initial values for both are 1.5 and 1.0 respectively, and are continuously adjusted based on actual destruction and stockout data.
[0055] Other constraints include: batch capacity constraints, which stipulate that the sum of the output of each product category in a batch shall not exceed the capacity of that batch; raw material constraints, which stipulate that the sum of the consumption of a certain raw material by the output of each product category shall not exceed the available amount for the day; no overnight inventory is allowed, which means that the output of the day must be shipped out within the same day's shipping wave; and non-negative and integer constraints.
[0056] The model is a mixed integer linear programming problem with tens of categories and single-digit batches. It can be solved in seconds using an open-source solver.
[0057] VII. Dynamic Rescheduling of Production and Synchronization of Status If the actual sales volume deviates from the forecast by more than a preset threshold, production will be rescheduled. The threshold is 30%.
[0058] To avoid conflicts between real-time adjustments and existing production scheduling results, this invention stipulates that production rescheduling can only adjust output on batches that have not yet started. The output of batches that have already started is locked as the executed value and used as a fixed parameter for the next solution. The trigger condition for this locking is that the batch has already started and its output is physically unchangeable. This is a true reflection of the established physical facts, which is different from the punitive locking imposed on physical resources due to rule violations.
[0059] During production rescheduling, the set of feasible shipping waves for each batch is recalculated based on the current time. As time progresses, the number of remaining available shipping waves decreases, and this set shrinks, thereby automatically suppressing over-scheduling near the end of the day. Beneficial effects
[0060] Compared with the prior art, the present invention has at least the following beneficial effects.
[0061] First, ensure that every product produced has a physical shipping route that meets the minimum remaining shelf life requirement. Production that does not meet this condition is hard-constrained and excluded during the production scheduling stage, thus preventing the production of products that have already been manufactured but cannot be delivered in compliance with regulations within their shelf life.
[0062] Second, it reduces the number of products physically destroyed due to exceeding their shelf life. The objective function primarily aims to minimize the number of products physically destroyed, and the saturation characteristics of the delivery response prevent overestimation of demand and subsequent overproduction in high-budget periods.
[0063] Third, the time granularity of production scheduling is refined from daily to production batch, thereby eliminating the inconsistency in freshness caused by the difference in the remaining shelf life of different batches of products arriving on the same day.
[0064] Fourth, it makes the pre-determined input budget a calculable demand input, and its quantification result is an incremental curve in time periods, which can be directly mapped to specific production batches, rather than just obtaining a daily total.
[0065] Fifth, it ensures that adjustments to meet sudden changes in intraday demand do not create conflicting plans. Batches already in operation are locked, while those not yet in operation are adjustable, and the set of feasible delivery waves shrinks with the current time, automatically suppressing excessive production near the end of the day.
[0066] Sixth, the present invention addresses the problem of arranging the production time and quantity under the physical constraint that the shelf life of a product decreases monotonically and irreversibly from the moment of production. Its technical means are applied to the physical production process, and its output directly determines the start-up batches and output of the production line. The resulting effect is that the product has a compliant delivery path in physical terms and the number of products physically destroyed decreases, both of which are physical effects. Attached Figure Description
[0067] Figure 1The flowchart illustrates a fresh food production scheduling method based on flow response quantization and batch shelf life hard constraints, as provided in an embodiment of the present invention.
[0068] Figure 2 This is a schematic diagram of the saturation response and time-series decay of the current-response quantization sub-model provided in an embodiment of the present invention.
[0069] Figure 3 This is a schematic diagram illustrating the construction of a feasible matching set of production batches and shipping waves provided in an embodiment of the present invention. Detailed Implementation
[0070] The embodiments of the present invention will now be described with reference to the accompanying drawings. These embodiments are for illustrative purposes only and are not intended to limit the scope of the invention. Example
[0071] A manufacturer of fresh braised food products sells its products simultaneously on five sales platforms: Douyin Live, Douyin Mall, Tmall, JD.com, and Pinduoduo, using a cold chain delivery method with ice packs. The total shelf life L of the product is taken as 72 hours, the minimum remaining shelf life upon arrival R_min is taken as 10 hours, the production cycle for a single batch is approximately 3 hours, and three production batches are scheduled within the daily production window, with completion times of 9:00, 12:00, and 15:00 respectively; two shipping waves are scheduled for the same day, with departure times of 13:00 and 16:00 respectively. The cold chain delivery time is taken as 20 hours for both waves, using the aforementioned quantile method.
[0072] See Figure 1 The production schedule for that day is as follows.
[0073] The system first obtains the confirmed traffic budget and ad placement time for each platform for the day. In this embodiment, the live streaming platform will ad placement from 7 PM to 9 PM, with a budget of 3,000 yuan; the other platforms will not ad placement for the day.
[0074] See Figure 2 The system calculates the sales increase brought about by this traffic delivery using the traffic delivery response quantification sub-model. Taking the response coefficient k of the live streaming platform as 10 yuan per order and the saturation increment limit S_max as 400 orders, the increment during the delivery period, calculated according to the aforementioned saturation response function, is 400 multiplied by 1 minus the exponent of -3000 divided by 10 multiplied by 400, approximately 220 orders. If calculated using a simple linear relationship, 3000 yuan divided by 10 yuan per order yields 300 orders, a difference of 80 orders. This difference represents the overestimation of demand avoided by the saturation effect.
[0075] Subsequently, the system calculates the increment for each time period after the campaign ends, based on the attenuation coefficient. Taking the attenuation coefficient of the live streaming platform as 0.35 per hour, the increment in the first hour after the campaign ends is approximately 0.70 times the increment during the campaign period, the second hour is approximately 0.50 times, and the third hour is approximately 0.35 times. Therefore, the output of this campaign is not a single number of 220 orders, but rather a time-segmented increment curve that decreases sequentially in each hour starting from 7 PM.
[0076] The system overlays the time-segmented incremental curve onto the baseline demand obtained from the historical sales sequence to obtain the total demand for each time period of the day.
[0077] See Figure 3 The system then determines the set of feasible shipping waves for each production batch. For batch one, its production completion time is 9:00 AM, the first shipping wave is dispatched at 1:00 PM, and the delivery time is 20 hours. Therefore, 1:00 PM + 20 hours - 9:00 AM equals 24 hours, which is less than L - R_min, or 62 hours. Thus, the first wave is feasible. Similarly, the second wave is also feasible. Therefore, the set of feasible shipping waves for batch one includes two waves. For batch three, its production completion time is 3:00 PM, and the first shipping wave was dispatched at 1:00 PM, so it is unusable. The second wave is dispatched at 4:00 PM. 16:00 PM + 20 hours - 3:00 PM equals 21 hours, which is less than 62 hours. Therefore, it is feasible. Thus, the set of feasible shipping waves for batch three only includes the second wave. It is evident that the later the batch is produced, the smaller its set of feasible shipping waves.
[0078] The system uses the output of each batch as the decision variable, the sum of the demand for the time period corresponding to the above set of feasible delivery waves as the upper limit of the output of each batch, and the goal is to minimize the weighted sum of the physical destruction quantity and the out-of-stock quantity to obtain the output allocation of the three batches.
[0079] Production is organized according to this result, the actual output completion time of each batch is recorded, and each batch of products is bound to the corresponding wave for shipment according to its feasible shipment wave set. Example
[0080] This example illustrates the production rescheduling process in the event of a sudden change in intraday demand. Continuing from Example 1, at 13:00 on the same day, the system detects that actual sales are 35% higher than the predicted value, exceeding the preset threshold of 30%, triggering production rescheduling. At this time, batches one and two have already started production, and their output is locked as executed values and used as fixed parameters; only the output of batch three participates in this calculation. Simultaneously, the system recalculates the feasible delivery wave set for each batch based on the current time of 13:00: Since the first delivery wave has already been dispatched, the only remaining available wave is the second wave at 16:00. Therefore, the feasible delivery wave set for batch three is further reduced compared to the morning calculation, and its upper limit for output decreases accordingly. Thus, even if actual demand is higher than the forecast, the system will not arrange production exceeding the remaining delivery capacity, thereby avoiding products that cannot be delivered within their shelf life after production. Example
[0081] This example illustrates the handling of uncertainties in cold chain delivery time. A certain shipment wave is destined for two delivery regions, A and B, whose historical delivery time 90th percentiles are 18 hours and 24 hours, respectively. The system groups the delivery regions and takes values separately: 18 hours for region A and 24 hours for region B. For batch three, with a production completion time of 15:00, if it is shipped to region A, then 16:00 + 18 hours - 15 hours equals 19 hours, which is no more than 62 hours, and is feasible; if it is shipped to region B, then 16:00 + 24 hours - 15 hours equals 25 hours, which is also no more than 62 hours, and is also feasible. When a region has fewer than 30 historical orders, it is merged with adjacent regions before taking the quantile. Example
[0082] This embodiment illustrates alternative implementation methods. First, the saturation function of the flow response can be replaced with a Shell function, logarithmic function, or piecewise linear function, as long as it satisfies the characteristic that the increment monotonically increases with the budget and the growth rate decreases. Second, the prediction baseline model can use a combination of a long short-term memory network and gradient boosting decision tree residual correction, or a seasonal difference autoregressive moving average model or gradient boosting decision tree direct regression. Third, the number and combination of sales platforms are not limited to the five listed in this embodiment, and the data acquisition method is not limited to interface integration. Fourth, the processing of cold chain delivery time can use the quantile method, scenario method, or rolling correction method, or a combination of all three. Fifth, the product is not limited to braised food; it can be any fresh food with a total shelf life not exceeding the preset time and multiple production batches existing daily; the delivery method is not limited to cold chain with ice packs. Sixth, the solver is not limited to open-source solvers; the scheduling solution can use planning algorithms, heuristic algorithms, or a combination of both.
[0083] The above-described embodiments can be implemented individually or in combination. Equivalent substitutions and conventional modifications made by those skilled in the art based on the technical solutions of this invention are all within the scope of protection of this invention.
[0084] The present invention also provides a fresh food production scheduling system based on flow response quantification and batch shelf life hard constraints, including a data acquisition module, a flow response quantification module, a demand synthesis module, a feasible wave determination module, a batch production scheduling solution module, and a batch delivery binding module. Each module is used to perform the processing corresponding to steps S1 to S8 above.
[0085] The present invention also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the above-described method.
Claims
1. A fresh food production scheduling method based on flow response quantization and batch shelf life hard constraints, applied to the production of fresh food with a total shelf life of L and multiple production batches per day, characterized in that, include: Obtain the daily traffic budget, time slots, and platform identifiers for each sales platform; The traffic investment budget is converted into sales increment by the traffic investment response quantification sub-model. The conversion includes: adopting a response function for each platform that makes the growth rate of sales increment decrease as the traffic investment budget increases; Furthermore, for each time period after the end of the campaign, the sales increase for that time period is reduced as the time remaining until the end of the campaign is calculated according to the platform's attenuation coefficient, so that the output of the conversion is a sales increase curve for each time period. The sales increment curves for each time period are superimposed on the baseline demand obtained from the historical sales sequence to obtain the total demand for each time period. Using the completion time of each production batch as a time index, the feasible set of shipping waves for each production batch is determined by the following formula: the sum of the dispatch time of the shipping wave and the cold chain delivery time of the shipping wave, minus the completion time of the production batch, is not greater than the difference between the total shelf life L and the lower limit of the remaining shelf life R_min; the feasible set of shipping waves consists of all shipping waves that satisfy this formula. Using the output of each production batch as the decision variable, the total demand of the time period as the demand input, and the constraint that the output of each production batch does not exceed the sum of the demand of the time periods corresponding to each shipping wave in its feasible shipping wave set, the solution is to find the batch output that minimizes the number of items that will be physically destroyed due to exceeding the shelf life. Production is organized according to the solution results, the actual output completion time of each production batch is recorded, and the products of each production batch are bound to the shipping waves in its feasible shipping wave set.
2. The method according to claim 1, characterized in that, The response function that causes the growth rate of sales increment to decrease as the investment budget increases is a response function with a saturation upper limit. The sales increment of platform p is calculated using the following formula: ΔS_p = S_p_max × [1 − exp(−B_p / (k_p × S_p_max))] Where B_p is the feed budget of platform p during the time period, S_p_max is the upper limit of the saturation increment of platform p during the time period, and k_p is the response coefficient of platform p; the derivative of the response function when the feed budget approaches zero is the reciprocal of k_p.
3. The method according to claim 2, characterized in that, The upper limit of the saturation increment and the response coefficient are maintained and constituted as parameter matrices according to the two dimensions of platform and time period respectively; the parameter matrix is updated by least squares rolling nonlinear fitting based on sample pairs of traffic investment budget and actual sales increment within the most recent preset number of days.
4. The method according to claim 1, characterized in that, The total shelf life L shall not exceed 72 hours, and the minimum remaining shelf life R_min shall not be less than 10 hours; the difference between the completion times of two adjacent production batches shall not be less than the production cycle of a single batch.
5. The method according to claim 1, characterized in that, The objective function for finding the batch output that minimizes the number of items physically destroyed due to exceeding shelf life is to minimize the weighted sum of the number of items physically destroyed and the number of items out of stock in each production batch and for each product category, with the weight of the number of items physically destroyed being greater than the weight of the number of items out of stock.
6. The method according to claim 1, characterized in that, The cold chain delivery time is determined in any of the following ways: taking the preset quantile of the historical delivery time under the delivery region group for the current delivery wave, wherein the quantile is not lower than the 80th quantile; or, solving multiple cold chain delivery time scenarios for the same delivery wave separately, and taking the intersection of the feasible delivery wave sets obtained from each scenario; or, after the actual delivery wave is dispatched, updating the estimated value of the cold chain delivery time with its real-time delivery progress, and incorporating it into the next production rescheduling.
7. The method according to claim 1, characterized in that, Also includes: When the deviation between the actual sales volume and the predicted value exceeds a preset threshold, production rescheduling is triggered. The rescheduling locks the output of the production batches that have already started production as the executed value and uses it as a fixed parameter, and only adjusts the output of the production batches that have not yet started production. Furthermore, based on the trigger time, the feasible shipment wave set for each production batch is recalculated, so that the set shrinks as the current time progresses.
8. The method according to claim 1, characterized in that, The baseline requirement is obtained in any of the following ways: the baseline value is output by a long short-term memory network with historical daily sales sequence as input, and the residual of the baseline value is fitted by a gradient boosting decision tree and then superimposed; or, a seasonal difference autoregressive moving average model; or, direct regression by a gradient boosting decision tree.
9. A fresh food production scheduling system based on flow response quantization and batch shelf life hard constraints, characterized in that, include: The data acquisition module is used to obtain the daily traffic budget, traffic period and traffic platform identifier, and historical sales sequence of each sales platform; The traffic delivery response quantification module is used to apply a response function to each platform, which makes the growth rate of sales increase decrease as the traffic delivery budget increases. It also applies the decay coefficient of the platform to each time period after the end of the campaign, so that the sales increase decreases with the time remaining until the end of the campaign, and outputs the sales increase curve for each time period. The demand synthesis module is used to overlay the sales increment curves of the time periods onto the baseline demand to obtain the total demand for the time periods. The feasible wave determination module is used to determine the set of feasible shipping waves for each production batch, using the output completion time of each production batch as the time index. The batch scheduling module is used to solve the batch output that minimizes the number of products that will be physically destroyed due to exceeding their shelf life, using the output of each production batch as the decision variable. The batch shipment binding module is used to record the actual output completion time of each production batch and bind the products of each production batch to the shipment wave in its feasible shipment wave set. The system is used to implement the method according to any one of claims 1 to 8.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the method of any one of claims 1 to 8.
