Group meal dish demand prediction method based on artificial intelligence

Through the artificial intelligence-based group meal demand prediction method, and the prediction model is established and trained using multi-dimensional data, the problems of inaccurate and inefficient prediction of traditional methods are solved, and more efficient and accurate demand prediction is achieved.

CN119722155APending Publication Date: 2025-03-28苏州星点点信息科技有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411802010.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-09
Publication Date
2025-03-28

AI Technical Summary

Technical Problem

The traditional method of group meal demand prediction depends on manual experience, and there are problems such as inaccurate prediction and inefficient efficiency.

Method used

Using artificial intelligence-based group meal demand prediction method, we collect and preprocess historical sales data, user evaluation data, seasonal factor data, holiday data and meteorological data, and use artificial intelligence algorithms to establish demand prediction models and train to achieve accurate prediction.

Benefits of technology

It improves the accuracy and efficiency of group meal demand forecasts, and can predict dishes demand more accurately, thereby improving the operational efficiency and service quality of catering companies.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119722155A_ABST
    Figure CN119722155A_ABST
Patent Text Reader

Abstract

The invention discloses a group meal dish demand prediction method based on artificial intelligence, which belongs to the technical field of dish demand prediction, and comprises the following steps: collecting historical sales data, user evaluation data, seasonal factor data, holiday and festival data and meteorological data; and then an artificial intelligence algorithm is used to learn data relationships between historical sales data, user evaluation data, seasonal factor data, holiday and festival data and meteorological data and group meal daily sales volume, so that accurate prediction of group meal dish demands is realized, and finally operation efficiency and service quality of catering enterprises are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of dish demand prediction, and in particular relates to a group meal dish demand prediction method based on artificial intelligence. Background Art

[0002] Group meals, also known as group catering, refer to catering services provided to groups, which usually occur in collective occasions such as schools, enterprises, government agencies, meetings, and events. The characteristics of group meals include batch production, unified supply, and large-scale groups with fixed or temporary service objects. With the rapid development of the group meal market, how to accurately predict the demand for dishes has become a major challenge facing catering companies. Traditional demand forecasting methods often rely on manual experience, and there are problems such as inaccurate forecasting and low efficiency. Therefore, it is necessary to study a group meal dish demand forecasting method based on artificial intelligence to improve the forecast accuracy. Summary of the invention

[0003] The present invention provides a method for predicting group meal menu demand based on artificial intelligence, so as to solve the problems that the prior art relies on manual experience, has inaccurate prediction, low efficiency, etc.

[0004] A method for predicting group meal demand based on artificial intelligence, comprising:

[0005] Collecting multi-dimensional data on group meal sales; wherein the multi-dimensional data on group meal sales includes historical sales data, user evaluation data, seasonal factor data, holiday data, and meteorological data;

[0006] Clean, deduplicate, normalize and format the collected multi-dimensional data on group meal sales to obtain pre-processed multi-dimensional data on group meal sales;

[0007] An artificial intelligence algorithm is used to establish a group meal demand prediction model, and the group meal demand prediction model is trained through pre-processed multi-dimensional group meal sales data. By adjusting the model parameters, a trained group meal demand prediction model is obtained;

[0008] The multi-dimensional data to be predicted is obtained and normalized, and the normalized multi-dimensional data to be predicted is input into the trained group meal food demand prediction model to obtain the group meal food demand prediction result.

[0009] Furthermore, the historical sales data includes group meal dish types, group meal daily sales, group meal average order price, group meal box fee, group meal average delivery fee, group meal actual price, group meal average payment price and average discount;

[0010] The user evaluation data includes the number of group meal collections, the average group meal evaluation score, and the number of group meal purchases in history;

[0011] The seasonal factor data include spring, summer, autumn or winter;

[0012] The holiday data includes statutory holidays, working days or non-working days;

[0013] The meteorological data includes the average temperature during the group meal purchasing period, the weather during the group meal purchasing period, and the rainfall during the group meal purchasing period.

[0014] Furthermore, the collected multi-dimensional data on group meal sales is cleaned, deduplicated, normalized, and formatted to obtain the pre-processed multi-dimensional data on group meal sales, including:

[0015] For the historical sales data, user evaluation data, seasonal factor data, holiday data and meteorological data in the multi-dimensional data of group meal sales, the non-text data is converted into numerical values ​​according to the preset text character conversion rules to obtain the converted multi-dimensional data of group meal sales;

