Photovoltaic power generation multi-scale power prediction transaction optimization method

By constructing a correlation analysis framework for multi-scale forecast data, this method identifies and addresses high-risk evolution patterns in photovoltaic power generation transactions, generates trading sub-strategies, and dynamically adjusts trading strategies. This solves the problem of existing methods failing to effectively manage multi-scale forecast risks and improves decision-making adaptability and risk resilience.

CN121998200APending Publication Date: 2026-05-08华能澜沧江新能源有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
华能澜沧江新能源有限公司
Filing Date
2026-02-10
Publication Date
2026-05-08

AI Technical Summary

Technical Problem

Existing photovoltaic power generation trading optimization methods fail to effectively manage the dynamic evolution of multi-scale power generation forecasts and the risks of decision chain interactions. This results in early trading contracts limiting the scope for subsequent adjustments, forcing operators to make corrections at high costs and weakening overall returns.

Method used

A framework for correlation analysis between the evolution sequence of multi-scale prediction data and actual trading results is constructed. High-risk trajectories are screened through historical simulation, high-risk evolution patterns are identified, and specific trading sub-strategies are generated to dynamically match changes in real-time prediction data and trigger conditional adjustments.

Benefits of technology

It enhances decision-making adaptability and risk resistance in volatile forecasting environments, and reduces potential losses caused by the intertemporal evolution of forecast information and the accumulation of decision constraints.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121998200A_ABST
    Figure CN121998200A_ABST
Patent Text Reader

Abstract

The invention provides a photovoltaic power generation multi-scale power prediction transaction optimization method, and relates to the technical field of power transaction. The method comprises the following steps: constructing a corresponding data set for each transaction day selected in advance; and for the data set corresponding to each transaction day, simulating a preset transaction strategy based on the data set to obtain a plurality of decision prediction trajectories. And screening out a plurality of high-risk trajectories of which the transaction results meet high-risk conditions from the decision prediction trajectories, and determining at least one high-risk evolution mode based on the change rule of the power generation prediction value in each high-risk trajectory. And generating a corresponding transaction sub-strategy for each identified high-risk evolution mode, and updating the transaction strategy based on the transaction sub-strategy. According to the method, the transaction risk caused by the specific prediction evolution mode can be identified and responded, the potential loss caused by prediction information cross-term evolution and decision constraint accumulation can be reduced, and the decision adaptability and the risk resisting capability can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of power trading technology, and in particular to a method for optimizing multi-scale power prediction and trading of photovoltaic power generation. Background Technology

[0002] In the context of photovoltaic power generation participating in the electricity market, operators, in order to obtain economic benefits, need to submit and adjust trading plans sequentially across multiple time scales (such as day-ahead and intraday) based on future power generation forecasts, and ultimately bear the settlement risks arising from deviations between actual power generation and plans. Currently, decision-making typically relies on independent forecast results at the corresponding time scales within each trading cycle. Widely used trading optimization methods also often make independent, locally optimal decisions at each decision point based on the latest forecast fragment at that moment. This method may be effective within a single time scale.

[0003] However, this technical approach may not adequately assess deeper, cross-cycle structural risks. These risks stem from the interaction between the dynamic evolution of multi-scale power generation forecast sequences and the rigid constraints of sequential decision-making (i.e., established trading contracts or market positions). When forecast data exhibits a sustained and significant adverse trend in subsequent time windows, contracts established earlier based on different forecast assumptions can limit subsequent adjustment space, potentially forcing operators to make corrections at high costs, thereby weakening overall profitability.

[0004] Therefore, the current core challenge has shifted from managing "prediction errors" at a single point in time to managing the more complex "interaction risks between high-risk prediction evolution patterns and decision chains," meaning that there are certain limitations in systematically identifying such risks triggered by specific prediction evolution patterns and transmitted through decision chains. Summary of the Invention

[0005] To overcome the aforementioned problems in the existing technology, this disclosure provides a multi-scale power prediction and trading optimization method for photovoltaic power generation, including: For each pre-selected trading day, a corresponding dataset is constructed, which includes a set of pre-day forecast sequences, an intraday forecast set, and an actual power sequence for that trading day. For each trading day's corresponding dataset, a preset trading strategy is simulated based on the dataset to obtain multiple decision prediction trajectories. The trading strategy is used to make trading decisions at multiple preset trading times based on the previous day's prediction sequence and the intraday prediction set to obtain trading contracts. Each decision prediction trajectory includes a trading decision sequence sorted by trading time, and trading contracts corresponding to each trading decision in the trading decision sequence, and trading results obtained based on the actual power sequence and each trading contract. From the various decision prediction trajectories, select several high-risk trajectories whose transaction results meet the high-risk conditions, and determine at least one high-risk evolution mode based on the changing pattern of the power generation prediction value in each high-risk trajectory. For each identified high-risk evolution pattern, a corresponding trading sub-strategy is generated. The trading strategy is then updated based on the trading sub-strategy, so that when the trading strategy is executed, if the changes in the real-time updated intraday forecast set match any high-risk evolution pattern, the trading sub-strategy corresponding to the high-risk evolution pattern is triggered.

[0006] Furthermore, the day-ahead forecast sequence includes multiple power generation forecasts arranged in chronological order, with each forecast corresponding to a trading moment on the trading day; The intraday forecast set includes multiple forecast subsequences that are rolled out at different release times on the trading day, and each forecast subsequence contains the power generation forecast values ​​corresponding to multiple consecutive trading times. The actual power sequence includes the actual power generation value corresponding to each trading moment in the trading day.

[0007] Furthermore, the steps for constructing the dataset include: The predicted sequence, the predicted subsequence, and the actual power sequence are time-aligned according to the same set of trading times preset for the trading day.

[0008] Furthermore, the simulation of the preset trading strategy based on the dataset includes: The dataset is traversed sequentially through the day-ahead prediction sequence and the intraday prediction set for each trading moment in chronological order. For the current trading time, the following steps are performed: Based on the previous day's prediction sequence and the prediction subsequences in the intraday prediction set whose release time is no later than the current time, a currently available prediction information set is constructed; The preset trading strategy is invoked to generate at least one trading decision based on the currently available prediction information set, and trading contracts corresponding to each trading decision are generated; The trading result is obtained based on the actual power sequence and each trading contract. The trading decisions, trading contracts, and trading results corresponding to each trading moment are combined into a decision prediction trajectory.

[0009] Furthermore, the step of selecting several high-risk trajectories from the various decision prediction trajectories whose transaction results meet the high-risk conditions includes: Based on the transaction results, multiple decision prediction trajectories are sorted, and the decision prediction trajectories at the end of the sorting results with a preset proportion are identified as high-risk trajectories.

