CN-122022512-A - Substation flood prevention response decision method and device, electronic equipment and medium
Abstract
The invention relates to a method, a device, electronic equipment and a medium for flood control response decision of a transformer substation, and belongs to the technical field of intelligent decision of the transformer substation; the method comprises the steps of inputting a flood control decision question into a preset large language model to obtain a flood control decision answer output by the large language model, determining a first loss value according to the difference between the flood control decision answer and a standard answer, determining the danger level of a flood control rule violated by the flood control decision answer according to a flood control rule base, determining a second loss value according to the danger level, fine-tuning the large language model according to the first loss value and the second loss value, and conducting a flood control response decision of a transformer substation through the fine-tuned large language model. The trimmed large language model can generate more reasonable flood control response decisions of the transformer substation based on flood control rule constraint.
Inventors
- SHI YING
- XU ZHONGHE
- PENG JIA
Assignees
- 武汉理工大学
Dates
- Publication Date
- 20260512
- Application Date
- 20251231
Claims (10)
- 1. The flood prevention response decision-making method of the transformer substation is characterized by comprising the following steps of: Constructing a flood control decision problem, a standard answer of the flood control decision problem and a flood control rule base according to the flood control information of the transformer substation; Inputting the flood control decision questions into a preset large language model to obtain flood control decision answers output by the large language model; determining a first loss value according to the difference between the flood control decision answer and the standard answer, determining a risk level of a flood control rule violated by the flood control decision answer according to the flood control rule base, and determining a second loss value according to the risk level; And fine tuning the large language model according to the first loss value and the second loss value, and carrying out flood prevention response decision of the transformer substation through the fine-tuned large language model.
- 2. The substation flood control response decision-making method according to claim 1, wherein the fine-tuning the large language model according to the first loss value and the second loss value comprises: Determining a mixed loss value by the following formula, and fine-tuning the large language model according to the mixed loss value: In the formula, Representing a mixing loss value; representing a first loss value; n represents the number of flood control decision questions; an ith input representing a large language model; representing the standard answer corresponding to the ith input, Θ representing training parameters of a large language model, gamma being preset safety constraint parameters, s being a flood prevention rule base A flood prevention rule in (2); Is a weight determined according to the risk level of the flood control rule, violate (s; Θ) is equal to 1 when the flood control decision answer generated under Θ violates the flood control rule s, otherwise 0.
- 3. The method for flood control response decision-making of a transformer substation according to claim 1, wherein the constructing a flood control decision question according to the transformer substation flood control data and a standard answer of the flood control decision question comprises: Generating a prompt word template and an answer generating prompt word template through a preset question, and constructing a flood control decision problem and a standard answer of the flood control decision problem according to the flood control data of the transformer substation.
- 4. The substation flood control response decision-making method according to claim 1, wherein the substation flood control data comprises expert question-and-answer dialogs, engineering monographs and power industry standards, historical flood control case logs and substation knowledge maps.
- 5. The method for making a flood control response decision of a substation according to claim 1, wherein the making a flood control response decision of a substation by the trimmed large language model comprises: acquiring a current flood control scene description, extracting static attributes and dynamic attributes of the current flood control scene from the current flood control scene description through the trimmed large language model according to a preset chain type thinking prompt template, and determining model tasks; and generating a flood prevention response decision of the transformer substation according to the static attribute, the dynamic attribute and the model task through the trimmed large language model.
- 6. The method for making a flood control response decision for a substation according to claim 5, wherein the generating the flood control response decision for a substation by the trimmed large language model according to the static attribute, the dynamic attribute and the model task comprises: Determining an associated flood control rule of the current flood control scene description according to the flood control rule library; And generating a substation flood control response decision according to the static attribute, the dynamic attribute, the model task and the associated flood control rule through the trimmed large language model.
- 7. The substation flood control response decision-making method according to claim 5, wherein the model tasks include identifying key risks, recommending immediate emergency actions, and optimizing resource allocation.
- 8. A flood prevention response decision device for a substation, comprising: the training set construction module is used for constructing flood control decision questions, standard answers of the flood control decision questions and a flood control rule base according to the flood control data of the transformer substation; The model training module is used for inputting the flood control decision questions into a preset large language model to obtain flood control decision answers output by the large language model; the loss value determining module is used for determining a first loss value according to the difference between the flood control decision answer and the standard answer, determining the danger level of the flood control rule violated by the flood control decision answer according to the flood control rule base, and determining a second loss value according to the danger level; and the substation flood prevention response decision module is used for carrying out fine adjustment on the large language model according to the first loss value and the second loss value, and carrying out substation flood prevention response decision through the fine-adjusted large language model.
- 9. An electronic device comprising a memory and a processor, wherein, The memory is used for storing programs; the processor, coupled to the memory, is configured to execute the program stored in the memory, to implement the steps in the substation flood control response decision method according to any one of the preceding claims 1 to 7.
- 10. A computer readable storage medium storing a computer readable program or instructions which when executed by a processor is capable of carrying out the steps of the flood control response decision method of a substation according to any one of claims 1 to 7.
Description
Substation flood prevention response decision method and device, electronic equipment and medium Technical Field The invention relates to the technical field of intelligent decision making of substations, in particular to a flood prevention response decision making method, device, electronic equipment and medium of a substation. Background In recent years, extreme storm disasters frequently happen, and the safety and the power supply reliability of a transformer substation are seriously threatened. In extreme weather conditions, emergency decisions of the transformer substation for flood attack are critical to the stability of the power system. Traditional flood control decision response methods can be divided into three main categories. The first type relies on historical data and empirically preset thresholds, for example, when the water level exceeds 1.0 meter, the system automatically activates the flood control pump. The method has remarkable effect in a stable scene, but is difficult to cope with abnormal conditions (such as sudden flood with the highest historic water level exceeding 300 percent), and environmental factors such as altitude gradient of a transformer substation are ignored. The second class adopts a deep learning model to improve flood prediction precision, but the method focuses on risk probability assessment rather than emergency scheme formulation, and is difficult to deal with cross-domain interaction problems. The third class is to implement disaster management through a large language model (Large Language Model, LLM). Recently introduced LLMs (e.g., qwen, deepSeek) exhibit powerful context understanding capabilities and multi-step reasoning capabilities that enable complex emergency schemes to be formulated. The development of artificial intelligence technology enables LLM to learn relevant experience from cases and make flood control corresponding decisions, and LLM also shows excellent capability in understanding relevant experience content and generating flood control decisions. However, if the generic LLM is directly applied to flood control tasks, a "phantom" answer is easily generated that departs from reality. For example, when asked to "how many sandbags are needed to close a 50 meter wide flood discharge opening", a generic LLM may calculate "200" such numbers from a simple area. While this result may be mathematically true, it completely ignores the realistic constraints that a single thin sandbag wall will be instantaneously unstable under turbulent water pressure and that it is difficult to achieve staging, filling and stacking of 200 sandbags for a limited emergency time. In addition, the flood control decision generated by the universal LLMs is easy to have the problem of lack of field constraint (such as safety rule), so that the flood control decision is unreasonable. Disclosure of Invention In view of the foregoing, it is necessary to provide a method, a device, an electronic device and a medium for flood control response decision of a transformer substation, which are used for solving the problem that the existing large language model is easy to generate flood control decisions which are out of reality and lack of field constraint. In order to solve the above problems, in a first aspect, the present invention provides a flood prevention response decision method for a substation, including: Constructing a flood control decision problem, a standard answer of the flood control decision problem and a flood control rule base according to the flood control information of the transformer substation; Inputting the flood control decision questions into a preset large language model to obtain flood control decision answers output by the large language model; determining a first loss value according to the difference between the flood control decision answer and the standard answer, determining a risk level of a flood control rule violated by the flood control decision answer according to the flood control rule base, and determining a second loss value according to the risk level; And fine tuning the large language model according to the first loss value and the second loss value, and carrying out flood prevention response decision of the transformer substation through the fine-tuned large language model. In one possible implementation manner, the fine tuning the large language model according to the first loss value and the second loss value includes: Determining a mixed loss value by the following formula, and fine-tuning the large language model according to the mixed loss value: In the formula, Representing a mixing loss value; representing a first loss value; n represents the number of flood control decision questions; an ith input representing a large language model; representing the standard answer corresponding to the ith input, Θ representing training parameters of a large language model, gamma being preset safety constraint parameters, s being a flood prevent