[0016] For the converted multi-dimensional data of group meal sales, determine whether there are missing values. If so, take the average of the data before and after the missing value or deduce it based on the data before and after the missing value to obtain the multi-dimensional data of group meal sales after the missing value processing. Otherwise, directly use the original data as the multi-dimensional data of group meal sales after the missing value processing.

[0017] Determine whether there are two sets of multi-dimensional data on the sales of group meals after missing values ​​are processed on the same day. If so, randomly remove one set to obtain the multi-dimensional data on the sales of group meals after deduplication. Otherwise, directly obtain the multi-dimensional data on the sales of group meals after deduplication.

[0018] Normalizing the group meal dish sales multi-dimensional data after deduplication processing to obtain normalized group meal dish sales multi-dimensional data;

[0019] For the normalized multi-dimensional data of group meal sales, the historical sales data and user evaluation data of the previous N days and the seasonal factor data, holiday data and meteorological data of the N+1th day are used as training samples, and the daily sales volume of group meals on the N+1th day is used as the true value label corresponding to the training sample to obtain the multi-dimensional data of group meal sales after preprocessing.

[0020] Furthermore, an artificial intelligence algorithm is used to establish a group meal dish demand prediction model, including: using a BP neural network algorithm to construct a group meal dish demand prediction model.

[0021] Furthermore, the group meal dish demand prediction model is trained by preprocessing the multi-dimensional group meal dish sales data, and the trained group meal dish demand prediction model is obtained by adjusting the model parameters, including:

[0022] According to the processed multi-dimensional data of group meal sales, an adaptive hidden layer node number selection algorithm is used to obtain the number of hidden layer nodes of the group meal demand prediction model, and a group meal demand prediction model with a determined structure is obtained;

[0023] The improved IPSO algorithm is used to adjust the weights of the group meal demand prediction model after the structure is determined to obtain a trained group meal demand prediction model.

[0024] Furthermore, according to the processed multi-dimensional data of group meal sales, an adaptive hidden layer node number selection algorithm is used to obtain the number of hidden layer nodes of the group meal demand prediction model, and a group meal demand prediction model with a determined structure is obtained, including:

[0025] According to the processed multi-dimensional data of group meal sales, determine the number of input nodes and the number of output nodes of the group meal demand prediction model;

[0026] Randomly initialize the weight parameters of the group meal demand prediction model, the maximum number of hidden layer nodes K, and the counter k = 1;

[0027] Let the number of hidden layer nodes be k, and train the group meal demand prediction model based on the processed multi-dimensional data of group meal sales, and obtain the MSE value in the k-th training process;

[0028] Determine whether the count value of counter k reaches the maximum number of hidden layer nodes K. If so, enter the step of determining the number of hidden layer nodes. Otherwise, add one to the count value of counter k and return to the step of obtaining the MSE value in the kth training process.

[0029] According to the MSE values ​​corresponding to the K training processes, the number of target hidden layer nodes with the minimum MSE value is determined;

[0030] According to the target number of hidden layer nodes, the number of input nodes and the number of output nodes, the number of hidden layer nodes of the group meal dish demand prediction model is determined, and the group meal dish demand prediction model after the structure is determined is obtained.

[0031] Furthermore, the improved IPSO algorithm is used to adjust the weights of the group meal demand forecasting model after the structure is determined, and a trained group meal demand forecasting model is obtained, including:

[0032] Initialize the particle swarm based on the weights of the group meal demand prediction model;

[0033] Determine the local optimum and the global optimum based on the processed multi-dimensional data of group meal sales;

[0034] When the number of weight training times is less than the preset maximum number of training times, the particles are subjected to mutation and neighborhood crossover operations to determine the particles after the crossover;

[0035] Determine the nonlinear inertia weight, and use the nonlinear inertia weight, local optimum and global optimum to perform social learning on the particles after the crossover to obtain the particles after social learning;

[0036] Performing social information interaction on particles after social learning to obtain particles after social information interaction;

[0037] Determine whether the number of weight training times is less than the preset maximum number of weight training times. If so, return to the steps of determining the local optimum and the global optimum. Otherwise, redetermine the global optimum based on the particles after social information interaction to determine the trained group meal demand prediction model.

[0038] Furthermore, a mutation operation and a neighborhood crossover operation are performed on the particles to determine the particles after the crossover, including:

[0039] For any particle, randomly select any three other particles and determine the mutant particle based on the other particles;

[0040] For any particle, obtain the Euclidean distance between the particle and its corresponding variant particle, and determine whether the Euclidean distance is less than one-quarter of the search length. If so, cross the particle with its corresponding variant particle to obtain the crossover particle. Otherwise, use the original particle directly as the crossover particle.