[0010] Furthermore, determining at least one high-risk evolution pattern based on the changing patterns of power generation forecasts in each high-risk trajectory includes: For each high-risk trajectory, obtain the intraday forecast set corresponding to the high-risk trajectory; The analysis examines the changing trends of multiple power generation forecasts for the same future trading time within the intraday forecast set as their release time progresses. By analyzing the similar trends identified in multiple high-risk trajectories, at least one high-risk evolution pattern is defined, and corresponding triggering conditions are established for each of the high-risk evolution patterns.

[0011] Furthermore, the matching methods for the high-risk evolution patterns include: For any future trading moment, if there are multiple consecutive prediction updates for that moment in the intraday prediction set, and each updated prediction value changes in the same direction and the magnitude of the change exceeds a preset threshold compared to the previous updated value or the corresponding prediction value in the previous day prediction sequence, then the evolution of the current prediction data is determined to match the high-risk evolution pattern.

[0012] Furthermore, the generation of corresponding trading sub-strategies for each identified high-risk evolution pattern includes: Extract each high-risk trajectory that matches the high-risk evolution pattern of the target and construct a training set; For each high-risk trajectory in the training set, determine the decision moments at which the target high-risk evolution pattern is triggered; For each triggered decision moment, a training sample is generated based on the system state at that moment. The system state includes the predicted data state at that moment, the state of the relevant trading contracts already held, and the accumulated trading results from that moment to the end of the trading day. Based on multiple training samples, the strategy parameters are optimized to obtain a trading sub-strategy corresponding to the target high-risk evolution pattern.

[0013] Further, obtaining the policy parameters corresponding to the high-risk evolution pattern based on each of the training samples includes: A strategy optimization model is constructed with the goal of minimizing the expected trading loss after the high-risk evolution pattern of the target is triggered. The input of the strategy optimization model is the system state in the training samples, and the output of the strategy optimization model is a set of strategy parameters. Solve the policy optimization model to obtain a set of optimal policy parameters.

[0014] This disclosure also provides a photovoltaic power generation multi-scale power prediction and trading optimization system, including: The data acquisition module is used to construct a corresponding dataset for each pre-selected trading day. The dataset includes a set of pre-day forecast sequences, intraday forecast sets, and actual power sequences corresponding to the trading day. The trajectory generation module is used to simulate a preset trading strategy based on the dataset corresponding to each trading day to obtain multiple decision prediction trajectories. The trading strategy is used to make trading decisions at multiple preset trading times based on the previous day prediction sequence and the intraday prediction set to obtain trading contracts. Each decision prediction trajectory includes a trading decision sequence sorted by trading time, and trading contracts corresponding to each trading decision in the trading decision sequence, and trading results obtained based on the actual power sequence and each trading contract. The risk screening module is used to screen out several high-risk trajectories from the various decision prediction trajectories, and to determine at least one high-risk evolution mode based on the changing pattern of the power generation prediction value in each high-risk trajectory. The strategy adjustment module is used to generate a corresponding trading sub-strategy for each identified high-risk evolution pattern, and update the trading strategy based on the trading sub-strategy, so that when the trading strategy is executed, if the changes in the real-time updated intraday forecast set match any high-risk evolution pattern, the trading sub-strategy corresponding to the high-risk evolution pattern is triggered.

[0015] This specification's embodiments construct a correlation analysis framework between the evolutionary sequence of multi-scale prediction data and actual trading results, enabling the identification of trading risks caused by specific prediction evolution patterns. The method not only focuses on prediction errors at a single moment but also emphasizes analyzing persistent adverse trends that conflict with constraints formed by early trading decisions during the rolling updates of predicted values ​​from the previous day to the intraday. High-risk trajectories are screened through historical simulations, and common high-risk evolution patterns are extracted. Then, specific trading sub-strategies are trained and generated for each pattern.

[0016] Therefore, in practical applications, this method can dynamically match defined risk patterns by continuously monitoring the evolution of real-time forecast data, and trigger corresponding sub-strategies upon matching, thereby conditionally adjusting trading decisions. This enables the adjusted trading strategy to identify and respond to systemic forecast risks, helping to reduce potential losses caused by the intertemporal evolution of forecast information and the accumulation of decision constraints, and improving decision-making adaptability and risk resistance in a volatile forecasting environment. Attached Figure Description

[0017] Figure 1 This is a schematic diagram of a multi-scale power prediction and trading optimization method for photovoltaic power generation provided in the embodiments of this specification; Figure 2This is a schematic diagram illustrating the process of simulating a preset trading strategy based on a dataset, as provided in the embodiments of this specification. Figure 3 This is a flowchart illustrating the process of determining at least one high-risk evolution pattern based on the changing patterns of predicted power generation values ​​in various high-risk trajectories, as provided in the embodiments of this specification. Figure 4 This is a flowchart illustrating the process of generating corresponding trading sub-strategies for each identified high-risk evolution pattern, as provided in the embodiments of this specification. Figure 5 This is a schematic diagram of the structure of a photovoltaic power generation multi-scale power prediction and trading optimization system provided in the embodiments of this specification. Detailed Implementation

[0018] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.

[0019] The terminology used in this application is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. The singular forms “a,” “the,” and “the” used in this application and the appended claims are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used herein refers to and includes any or all possible combinations of one or more of the associated listed items.

[0020] It should be understood that although the terms first, second, third, etc., may be used in this application to describe various information, such information should not be limited to these terms. These terms are only used to distinguish information of the same type from one another. For example, without departing from the scope of this application, first information may also be referred to as second information, and similarly, second information may also be referred to as first information. Depending on the context, the word "if" as used herein may be interpreted as "when," "when," or "in response to determination."

[0021] In an electricity market environment, photovoltaic (PV) power generation, as a renewable energy source with significant intermittency and volatility, typically requires its operators to participate in electricity trading across multiple time scales to generate economic benefits. This process relies on forecasting future power generation. Based on the forecast results, operators submit power generation plans in the day-ahead market, make adjustments in the intraday market, and ultimately bear the settlement risk arising from deviations between actual power generation and the trading plan in real-time operation. Currently, each trading cycle typically uses independent forecast results at the corresponding time scale as the basis for decision-making.

[0022] However, power forecasts at different scales (such as day-ahead and ultra-short-term) exhibit inherent differences and dynamic updates. Together, these constitute a multi-scale power generation forecast sequence generated sequentially over time and used for decision-making. As this sequence traverses different decision points (specific time periods where market rules allow or require trading decisions), decision-makers need to make binding trading decisions based on the latest available forecast data. During this process, numerical changes within the sequence may exhibit identifiable, systematic trends. The risk of such trends lies not in the accuracy of individual forecasts, but in the persistent and significant deviation of their evolutionary direction from the assumptions upon which earlier decisions were based—for example, starting with optimistic day-ahead forecasts and then experiencing sustained and significant downward revisions during intraday periods.

