Power retail package recommendation method and system
By using smart meters and data processing technology, user electricity consumption sample data is constructed and a package recommendation model is trained, which solves the problem of insufficient accuracy in traditional electricity package recommendations and achieves accurate recommendations and improved user experience.
Patent Information
- Application Number
- CN202511633109.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-10
- Publication Date
- 2026-02-13
AI Technical Summary
Traditional electricity package recommendation methods rely on human experience or simple rule matching, resulting in insufficient recommendation accuracy and a poor user experience.
Historical electricity consumption data of users is obtained through smart meters or power data acquisition terminals. Noise and outlier processing are performed to construct user electricity consumption sample data. Combined with user attribute data, a package recommendation model is trained, and accurate recommendations are made using real-time electricity consumption data and user attribute data.
It enables precise electricity package recommendations, improves user experience, optimizes electricity costs, enhances the company's market competitiveness and user loyalty, and promotes the data-driven intelligent transformation of electricity retail services.
Smart Images

Figure CN121526731A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of electricity retail technology, and in particular to a method and system for recommending electricity retail packages. Background Technology
[0002] With the advancement of smart grid construction and the deepening of electricity market reform, competition in the electricity retail market is becoming increasingly fierce, and users' demand for personalized and economical electricity packages is becoming more and more significant. Traditional electricity package recommendation methods mostly rely on manual experience or simple rule matching, which makes it difficult to effectively integrate multi-dimensional data such as user electricity consumption behavior, load characteristics, and consumption habits, resulting in insufficient recommendation accuracy and a poor user experience.
[0003] The above content is only used to help understand the technical solution of the present invention and does not represent an admission that the above content is prior art. Summary of the Invention
[0004] The main objective of this invention is to provide a method and system for recommending electricity retail packages, aiming to solve the technical problem that traditional electricity package recommendation methods rely heavily on manual experience or simple rule matching, resulting in insufficient recommendation accuracy and poor user experience.
[0005] To achieve the above objectives, the present invention provides a method for recommending electricity retail packages, the method comprising: Historical electricity consumption data of users is obtained through smart meters or power data acquisition terminals. Noise removal and outlier processing are performed on the historical electricity consumption data to construct user electricity consumption sample data. Obtain user attribute data and electricity retail package attribute data, and add user electricity consumption feature tags to the user electricity consumption sample data; The package recommendation model is trained using the electricity consumption sample data and user electricity consumption feature tags. The system acquires real-time electricity consumption data and user attribute data of the current user and uses them as input data for the package recommendation model. The model then outputs recommendation scores for each electricity retail package and pushes the electricity retail package with the highest recommendation score to the user terminal.
[0006] Optionally, the step of denoising and outlier processing the historical electricity consumption data to construct user electricity consumption sample data includes: The historical electricity consumption data is converted into an electricity consumption embedding matrix according to the time series. The electricity consumption embedding matrix is decomposed into an electricity consumption matrix. The electricity consumption matrix with singular values greater than 0 is used to form an electricity consumption component matrix. The electricity consumption component matrix is converted into an electricity consumption time series by diagonal averaging. The electricity consumption time series is transformed to the frequency domain to obtain electricity consumption spectrum data. The electricity consumption spectrum data is divided to obtain continuous intervals of peak, flat and valley electricity consumption. Within the continuous intervals, an electricity consumption scaling function is constructed to obtain electricity consumption detail coefficients and electricity consumption approximation coefficients. The signal is reconstructed based on the electricity consumption detail coefficients and electricity consumption approximation coefficients to obtain electricity consumption components. Calculate the correlation coefficient of the electricity consumption components, and merge the electricity consumption components with the correlation coefficient greater than a preset coefficient threshold into user electricity consumption sample data, wherein the correlation coefficient is the Pearson correlation coefficient between the electricity consumption components.
[0007] Optionally, the calculation formula for obtaining the power consumption component from the reconstructed signal based on the power consumption detail coefficients and the power consumption approximation coefficients is as follows:
[0008] in, For electrical components, For electricity consumption detail factors, Let F be the approximation coefficient for electricity consumption, F be the Fourier transform, A be the electricity consumption scale function, τ be the time length of the continuous interval, j be the component count, and M be the number of electricity consumption component categories.
[0009] Optionally, the step of obtaining user attribute data and electricity retail package attribute data, and adding user electricity consumption feature tags to the user electricity consumption sample data, includes: Obtain user attribute data and electricity retail package attribute data; add user electricity consumption feature tags to the user electricity consumption sample data based on the user attribute data; and define peak-valley electricity consumption difference rate.
[0010] in, Peak-valley electricity consumption differential rate Peak electricity consumption Electricity consumption during off-peak hours Electricity consumption for the flat section; If the peak-valley electricity consumption difference rate is greater than the first preset peak-valley electricity consumption difference rate, then the user electricity consumption feature tag is set to -1; if the peak-valley electricity consumption difference rate is greater than or equal to the second preset peak-valley electricity consumption difference rate and less than or equal to the first preset peak-valley electricity consumption difference rate, then the user electricity consumption feature tag is set to 0; if the peak-valley electricity consumption difference rate is less than the second preset peak-valley electricity consumption difference rate, then the user electricity consumption feature tag is set to 1; wherein, the first preset peak-valley electricity consumption difference rate is greater than the second preset peak-valley electricity consumption difference rate; The user electricity consumption feature tags are added to the electricity consumption sample data; the user attribute data includes user type, total power of electrical equipment, average electricity consumption duration, and peak-valley electricity consumption ratio; the electricity retail package attribute data includes package type, benchmark electricity price, peak-valley time period division, and discount rate.
[0011] Optionally, training the package recommendation model using the electricity consumption sample data and user electricity consumption feature labels includes: The electricity consumption sample data and user electricity consumption feature labels are input into a deep collaborative filtering network. In the deep collaborative filtering network, the user ID and package ID are mapped into low-dimensional dense vectors through an embedding layer. The nonlinear features of the input data are extracted by a multilayer perceptron to obtain feature mapping. The feature mapping is then dimensionality-reduced to obtain a user-package feature mapping set. Establish a package recommendation model, and initialize the weight matrix and bias vector of the package recommendation model to obtain the initial parameter vector and prediction score vector; Based on the user-package feature mapping set, a parameter vector is obtained. If the loss function value corresponding to the parameter vector in the next iteration is less than or equal to the preset loss function value, then the parameter vector is used as the update parameter vector; if the loss function value is less than or equal to the preset loss function value, then the initial parameter vector is used as the update parameter vector. Calculate the prediction error value of the parameter vector, where the prediction error value is the difference between the predicted score and the actual score. If the prediction error value is greater than a preset error value, then update the parameter vector at the next time step based on the initial parameter vector. The model parameters corresponding to the parameter vectors after iteration are used to construct a model parameter set, which is used to characterize the package recommendation model.
[0012] Optionally, the step of extracting nonlinear features from the input data using a multilayer perceptron to obtain a feature map includes: The number of neurons in the hidden layer of the multilayer perceptron is set according to the input data. The nonlinear interactive features of the input data are extracted using an activation function to obtain the feature map. The calculation formula is as follows:
[0013] in, The size of the feature mapping matrix, For the input data dimensions, This represents the number of neurons in the hidden layer. Step size, The number of hidden layers. Let g be the m-th feature map, and g be the activation function. Let m be the weight matrix of the m-th eigenmap. For input data, This is the bias vector.
[0014] Optionally, after obtaining the current user's real-time electricity consumption data and user attribute data as input data for the package recommendation model, outputting the recommendation score of each electricity retail package through the package recommendation model, and pushing the electricity retail package with the highest recommendation score as the recommendation result to the user terminal, the method further includes: Obtain user needs and preferences, and establish a package matching degree model based on user needs and preferences. The calculation formula for the package matching degree model is as follows: ; in, For the overall suitability of the package, , , These are the weighting coefficients. + + =1, Estimate the monthly electricity cost for the package. To ensure the compatibility between users' electricity consumption habits and the electricity pricing structure of the packages, Rate the flexibility of the package; The optimal electricity retail package is determined based on the overall matching degree of the package and the recommendation score of each electricity retail package, and the optimal electricity retail package is pushed to the user terminal as a recommendation result.
[0015] Furthermore, to achieve the above objectives, the present invention also provides an electricity retail package recommendation system, the electricity retail package recommendation system comprising: The data processing module is used to acquire users' historical electricity consumption data through smart meters or power data acquisition terminals, perform noise reduction and outlier processing on the historical electricity consumption data, and construct user electricity consumption sample data. The feature annotation module is used to acquire user attribute data and electricity retail package attribute data, and add user electricity consumption feature tags to the user electricity consumption sample data. The model training module is used to train a package recommendation model using the electricity consumption sample data and user electricity consumption feature labels; The recommendation generation module is used to obtain the current user's real-time electricity consumption data and user attribute data as input data for the package recommendation model. The package recommendation model outputs the recommendation score of each electricity retail package, and pushes the electricity retail package with the highest recommendation score as the recommendation result to the user terminal.
[0016] Furthermore, to achieve the above objectives, the present invention also provides an electricity retail package recommendation device, the electricity retail package recommendation device comprising: a memory, a processor, and an electricity retail package recommendation program stored on the memory and executable on the processor, the electricity retail package recommendation program being configured to implement the steps of the electricity retail package recommendation method as described above.
[0017] In addition, to achieve the above objectives, the present invention also provides a storage medium storing an electricity retail package recommendation program, which, when executed by a processor, implements the steps of the electricity retail package recommendation method as described above.
[0018] This invention provides a method for recommending electricity retail packages. The method collects and cleans historical electricity consumption data using intelligent devices to ensure data reliability. It combines user attributes and package attributes with multi-dimensional feature annotation to deeply characterize user electricity consumption behavior, load characteristics, and consumption habits, laying a data foundation for accurate recommendations. Based on the annotated sample data, a recommendation model is trained to uncover potential correlations between user needs and package characteristics, overcoming the limitations of traditional manual rule matching. This model supports dynamic learning of changes in user electricity consumption patterns, enhancing its adaptability. By inputting real-time electricity consumption data and user attribute data into the model, a quantitative recommendation score is quickly output, achieving automated and real-time package matching, shortening the recommendation cycle, reducing manual intervention costs, and significantly improving service efficiency. For users, this provides access to cost-effective packages tailored to their electricity consumption habits, optimizing electricity costs. For businesses, accurate recommendations enhance user stickiness and market competitiveness, while simultaneously driving the transformation of electricity retail services towards data-driven intelligence, facilitating resource optimization and service model innovation. Attached Figure Description
[0019] Figure 1 This is a schematic diagram of the recommended equipment structure for the power retail package in the hardware operating environment involved in the embodiments of the present invention; Figure 2 This is a flowchart illustrating an embodiment of the electricity retail package recommendation method of the present invention; Figure 3 This is a structural block diagram of an embodiment of the electricity retail package recommendation system of the present invention.
[0020] The realization of the objective, functional features and advantages of the present invention will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation
[0021] It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
[0022] Reference Figure 1 , Figure 1 This is a schematic diagram of the structure of the recommended power retail package equipment in the hardware operating environment of the embodiment of the present invention.
[0023] like Figure 1As shown, the recommended equipment for this electricity retail package may include: a processor 1001, such as a central processing unit (CPU), a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. The communication bus 1002 is used to enable communication between these components. The user interface 1003 may include a display screen, and optionally, it may also include a standard wired interface or a wireless interface. In this invention, the wired interface of the user interface 1003 may be a USB interface. The network interface 1004 may optionally include a standard wired interface or a wireless interface (such as a Wi-Fi interface). The memory 1005 may be a high-speed random access memory (RAM) or a non-volatile memory (NVM), such as a disk storage device. The memory 1005 may also optionally be a storage device independent of the aforementioned processor 1001.
[0024] Those skilled in the art will understand that Figure 1 The structure shown does not constitute a limitation on the recommended equipment for electricity retail packages and may include more or fewer components than shown, or combine certain components, or have different component arrangements.
[0025] like Figure 1 As shown, the memory 1005, which serves as a computer storage medium, may include an operating system, a network communication module, a user interface module, and an electricity retail package recommendation program.
[0026] exist Figure 1 In the electricity retail package recommendation device shown, the network interface 1004 is mainly used to connect to the backend server and communicate with the backend server; the user interface 1003 is mainly used to connect to peripheral devices; the electricity retail package recommendation device calls the electricity retail package recommendation program stored in the memory 1005 through the processor 1001 and executes the electricity retail package recommendation method provided in this embodiment of the invention.
[0027] Based on the above hardware structure, an embodiment of the electricity retail package recommendation method of the present invention is proposed.
[0028] Reference Figure 2 , Figure 2 This is a flowchart illustrating an embodiment of the electricity retail package recommendation method of the present invention, which presents an embodiment of the electricity retail package recommendation method of the present invention.
[0029] In one embodiment, the method for recommending electricity retail packages includes the following steps: Step S100: Obtain the user's historical electricity consumption data through a smart meter or power data acquisition terminal, perform noise reduction and outlier processing on the historical electricity consumption data, and construct user electricity consumption sample data.
[0030] The smart meter can be an intelligent metering device used to collect user electricity consumption information in real time, enabling continuous monitoring and data collection of user electricity consumption behavior. In this embodiment, the smart meter can periodically collect electrical quantities such as voltage, current, and power through built-in sensors and communication modules, and upload the data to a data platform. Furthermore, the smart meter can include, but is not limited to, one or more of single-phase smart meters, three-phase smart meters, and carrier communication meters. The power data acquisition terminal can be a data acquisition device deployed on the user side or in the distribution network, used to aggregate and transmit electricity consumption data, and can be used to expand the data acquisition range, supporting multi-point and multi-type data access. For example, the power data acquisition terminal can access multiple data sources through wired or wireless communication and execute timed or triggered data acquisition tasks. Furthermore, the power data acquisition terminal can include, but is not limited to, one or more of concentrators, collectors, and remote terminal units (RTUs).
[0031] Historical electricity consumption data can be a user's electricity consumption records over a past period, including time-series electricity consumption, load curves, and other information, which can be used to reflect the user's long-term electricity consumption patterns and load characteristics. In an exemplary embodiment, historical electricity consumption data is periodically collected by smart meters or power data acquisition terminals and stored in a database. Furthermore, historical electricity consumption data can include, but is not limited to, one or more of daily electricity consumption data, hourly load data, and time-of-use electricity consumption records. Obtaining a user's historical electricity consumption data can be achieved by reading the stored electricity consumption records from smart meters or power data acquisition terminals. Furthermore, this operation can be achieved by directly reading through a local interface or remotely pulling historical data packets through a communication network, thereby establishing a data foundation for user electricity consumption behavior analysis. Noise removal and outlier processing of historical electricity consumption data can be performed using statistical methods or signal processing techniques to identify and correct noise and outliers in the data. Furthermore, this operation can be achieved through data cleaning using moving average filtering, Z-score detection, or the isolated forest algorithm, thereby improving sample data quality and enhancing the stability of subsequent modeling. Constructing user electricity consumption sample data can be achieved by organizing the cleaned historical electricity consumption data into a structured dataset. Furthermore, this operation can be achieved by aggregating data by time window, generating feature vectors, or creating user-level data tables, thereby forming a standard input format that can be used for model training.
[0032] Step S200: Obtain user attribute data and electricity retail package attribute data, and add user electricity consumption feature tags to the user electricity consumption sample data.
[0033] The user attribute data can be static or semi-static data describing basic user information and electricity usage scenarios, which can be used to assist in identifying user types and their electricity demand characteristics. In one specific embodiment, the user attribute data comes from user registration information, contract files, or is imported from external systems. Furthermore, the user attribute data can include, but is not limited to, one or more of user type, electricity address, and industry category. The electricity retail package attribute data can be structured information such as the pricing mechanism, billing method, and service content included in the electricity retail product, which can be used to provide a functional and economical description of recommended packages. For example, the electricity retail package attribute data is configured and maintained by the electricity retailer in the product management system. Furthermore, the electricity retail package attribute data can include, but is not limited to, one or more of time-of-use pricing packages, fixed-price packages, and green energy packages.
[0034] Obtaining user attribute data and electricity retail package attribute data can be achieved by extracting two types of structured data from business systems or databases. Furthermore, this operation can be implemented by integrating data sources through API calls, database queries, or file imports, thereby supplementing the contextual information of users and packages to support feature engineering. User electricity consumption sample data can be a collection of cleaned and structured historical electricity consumption data, which can be used as basic input data for model training to improve data reliability. In this embodiment, user electricity consumption sample data is generated by denoising, imputing missing values, and removing outliers from the original historical electricity consumption data. User electricity consumption feature tags can be multi-dimensional feature identifiers that semantically annotate electricity consumption behavior based on user attributes and package attributes, which can be used to achieve a structured expression of user electricity consumption habits and preferences. Furthermore, user electricity consumption feature tags are generated by labeling sample data using a rule engine or manual annotation methods, combining user attributes and package attributes. Furthermore, user electricity consumption feature tags can include, but are not limited to, one or more of the following: peak electricity consumption tendency tags, energy-saving preference tags, and price sensitivity tags. Adding user electricity consumption feature tags to user electricity consumption sample data can be done by performing multi-dimensional feature annotation on the sample data based on user attributes and package attributes. Furthermore, this operation can be achieved by assigning tags through preset rule mapping, cluster analysis, or expert experience, thereby realizing the semantic expression of user electricity consumption behavior.
[0035] Step S300: Train the package recommendation model using electricity consumption sample data and user electricity consumption feature labels.
[0036] The package recommendation model can be a rating model built based on machine learning algorithms to predict users' preferences for electricity packages, and can be used to achieve a quantifiable evaluation of the matching between users and electricity packages. In an exemplary embodiment, the package recommendation model is trained using labeled user electricity consumption sample data through supervised learning. Furthermore, the package recommendation model can be one or more of the following, including but not limited to collaborative filtering models, gradient boosting tree models, and neural network recommendation models. Training the package recommendation model can be achieved by using labeled sample data to drive machine learning algorithms to learn user-package matching patterns. Furthermore, this operation can be implemented by optimizing hyperparameters through cross-validation, introducing regularization to prevent overfitting, and using incremental learning to update the model, thereby establishing a predictive capability capable of capturing potential correlations.
[0037] Step S400: Obtain the current user's real-time electricity consumption data and user attribute data and use them as input data for the package recommendation model. Output the recommendation score of each electricity retail package through the package recommendation model, and push the electricity retail package with the highest recommendation score as the recommendation result to the user terminal.
[0038] Real-time electricity consumption data can be user electricity consumption information streams collected at the current moment or recently, reflecting the user's current electricity consumption status and short-term behavioral changes. For example, real-time electricity consumption data is uploaded to the data analysis system in real time via smart meters or collection terminals. Furthermore, real-time electricity consumption data can include, but is not limited to, one or more of minute-level load data, daily cumulative electricity consumption, and real-time power data. Obtaining the current user's real-time electricity consumption data and user attribute data can involve real-time collection and integration of the user's latest electricity consumption information and static attributes. Furthermore, this operation can be implemented by receiving real-time streaming data through a message queue and linking with the main data system, thereby ensuring that the recommended input reflects the user's current status. The recommendation score can be a numerical value output by the model representing the degree of matching between a certain electricity package and the user, which can be used to sort and select the optimal recommendation result. In a specific embodiment, the recommendation score is calculated by the package recommendation model based on the input data.
[0039] Outputting recommendation scores for each electricity retail package through a package recommendation model can be achieved by feeding input data into a trained model and calculating a matching score for each package. Furthermore, this operation can be improved in response speed through batch inference or multi-threaded concurrent processing, thereby enabling quantitative evaluation of personalized packages. The user terminal can be an electronic device for receiving information and interacting with services, used to complete the information delivery of recommendation results and user outreach. In this embodiment, the user terminal receives system-pushed content through mobile applications, web platforms, or SMS channels. Furthermore, the user terminal can be, but is not limited to, one or more of smartphones, tablets, and web browsers. Pushing the electricity retail package with the highest recommendation score to the user terminal can be achieved by filtering the highest-scoring package and sending a notification through communication channels. Furthermore, this operation can be implemented by combining push notifications with user activity periods, adding explanations, or providing alternative solutions, thereby completing a service loop from model output to user outreach.
[0040] Taking the summer electricity consumption optimization recommendation for residential users as an example, the electricity retail package recommendation method in this embodiment can be as follows: A residential user in a certain city uses air conditioning frequently in the summer. The system continuously collects their hourly electricity consumption data through smart meters and finds that the user's load increases significantly during the evening peak hours. After data cleaning, an electricity consumption sample is constructed, and combined with the user's "household user" attribute and the local "time-of-use pricing policy," "high peak electricity consumption" and "price sensitive" characteristic tags are labeled. The recommendation model trained based on historical labeled data identifies that the user is suitable for an off-peak discount package. After the system obtains the user's real-time electricity consumption data, the model outputs multiple package scores, among which a certain green time-of-use package has the highest score. The system automatically pushes its recommendation information to the user's mobile app. After the user confirms the change, the monthly electricity bill decreases, and the company also improves customer satisfaction due to precise service.
[0041] This embodiment provides a method for recommending electricity retail packages. It acquires historical electricity consumption data from users and performs noise reduction and outlier processing on this data to construct user electricity consumption sample data. It then acquires user attribute data and electricity retail package attribute data, adding user electricity consumption feature tags to the sample data. A package recommendation model is trained using this sample data and user feature tags. Real-time electricity consumption data and user attribute data of the current user are acquired and used as model input to output recommendation scores for each electricity retail package. Finally, the electricity retail package with the highest recommendation score is pushed to the user's terminal. This method integrates long-term user electricity consumption behavior characteristics with real-time electricity consumption status, combines user attributes and package attributes to achieve multi-dimensional feature characterization, dynamically evaluates package matching using a machine learning model, and completes the service loop through automated push notifications. This approach can achieve the technical effects of improving the personalization level of electricity retail services, optimizing user electricity costs, and enhancing enterprise service capabilities and market competitiveness.
[0042] Furthermore, the step of denoising and outlier processing the historical electricity consumption data to construct user electricity consumption sample data includes: Historical electricity consumption data is converted into an electricity consumption embedding matrix according to the time series. The electricity consumption embedding matrix is decomposed into an electricity consumption matrix. The electricity consumption matrix with singular values greater than 0 is used to form an electricity consumption component matrix. The electricity consumption component matrix is converted into an electricity consumption time series by diagonal averaging.
[0043] The electricity consumption embedding matrix can be a two-dimensional matrix structure reconstructed from historical electricity consumption data of a time series using a sliding window. It can be used to reveal potential dynamic patterns in the electricity consumption data and support subsequent matrix decomposition processing. In this embodiment, the electricity consumption embedding matrix can map a one-dimensional electricity consumption sequence to a matrix representation in a high-dimensional phase space using a time-delay embedding method. Furthermore, the electricity consumption embedding matrix can serve as the basis for generating the electricity consumption matrix, working in conjunction with it during signal decomposition. The electricity consumption matrix can be a set of sub-matrices containing left singular vectors, right singular vectors, and singular values obtained after singular value decomposition of the electricity consumption embedding matrix. It can be used to separate the main components and noise components in the electricity consumption signal. In an exemplary embodiment, the electricity consumption matrix is obtained by orthogonally decomposing the electricity consumption embedding matrix using a singular value decomposition algorithm. Exemplarily, the electricity consumption matrix can include, but is not limited to, one or more of the following: left singular vector sub-matrices, right singular vector sub-matrices, and singular value diagonal sub-matrices. The electricity consumption component matrix can be a set of signal components composed of electricity consumption matrices with singular values greater than 0, which can be used to preserve the effective structural features in the original electricity consumption signal. Furthermore, the electrical component matrix is formed by selecting singular value corresponding submatrices with significant energy contributions and then linearly superimposing them. In one specific embodiment, the electrical component matrix is used as input for diagonal averaging to participate in the generation of an analyzable time series signal.
[0044] Electricity consumption time series can be a one-dimensional time-domain signal recovered by performing a diagonal averaging operation on the electricity consumption component matrix. It can be used to restore the original time series form from matrix form, facilitating frequency domain transformation. In this embodiment, the electricity consumption time series is obtained by averaging along the anti-diagonal direction of the electricity consumption component matrix to obtain reconstructed values at continuous time points. For example, the electricity consumption time series can include, but is not limited to, one or more of high-frequency fluctuating electricity consumption series, low-frequency trend electricity consumption series, and daily periodic electricity consumption series. Converting historical electricity consumption data into an electricity consumption embedding matrix according to the time series can be achieved by using time-delay embedding technology to reconstruct the one-dimensional electricity consumption series into a two-dimensional matrix. Further, this operation can be achieved by setting the sliding window length and delay step size, segmenting and stacking data to form matrix row vectors, thereby enhancing the structural expressiveness of the data and facilitating subsequent decomposition processing. Decomposing the electricity consumption embedding matrix into an electricity consumption matrix can be achieved by applying a singular value decomposition algorithm to perform orthogonal decomposition on the electricity consumption embedding matrix. Furthermore, this operation can be achieved by using a numerical computation library to perform SVD decomposition, separating the left singular vector, right singular vector, and singular values, thereby realizing signal denoising and principal component extraction. The singular values greater than 0 are used to construct the electricity component matrix using the electron matrix; this can be achieved by selecting sub-matrices corresponding to non-zero singular values and weighting them. Further, this operation can be achieved by setting an energy accumulation contribution rate threshold to retain the principal components, thereby removing redundant information and preserving the effective signal structure. The electricity component matrix is converted into an electricity time series through diagonal averaging; this can be achieved by calculating the average value along the anti-diagonal direction of the matrix to recover the time-series signal. Further, this operation can be achieved by using the Hankel inverse transform method to reconstruct continuous time-point values, thereby completing the back-mapping from the matrix space to the original time domain.
[0045] The electricity consumption time series is transformed to the frequency domain to obtain electricity consumption spectrum data. The electricity consumption spectrum data is divided into continuous intervals of peak, flat and valley electricity consumption. Within the continuous intervals, an electricity consumption scaling function is constructed to obtain electricity consumption detail coefficients and electricity consumption approximation coefficients. The signal is reconstructed based on the electricity consumption detail coefficients and electricity consumption approximation coefficients to obtain the electricity consumption components.
[0046] The electricity consumption spectrum data can be the frequency domain representation of an electricity consumption time series after Fourier transform, which can be used to identify periodic components in the electricity load, such as daily or weekly cycles. In an exemplary embodiment, the electricity consumption spectrum data is obtained by converting the time-domain signal into a frequency-domain amplitude distribution using a Fast Fourier Transform (FFT). Exemplarily, the electricity consumption spectrum data can include, but is not limited to, one or more of the fundamental frequency spectrum component, harmonic frequency spectrum component, and noise frequency spectrum component. The peak, flat, and valley electricity consumption continuous intervals can be load level intervals divided according to the electricity consumption spectrum energy distribution, which can be used to reflect the time-period characteristics of user electricity consumption and support differentiated modeling. Further, the peak, flat, and valley electricity consumption continuous intervals are obtained by determining the time period range corresponding to different load intensities based on spectral amplitude clustering or threshold segmentation. In a specific embodiment, the peak, flat, and valley electricity consumption continuous intervals serve as the time basis for constructing an electricity consumption scaling function. The electricity consumption scaling function can be a basis function constructed within a specific time interval for multi-resolution analysis, which can be used to extract detailed and approximate features of the electricity consumption signal in a local time interval. In this embodiment, the electricity consumption scaling function is constructed by scaling and translating a mother wavelet function at different scales within a wavelet transform framework. For example, the electricity consumption scaling function can be the Haar scaling function, the Daubechies scaling function, the Symlet scaling function, etc. The electricity consumption detail coefficients can be the high-frequency output of wavelet decomposition reflecting the local rate of change of the electricity consumption signal, and can be used to capture transient behaviors such as short-term load surges and start-stop events. Furthermore, the electricity consumption detail coefficients are obtained by multi-level decomposition of the electricity consumption scaling function using a high-pass filter bank. In an exemplary embodiment, the electricity consumption detail coefficients and the electricity consumption approximation coefficients are used together for signal reconstruction.
[0047] Electricity consumption approximation coefficients can be the low-frequency output of wavelet decomposition reflecting the overall trend of electricity consumption signals, and can be used to characterize the long-term load trend and basic electricity consumption profile of users. In this embodiment, the electricity consumption approximation coefficients are obtained by extracting the electricity consumption scale function layer by layer through a low-pass filter bank. For example, the electricity consumption approximation coefficients can be one or more of the following, including but not limited to the daily average load coefficient, weekly trend coefficient, and seasonal benchmark coefficient. Electricity consumption components can be components of electricity consumption signals with different feature dimensions obtained based on wavelet reconstruction, which can be used to realize multi-granularity analysis of electricity consumption behavior and support refined modeling. In a specific embodiment, the electricity consumption components are obtained by synthesizing them using inverse wavelet transform with electricity consumption detail coefficients and electricity consumption approximation coefficients. Furthermore, the electricity consumption components participate in the correlation coefficient calculation and serve as the basis for merging judgment. For example, the electricity consumption components can be one or more of the following, including but not limited to trend-type electricity consumption components, fluctuation-type electricity consumption components, and noise-type electricity consumption components. Transforming the electricity consumption time series to the frequency domain to obtain electricity consumption spectrum data can be achieved by performing a fast Fourier transform to convert the time-domain signal into a frequency-domain representation. Furthermore, this operation can be achieved by reducing spectral leakage and improving frequency resolution through windowing, thereby identifying periodic patterns in the load. Dividing the electricity consumption spectrum data into continuous peak, flat, and valley consumption intervals can be based on interval segmentation according to spectral energy distribution characteristics. Further, this operation can be achieved by combining clustering algorithms or setting power thresholds to automatically identify load level intervals, thus establishing time partitions that conform to actual electricity consumption rhythms. Constructing electricity consumption scale functions within continuous intervals to obtain electricity consumption detail coefficients and approximation coefficients can be achieved by applying wavelet transform to decompose the electricity consumption signal at different scales. Further, this operation can be achieved by selecting appropriate wavelet basis functions for multi-level decomposition to extract multi-resolution features, thereby achieving a fine characterization of electricity consumption behavior. Reconstructing the signal from the electricity consumption detail coefficients and approximation coefficients to obtain electricity consumption components can be achieved by using inverse wavelet transform to restore the coefficients to time-domain signal segments. Further, this operation can be achieved by using maximum overlap discrete wavelet transform to ensure reconstruction accuracy, thereby generating electricity consumption components with clear physical meaning.
[0048] Calculate the correlation coefficient of the electricity consumption components, and merge the electricity consumption components with correlation coefficients greater than the preset coefficient threshold into user electricity consumption sample data, where the correlation coefficient is the Pearson correlation coefficient between the electricity consumption components.
[0049] The Pearson correlation coefficient can be a statistical indicator measuring the degree of linear correlation between two electricity consumption components, and can be used to determine whether different electricity consumption components represent the same type of behavioral pattern. In an exemplary embodiment, the Pearson correlation coefficient is obtained by calculating the similarity between two sets of data using the ratio of covariance to standard deviation. Further, the Pearson correlation coefficient is used to compare the similarity between electricity consumption components and decide whether to merge them. For example, the Pearson correlation coefficient can be one or more of the following, including but not limited to strong positive correlation coefficient, weak correlation coefficient, and negative correlation coefficient. Calculating the correlation coefficient of electricity consumption components can be achieved by using the Pearson formula to calculate the linear correlation between any two electricity consumption components. Further, this operation can be achieved by constructing a correlation coefficient matrix to visualize the relationship between components, thereby assessing the pattern overlap of different components. Merging electricity consumption components with correlation coefficients greater than a preset threshold can be achieved by weighted fusion of highly correlated electricity consumption components to form a comprehensive component. Further, this operation can be achieved by using principal component analysis or average ensemble methods to reduce redundant features and improve the consistency of sample data.
[0050] For example, in the scenario of optimizing and identifying the load patterns of industrial and commercial users, the electricity retail package recommendation method in this embodiment can be based on the complex fluctuations in historical electricity consumption data of a shopping mall user. The system converts this data into an electricity consumption embedding matrix and performs singular value decomposition to separate multiple electricity consumption matrices. After reconstructing the time series by filtering effective components, frequency domain analysis identifies obvious daily cycles and weekend effects. Within the peak interval, a Haar scaling function is constructed to extract high-frequency detail coefficients caused by air conditioning start-stop and low-frequency approximation coefficients of lighting load, reconstructing three types of electricity consumption components: basic lighting, air conditioning load, and temporary equipment. Calculations show that the correlation coefficient between air conditioning and temporary equipment components is below a threshold and is retained independently; while nighttime lighting and security equipment components are highly correlated and are merged. The final user electricity consumption sample data more accurately reflects their true electricity consumption structure, providing high-quality input for subsequent recommendation models.
[0051] In one embodiment, the formula for calculating the power consumption component by reconstructing the signal based on the power consumption detail coefficients and the power consumption approximation coefficients is as follows:
[0052] in, For electrical components, For electricity consumption detail factors, Let F be the approximation coefficient for electricity consumption, F be the Fourier transform, A be the electricity consumption scale function, τ be the time length of the continuous interval, j be the component count, and M be the number of electricity consumption component categories.
[0053] The electricity consumption component can be a component of the electricity consumption signal synthesized by a reconstruction formula using electricity consumption detail coefficients and electricity consumption approximation coefficients. It can be used to generate electricity consumption behavior decomposition units with clear mathematical basis and physical meaning, thereby finely characterizing the user's load structure. In an exemplary embodiment, the electricity consumption component can be obtained through inverse signal reconstruction using a specified mathematical expression combined with Fourier transform, electricity consumption scaling function, time length parameter, and coefficient terms. Furthermore, the electricity consumption component can be the result of the reconstruction process relying on parameters such as electricity consumption detail coefficients, electricity consumption approximation coefficients, and electricity consumption scaling function. The electricity consumption detail coefficients can be wavelet high-frequency decomposition outputs reflecting the local abrupt changes in the electricity consumption signal, and can be used to capture transient electricity consumption behaviors such as short-term fluctuations and equipment start-up and shutdown. In this embodiment, the electricity consumption detail coefficients can be obtained by performing multi-resolution analysis of the electricity consumption scaling function within a continuous interval using a high-pass filter. Exemplarily, the electricity consumption detail coefficients can be used together with the electricity consumption approximation coefficients as input terms in the reconstruction formula, forming the basis of the electricity consumption component. The electricity consumption approximation coefficients can be wavelet low-frequency decomposition outputs reflecting the overall trend characteristics of the electricity consumption signal, and can be used to characterize the user's baseline load level and long-term electricity consumption trend. In one specific embodiment, the electricity consumption approximation coefficients can be obtained by progressively approximating the electricity consumption scale function using a low-pass filter. Furthermore, the electricity consumption approximation coefficients, together with the electricity consumption detail coefficients, can serve as input terms in the reconstruction formula, forming the basis of the electricity consumption components.
[0054] The Fourier transform can be a mathematical tool for converting signals from the time domain to the frequency domain. It can be used to support the processing and combination of coefficients in the frequency domain, facilitating multi-component fusion and preservation of periodic features. For example, the Fourier transform can be implemented by applying complex exponential basis function integration or a fast algorithm to a time-series signal. Furthermore, the Fourier transform can be applied to the frequency domain mapping process of power consumption detail coefficients and power consumption approximation coefficients, providing an intermediate representation for inverse transform reconstruction. In an exemplary embodiment, the Fourier transform can include, but is not limited to, one or more of continuous Fourier transform, discrete Fourier transform, and fast Fourier transform. The power consumption scaling function can be a basis function used in wavelet analysis to construct multi-scale decomposition, providing a mathematical basis for the extraction of detail and approximation coefficients and participating in the modulation of frequency components during reconstruction. In this embodiment, the power consumption scaling function can be generated by pre-selecting a mother wavelet function and scaling and translating it at different scales and positions. Furthermore, the power consumption scaling function can serve as a modulation factor in the reconstruction formula, influencing the shape and distribution of the final power consumption components.
[0055] The duration of the continuous interval can be the time span covered by the peak, flat, and valley electricity consumption intervals. It can be used to limit the effective time range of the reconstructed signal, ensuring that the components are aligned with the actual electricity consumption periods. In a specific embodiment, the duration of the continuous interval can be obtained by dividing the electricity consumption spectrum data and statistically analyzing the start and end time differences of each interval. The component count can be the index of the j-th electricity consumption component currently being reconstructed. It can be used to distinguish different categories of electricity consumption behavior patterns and support parallel modeling of M types of components. In this embodiment, the component count can be assigned sequentially during iterative cycles or multi-channel decomposition. Furthermore, the component count can be used together with M to define the traversal range of the reconstruction process. The number of electricity consumption component categories can be the total number of electricity consumption behavior categories preset or determined by clustering. It can be used to control model complexity and guide the granularity of electricity consumption behavior classification. In an exemplary embodiment, the number of electricity consumption component categories can be set through prior knowledge or obtained through clustering analysis based on component differences. For example, the number of electricity consumption component categories can determine the maximum value of j, limiting the termination condition of the reconstruction process.
[0056] The electricity consumption component is obtained by reconstructing the signal based on the electricity consumption detail coefficients and approximation coefficients. This can be achieved by following a given mathematical formula, performing a Fourier transform on the electricity consumption detail coefficients and approximation coefficients, then weighting them with an electricity consumption scaling function, and finally recovering the time-domain signal through an inverse transform. Further, this operation can be performed by processing each coefficient term separately in the frequency domain, multiplying it by the corresponding scaling function A(τ,j), then summing the results and performing an inverse Fourier transform to obtain the final electricity consumption component. Parallel computing can be used to improve the reconstruction efficiency of multiple components, thereby achieving accurate reconstruction of the electricity consumption signal based on a rigorous mathematical expression, enhancing the interpretability and consistency of the components. For example, in the scenario of identifying nighttime electricity consumption patterns of residential users, the electricity retail package recommendation method in this embodiment can be based on the fact that a household user has three types of loads at night: lighting, water heater, and refrigerator. The system divides the continuous off-peak period (23:00–7:00) based on its historical data, where τ = 8 hours. Within this interval, detailed electricity consumption coefficients (reflecting the start-stop pulses of the water heater) and approximate electricity consumption coefficients (characterizing the continuous operating trend of the refrigerator) are extracted. Using the Daubechies scaling function A, three electricity consumption components are reconstructed sequentially within the range of j=1 to M=3: stable base load, periodic heating, and random lighting. Each component undergoes F-transformation to fuse coefficients in the frequency domain, followed by inverse transform to restore the original components, ensuring time alignment and waveform continuity. The reconstructed components are then subjected to correlation testing to merge similar terms, forming a clearly structured user electricity consumption sample data, significantly improving the accuracy of subsequent recommendation models in identifying off-peak electricity consumption preferences.
[0057] In one embodiment, user attribute data and electricity retail package attribute data are obtained, and user electricity consumption feature tags are added to the user electricity consumption sample data, including: Obtain user attribute data and electricity retail package attribute data; add user electricity consumption feature tags to user electricity consumption sample data based on user attribute data; and define peak-valley electricity consumption difference rate.
[0058] in, Peak-valley electricity consumption differential rate Peak electricity consumption Electricity consumption during off-peak hours Electricity consumption for the flat section; The peak-valley electricity consumption difference rate can be a quantitative indicator measuring the difference in electricity consumption between peak, flat, and valley periods. It can be used to identify the user's load distribution characteristics and determine whether they are suitable for participating in time-of-use pricing packages. Peak-segment electricity consumption can be the user's cumulative electricity consumption during the peak period defined by the power grid, reflecting the user's electricity consumption intensity during periods of high load in the power system. In this embodiment, peak-segment electricity consumption can be obtained by extracting the total electricity consumption for the corresponding time period from historical electricity consumption data. For example, peak-segment electricity consumption can be one of the input parameters for calculating the peak-valley electricity consumption difference rate. Valley-segment electricity consumption can be the user's cumulative electricity consumption during the low-valley period defined by the power grid, reflecting the user's electricity consumption level during periods of low load in the power system. In a specific embodiment, valley-segment electricity consumption can be obtained by extracting the total electricity consumption for the corresponding time period from historical electricity consumption data. Further, valley-segment electricity consumption can be one of the input parameters for calculating the peak-valley electricity consumption difference rate. Flat-segment electricity consumption can be the user's cumulative electricity consumption during the flat-segment defined by the power grid, and can be used as a normalized benchmark value in the calculation of the peak-valley electricity consumption difference rate. For example, the average electricity consumption during a peak period can be obtained by extracting the total electricity consumption for the corresponding time period from historical electricity consumption data. In this embodiment, the average electricity consumption during a peak period can be used as a denominator in the calculation of the peak-valley electricity consumption difference rate.
[0059] The first preset peak-valley electricity consumption difference rate can be a threshold parameter used to classify highly differentiated electricity consumption behaviors, and can be used as an upper limit judgment condition for user electricity consumption feature label classification. In an exemplary embodiment, the first preset peak-valley electricity consumption difference rate can be set to a fixed value based on regional electricity consumption characteristics or historical data analysis. Further, the first preset peak-valley electricity consumption difference rate can be used together with the second preset peak-valley electricity consumption difference rate to form a multi-level discrimination logic. The second preset peak-valley electricity consumption difference rate can be a threshold parameter used to classify moderately differentiated electricity consumption behaviors, and can be used as a lower limit judgment condition for user electricity consumption feature label classification. In this embodiment, the second preset peak-valley electricity consumption difference rate can be set to a fixed value based on regional electricity consumption characteristics or historical data analysis. Exemplarily, the second preset peak-valley electricity consumption difference rate can be used together with the first preset peak-valley electricity consumption difference rate to form a multi-level discrimination logic. Adding user electricity consumption feature labels to user electricity consumption sample data based on user attribute data can be an operation of calculating the peak-valley electricity consumption difference rate based on peak, valley, and flat electricity consumption in user attributes, and assigning labels according to preset threshold intervals. Furthermore, this operation can achieve three-interval classification through conditional statements: if the peak-valley electricity consumption difference rate is greater than the first preset peak-valley electricity consumption difference rate, the label is set to -1; if the peak-valley electricity consumption difference rate is greater than or equal to the second preset peak-valley electricity consumption difference rate and less than or equal to the first preset peak-valley electricity consumption difference rate, the label is set to 0; if the peak-valley electricity consumption difference rate is less than the second preset peak-valley electricity consumption difference rate, the label is set to 1. This transforms continuous electricity consumption behavior into a discrete feature representation, making it easier for the model to learn nonlinear preferences.
[0060] If the peak-valley electricity consumption difference rate is greater than the first preset peak-valley electricity consumption difference rate, the user's electricity consumption characteristic label is set to -1; if the peak-valley electricity consumption difference rate is greater than or equal to the second preset peak-valley electricity consumption difference rate and less than or equal to the first preset peak-valley electricity consumption difference rate, the user's electricity consumption characteristic label is set to 0; if the peak-valley electricity consumption difference rate is less than the second preset peak-valley electricity consumption difference rate, the user's electricity consumption characteristic label is set to 1; wherein, the first preset peak-valley electricity consumption difference rate is greater than the second preset peak-valley electricity consumption difference rate. User attribute data includes user type, total power of electrical equipment, average electricity consumption duration, and peak-valley electricity consumption ratio. User type can describe the user's electricity consumption category, such as residential, industrial, or commercial, and can be used to influence electricity consumption behavior patterns and the appropriate service package. In one specific embodiment, user type can be derived from user registration information or a profile system. Furthermore, user type can be combined with total power of electrical equipment and average electricity consumption duration to form a user attribute data system. For example, user type can include, but is not limited to, one or more of residential, industrial, and commercial users. Total power of electrical equipment can be the sum of the rated power of all the user's electrical equipment, and can be used to reflect the user's maximum potential load demand. In this embodiment, total power of electrical equipment can be declared by the user or estimated through load monitoring. Furthermore, total power of electrical equipment can be combined with average electricity consumption duration to assess the overall electricity consumption scale. Average electricity consumption duration can be the average continuous operating time of the user's equipment within a daily or typical cycle, and can be used to assist in judging the continuity and stability of the user's electricity consumption. In an exemplary embodiment, average electricity consumption duration can be calculated statistically from the time span of continuous electricity consumption records. For example, average electricity consumption duration can be combined with the total power of electrical equipment for load profiling. Peak-valley electricity consumption ratio can be the proportion of a user's electricity consumption during peak and valley periods relative to their total electricity consumption, and can be used to reveal a user's preferences for electricity resource utilization at different times. In this embodiment, the peak-valley electricity consumption ratio can be calculated by dividing peak or valley electricity consumption by the total electricity consumption over a period. Furthermore, the peak-valley electricity consumption ratio can be used to support the contextual interpretation and verification of peak-valley electricity consumption difference rates. For example, the peak-valley electricity consumption ratio can include, but is not limited to, one or more of peak-period electricity consumption ratio and valley-period electricity consumption ratio.
[0061] Electricity retail package attribute data includes package type, benchmark electricity price, peak-valley time period division, and discount rate. Package type can be a classification identifier for electricity retail products, reflecting their pricing mechanism and service characteristics, and can be used to determine the applicable scenarios and target user groups for the package. In one specific embodiment, the package type can be defined and maintained by the electricity retailer during the product design phase. Furthermore, the package type can constitute a package attribute data system together with the benchmark electricity price and peak-valley time period division. For example, the package type can include, but is not limited to, one or more of time-of-use pricing packages, fixed-price packages, and demand-response packages. The benchmark electricity price can be the basic price per unit of electricity specified in the electricity package, and can be used as a core parameter for calculating user electricity bills. In this embodiment, the benchmark electricity price can be set by the electricity retailer based on costs and market strategies. Furthermore, the benchmark electricity price can be combined with the discount rate for deriving actual electricity prices. Peak-valley time period division can be a time interval configuration that divides a day into different price periods such as peak, flat, and valley, and can be used to support the implementation of differentiated pricing strategies. In an exemplary embodiment, the peak-valley time period division can be set according to regional power grid dispatch rules or policy requirements. For example, peak-valley time periods can include, but are not limited to, one or more of the following: peak + peak + flat + valley, peak + valley, and multi-rate time periods. Furthermore, peak-valley time period division can affect the definition of peak and valley electricity consumption. The discount rate can be a reduction percentage relative to the benchmark electricity price, which can be used to enhance the attractiveness of the package and incentivize users to choose it. In this embodiment, the discount rate can be set by the electricity retailer for specific user groups or promotional activities. Furthermore, the discount rate can be combined with the benchmark electricity price to generate the actual executed electricity price.
[0062] User electricity consumption characteristic tags are added to the electricity consumption sample data. Taking the identification of electricity consumption patterns and package matching for industrial and commercial users as an example, the electricity retail package recommendation method in this embodiment can be as follows: a commercial office building user has concentrated air conditioning load during the day and basically no electricity consumption at night. The system collects its historical electricity consumption data and calculates that the peak electricity consumption is 800kWh, the average peak is 400kWh, and the valley is 100kWh. The peak-valley electricity consumption difference rate is (800-100) / 400 = 1.75. Assuming the first preset peak-valley electricity consumption difference rate is 1.5 and the second is 1.0, since 1.75 > 1.5, the tag is set to -1, indicating that the user has a significant peak-valley difference. Combining its "commercial user" type and the total power attribute of high-consuming equipment, the system classifies it as a candidate suitable for time-of-use electricity price optimization packages. This tag enters the model training stage along with the sample data, enabling the model to identify that such users with high differences are more likely to choose packages with large peak price reductions, thereby improving the matching accuracy in real-time recommendations.
[0063] This embodiment acquires user attribute data and electricity retail package attribute data, calculates the peak-valley electricity consumption difference rate based on peak, valley, and flat electricity consumption, and discretizes user electricity consumption feature tags according to the first and second preset peak-valley electricity consumption difference rate and their corresponding threshold values. These tags are then attached to the electricity consumption sample data, allowing user electricity consumption behavior to express its time-period electricity consumption differences through structured tags. By introducing dimensions such as user type, total power of electrical equipment, average electricity consumption duration, and peak-valley electricity consumption ratio, the user profile is improved. Combined with information such as package type, benchmark electricity price, peak-valley time period division, and discount rate, a product-side description system is constructed. This allows for refined modeling of the matching logic between user characteristics and package attributes, achieving the technical effect of improving the accuracy and practicality of electricity retail package recommendations.
[0064] In one embodiment, a package recommendation model is trained using electricity consumption sample data and user electricity consumption feature tags, including: Electricity consumption sample data and user electricity consumption feature labels are input into a deep collaborative filtering network. In this embodiment, the deep collaborative filtering network can be a recommendation model architecture combining collaborative filtering mechanisms and deep neural networks, which can be used to improve the modeling ability of complex relationships between user preferences and package characteristics. For example, the deep collaborative filtering network can map discrete IDs into continuous vectors through an embedding layer and use a multilayer perceptron to learn high-order interaction features between users and packages. Further, the deep collaborative filtering network can receive electricity consumption sample data and user electricity consumption feature labels as input and output a user-package feature mapping set for model training. In an exemplary embodiment, the deep collaborative filtering network can include, but is not limited to, one or more of attention-based deep collaborative filtering, graph-enhanced collaborative filtering, and autoencoder collaborative filtering. Inputting electricity consumption sample data and user electricity consumption feature labels into the deep collaborative filtering network can involve organizing structured data and sending it to the network front end for vector mapping. Further, this operation can be implemented by batch loading or streaming data transmission to the embedding layer, thereby initiating the feature extraction process of the deep model.
[0065] The embedding layer maps user IDs and package IDs to low-dimensional dense vectors. In this embodiment, the embedding layer can be a trainable layer in a neural network used to convert categorical IDs into low-dimensional dense vectors, which can reduce the input dimensionality and capture the latent semantic relationships between IDs. In one specific embodiment, the embedding layer can map user IDs and package IDs to fixed-length vector representations using a lookup table. Furthermore, the embedding layer can operate on user IDs and package IDs to provide vector input for subsequent multilayer perceptrons.
[0066] Feature mappings are obtained by extracting nonlinear features from input data using a multilayer perceptron. In this embodiment, the multilayer perceptron can be a feedforward neural network structure composed of multiple fully connected layers, which can be used to mine nonlinear interaction patterns between users and package features. For example, the multilayer perceptron can transform the input features layer by layer using nonlinear activation functions to extract higher-order abstract representations. Further, the multilayer perceptron can generate feature mappings using the vector output from the embedding layer as input. In an exemplary embodiment, the multilayer perceptron can include, but is not limited to, one or more of shallow perceptrons, deep feedforward networks, and residual connection perceptrons.
[0067] Feature mappings are obtained by extracting nonlinear features from input data using a multilayer perceptron, which can involve performing linear transformations and nonlinear activation operations layer by layer. Furthermore, this operation can be improved by introducing Dropout and Batch Normalization to enhance generalization capabilities, thereby capturing complex high-order interaction features between users and service plans. Dimensionality reduction of the feature mappings yields a user-service plan feature mapping set. In this embodiment, the user-service plan feature mapping set can be a set of joint user and service plan feature representations obtained after processing by a deep collaborative filtering network, which can be used as the basic input for model parameter updates, reflecting the comprehensive matching features between users and services plans. In a specific embodiment, the user-service plan feature mapping set can be obtained by performing dimensionality reduction on the feature mappings output by the multilayer perceptron. Furthermore, the user-service plan feature mapping set can be used to calculate parameter vectors and participate in loss function evaluation. For example, the user-service plan feature mapping set can include, but is not limited to, one or more of the following: low-dimensional joint embedding representation, compressed feature tensors, and fused feature vector sets. Dimensionality reduction of the feature mappings to obtain the user-service plan feature mapping set can be achieved by applying principal component analysis or fully connected compression layers to reduce feature dimensionality. Furthermore, this operation can be achieved by using an autoencoder or pooling operation to condense information, thereby preserving key matching features and reducing computational load.
[0068] A package recommendation model is established, and the weight matrix and bias vector of the package recommendation model are initialized to obtain an initial parameter vector and a predicted score vector. In this embodiment, the initial parameter vector can be a combination of a weight matrix and bias vector randomly initialized at the beginning of model training, which can be used to provide a starting point for the iterative optimization process. For example, the initial parameter vector can be initialized with model parameters according to a preset distribution (such as a normal distribution). Further, the initial parameter vector can be used to generate a predicted score vector in the early stages of training and participate in subsequent parameter update judgments. In an exemplary embodiment, the initial parameter vector can be one or more of the following, including but not limited to a zero-initialization vector, a Xavier initialization vector, and a He initialization vector. In this embodiment, the predicted score vector can be a set of matching scores output by the model for user-package combinations under the current parameters, which can be used to compare with the true scores to evaluate model performance. For example, the predicted score vector can be calculated by the output layer after the current parameter vector is applied to the input features. Further, the predicted score vector can participate in the prediction error value calculation together with the true score. In a specific embodiment, the predicted score vector can be one or more of the following, including but not limited to a normalized score vector, a probability distribution score, and a ranking preference score. A package recommendation model is established, and the initial parameter vector and predicted score vector are obtained by initializing the weight matrix and bias vector of the package recommendation model. This can be achieved by defining the network structure and randomly initializing the parameters. Furthermore, this operation can be improved by adopting a specific initialization strategy to enhance training stability, thereby preparing the initial state for model training.
[0069] The parameter vector is obtained based on the user-package feature mapping set. If the loss function value corresponding to the parameter vector in the next iteration is less than or equal to the preset loss function value, the parameter vector is used as the updated parameter vector; otherwise, the initial parameter vector is used as the updated parameter vector. In this embodiment, the loss function value can be a scalar indicator that measures the difference between the model's predicted result and the true label, and can be used to guide the direction of model parameter optimization. For example, the loss function value can be calculated using functions such as mean squared error and cross-entropy to determine the deviation between the predicted score and the true score. Furthermore, the loss function value can determine whether to accept the parameter vector of the next iteration as the updated parameter. In an exemplary embodiment, the loss function value can be one or more of the following, including but not limited to mean squared error, cross-entropy loss, and contrastive ranking loss. In this embodiment, the preset loss function value can be a pre-set loss function convergence threshold, which can be used as one of the training termination conditions. For example, the preset loss function value can be determined based on experience or experimental parameter tuning to determine whether the training has reached a stable state. Furthermore, the preset loss function value can be compared with the actual loss function value to determine the parameter update path. The parameter vector is obtained from the user-package feature mapping set. This feature mapping can be passed to the parameter generation module to calculate new parameters. Furthermore, this operation can be implemented by updating parameters using gradient descent or meta-learning methods, thus enabling parameter iteration based on the current features. Comparing the loss function value with a preset loss function value and selecting the updated parameter vector can determine whether the current loss meets the convergence condition and decide the parameter update path. Further, this operation can be implemented by setting a dynamic threshold or sliding window average loss as the criterion, ensuring that the model stops updating when it reaches convergence.
[0070] The prediction error value of the parameter vector is calculated. The prediction error value is the difference between the predicted score and the actual score. If the prediction error value is greater than a preset error value, the parameter vector at the next time step is updated based on the initial parameter vector. In this embodiment, the prediction error value can be the deviation between the model's predicted score and the score corresponding to the user's actual selection behavior. It can be used to evaluate the accuracy of a single prediction and trigger a parameter adjustment mechanism. For example, the prediction error value can be obtained by calculating the difference between the predicted score vector and the actual score vector. Further, the prediction error value can be compared with a preset error value to determine whether to update the parameter vector. In a specific embodiment, the prediction error value can be one or more of the following, including but not limited to absolute error, relative error, and sorting position error. In this embodiment, the preset error value can be a manually set maximum acceptable prediction error threshold, which can be used to control model accuracy requirements and affect the parameter update logic. For example, the preset error value can be set based on business needs or historical data statistics. Further, the preset error value can be compared with the prediction error value to determine whether to perform parameter updates. Calculating the prediction error value of the parameter vector can be done by comparing the predicted score with the actual behavior label to calculate the deviation. Furthermore, this operation can be improved by employing weighted error or a multi-objective error function, thereby quantifying the model's prediction accuracy. Updating the parameter vector at the next time step based on the initial parameter vector can involve backtracking or correcting the parameter update direction when the error exceeds the limit. Furthermore, this operation can be achieved by introducing a momentum term or adjusting the update magnitude using an adaptive learning rate, thus preventing the model from deviating from its reasonable training trajectory.
[0071] The model parameters corresponding to the iterated parameter vectors are used to construct a model parameter set, which represents the package recommendation model. In this embodiment, the model parameter set can be a collection of all learnable parameters finally determined after training, which can be used to fully represent the trained package recommendation model. For example, the model parameter set can be generated by fixing the optimal parameter vectors after iteration. Furthermore, the model parameter set can be used to construct a deployable package recommendation model instance. In an exemplary embodiment, the model parameter set can include, but is not limited to, one or more of the following: static parameter snapshots, incrementally updated parameter packages, and distributed parameter shards. Constructing the model parameter set from the iterated parameter vectors can involve persistently storing the final parameter state. Furthermore, this operation can be implemented by supporting version management, incremental saving, or encrypted storage, thereby forming a deployable recommendation model entity.
[0072] Taking dynamic package adaptation for industrial and commercial users as an example, the electricity retail package recommendation method in this embodiment can be based on the fact that the electricity consumption pattern of a commercial complex fluctuates significantly with seasons and holidays. The system collects its historical electricity consumption data and labels it with feature tags such as high peak load and sudden increase in electricity consumption during holidays. During the model training phase, a deep collaborative filtering network maps user IDs and various package IDs into vectors, and after nonlinear features are extracted by a multilayer perceptron, a joint user-package representation is formed. During training, the model continuously iterates the parameter vector. When the loss function value is lower than a preset threshold and the prediction error is controllable, training stops, and the final model parameter set is generated. After going live, whenever the user's real-time electricity consumption data shows a change in load pattern, the model immediately outputs the latest recommendation score and pushes a better demand-price package, achieving accurate dynamic matching.
[0073] This embodiment uses electricity consumption sample data and user electricity consumption feature tags as input data into a deep collaborative filtering network. An embedding layer maps user IDs and package IDs into low-dimensional dense vectors. A multilayer perceptron extracts nonlinear features from the input data to obtain feature maps. Dimensionality reduction of these feature maps yields a user-package feature map set. A package recommendation model is established, and its weight matrix and bias vector are initialized to obtain initial parameter vectors and prediction score vectors. Parameter vectors are obtained based on the user-package feature map set, and the updated parameter vectors are selected when the loss function value meets the convergence condition. The prediction error value of the parameter vectors is calculated, and the parameter update direction is adjusted based on the initial parameter vectors when the error exceeds a threshold. The model parameters corresponding to the iterated parameter vectors are used to construct a model parameter set, which represents the package recommendation model. The deep collaborative filtering network achieves high-order nonlinear modeling of user and package features. The embedding layer completes the conversion from sparse IDs to a continuous vector space. A multilayer perceptron extracts complex interaction features and forms a compact joint representation through dimensionality reduction. The loss function-driven parameter iteration mechanism and prediction error feedback control ensure model convergence and accuracy. Finally, the optimal parameters are solidified to form a deployable model entity, achieving the technical effect of improving recommendation accuracy and adaptability.
[0074] In one embodiment, a feature map is obtained by extracting nonlinear features from the input data using a multilayer perceptron, including: The number of neurons in the hidden layer of the multilayer perceptron is set according to the input data. The nonlinear interactive features of the input data are extracted using an activation function to obtain the feature map. The calculation formula is as follows:
[0075] in, The size of the feature mapping matrix, For the input data dimensions, This represents the number of neurons in the hidden layer. Step size, The number of hidden layers. Let g be the m-th feature map, and g be the activation function. Let m be the weight matrix of the m-th eigenmap. For input data, This is the bias vector.
[0076] The number of hidden layer neurons can be the number of neurons in each hidden layer of a multilayer perceptron, and can be used to determine the model's expressive power and computational capacity. In an exemplary embodiment, the number of hidden layer neurons can be set according to the input data dimensionality and model complexity requirements, and can be determined through empirical rules or hyperparameter optimization methods. Furthermore, the number of hidden layer neurons, along with the input data dimensionality and the number of hidden layers, jointly influences the structure of the feature mapping matrix. For example, the number of hidden layer neurons can include, but is not limited to, one or more of low-dimensional hidden layer configurations, medium-sized hidden layer configurations, and high-dimensional hidden layer configurations. This operation can be achieved by using a fixed ratio (such as twice the input dimension) or by using grid search to find the optimal configuration, thereby balancing model expressive power and computational efficiency.
[0077] The activation function can be a mathematical function used to introduce nonlinear transformations, enabling the neural network to learn complex patterns and extract nonlinear interactive features from the input data. In this embodiment, the activation function is applied after the output of each neuron in each layer, acting on the weighted sum of the input and bias to generate a nonlinear feature map. For example, the activation function can be one or more of the ReLU, Sigmoid, and Tanh functions. The basic operation involves applying the activation function to the linear transformation result in each hidden layer, generating nonlinear features layer by layer. Furthermore, convergence can be accelerated using ReLU, or LeakyReLU can be used to prevent neuron deactivation, enabling the capture of complex nonlinear relationships between user electricity consumption behavior and package attributes.
[0078] The size of the feature mapping matrix can represent the overall scale of the final generated feature mapping in the dimensional space. It can reflect the output specifications of the feature extraction process and affect the data form of subsequent model processing. In a specific embodiment, the size of the feature mapping matrix is jointly determined by the input data dimension, the number of hidden layer neurons, the number of hidden layers, and the stride. Further, the size of the feature mapping matrix is calculated based on the input data dimension, the number of hidden layer neurons, and the number of hidden layers. The input data dimension can be the dimension of the vector space input to the multilayer perceptron, representing the number of features. It can be used as the input basis of the multilayer perceptron and determine the shape of the weight matrix. For example, the input data dimension is formed by concatenating the user and package joint feature vectors output from the embedding layer. Further, the input data dimension, weight matrix, and bias vector jointly participate in the feature mapping calculation. For example, the input data dimension can be one or more of low-dimensional input, medium-dimensional input, and high-dimensional input, including but not limited to. The stride can be a parameter that controls the rate of dimensionality change during feature transformation and can be used to influence the compression or expansion trend of the feature mapping. In this embodiment, the stride is preset during model design and used to adjust the magnitude of change in the output dimension of each network layer. Furthermore, the stride, the number of hidden layers, and the dimensionality of the input data all influence the size of the feature mapping matrix. The number of hidden layers can be the total number of intermediate layers between the input and output layers in a multilayer perceptron, and can be used to enhance the model's ability to model complex nonlinear relationships. For example, the number of hidden layers is set during the model architecture design phase, determining the network depth. Furthermore, the number of hidden layers and the number of neurons in the hidden layers together determine the depth and breadth of feature extraction. For example, the number of hidden layers can be one or more of the following: shallow network structures, medium-depth network structures, and deep network structures.
[0079] The m-th feature map can be the specific feature representation result generated by the m-th feature transformation, and can be used to construct an intermediate expression of user-package matching features. In an exemplary embodiment, the m-th feature map is obtained by joint operation of the weight matrix, input data, bias vector, and activation function of the m-th layer network. Further, the m-th feature map is generated jointly by the weight matrix, input data, bias vector, and activation function. The weight matrix can be a learnable parameter matrix connecting the input layer and the hidden layer, and can be used to achieve a linear combination transformation of the input features. For example, the weight matrix is continuously updated during training using a backpropagation algorithm. Further, the weight matrix is multiplied by the input data and then used in the feature map calculation. For example, the weight matrix can use one or more of the following: randomly initialized weights, pre-trained weights, sparse weight matrices, etc. The bias vector can be a learnable parameter vector used to adjust the activation threshold of neurons, which can be used to improve model flexibility and avoid the output being limited to the origin. In this embodiment, each hidden layer is equipped with an independent bias vector, which is updated synchronously during training. Further, the bias vector is added to the weighted input and then used as the input to the activation function. For example, the bias vector can be one or more of the following, including but not limited to zero-initialized bias, constant bias, and learnable bias. The calculation process is derived formulaically based on the input data dimension, the number of neurons in the hidden layer, the number of hidden layers, and the stride. Furthermore, a dynamic structure adjustment mechanism can be designed to automatically adjust the output dimension according to the training process, thereby ensuring that the feature mapping meets the input requirements for subsequent dimensionality reduction and parameter learning.
[0080] Taking load fluctuation adaptation for manufacturing users as an example, the electricity retail package recommendation method in this embodiment can be based on the frequent changes in electricity consumption patterns caused by shift adjustments in a manufacturing enterprise. The system combines its historical electricity consumption data with the attributes of large industrial users to generate high-dimensional input features. In the deep collaborative filtering network, the multilayer perceptron sets three hidden layers according to the dimension of the input data, each containing 128 neurons, and uses the ReLU activation function to extract nonlinear features layer by layer. By controlling the dimensional transition through a preset step size, a compact feature mapping matrix is finally generated. After training, the model can accurately identify the user's need to switch from a fixed electricity price to a demand-based billing package, achieving real-time and accurate recommendations.
[0081] In one embodiment, after acquiring the current user's real-time electricity consumption data and user attribute data as input data for the package recommendation model, outputting recommendation scores for each electricity retail package through the package recommendation model, and pushing the electricity retail package with the highest recommendation score as the recommendation result to the user terminal, the method further includes: Obtain user needs and preferences, and build a package matching degree model based on user needs and preferences. The calculation formula for the package matching degree model is as follows: ; in, For the overall suitability of the package, , , These are the weighting coefficients. + + =1, Estimate the monthly electricity cost for the package. To ensure the compatibility between users' electricity consumption habits and the electricity pricing structure of the packages, The system scores the flexibility of electricity packages. User preferences can be subjective information regarding their inclinations towards electricity packages in terms of price, flexibility, and service content. This information can be used to build a personalized matching evaluation model, enhancing the consistency between recommended results and user expectations. In one exemplary embodiment, user preferences can be collected and structured through user questionnaires, historical selection behavior analysis, or interaction log mining. Furthermore, user preferences can include, but are not limited to, one or more of the following: cost-priority preferences, flexible electricity usage time preferences, and green electricity usage preferences.
[0082] Establishing a package matching model can involve constructing a weighted calculation framework that incorporates three elements: cost, habit matching, and flexibility. This framework provides a secondary ranking mechanism independent of the recommendation model, enhancing the overall rationality of the recommendation results. For example, establishing a package matching model can achieve dynamic adjustment of model parameters using configurable rule templates, supporting differentiated modeling for different user groups. This introduces an explicit logical judgment mechanism to supplement the implicit association mining of the machine learning model.
[0083] In one specific embodiment, the package matching degree model can be a mathematical model that integrates multi-dimensional indicators to quantify the degree of compatibility between users and electricity packages. Its calculation process is based on setting weight parameters according to user needs and preferences, and combining the estimated monthly electricity cost of the package, the matching degree between user electricity usage habits and the package's electricity price structure, and the package's flexibility score for weighted calculation. Furthermore, this model can be implemented using one or more of the following methods: linear weighted matching model, analytic hierarchy process (AHP) matching model, and fuzzy comprehensive evaluation model.
[0084] The estimated monthly electricity cost of a service package can be a predicted monthly electricity expenditure based on the user's current electricity consumption patterns and the package's pricing rules, reflecting the package's economic attractiveness. In this embodiment, the estimated monthly electricity cost of the package can be obtained through simulation calculation using real-time electricity consumption data and the package's rate structure. Furthermore, the estimated monthly electricity cost of the package may include, but is not limited to, one or more of the following: basic electricity cost, cost including additional services, and dynamically adjusted cost.
[0085] The matching degree between user electricity consumption habits and package electricity price structure can be an indicator measuring the degree of overlap between the user's actual electricity consumption time distribution and the time-of-use pricing discount periods of the package. It can be used to assess whether users can fully benefit from the package's pricing mechanism. For example, the matching degree between user electricity consumption habits and package electricity price structure can be obtained by comparing the user's load curve with the package's low-price periods through correlation analysis or overlap rate calculation. Furthermore, the matching degree between user electricity consumption habits and package electricity price structure can include, but is not limited to, one or more of peak-valley matching degree, flat-period utilization rate, and peak-spot avoidance degree. Package flexibility score can be a quantitative indicator describing the convenience of changing, withdrawing from, or adjusting usage of the electricity package. It can be used to reflect the impact of non-price factors on user experience. In an exemplary embodiment, the package flexibility score can be assigned by a rule engine or generated manually based on the package contract terms and service policies. Furthermore, the package flexibility score can include, but is not limited to, one or more of contract freedom score, change convenience score, and breach of contract cost score. Weighting coefficients can be parameters used to adjust the relative importance of each component in the matching degree model. They can be used to achieve personalized weighting, making the model output more aligned with individual priorities. In this embodiment, the weighting coefficient can be automatically configured according to user needs and preferences, or set through the system default strategy. Furthermore, the weighting coefficient may include, but is not limited to, one or more of cost weight, matching degree weight, and flexibility weight, and the sum of the three is equal to 1.
[0086] The optimal electricity retail package is determined based on the overall matching degree of the package and the recommendation score of each electricity retail package, and then the optimal electricity retail package is pushed to the user's terminal as a recommendation result.
[0087] The overall matching degree of the electricity package can be a numerical value representing the overall compatibility level between a user and a certain electricity package, output by a matching degree model. This value can be used to further filter the optimal option among multiple highly recommended packages. In one specific embodiment, the overall matching degree can integrate information from three dimensions: economy, behavioral matching, and usage flexibility, calculated using a weighted formula. Determining the optimal electricity retail package based on the overall matching degree and the recommendation scores of each electricity retail package can be achieved by jointly ranking the recommendation scores and matching degree results, selecting the one with the highest matching degree from the high-scoring candidate set, thus implementing a two-layer screening mechanism. Furthermore, this operation can be achieved by setting a threshold screening condition, pushing the package only when the matching degree exceeds a certain level; or by using a fusion function to unify the units and then summing them, ensuring that the final recommendation balances model prediction accuracy and business interpretability.
[0088] For example, in a scenario where industrial and commercial users are optimizing and upgrading their electricity retail packages, the electricity retail package recommendation method in this embodiment could be as follows: A small manufacturing enterprise was originally using a fixed-price electricity package. The system, through analysis of its recent load data, discovered an increase in nighttime production. The recommendation model outputs multiple time-of-use electricity packages with high recommendation scores. Simultaneously, the system constructs a matching degree model based on the user's preferences, such as "desiring to reduce electricity cost fluctuations" and "accepting some adjustments to electricity usage plans," submitted on the service platform. Calculations show that although a certain off-peak discount package has a slightly lower recommendation score, its electricity price structure closely matches the current nighttime peak electricity consumption, and the contract allows for monthly capacity adjustments, resulting in a high flexibility score and ultimately the best overall matching degree. The system pushes this package as the final recommendation to the enterprise's management terminal, achieving more precise service matching.
[0089] This embodiment introduces a package matching degree model based on user needs and preferences on top of the initial recommendation. It combines the estimated monthly electricity cost of the package, the matching degree between user electricity consumption habits and electricity price structure, package flexibility score and adjustable weights to generate a comprehensive package matching degree. The matching degree is then used to perform a secondary ranking of candidate packages with high recommendation scores to determine the optimal recommendation scheme. This makes the recommendation process not only rely on data-driven model output, but also integrate multi-dimensional adaptation evaluation based on user subjective value orientation. This can achieve the technical effect of enhancing the personalization capability and decision-making transparency of the recommendation system, and improving user satisfaction and adoption rate of recommendation results.
[0090] Furthermore, embodiments of the present invention also propose a storage medium storing an electricity retail package recommendation program, which, when executed by a processor, implements the steps of the electricity retail package recommendation method described above.
[0091] In addition, refer to Figure 3 This invention also proposes an electricity retail package recommendation system, which includes: Data processing module 10 is used to acquire users' historical electricity consumption data through smart meters or power data acquisition terminals, perform noise reduction and outlier processing on the historical electricity consumption data, and construct user electricity consumption sample data. Feature annotation module 20 is used to obtain user attribute data and electricity retail package attribute data, and add user electricity consumption feature tags to the user electricity consumption sample data; Model training module 30 is used to train a package recommendation model using the electricity consumption sample data and user electricity consumption feature labels; The recommendation generation module 40 is used to obtain the current user's real-time electricity consumption data and user attribute data as input data for the package recommendation model, output the recommendation score of each electricity retail package through the package recommendation model, and push the electricity retail package with the highest recommendation score as the recommendation result to the user terminal.
[0092] Other embodiments or specific implementations of the electricity retail package recommendation system of the present invention can be referred to the above-described method embodiments, and will not be repeated here.
[0093] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.
[0094] The sequence numbers of the above embodiments of the present invention are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments. In the module claims listing several systems, several of these systems may be specifically embodied by the same hardware item. The use of the terms first, second, and third, etc., does not indicate any order and can be interpreted as names.
[0095] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as a read-only memory image (ROM) / random access memory (RAM), magnetic disk, optical disk), and includes several instructions to cause a terminal user device (which may be a mobile phone, computer, server, air conditioner, or network user device, etc.) to execute the methods described in the various embodiments of the present invention.
[0096] The above are merely preferred embodiments of the present invention and do not limit the scope of the patent. Any equivalent structural or procedural transformations made based on the description and drawings of the present invention, or direct or indirect applications in other related technical fields, are similarly included within the scope of patent protection of the present invention.
Claims
1. A method for recommending electricity retail packages, characterized in that, The method includes: Historical electricity consumption data of users is obtained through smart meters or power data acquisition terminals. Noise removal and outlier processing are performed on the historical electricity consumption data to construct user electricity consumption sample data. Obtain user attribute data and electricity retail package attribute data, and add user electricity consumption feature tags to the user electricity consumption sample data; The package recommendation model is trained using the electricity consumption sample data and user electricity consumption feature tags. The system acquires real-time electricity consumption data and user attribute data of the current user and uses them as input data for the package recommendation model. The model then outputs recommendation scores for each electricity retail package and pushes the electricity retail package with the highest recommendation score to the user terminal.
2. The method for recommending electricity retail packages as described in claim 1, characterized in that, The step of denoising and outlier processing of the historical electricity consumption data to construct user electricity consumption sample data includes: The historical electricity consumption data is converted into an electricity consumption embedding matrix according to the time series. The electricity consumption embedding matrix is decomposed into an electricity consumption matrix. The electricity consumption matrix with singular values greater than 0 is used to form an electricity consumption component matrix. The electricity consumption component matrix is converted into an electricity consumption time series by diagonal averaging. The electricity consumption time series is transformed to the frequency domain to obtain electricity consumption spectrum data. The electricity consumption spectrum data is divided to obtain continuous intervals of peak, flat and valley electricity consumption. Within the continuous intervals, an electricity consumption scaling function is constructed to obtain electricity consumption detail coefficients and electricity consumption approximation coefficients. The signal is reconstructed based on the electricity consumption detail coefficients and electricity consumption approximation coefficients to obtain electricity consumption components. Calculate the correlation coefficient of the electricity consumption components, and merge the electricity consumption components with the correlation coefficient greater than a preset coefficient threshold into user electricity consumption sample data, wherein the correlation coefficient is the Pearson correlation coefficient between the electricity consumption components.
3. The method for recommending electricity retail packages as described in claim 2, characterized in that, The formula for calculating the power consumption component by reconstructing the signal based on the power consumption detail coefficients and the power consumption approximation coefficients is as follows: ; in, For electrical components, For electricity consumption detail factors, This is an approximation factor for electricity consumption. For Fourier transform, For electricity consumption scale function, The time length of the continuous interval. For component counting, This represents the number of categories of electricity consumption components.
4. The method for recommending electricity retail packages as described in claim 1, characterized in that, The process of acquiring user attribute data and electricity retail package attribute data, and adding user electricity consumption feature tags to the user electricity consumption sample data, includes: Obtain user attribute data and electricity retail package attribute data; add user electricity consumption feature tags to the user electricity consumption sample data based on the user attribute data; and define peak-valley electricity consumption difference rate. ; in, Peak-valley electricity consumption differential rate Peak electricity consumption Electricity consumption during off-peak hours Electricity consumption for the flat section; If the peak-valley electricity consumption difference rate is greater than the first preset peak-valley electricity consumption difference rate, then the user electricity consumption feature tag is set to -1; if the peak-valley electricity consumption difference rate is greater than or equal to the second preset peak-valley electricity consumption difference rate and less than or equal to the first preset peak-valley electricity consumption difference rate, then the user electricity consumption feature tag is set to 0; if the peak-valley electricity consumption difference rate is less than the second preset peak-valley electricity consumption difference rate, then the user electricity consumption feature tag is set to 1; wherein, the first preset peak-valley electricity consumption difference rate is greater than the second preset peak-valley electricity consumption difference rate; The user electricity consumption feature tags are added to the electricity consumption sample data; the user attribute data includes user type, total power of electrical equipment, average electricity consumption duration, and peak-valley electricity consumption ratio; the electricity retail package attribute data includes package type, benchmark electricity price, peak-valley time period division, and discount rate.
5. The method for recommending electricity retail packages as described in claim 1, characterized in that, The step of training a package recommendation model using the electricity consumption sample data and user electricity consumption feature tags includes: The electricity consumption sample data and user electricity consumption feature labels are input into a deep collaborative filtering network. In the deep collaborative filtering network, the user ID and package ID are mapped into low-dimensional dense vectors through an embedding layer. The nonlinear features of the input data are extracted by a multilayer perceptron to obtain feature mapping. The feature mapping is then dimensionality-reduced to obtain a user-package feature mapping set. Establish a package recommendation model, and initialize the weight matrix and bias vector of the package recommendation model to obtain the initial parameter vector and prediction score vector; Based on the user-package feature mapping set, a parameter vector is obtained. If the loss function value corresponding to the parameter vector in the next iteration is less than or equal to the preset loss function value, then the parameter vector is used as the update parameter vector; if the loss function value is less than or equal to the preset loss function value, then the initial parameter vector is used as the update parameter vector. Calculate the prediction error value of the parameter vector, where the prediction error value is the difference between the predicted score and the actual score. If the prediction error value is greater than a preset error value, then update the parameter vector at the next time step based on the initial parameter vector. The model parameters corresponding to the parameter vectors after iteration are used to construct a model parameter set, which is used to characterize the package recommendation model.
6. The method for recommending electricity retail packages as described in claim 5, characterized in that, The step of extracting nonlinear features from the input data using a multilayer perceptron to obtain a feature map includes: The number of neurons in the hidden layer of the multilayer perceptron is set according to the input data. The nonlinear interactive features of the input data are extracted using an activation function to obtain the feature map. The calculation formula is as follows: ; in, The size of the feature mapping matrix, For the input data dimensions, This represents the number of neurons in the hidden layer. Step size, The number of hidden layers. Let g be the m-th feature map, and g be the activation function. Let m be the weight matrix of the m-th eigenmap. For input data, This is the bias vector.
7. The method for recommending electricity retail packages as described in claim 1, characterized in that, The process of acquiring the current user's real-time electricity consumption data and user attribute data as input data for the package recommendation model, outputting recommendation scores for each electricity retail package through the package recommendation model, and pushing the electricity retail package with the highest recommendation score as the recommendation result to the user terminal, further includes: Obtain user needs and preferences, and establish a package matching degree model based on user needs and preferences. The calculation formula for the package matching degree model is as follows: ; in, For the overall suitability of the package, These are the weighting coefficients. , Estimate the monthly electricity cost for the package. To ensure the compatibility between users' electricity consumption habits and the electricity pricing structure of the packages, Rate the flexibility of the package; The optimal electricity retail package is determined based on the overall matching degree of the package and the recommendation score of each electricity retail package, and the optimal electricity retail package is pushed to the user terminal as a recommendation result.
8. A power retail package recommendation system, characterized in that, The electricity retail package recommendation system includes: The data processing module is used to acquire users' historical electricity consumption data through smart meters or power data acquisition terminals, perform noise reduction and outlier processing on the historical electricity consumption data, and construct user electricity consumption sample data. The feature annotation module is used to acquire user attribute data and electricity retail package attribute data, and add user electricity consumption feature tags to the user electricity consumption sample data. The model training module is used to train a package recommendation model using the electricity consumption sample data and user electricity consumption feature labels; The recommendation generation module is used to obtain the current user's real-time electricity consumption data and user attribute data as input data for the package recommendation model. The package recommendation model outputs the recommendation score of each electricity retail package, and pushes the electricity retail package with the highest recommendation score as the recommendation result to the user terminal.
9. A device for recommending electricity retail packages, characterized in that, The electricity retail package recommendation device includes: a memory, a processor, and an electricity retail package recommendation program stored on the memory and executable on the processor, the electricity retail package recommendation program being configured to implement the steps of the electricity retail package recommendation method as described in any one of claims 1 to 7.
10. A storage medium, characterized in that, The storage medium stores a program for recommending electricity retail packages, which, when executed by a processor, implements the steps of the electricity retail package recommendation method as described in any one of claims 1 to 7.
Citation Information
Cited By
Power contract recommendation method and system fusing dynamic electricity price and user portrait
CN121903671A