[0041] Furthermore, social information interaction is performed on the particles after social learning to obtain particles after social information interaction, including:

[0042] For any particle after social learning, determine its corresponding social information interaction particle;

[0043] An exponential function and an information interaction method limited by relative distance are used to perform social information interaction between particles after social learning and corresponding social information interaction particles to obtain particles after social information interaction.

[0044] Furthermore, the multi-dimensional data to be predicted is obtained and normalized, and the normalized multi-dimensional data to be predicted is input into the trained group meal dish demand prediction model to obtain the group meal dish demand prediction result, including:

[0045] Acquire multi-dimensional data to be predicted; wherein the multi-dimensional data to be predicted includes historical sales data N days before the date to be predicted, user evaluation data, and seasonal factor data, holiday data, and meteorological data corresponding to the date to be predicted;

[0046] Normalizing the multi-dimensional data to be predicted to obtain normalized multi-dimensional data to be predicted;

[0047] Input the normalized multi-dimensional data to be predicted into the trained group meal demand prediction model to obtain the group meal demand;

[0048] According to the demand for group meals and the number of dishes required for each group meal, the group meal dish demand forecast results are obtained.

[0049] The present invention provides a method for predicting the demand for group meal dishes based on artificial intelligence. The method collects historical sales data, user evaluation data, seasonal factor data, holiday data and meteorological data, and then uses an artificial intelligence algorithm to learn the data relationship between the historical sales data, user evaluation data, seasonal factor data, holiday data and meteorological data and the daily sales volume of group meals, thereby achieving accurate prediction of the demand for group meal dishes, and ultimately improving the operating efficiency and service quality of catering enterprises. BRIEF DESCRIPTION OF THE DRAWINGS

[0050] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.

[0051] Figure 1 A flowchart of a method for predicting group meal menu demand based on artificial intelligence provided in an embodiment of the present invention.

[0052] The above drawings have shown clear embodiments of the present invention, which will be described in more detail below. These drawings and text descriptions are not intended to limit the scope of the present invention in any way, but to illustrate the concept of the present invention for those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION

[0053] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Instead, they are merely examples of devices and methods consistent with some aspects of the present invention as detailed in the appended claims.

[0054] The embodiments of the present invention are described in detail below with reference to the accompanying drawings.

[0055] like Figure 1 As shown, an embodiment of the present invention provides a method for predicting group meal demand based on artificial intelligence, including:

[0056] S1. Collect multi-dimensional data on group meal sales; wherein the multi-dimensional data on group meal sales includes historical sales data, user evaluation data, seasonal factor data, holiday data, and meteorological data;

[0057] The multi-dimensional data of group meal sales needs to include daily data, and then these data can be learned to determine the impact of time characteristics and spatial characteristics on the daily sales of group meals, and finally realize the demand forecast of group meal dishes. However, it is worth noting that the above data is only the preferred data of the embodiment of the present invention, and other data related to group meal sales can also be used for learning, and the above data can also be deleted.

[0058] S2. Clean, deduplicate, normalize and format the collected multi-dimensional data on group meal sales to obtain pre-processed multi-dimensional data on group meal sales;

[0059] The above cleaning, deduplication, normalization and formatting are to make the data complete and in a unified format, so as to facilitate data learning and recognition. In the subsequent recognition process, the data to be recognized also needs to be organized into data of the same type and format, so as to facilitate effective recognition by artificial intelligence.

[0060] S3. Use artificial intelligence algorithms to establish a group meal demand prediction model, and train the group meal demand prediction model through pre-processed multi-dimensional group meal sales data, and obtain a trained group meal demand prediction model by adjusting model parameters;

[0061] Artificial intelligence algorithms such as BP (Back Propagation) neural network algorithm, CNN (Convolutional Neural Network) algorithm, LSTM (Long Short-Term Memory) algorithm, etc. can be used to establish a group meal dish demand prediction model. However, since the data dimension involved in the embodiment of the present invention is relatively small, the embodiment of the present invention preferably uses the BP neural network algorithm to establish a group meal dish demand prediction model, and the group meal dish demand prediction model can be trained by the gradient descent method.

[0062] S4. Obtain the multi-dimensional data to be predicted and normalize it, and input the normalized multi-dimensional data to be predicted into the trained group meal dish demand prediction model to obtain the group meal dish demand prediction result.