[0023] Currently widely used trading optimization methods often make independent, locally optimal decisions based on the latest forecast fragment at each decision point. While this approach may be effective on a single timescale, it may not adequately assess deeper, cross-cycle structural risks. This risk stems from the interaction between the predicted high-risk evolution patterns and the decision chain: at early decision points (e.g., the day before), trading decisions based on then-current forecast information form legally or market-regulated trading contracts, representing contracts to trade a certain amount of electricity in a specific future period—also known as market positions. These established "trading contracts" constitute predetermined constraints that subsequent decisions must accept. When the "forecast data stream" exhibits unfavorable high-risk evolution patterns in subsequent windows (e.g., intraday) (e.g., forecasts consistently fall below expectations when trading contracts were established), the early-formed trading contracts severely limit the flexibility and scope for decision adjustments, forcing operators to engage in costly corrective trading under unfavorable market conditions. This systemic characteristic—the conflict between the cross-cycle evolution of forecast information and the rigid constraints formed by sequential decision-making, leading to a significant reduction in expected returns—constitutes the vulnerability of trading strategies.

[0024] Therefore, the core challenge facing multi-scale photovoltaic power generation trading optimization has shifted to some extent from addressing "prediction errors" at a single point in time to managing the more complex "interaction risks between predicted high-risk evolution patterns and decision-making chains." Existing methods may be insufficient in systematically identifying vulnerabilities triggered by specific predicted high-risk evolution patterns and amplified through the decision-making chain. Therefore, a new analytical approach is needed to holistically model, examine, and evaluate the dynamic sequence of multi-scale predictions, the cumulative and constraining effects of transaction contracts formed by sequential decision-making, and the risks that may be induced by their interaction.

[0025] Please see Figure 1 , Figure 1 This is a schematic diagram of a photovoltaic power generation multi-scale power prediction and trading optimization method provided in the embodiments of this specification. The method includes: S100: Construct a corresponding dataset for each pre-selected trading day.

[0026] The dataset contains a set of pre-trading forecast sequences, intraday forecast sets, and actual power sequences corresponding to each trading day.

[0027] S102: For each trading day's corresponding dataset, simulate the preset trading strategy based on the dataset to obtain multiple decision prediction trajectories.

[0028] The trading strategy is used to make trading decisions and obtain trading contracts at multiple preset trading times based on the daily forecast sequence and the intraday forecast set. Each decision forecast trajectory includes a trading decision sequence sorted by trading time, and the trading contract corresponding to each trading decision in the trading decision sequence, and the trading results obtained based on the actual power sequence and each trading contract.

[0029] S104: Select several high-risk trajectories from various decision prediction trajectories whose transaction results meet the high-risk conditions, and determine at least one high-risk evolution mode based on the changing pattern of the power generation prediction value in each high-risk trajectory.

[0030] S106: Generate a corresponding trading sub-strategy for each identified high-risk evolution pattern, and update the trading strategy based on the trading sub-strategy so that when the trading strategy is executed, if the changes in the real-time updated intraday forecast set match any high-risk evolution pattern, the trading sub-strategy corresponding to the high-risk evolution pattern is triggered.

[0031] This specification's embodiments construct a correlation analysis framework between the evolutionary sequence of multi-scale prediction data and actual trading results, enabling the identification of trading risks caused by specific prediction evolution patterns. The method not only focuses on prediction errors at a single moment but also emphasizes analyzing persistent adverse trends that conflict with constraints formed by early trading decisions during the rolling updates of predicted values ​​from the previous day to the intraday. High-risk trajectories are screened through historical simulations, and common high-risk evolution patterns are extracted. Then, specific trading sub-strategies are trained and generated for each pattern.

[0032] Therefore, in practical applications, this method can dynamically match defined risk patterns by continuously monitoring the evolution of real-time forecast data, and trigger corresponding sub-strategies upon matching, thereby conditionally adjusting trading decisions. This enables the adjusted trading strategy to identify and respond to systemic forecast risks, helping to reduce potential losses caused by the intertemporal evolution of forecast information and the accumulation of decision constraints, and improving decision-making adaptability and risk resistance in a volatile forecasting environment.

[0033] The following detailed description of the photovoltaic power generation multi-scale power prediction and trading optimization method, with reference to specific embodiments, provides a comprehensive overview.

[0034] S100: Construct a corresponding dataset for each pre-selected trading day.

[0035] This method requires building a dataset for each selected historical trading day. This dataset is equivalent to a complete "archive" of that trading day, which includes the day-ahead forecast sequence covering all time periods of the day, the continuously updated intraday forecast set released on a rolling basis during the trading day, and the actual power sequence that is finally determined after the end of the trading day.

[0036] Furthermore, the day-ahead forecast sequence contains multiple chronologically ordered power generation forecasts, each corresponding to a trading moment within a trading day. The day-ahead forecast sequence is a complete set of forecasts released before the start of the trading day (e.g., the previous day).

[0037] The intraday forecast set comprises multiple forecast subsequences released on a rolling basis at different times throughout the trading day. Each forecast subsequence contains power generation forecasts for a consecutive range of trading hours. The intraday forecast set refers to the forecast information dynamically generated on a trading day. It consists of multiple forecast subsequences released on a rolling basis at different times throughout the trading day. Each such subsequence is, in fact, a set of power generation forecasts for a consecutive range of trading hours at its release time. This means that as the trading day progresses, the forecast information is continuously updated and revised, forming a set of forecast data streams that evolve over time.

[0038] The actual power sequence contains the actual power generation values ​​corresponding to each trading moment within a trading day. It is a post-confirmation data sequence that includes the actual power generation values ​​corresponding to each trading moment within a trading day. This sequence is only fully determined after the trading day ends, and in the context of the methodology, it primarily serves as an objective factual benchmark for evaluating forecast accuracy and calculating trading results.

[0039] In one embodiment, the selected trading day D is divided into N consecutive and equal-length time periods, with time period indices t∈{1,2,...,N}. For example, if the interval is 15 minutes, then N=96.

[0040] The current day prediction sequence can then be represented as: PDA={pDAt | t∈{1,2,...,N}}, Where pDAt represents the power generation forecast for the t-th period within trading day D, published before the start of trading day D (e.g., on day D-1).

[0041] The intraday forecast set can be represented as: PID={pIDτ| τ∈{1,2,...,N-1}}, The intraday forecast set is a set of forecasts that are rolled out across multiple release times τ on trading day D, where τ∈{1,2,...,N-1}. pIDτ represents the intraday forecast sequence pIDτ covering the time period τ to N released at release time τ, which can be further expressed as: pIDτ=[pID(τ,τ+1), pID(τ,τ+2), ...,pID(τ,N)].

[0042] Where pID(τ,τ+1) represents the predicted power generation value at the time of release (τ+1) at the time of release τ.

