Power market collaborative transaction decision-making method and system based on multi-period machine learning
By constructing a cross-market time-series knowledge graph and a multi-agent collaborative negotiation mechanism, and using a multi-time-period machine learning model to generate trading schemes, the problem of insufficient cross-market collaboration in existing power market transactions is solved, and efficient trading decisions are achieved in a multi-market environment.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- YIDIANLIANG (BEIJING) ENERGY TECHNOLOGY CO LTD
- Filing Date
- 2025-11-26
- Publication Date
- 2026-05-05
AI Technical Summary
Existing electricity market trading methods are insufficient in terms of cross-market coordination. The data time-series correlation and the coupling degree of market rules are limited, resulting in defects in the coordination of trading strategies across multiple markets.
By constructing a cross-market time-series knowledge graph, analyzing market characteristics using multi-time period machine learning models, generating trading plans through a multi-agent collaborative negotiation mechanism, and ensuring the feasibility of the strategy through cross-market verification and iterative optimization, unified trading decisions across multiple markets are achieved.
It enhances the adaptability and reliability of trading strategies in multi-market environments, ensures that trading solutions meet the operational constraints and coordination requirements of multiple markets, and improves the overall efficiency of cross-market trading.
Smart Images

Figure CN121213129B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of electricity market trading technology, and in particular to a collaborative trading decision-making method and system for electricity markets based on multi-period machine learning. Background Technology
[0002] Collaborative trading decision-making in the electricity market is one of the core technologies in modern power system operation, and it has significant application prospects in improving market efficiency and ensuring grid security. With the development of multi-market trading models, this method has demonstrated its value in coordinating the operation of spot, futures, and ancillary service markets.
[0003] Existing technologies include power trading decision-making schemes that utilize machine learning to process time-series data. These schemes typically build predictive models based on historical market data and generate trading strategies by analyzing price fluctuation patterns. Some schemes also introduce multi-agent systems for strategy optimization to achieve decision-making coordination among different market participants.
[0004] However, existing methods suffer from limited temporal correlation and market rule coupling when processing heterogeneous data from multiple markets, resulting in insufficient cross-market coordination of the generated trading strategies. Therefore, existing technologies suffer from insufficient cross-market trading coordination. Summary of the Invention
[0005] The methods and systems proposed in this application are based on the physical operating laws of power systems, including but not limited to natural laws such as energy conservation, grid transmission limits, and the temporal characteristics of power generation and load, rather than relying on human factors such as policy planning, market demand, or economic fluctuations.
[0006] This application provides a collaborative decision-making method and system for electricity market transactions based on multi-period machine learning, in order to solve the problem of low collaborative decision-making capability in cross-market electricity transactions in the prior art.
[0007] To address the aforementioned technical problems, in a first aspect, this application provides a collaborative transaction decision-making method for the electricity market based on multi-period machine learning, comprising:
[0008] Collect heterogeneous power data from multiple time periods and markets;
[0009] Based on the heterogeneous power data, the temporal relationships between power plant entities, user entities, and transaction product entities in different markets are established, and a cross-market temporal knowledge graph is constructed based on the temporal relationships.
[0010] The cross-market time-series knowledge graph is traversed in multiple dimensions to extract historical price sequences and real-time supply and demand relationships across markets;
[0011] Based on a machine learning model with a multi-scale processing structure, multi-period feature analysis is performed on the historical price sequence and the real-time supply and demand relationship to obtain market status prediction information.
[0012] Based on the market state prediction information, an initial transaction decision scheme is generated through interactive negotiation among multiple agents.
[0013] The initial trading decision scheme is subjected to cross-market consistency verification and rule compliance checks. Based on the verification and check results, the initial trading decision scheme is optimized through a multi-round iterative optimization mechanism to output a unified trading strategy that satisfies the market constraints and physical constraints of the preset multi-markets.
[0014] Optionally, the step of using a machine learning model with a multi-scale processing structure to perform multi-period feature analysis on the historical price sequence and the real-time supply and demand relationship to obtain market state prediction information includes:
[0015] The historical price quote series is divided into minute-level time series, hour-level time series, and daily-level time series according to the time scale.
[0016] Identify instantaneous fluctuation characteristics from the minute-level time series, identify periodic change characteristics from the hour-level time series, and identify long-term trend characteristics from the daily-level time series;
[0017] Using physical constraints as boundary limitations, feature combinations are performed on the instantaneous fluctuation characteristics, the periodic change characteristics, and the long-term trend characteristics;
[0018] Based on the real-time supply and demand relationship, adjust the weight of each feature in the feature combination result;
[0019] The weighted feature combination results are input into a machine learning model with a multi-scale processing structure to generate minute-level, hour-level, and daily-level market state prediction vectors. The minute-level, hour-level, and daily-level market state prediction vectors are then integrated to form market state prediction information.
[0020] Optionally, the step of inputting the weighted feature combination result into a machine learning model with a multi-scale processing structure to generate minute-level, hourly-level, and daily-level market state prediction vectors, and integrating the minute-level, hourly, and daily-level market state prediction vectors to form market state prediction information, including:
[0021] The weighted feature combination result is input into a machine learning model with a multi-scale processing structure. Through the time scale recognition layer of the machine learning model, the weighted feature combination result is separated into minute-level fluctuation features, hour-level cycle features, and daily-level trend features.
[0022] The first processing branch of the machine learning model performs a temporal convolution operation on the minute-level fluctuation features to obtain the instantaneous change pattern within the minute-level time segment. Based on the instantaneous change pattern, a minute-level state change sequence is formed.
[0023] Through the second processing branch of the machine learning model, the cyclical evolution pattern within the hourly time segment is extracted from the hourly periodic features using the cyclical memory unit, and an hourly state evolution sequence is generated based on the cyclical evolution pattern.
[0024] Through the third processing branch of the machine learning model, long-term dependencies within daily time segments are extracted from the daily trend features using a self-attention mechanism, and a daily state trend sequence is generated based on the long-term dependencies.
[0025] The feature fusion layer of the machine learning model performs feature fusion on the minute-level state change sequence, the hour-level state evolution sequence, and the daily state trend sequence.
[0026] Using the multi-scale prediction head of the machine learning model, based on the fused feature sequence, minute-level market state prediction vectors, hour-level market state prediction vectors, and daily-level market state prediction vectors are generated respectively.
[0027] The time series reconstruction layer of the machine learning model arranges and combines the minute-level market state prediction vector, the hour-level market state prediction vector, and the daily-level market state prediction vector in chronological order to form market state prediction information.
[0028] Optionally, the step of generating an initial trading decision scheme based on the market state prediction information through interactive negotiation among multiple agents includes:
[0029] A large language model based on the Transformer architecture is used to perform semantic parsing on the cross-market temporal knowledge graph to generate market constraints.
[0030] In the first agent of the multi-agent system, a first set of trading operations is generated based on the market constraints; in the second agent of the multi-agent system, a second set of trading operations is generated based on the market state prediction information.
[0031] The intersection of the two sets of transaction operations is calculated through multiple message exchanges between the first and second intelligent agents.
[0032] When the intersection calculation result is not empty, select the transaction operation with the highest priority from the intersection calculation result to form the initial transaction decision scheme;
[0033] Alternatively, when the intersection calculation result is empty, the first agent adjusts the market constraints, the second agent adjusts the expected returns, and the intersection calculation is performed again until the intersection calculation result is non-empty, generating an initial trading decision scheme.
[0034] Optionally, the step of performing cross-market consistency verification and rule compliance checks on the initial trading decision scheme, and optimizing the initial trading decision scheme through a multi-round iterative optimization mechanism based on the verification and check results, to output a unified trading strategy that satisfies the preset market constraints and physical constraints of multiple markets, includes:
[0035] The initial trading decision scheme is broken down into a spot electricity market sub-scheme, a futures electricity market sub-scheme, and an ancillary services market sub-scheme.
[0036] An adaptive verification mechanism based on deep reinforcement learning is introduced to verify the degree of temporal matching between the electricity spot market sub-scheme and the electricity futures market sub-scheme, and to verify the degree of consistency in resource allocation between the electricity futures market sub-scheme and the ancillary services market sub-scheme.
[0037] Constraint satisfaction network is used to check each sub-solution;
[0038] If the verification or check fails, adjust the parameter settings in the initial transaction decision scheme;
[0039] Repeat the splitting, verification, and checking process until all the market constraints and physical constraints of the preset multi-market are met. Finally, output the trading decision scheme that meets all constraints as a unified trading strategy.
[0040] Optionally, the heterogeneous power data includes real-time operating status data of the electricity spot market, historical trading data of the electricity futures market, service demand data of the ancillary services market, and physical operation data of the power grid;
[0041] The step of establishing time-related relationships between power plant entities, user entities, and transaction product entities in different markets based on the heterogeneous power data includes:
[0042] Based on the real-time operating status data of the electricity spot market, the power generation output change sequence of the power plant entity is determined;
[0043] Based on the historical trading data of the electricity futures market, determine the electricity consumption commitment curve of the user entity;
[0044] Based on the service demand data of the ancillary services market, the qualification requirements description for the transaction product entity is determined;
[0045] Based on the power grid physical operation data, the transmission constraints of the power grid nodes are determined;
[0046] The power generation output change sequence, the electricity consumption commitment curve, the qualification requirement description, and the transmission restriction conditions are organized according to a unified time axis to establish a time correlation.
[0047] Optionally, the step of using a large language model based on the Transformer architecture to perform semantic parsing processing on the cross-market temporal knowledge graph to generate market constraints includes:
[0048] A large language model based on the Transformer architecture is used to read historical market behavior data from the cross-market time-series knowledge graph and identify patterns and pattern constraints in the historical market behavior data.
[0049] The market constraints are formed by combining the pattern and the pattern constraints.
[0050] Secondly, this application provides a collaborative trading decision-making system for the electricity market based on multi-period machine learning, comprising:
[0051] The data acquisition module is used to collect heterogeneous power data from multiple time periods and markets.
[0052] A module is established to establish temporal relationships between power plant entities, user entities, and transaction product entities in different markets based on the heterogeneous power data, and to construct a cross-market temporal knowledge graph based on the temporal relationships.
[0053] The extraction module is used to perform multi-dimensional traversal of the cross-market time-series knowledge graph to extract historical price sequences and real-time supply and demand relationships across markets.
[0054] The analysis module is used to perform multi-period feature analysis on the historical price sequence and the real-time supply and demand relationship based on a machine learning model with a multi-scale processing structure, and obtain market status prediction information.
[0055] The generation module is used to generate an initial trading decision scheme based on the market state prediction information through interactive negotiation among multiple agents;
[0056] The inspection module is used to perform cross-market consistency verification and rule compliance checks on the initial trading decision scheme. Based on the verification and inspection results, the initial trading decision scheme is optimized through a multi-round iterative optimization mechanism to output a unified trading strategy that meets the preset market constraints and physical constraints of multiple markets.
[0057] Thirdly, this application provides an electronic device, comprising:
[0058] Memory, used to store computer programs;
[0059] A processor is configured to execute the computer program to implement the steps of the electricity market collaborative trading decision-making method based on multi-period machine learning as described in the first aspect above.
[0060] Fourthly, this application provides a computer-readable storage medium storing a computer program that, when executed by a processor, can implement the steps of the electricity market collaborative trading decision-making method based on multi-period machine learning as described in the first aspect above.
[0061] The technical solution provided in this application has the following beneficial effects:
[0062] This application achieves comprehensive acquisition of multi-source power data. It establishes a unified, structured market data relationship network, extracts cross-market spatiotemporal correlation features, obtains market state predictions at multiple time granularities, generates trading schemes that comprehensively consider multiple factors, and ensures that the trading schemes meet the requirements of multi-market coordination.
[0063] Furthermore, this application also divides historical price sequences into minute-level, hour-level, and daily-level time series, identifies instantaneous fluctuations, periodic changes, and long-term trend characteristics respectively, combines features with physical constraints, adjusts feature weights according to real-time supply and demand relationships, and finally generates and integrates market state prediction vectors at different time scales through a multi-scale machine learning model to form complete market state prediction information.
[0064] Furthermore, this method can simultaneously capture short-term market fluctuations, medium-term cycles, and long-term trend characteristics. By combining real-time supply and demand conditions with physical constraints, it generates more accurate and comprehensive multi-timescale market state predictions, providing a reliable basis for trading decisions. Attached Figure Description
[0065] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0066] Figure 1 A flowchart illustrating a collaborative transaction decision-making method for the power market based on multi-period machine learning, provided as an embodiment of this application;
[0067] Figure 2 A schematic diagram illustrating a specific implementation of a collaborative transaction decision-making method for the power market based on multi-period machine learning, provided in this application embodiment;
[0068] Figure 3 This is a schematic diagram of the structure of a collaborative trading decision system for the power market based on multi-time period machine learning, provided as an embodiment of this application. Detailed Implementation
[0069] Existing electricity market trading decision-making methods often employ independent analysis of data from each market when dealing with multi-market coordination issues. This results in limited coupling between the temporal correlation characteristics of the data and market rules. This approach weakens the coordination between the spot market, futures market, and ancillary services market, making it difficult for generated trading strategies to simultaneously meet the operational constraints and coordination requirements of multiple markets, thus impacting the overall efficiency of cross-market trading.
[0070] To address the aforementioned issues, this application proposes a collaborative trading decision-making method for the electricity market based on multi-time-period machine learning. This method integrates multi-source heterogeneous data by constructing a cross-market temporal knowledge graph, establishing temporal relationships between market entities. It utilizes multi-scale machine learning models to analyze market characteristics, combines a multi-agent collaborative negotiation mechanism to generate trading schemes, and ensures the feasibility of the strategies through cross-market verification and iterative optimization. This scheme effectively solves the problem of insufficient cross-market coordination in existing technologies through unified data representation and collaborative decision-making mechanisms, improving the adaptability and reliability of trading strategies in multi-market environments.
[0071] To enable those skilled in the art to better understand the present application, the present application will be further described in detail below with reference to the accompanying drawings and specific embodiments. Obviously, the described embodiments are merely some embodiments of the present application, and not all embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0072] The core of this application is to provide a collaborative transaction decision-making method for the electricity market based on multi-period machine learning, and a flowchart of one specific implementation is shown below. Figure 1 As shown, the method includes:
[0073] Step 101: Collect heterogeneous power data from multiple time periods and markets.
[0074] In the aforementioned scheme, "multi-time period" refers to the data set of real-time operational data from the electricity spot market, periodic contract data from the electricity futures market, and rule update data from the ancillary services market across multiple time scales, such as minutes, hours, and days. "Multi-time period, multi-market heterogeneous electricity data" refers to real-time operational status data from the electricity spot market, contract terms data from the electricity futures market, and rule text data from the ancillary services market. This data encompasses multiple time dimensions, including minutes, hours, and days, and its data structure includes numerical transaction data and unstructured text data.
[0075] In this embodiment, firstly, real-time operational status data updated every minute is collected from the electricity spot market, daily updated contract terms data is collected from the electricity futures market, and rule text data is collected from the ancillary services market via a data acquisition interface. For example, the data acquisition interface continuously records the electricity price and power data of a certain region's electricity spot market every minute, while simultaneously acquiring new contract information from the region's electricity futures market daily and periodically capturing the latest rule documents from the ancillary services market. Secondly, the collected heterogeneous data is formatted and timestamped using a data preprocessing module. For example, the preprocessing module converts the text terms of futures contracts into structured data tables, resamples the real-time data from the spot market at minute intervals, and adds a unified timestamp to all data. Finally, the processed data is categorized and stored according to market type and time dimension using a data storage module. For example, the storage module stores minute-level spot data in a real-time database, contract data in a relational database, and rule text in a document database, forming a complete heterogeneous data set.
[0076] In practical applications, a provincial power trading center needs to manage three markets simultaneously: spot, futures, and ancillary services. The system acquires real-time, minute-by-minute electricity price fluctuation data from the spot market via a data acquisition interface, periodically downloads bilateral contract documents from the futures market, and monitors rule updates in the ancillary services market. The data preprocessing module parses the terms in the contract documents into standard trading parameters, transforms the technical requirements in the rule text into quantifiable indicators, and aligns them with the spot market data on a unified timeline. Finally, all data is categorized and stored in different database units, providing a complete data foundation for subsequent analysis.
[0077] This application establishes a unified multi-source data acquisition and processing process, ensuring the integrity and consistency of cross-market electricity data and providing reliable data support for subsequent collaborative trading decisions.
[0078] Step 102: Based on the heterogeneous power data, establish the temporal relationships between power plant entities, user entities, and transaction product entities in different markets, and construct a cross-market temporal knowledge graph based on the temporal relationships.
[0079] In this embodiment, step 102 includes the following process:
[0080] Step 1021: Based on the real-time operating status data of the electricity spot market, determine the power generation output change sequence of the power plant entity.
[0081] Step 1022: Based on the historical trading data of the electricity futures market, determine the electricity consumption commitment curve of the user entity.
[0082] Step 1023: Based on the service demand data of the ancillary services market, determine the qualification requirements description of the transaction product entity.
[0083] Step 1024: Based on the power grid physical operation data, determine the transmission constraints of the power grid nodes.
[0084] Step 1025: Organize the power generation output change sequence, the electricity consumption commitment curve, the qualification requirement description, and the transmission restriction conditions according to a unified time axis to establish a time correlation.
[0085] In the above scheme, the power plant entity represents a specific power generation company, and its power output change sequence records the actual power generation value of the power plant at different points in time. The user entity represents the electricity consumer, and its electricity commitment curve reflects the user's future electricity consumption plan according to the futures contract. The trading product entity refers to various electricity trading varieties, and its qualification requirements describe the technical conditions and rules that need to be met to participate in specific market transactions. Grid nodes are key connection points in the power grid, and transmission constraints stipulate the maximum power capacity that these nodes can safely transmit. Temporal relationships are established by using a unified time axis to establish temporal correspondences between the data of different entities. The cross-market temporal knowledge graph is a networked data structure that includes a time dimension, where nodes represent various entities, edges represent relationships between entities, and each relationship has a time label. The power output change sequence refers to the sequence formed by the actual power generation values of each recorded point of a power generation company in chronological order over a continuous period of time, used to reflect the dynamic changes in power generation capacity. The electricity commitment curve is a curve connecting the electricity values that electricity users plan to use in various future time periods according to the futures contract, used to characterize the temporal distribution characteristics of user electricity demand. The qualification requirements description refers to the written explanation of the technical conditions and rules that must be met to participate in a specific electricity market trading product, used to define the entry standards and operational specifications for the trading product. Transmission limitations refer to the maximum power capacity that can be safely transmitted at critical grid connection points, used to represent the constraints imposed on power transmission by the grid's physical structure. The entity relationship network refers to a network structure composed of power plant entities, user entities, and trading product entities as nodes, with supply and demand relationships, qualification matching relationships, and rights constraint relationships as edges, used to characterize the relationships between different market entities.
[0086] In this embodiment, firstly, step 1021 extracts the power generation value of the power plant at each time point based on real-time operating status data from the electricity spot market, forming a power generation output change sequence for the power plant entity. For example, the power generation reading of a thermal power plant per minute is obtained from the spot market data to generate a continuous 24-hour power generation curve. Secondly, step 1022 analyzes the terms of the electricity contracts signed by users based on historical trading data from the electricity futures market, generating a user entity's electricity commitment curve. For example, based on a futures contract signed by an industrial user, the agreed hourly electricity consumption for the next 24 hours is extracted to form an electricity consumption plan curve. Next, step 1023 analyzes the access conditions of the trading products based on service demand data from the ancillary services market, forming a description of the qualification requirements for the trading product entity. For example, the technical requirements for frequency regulation service products are extracted, including response time requirements and capacity requirements. Then, step 1024 obtains the transmission capacity parameters of key nodes based on grid physical operation data, determining the transmission constraints of grid nodes. For example, the maximum allowable transmission power value of major transmission lines is extracted from grid operation data.
[0087] Finally, step 1025 organizes the power generation output change sequence, electricity consumption commitment curve, qualification requirement description, and transmission restrictions according to a unified time axis to establish temporal relationships. For example, these temporal relationships include supply and demand relationships between power plant entities and user entities, qualification matching relationships between trading product entities and power plant entities, and rights constraint relationships between user entities and trading product entities. Based on these supply and demand relationships, qualification matching relationships, and rights constraint relationships, an entity relationship network is formed. This entity relationship network is then integrated with the unified time axis to construct a cross-market temporal knowledge graph. For instance, power plant generation curves, user electricity consumption curves, product qualification requirements, and line transmission restrictions are all mapped to the same time axis, establishing temporal correspondences between them, and a cross-market temporal knowledge graph is constructed based on these relationships.
[0088] In practical applications, building upon the data foundation of a provincial power trading center in step 101, this embodiment specifically describes the process of constructing time-related relationships. Based on real-time operating status data from the electricity spot market, the power generation output change sequence of power plant A is determined. This sequence is obtained by recording power generation once per minute. For example, 30 data points are recorded between 8:00 and 8:30, forming the sequence [60.2, 61.5, 59.8, ..., 62.1] (unit: 10,000 kW). Based on historical trading data from the electricity futures market, the electricity consumption commitment curve of user B is determined. This curve is obtained by analyzing the 24-hour electricity consumption plan in its futures contract. For example, the electricity consumption is 550,000 kW from 8:00 to 9:00 and 500,000 kW from 9:00 to 10:00, forming the curve [55, 50, ..., 48] (unit: 10,000 kW). Based on service demand data from the ancillary services market, the qualification requirements for frequency regulation service products are determined, including a response time of less than 30 seconds and a regulation capacity of more than 50,000 kW. Based on power grid physical operation data, transmission constraints at node C are determined, specifying a maximum transmission power of 1 million kilowatts. The power generation output change sequence, electricity consumption commitment curve, eligibility requirements, and transmission constraints are organized along a unified time axis, covering 24 hours in minutes. The process of establishing time correlations employs a time alignment algorithm. The core of this algorithm is the alignment function F = min|T1 - T2|, where F represents the time alignment degree (unit: minutes), T1 represents the real-time data timestamp, and T2 represents the planned data timestamp. Alignment is achieved by calculating the minimum deviation of all data points on the time axis. For example, aligning the power generation data of power plant A at 8:00:30 with the electricity consumption data of user B at 8:00:00 results in a time deviation of 0.5 minutes. The final established time correlations include a positive correlation between the power generation sequence of power plant A and the electricity consumption curve of user B during the 8:00 to 9:00 period, a matching correlation between frequency regulation service eligibility requirements and the power generation capacity of power plant A, and a constraint correlation between the transmission constraints at node C on all power flows.
[0089] This application integrates heterogeneous data scattered across different markets into a structured knowledge graph by establishing an entity relationship network under a unified time-series framework, providing a complete data foundation for subsequent cross-market collaborative analysis.
[0090] Step 103: Perform multi-dimensional traversal of the cross-market time-series knowledge graph to extract historical price sequences and real-time supply and demand relationships across markets.
[0091] In the above scheme, the cross-market historical price sequence refers to the historical price data sequence of multiple markets extracted from the cross-market time-series knowledge graph and arranged in chronological order. The cross-market real-time supply and demand relationship refers to the relationship data obtained from the cross-market time-series knowledge graph, reflecting the comparative status of supply and demand in multiple markets at the latest point in time. Multi-dimensional traversal refers to the process of systematically searching and extracting information from the cross-market time-series knowledge graph along multiple directions such as time, market type, and entity relationships.
[0092] In this embodiment, firstly, by traversing the time dimension, different time slice nodes are sequentially accessed along the time axis of the cross-market time-series knowledge graph to extract historical price data from multiple markets corresponding to each time point, forming a cross-market historical price sequence. For example, spot market prices, futures market reference prices, and ancillary service market prices recorded at time slice nodes such as 8:00, 8:01, and 8:02 are read sequentially from the cross-market time-series knowledge graph, and these prices are arranged in chronological order to form a historical price sequence. Secondly, by traversing the market dimension, the current state nodes of the spot market, futures market, and ancillary service market are accessed simultaneously along the market association edges of the cross-market time-series knowledge graph to extract the latest supply and demand data for each market, and calculate the real-time supply and demand relationship across markets. For example, the current total power generation output of the spot market, the total contracted electricity consumption of the futures market, and the demand capacity of the ancillary service market are obtained from the cross-market time-series knowledge graph, and the real-time supply and demand balance is obtained by comparing these data.
[0093] In practical applications, building upon the cross-market time-series knowledge graph already constructed by a provincial power trading center in embodiments 101 and 102, this embodiment specifically illustrates the process of multi-dimensional traversal and information extraction. First, the cross-market time-series knowledge graph is traversed along the time dimension. Starting from 8:00, each time slice node is accessed sequentially by minute to extract historical price sequences. Specifically, this includes extracting the spot market price of 0.53 yuan / kWh, the futures market reference price of 0.49 yuan / kWh, and the ancillary services market price of 0.12 yuan / kWh from the 8:00 time node; and extracting the spot market price of 0.54 yuan / kWh, the futures market reference price of 0.49 yuan / kWh, and the ancillary services market price of 0.12 yuan / kWh from the 8:01 time node. Price data from 31 time nodes, from 8:00 to 8:30, are extracted sequentially to form a cross-market historical price sequence. Secondly, the cross-market time-series knowledge graph was traversed along the market dimension. At the 8:30 time node, the status data of the three markets were accessed simultaneously to extract the real-time supply and demand relationship. The total power generation output of the spot market was 2.8 million kilowatts, and the total power demand was 2.65 million kilowatts, with a supply and demand difference of 150,000 kilowatts. This difference was calculated by subtracting the total power demand from the total power generation output, i.e., 2.8 million - 2.65 million = 150,000. The contracted power capacity of the futures market was 2.4 million kilowatts, and the demand capacity of the ancillary service market was 180,000 kilowatts. Finally, the real-time supply and demand relationship data of the cross-market was formed, including the supply and demand surplus of 150,000 kilowatts in the spot market, the contract coverage rate of the futures market was 90%, and the supply and demand ratio of the ancillary service market was 1.1. The contract coverage rate of the futures market was calculated by dividing the contracted power capacity by the total power demand, i.e., 2.4 million ÷ 2.65 million ≈ 0.90. The supply and demand ratio of the ancillary service market was calculated by dividing the available capacity by the demand capacity, i.e., 200,000 ÷ 180,000 ≈ 1.1. Through the above multi-dimensional traversal process, the system fully extracts historical price sequences and real-time supply and demand relationships across markets, providing accurate market dynamic information for subsequent analysis.
[0094] This application systematically extracts historical price sequences and real-time supply and demand relationships by traversing cross-market time-series knowledge graphs from multiple dimensions, providing comprehensive market dynamic information support for subsequent market condition prediction and trading decisions.
[0095] Step 104: Based on a machine learning model with a multi-scale processing structure, perform multi-period feature analysis on the historical price sequence and the real-time supply and demand relationship to obtain market status prediction information.
[0096] In this embodiment, step 104 includes the following process, such as... Figure 2 As shown:
[0097] Step 1041: Divide the historical price quote sequence into minute-level time series, hour-level time series, and day-level time series according to the time scale.
[0098] Step 1042: Identify instantaneous fluctuation characteristics from the minute-level time series, identify periodic change characteristics from the hour-level time series, and identify long-term trend characteristics from the daily-level time series.
[0099] Step 1043: Using physical constraints as boundary limits, perform feature combination on the instantaneous fluctuation characteristics, the periodic change characteristics, and the long-term trend characteristics.
[0100] Step 1044: Based on the real-time supply and demand relationship, adjust the weight of each feature in the feature combination result.
[0101] Step 1045: Input the weighted feature combination results into a machine learning model with a multi-scale processing structure to generate minute-level market state prediction vectors, hour-level market state prediction vectors, and daily-level market state prediction vectors. Integrate the minute-level market state prediction vectors, hour-level market state prediction vectors, and daily-level market state prediction vectors to form market state prediction information.
[0102] Step 1045 may specifically include the following steps:
[0103] A1: Input the weighted feature combination result into a machine learning model with a multi-scale processing structure. Through the time scale recognition layer of the machine learning model, the weighted feature combination result is separated into minute-level fluctuation features, hour-level cycle features, and daily-level trend features.
[0104] A2: Through the first processing branch of the machine learning model, a temporal convolution operation is performed on the minute-level fluctuation features to obtain the instantaneous change pattern within the minute-level time segment. Based on the instantaneous change pattern, a minute-level state change sequence is formed.
[0105] A3: Through the second processing branch of the machine learning model, the cyclic evolution pattern within the hourly time segment is extracted from the hourly periodic features using the cyclic memory unit, and an hourly state evolution sequence is generated based on the cyclic evolution pattern.
[0106] A4: Through the third processing branch of the machine learning model, the long-term dependencies within the daily time segments are extracted from the daily trend features through a self-attention mechanism, and a daily state trend sequence is generated based on the long-term dependencies.
[0107] A5: The feature fusion layer of the machine learning model is used to fuse the features of the minute-level state change sequence, the hour-level state evolution sequence, and the daily state trend sequence.
[0108] A6: Using the multi-scale prediction head of the machine learning model, based on the fused feature sequence, minute-level market state prediction vectors, hourly-level market state prediction vectors, and daily-level market state prediction vectors are generated respectively.
[0109] A7: Through the time series recombination layer of the machine learning model, the minute-level market state prediction vector, the hour-level market state prediction vector, and the daily-level market state prediction vector are arranged and combined in chronological order to form market state prediction information.
[0110] In the above scheme, minute-level time segments are basic analytical units obtained by dividing a continuous time stream into minute-level intervals, used to capture the instantaneous fluctuations in power generation output and load demand in the electricity spot market. Hour-level time segments are aggregated analytical units formed by dividing a continuous time stream into hourly spans, used to analyze the periodic changes in trading volume and prices in the electricity futures market. Daily-level time segments are trend analysis units obtained by dividing a continuous time stream into daily cycles, used to identify the long-term evolution trends of cross-market trading behavior. Minute-level time series refers to market price data sequences recorded at minute intervals, hourly time series refers to market price data sequences statistically analyzed hourly, and daily time series refers to market price data sequences calculated based on daily averages. Instantaneous fluctuation characteristics reflect the rapid changes in prices over a short period, periodic changes reflect the recurring patterns of prices on an hourly scale, and long-term trend characteristics indicate the continuous development direction of prices on a multi-day scale. Minute-level state change sequences are predictive sequences of future minute-level price changes, hourly state evolution sequences are predictive sequences of future hourly-level price changes, and daily state trend sequences are predictive sequences of future daily-level price changes. The minute-level market state prediction vector is a sequence of predicted values for future minute-level price changes; the hour-level market state prediction vector is a sequence of predicted values for future hour-level price levels; and the daily-level market state prediction vector is a sequence of predicted values for future daily-level price trends.
[0111] In this embodiment, firstly, step 1041 divides the historical price quote series according to different time scales, for example, organizing a week's worth of price data into minute-by-minute price series, hourly average price series, and daily average price series. Secondly, step 1042 identifies features from different time series, for example, identifying rapid price change patterns with fluctuations exceeding 3% within 5 minutes from the minute-level series, identifying cyclical patterns of regular price increases during morning and evening peak hours from the hourly series, and identifying long-term trends of slow price increases over multiple consecutive days from the daily series. Then, step 1043 combines these features with physical constraints, for example, using line transmission capacity limitations as boundary conditions to exclude feature combinations exceeding transmission capacity.
[0112] Then, in step 1044, the weights are adjusted based on real-time supply and demand. For example, the weight of fluctuation characteristics is reduced when supply exceeds demand, and the weight of trend characteristics is increased when demand exceeds supply. Finally, in step 1045, the processed features are input into a multi-scale machine learning model. The model's time scale identification layer first separates features at different time scales. The first processing branch analyzes minute-level fluctuation characteristics through temporal convolution to form a minute-level state change sequence. The second processing branch analyzes hourly periodic characteristics through recurrent memory units to form an hourly state evolution sequence. The third processing branch analyzes daily trend characteristics through a self-attention mechanism to form a daily state trend sequence. The feature fusion layer integrates the three sequences. During feature fusion, the hourly state evolution sequence is used as a benchmark to periodically calibrate the minute-level state change sequence and correct the daily state trend sequence. The multi-scale prediction head generates prediction vectors at different time scales. The time series reconstruction layer combines these prediction vectors into complete market state prediction information. Minute-level fluctuation characteristics refer to the regular pattern of rapid, small-amplitude changes in electricity market prices on a minute-by-minute time scale, reflecting the instantaneous supply and demand adjustments and random disturbances in the market. Hourly cycle characteristics refer to the regular fluctuations in electricity market prices on an hourly time scale, primarily reflecting the intraday cyclical changes in electricity load. Daily trend characteristics refer to the continuous direction of change in electricity market prices on a daily time scale, reflecting the long-term evolution of market supply and demand fundamentals. Instantaneous change patterns refer to specific price changes within a very short period, reflecting the market's rapid response to immediate information. Cyclical evolution patterns refer to the recurring fluctuations in market prices at fixed time intervals, reflecting the cyclical operation of the market. Long-term dependencies refer to the interrelationships between market prices over a long period, reflecting the sustained impact of historical conditions on the future. Market state forecasting information refers to the set of predictions for key indicators such as market prices and supply and demand over a future period based on historical data and market characteristics. Physical constraints refer to the limitations imposed on power transmission and trading by the physical structure and technical parameters of the power grid. These conditions are derived from actual power grid operation data, including physical characteristic parameters of power grid infrastructure such as the maximum transmission capacity of transmission lines, the rated power of transformers, and the safe range of node voltages. They are obtained by collecting real-time operation data and safety verification results from the power grid dispatching system and are used to ensure that trading decisions are executed safely within the physical carrying capacity of the power grid. Physical constraints include line transmission capacity, safe range of node voltages, and generator output limits, all of which are derived from the objective physical characteristics of the power system and are the inviolable natural laws underlying the execution of this method.
[0113] In practical applications, following the historical price sequence and real-time supply and demand relationship extracted by a provincial power trading center in the embodiments of steps 101 to 103, this embodiment specifically illustrates the process of multi-period feature analysis and market status prediction. First, the historical price series is divided by time scale. The minute-level time series contains spot market price data for 31 time points from 8:00 to 8:30, [0.53, 0.54, 0.52, ..., 0.55] yuan / kWh. The hour-level time series contains the average spot market price data for 60 time points from 7:00 to 8:00. This data is obtained by calculating the average of the 60 minute-level prices for each hour. That is, the hourly price is equal to the sum of all minute-level prices for that hour divided by 60. For example, the hourly price from 7:00 to 8:00 is 0.51 yuan / kWh. The daily-level time series contains the average daily price data for the past 7 days, [0.48, 0.49, 0.50, 0.51, 0.52, 0.53, 0.54] yuan / kWh. The system identifies instantaneous fluctuations in minute-level time series, specifically price fluctuations exceeding 0.02 yuan within 5 minutes. It also identifies cyclical changes in hourly-level time series, such as a price increase of 0.03 yuan between 8:00 and 9:00 AM compared to the baseline period. Finally, it identifies long-term trends in daily time series, such as a 7-day average daily price increase of 0.01 yuan. Physical constraints are used as boundary limits, with a maximum transaction volume limit of 1 million kilowatts for node C. These instantaneous fluctuations, cyclical changes, and long-term trends are combined to exclude combinations exceeding the transmission capacity. The weights of each feature in the result of the feature combination are adjusted based on the real-time supply and demand relationship. A spot market supply-demand surplus of 150,000 kilowatts corresponds to a state of oversupply. According to the weight adjustment formula, W equals the benchmark weight multiplied by the supply-demand balance coefficient, where W represents the adjusted weight. The benchmark weights are set at 0.4 for minute-level features, 0.35 for hourly features, and 0.25 for daily features. The supply-demand balance coefficient equals the actual supply-demand difference divided by the benchmark supply-demand difference, which is set at 100,000 kilowatts. The calculated supply-demand balance coefficient is 150,000 kilowatts ÷ 10 = 1.5. Therefore, the adjusted weights are: 0.4 × 1.5 = 0.6 for minute-level features, 0.35 × 1.5 = 0.525 for hourly features, and 0.25 × 1.5 = 0.375 for daily features, with a total weight of 1.5. After normalization, the final weights are: 0.4 for minute-level features, 0.35 for hourly features, and 0.25 for daily features.The weighted feature combination result is input into a machine learning model with a multi-scale processing structure. A time-scale recognition layer separates minute-level fluctuation features, hourly-level periodic features, and daily-level trend features. The first processing branch performs a temporal convolution operation on the minute-level fluctuation features to obtain instantaneous change patterns within minute-level time segments, forming a minute-level state change sequence [0.56, 0.57, 0.55, ..., 0.58] yuan / kWh. The second processing branch uses a recurrent memory unit to extract cyclic evolution patterns from the hourly-level periodic features, generating an hourly-level state evolution sequence [0.55, 0.56, 0.57, ..., 0.59] yuan / kWh. The third processing branch uses a self-attention mechanism to extract long-term dependencies from the daily-level trend features, generating a daily-level state trend sequence [0.55...]. The feature fusion layer merges the three sequences. The multi-scale prediction head generates minute-level market state prediction vectors based on the fused feature sequences to predict the price of the next 30 minutes [0.56, 0.57, 0.58, ..., 0.60] yuan / kWh, hour-level market state prediction vectors to predict the price of the next 6 hours [0.57, 0.58, 0.59, ..., 0.62] yuan / kWh, and daily-level market state prediction vectors to predict the price of the next 3 days [0.58, 0.59, 0.60] yuan / kWh. The time series recombination layer arranges and combines these prediction vectors in chronological order to form complete market state prediction information. This information shows that the future market will exhibit a comprehensive trend of short-term fluctuation and rise, medium-term steady growth, and long-term slow rise.
[0114] This application uses multi-scale feature analysis and machine learning prediction to simultaneously capture short-term market fluctuations, medium-term cycles, and long-term trends, generating comprehensive and accurate market condition prediction information and providing a reliable basis for trading decisions.
[0115] Step 105: Based on the market state prediction information, generate an initial transaction decision scheme through interactive negotiation among multiple agents.
[0116] In this embodiment, step 105 includes the following process:
[0117] Step 1051: Use a large language model based on the Transformer architecture to perform semantic parsing on the cross-market temporal knowledge graph to generate market constraints.
[0118] Step 1051 may specifically include the following steps:
[0119] B1: Using a large language model based on the Transformer architecture, read historical market behavior data from the cross-market time-series knowledge graph and identify patterns and pattern constraints in the historical market behavior data.
[0120] B2: Combine the stated pattern and the stated pattern constraints to form market constraints.
[0121] Step 1052: In the first agent of the multi-agent system, a first set of trading operations is generated based on the market constraints; in the second agent of the multi-agent system, a second set of trading operations is generated based on the market state prediction information.
[0122] Step 1053: Calculate the intersection of the two transaction operation sets through multiple message exchanges between the first and second intelligent agents.
[0123] Step 1054: When the intersection calculation result is not empty, select the transaction operation with the highest priority from the intersection calculation result to form the initial transaction decision scheme.
[0124] Step 1055: Alternatively, when the intersection calculation result is empty, the first agent adjusts the market constraints, the second agent adjusts the expected returns, and the intersection calculation is performed again until the intersection calculation result is non-empty, generating an initial trading decision scheme.
[0125] In the above scheme, market constraints refer to the rules and restrictions that must be followed in electricity market transactions, including price limits, transaction volume limits, and time limits. Although market constraints originate from market rules, their setting and execution must conform to the physical safety operation boundaries of the power system and are essentially constrained by natural laws. The first set of trading operations refers to the set of all feasible trading operations that meet the market constraints. The second set of trading operations refers to the set of trading operations with the highest expected returns, selected based on market state prediction information. The highest priority trading operation refers to the trading operation with the highest score after being ranked according to preset evaluation criteria. Historical market behavior data refers to various operational and result data recorded in the electricity market during past transactions, including historical quotes, transaction records, and information on violations. Patterns refer to regular and repetitive trading characteristics or operational habits discovered from historical market behavior data, reflecting typical behavioral patterns of market participants. Pattern constraints refer to the restrictive requirements for such behavior derived from the identified behavioral patterns and combined with market rules, used to regulate the execution conditions of similar market behaviors. Market constraints refer to the set of rules and restrictions that must be followed in the operation of the electricity market, including a comprehensive constraint system composed of model constraints, explicit regulations, and physical restrictions. Initial trading decision schemes refer to preliminary decision schemes generated through multi-agent negotiation, containing specific trading operation parameters but not yet validated across markets, serving as the input basis for subsequent optimization processes.
[0126] In this embodiment, firstly, step 1051 uses a large language model based on the Transformer architecture to perform semantic parsing on the cross-market time-series knowledge graph, reads historical market behavior data, identifies transaction patterns and corresponding constraints in the data, and combines these patterns and constraints to form market constraints. For example, the large language model identifies the transaction pattern "price fluctuation range during peak hours does not exceed 10%" from the knowledge graph, and combines it with the constraint "single transaction volume does not exceed 500,000 kilowatts" in the rule text to form complete market constraints. Secondly, step 1052 generates a first set of transaction operations based on the market constraints in the first agent of the multi-agent system, and generates a second set of transaction operations based on market state prediction information in the second agent. For example, the first agent generates a set of transaction operations including "purchasing 300,000 kilowatts of electricity at a price not exceeding 0.60 yuan during peak hours," and the second agent generates a set of transaction operations including "purchasing a large amount of electricity when the predicted price is low."
[0127] Next, in step 1053, through multiple message exchanges between the first and second agents, the intersection of the two sets of trading operations is calculated. For example, the two agents gradually narrow down the scope of operations by exchanging operation parameters and constraints, searching for mutually agreed-upon trading operations. Then, in step 1054, when the intersection calculation result is non-empty, the highest-priority trading operation is selected from the intersection calculation result to form an initial trading decision scheme. For example, the combination of trading operations with the highest expected return and lowest risk is selected from the mutually agreed-upon operations. Finally, in step 1055, when the intersection calculation result is empty, the first agent adjusts the market constraints, the second agent adjusts the expected return, and the intersection calculation is re-performed until the intersection calculation result is non-empty, generating an initial trading decision scheme. For example, the first agent relaxes the trading volume limit, the second agent lowers the expected return requirement, and after recalculating to obtain a non-empty intersection, a feasible trading scheme is generated.
[0128] In practical applications, building upon the market state prediction information obtained by a provincial power trading center in steps 101 to 104, this embodiment specifically illustrates the process of multi-agent interactive negotiation to generate an initial trading decision scheme. First, a large language model based on the Transformer architecture is used to read historical market behavior data from a cross-market time-series knowledge graph, identifying patterns and pattern constraints. Specifically, historical patterns are identified where price fluctuations during the peak hours of 8:00 to 9:00 do not exceed 10%, and the constraint that a single transaction volume does not exceed 500,000 kilowatts. These patterns and constraints are combined to form market constraints, including peak-hour trading prices limited to between 0.50 and 0.60 yuan, and a single transaction volume not exceeding 500,000 kilowatts. In a multi-agent system, the first agent generates a first set of trading operations based on market constraints, including purchasing 300,000 kW of electricity at 0.55 yuan at 8:30 and selling 200,000 kW of electricity at 0.58 yuan at 9:00. The second agent generates a second set of trading operations based on market state predictions, including purchasing 600,000 kW of electricity at 0.57 yuan at 8:45 and selling 250,000 kW of electricity at 0.61 yuan at 9:30. Through multiple message passes between the first and second agents, the intersection of the two sets of trading operations is calculated. It is found that the maximum purchase quantity in the first set is 300,000 kW, while the purchase quantity in the second set is 600,000 kW, resulting in a zero intersection. Therefore, the first agent adjusts the market constraints, increasing the single transaction quantity limit from 500,000 kW to 700,000 kW, while the second agent adjusts its profit expectations, reducing the purchase quantity from 600,000 kW to 450,000 kW, and the intersection is recalculated. After adjustments, the two sets of trading operations reached an agreement on purchasing 450,000 kilowatts of electricity at 0.57 yuan per kilowatt at 8:45, and the intersection result was non-empty. The trading operation with the highest priority was selected from the intersection result. The priority was determined based on the matching degree between the operation time and the predicted period, as well as the expected return. The expected return equals the expected electricity sales revenue and the electricity purchase cost. The expected electricity sales revenue is calculated by multiplying the predicted electricity sales price by the electricity sales volume, and the electricity purchase cost is calculated by multiplying the electricity purchase price by the electricity purchase volume. The final selected operation combination is to purchase 450,000 kilowatts of electricity at 0.57 yuan per kilowatt at 8:45 and sell 250,000 kilowatts of electricity at 0.61 yuan per kilowatt at 9:30, forming the initial trading decision plan. This plan's expected total return is 250,000 × 0.61 - 450,000 × 0.57 - 256,500 = -104,000 yuan. However, considering the prediction of continued price increases, this plan still has a positive return expectation in the long term.
[0129] This application effectively balances the relationship between market rule constraints and profit expectations through a multi-agent collaborative decision-making mechanism, generating an initial transaction plan that is both compliant and economically beneficial, laying a solid foundation for subsequent optimization decisions.
[0130] Step 106: Perform cross-market consistency verification and rule compliance checks on the initial trading decision scheme. Based on the verification and check results, optimize the initial trading decision scheme through a multi-round iterative optimization mechanism to output a unified trading strategy that satisfies the market constraints and physical constraints of the preset multi-markets.
[0131] In this embodiment, step 106 includes the following process:
[0132] Step 1061: Decompose the initial trading decision scheme into a spot market sub-scheme, a futures market sub-scheme, and an ancillary services market sub-scheme.
[0133] Step 1062: Introduce an adaptive verification mechanism based on deep reinforcement learning to verify the degree of temporal matching between the electricity spot market sub-scheme and the electricity futures market sub-scheme, and to verify the degree of consistency in resource allocation between the electricity futures market sub-scheme and the ancillary service market sub-scheme.
[0134] Step 1063: Use a constraint satisfaction network to check each sub-solution.
[0135] Step 1064: If the verification or check fails, adjust the parameter settings in the initial transaction decision scheme.
[0136] Step 1065: Repeat the splitting, verification, and checking process until all the market constraints and physical constraints of the preset multi-market are met. Output the final trading decision scheme that meets all constraints as a unified trading strategy.
[0137] In the above scheme, the verification process adopts a progressive logical chain. First, it verifies the temporal matching degree between the electricity spot market sub-scheme and the electricity futures market sub-scheme. Then, based on this result, it verifies the consistency in resource allocation between the electricity futures market sub-scheme and the ancillary services market sub-scheme. This design implicitly assumes that the electricity futures market sub-scheme acts as an intermediate hub connecting the spot market and the ancillary services market. By verifying its correlation with the sub-schemes at both ends of the market, the overall coordination between the electricity spot market sub-scheme and the ancillary services market sub-scheme can be indirectly ensured, thus eliminating the need for a separate direct verification step. The constraint satisfaction network in this application specifically refers to a graph neural network structure used to process and verify complex constraints. Its specific type is a graph attention network based on a message-passing mechanism. This network represents rule constraints, physical constraints, and transaction constraints in the electricity market as nodes in the network. It detects and locates constraint conflicts in transaction decision schemes through message passing between nodes and attention weight calculation. The electricity spot market sub-scheme refers to the specific trading operation plan formulated for the electricity spot market; the electricity futures market sub-scheme refers to the contract trading plan formulated for the electricity futures market; and the ancillary services market sub-scheme refers to the service provision or purchase plan formulated for the ancillary services market. The adaptive verification mechanism based on deep reinforcement learning refers to an intelligent verification method that can continuously improve its verification effect through autonomous learning. The unified trading strategy refers to the final trading plan that integrates multiple market trading schemes and satisfies all constraints.
[0138] In this embodiment, firstly, step 1061 divides the initial trading decision scheme into three sub-schemes according to market type. For example, the initial scheme involving multiple market transactions is decomposed into independent spot trading schemes, futures trading schemes, and ancillary service trading schemes. Secondly, step 1062 introduces an adaptive verification mechanism based on deep reinforcement learning to verify the coordination between different market sub-schemes. For example, it verifies the matching degree between the spot market sub-scheme and the futures market sub-scheme in terms of trading time, and verifies the consistency degree between the futures market sub-scheme and the ancillary service market sub-scheme in terms of resource allocation. Next, step 1063 uses a constraint satisfaction network to check each sub-scheme. For example, it checks whether the spot market sub-scheme complies with real-time trading rules, whether the futures market sub-scheme complies with contract terms, and whether the ancillary service market sub-scheme complies with technical service standards. Then, step 1064 adjusts the parameter settings in the initial trading decision scheme when verification or checks fail. For example, it modifies the trading time, adjusts the trading volume, or changes the trading price. Finally, the splitting, verification, and checking process is repeated through step 1065 until all market and physical constraints are met, and the final trading decision scheme that satisfies all constraints is output as a unified trading strategy.
[0139] In practical application, following the initial trading decision scheme generated by a provincial power trading center in steps 101 to 105, this embodiment specifically illustrates the cross-market verification and optimization process. First, the initial trading decision scheme is broken down into three sub-schemes: a spot market sub-scheme containing the operation of purchasing 450,000 kW of power at 0.57 yuan at 8:45 and selling 250,000 kW of power at 0.61 yuan at 9:30; a futures market sub-scheme containing a contract to maintain a 300,000 kW base load over the next 24 hours; and an ancillary services market sub-scheme containing a service commitment to provide 80,000 kW of reserve capacity. An adaptive verification mechanism based on deep reinforcement learning is introduced to verify the temporal matching degree between the spot market sub-scheme and the futures market sub-scheme. The time matching degree is calculated using the formula T = overlapping period divided by the total period, where T represents the time matching degree, the overlapping period is the intersection of the spot trading period and the futures contract period, and the total period is the union of the two periods. The calculated time matching degree is 0.75. The consistency of resource allocation between the electricity futures market sub-scheme and the ancillary services market sub-scheme was verified. The resource coordination degree was calculated using the formula R = minimum available resources divided by demand resources, where R represents the resource coordination degree, available resources are the remaining adjustable capacity of the futures contract, and demand resources are the capacity required for ancillary services. The calculated resource coordination degree was 0.9. A constraint satisfaction network was used to check each sub-scheme. The electricity spot market sub-scheme was checked to see if it met real-time market rules. It was found that the 450,000 kW trading volume exceeded the 400,000 kW limit for a single transaction. The electricity futures market sub-scheme was checked to see if it met the contract terms. It was found that the 300,000 kW contract volume was within the allowable range. The ancillary services market sub-scheme was checked to see if it met technical service standards. It was found that the 80,000 kW reserve capacity met the minimum standard. When the checks failed, the parameter settings in the initial trading decision scheme were adjusted. The spot market purchase volume was adjusted from 450,000 kW to 400,000 kW, and the selling time was adjusted from 9:30 to 9:45 to match the price peak. The process of splitting, verifying, and checking was repeated. The second verification improved the time matching accuracy to 0.85, while the resource coordination accuracy remained at 0.9. The network check showed that all sub-schemes met the rule requirements, and the total transmission power of 400,000 kW did not exceed the 1,000,000 kW transmission limit of node C. The final output was a unified trading strategy that satisfied all market and physical constraints. This included purchasing 400,000 kW of electricity at 0.57 yuan at 8:45, selling 250,000 kW of electricity at 0.62 yuan at 9:45, maintaining a 300,000 kW futures base load contract, and providing 80,000 kW of standby capacity service. The projected net profit for this scheme was 250,000 × 0.62 - 400,000 × 0.57 - 228,000 = -73,000 yuan, but after compensation through futures contract revenue and ancillary service revenue, overall profitability could be achieved.
[0140] This application, through a multi-round iterative cross-market verification and optimization process, ensures that the final trading strategy simultaneously meets the rule requirements and physical constraints of multiple markets, thereby improving the executability and market adaptability of the trading solution.
[0141] Figure 3 A schematic diagram of the structure of a collaborative trading decision-making system for the power market based on multi-time period machine learning, as provided in this application embodiment, is shown below. Figure 3 As shown, the detailed implementation section describes:
[0142] The acquisition module 31 is used to acquire heterogeneous power data from multiple time periods and markets.
[0143] Module 32 is used to establish time-related relationships between power plant entities, user entities, and transaction product entities in different markets based on the heterogeneous power data, and to construct a cross-market time-series knowledge graph based on the time-related relationships.
[0144] Extraction module 33 is used to perform multi-dimensional traversal of the cross-market time-series knowledge graph to extract historical price sequences and real-time supply and demand relationships across markets.
[0145] Analysis module 34 is used to perform multi-period feature analysis on the historical price sequence and the real-time supply and demand relationship based on a machine learning model with a multi-scale processing structure, and obtain market status prediction information.
[0146] The generation module 35 is used to generate an initial transaction decision scheme based on the market state prediction information through interactive negotiation among multiple agents.
[0147] The inspection module 36 is used to perform cross-market consistency verification and rule compliance checks on the initial trading decision scheme. Based on the verification results and inspection results, the initial trading decision scheme is optimized through a multi-round iterative optimization mechanism to output a unified trading strategy that meets the preset market constraints and physical constraints of multiple markets.
[0148] The electricity market collaborative transaction decision system based on multi-period machine learning in this application is used to implement the aforementioned electricity market collaborative transaction decision method based on multi-period machine learning. Therefore, the specific implementation of the electricity market collaborative transaction decision system based on multi-period machine learning can be found in the embodiment section of the electricity market collaborative transaction decision method based on multi-period machine learning mentioned above. The specific implementation can be referred to the description of the corresponding embodiment, and will not be repeated here.
[0149] This application also provides an electronic device, comprising: a memory for storing a computer program; and a processor for executing the computer program to implement the steps of the above-described multi-period machine learning-based collaborative trading decision-making method for the electricity market.
[0150] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of any of the above-described power market collaborative trading decision-making methods based on multi-period machine learning.
[0151] In one exemplary embodiment, the aforementioned computer-readable storage medium may include, but is not limited to, various media capable of storing computer programs, such as USB flash drives, read-only memory, random access memory, portable hard drives, magnetic disks, or optical disks.
[0152] The embodiments of this application also provide a computer program product, which includes a computer program that, when executed by a processor, implements the steps in any of the embodiments of the power market collaborative trading decision-making method based on multi-period machine learning described above.
[0153] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.
[0154] The foregoing has provided a detailed description of a power market collaborative trading decision-making method, system, electronic device, and storage medium based on multi-period machine learning, as provided in this application. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the embodiments above are merely for the purpose of helping to understand the method and its core ideas. It should be noted that those skilled in the art can make various improvements and modifications to this application without departing from its principles, and these improvements and modifications also fall within the protection scope of this application.
Claims
1. A collaborative transaction decision-making method for the electricity market based on multi-period machine learning, characterized in that, include: Collect heterogeneous power data from multiple time periods and markets; Based on the heterogeneous power data, temporal relationships are established between power plant entities, user entities, and transaction product entities in different markets. Based on these temporal relationships, a cross-market temporal knowledge graph is constructed. These temporal relationships establish temporal correspondences between data from different entities through a unified timeline. The temporal relationships include supply and demand relationships between power plant entities and user entities, qualification matching relationships between transaction product entities and power plant entities, and rights and obligations relationships between user entities and transaction product entities. The cross-market temporal knowledge graph is a networked data structure with a time dimension, where nodes represent various entities, edges represent relationships between entities, and each relationship is labeled with a time tag. The construction of a cross-market time-series knowledge graph based on the aforementioned time relationships includes: Based on the supply and demand relationship, the qualification matching relationship, and the right constraint relationship, an entity relationship network is formed; the entity relationship network is integrated with the unified timeline to construct a cross-market time-series knowledge graph; The cross-market time-series knowledge graph is traversed in multiple dimensions to extract historical price sequences and real-time supply and demand relationships across markets; Based on a machine learning model with a multi-scale processing structure, multi-period feature analysis is performed on the historical price sequence and the real-time supply and demand relationship to obtain market status prediction information. Based on the market state prediction information, an initial transaction decision scheme is generated through interactive negotiation among multiple agents. The initial trading decision scheme is subjected to cross-market consistency verification and rule compliance check. Based on the verification and check results, the initial trading decision scheme is optimized through a multi-round iterative optimization mechanism to output a unified trading strategy that meets the market constraints and physical constraints of the preset multi-markets. The machine learning model, based on a multi-scale processing structure, performs multi-period feature analysis on the historical price sequence and the real-time supply and demand relationship to obtain market state prediction information, including: The historical price quote series is divided into minute-level time series, hour-level time series, and daily-level time series according to the time scale. Identify instantaneous fluctuation characteristics from the minute-level time series, identify periodic change characteristics from the hour-level time series, and identify long-term trend characteristics from the daily-level time series; Using physical constraints as boundary limitations, feature combinations are performed on the instantaneous fluctuation characteristics, the periodic change characteristics, and the long-term trend characteristics; Based on the real-time supply and demand relationship, adjust the weight of each feature in the feature combination result; The weighted feature combination results are input into a machine learning model with a multi-scale processing structure to generate minute-level market state prediction vectors, hour-level market state prediction vectors, and daily-level market state prediction vectors. The minute-level market state prediction vectors, hour-level market state prediction vectors, and daily-level market state prediction vectors are then integrated to form market state prediction information. The process of generating an initial trading decision scheme based on the market state prediction information through interactive negotiation among multiple agents includes: A large language model based on the Transformer architecture is used to perform semantic parsing on the cross-market temporal knowledge graph to generate market constraints. In the first agent of the multi-agent system, a first set of trading operations is generated based on the market constraints. In the second agent of the multi-agent system, a second set of trading operations is generated based on the market state prediction information. The first set of trading operations refers to the set of all feasible trading operations that meet the market constraints, and the second set of trading operations refers to the set of trading operations with the highest expected return selected based on the market state prediction information. The intersection of the two sets of transaction operations is calculated through multiple message exchanges between the first and second intelligent agents. When the intersection calculation result is not empty, the highest priority trading operation is selected from the intersection calculation result to form the initial trading decision scheme, where the priority is comprehensively evaluated based on the matching degree between the operation time and the prediction period and the expected return. Alternatively, when the intersection calculation result is empty, the first agent adjusts the market constraints, the second agent adjusts the expected returns, and the intersection calculation is performed again until the intersection calculation result is non-empty, generating an initial trading decision scheme. The process of performing cross-market consistency verification and rule compliance checks on the initial trading decision scheme, and optimizing the initial trading decision scheme through a multi-round iterative optimization mechanism based on the verification and check results, to output a unified trading strategy that satisfies the preset market constraints and physical constraints of multiple markets, includes: The initial trading decision scheme is broken down into a spot electricity market sub-scheme, a futures electricity market sub-scheme, and an ancillary services market sub-scheme. An adaptive verification mechanism based on deep reinforcement learning is introduced to verify the degree of temporal matching between the electricity spot market sub-scheme and the electricity futures market sub-scheme, and to verify the degree of consistency in resource allocation between the electricity futures market sub-scheme and the ancillary services market sub-scheme. Constraint satisfaction network is used to check each sub-solution; If the verification or check fails, adjust the parameter settings in the initial transaction decision scheme; Repeat the splitting, verification, and checking process until all the market constraints and physical constraints of the preset multi-market are met. Finally, output the trading decision scheme that meets all constraints as a unified trading strategy.
2. The power market collaborative trading decision-making method based on multi-period machine learning according to claim 1, characterized in that, The process involves inputting the weighted feature combination results into a machine learning model with a multi-scale processing structure to generate minute-level, hourly-level, and daily-level market state prediction vectors. These vectors are then integrated to form market state prediction information, including: The weighted feature combination result is input into a machine learning model with a multi-scale processing structure. Through the time scale recognition layer of the machine learning model, the weighted feature combination result is separated into minute-level fluctuation features, hour-level cycle features, and daily-level trend features. The first processing branch of the machine learning model performs a temporal convolution operation on the minute-level fluctuation features to obtain the instantaneous change pattern within the minute-level time segment. Based on the instantaneous change pattern, a minute-level state change sequence is formed. Through the second processing branch of the machine learning model, the cyclical evolution pattern within the hourly time segment is extracted from the hourly periodic features using the cyclical memory unit, and an hourly state evolution sequence is generated based on the cyclical evolution pattern. Through the third processing branch of the machine learning model, long-term dependencies within daily time segments are extracted from the daily trend features using a self-attention mechanism, and a daily state trend sequence is generated based on the long-term dependencies. The feature fusion layer of the machine learning model performs feature fusion on the minute-level state change sequence, the hour-level state evolution sequence, and the daily state trend sequence. Using the multi-scale prediction head of the machine learning model, based on the fused feature sequence, minute-level market state prediction vectors, hour-level market state prediction vectors, and daily-level market state prediction vectors are generated respectively. The time series reconstruction layer of the machine learning model arranges and combines the minute-level market state prediction vector, the hour-level market state prediction vector, and the daily-level market state prediction vector in chronological order to form market state prediction information.
3. The power market collaborative trading decision-making method based on multi-period machine learning according to claim 1, characterized in that, The heterogeneous power data includes real-time operating status data of the electricity spot market, historical trading data of the electricity futures market, service demand data of the ancillary services market, and physical operation data of the power grid. The step of establishing time-related relationships between power plant entities, user entities, and transaction product entities in different markets based on the heterogeneous power data includes: Based on the real-time operating status data of the electricity spot market, the power generation output change sequence of the power plant entity is determined; Based on the historical trading data of the electricity futures market, determine the electricity consumption commitment curve of the user entity; Based on the service demand data of the ancillary services market, the qualification requirements description for the transaction product entity is determined; Based on the power grid physical operation data, the transmission constraints of the power grid nodes are determined; The power generation output change sequence, the electricity consumption commitment curve, the qualification requirement description, and the transmission restriction conditions are organized according to a unified time axis to establish a time correlation.
4. The power market collaborative trading decision-making method based on multi-period machine learning according to claim 1, characterized in that, The method employs a large language model based on the Transformer architecture to perform semantic parsing on the cross-market temporal knowledge graph, generating market constraints, including: A large language model based on the Transformer architecture is used to read historical market behavior data from the cross-market time-series knowledge graph and identify patterns and pattern constraints in the historical market behavior data. The market constraints are formed by combining the pattern and the pattern constraints.
5. A collaborative trading decision-making system for the electricity market based on multi-period machine learning, characterized in that, include: The data acquisition module is used to collect heterogeneous power data from multiple time periods and markets. A module is established to create temporal relationships between power plant entities, user entities, and transaction product entities in different markets based on the heterogeneous power data. Based on these temporal relationships, a cross-market temporal knowledge graph is constructed. These temporal relationships establish temporal correspondences between data from different entities through a unified timeline. The temporal relationships include supply and demand relationships between power plant entities and user entities, qualification matching relationships between transaction product entities and power plant entities, and rights and obligations relationships between user entities and transaction product entities. The cross-market temporal knowledge graph is a networked data structure with a time dimension, where nodes represent various entities, edges represent relationships between entities, and each relationship is labeled with a time tag. The construction of a cross-market time-series knowledge graph based on the aforementioned time relationships includes: Based on the supply and demand relationship, the qualification matching relationship, and the right constraint relationship, an entity relationship network is formed; the entity relationship network is integrated with the unified timeline to construct a cross-market time-series knowledge graph; The extraction module is used to perform multi-dimensional traversal of the cross-market time-series knowledge graph to extract historical price sequences and real-time supply and demand relationships across markets. The analysis module is used to perform multi-period feature analysis on the historical price sequence and the real-time supply and demand relationship based on a machine learning model with a multi-scale processing structure, and obtain market status prediction information. The generation module is used to generate an initial trading decision scheme based on the market state prediction information through interactive negotiation among multiple agents; The inspection module is used to perform cross-market consistency verification and rule compliance checks on the initial trading decision scheme. Based on the verification results and inspection results, the initial trading decision scheme is optimized through a multi-round iterative optimization mechanism to output a unified trading strategy that meets the market constraints and physical constraints of preset multi-markets. The machine learning model, based on a multi-scale processing structure, performs multi-period feature analysis on the historical price sequence and the real-time supply and demand relationship to obtain market state prediction information, including: The historical price quote series is divided into minute-level time series, hour-level time series, and daily-level time series according to the time scale. Identify instantaneous fluctuation characteristics from the minute-level time series, identify periodic change characteristics from the hour-level time series, and identify long-term trend characteristics from the daily-level time series; Using physical constraints as boundary limitations, feature combinations are performed on the instantaneous fluctuation characteristics, the periodic change characteristics, and the long-term trend characteristics; Based on the real-time supply and demand relationship, adjust the weight of each feature in the feature combination result; The weighted feature combination results are input into a machine learning model with a multi-scale processing structure to generate minute-level market state prediction vectors, hour-level market state prediction vectors, and daily-level market state prediction vectors. The minute-level market state prediction vectors, hour-level market state prediction vectors, and daily-level market state prediction vectors are then integrated to form market state prediction information. The process of generating an initial trading decision scheme based on the market state prediction information through interactive negotiation among multiple agents includes: A large language model based on the Transformer architecture is used to perform semantic parsing on the cross-market temporal knowledge graph to generate market constraints. In the first agent of the multi-agent system, a first set of trading operations is generated based on the market constraints. In the second agent of the multi-agent system, a second set of trading operations is generated based on the market state prediction information. The first set of trading operations refers to the set of all feasible trading operations that meet the market constraints, and the second set of trading operations refers to the set of trading operations with the highest expected return selected based on the market state prediction information. The intersection of the two sets of transaction operations is calculated through multiple message exchanges between the first and second intelligent agents. When the intersection calculation result is not empty, the highest priority trading operation is selected from the intersection calculation result to form the initial trading decision scheme, where the priority is comprehensively evaluated based on the matching degree between the operation time and the prediction period and the expected return. Alternatively, when the intersection calculation result is empty, the first agent adjusts the market constraints, the second agent adjusts the expected returns, and the intersection calculation is performed again until the intersection calculation result is non-empty, generating an initial trading decision scheme. The process of performing cross-market consistency verification and rule compliance checks on the initial trading decision scheme, and optimizing the initial trading decision scheme through a multi-round iterative optimization mechanism based on the verification and check results, to output a unified trading strategy that satisfies the preset market constraints and physical constraints of multiple markets, includes: The initial trading decision scheme is broken down into a spot electricity market sub-scheme, a futures electricity market sub-scheme, and an ancillary services market sub-scheme. An adaptive verification mechanism based on deep reinforcement learning is introduced to verify the degree of temporal matching between the electricity spot market sub-scheme and the electricity futures market sub-scheme, and to verify the degree of consistency in resource allocation between the electricity futures market sub-scheme and the ancillary services market sub-scheme. Constraint satisfaction network is used to check each sub-solution; If the verification or check fails, adjust the parameter settings in the initial transaction decision scheme; Repeat the splitting, verification, and checking process until all the market constraints and physical constraints of the preset multi-market are met. Finally, output the trading decision scheme that meets all constraints as a unified trading strategy.
6. An electronic device, characterized in that, include: Memory, used to store computer programs; A processor, configured to implement the steps of the electricity market collaborative trading decision-making method based on multi-period machine learning as described in any one of claims 1 to 4 when executing the computer program.
7. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, enables the implementation of the power market collaborative trading decision-making method based on multi-period machine learning as described in any one of claims 1 to 4.
Citation Information
Patent Citations
Power-generation-side technical support substation system in spot market environment
CN114049145A
Park source network load storage multi-agent transaction mechanism under multiple markets
CN119919228A