[0063] The present invention provides a method for predicting the demand for group meal dishes based on artificial intelligence. The method collects historical sales data, user evaluation data, seasonal factor data, holiday data and meteorological data, and then uses an artificial intelligence algorithm to learn the data relationship between the historical sales data, user evaluation data, seasonal factor data, holiday data and meteorological data and the daily sales volume of group meals, thereby achieving accurate prediction of the demand for group meal dishes, and ultimately improving the operating efficiency and service quality of catering enterprises.

[0064] In an embodiment of the present invention, the historical sales data includes group meal dish types, group meal daily sales, group meal average order price, group meal box fee, group meal average delivery fee, group meal actual price, group meal average payment price and average discount;

[0065] The user evaluation data includes the number of group meal collections, the average group meal evaluation score, and the number of group meal purchases in history;

[0066] The seasonal factor data include spring, summer, autumn or winter;

[0067] The holiday data includes statutory holidays, working days or non-working days;

[0068] The meteorological data include the average temperature during the group meal purchasing period, the weather during the group meal purchasing period (such as sunny, cloudy, light rain, heavy rain and other weather conditions clearly specified in the weather forecast) and the rainfall during the group meal purchasing period (which can be determined through weather forecasts or actual conditions).

[0069] For data related to group meal sales, the daily average data can be used as the basis to determine the historical sales data and user evaluation data corresponding to each day. Other data can be determined through weather forecasts or actual conditions, thereby determining the daily historical sales data, user evaluation data, seasonal factor data, holiday data and meteorological data, and then using this as the basis for artificial intelligence training.

[0070] In an embodiment of the present invention, the collected multi-dimensional data on group meal sales is cleaned, deduplicated, normalized, and formatted to obtain the pre-processed multi-dimensional data on group meal sales, including:

[0071] For the historical sales data, user evaluation data, seasonal factor data, holiday data and meteorological data in the multi-dimensional data of group meal sales, the non-text data is converted into numerical values ​​according to the preset text character conversion rules to obtain the converted multi-dimensional data of group meal sales;

[0072] For example, the type of group meal dishes can be set as a type code, and non-numeric data such as seasonal factor data and holiday data can also be set with corresponding codes, thereby converting non-numeric data into recognizable data.

[0073] For the converted multi-dimensional data of group meal sales, determine whether there are missing values. If so, take the average of the data before and after the missing value or deduce it based on the data before and after the missing value to obtain the multi-dimensional data of group meal sales after the missing value processing. Otherwise, directly use the original data as the multi-dimensional data of group meal sales after the missing value processing.

[0074] For example, when a certain day is a working day, you can determine whether another day is a working day based on the actual date of that day. Or, when the sales data for a certain day is missing, you can take the average of the sales data before and after that day as the missing value.

[0075] Optionally, the multi-dimensional data of group meal sales corresponding to the missing values ​​may be directly removed, and then the continuous part may be selected when determining the training samples later.

[0076] Determine whether there are two sets of multi-dimensional data on the sales of group meals after missing values ​​are processed on the same day. If so, randomly remove one set to obtain the multi-dimensional data on the sales of group meals after deduplication. Otherwise, directly obtain the multi-dimensional data on the sales of group meals after deduplication.

[0077] Normalizing the group meal dish sales multi-dimensional data after deduplication processing to obtain normalized group meal dish sales multi-dimensional data;

[0078] For the normalized multi-dimensional data of group meal sales, the historical sales data and user evaluation data of the previous N days and the seasonal factor data, holiday data and meteorological data of the N+1th day are used as training samples, and the daily sales volume of group meals on the N+1th day is used as the true value label corresponding to the training sample to obtain the multi-dimensional data of group meal sales after preprocessing.

[0079] In an embodiment of the present invention, an artificial intelligence algorithm is used to establish a group meal dish demand prediction model, including: using a BP neural network algorithm to build a group meal dish demand prediction model. It is worth noting that this algorithm is only a preferred method of the embodiment of the present invention, and other algorithms can also be used to build a group meal dish demand prediction model.

[0080] In an embodiment of the present invention, a group meal dish demand prediction model is trained by preprocessing the multi-dimensional group meal dish sales data, and a trained group meal dish demand prediction model is obtained by adjusting the model parameters, including:

[0081] According to the processed multi-dimensional data of group meal sales, an adaptive hidden layer node number selection algorithm is used to obtain the number of hidden layer nodes of the group meal demand prediction model, and a group meal demand prediction model with a determined structure is obtained;

[0082] The improved IPSO (particle swarm) algorithm is used to adjust the weights of the group meal demand prediction model after the structure is determined to obtain a trained group meal demand prediction model.