[0043] The actual power sequence can be represented as: PACT={pACTt | t∈{1,2,...,N}}, Where pACTt represents the actual power generated in the t-th time period within trading day D. This sequence is fully acquired after the selected trading day ends and serves as an objective benchmark in the simulation to verify prediction bias and calculate trading results.

[0044] In one embodiment, the actual power sequence can be obtained from a different business system than the day-ahead and intraday forecast sequences. The dataset construction steps include: The forecast sequence, forecast subsequence, and actual power sequence are time-aligned according to the same set of trading times preset for the trading day.

[0045] Since the predicted sequences, multiple predicted subsequences released on a rolling basis, and the actual power sequences may come from different systems, and the original data may differ in timestamps, sampling frequencies, or time intervals, directly merging them may lead to analytical biases due to inconsistent time bases.

[0046] For example, for day-ahead forecast sequences, it is necessary to extract forecast reports that are generated and published before the start of trading day D (such as at a fixed time on day D-1) from the power plant's power forecast system, covering the entire period of trading day D.

[0047] For intraday forecast sequences, it is necessary to extract all forecast records published on trading day D at a preset high frequency (e.g., every 15 minutes) from the rolling forecast log of the same power forecast system. Each record contains its publication time τ and the corresponding forecast vector. All records need to be parsed and stored according to publication time and target time period to construct a complete set of PIDs.

[0048] For the actual power sequence, historical power sampling data for the entire trading day D can be extracted from the smart meter database of the power plant. This data is usually recorded at a high frequency (e.g., per minute) and needs to be aggregated according to the target time period t (e.g., by taking the average) to generate a sequence PACT with the same time resolution as the predicted sequence.

[0049] All data points from these three series are mapped and adjusted to a pre-defined set of trading times for that trading day. This set of trading times typically represents standard time points for electricity market settlement or decision-making (e.g., one time point every 15 minutes or hour). This mapping and adjustment ensures that predicted or actual values ​​from different series pointing to the same future period (or the same past period) have exactly the same time index in the dataset.

[0050] In this way, multiple data sequences that might have had inconsistent time structures are integrated into a unified and comparable time frame. This provides the necessary data consistency foundation for subsequent steps such as comparing predicted and actual values ​​at the same point in time, analyzing the evolution trend of predicted values ​​over time, and simulating trading decisions.

[0051] Based on the foregoing explanation, step S100 can be viewed as creating a "data snapshot" that can be used for historical playback or scenario analysis. This process requires ensuring that each value in PDA, PID, and PACT accurately points to the time period corresponding to any given time period index t. This involves standardizing time labels, processing timestamps, and ensuring that data is aggregated on the same time period boundaries.

[0052] Once aligned, this dataset encapsulates the complete information evolution of trading day D: from pre-trade expectation (PDA), to continuous updates during the trading process (PID), and finally to the actual outcome (PACT). This allows us to conduct simulations with the actual outcome (PACT) known, simulating how a decision-making mechanism would unfold its decision chain and ultimately lead to a trading result if it made judgments based on the progressively revealed predictive information (PDA and PID). This provides an indispensable data foundation for subsequent steps to systematically evaluate the performance of decision-making strategies under different predictive scenarios and to identify their potential vulnerabilities.

[0053] S102: For each trading day's corresponding dataset, simulate the preset trading strategy based on the dataset to obtain multiple decision prediction trajectories.

[0054] The trading strategy is used to make trading decisions at multiple preset trading times based on the day-ahead forecast sequence and the intraday forecast set to obtain trading contracts. Each decision prediction trajectory includes a trading decision sequence sorted by trading time, and the trading contracts corresponding to each trading decision in the trading decision sequence, and the trading results obtained based on the actual power sequence and each trading contract.

[0055] This step utilizes these datasets to perform historical simulations of a pre-defined initial trading strategy to be evaluated. The simulation process assumes that at each pre-defined trading decision point, the strategy can only make trading decisions based on the published daily and intraday forecasts, resulting in binding trading contracts. After simulating the entire trading day, these contracts are settled based on the actual power sequence, calculating the final trading outcome. Each complete simulation process, including all decisions, contracts, and results, is recorded as a decision prediction trajectory.

[0056] The trading strategy can be represented as a function that takes the set of predictive information available at a specific decision moment as input and outputs a specific trading instruction.

[0057] For example, each moment corresponding to the aforementioned time period index t∈{1,2,...,N} can be recorded as a decision moment. A decision prediction trajectory is generated through a decision strategy, which is equivalent to replaying the complete decision sequence of the strategy under a prediction scenario (defined jointly by PDA and PID) within the unique factual framework defined in the dataset (PACT as the final validation benchmark). This trading strategy can be analyzed using a simulation tool. Figure 2 This is a flowchart illustrating the simulation of a preset trading strategy based on a dataset, as provided in the embodiments of this specification. The simulation of the preset trading strategy based on the dataset includes: S200: Iterate through the day-ahead prediction sequence and intraday prediction set of the dataset in chronological order for each trading moment. S202: For the current trading time, execute: Based on the previous day's forecast sequence and the forecast subsequences in the intraday forecast set whose release time is no later than the current time, construct the currently available forecast information set; call the preset trading strategy, generate at least one trading decision based on the currently available forecast information set, and generate trading contracts corresponding to each trading decision; obtain the trading results based on the actual power sequence and each trading contract.

[0058] At each decision time T, the simulation tool extracts the intraday forecast subset {pIDτ|τ≤T} of all release times τ ≤ T from the PID, and combines it with the PDA to form the available forecast information set for the current time.

[0059] Then, the pre-defined trading strategy function is invoked, causing it to calculate based on the available set of predictive information and output one or more trading decisions. Each trading decision is typically represented as a trading instruction to deliver a certain amount of electricity in a specific future time period. Executing the trading decision creates or updates the corresponding trading contract. In practical applications, the trading contract has legal or market binding force, clearly defining the delivery quantity, time period, and price.

[0060] During this process, the simulation tool records the state data corresponding to the decision moment. The state data includes the window time T, the prediction information set, the generated trading decision, and the trading contract generated after the decision is executed.

[0061] S204: Combine the trading decisions, trading contracts, and trading results corresponding to each trading moment into a decision prediction trajectory.

[0062] Once the simulation covers all N time periods of trading day D, the settlement phase begins. The agreed-upon delivery volumes for each time period of all contracts held at the end of the simulation are compared with the actual power sequence PACT in the dataset, time period by time (t=1 to N). Based on the standard settlement rules of the electricity market (typically including contract execution revenue and imbalance costs arising from the deviation between actual power generation and contract delivery volume), the final trading result for this simulation is calculated and quantified using net profit as the indicator.

[0063] Then, the serialized decisions and the evolutionary state sequence of the transaction contract combinations recorded in chronological order throughout the simulation process, as well as the transaction results obtained from the final settlement, are packaged together into a structured decision prediction trajectory.

