A method and system for generating user power consumption data
By generating user electricity consumption event sequence groups and combining them with an appliance curve database, the problem of difficulty in obtaining electricity consumption data was solved, and the accuracy and efficiency of the power grid optimization model were improved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HUADA SEMICON CO LTD
- Filing Date
- 2026-04-13
- Publication Date
- 2026-07-07
AI Technical Summary
In existing technologies, it is difficult to obtain a large amount of high-frequency sampling electricity consumption curve data that conforms to users' electricity consumption habits, resulting in insufficient training set data for power grid optimization models, which affects the accuracy and efficiency of the algorithm.
By generating electricity consumption event sequence groups based on user profile annotation data, and combining them with a pre-set appliance curve database, total electricity consumption curve data is generated. The generation process is optimized using sequence generation models and reward models to ensure the logicality and accuracy of the data.
It generated a large amount of electricity consumption curve data that conforms to users' electricity consumption logic, which improved the accuracy and reliability of load forecasting and scheduling analysis of the power grid optimization model and reduced the dependence on actual data acquisition terminals.
Smart Images

Figure CN122346684A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of electrical technology, and in particular to a method and system for generating user electricity consumption data. Background Technology
[0002] Training electrical-related algorithms, especially power grid optimization models, often requires a large amount of user electricity consumption curve data that is consistent with users' electricity usage habits, involves long-term, high-frequency sampling, and has clear labels indicating changes in appliance status. If the amount of training data is insufficient, it will affect the performance of the algorithm and model, and consequently, the accuracy, cost, and efficiency of power grid optimization based on the algorithm and model will be significantly affected.
[0003] However, due to limitations such as data privacy and device performance, it is often difficult to obtain training data that meets the training requirements. Therefore, in the current process of training deep learning models, the sampling frequency of the data used is usually one sampling point every 15 minutes, or at most one sampling point every minute. The amount of data collected in this way is far from meeting the data sampling rate required for training deep learning algorithms. The commonly used methods for obtaining high-frequency user electricity consumption data are mainly two types: in-home collection and random appliance operation sequence. In-home collection refers to installing equipment in users' homes or having users provide information annotations. However, this method is time-consuming, has low brand / model coverage, and users may not be willing to share their detailed household electricity consumption behavior due to privacy concerns. This makes it difficult to collect data on a large scale, and the publicly available dataset size is limited. Random appliance operation sequence refers to randomly superimposing the start and stop of appliances, but it cannot reflect user behavior patterns. It can only be used as data augmentation for existing data and cannot reconstruct a logically consistent electricity consumption curve. Summary of the Invention
[0004] To address some or all of the problems in existing technologies, and to solve the problem of insufficient training set data due to the difficulty in obtaining large amounts of user electricity consumption data, the first aspect of this invention provides a method for generating user electricity consumption data, comprising: Several electricity consumption event sequence groups are generated based on user profile annotation data. The user profile annotation data includes at least one tag data, which is used to describe the user's user characteristics, lifestyle habits, or electricity consumption preferences. Each electricity consumption event sequence group includes at least one electricity consumption time sequence, and each electricity consumption event sequence includes an appliance identifier, appliance type, start time, and duration. Based on the electricity consumption event sequence group and combined with the preset appliance curve database, at least one total electricity consumption curve data of the user is generated, wherein the preset appliance curve database includes the operating cycle power curve data of at least one appliance.
[0005] Furthermore, several electricity consumption event sequence groups are generated based on user profile annotation data, including: Obtain user profile annotation data; Convert the user profile annotation data into structured query conditions; The structured query conditions are input into a pre-trained sequence generation model to generate several sets of electricity consumption event sequences.
[0006] Furthermore, based on the remaining electricity consumption event sequence groups and combined with a preset appliance curve database, at least one total electricity consumption curve data for the user is generated, including: Based on the appliance identifiers in the electricity consumption event sequence group, the operating cycle power curve data corresponding to each appliance identifier is retrieved from the preset appliance curve database. Based on the power curve data of the operating cycle, generate the total power consumption curve data corresponding to each target power consumption event sequence group.
[0007] Furthermore, based on the electricity consumption event sequence group and combined with a preset appliance curve database, generating at least one total electricity consumption curve data for the user includes: Based on the start time and duration of each power consumption event sequence in the remaining power consumption event sequence group, the operating cycle power curve data corresponding to the appliance identifier is trimmed to obtain the trimmed power curve data. Starting from the start time and ending from the duration in the power consumption event sequence, the cropped power curve data is superimposed one by one onto the initial total power consumption curve data to obtain the total power consumption curve data. The values corresponding to each time point in the initial total power consumption curve data are 0, and the total time length is a preset time value.
[0008] Furthermore, the generation method also includes: Before generating at least one total electricity consumption curve data for the user, each electricity consumption event sequence is scored, and the cumulative reward value of each electricity consumption event sequence group is determined. Electricity consumption event sequence groups with cumulative reward values lower than a preset threshold are deleted.
[0009] Furthermore, determining the cumulative reward value for each electricity consumption event sequence group includes: The cumulative reward value is obtained by summing the scores of all electricity consumption event sequences in a group of electricity consumption event sequences.
[0010] Furthermore, using the pre-trained sequence generation model, several electricity consumption event sequence groups are generated based on user profile annotation data; The pre-trained reward model scores each sequence of electricity consumption events.
[0011] Furthermore, the pre-training of the sequence generation model and the reward model includes: Construct an initial sequence generation model and an initial reward model; Obtain a first training dataset, wherein the first training dataset includes at least one first training data sample, and the first training data sample includes first image annotation data; Based on the first profile annotation data, multiple first electricity consumption event sequence groups are generated through the initial sequence generation model; Using the initial reward model, the rationality of each first electricity consumption event sequence is judged according to the preset scoring rules, and the reward value and textual reason for each first electricity consumption event sequence are obtained. With the goal of maximizing multiple cumulative reward values, the initial sequence generation model is optimized according to the near-end policy optimization algorithm to obtain the sequence generation model; Based on the reward value, textual reason, and correction data corresponding to each first electricity consumption event sequence, the initial reward model is optimized to obtain the reward model, wherein the correction data is the result data of manual sampling inspection of the reward value and textual reason.
[0012] Furthermore, constructing the initial sequence generation model includes: Obtain a second training dataset, wherein the second training dataset includes at least one second training data sample, and the second training data sample includes second profile annotation data and second behavior log data corresponding to the second profile annotation data; Using the second profile annotation data as the first input data, the second behavior log sample data as the label of the first input data, and the electricity consumption event sequence group as the expected output, the first basic large language model is trained to obtain the initial sequence generation model.
[0013] Furthermore, constructing the initial reward model includes: Obtain a third training dataset, wherein the third training dataset includes at least one third training data sample, the third training data sample includes third profile annotation data, a third electricity event sequence group generated by the initial sequence generation model based on the third profile annotation data, a third human score and a third human reason annotation obtained by making a reasonable judgment on each third electricity event sequence in the third electricity event sequence group based on the preset scoring rules. Using the third profile annotation data and the third electricity consumption event sequence group as the second input data, the third human rating and the third human reason annotation as the labels of the second input data, and the reward value of each third electricity consumption event sequence, the text reason, and the cumulative reward value of each third electricity consumption event sequence group as the expected output, the second basic large language model is trained to obtain the initial reward model.
[0014] A second aspect of the present invention provides a system for generating user electricity consumption data, comprising: The sequence generation module is used to generate several electricity consumption event sequence groups based on user profile annotation data, wherein the user profile annotation data includes at least one tag data, the tag data is used to describe the user's user characteristics, living habits, or electricity consumption preferences, and each electricity consumption event sequence group includes at least one electricity consumption time sequence, each of the electricity consumption event sequences including appliance identifier, appliance type, start time, and duration; The curve generation module is used to generate at least one total electricity consumption curve data for the user based on a sequence of electricity consumption events and a preset appliance curve database, wherein the preset appliance curve database includes the operating cycle power curve data of at least one appliance.
[0015] Based on the generation method described above, a third aspect of the present invention provides an electronic device for generating user electricity consumption data, comprising a memory and a processor, wherein the memory is configured to store a computer program that executes the training set generation method described above when the processor is running.
[0016] A fourth aspect of the present invention also provides a computer-readable storage medium for generating user electricity consumption data, which stores a computer program that, when run on a processor, executes the generation method as described above.
[0017] Based on the generation method described above, a fifth aspect of the present invention provides a power grid optimization method, comprising: The training set is generated based on the generation method described above; The initial power grid optimization model is trained based on the training set to obtain the power grid optimization model; Based on the collected user electricity consumption data, the power grid optimization model predicts the power grid load and determines the power grid adjustment strategy, wherein the power grid adjustment strategy includes the power load regulation method for each area of the power grid.
[0018] This invention provides a method and system for generating user electricity consumption data. It generates user electricity consumption event sequences from a small amount of user profile annotation data, and then inserts a small number of preset appliance curves in a jigsaw-like manner to generate a large amount of electricity consumption curve data that conforms to user electricity consumption logic. This solves the technical problem of the difficulty in obtaining large amounts of user electricity consumption data in existing technologies. Training a power grid optimization model using the training set generated by this method can effectively improve the accuracy and reliability of its load forecasting and scheduling analysis, thereby improving the efficiency and accuracy of power grid optimization. Attached Figure Description
[0019] To further illustrate the above and other advantages and features of the various embodiments of the present invention, a more specific description of the various embodiments of the present invention will be presented with reference to the accompanying drawings. It is to be understood that these drawings depict only typical embodiments of the invention and are therefore not intended to limit its scope. In the drawings, identical or corresponding parts will be indicated by identical or similar reference numerals for clarity.
[0020] Figure 1 This diagram illustrates a flowchart of a method for generating user electricity consumption data sets according to an embodiment of the present invention. Figure 2 This diagram illustrates a pre-training method for a sequence generation model and a reward model according to an embodiment of the present invention. Figure 3 This diagram illustrates the structure of a user electricity consumption data generation system according to an embodiment of the present invention. Figure 4 The diagram shows a flowchart of a power grid optimization method according to an embodiment of the present invention. Detailed Implementation
[0021] In the following description, the invention is described with reference to various embodiments. However, those skilled in the art will recognize that the embodiments may be practiced without one or more specific details or with other alternatives and / or additional methods, materials, or components. In other instances, well-known structures, materials, or operations are not shown or described in detail so as not to obscure the inventive points of the invention. Similarly, for illustrative purposes, specific quantities, materials, and configurations are set forth to provide a comprehensive understanding of embodiments of the invention. However, the invention is not limited to these specific details. Furthermore, it should be understood that the embodiments shown in the drawings are illustrative representations and are not necessarily drawn to scale.
[0022] In this specification, references to "an embodiment" or "this embodiment" mean that a particular feature, structure, or characteristic described in connection with that embodiment is included in at least one embodiment of the invention. The phrase "in one embodiment" appearing throughout this specification does not necessarily refer to the same embodiment in all instances.
[0023] It should be noted that the embodiments of the present invention describe the method steps in a specific order; however, this is only for illustrating the specific embodiment and not for limiting the order of the steps. On the contrary, in different embodiments of the present invention, the order of the steps can be adjusted according to actual needs.
[0024] It should be noted that the dashed boxes in the accompanying drawings indicate modules or steps that can be omitted.
[0025] To address the problems of limited real-user electricity consumption data, sparse samples, insufficient data coverage, and incomplete dimensions in existing technologies, which make it difficult to obtain large-scale, continuous, and accurate electricity consumption data, resulting in poor model training performance and consequently low accuracy and reliability in power grid load forecasting and scheduling analysis, this invention provides a method and system for generating user electricity consumption data. It employs reinforcement learning (RL) to generate user behavior sequences instead of manually labeled event sequences, and then uses a small number of real appliance periodic curves for piecemeal insertion, ultimately producing batch-labeled appliance curves that are brand-changeable and conform to human electricity consumption logic. Through data processing and machine learning techniques, based on user profiles, it learns and generates a large amount of accurate electricity consumption data, effectively expanding the scale of the electricity consumption data training set, improving data integrity, continuity, and accuracy, reducing dependence on the number of actual data collection terminals, and effectively improving the accuracy and reliability of power grid load forecasting and scheduling analysis, thereby optimizing the power grid. The method and system do not directly generate continuous power signals, but rather generate logical sequences and then stitch them together with physical curves, ensuring the authenticity of power patterns and physical laws. It employs human feedback reinforcement learning (RLHF) to learn complex behavioral logic and can also overcome the instability of traditional curve generation routes.
[0026] The technical solution of the present invention will be further described below with reference to the accompanying drawings of the embodiments.
[0027] Figure 1 This diagram illustrates a flowchart of a method for generating user electricity consumption data according to an embodiment of the present invention. Figure 1 As shown, a method for generating user electricity consumption data includes: First, in step 101, a series of electricity consumption events are generated. Several series of electricity consumption events are generated based on user profile annotation data, wherein the user profile annotation data includes at least one tag data, which includes user characteristic tags, lifestyle habit tags, and electricity consumption preference tags, used to describe the user's user characteristics, lifestyle habits, electricity consumption preferences, etc.
[0028] In one embodiment of the present invention, the user profile annotation data is obtained through actual in-home collection or surveys, such as in-home collection, questionnaires, and user registration information. Specifically, through actual in-home collection or surveys, a small amount of user profile annotation data and user behavior log data are obtained. The user profile annotation data includes information such as user characteristics, lifestyle habits, electricity usage preferences, date type, weather, and region. These tags can be added or removed according to actual circumstances. Among them, user characteristics mainly cover basic demographic information, such as age, gender, and occupation. Users with different characteristics have different needs and usage patterns for electrical appliances. For example, young people may prefer smart appliances, and office workers and freelancers have different electricity usage patterns. Lifestyle habits can mainly include work and rest schedules and electricity usage preferences. For example, early risers may use kettles and soymilk makers frequently in the morning, while late-night users use electricity for longer periods at night. Electricity usage preferences can reflect users' preferences for appliance types, brands, functions, etc. For example, users who enjoy cooking will frequently use kitchen appliances, and users who value energy conservation will prioritize energy-efficient appliances. The user behavior log data includes appliance operation information and appliance operation motivation information, mainly recording detailed records of the user's use of home appliances, reflecting the user's electricity consumption behavior. Appliance operation information can include operation type (e.g., turning on, turning off, adjusting settings, switching modes), appliance type (e.g., refrigerator, air conditioner, washing machine, vacuum cleaner), and operation time information (e.g., specific time and time period). Appliance operation motivation information can include, for example, daily needs such as heating, increasing air humidity, and special events such as frequent use of air conditioning for cooling in hot summer weather or using heating for warmth in cold winter weather.
[0029] After acquiring user profile annotation data, multiple electricity consumption event sequence groups are generated based on it. Each electricity consumption event sequence is a series of electricity-related events generated from the user profile annotation data, arranged in a specific order. Each electricity consumption event sequence includes an appliance identifier, appliance type, start time, and duration, and may include operations such as turning the appliance on, off, and adjusting its power, reflecting the user's electricity consumption behavior at different times. The format of each electricity consumption event sequence can be {appliance_id, type, on / off, start_time, reason}. For example, one electricity consumption event sequence might be: Secondary Bedroom Light 01, Lighting, Off, 2025-02-14 00:15:00, User is asleep; another electricity consumption event sequence might be: Secondary Bedroom Bed 02, Air Conditioner, On, 2025-02-14 06:51:00, Weather is cold, Preheat room to 26℃. An electricity consumption event sequence group is a collection of multiple electricity consumption event sequences.
[0030] In one embodiment of the present invention, multiple electricity consumption event sequence groups are generated through a pre-trained sequence generation model. Specifically, after acquiring user profile annotation data, the user profile annotation data is first cleaned, organized, and transformed according to pre-set rules and formats. Unstructured text information is converted into structured data format, the logical relationships between various data are determined, and structured query conditions are formed. Then, the structured query conditions are input into the pre-trained sequence generation model to generate several electricity consumption event sequence groups. The structured query conditions are standardized data forms that can be recognized and processed by the sequence generation model after the profile annotation data is organized and transformed according to certain rules and formats. The structured query conditions present the user's key information in a structured manner, making it convenient for the model to quickly and accurately obtain the required content. For example, user profile annotation data may contain "age: 30 years old, occupation: office worker, residence region: southern coastal city, electricity preference: energy-saving appliances", which can be transformed into the corresponding structured query conditions "age=30, occupation=office_worker, region=southern_coastal_city, electricity preference=energy_efficient". Structured query criteria enable sequence generation models to more easily and accurately acquire and process user information. Through standardized data formats, the model can quickly understand user characteristics and needs, improving the efficiency and accuracy of generating electricity consumption event sequences.
[0031] The sequence generation model is a large language model pre-learned using extensive training data, including user profile annotation data and user behavior logs. Based on the input structured query conditions, user feature information, and its internally learned user behavior patterns and rules, the model generates multiple sets of electricity consumption event sequences that match the user's characteristics. Each set contains multiple electricity consumption event sequences. These sequences simulate the electricity consumption behaviors that users may exhibit in different scenarios. The model uses user profile annotation data as guiding words to capture patterns and scales in user electricity consumption behavior, thereby generating reasonable and diverse electricity consumption events. Each electricity consumption event sequence is a series of electricity-related events arranged chronologically and may include appliance identifiers (unique appliance numbers), appliance type, start time (the time the appliance starts running), and duration (the time elapsed from start to stop), among other information. Sequence generation models can learn complex patterns and rules of user electricity consumption behavior using a large amount of training data, thereby generating diverse and reasonable sequences of electricity consumption events. This provides rich data samples for subsequent analysis of user electricity consumption patterns and prediction of electricity load, which helps to improve the planning, scheduling and optimization of the power system.
[0032] Finally, in step 103, electricity consumption curve data is generated. Based on the generated electricity consumption event sequence group and combined with a preset appliance curve database, at least one total electricity consumption curve data for the user is generated, wherein the preset appliance curve database includes the operating cycle power curve data of at least one appliance. In one embodiment of the present invention, complete operating cycle power curve data of multiple appliances are collected in the laboratory, mainly collecting complete operating cycle power curves of multiple brands and multiple appliances in multiple states, such as the complete process of power-on → steady state → power-off. Each curve only needs to be collected once. The set of complete operating cycle power curve data of multiple appliances can be used to construct the preset appliance curve database. That is, the preset appliance curve database contains the power changes of various appliances under different operating states, such as the power curves of air conditioners under different temperature settings and different operating modes, and the power curves of refrigerators under different time periods and different load conditions. The data in the preset appliance curve database can provide a basic reference for generating the user's total electricity consumption curve data.
[0033] In one embodiment of the present invention, in order to make the generated data more in line with the user's actual electricity consumption habits and needs, step 102 is required before generating the electricity consumption curve data to determine the cumulative reward value.
[0034] In step 102, the cumulative reward value is determined. Each electricity consumption event sequence is scored, and the cumulative reward value for each electricity consumption event sequence group is determined. Specifically, each electricity consumption event sequence is scored to obtain a reward value and a textual explanation for each sequence. Then, the reward values of all electricity consumption event sequences in each sequence group are summed to obtain the cumulative reward value for each sequence group. The reward value is a quantitative score of the rationality of a single electricity consumption sequence, such as 1 point for rationality and -1 point for unreasonableness. It is used to measure the rationality and degree of conformity to expectations of each electricity consumption event sequence, reflecting its quality, such as energy efficiency and safety. The higher the reward value, the more the electricity consumption event sequence conforms to the user's actual electricity consumption habits and needs, and the more likely it is to generate accurate total electricity consumption curve data. The textual explanation is explanatory text that indicates the basis for the scoring, such as prohibiting the use of electric heaters in single-person apartments or not needing electric heaters for heating in hot weather. The cumulative reward value is the sum of the reward values of all electricity event sequences in a group of electricity event sequences. For example, if a group of electricity event sequences contains 10 sequences, the cumulative reward value is 8 points, which reflects the overall quality of each group. By scoring each electricity event sequence in each group, the reward value of each sequence is obtained. The cumulative reward value of each group is then summed, allowing subsequent reinforcement learning optimization based on the cumulative reward value to guide the model in exploring higher-quality strategies. In one embodiment of this invention, a pre-trained reward model is used to score each electricity event sequence.
[0035] From multiple electricity consumption event sequence groups, those with a cumulative reward value exceeding a preset threshold are selected as target electricity consumption event sequence groups. These sequence groups are considered to better reflect the user's actual electricity consumption. Based on the appliances involved in each sequence within the target electricity consumption event sequence group, the corresponding appliance's operating cycle power curve data is retrieved from a preset appliance curve database. This operating cycle power curve data is then combined and superimposed to generate multiple total electricity consumption curves for the user over a period of time, such as a whole day. The preset threshold is a pre-defined numerical limit for selecting target electricity consumption event sequence groups, for example, 80 points, which can be adjusted according to actual conditions. Only electricity consumption event sequence groups with a cumulative reward value exceeding this preset threshold are selected as target electricity consumption event sequence groups. The cumulative reward value helps exclude unreasonable or inconsistent electricity consumption event sequence groups, retaining only those high-quality sequence groups more likely to reflect the user's actual electricity consumption behavior, thus ensuring the high quality and reliability of the generated total electricity consumption curve data. The total electricity consumption curve data is generated by integrating target electricity consumption event sequences and a pre-set appliance curve database. It displays the changes in a user's total electricity consumption over a period of time in the form of a curve, intuitively reflecting the user's electricity consumption patterns and load characteristics. By generating electricity consumption event sequences using user profile annotation data and then scoring and filtering these sequences, a large volume of total electricity consumption curve data that better reflects users' actual electricity consumption habits and needs can be generated. Compared to traditional methods based on simple statistics or assumptions, this approach reduces data generation errors and improves data accuracy and reliability by considering users' personalized characteristics and electricity preferences. Furthermore, by generating user electricity consumption event sequences from a small amount of user profile annotation data and then inserting a small number of pre-set appliance curves in a piecemeal fashion, a large volume of electricity consumption curve data that conforms to user electricity consumption logic can be generated, thus solving the technical problem of the difficulty in obtaining large amounts of user electricity consumption data in existing technologies.
[0036] In one embodiment of the present invention, all electricity consumption event sequence groups are first traversed. The cumulative reward value of each electricity consumption event sequence group is compared with a preset threshold, and electricity consumption event sequence groups with a cumulative reward value greater than the preset threshold are selected as target electricity consumption event sequence groups. Then, for each target electricity consumption event sequence group, appliance identifiers are extracted. Based on these appliance identifiers, the categories of all appliances in the sequence are determined. A query is performed in a preset appliance curve database to find all appliances that match the appliance category. The operating cycle power curve data corresponding to one appliance is randomly selected from all appliances. Finally, the operating cycle power curve data of this selected appliance is superimposed on the total electricity consumption curve data to generate the total electricity consumption curve data. The above steps are repeated to generate multiple sets of total electricity consumption curve data that conform to the user's electricity consumption experience.
[0037] By filtering target electricity consumption event sequences, we can focus on users' relatively high-quality electricity consumption behaviors and analyze users' electricity consumption habits and preferences more accurately. By filtering the power curve data of appliance operating cycles, we can determine the power changes of all appliances involved in each target electricity consumption event sequence group during normal operation. This provides detailed appliance power information for the subsequent generation of total electricity consumption curve data, enabling the total electricity consumption curve to accurately reflect the electricity contribution of each appliance.
[0038] In one embodiment of the present invention, generating total power consumption curve data corresponding to each target power consumption event sequence group based on the operating cycle power curve data corresponding to multiple appliance identifiers means that the operating cycle power curve data corresponding to the appliance identifiers is trimmed according to the start time and duration of each target power consumption event sequence in each target power consumption event sequence group to obtain trimmed power curve data. Taking the start time of each target power consumption event sequence as the starting point and the duration as the ending point, each trimmed power curve data is superimposed onto the initial total power consumption curve data to obtain the total power consumption curve data corresponding to each target power consumption event sequence group. In the initial total power consumption curve data, the values corresponding to each time point are 0, and the total time length is a preset time value.
[0039] In one embodiment of the present invention, after determining the operating cycle power curve data of each appliance, the specific process of generating the total power consumption curve data includes: for each target power consumption event sequence group, obtaining the start time and duration of each target power consumption event sequence. Then, in the operating cycle power curve data of the corresponding appliance, finding the position corresponding to the start time as the starting point, and extracting the corresponding power data segment according to the duration, thereby obtaining the trimmed power curve data corresponding to each target power consumption event sequence. The trimmed power curve data is the data obtained after trimming the original operating cycle power curve data, retaining only the power change information within the time period corresponding to the target power consumption event sequence. Since the operating time of appliances differs in different target power consumption event sequences, the trimming operation can extract the power change information of each appliance within the actual operating time period, removing power data from irrelevant time periods, making the subsequent superposition operation more accurate and truly reflecting the power consumption of appliances within a specific time period. Then, the initial total power consumption curve data is determined, with each time point value being 0 and the total time length being a preset time value, such as 24 hours. For each clipped power curve data, based on its corresponding start time, the corresponding time starting point is found in the initial total power consumption curve data. The power value of the clipped power curve data within that time period is added point by point to the corresponding time point value in the initial total power consumption curve data to complete the overlay operation. This operation is repeated to overlay the clipped power curve data corresponding to all target power consumption event sequences in each target power consumption event sequence group onto the initial total power consumption curve data, ultimately obtaining the total power consumption curve data corresponding to each target power consumption event sequence group. By overlaying the electrical power consumption information of appliances in different target power consumption event sequences, the trend of overall power consumption over time when all appliances are running simultaneously within a preset time range can be presented. This provides accurate data support for users to understand their electricity consumption patterns and for power departments to conduct power planning and scheduling.
[0040] This completes the generation of user electricity consumption data. It can be seen that by using the methods described above, only a one-time collection and construction of an appliance operating cycle power curve database and a small amount of user behavior logs are needed to generate an unlimited amount of tagged user electricity consumption data, while ensuring that the generated user electricity consumption sequences conform to human living habits and electrical safety. The appliance operating cycle power curve database can be updated at any time with new appliance brands, and the usage of the new brand in various user behaviors can be directly simulated without affecting the generation model.
[0041] As mentioned above, in one embodiment of the present invention, multiple electricity consumption event sequence groups are generated through a sequence generation model, and the electricity consumption event sequences are scored through a reward model to obtain the reward value and textual reason for the electricity consumption event sequence. Therefore, before generating user electricity consumption data, it is necessary to construct an initial sequence generation model and an initial reward model, and to perform joint reinforcement learning training on the initial sequence generation model and the initial reward model to obtain the final sequence generation model and reward model. Figure 2 This diagram illustrates a flowchart of a pre-training method for a sequence generation model and a reward model according to an embodiment of the present invention. Figure 2 As shown, a pre-training method for a sequence generation model and a reward model includes: First, in step 201, an initial model is constructed. This involves constructing an initial sequence generation model and an initial reward model. In one embodiment of the invention, constructing the initial sequence generation model includes: First, a second training dataset is obtained, wherein the second training dataset includes at least one second training data sample, and the second training data sample includes second profile annotation data and second behavior log data corresponding to the second profile annotation data; Finally, the first basic large language model is trained using the second profile annotation data as the first input data, the second behavior log sample data as the label of the first input data, and the electricity consumption event sequence group as the expected output, to obtain the initial sequence generation model.
[0042] In one embodiment of the present invention, the sequence generation model can be a fine-tuned Large Language Model (LLM) used to generate structured electrical appliance power consumption event sequences based on user profile annotation data. The LLM is trained using a Transformer architecture based on a second training dataset, with the second profile annotation data as input and multiple power consumption event sequence sets as output. The second training dataset is a structured dataset consisting of multiple samples, each containing second profile annotation data and second behavioral log data. The first basic LLM is a pre-trained model using a Transformer architecture, possessing a multi-head self-attention mechanism and a feedforward neural network, supporting sequence-to-sequence generation tasks. The first basic LLM is pre-trained on a large-scale general corpus to master language rules and contextual association capabilities, and is fine-tuned to adapt to the power consumption event sequence generation task. Specifically, a supervised learning task is constructed using second profile annotation data, such as "30 years old - office worker - southern coastal city - energy-saving preference," as input, and second behavioral log data, such as "air conditioner turned on at 14:00 - turned off at 16:00 - average power 1.2kW," as labels. The first basic large language model needs to learn the generation logic from user features to electricity consumption event sequences, outputting sequences that conform to actual behavioral patterns. This first basic large language model is used as the basic architecture, and fine-tuned to adapt to the task. During training, the second profile-annotated data is input, and the model captures the correlation between features through multi-head self-attention. The output layer generates electricity consumption event sequence sets. The loss function uses cross-entropy or mean squared error, and the optimizer adjusts the parameters to minimize the prediction error, thus obtaining the initial sequence generation model after training.
[0043] In one embodiment of the present invention, constructing the initial reward model includes: First, a third training dataset is obtained, wherein the third training dataset includes at least one third training data sample, the third training data sample includes third profile annotation data, a third electricity consumption event sequence group generated by the initial sequence generation model based on the third profile annotation data, a third human score and a third human reason annotation obtained by judging the rationality of each third electricity consumption event sequence in the third electricity consumption event sequence group based on the preset scoring rules, wherein the third human score refers to the human rationality score of each third electricity consumption event sequence according to the preset scoring rules, and the third human reason annotation refers to the human textual explanation of each third electricity consumption event sequence, such as the reason for being unreasonable; Finally, using the third profile annotation data and the third electricity consumption event sequence group as the second input data, and the third human rating and the third human reason annotation as the labels of the second input data, and using the reward value of each of the third electricity consumption event sequences, the text reason, and the cumulative reward value of each of the third electricity consumption event sequence groups as the expected output, the second basic large language model is trained to obtain the initial reward model. In one embodiment of the present invention, the second basic large language model learns the mapping relationship from the profile annotation data and electricity consumption event sequence groups to the reward value and reason through fine-tuning, and outputs structured ratings and natural language explanations, that is, outputs the reward value and text reason of each of the third electricity consumption event sequences, and the cumulative reward value of each of the third electricity consumption event sequence groups. During the training process, multi-task loss functions are used for joint training, such as using mean squared error (MSE) loss to measure the difference between the predicted rating and the human rating, or using cross-entropy loss to measure the semantic similarity between the generated reason and the human reason, etc. Finally, the trained initial reward model is obtained. The initial reward model can generate reasonable reward values and explanations based on user profile annotation data and electricity event sequence groups, providing a core judgment basis for subsequent screening of high-quality electricity event sequence groups. During training, the preset scoring rules are standardized criteria used to evaluate the reasonableness of the generated electricity event sequences. In one embodiment of the invention, the preset scoring rules may include hard-coded rules and soft-coded rules. Hard-coded rules are rigid constraints that cannot be violated, such as setting that the same appliance cannot be turned on twice consecutively; when a hard-coded rule is violated, the score is fixed at -1. Soft-coded rules are quantifiable flexible constraints used to evaluate the sequence's performance in dimensions such as reasonableness, energy efficiency, and user preferences. The scores are usually continuous values, with a range such as [-1, 1], and partial violations are allowed to be compensated through other dimensions, such as 1 point for electricity usage time conforming to user habits, and -1 point for a user's washing machine starting at 2 AM, which violates user habits. In this embodiment, the specific rules of the preset scoring rules are not limited. By ensuring basic security through hard-coded rules and enabling fine-grained optimization through soft-coded rules, a reliable and flexible scoring system can be built to support the intelligent generation and screening of electricity event sequences.
[0044] In one embodiment of the present invention, the reward model can be a hybrid architecture employing a rule engine and a fine-tuned LLM, used to score each electricity consumption event sequence, outputting the reward value, textual reason, and cumulative reward value for each set of electricity consumption event sequences. First, a third training dataset is constructed.
[0045] Next, in step 202, a first training dataset is obtained. The first training dataset includes multiple first training data samples, which include first image annotation data. The first training dataset provides the basic training data for the initial model.
[0046] Next, in step 203, a first electricity consumption event sequence group is generated. The first profile annotation data is input into the initial sequence generation model, and the initial sequence generation model outputs multiple first electricity consumption event sequence groups. Each first electricity consumption event sequence group contains multiple first electricity consumption event sequences.
[0047] Next, in step 204, a rationality assessment is performed. Based on the preset scoring rules, the initial reward model assesses the rationality of each first electricity consumption event sequence within each first electricity consumption event sequence group, calculates the reward value for each first electricity consumption event sequence, and generates corresponding textual reasons. For each electricity consumption event sequence group, the reward values of all electricity consumption event sequences within the group are summed to obtain the cumulative reward value for that electricity consumption event sequence group.
[0048] Next, in step 205, the initial sequence generation model is optimized. With the goal of maximizing multiple cumulative reward values, the initial sequence generation model is optimized using a proximal policy optimization algorithm to generate sequences with higher cumulative rewards, thus obtaining the sequence generation model. The proximal policy optimization algorithm is a reinforcement learning algorithm that updates the model by comparing the probability distributions of the new and old policies, avoiding the high variance problem of traditional policy gradient methods. In one embodiment of the invention, the proximal policy optimization algorithm maximizes the expected cumulative reward while ensuring that the difference between the new and old policies is small. Specifically, policy gradient updates are performed, comparing the probability distributions of the new and old policies. For example, if the probability of the old policy generating sequence A is 0.3 and the probability of the new policy generating sequence A is 0.4, the model parameters are adjusted according to the proximal policy optimization algorithm to increase the probability of sequences with high cumulative reward values and decrease the probability of sequences with low cumulative reward values. Steps 203 to 205 are repeated until the initial sequence generation model converges, for example, when the cumulative reward value no longer increases significantly, resulting in the final sequence generation model.
[0049] Finally, in step 206, the initial reward model is optimized. Based on the reward value, textual justification, and correction data corresponding to each first electricity consumption event sequence, the initial reward model is optimized to obtain the new reward model, thereby improving the evaluation accuracy of the reward model and reducing deviation from human judgment. The correction data refers to the results of a random sampling inspection of the reward values and textual justifications by humans. Specifically, from the reward values and textual justifications corresponding to multiple first electricity consumption event sequences output by the initial reward model, a portion of the reward values and textual justifications for the first electricity consumption event sequences are randomly sampled (e.g., 2% of the total number of sequences sampled). Experts then label the correct values, and this sampled result data is used as the corresponding correction data. The initial reward model is optimized using the sampled reward values, textual justifications, and corresponding correction data for the first electricity consumption event sequences. For example, if the reward value deviation is large (e.g., the model outputs 1 point while the human evaluation is 0 points), the scoring weight of the reward model is adjusted, such as reducing the weight of "power exceeding the limit"; if the textual justification lacks key information (e.g., it does not mention "safety risks"), the model's focus on hard-coded rules is enhanced. Then, the corrected data is added to the training set, and the reward model is retrained until it matches human judgment, thus obtaining the optimized reward model.
[0050] Based on the user electricity consumption data generation method described above. Figure 3 This diagram illustrates the structure of a user electricity consumption data generation system according to an embodiment of the present invention. Figure 3 As shown, a user electricity consumption data generation system includes a sequence generation module 301, a sequence scoring module 302, and a curve generation module 303. The sequence generation module 301 generates several electricity consumption event sequence groups based on user profile annotation data. The user profile annotation data includes at least one tag data, which describes the user's characteristics, lifestyle habits, or electricity consumption preferences. Each electricity consumption event sequence group includes at least one electricity consumption time series, and each electricity consumption event sequence includes an appliance identifier, appliance type, start time, and duration. The sequence scoring module 302 scores each electricity consumption event sequence and determines the cumulative reward value for each electricity consumption event sequence group. The curve generation module 303 generates at least one total electricity consumption curve data for the user based on the electricity consumption event sequence groups and a preset appliance curve database. The preset appliance curve database includes the operating cycle power curve data of at least one appliance.
[0051] In one embodiment of the present invention, the sequence generation module 301 includes a data acquisition submodule, a data conversion submodule, and a sequence generation submodule. The data acquisition submodule acquires user profile annotation data, the data conversion submodule converts the profile annotation data into structured query conditions, and the sequence generation submodule inputs the structured query conditions into a pre-trained sequence generation model to generate multiple electricity consumption event sequence groups. Each electricity consumption event sequence includes an appliance identifier, appliance type, start time, and duration.
[0052] In one embodiment of the present invention, the sequence scoring module 302 includes a first scoring submodule and a cumulative scoring submodule. The first scoring submodule is used to score each electricity consumption event sequence to obtain a reward value for each sequence. The cumulative scoring submodule is used to sum the reward values of all electricity consumption event sequences in each electricity consumption event sequence group to obtain a cumulative reward value for each group. As mentioned above, in some embodiments of the present invention, the sequence scoring module 302 can be omitted, and electricity consumption curve data can be directly generated based on the electricity consumption event sequence groups generated by the sequence generation module 301.
[0053] In one embodiment of the present invention, the curve generation module 303 includes a target determination submodule, a curve filtering submodule, and a curve generation submodule. The target determination submodule is used to determine multiple electricity consumption event sequence groups with accumulated reward values greater than a preset threshold as multiple target electricity consumption event sequence groups. Correspondingly, when the sequence scoring module 302 is omitted, the target determination submodule can also be omitted; in this case, the electricity consumption event sequence group generated by the sequence generation module 301 is directly used as the target electricity consumption event sequence group. The curve filtering submodule is used to determine the operating cycle power curve data corresponding to each appliance identifier in a preset appliance curve database based on the appliance identifier in each target electricity consumption event sequence group. The curve generation submodule is used to generate the total electricity consumption curve data corresponding to each target electricity consumption event sequence group based on the operating cycle power curve data corresponding to multiple appliance identifiers.
[0054] In one embodiment of the present invention, the curve generation submodule includes a curve trimming unit and a curve overlay unit. The curve trimming unit is used to trim the operating cycle power curve data corresponding to the appliance identifier based on the start time and duration of each target electricity consumption event sequence in each target electricity consumption event sequence group, obtaining trimmed power curve data. The curve overlay unit is used to overlay each trimmed power curve data onto the initial total electricity consumption curve data, starting from the start time and ending at the duration in each target electricity consumption event sequence, to obtain the total curve data corresponding to each target electricity consumption event sequence group. The initial total curve data contains a value of 0 for each time point, and the total time length is a preset time value.
[0055] In one embodiment of the present invention, the generation system further includes an initial model building module and a model training module. The initial model building module is used to build an initial sequence generation model and an initial reward model. The model training module is used to perform reinforcement learning training on the initial sequence generation model and the initial reward model to obtain a sequence generation model and a reward model. The sequence generation model is used to generate multiple sets of electricity consumption event sequences, and the reward model is used to score the electricity consumption event sequences to obtain a reward value for each sequence.
[0056] In one embodiment of the present invention, the model training module includes a first training set acquisition submodule, a first generation submodule, a first scoring submodule, a reinforcement training submodule, and a second optimization submodule. The first training set acquisition submodule acquires a first training dataset, which includes multiple first training data samples, each including first profile annotation data. The first generation submodule generates multiple first electricity consumption event sequence groups based on the first profile annotation data using an initial sequence generation model. The first scoring submodule uses an initial reward model to judge the rationality of each first electricity consumption event sequence in each first electricity consumption event sequence group according to preset scoring rules, obtaining a reward value and textual reason for each first electricity consumption event sequence. The reinforcement training submodule optimizes the initial sequence generation model with the objective of maximizing the cumulative reward value of multiple first electricity consumption event sequence groups using a near-end strategy optimization algorithm, obtaining a sequence generation model. The second optimization submodule optimizes the initial reward model based on the reward value, textual reason, and correction data corresponding to each first electricity consumption event sequence, obtaining a reward model; wherein the correction data is the result data of manual sampling of the reward value and textual reason.
[0057] In one embodiment of the present invention, the initial model construction module includes a second training set acquisition submodule and a second training submodule. The second training set acquisition submodule is used to acquire a second training dataset. The second training dataset includes multiple second training data samples, which include second profile annotation data and second behavioral log data corresponding to the second profile annotation data. The second training submodule is used to train a first basic large language model using the second profile annotation data as first input data, the second behavioral log sample data as labels for the first input data, and electricity consumption event sequence groups as the expected output, to obtain an initial sequence generation model.
[0058] In one embodiment of the present invention, the initial model construction module further includes a third training set acquisition submodule and a third training submodule. The third training set acquisition submodule is used to acquire a third training dataset. The third training dataset includes multiple third training data samples, which include third profile annotation data, a third electricity consumption event sequence group generated by an initial sequence generation model based on the third profile annotation data, and third human evaluation scores and third human reason annotations obtained by judging the reasonableness of each third electricity consumption event sequence in the third electricity consumption event sequence group based on preset scoring rules. The third training submodule is used to train a second basic large language model with the third profile annotation data and the third electricity consumption event sequence group as second input data, the third human evaluation scores and third human reason annotations as labels for the second input data, and the reward value, text reason, and cumulative reward value of each third electricity consumption event sequence group as the expected output, to obtain an initial reward model.
[0059] It should be noted that the information interaction and execution process between the modules in the above training set generation system are based on the same concept as the method embodiment of this application. For details on their specific functions and technical effects, please refer to the method embodiment section, which will not be repeated here.
[0060] Based on the generation method described above, the present invention also provides an electronic device for generating user electricity consumption data, comprising a memory and a processor, wherein the memory is configured to store a computer program that executes the generation method described above when the processor is running.
[0061] The present invention also provides a computer-readable storage medium for generating user electricity consumption data, which stores a computer program that executes the generation method described above when running on a processor.
[0062] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the methods of the above embodiments of this application can be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include at least: any entity or device capable of carrying the computer program code to a photographic device / terminal device, a recording medium, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium. Examples include USB flash drives, portable hard drives, magnetic disks, or optical disks.
[0063] The user electricity consumption data generated using the aforementioned generation method and system can be used to create an electricity consumption database. Specifically, this involves organizing, summarizing, and standardizing various types of electricity consumption data from multiple users, such as time-series electricity consumption data, peak-valley electricity consumption data, and regional electricity consumption data, to construct an electricity consumption database containing multi-user electricity consumption data. This electricity consumption database can be used for power grid optimization. For example, it can be applied to power grid load forecasting. Since the database covers daily time-series electricity consumption data, peak-valley electricity consumption data, and historical electricity consumption fluctuation data for different regions and types of users, a load forecasting model can be trained based on the data in the database to obtain the load forecast results for each time period of the power grid in the next 24 hours. Based on these forecast results, the power supply allocation of each power supply line in the power grid can be adjusted to avoid the power supply pressure during peak load periods, balance the power supply load in each time period, and achieve power grid operation optimization.
[0064] For example, based on the electricity consumption database, user electricity consumption data for different time periods and regions can be extracted, the load distribution of the power grid during the morning peak, evening peak and flat periods can be analyzed, areas with excessively high or low loads can be identified, the power supply load ratio of each region of the power grid can be adjusted, and some of the power supply load in areas with excessively high loads can be transferred to areas with low loads, thereby reducing the ineffective losses of power grid lines, reducing power grid operating losses, and achieving power grid optimization.
[0065] For example, the electricity consumption database can be input into the power grid basic optimization module. The power grid basic optimization module can receive multi-user electricity consumption data and perform simple load analysis and calculation. Based on the multi-user electricity load patterns and regional electricity consumption differences in the electricity consumption database, it outputs power grid load control suggestions to guide power grid staff to adjust the power supply strategies of each region, optimize the allocation of power supply periods, and complete the power grid optimization.
[0066] Figure 4 This diagram illustrates a flowchart of a power grid optimization method according to an embodiment of the present invention. Figure 4 As shown, a power grid optimization method includes: First, in step 401, a training set is generated. User electricity consumption data is generated based on the generation method described above and used as the training set; Next, in step 402, the power grid optimization model is trained. Based on the training set, the initial power grid optimization model is trained to obtain the power grid optimization model. Finally, in step 403, power grid optimization is performed. Using the power grid optimization model, based on collected user electricity consumption data, the power grid load is predicted, and a power grid adjustment strategy is determined. This power grid adjustment strategy includes methods for regulating the power supply load in different areas of the power grid.
[0067] This invention provides a method and system for generating user electricity consumption data. By learning and generating a small amount of real electricity consumption data through an artificial intelligence model, a large amount of accurate electricity consumption data is generated, thereby expanding the scale of electricity consumption data, improving data integrity, continuity and accuracy, and reducing dependence on the number of actual data collection terminals. This can effectively improve the accuracy and reliability of power grid load forecasting, scheduling analysis, etc., and thus optimize the power grid.
[0068] Although various embodiments of the invention have been described above, it should be understood that they are presented by way of example only and not as limitations. It will be apparent to those skilled in the art that various combinations, modifications, and alterations can be made without departing from the spirit and scope of the invention. Therefore, the breadth and scope of the invention disclosed herein should not be limited by the exemplary embodiments disclosed above, but should be defined solely by the appended claims and their equivalents.
Claims
1. A method for generating user electricity consumption data, characterized in that, include: Several electricity consumption event sequence groups are generated based on user profile annotation data. The user profile annotation data includes at least one tag data, which includes user characteristic tags, lifestyle tags, and electricity consumption preference tags. Each electricity consumption event sequence group includes at least one electricity consumption time sequence, and each electricity consumption event sequence includes an appliance identifier, appliance type, start time, and duration. Based on the electricity consumption event sequence group and combined with the preset appliance curve database, at least one total electricity consumption curve data of the user is generated, wherein the preset appliance curve database includes the operating cycle power curve data of at least one appliance.
2. The generation method as described in claim 1, characterized in that, Using a pre-trained sequence generation model, several electricity consumption event sequence groups are generated based on user profile annotation data, including: Obtain user profile annotation data; Convert the user profile annotation data into structured query conditions; The structured query conditions are input into the pre-trained sequence generation model to generate several sets of electricity consumption event sequences.
3. The generation method as described in claim 1, characterized in that, Based on the electricity consumption event sequence group and combined with a preset appliance curve database, at least one total electricity consumption curve data for the user is generated, including: Based on the appliance identifiers in the electricity consumption event sequence group, the operating cycle power curve data corresponding to each appliance identifier is retrieved from the preset appliance curve database. Based on the power curve data of the operating cycle, generate the total power consumption curve data corresponding to each target power consumption event sequence group.
4. The generation method as described in claim 1, characterized in that, Based on electricity consumption event sequence groups and combined with a preset appliance curve database, at least one total electricity consumption curve data for the user is generated, including: Based on the start time and duration of each power consumption event sequence in the remaining power consumption event sequence group, the operating cycle power curve data corresponding to the appliance identifier is trimmed to obtain the trimmed power curve data. Starting from the start time and ending from the duration in the power consumption event sequence, the cropped power curve data is superimposed one by one onto the initial total power consumption curve data to obtain the total power consumption curve data. The values corresponding to each time point in the initial total power consumption curve data are 0, and the total time length is a preset time value.
5. The generation method as described in claim 1, characterized in that, Before generating at least one total electricity consumption curve data for the user, each electricity consumption event sequence is scored using a pre-trained reward model, and the cumulative reward value of each electricity consumption event sequence group is determined. Electricity consumption event sequence groups with cumulative reward values lower than a preset threshold are then deleted.
6. The generation method as described in claim 2, characterized in that, The pre-training of the sequence generation model includes: Construct an initial sequence generation model and an initial reward model; Obtain a first training dataset, wherein the first training dataset includes at least one first training data sample, and the first training data sample includes first image annotation data; Based on the first profile annotation data, multiple first electricity consumption event sequence groups are generated through the initial sequence generation model; Using the initial reward model, the rationality of each first electricity consumption event sequence is judged according to the preset scoring rules, and the reward value and textual reason for each first electricity consumption event sequence are obtained. With the goal of maximizing multiple cumulative reward values, the initial sequence generation model is optimized according to the near-end policy optimization algorithm to obtain the sequence generation model; Based on the reward value, textual reason, and correction data corresponding to each first electricity consumption event sequence, the initial reward model is optimized to obtain the reward model, wherein the correction data is the result data of manual sampling inspection of the reward value and textual reason.
7. The generation method as described in claim 6, characterized in that, Building the initial sequence generation model includes: Obtain a second training dataset, wherein the second training dataset includes at least one second training data sample, and the second training data sample includes second profile annotation data and second behavior log data corresponding to the second profile annotation data; Using the second profile annotation data as the first input data, the second behavior log sample data as the label of the first input data, and the electricity consumption event sequence group as the expected output, the first basic large language model is trained to obtain the initial sequence generation model.
8. The generation method as described in claim 6, characterized in that, The initial reward model is constructed as follows: Obtain a third training dataset, wherein the third training dataset includes at least one third training data sample, the third training data sample includes third profile annotation data, a third electricity event sequence group generated by the initial sequence generation model based on the third profile annotation data, a third human score and a third human reason annotation obtained by making a reasonable judgment on each third electricity event sequence in the third electricity event sequence group based on the preset scoring rules. Using the third profile annotation data and the third electricity consumption event sequence group as the second input data, the third human rating and the third human reason annotation as the labels of the second input data, and the reward value of each third electricity consumption event sequence, the text reason, and the cumulative reward value of each third electricity consumption event sequence group as the expected output, the second basic large language model is trained to obtain the initial reward model.
9. A system for generating user electricity consumption data, characterized in that, include: The sequence generation module is configured to generate several electricity consumption event sequence groups based on user profile annotation data, wherein the user profile annotation data includes at least one tag data, the tag data is used to describe the user's user characteristics, living habits, or electricity consumption preferences, and each electricity consumption event sequence group includes at least one electricity consumption time sequence, each of the electricity consumption event sequences including appliance identifier, appliance type, start time, and duration; The curve generation module is configured to generate at least one total electricity consumption curve data for the user based on a sequence of electricity consumption events and a preset appliance curve database, wherein the preset appliance curve database includes the operating cycle power curve data of at least one appliance.
10. A power grid optimization method, characterized in that, include: A training set is generated based on the generation method described in any one of claims 1 to 8; The initial power grid optimization model is trained based on the training set to obtain the power grid optimization model; Based on the collected user electricity consumption data, the power grid optimization model predicts the power grid load and determines the power grid adjustment strategy, wherein the power grid adjustment strategy includes the power load regulation method for each area of the power grid.