[0083] Optionally, the group meal menu demand prediction model can be trained in the process of obtaining the number of hidden layer nodes of the group meal menu demand prediction model, but this method requires complete optimization of the weights in each training, which consumes a lot of time and computing power. Therefore, the embodiment of the present invention first uses fixed weights to determine the number of hidden layer nodes, and then trains the group meal menu demand prediction model after the structure is determined to improve the efficiency of the algorithm.

[0084] In an embodiment of the present invention, according to the processed multi-dimensional data of group meal sales, an adaptive hidden layer node number selection algorithm is used to obtain the number of hidden layer nodes of the group meal demand prediction model, and a group meal demand prediction model with a determined structure is obtained, including:

[0085] According to the processed multi-dimensional data of group meal sales, determine the number of input nodes and the number of output nodes of the group meal demand prediction model;

[0086] Randomly initialize the weight parameters of the group meal demand prediction model, the maximum number of hidden layer nodes K, and the counter k = 1;

[0087] Let the number of hidden layer nodes be k, and train the group meal demand prediction model based on the processed multi-dimensional data of group meal sales, and obtain the MSE (root mean square error function) value in the k-th training process;

[0088] Determine whether the count value of counter k reaches the maximum number of hidden layer nodes K. If so, enter the step of determining the number of hidden layer nodes. Otherwise, add one to the count value of counter k and return to the step of obtaining the MSE value in the kth training process.

[0089] According to the MSE values ​​corresponding to the K training processes, the number of target hidden layer nodes with the minimum MSE value is determined;

[0090] According to the target number of hidden layer nodes, the number of input nodes and the number of output nodes, the number of hidden layer nodes of the group meal dish demand prediction model is determined, and the group meal dish demand prediction model after the structure is determined is obtained.

[0091] According to the target number of hidden layer nodes, the number of input nodes and the number of output nodes, the number of hidden layer nodes of the group meal menu demand prediction model is determined. When the target number of hidden layer nodes is < (the number of input nodes + the number of output nodes) / 2, the number of hidden layer nodes is determined to be (the number of input nodes + the number of output nodes) / 2. When the target number of hidden layer nodes is > (2*the number of input nodes+1), the number of hidden layer nodes is determined to be (2*the number of input nodes+1); in other cases, the number of hidden layer nodes is determined to be the target number of hidden layer nodes.

[0092] Optionally, the number of hidden layer nodes may also be directly determined as the target number of hidden layer nodes.

[0093] Usually the topological structure of the network is determined through network learning or experiments, and the hidden layer of the network is the most important. The number of nodes and layers of the hidden layer will determine the overall structure of a network and the way information is transmitted. The number of nodes in the hidden layer has an important influence on the training efficiency and training accuracy of the neural network. Most existing network models use artificial experience or trial and error to set the number of nodes in the hidden layer, which is blind and ultimately leads to the network model being unable to accurately identify data or having a high misrecognition rate. Therefore, the embodiments of the present invention can effectively solve the problems existing in the prior art by determining the number of nodes in the hidden layer, and ultimately improve the accuracy of group meal demand prediction.

[0094] In the embodiment of the present invention, the improved IPSO algorithm is used to adjust the weight of the group meal dish demand prediction model after the structure is determined, so as to obtain a trained group meal dish demand prediction model, including:

[0095] Initialize the particle swarm based on the weights of the group meal demand prediction model;

[0096] Determine the local optimum and the global optimum based on the processed multi-dimensional data of group meal sales;

[0097] When the number of weight training times is less than the preset maximum number of training times, the particles are subjected to mutation and neighborhood crossover operations to determine the particles after the crossover;

[0098] Determine the nonlinear inertia weight, and use the nonlinear inertia weight, local optimum and global optimum to perform social learning on the particles after the crossover to obtain the particles after social learning;

[0099] Performing social information interaction on particles after social learning to obtain particles after social information interaction;

[0100] Determine whether the number of weight training times is less than the preset maximum number of weight training times. If so, return to the steps of determining the local optimum and the global optimum. Otherwise, redetermine the global optimum based on the particles after social information interaction to determine the trained group meal demand prediction model.

[0101] In the embodiment of the present invention, performing a mutation operation and a neighborhood crossover operation on particles to determine particles after the crossover includes:

[0102] For any particle, randomly select any three other particles, and determine the mutant particle based on the other particles:

[0103]

[0104] in, represents the i-th particle in the t-th training process The corresponding mutant particles, F represents a random number between (-1,1), Represents three and particles Different other particles; i = 1, 2, …, I, I represents the total number of particles.