[0064] S104: Select several high-risk trajectories from various decision prediction trajectories whose transaction results meet the high-risk conditions, and determine at least one high-risk evolution mode based on the changing pattern of the power generation prediction value in each high-risk trajectory.

[0065] This step filters out those tracks from the large number of generated tracks that have poor trading results (i.e., meet the high-risk criteria), which are the high-risk tracks. The key is to move beyond simply focusing on the quality of the results and instead delve into the common patterns in the changes of the power generation forecasts over time in these failed cases. For example, it might be found that in most cases leading to losses, the intraday rolling forecasts show a continuous and significant downward revision trend in the estimated value for the same period. By summarizing and defining these commonalities, one or more specific high-risk evolution patterns can be identified.

[0066] Furthermore, a high-risk condition could be to sort all tracks from worst to best based on their trading results and select the tracks that rank at the bottom of a certain percentage (e.g., the top 20%); or to set an absolute financial loss threshold and filter out all tracks whose results are below this threshold.

[0067] In this approach, the screening process does not rely on an absolute, fixed loss threshold, but rather employs a relative comparison mechanism to accommodate potential differences in the overall distribution of trading results across various market environments or data samples. Its aim is to automatically focus the analysis on a series of decision-making processes that historically led to the most unsatisfactory trading outcomes, providing a target sample set for subsequent in-depth analysis of their common characteristics. Essentially, this method is a risk case identification strategy based on historical performance ranking.

[0068] Based on this, high-risk trajectories include records of decision-making processes that were judged as "failures" or "severely poor performance" under preset conditions. The purpose of screening is to narrow the analytical focus from broad average performance to the most representative negative cases, thereby improving the efficiency and relevance of subsequent analysis.

[0069] Furthermore, Figure 3 This is a flowchart illustrating the process of determining at least one high-risk evolution pattern based on the changing patterns of predicted power generation values ​​in various high-risk trajectories, as provided in the embodiments of this specification. The process includes the following steps: S300: For each high-risk trajectory, obtain the intraday forecast set corresponding to the high-risk trajectory.

[0070] S302: Analyze the changing trends of multiple electricity generation forecasts for the same future trading time within the intraday forecast set as their release time progresses. This step focuses on the dynamic characteristics of the intraday forecast set. Specifically, for the same future trading time, analyze multiple electricity generation forecasts generated at different release times, observing the changing trends of these values ​​as the release time approaches that time. For example, observe whether the forecast values ​​show a continuous unidirectional shift (such as continuous downward adjustment) or whether there is a certain regular fluctuation.

[0071] S304: By analyzing the similar changing trends identified in multiple high-risk trajectories, define at least one high-risk evolution pattern and establish corresponding triggering conditions for each high-risk evolution pattern.

[0072] Step S304 involves traversing multiple high-risk tracks and comparing the identified trends within each track. The aim is to identify recurring, similar trend characteristics. For example, it might be found that in multiple tracks leading to losses, the intraday forecasts showed sustained and significant downward revisions for certain periods.

[0073] Based on these identified, shared trends, at least one high-risk evolution pattern can be defined. Each pattern is essentially a general description of a specific, predictive dynamic process associated with adverse trading outcomes. Finally, to identify whether the pattern is occurring in actual trading, a quantifiable trigger condition needs to be established for each defined pattern. This condition typically includes specific provisions regarding the direction, continuity, and magnitude thresholds of the predicted value changes.

[0074] For example, for trajectory A, the day-ahead forecast sequence PDA = [100, 120, 90, 80,...] indicates that the predicted power generation is 100kW in the first period, 120kW in the second period, 90kW in the third period, and so on.

[0075] The intraday forecast set PID is rolled out on day D at times τ1, τ2, and τ3 (before the start of the first time period, at the end of the first time period, and at the end of the second time period, respectively). To focus on the core, this example illustrates how the forecast for the third time period evolves.

[0076] In the intraday forecast set, at time τ1, the forecast value for the third time period is pID(τ1, t3) = 85. Released at time τ2: The predicted value for the third time period is pID(τ2, t3) = 70; Released at time τ3: The predicted value for the third time period is pID(τ3, t3) = 55.

[0077] Then, the systematic deviation trend of the above forecast values ​​was analyzed: it can be observed that, starting from the first intraday forecast (85), all intraday forecast values ​​for t3 are lower than the previous day forecast values ​​(90), and as time gets closer to t3, the negative deviation of the forecast values ​​from the previous day forecasts continues to expand (from -5 to -20 and then to -35). This indicates that the intraday information flow systematically and continuously corrects the optimistic estimates made in the previous day downwards.

[0078] After analyzing a single high-risk trajectory, a preliminary pattern was discovered: "For the t3 period, intraday forecasts are continuously revised downwards relative to previous day's forecasts." To confirm that this is a universal pattern (rather than a coincidence), we need to compare and analyze multiple high-risk trajectories.

[0079] For example, suppose we analyze two other high-risk trajectories and find similar phenomena: The predicted evolution of trajectory B for time period t4: PDAt4=95, PID sequence [90, 78, 60].

[0080] Evolution of trajectory C for time period t2: PDAt2=110, PID sequence [105, 92, 80].

[0081] All three of these loss-leading trajectories show that, for one or more key periods, the PID exhibits a consistent and substantial downward adjustment trend as the decision window progresses, continuously moving away from the initial PDA value.

[0082] Based on the common characteristics of the aforementioned multiple trajectories, this type of predictive evolution process can be defined as a specific high-risk evolution pattern. For example, it can be assigned a unique identifier R1 and named "the intraday continuous large downward revision pattern under optimistic initial prediction". The triggering condition of this pattern can be further quantified as follows: "For any future period, if there are K consecutive (K≥2) updated values ​​in its intraday prediction sequence, and the decrease in the predicted value of each update compared to the previous update value (or compared to the predicted value of the previous day) exceeds a preset threshold X, then the predictive evolution of that period is determined to match this pattern." Here, K and X are configurable parameters. For example, K=2 and X=5% (or an absolute value threshold) can be set, which needs to be determined based on historical data statistical analysis.

[0083] S106: Generate a corresponding trading sub-strategy for each identified high-risk evolution pattern, and update the trading strategy based on the trading sub-strategy so that when the trading strategy is executed, if the changes in the real-time updated intraday forecast set match any high-risk evolution pattern, the trading sub-strategy corresponding to the high-risk evolution pattern is triggered.

[0084] Finally, step S106 generates a specific trading sub-strategy for each identified pattern. The goal of this sub-strategy is likely to make better decisions to mitigate risk in similar predictive evolution scenarios. Subsequently, the initial trading strategy is updated, incorporating a monitoring and response mechanism. During actual execution, the system monitors the latest intraday prediction set in real time. Once the evolution process is detected to match any predefined high-risk evolution pattern, the corresponding trading sub-strategy is automatically triggered, thereby dynamically adjusting the trading decision.

