Tea bar machine control method and device based on big data collection and computer storage medium
Through cloud platform and user behavior prediction models, the smart tea bar machine can identify user preferences and automatically adjust its status, solving the problem that the existing smart tea bar machine cannot accurately predict user preferences and improves the user experience.
Patent Information
- Application Number
- CN202411107761.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-13
- Publication Date
- 2024-12-03
Smart Images

Figure CN119071338A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of intelligent control of tea bar machines, and in particular to a tea bar machine control method, device and computer storage medium based on big data collection. Background Art
[0002] With the rapid development of Internet of Things technology and the popularization of smart home concepts, people pay more and more attention to their health, and the demand for intelligent drinking water equipment is also increasing. As a common drinking water equipment in homes and offices, the intelligence level of tea bar machines is increasingly attracting the attention of users. Traditional tea bar machines mostly rely on manual operation and cannot be intelligently adjusted according to the personalized needs of users. There is a large room for improvement in user experience. Although some intelligent tea bar machines have appeared on the existing market, most of these products only have simple functions such as timing and heat preservation. They lack in-depth mining and analysis of user behavior data and cannot accurately predict and meet the personalized preferences of users. For example, users may want the tea bar machine to automatically boil water to their preferred temperature within a specific time period, but existing products often cannot automatically recognize and execute such complex instructions. In addition, the intelligence level of the intelligent tea bar machine is also restricted by the accuracy of the user behavior prediction model. Traditional prediction models are often based on simple statistical laws or empirical formulas, which are difficult to cope with complex and changeable user behavior patterns, resulting in large deviations in prediction results and unable to effectively guide the intelligent control of the tea bar machine.
[0003] Therefore, there is an urgent need for an intelligent tea bar machine control method based on big data collection and analysis, so as to accurately identify the user's personalized preferences and automatically adjust the working state according to the current usage of the tea bar machine to provide users with a more convenient and comfortable drinking experience. Summary of the invention
[0004] The purpose of the present invention is to provide a tea bar machine control method, device and computer storage medium based on big data collection, which is used to solve the problem that the prior art cannot accurately predict user behavior and intelligently control the tea bar machine.
[0005] The present invention solves the above problems through the following technical solutions:
[0006] A tea bar machine control method based on big data collection is applied to a cloud platform, the cloud platform is connected to a target tea bar machine for communication, and the method comprises:
[0007] Obtaining a user behavior data set uploaded by the target tea bar machine, wherein the user behavior data set includes user behavior data for the tea bar machine;
[0008] Inputting the user behavior data set into a pre-trained user behavior prediction model, and identifying the user preference of the user based on the user behavior prediction model;
[0009] According to the user preference and the current usage of the tea bar machine, determining whether the tea bar machine triggers the usage condition corresponding to the user preference;
[0010] When the tea bar machine does not trigger the use condition corresponding to the user preference, a trigger command is sent to the tea bar machine, and the trigger command includes a command to control the tea bar machine to run the user preference.
[0011] Furthermore, the training process of the user behavior prediction model includes:
[0012] Obtain a training sample library, the training sample library includes a plurality of training sample sets, the training sample sets are user behavior data sample sets, the user behavior data sample sets include sample behavior data of sample users for sample tea bar machines, wherein each of the training sample sets carries a corresponding user preference label;
[0013] Calling an initial user behavior prediction model to divide multiple training sample sets in the training sample library into multiple training batches;
[0014] Inputting the multiple training batches into the initial user behavior prediction model in sequence to obtain predicted user preferences corresponding to each training sample set;
[0015] Based on the predicted user preferences and the user preference labels corresponding to each training sample set, determining the loss value of the initial user behavior prediction model according to a preset loss function;
[0016] Adjusting the model parameters of the initial user behavior prediction model according to the loss value to obtain an adjusted initial user behavior prediction model;
[0017] Return to the step of inputting the multiple training batches into the initial user behavior prediction model in sequence, and iteratively execute the step of obtaining the predicted user preference corresponding to each training sample set until the initial user behavior prediction model reaches the preset training stop condition, terminate the training, and obtain the trained user behavior prediction model.
[0018] Furthermore, the initial user behavior prediction model includes an input module, a feature extraction module, a time prediction model, a pattern prediction model, and a numerical prediction model; the step of sequentially inputting the multiple training batches into the initial user behavior prediction model to obtain the predicted user preference corresponding to each training sample set includes:
[0019] Inputting the plurality of training batches into the feature extraction module in sequence through the input module;
[0020] Perform feature extraction based on the feature extraction module to obtain time series features, usage mode features and water boiling temperature features;
[0021] Inputting the time series features into the time prediction model module to obtain the prediction result of the tendency usage time of the tea bar machine;
[0022] Inputting the time series features and the usage pattern features into the pattern prediction model to obtain a prediction result of the tendency usage pattern of the tea bar machine;
[0023] Inputting the time series characteristics, the usage pattern characteristics and the water boiling temperature characteristics into the numerical prediction model to obtain the tendency setting data prediction result of the tea bar machine;
[0024] The tendency usage time prediction result, the tendency usage mode prediction result and the tendency setting data prediction result constitute the predicted user preference.
[0025] Furthermore, the feature extraction module includes:
[0026] A user preprocessing submodule, used for preprocessing the training sample sets in the input multiple training batches;
[0027] A time series feature extraction submodule, used to extract time series features of the time series data in the training sample set;
[0028] A usage pattern feature extraction submodule, used to extract usage pattern features of usage pattern data in the training sample set;
[0029] The water boiling temperature feature extraction submodule is used to extract the water boiling temperature features of the water boiling temperature data in the training sample set.
[0030] Furthermore, the time prediction model includes a time series feature extraction module and a time preference prediction module, the pattern prediction model includes a pattern classifier, and the numerical prediction model includes a regression analysis module; the time series feature is input into the time prediction model to obtain the tea bar machine's tendency to use time prediction result, including:
[0031] Input the time series features into the time series feature extraction module to obtain periodic features, trend features and seasonal features, and obtain the prediction result of the tea bar machine's tendency to use time based on the periodic features, trend features and seasonal features through the time preference prediction module;
[0032] The step of inputting the time series features and the usage pattern features into the pattern prediction model to obtain the prediction result of the tendency usage pattern of the tea bar machine includes:
[0033] Inputting the time series features and the usage pattern features into the pattern classifier, and combining the tendency usage time prediction results, to obtain the tendency usage pattern prediction results of the tea bar machine;
[0034] The step of inputting the water boiling temperature feature, the time series feature and the usage mode feature into the numerical prediction model to obtain the prediction result of the tendency setting data of the tea bar machine includes:
[0035] The water boiling temperature characteristics, time series characteristics and usage pattern characteristics are input into the regression analysis module, and the tendency usage time prediction results and the tendency usage pattern prediction results are combined to obtain the tendency setting data prediction results of the tea bar machine.
[0036] Furthermore, the user preference label includes a tendency usage time label, a tendency usage mode label, and the tendency setting data label; the loss value of the initial user behavior prediction model is determined according to a preset loss function based on the predicted user preference corresponding to each training sample set and the user preference label, including:
[0037] Obtaining a tendency usage time loss based on the tendency usage time label and the tendency usage time prediction result;
[0038] Obtaining a tendency usage pattern loss based on the tendency usage pattern label and the tendency usage pattern prediction result;
[0039] Obtaining a tendency setting data loss based on the tendency setting data label and the tendency setting data prediction result;
[0040] The tendency usage time loss, the tendency usage pattern loss, and the tendency setting data loss are integrated to obtain a total loss, and the total loss is determined as the loss value of the initial user behavior prediction model.
[0041] Furthermore, it also includes:
[0042] When the tea bar machine triggers the usage condition corresponding to the user preference, the tea bar machine is automatically controlled to run the user preference.
[0043] A tea bar machine control device based on big data collection, comprising:
[0044] An acquisition module, which acquires a user behavior data set uploaded by a target tea bar machine, wherein the user behavior data set includes user behavior data for the tea bar machine;
[0045] A training module, inputting the user behavior data set into a pre-trained user behavior prediction model, and identifying the user preference of the user based on the user behavior prediction model;
[0046] A judgment module, which judges whether the tea bar machine triggers a usage condition corresponding to the user preference according to the user preference and the current usage of the tea bar machine;
[0047] The execution module sends a trigger command to the tea bar machine when the tea bar machine does not trigger the use condition corresponding to the user preference, and the trigger command includes a command to control the tea bar machine to run the user preference.
[0048] A computer storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the steps of the tea bar machine control method based on big data collection described in any one of claims 1 to 7 are implemented.
[0049] Compared with the prior art, the present invention has the following advantages and beneficial effects:
[0050] The present invention establishes a stable communication connection with the target tea bar machine through a cloud platform, obtains user behavior data in real time, and identifies and analyzes the user through a preset user behavior prediction model to accurately predict the user's personalized preferences, and automatically adjusts the working status according to the current usage status of the tea bar machine, providing users with a more convenient and comfortable drinking experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] Figure 1 is a flow chart of the method of the present invention;
[0052] Figure 2 It is a schematic diagram of the structure of the device of the present invention; DETAILED DESCRIPTION
[0053] The present invention is further described in detail below in conjunction with examples, but the embodiments of the present invention are not limited thereto.
[0054] Example:
[0055] Combined with Figure 1 As shown, a tea bar machine control method based on big data collection is applied to a cloud platform, and the cloud platform is connected to the target tea bar machine in communication. The method includes:
[0056] Step S100, obtaining a user behavior data set uploaded by the target tea bar machine, wherein the user behavior data set includes user behavior data for the tea bar machine;
[0057] Specifically, the behavior data includes the collected user usage time, the usage pattern corresponding to the usage time, and the set preference data.
[0058] Step S200, inputting the user behavior data set into a pre-trained user behavior prediction model, and identifying the user preference of the user based on the user behavior prediction model;
[0059] Specifically, the user preferences include the tea bar machine's preferred usage time, the tea bar machine's preferred usage mode, and the tea bar machine's preferred data settings.
[0060] Step S300, judging whether the tea bar machine triggers the usage condition corresponding to the user preference according to the user preference and the current usage of the tea bar machine;
[0061] Step S400, when the tea bar machine does not trigger the usage condition corresponding to the user preference, a trigger command is sent to the tea bar machine, and the trigger command includes a command to control the tea bar machine to run the user preference.
[0062] Invention principle: The present application first obtains the user behavior data set uploaded by the target tea bar machine. These data sets cover various behaviors of users for the tea bar machine, including but not limited to the usage time, the usage mode corresponding to the usage time, and the preference data set by the user. For example, a user may choose the tea brewing mode at 3 pm every day and set the water temperature to 90 degrees. These data will be collected by the tea bar machine and uploaded to the cloud platform, which is an Internet-based computing platform for storing and processing user behavior data sets uploaded from the tea bar machine. Subsequently, these data sets will be input into a pre-trained user behavior prediction model. This model is built based on big data and machine learning technology, and can deeply explore the potential laws in user behavior data, so as to accurately identify user preferences. These preferences include the tea bar machine's tendency to use time (such as 3 pm), tendency to use mode (such as tea brewing mode), and tendency data settings (such as water temperature 90 degrees). After identifying the user's preferences, the method will make intelligent judgments based on these preferences and the current usage of the tea bar machine. It will check whether the tea bar machine has triggered the usage conditions corresponding to the user's preferences. Taking the previous example, if the current time is 3 pm, but the tea bar machine is not turned on and is not in tea brewing mode or the water temperature has not reached 90 degrees, then it will be determined that the tea bar machine has not triggered the usage conditions corresponding to the user preferences. Finally, when the tea bar machine does not trigger the usage conditions corresponding to the user preferences, the method sends a trigger command to the tea bar machine through the cloud platform. These commands contain specific control instructions designed to allow the tea bar machine to operate according to the user's preferences. Taking the previous example, the trigger command may cause the tea bar machine to immediately switch to tea brewing mode and adjust the water temperature to 90 degrees, thereby ensuring that the user can enjoy the ideal tea brewing experience at the desired time.
[0063] In summary, the tea bar machine control method based on big data collection realizes intelligent control of the tea bar machine through the combination of cloud platform, user behavior data set, user behavior prediction model and trigger command. This method can accurately identify the user's personalized preferences and automatically adjust the working state according to the current usage of the tea bar machine, thereby providing a more convenient and comfortable drinking experience.
[0064] As an implementation method, the training process of the user behavior prediction model includes:
[0065] Obtain a training sample library, the training sample library includes a plurality of training sample sets, the training sample sets are user behavior data sample sets, the user behavior data sample sets include sample behavior data of sample users for sample tea bar machines, wherein each of the training sample sets carries a corresponding user preference label;
[0066] Calling an initial user behavior prediction model to divide multiple training sample sets in the training sample library into multiple training batches;
[0067] Inputting the multiple training batches into the initial user behavior prediction model in sequence to obtain predicted user preferences corresponding to each training sample set;
[0068] Based on the predicted user preferences and the user preference labels corresponding to each training sample set, determining the loss value of the initial user behavior prediction model according to a preset loss function;
[0069] Adjusting the model parameters of the initial user behavior prediction model according to the loss value to obtain an adjusted initial user behavior prediction model;
[0070] Return to the step of inputting the multiple training batches into the initial user behavior prediction model in sequence, and iteratively execute the step of obtaining the predicted user preference corresponding to each training sample set until the initial user behavior prediction model reaches the preset training stop condition, terminate the training, and obtain the trained user behavior prediction model.
[0071] Specifically, first, we need to obtain a training sample library. This library contains multiple training sample sets, and each training sample set is a collection of user behavior data. These data are about how sample users interact with sample tea bar machines. Suppose we have a training sample library containing 1,000 user behavior data sample sets, each of which contains a user's behavior data when using a tea bar machine, such as usage time, usage mode, and setting preferences. Each training sample set carries a corresponding user preference label, which clearly indicates the user's actual preferences, such as when they tend to use the tea bar machine, which mode they like, and the water temperature they set. Next, an initial user behavior prediction model will be called. This model does not have prediction capabilities at the beginning and needs to be learned through training. During the training process, multiple training sample sets in the training sample library will be divided into multiple training batches. A training batch is a small batch of data into which multiple training sample sets in the training sample library are divided. This is done to make training more efficient, because processing all the data at once may be too large and complex. If the training sample library contains 1,000 training sample sets, we can divide them into 10 training batches, each containing 100 sample sets. During the training process, the model will process these 10 training batches in turn. Then, multiple training batches are input into the initial user behavior prediction model in turn. The model will analyze each training sample set and try to predict the corresponding user preferences. These prediction results will be compared with the actual user preference labels. Based on the comparison results, the loss value of the initial user behavior prediction model will be determined according to a preset loss function. The preset loss function is as follows:
[0072]
[0073] Where: Y represents the true label, yic is a one-hot encoding vector, indicating whether sample i belongs to category c;
[0074] F(x) represents the predicted probability distribution of the model, pic is the predicted probability that sample i belongs to category c;
[0075] K is the total number of categories;
[0076] N is the total number of samples;
[0077] The loss value is an indicator of the prediction accuracy of the model, which represents the difference between the model prediction result and the actual result. If the loss value is high, it means that the prediction accuracy of the model is very low and needs to be adjusted. Therefore, the model parameters of the initial user behavior prediction model are adjusted according to the loss value. These parameters are mathematical variables used for calculation and prediction inside the model. By adjusting these parameters, the prediction accuracy of the model can be improved. After completing a round of parameter adjustment, it will return to the step of inputting multiple training batches into the model in sequence and obtaining the predicted user preferences corresponding to each training sample set. This process will be iteratively executed, which means that it will be repeated many times until the initial user behavior prediction model reaches the preset training stop condition. These conditions may be that the model prediction accuracy reaches a certain threshold, or the number of iterations reaches an upper limit, etc. For example, the training stop condition can be that the model prediction accuracy reaches more than 95%, or the number of iterations reaches 1000 times. Finally, when the training meets the stop condition, the training process ends and a trained user behavior prediction model is obtained. This model has learned how to accurately predict user preferences based on user behavior data and can be used in actual tea bar machine control.
[0078] For example, suppose there is a training sample set that contains the behavior data of a user who uses the tea brewing mode at 3 pm every day and sets the water temperature to 90 degrees. The user preference label carried by this sample set is "use the tea brewing mode at 3 pm, water temperature 90 degrees". During the training process, the initial user behavior prediction model will try to predict the user's preference and compare it with the actual label. Through multiple iterations and adjustment of model parameters, the final trained user behavior prediction model can accurately predict the user's preference and apply this preference in the actual tea bar machine control to provide personalized services.
[0079] As an implementation method, in combination with the attached Figure 2 As shown, the initial user behavior prediction model includes an input module, a feature extraction module, a time prediction model, a pattern prediction model, and a numerical prediction model; the multiple training batches are sequentially input into the initial user behavior prediction model to obtain the predicted user preference corresponding to each training sample set, including:
[0080] Inputting the plurality of training batches into the feature extraction module in sequence through the input module;
[0081] Perform feature extraction based on the feature extraction module to obtain time series features, usage mode features and water boiling temperature features;
[0082] Inputting the time series features into the time prediction model module to obtain the prediction result of the tendency usage time of the tea bar machine;
[0083] Inputting the time series features and the usage pattern features into the pattern prediction model to obtain a prediction result of the tendency usage pattern of the tea bar machine;
[0084] Inputting the time series characteristics, the usage pattern characteristics and the water boiling temperature characteristics into the numerical prediction model to obtain the tendency setting data prediction result of the tea bar machine;
[0085] The tendency usage time prediction result, the tendency usage mode prediction result and the tendency setting data prediction result constitute the predicted user preference.
[0086] Specifically, the initial user behavior prediction model consists of multiple modules, including an input module, a feature extraction module, a time prediction model, a pattern prediction model, and a numerical prediction model. When multiple training batches are sequentially input into this model, they first enter the feature extraction module through the input module, and the input module receives the data in the training sample batch. This data is detailed information about how users use the tea bar machine, including when it is used, which mode is used, and the set water temperature.
[0087] In the feature extraction module, the model conducts an in-depth analysis of the input training sample set and extracts key feature information from it. These feature information include water boiling temperature features, time series features, and usage pattern features, which can represent the user's behavior patterns. The water boiling temperature feature reflects the water temperature that users tend to set when using the tea bar machine, the time series feature reveals the time pattern of users using the tea bar machine, and the usage pattern feature shows the user's preferred usage mode of the tea bar machine, such as brewing tea, keeping warm, etc.
[0088] After extracting these features, they will be input into the numerical prediction model, pattern prediction model and time prediction model respectively to obtain the prediction results about user behavior. In the time prediction model, the model mainly predicts the user's preferred tea bar machine usage time based on the time series features, for example, the user may be accustomed to using the tea bar machine at 3 pm every day. Next, in the pattern prediction model module, the model will predict the user's preferred tea bar machine usage mode based on the time series features and usage pattern features, for example, the user may prefer to use the tea brewing mode in the afternoon, and in the numerical prediction model module, the model will use all the extracted features (time series features, usage pattern features and water boiling temperature features) to predict the user's preferred tea bar machine data settings, for example, the user may tend to set the water temperature to 90 degrees.
[0089] The results of these three prediction models (prediction of intended usage time, intended usage pattern, and intended setting data) together constitute our prediction of user preferences. These prediction results can help us better understand user needs and behavior patterns, so as to provide them with more personalized services and product recommendations.
[0090] For example, suppose there is a user's behavior data sample set showing that the user has used the tea-making mode at 4 p.m. every day in the past week and set the water temperature to 85 degrees. When this sample set is input into the initial user behavior prediction model, the feature extraction module extracts the boiling water temperature feature (85 degrees), time series feature (4 p.m.), and usage pattern feature (tea-making mode). These features are then input into the three prediction model modules respectively. The numerical prediction model module may predict that the user's preferred tea bar machine data setting is 85 degrees, the pattern prediction model module may predict that the user's preferred tea bar machine usage mode is the tea-making mode, and the time prediction model module may predict that the user's preferred tea bar machine usage time is 4 p.m. Finally, the output module integrates these prediction results to give a complete predicted user preference.
[0091] As an implementation method, in combination with the attached Figure 2 As shown, the feature extraction module includes: a user preprocessing submodule, which is used to preprocess the training sample sets in the input multiple training batches;
[0092] A time series feature extraction submodule, used to extract time series features of the time series data in the training sample set;
[0093] A usage pattern feature extraction submodule, used to extract usage pattern features of usage pattern data in the training sample set;
[0094] The water boiling temperature feature extraction submodule is used to extract the water boiling temperature features of the water boiling temperature data in the training sample set.
[0095] Specifically, the feature extraction module includes a user preprocessing submodule, which mainly preprocesses the input data, including data cleaning, denoising, missing value processing, and format conversion to ensure the accuracy and consistency of the data, so as to facilitate subsequent feature extraction and model training. Data cleaning refers to removing erroneous, duplicated, or inconsistent records in the data to ensure the accuracy of the data; denoising refers to eliminating random errors or outliers in the data, which may interfere with subsequent feature extraction and model prediction; missing value processing is to check whether the data in the training sample set is complete, whether there are missing timestamps or temperature values, and perform corresponding processing; format conversion is to convert the data into a format suitable for subsequent processing, such as converting text data into numerical data. For example, if the user behavior data contains some invalid records or obviously wrong values, the user preprocessing submodule will delete or correct these records or values to ensure the accuracy and consistency of the data.
[0096] The time series feature extraction submodule is specifically used to extract time series features from the time series data in the training sample set. Time series data refers to data arranged in chronological order, which contains information about how user behavior changes over time. The time series feature extraction submodule will analyze this data and extract the temporal patterns of user behavior. For example, the time series feature extraction submodule may extract features such as the number of uses per day, the frequency of use per week, and the duration of use from the user's tea bar machine usage records. These features can reflect the user's usage habits in different time periods. For example, if the user has used the tea bar machine at 4 pm every day in the past week, the time series feature extraction submodule will extract this time period as an important feature of the user's behavior.
[0097] The usage pattern feature extraction submodule is responsible for extracting usage pattern features from the usage pattern data in the training sample set. The usage pattern data here refers to the different modes selected by the user when using the tea bar machine, such as tea brewing mode, insulation mode, etc. Each mode corresponds to the user's different usage preferences. The usage pattern feature extraction submodule analyzes the user's behavior data in different modes and extracts features such as the user's preferred usage mode and the frequency of mode switching. For example, if the user has frequently used the tea brewing mode in the past and has set a specific water temperature and time in this mode, the usage pattern feature extraction submodule will extract the tea brewing mode as an important preference feature of the user.
[0098] The water boiling temperature feature extraction submodule is responsible for extracting water boiling temperature features from the water boiling temperature data in the training sample set. Water boiling temperature is an important setting item of the tea bar machine, and different users may prefer different water temperatures. The water boiling temperature feature extraction submodule analyzes the user's past water boiling temperature setting data and extracts features such as the user's preferred water temperature range, specific temperature value, or temperature adjustment frequency. For example, if the user usually set the water temperature of the tea bar machine to 90 degrees in the past, the water boiling temperature feature extraction submodule will extract 90 degrees as an important preference feature of the user.
[0099] In summary, the various submodules of the feature extraction module work together to extract feature information that is useful for the prediction model from the original user behavior data. This information will be used in subsequent model training and prediction processes to help the model more accurately predict user preferences and behaviors.
[0100] As an implementation method, in combination with the attached Figure 2 As shown, the time prediction model includes a time series feature extraction module and a time preference prediction module, the pattern prediction model includes a pattern classifier, and the numerical prediction model includes a regression analysis module; the time series feature is input into the time prediction model to obtain the tea bar machine's tendency to use time prediction result, including:
[0101] Input the time series features into the time series feature extraction module to obtain periodic features, trend features and seasonal features, and obtain the prediction result of the tea bar machine's tendency to use time based on the periodic features, trend features and seasonal features through the time preference prediction module;
[0102] The step of inputting the time series features and the usage pattern features into the pattern prediction model to obtain the prediction result of the tendency usage pattern of the tea bar machine includes:
[0103] Inputting the time series features and the usage pattern features into the pattern classifier, and combining the tendency usage time prediction results, to obtain the tendency usage pattern prediction results of the tea bar machine;
[0104] The step of inputting the water boiling temperature feature, the time series feature and the usage mode feature into the numerical prediction model to obtain the prediction result of the tendency setting data of the tea bar machine includes:
[0105] The water boiling temperature characteristics, time series characteristics and usage pattern characteristics are input into the regression analysis module, and the tendency usage time prediction results and the tendency usage pattern prediction results are combined to obtain the tendency setting data prediction results of the tea bar machine.
[0106] Specifically, the time prediction model includes a time series feature extraction module and a time preference prediction module. The time series feature extraction module is responsible for extracting periodic features, trend features, and seasonal features from the input time series features. These features reflect the repetitive patterns of the tea bar machine usage time, long-term trends, and seasonal usage habits. For example, if the user has used the tea bar machine at 3 pm every day in the past week, the time series feature extraction module can identify this daily periodic usage pattern. After extracting these features, the time preference prediction module will predict the tea bar machine's preferred usage time based on them. It predicts the user's preferred usage time based on the input time series features. The specific time prediction algorithm is as follows:
[0107]
[0108] Among them, F t is the predicted value at the next time point t; A t-1 , A t-2 , ..., A t-n is the actual observation value at the past n time points; n is the number of periods of the moving average.
[0109] For example, based on the user's past usage behavior, the time preference prediction module may predict that the user will use the tea bar machine around 3 pm every day in the next week.
[0110] The pattern prediction model is responsible for predicting the tea bar machine's usage pattern. The pattern prediction model mainly includes a pattern classifier, which is responsible for implementing a logistic regression classification algorithm. It receives time series features and usage pattern features, and classifies and predicts the user's tea bar machine usage pattern. The specific logistic regression classification algorithm is as follows:
[0111]
[0112] Where P(Y=1|X) represents the probability that the output variable Y is 1 given the input feature X; β0, β1, …, β p are the model parameters learned through training data; X1, X2, ..., X p are the input time series features and usage pattern features.
[0113] For example, if a user frequently uses the tea-making mode in the past period of time, and this usage pattern has a certain time regularity, the pattern classifier can identify this pattern and predict that the user will tend to use the tea-making mode in a similar time period in the future.
[0114] The numerical prediction model is responsible for predicting the tea bar machine's preferred setting data. The numerical prediction model includes a regression analysis module. The regression analysis module is responsible for implementing linear regression and nonlinear regression algorithms. It receives the characteristics of boiling water temperature, time series characteristics, and usage pattern characteristics, and predicts the user's preferred tea bar machine temperature. The specific linear regression formula and nonlinear regression formula are as follows:
[0115] Linear regression formula: Y = β0 + β1X1 + β2X2 + … + β p X p +∈
[0116] Where Y is the dependent variable (such as the temperature preferred by the user); X1, X2, …, X p is the independent variable (such as water boiling temperature characteristics, time series characteristics, etc.); β0, β1, …, β p is the regression coefficient; ∈ is the error term.
[0117] Nonlinear regression formula: Y = β0 + β1X + β2X2 + ... + β p X p +∈
[0118] Here, it is similar to linear regression, but the independent variable X is expanded to its polynomial form.
[0119] For example, if the user usually sets the water temperature of the tea bar machine to 90 degrees in the past, the regression analysis module can predict that the user will tend to set the water temperature to 90 degrees in the future.
[0120] As an implementation manner, the user preference label includes a tendency usage time label, a tendency usage mode label, and the tendency setting data label; the loss value of the initial user behavior prediction model is determined according to a preset loss function based on the predicted user preference corresponding to each training sample set and the user preference label, including:
[0121] Obtaining a tendency usage time loss based on the tendency usage time label and the tendency usage time prediction result;
[0122] Obtaining a tendency usage pattern loss based on the tendency usage pattern label and the tendency usage pattern prediction result;
[0123] Obtaining a tendency setting data loss based on the tendency setting data label and the tendency setting data prediction result;
[0124] The tendency usage time loss, the tendency usage pattern loss, and the tendency setting data loss are integrated to obtain a total loss, and the total loss is determined as the loss value of the initial user behavior prediction model.
[0125] Specifically, in the process of building a user behavior prediction model, we will train the model so that it can accurately predict user preferences. Among them, "user preference labels" are an important basis for us to measure the accuracy of model predictions. They include labels for preferred usage time, preferred usage pattern, and preferred setting data. These labels represent the user's preferred usage time, preferred usage pattern, and preferred setting data when using the tea bar machine.
[0126] In order to determine the loss value of the initial user behavior prediction model, we will calculate the loss value based on the predicted user preferences and user preference labels corresponding to each training sample set according to the preset loss function. Specifically, we will calculate the loss of the intended use time, the intended use mode, and the intended setting data respectively, and then combine these three losses to obtain the total loss, and determine the total loss as the loss value of the initial user behavior prediction model.
[0127] The tendency usage time loss refers to the loss caused by the difference between the tendency usage time predicted by the model and the actual tendency usage time of the user. It is calculated based on the tendency usage time label and the tendency usage time prediction result. For example, if a user's tendency usage time label is 3 pm to 5 pm, but the model predicts the tendency usage time to be between 2 pm and 4 pm, there will be a time difference, which is the tendency usage time loss. By calculating the tendency usage time loss of all training samples, we can get an overall tendency usage time loss value. The specific formula is as follows:
[0128]
[0129] Among them, y i is the actual time, is the prediction time and n is the number of samples.
[0130] Similarly, the tendency usage pattern loss refers to the loss caused by the difference between the tendency usage pattern predicted by the model and the user's actual tendency usage pattern, and is calculated based on the tendency usage pattern label and the tendency usage pattern prediction result. For example, if a user's tendency usage pattern label is "tea brewing mode", but the tendency usage pattern predicted by the model is "keeping warm mode", then there will be a difference in pattern, and this difference is the tendency usage pattern loss.
[0131] The tendency setting data loss refers to the loss caused by the difference between the tendency setting data predicted by the model and the user's actual tendency setting data, which is calculated based on the tendency setting data label and the tendency setting data prediction result. For example, if a user's tendency setting data label is that the water boiling temperature is 90 degrees, but the tendency setting data predicted by the model is 85 degrees, then there will be a temperature difference, which is the tendency setting data loss.
[0132] Finally, we merge the loss of the intended use time, the intended use mode, and the intended setting data to obtain a total loss value. This total loss value represents the overall prediction error of the initial user behavior prediction model on the training sample set. By continuously optimizing the model parameters, we can reduce the total loss value and thus improve the prediction accuracy of the model.
[0133] As an implementation mode, it also includes: when the tea bar machine triggers the usage condition corresponding to the user preference, automatically controlling the tea bar machine to run the user preference.
[0134] Specifically, the "tea bar machine" here is an intelligent device that integrates multiple beverage making functions. It can automatically complete operations such as brewing tea and coffee according to the user's instructions or preset programs. "User preferences" refers to some personalized settings set by the user when using the tea bar machine, such as the type of tea they like, the water temperature for brewing tea, the time for brewing tea, etc. Once these preferences are set, the tea bar machine will remember them and try to meet these personalized needs of the user in subsequent use. "Triggering the usage conditions corresponding to the user preferences" means that when the tea bar machine detects certain specific conditions or situations, it will automatically call the preference settings previously set by the user. For example, if the user sets "automatically brew a cup of Longjing tea at 8 o'clock every morning", then when the time of the tea bar machine reaches 8 o'clock in the morning, this "usage condition" is triggered. Finally, "automatically controlling the tea bar machine to run the user preferences" means that after detecting that the usage conditions are triggered, the tea bar machine will automatically run according to the preferences previously set by the user. In other words, it will automatically start brewing tea, using the type of tea, water temperature and brewing time specified by the user, and finally brew a cup of tea that suits the user's taste.
[0135] As another embodiment of the present application, Figure 2 As shown, a tea bar machine control device based on big data collection includes:
[0136] An acquisition module, which acquires a user behavior data set uploaded by a target tea bar machine, wherein the user behavior data set includes user behavior data for the tea bar machine;
[0137] A training module, inputting the user behavior data set into a pre-trained user behavior prediction model, and identifying the user preference of the user based on the user behavior prediction model;
[0138] A judgment module, which judges whether the tea bar machine triggers a usage condition corresponding to the user preference according to the user preference and the current usage of the tea bar machine;
[0139] The execution module sends a trigger command to the tea bar machine when the tea bar machine does not trigger the use condition corresponding to the user preference, and the trigger command includes a command to control the tea bar machine to run the user preference.
[0140] As another embodiment of the present application, a computer storage medium stores a computer program thereon, and when the computer program is executed by a processor, the steps of the tea bar machine control method based on big data collection described in the present application are implemented.
[0141] Although the present invention is described herein with reference to the illustrative embodiments of the present invention, the above embodiments are only preferred embodiments of the present invention, and the embodiments of the present invention are not limited to the above embodiments. It should be understood that those skilled in the art can design many other modifications and embodiments, which will fall within the scope and spirit of the principles disclosed in this application.
Claims
1. A tea bar machine control method based on big data collection, characterized in that: Applied to a cloud platform, the cloud platform is communicatively connected with a target tea bar machine, the method comprises: Obtaining a user behavior data set uploaded by the target tea bar machine, wherein the user behavior data set includes user behavior data for the tea bar machine; Inputting the user behavior data set into a pre-trained user behavior prediction model, and identifying the user preference of the user based on the user behavior prediction model; According to the user preference and the current usage of the tea bar machine, determining whether the tea bar machine triggers the usage condition corresponding to the user preference; When the tea bar machine does not trigger the use condition corresponding to the user preference, a trigger command is sent to the tea bar machine, and the trigger command includes a command to control the tea bar machine to run the user preference.
2. A tea bar machine control method based on big data collection according to claim 1, characterized in that: The training process of the user behavior prediction model includes: Obtain a training sample library, the training sample library includes a plurality of training sample sets, the training sample sets are user behavior data sample sets, the user behavior data sample sets include sample behavior data of sample users for sample tea bar machines, wherein each of the training sample sets carries a corresponding user preference label; Calling an initial user behavior prediction model to divide multiple training sample sets in the training sample library into multiple training batches; Inputting the multiple training batches into the initial user behavior prediction model in sequence to obtain predicted user preferences corresponding to each training sample set; Based on the predicted user preferences and the user preference labels corresponding to each training sample set, determining the loss value of the initial user behavior prediction model according to a preset loss function; Adjusting the model parameters of the initial user behavior prediction model according to the loss value to obtain an adjusted initial user behavior prediction model; Return to the step of inputting the multiple training batches into the initial user behavior prediction model in sequence, and iteratively execute the step of obtaining the predicted user preference corresponding to each training sample set until the initial user behavior prediction model reaches the preset training stop condition, terminate the training, and obtain the trained user behavior prediction model.
3. A tea bar machine control method based on big data collection according to claim 2, characterized in that: The initial user behavior prediction model includes an input module, a feature extraction module, a time prediction model, a pattern prediction model, and a numerical prediction model; the multiple training batches are sequentially input into the initial user behavior prediction model to obtain the predicted user preference corresponding to each training sample set, including: Inputting the plurality of training batches into the feature extraction module in sequence through the input module; Perform feature extraction based on the feature extraction module to obtain time series features, usage mode features and water boiling temperature features; Inputting the time series features into the time prediction model module to obtain the prediction result of the tendency usage time of the tea bar machine; Inputting the time series features and the usage pattern features into the pattern prediction model to obtain a prediction result of the tendency usage pattern of the tea bar machine; Inputting the time series characteristics, the usage pattern characteristics and the water boiling temperature characteristics into the numerical prediction model to obtain the tendency setting data prediction result of the tea bar machine; The tendency usage time prediction result, the tendency usage mode prediction result and the tendency setting data prediction result constitute the predicted user preference.
4. A tea bar machine control method based on big data collection according to claim 3, characterized in that: The feature extraction module comprises: A user preprocessing submodule, used for preprocessing the training sample sets in the input multiple training batches; A time series feature extraction submodule, used to extract time series features of the time series data in the training sample set; A usage pattern feature extraction submodule, used to extract usage pattern features of usage pattern data in the training sample set; The water boiling temperature feature extraction submodule is used to extract the water boiling temperature features of the water boiling temperature data in the training sample set.
5. A tea bar machine control method based on big data collection according to claim 3, characterized in that: The time prediction model includes a time series feature extraction module and a time preference prediction module, the pattern prediction model includes, and the numerical prediction model includes a regression analysis module; the time series feature is input into the time prediction model to obtain the tea bar machine's tendency to use time prediction result, including: Input the time series features into the time series feature extraction module to obtain periodic features, trend features and seasonal features, and obtain the prediction result of the tea bar machine's tendency to use time based on the periodic features, trend features and seasonal features through the time preference prediction module; The step of inputting the time series features and the usage pattern features into the pattern prediction model to obtain the prediction result of the tendency usage pattern of the tea bar machine includes: Inputting the time series features and the usage pattern features into the pattern classifier, and combining the tendency usage time prediction results, to obtain the tendency usage pattern prediction results of the tea bar machine; The step of inputting the water boiling temperature feature, the time series feature and the usage mode feature into the numerical prediction model to obtain the prediction result of the tendency setting data of the tea bar machine includes: The water boiling temperature characteristics, time series characteristics and usage pattern characteristics are input into the regression analysis module, and the tendency usage time prediction results and the tendency usage pattern prediction results are combined to obtain the tendency setting data prediction results of the tea bar machine.
6. A tea bar machine control method based on big data collection according to claim 3, characterized in that: The user preference label includes a tendency usage time label, a tendency usage mode label, and the tendency setting data label; the loss value of the initial user behavior prediction model is determined according to a preset loss function based on the predicted user preference corresponding to each training sample set and the user preference label, including: Obtaining a tendency usage time loss based on the tendency usage time label and the tendency usage time prediction result; Obtaining a tendency usage pattern loss based on the tendency usage pattern label and the tendency usage pattern prediction result; Obtaining a tendency setting data loss based on the tendency setting data label and the tendency setting data prediction result; The tendency usage time loss, the tendency usage pattern loss, and the tendency setting data loss are integrated to obtain a total loss, and the total loss is determined as the loss value of the initial user behavior prediction model.
7. A tea bar machine control method based on big data collection according to claim 1, characterized in that: Also includes: When the tea bar machine triggers the usage condition corresponding to the user preference, the tea bar machine is automatically controlled to run the user preference.
8. A tea bar machine control device based on big data collection, characterized in that: include: An acquisition module, which acquires a user behavior data set uploaded by a target tea bar machine, wherein the user behavior data set includes user behavior data for the tea bar machine; A training module, inputting the user behavior data set into a pre-trained user behavior prediction model, and identifying the user preference of the user based on the user behavior prediction model; A judgment module, which judges whether the tea bar machine triggers a usage condition corresponding to the user preference according to the user preference and the current usage of the tea bar machine; The execution module sends a trigger command to the tea bar machine when the tea bar machine does not trigger the usage condition corresponding to the user preference, and the trigger command includes a command to control the tea bar machine to run the user preference.
9. A computer storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by the processor, the steps of the tea bar machine control method based on big data collection described in any one of claims 1-7 are implemented.