[0105] For any particle, obtain the Euclidean distance between the particle and its corresponding variant particle, and determine whether the Euclidean distance is less than one-quarter of the search length. If so, cross the particle with its corresponding variant particle to obtain the crossover particle. Otherwise, use the original particle directly as the crossover particle.

[0106] The search length can be determined by the Euclidean distance between the weight upper limit vector and the weight lower limit vector. Crossing a particle with its corresponding mutant particle can include: exchanging multiple weights in the particle with weights of multiple corresponding positions in the mutant particle to obtain two crossed particles; for the original particle, the mutant particle and the two crossed particles, determining the particle with the smallest MSE value as the particle after the crossover. By mutating and crossing particles, it is possible to effectively search for particles globally and avoid the algorithm from falling into a local optimum.

[0107] In an embodiment of the present invention, a nonlinear inertia weight is determined, and the nonlinear inertia weight, local optimum and global optimum are used to perform social learning on particles after the crossover to obtain particles after social learning, including:

[0108] Determine the nonlinear inertia weight as:

[0109]

[0110] in, represents the nonlinear inertia weight, represents the upper limit of the nonlinear inertia weight, represents the lower limit of the nonlinear inertia weight, T represents the maximum number of training times, rand1 represents a random number between (0,1), b represents an intermediate parameter, and

[0111] By adopting nonlinear inertia weight, the probability of taking a larger value of inertia weight in the early stage of search can be increased, and particles can search the entire space at a higher flight speed and determine the range of the global optimal solution, ensuring the global search capability of the population; the probability of taking a smaller value of inertia weight in the later stage of search increases, and particles obtain a smaller flight speed, which can more accurately search the neighborhood of the optimal solution position and ensure the local development capability of the population, which can balance the search performance of the algorithm. At the same time, during the search process, the inertia weight value is dynamically adjusted with the number of iterations, which can continuously correct the speed and position of the particles, strengthen the interaction of particles, and help particles quickly find the optimal solution, avoiding the algorithm from falling into the local optimum, and the dynamic change of inertia weight meets the nonlinear and complex characteristics of the actual search process.

[0112] Using nonlinear inertia weight, local optimum and global optimum, social learning is performed on the particles after crossover, and the particles after social learning are:

[0113]

[0114] in, represents the velocity of the particle after the jth crossover during the tth training process, represents the velocity of the particle after the jth crossover in the t+1th training process, c1 represents the first social learning factor, c2 represents the second social learning factor, P j represents the local optimum (i.e., historical optimum) of the particle after the jth crossover, G t represents the global optimum of the current particle swarm, rand2 represents a random number between (0,1), and rand3 represents a random number between (0,1). represents the particle after the jth crossover in the tth training process, Represents the particle after social learning

[0115] In an embodiment of the present invention, social information interaction is performed on particles after social learning to obtain particles after social information interaction, including:

[0116] For any particle after social learning, determine its corresponding social information interaction particle;

[0117] An exponential function and an information interaction method limited by relative distance are used to perform social information interaction between particles after social learning and corresponding social information interaction particles to obtain particles after social information interaction.

[0118] The particles after social information interaction are:

[0119]

[0120] in, represents the particle after the mth social learning in the tth training process, Represents particles after social information interaction represents the amount of information interaction at the t+1th time, represents the information interaction amount of the tth time, α represents the information interaction coefficient, e represents the natural constant, β represents the information interaction degree control coefficient, Represents particles The corresponding social information interaction particle, d ms Represents particles Interacting particles with social information The Euclidean distance between .

[0121] The particle swarm algorithm of the embodiment of the present invention introduces social information interaction, which not only enables particles to learn the position information contained in other particles, but also realizes multi-directional search, which is more conducive to exploring unfamiliar areas, thereby improving the convergence speed of the algorithm.

[0122] The improved IPSO algorithm provided by the embodiment of the present invention can effectively avoid the defect of the existing IPSO algorithm that it is easy to fall into the local optimal value, and improve the convergence speed of the algorithm, ultimately improving the prediction accuracy of the group meal dish demand prediction model, and realizing high-accuracy group meal dish demand prediction.

[0123] In an embodiment of the present invention, the multi-dimensional data to be predicted is obtained and normalized, and the normalized multi-dimensional data to be predicted is input into a trained group meal dish demand prediction model to obtain a group meal dish demand prediction result, including:

[0124] Acquire multi-dimensional data to be predicted; wherein the multi-dimensional data to be predicted includes historical sales data N days before the date to be predicted, user evaluation data, and seasonal factor data, holiday data, and meteorological data corresponding to the date to be predicted;