[0085] Therefore, the purpose of step S106 is to shift from risk analysis to risk response. Its input is one or more well-defined high-risk evolution patterns output from step S104. These patterns describe the dynamic changes in specific predictive data that have been validated by historical simulations and are significantly correlated with major trading losses.

[0086] This step involves two main processes. First, for each identified high-risk evolution pattern, a corresponding trading sub-strategy needs to be generated. This generation process typically involves specialized optimization calculations designed to minimize financial losses in simulated or historical prediction scenarios that match the pattern's characteristics. This optimization process utilizes the high-risk trajectory data matching the pattern generated in step S102 as the basis for analysis. The generated trading sub-strategy is essentially a specific set of trading rules or parameters, specifically designed to offset the risk exposure brought about by its corresponding pattern.

[0087] Secondly, the original trading strategy needs to be updated based on the generated trading sub-strategies. This update does not completely replace the original logic, but rather constructs a composite decision-making architecture that includes conditional judgments. The updated trading strategy will integrate a "pattern-sub-strategy" mapping knowledge base, while retaining the original strategy as the benchmark strategy.

[0088] When the updated strategy is executed, its operating mechanism will change. It will continuously monitor the evolution of the real-time input intraday forecast set and compare this evolution with the quantitative judgment conditions of various high-risk evolution patterns stored in the knowledge base. If the change pattern of the real-time forecast data is detected to match a certain pattern in the knowledge base, the decision-making process will automatically trigger the execution of the trading sub-strategy bound to that pattern, and use its output as the current trading instruction. If no match is detected with any defined pattern, the system will continue to execute the original baseline strategy.

[0089] This step endows the trading strategy with a conditional response capability based on real-time information status. The aim is to automatically invoke pre-set targeted solutions when the system identifies a known high-risk situation forming by predicting the evolution of the data stream, thereby potentially avoiding or reducing losses that might arise from following the original benchmark strategy. This transforms the entire trading strategy's decision-making mechanism from static execution to a model with dynamic risk intervention capabilities.

[0090] Based on the foregoing embodiments, the matching methods for high-risk evolution patterns include: For any future trading moment, if there are multiple consecutive updates of the forecast value for that moment in the intraday forecast set, and the direction of change of the forecast value of each update is consistent with the previous update value or the corresponding forecast value in the previous day's forecast sequence, and the magnitude of change exceeds the preset threshold, then the evolution of the current forecast data is determined to match a high-risk evolution pattern.

[0091] Furthermore, Figure 4 This is a flowchart illustrating the process of generating a corresponding trading sub-strategy for each identified high-risk evolution pattern, as provided in the embodiments of this specification. Generating a corresponding trading sub-strategy for each identified high-risk evolution pattern includes: S400: For any high-risk evolution pattern, extract all high-risk trajectories that match the high-risk evolution pattern. First, from all high-risk trajectories, select those whose predicted data evolution process matches the triggering conditions of the target high-risk evolution pattern. These trajectories constitute a dedicated dataset for training the corresponding sub-strategy; their common characteristic is that they all experienced the same unfavorable predictive change pattern and ultimately led to poor trading results.

[0092] S402: For each high-risk trajectory, identify the specific decision moments that trigger the high-risk evolution pattern.

[0093] For each selected trajectory, the system can precisely identify the decision point or points in the simulated trading day where the target high-risk evolution pattern is first triggered (i.e., the predicted data begins to match the pattern judgment conditions). Taking the previous "continuous large downward revision" pattern as an example, if at time τ2 of a certain trading day, the system identifies that the prediction for a certain period of time has met the condition of two consecutive large downward revisions, then time τ2 is a pattern trigger point.

[0094] S404: Generate a training sample based on the system state at each decision point; wherein the system state includes the prediction data state at that decision point, the trading contract, and the accumulated trading results from that decision point to the end of the trading day.

[0095] At each triggered decision moment, the system captures a complete snapshot of the system state as a training sample. This system state mainly includes three aspects of information: 1) Forecast data state: all available day-ahead and intraday forecast information at the current moment; 2) Trading contracts: all market positions established and held up to the current moment, representing the constraints formed by the accumulation of historical decisions; 3) Trading results: the portion of trading results calculated based on the final actual power sequence from the current trigger moment until the end of the trading day (which can be understood as "unchangeable predetermined losses" or "risk exposure for the remaining period").

[0096] S406: Obtain the strategy parameters corresponding to the high-risk evolution pattern based on each training sample. Perform an optimization process using all the training samples. The core of this process is to construct a strategy optimization model whose optimization objective is to minimize the expected subsequent trading losses by adjusting trading decisions after the target high-risk evolution pattern is triggered. The model's input is the system state from the training samples, and its output is a set of strategy parameters to be optimized (e.g., the trigger threshold or trading volume coefficient for a certain hedging order). By solving this model, a set of strategy parameters that perform optimally in historical scenarios of this pattern can be obtained.

[0097] S408: Bind the acquired strategy parameters with the triggering conditions of high-risk evolution patterns to form a trading sub-strategy.

[0098] Finally, the optimized strategy parameters are bound to the trigger conditions of the target high-risk evolution pattern. The resulting trading sub-strategy operates on the following logic: once the predicted data evolution matches the trigger condition in real time, the system uses these optimal parameters to calculate specific trading adjustment instructions based on the current real-time system state (similar to the state of the training samples).

[0099] Furthermore, based on each training sample, the policy parameters corresponding to the high-risk evolution patterns are obtained, including: A strategy optimization model is constructed with the goal of minimizing the expected trading loss after the high-risk evolution pattern of the target is triggered. The input of the strategy optimization model is the system state in the training samples, and the output of the strategy optimization model is a set of strategy parameters. Solve the strategy optimization model to obtain a set of optimal strategy parameters for high-risk evolution patterns.

[0100] To illustrate the process of obtaining this strategy parameter more specifically, we will use a simplified example. For instance, a high-risk evolution pattern has been identified, named M1, which is defined as "two consecutive downward revisions to the intraday forecast value for a future period, with each revision exceeding 10kW".

[0101] Step 1: Preparing Training Samples. Following the previous steps, five historical high-risk trajectories have been extracted, and their predicted data evolution all match Pattern M1. For each trajectory, we pinpoint the decision moment when Pattern M1 was triggered. At that moment, a training sample is recorded, encapsulating the system state at that time: for example, the latest predicted data at that moment shows that the target period's power expectation has been significantly lowered; existing trading contracts indicate that we still have a 50kW power sales commitment for that period; and forward-looking trading results show that, based on subsequent actual power generation data, holding the contract from this moment until the end of the trading day will result in an estimated loss of 200 yuan.