[0125] Normalizing the multi-dimensional data to be predicted to obtain normalized multi-dimensional data to be predicted;

[0126] Input the normalized multi-dimensional data to be predicted into the trained group meal demand prediction model to obtain the group meal demand;

[0127] According to the demand for group meals and the number of dishes required for each group meal, the group meal dish demand forecast results are obtained.

[0128] Optionally, for different types of group meals, separate group meal demand forecasts should be conducted, so that the forecast results of group meal demand for each type can be determined, and then purchases can be made based on the forecast results. Furthermore, purchase management can be performed in combination with inventory conditions and current forecast conditions, that is, when the current forecast conditions consume the preset number of days, if the inventory is insufficient, purchases need to be made.

[0129] Those skilled in the art will appreciate that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0130] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0131] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0132] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0133] A person of ordinary skill in the art can understand that all or part of the steps in realizing the above-mentioned facts and methods can be completed by instructing the relevant hardware through a program, and the program involved or the program described can be stored in a computer-readable storage medium. When the program is executed, it includes the following steps: At this time, the corresponding method steps are derived, and the storage medium can be ROM / RAM, a disk, an optical disk, etc.

[0134] The specific implementation methods described above further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific implementation method of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.

Claims

1. A method for predicting group meal demand based on artificial intelligence, characterized in that: include: Collecting multi-dimensional data on group meal sales; wherein the multi-dimensional data on group meal sales includes historical sales data, user evaluation data, seasonal factor data, holiday data, and meteorological data; Clean, deduplicate, normalize and format the collected multi-dimensional data on group meal sales to obtain pre-processed multi-dimensional data on group meal sales; An artificial intelligence algorithm is used to establish a group meal demand prediction model, and the group meal demand prediction model is trained through pre-processed multi-dimensional group meal sales data. By adjusting the model parameters, a trained group meal demand prediction model is obtained; The multi-dimensional data to be predicted is obtained and normalized, and the normalized multi-dimensional data to be predicted is input into the trained group meal food demand prediction model to obtain the group meal food demand prediction result.

2. The method for predicting group meal demand based on artificial intelligence according to claim 1 is characterized in that: The historical sales data includes group meal dish types, group meal daily sales, group meal average order price, group meal box fees, group meal average delivery fees, group meal actual prices, group meal average payment prices, and average discounts; The user evaluation data includes the number of group meal collections, the average group meal evaluation score, and the number of group meal purchases in history; The seasonal factor data include spring, summer, autumn or winter; The holiday data includes statutory holidays, working days or non-working days; The meteorological data includes the average temperature during the group meal purchasing period, the weather during the group meal purchasing period, and the rainfall during the group meal purchasing period.

3. The method for predicting group meal demand based on artificial intelligence according to claim 2 is characterized in that: The collected multi-dimensional data on group meal sales is cleaned, deduplicated, normalized, and formatted to obtain the pre-processed multi-dimensional data on group meal sales, including: For the historical sales data, user evaluation data, seasonal factor data, holiday data and meteorological data in the multi-dimensional data of group meal sales, the non-text data is converted into numerical values ​​according to the preset text character conversion rules to obtain the converted multi-dimensional data of group meal sales; For the converted multi-dimensional data of group meal sales, determine whether there are missing values. If so, take the average of the data before and after the missing value or deduce it based on the data before and after the missing value to obtain the multi-dimensional data of group meal sales after the missing value processing. Otherwise, directly use the original data as the multi-dimensional data of group meal sales after the missing value processing. Determine whether there are two sets of multi-dimensional data on the sales of group meals after missing values ​​are processed on the same day. If so, randomly remove one set to obtain the multi-dimensional data on the sales of group meals after deduplication. Otherwise, directly obtain the multi-dimensional data on the sales of group meals after deduplication. Normalizing the group meal dish sales multi-dimensional data after deduplication processing to obtain normalized group meal dish sales multi-dimensional data; For the normalized multi-dimensional data of group meal sales, the historical sales data and user evaluation data of the previous N days and the seasonal factor data, holiday data and meteorological data of the N+1th day are used as training samples, and the daily sales volume of group meals on the N+1th day is used as the true value label corresponding to the training sample to obtain the multi-dimensional data of group meal sales after preprocessing.

4. The method for predicting group meal demand based on artificial intelligence according to claim 3 is characterized in that: An artificial intelligence algorithm is used to establish a group meal dish demand prediction model, including: using a BP neural network algorithm to construct a group meal dish demand prediction model.

5. The method for predicting group meal demand based on artificial intelligence according to claim 3 is characterized in that: The group meal demand prediction model is trained through the pre-processed multi-dimensional group meal sales data. By adjusting the model parameters, the trained group meal demand prediction model is obtained, including: According to the processed multi-dimensional data of group meal sales, an adaptive hidden layer node number selection algorithm is used to obtain the number of hidden layer nodes of the group meal demand prediction model, and a group meal demand prediction model with a determined structure is obtained; The improved IPSO algorithm is used to adjust the weights of the group meal demand prediction model after the structure is determined to obtain a trained group meal demand prediction model.

6. The method for predicting group meal demand based on artificial intelligence according to claim 5 is characterized in that: According to the processed multi-dimensional data of group meal sales, an adaptive hidden layer node number selection algorithm is used to obtain the number of hidden layer nodes of the group meal demand prediction model, and a group meal demand prediction model with a determined structure is obtained, including: According to the processed multi-dimensional data of group meal sales, determine the number of input nodes and the number of output nodes of the group meal demand prediction model; Randomly initialize the weight parameters of the group meal demand prediction model, the maximum number of hidden layer nodes K, and the counter k = 1; Let the number of hidden layer nodes be k, and train the group meal demand prediction model based on the processed multi-dimensional data of group meal sales, and obtain the MSE value in the k-th training process; Determine whether the count value of counter k reaches the maximum number of hidden layer nodes K. If so, enter the step of determining the number of hidden layer nodes. Otherwise, add one to the count value of counter k and return to the step of obtaining the MSE value in the kth training process. According to the MSE values ​​corresponding to the K training processes, the number of target hidden layer nodes with the minimum MSE value is determined; According to the target number of hidden layer nodes, the number of input nodes and the number of output nodes, the number of hidden layer nodes of the group meal dish demand prediction model is determined, and the group meal dish demand prediction model after the structure is determined is obtained.

7. The method for predicting group meal demand based on artificial intelligence according to claim 6 is characterized in that: The improved IPSO algorithm is used to adjust the weights of the group meal demand forecasting model after the structure is determined, and a trained group meal demand forecasting model is obtained, including: Initialize the particle swarm based on the weights of the group meal demand prediction model; Determine the local optimum and the global optimum based on the processed multi-dimensional data of group meal sales; When the number of weight training times is less than the preset maximum number of training times, the particles are subjected to mutation and neighborhood crossover operations to determine the particles after the crossover; Determine the nonlinear inertia weight, and use the nonlinear inertia weight, local optimum and global optimum to perform social learning on the particles after the crossover to obtain the particles after social learning; Performing social information interaction on particles after social learning to obtain particles after social information interaction; Determine whether the number of weight training times is less than the preset maximum number of weight training times. If so, return to the steps of determining the local optimum and the global optimum. Otherwise, redetermine the global optimum based on the particles after social information interaction to determine the trained group meal demand prediction model.

8. The method for predicting group meal demand based on artificial intelligence according to claim 7 is characterized in that: Perform mutation operations and neighborhood crossover operations on particles to determine the particles after crossover, including: For any particle, randomly select any three other particles and determine the mutant particle based on the other particles; For any particle, obtain the Euclidean distance between the particle and its corresponding variant particle, and determine whether the Euclidean distance is less than one-quarter of the search length. If so, cross the particle with its corresponding variant particle to obtain the crossover particle. Otherwise, use the original particle directly as the crossover particle.

9. The method for predicting group meal demand based on artificial intelligence according to claim 8 is characterized in that: The particles after social learning are subjected to social information interaction to obtain particles after social information interaction, including: For any particle after social learning, determine its corresponding social information interaction particle; An exponential function and an information interaction method limited by relative distance are used to perform social information interaction between particles after social learning and corresponding social information interaction particles to obtain particles after social information interaction.

10. The method for predicting group meal demand based on artificial intelligence according to claim 1 is characterized in that: The multi-dimensional data to be predicted is obtained and normalized, and the normalized multi-dimensional data to be predicted is input into the trained group meal demand prediction model to obtain the group meal demand prediction results, including: Acquire multi-dimensional data to be predicted; wherein the multi-dimensional data to be predicted includes historical sales data N days before the date to be predicted, user evaluation data, and seasonal factor data, holiday data, and meteorological data corresponding to the date to be predicted; Normalizing the multi-dimensional data to be predicted to obtain normalized multi-dimensional data to be predicted; Input the normalized multi-dimensional data to be predicted into the trained group meal demand prediction model to obtain the group meal demand; According to the demand for group meals and the number of dishes required for each group meal, the group meal dish demand forecast results are obtained.