[0102] Step 2: Define Strategy Parameters and Optimization Model. Next, a specific trading sub-strategy needs to be designed to address pattern M1, and its key parameters need to be determined. For example, we decide that this sub-strategy adopts a "hedging trading" logic: when pattern M1 is triggered, the strategy suggests immediately purchasing a certain amount of electricity in the real-time market to hedge against the risk that future power sales contracts may not be fulfilled due to insufficient power generation. Here, the "purchased electricity" is a decision that needs to be optimized, which can be expressed as a proportionality coefficient k relative to the current risk exposure (e.g., the gap between contracted electricity sales and the latest predicted power generation). This proportionality coefficient k is the strategy parameter to be solved.

[0103] Therefore, a strategy optimization model is constructed. The input to the model is the system state (including predicted gaps, existing contracts, etc.) in each training sample. For any sample, given a trial value of a parameter k, the model can calculate the improvement in trading results (i.e., how much loss is reduced) after acting according to the rule of "buying the gap ratio k of electricity". The optimization objective of the model is to find the optimal value of k such that when applied to all training samples, it can minimize the average expected trading loss after the pattern is triggered, or in other words, minimize the overall loss.

[0104] Step 3: Solving for the optimal parameters. The model is solved using mathematical optimization algorithms (such as gradient descent, genetic algorithms, etc.). The solution process repeatedly tries different values ​​of k, simulating their effect on each historical training sample, and finally converges to a k* value that optimizes the objective function (minimizing the total loss), for example, k* = 0.7. This means that, based on historical experience, when mode M1 is triggered, immediately buying 70% of the currently predicted power gap as a hedge may be a relatively effective way to mitigate subsequent losses in most cases.

[0105] Thus, we obtain a set of optimal strategy parameters (k*=0.7) for pattern M1, obtained through data-driven optimization. Binding these parameters to the triggering conditions of pattern M1 forms an executable, quantitative trading sub-strategy. It should be noted that the effectiveness of these parameters largely depends on the representativeness of the training samples and the rationality of the optimization model. In practical applications, regular calibration and updates can be used to keep the trading strategy in a relatively optimal state in real time.

[0106] Please see Figure 5 , Figure 5 This is a schematic diagram of a photovoltaic power generation multi-scale power prediction and trading optimization system provided in the embodiments of this specification. The system includes: The data acquisition module is used to build a corresponding dataset for each pre-selected trading day. The dataset contains a set of pre-day forecast sequences, intraday forecast sets, and actual power sequences for each trading day. The trajectory generation module is used to simulate a preset trading strategy based on the dataset corresponding to each trading day to obtain multiple decision prediction trajectories. The trading strategy is used to make trading decisions at multiple preset trading times based on the daily prediction sequence and the intraday prediction set to obtain trading contracts. Each decision prediction trajectory includes a trading decision sequence sorted by trading time, and the trading contracts corresponding to each trading decision in the trading decision sequence, and the trading results obtained based on the actual power sequence and each trading contract. The risk screening module is used to select several high-risk trajectories from various decision prediction trajectories, and to determine at least one high-risk evolution pattern based on the changing pattern of the power generation prediction value in each high-risk trajectory. The strategy adjustment module is used to generate a corresponding trading sub-strategy for each identified high-risk evolution pattern, and update the trading strategy based on the trading sub-strategy, so that when the trading strategy is executed, if the changes in the real-time updated intraday forecast set match any high-risk evolution pattern, the trading sub-strategy corresponding to the high-risk evolution pattern will be triggered.

[0107] The embodiments of the subject matter and functional operation described in this specification can be implemented in the following ways: digital electronic circuits, tangibly embodied computer software or firmware, computer hardware including the structures disclosed in this specification and their structural equivalents, or combinations thereof. Embodiments of the subject matter described in this specification can be implemented as one or more computer programs, i.e., one or more modules of computer program instructions encoded on a tangible, non-transitory program carrier for execution by a data processing apparatus or for controlling the operation of a data processing apparatus. Alternatively or additionally, the program instructions may be encoded on artificially generated propagation signals, such as machine-generated electrical, optical, or electromagnetic signals, which are generated to encode information and transmit it to a suitable receiving device for execution by the data processing apparatus. The computer storage medium may be a machine-readable storage device, a machine-readable storage substrate, a random or serial access memory device, or combinations thereof.

[0108] The processing and logic described in this specification can be executed by one or more programmable computers that execute one or more computer programs to perform corresponding functions by operating on input data and generating output.

[0109] Suitable computers for executing computer programs include, for example, general-purpose and / or special-purpose microprocessors, or any other type of central processing unit. Typically, the central processing unit receives instructions and data from read-only memory and / or random access memory. The basic components of a computer include a central processing unit for implementing or executing instructions and one or more memory devices for storing instructions and data. Typically, a computer will also include one or more mass storage devices for storing data, such as disks, magneto-optical disks, or optical disks, or the computer will be operatively coupled to such mass storage devices to receive data from or transfer data to them, or both. However, a computer is not required to have such devices. Furthermore, a computer can be embedded in another device, such as a mobile phone, a personal digital assistant (PDA), a mobile audio or video player, a game console, a global positioning system (GPS) receiver, or a portable storage device such as a universal serial bus (USB) flash drive, to name a few.

[0110] Computer-readable media suitable for storing computer program instructions and data include all forms of non-volatile memory, media, and memory devices, such as semiconductor memory devices (e.g., EPROM, EEPROM, and flash memory devices), magnetic disks (e.g., internal hard disks or removable disks), magneto-optical disks, and CD-ROM and DVD-ROM disks. Processors and memory may be supplemented by or incorporated into dedicated logic circuitry.

[0111] While this specification contains numerous specific implementation details, these should not be construed as limiting the scope of any invention or the scope of the claims, but rather are primarily intended to describe features of specific embodiments of a particular invention. Certain features described in the various embodiments herein may also be implemented in combination in a single embodiment. Conversely, various features described in a single embodiment may also be implemented separately in various embodiments or in any suitable sub-combination. Furthermore, while features may function in certain combinations as described above and even initially claimed in this way, one or more features from a claimed combination may be removed from that combination in some cases, and a claimed combination may refer to a sub-combination or a variation thereof.

[0112] Similarly, although the operations are depicted in a specific order in the accompanying drawings, this should not be construed as requiring these operations to be performed in the specific order shown or sequentially, or requiring all illustrated operations to be performed to achieve the desired result. In some cases, multitasking and parallel processing may be advantageous. Furthermore, the separation of various system modules and components in the above embodiments should not be construed as requiring such separation in all embodiments, and it should be understood that the described program components and systems can generally be integrated together in a single software product or packaged into multiple software products.

[0113] Thus, specific embodiments of the subject matter have been described. Other embodiments are within the scope of the appended claims. In some cases, the actions recited in the claims may be performed in a different order and still achieve the desired result. Furthermore, the processes depicted in the drawings are not necessarily shown in a specific order or sequence to achieve the desired result. In some implementations, multitasking and parallel processing may be advantageous.

[0114] The above description is merely a preferred embodiment of this application and is not intended to limit this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of protection of this application.

Claims

1. A method for multi-scale power prediction and trading optimization of photovoltaic power generation, characterized in that, include: For each pre-selected trading day, a corresponding dataset is constructed, which includes a set of pre-day forecast sequences, an intraday forecast set, and an actual power sequence for that trading day. For each trading day's corresponding dataset, a preset trading strategy is simulated based on the dataset to obtain multiple decision prediction trajectories. The trading strategy is used to make trading decisions at multiple preset trading times based on the previous day's prediction sequence and the intraday prediction set to obtain trading contracts. Each decision prediction trajectory includes a trading decision sequence sorted by trading time, and trading contracts corresponding to each trading decision in the trading decision sequence, and trading results obtained based on the actual power sequence and each trading contract. From the various decision prediction trajectories, select several high-risk trajectories whose transaction results meet the high-risk conditions, and determine at least one high-risk evolution mode based on the changing pattern of the power generation prediction value in each high-risk trajectory. For each identified high-risk evolution pattern, a corresponding trading sub-strategy is generated. The trading strategy is then updated based on the trading sub-strategy, so that when the trading strategy is executed, if the changes in the real-time updated intraday forecast set match any high-risk evolution pattern, the trading sub-strategy corresponding to the high-risk evolution pattern is triggered.

2. The photovoltaic power generation multi-scale power prediction and trading optimization method according to claim 1, characterized in that, The day-ahead forecast sequence contains multiple power generation forecasts arranged in chronological order, with each forecast corresponding to a trading moment on the trading day; The intraday forecast set includes multiple forecast subsequences that are rolled out at different release times on the trading day, and each forecast subsequence contains the power generation forecast values ​​corresponding to multiple consecutive trading times. The actual power sequence includes the actual power generation value corresponding to each trading moment in the trading day.

3. The photovoltaic power generation multi-scale power prediction and trading optimization method according to claim 2, characterized in that, The steps for constructing the dataset include: The predicted sequence, the predicted subsequence, and the actual power sequence are time-aligned according to the same set of trading times preset for the trading day.

4. The photovoltaic power generation multi-scale power prediction and trading optimization method according to claim 2, characterized in that, The simulation of the preset trading strategy based on the dataset includes: The dataset is traversed sequentially through the day-ahead prediction sequence and the intraday prediction set for each trading moment in chronological order. For the current trading time, the following steps are performed: Based on the previous day's prediction sequence and the prediction subsequences in the intraday prediction set whose release time is no later than the current time, a currently available prediction information set is constructed; The preset trading strategy is invoked to generate at least one trading decision based on the currently available prediction information set, and trading contracts corresponding to each trading decision are generated; The trading result is obtained based on the actual power sequence and each trading contract. The trading decisions, trading contracts, and trading results corresponding to each trading moment are combined into a decision prediction trajectory.

5. The photovoltaic power generation multi-scale power prediction and trading optimization method according to claim 1, characterized in that, The step of selecting several high-risk trajectories from the various decision prediction trajectories whose transaction results meet the high-risk conditions includes: Based on the transaction results, multiple decision prediction trajectories are sorted, and the decision prediction trajectories at the end of the sorting results with a preset proportion are identified as high-risk trajectories.

6. The photovoltaic power generation multi-scale power prediction and trading optimization method according to claim 1, characterized in that, The determination of at least one high-risk evolution pattern based on the changing patterns of power generation forecasts in each high-risk trajectory includes: For each high-risk trajectory, obtain the intraday forecast set corresponding to the high-risk trajectory; The analysis examines the changing trends of multiple power generation forecasts for the same future trading time within the intraday forecast set as their release time progresses. By analyzing the similar trends identified in multiple high-risk trajectories, at least one high-risk evolution pattern is defined, and corresponding triggering conditions are established for each of the high-risk evolution patterns.

7. The photovoltaic power generation multi-scale power prediction and trading optimization method according to claim 6, characterized in that, The matching methods for the high-risk evolution patterns include: For any future trading moment, if there are multiple consecutive prediction updates for that moment in the intraday prediction set, and each updated prediction value changes in the same direction and the magnitude of the change exceeds a preset threshold compared to the previous updated value or the corresponding prediction value in the previous day prediction sequence, then the evolution of the current prediction data is determined to match the high-risk evolution pattern.

8. The photovoltaic power generation multi-scale power prediction and trading optimization method according to claim 1, characterized in that, The process of generating corresponding trading sub-strategies for each identified high-risk evolution pattern includes: Extract each high-risk trajectory that matches the high-risk evolution pattern of the target and construct a training set; For each high-risk trajectory in the training set, determine the decision moments at which the target high-risk evolution pattern is triggered; For each triggered decision moment, a training sample is generated based on the system state at that moment. The system state includes the predicted data state at that moment, the state of the relevant trading contracts already held, and the accumulated trading results from that moment to the end of the trading day. Based on multiple training samples, the strategy parameters are optimized to obtain a trading sub-strategy corresponding to the target high-risk evolution pattern.

9. The photovoltaic power generation multi-scale power prediction and trading optimization method according to claim 8, characterized in that, The step of obtaining the strategy parameters corresponding to the high-risk evolution pattern based on each of the training samples includes: A strategy optimization model is constructed with the goal of minimizing the expected trading loss after the high-risk evolution pattern of the target is triggered. The input of the strategy optimization model is the system state in the training samples, and the output of the strategy optimization model is a set of strategy parameters. Solve the policy optimization model to obtain a set of optimal policy parameters.

10. A photovoltaic power generation multi-scale power prediction and trading optimization system, characterized in that, include: The data acquisition module is used to construct a corresponding dataset for each pre-selected trading day. The dataset includes a set of pre-day forecast sequences, intraday forecast sets, and actual power sequences corresponding to the trading day. The trajectory generation module is used to simulate a preset trading strategy based on the dataset corresponding to each trading day to obtain multiple decision prediction trajectories. The trading strategy is used to make trading decisions at multiple preset trading times based on the previous day prediction sequence and the intraday prediction set to obtain trading contracts. Each decision prediction trajectory includes a trading decision sequence sorted by trading time, and trading contracts corresponding to each trading decision in the trading decision sequence, and trading results obtained based on the actual power sequence and each trading contract. The risk screening module is used to screen out several high-risk trajectories from the various decision prediction trajectories, and to determine at least one high-risk evolution mode based on the changing pattern of the power generation prediction value in each high-risk trajectory. The strategy adjustment module is used to generate a corresponding trading sub-strategy for each identified high-risk evolution pattern, and update the trading strategy based on the trading sub-strategy, so that when the trading strategy is executed, if the changes in the real-time updated intraday forecast set match any high-risk evolution pattern, the trading sub-strategy corresponding to the high-risk evolution pattern is triggered.