Multi-source heterogeneous data fusion and processing method based on localized LLM model

By using localized large language models for intelligent fusion and processing of multi-source heterogeneous data in factory energy management, the problems of low data processing efficiency, insufficient semantic understanding capabilities and insufficient real-time performance in the existing technology are solved, achieving high efficiency, Intelligent energy scheduling and management optimization.

CN119357880AInactive Publication Date: 2025-01-24UNIV OF ELECTRONIC SCI & TECH OF CHINA CHENGDU COLLEGE

Patent Information

Application Number
CN202411938607.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-26
Publication Date
2025-01-24
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

Existing factory energy management technologies are difficult to effectively process multi-source heterogeneous data, resulting in insufficient semantic understanding capabilities, low data processing efficiency, and lack of intelligent anomaly detection and real-time dynamic adaptability.

Method used

The intelligent integration and processing of multi -source heterogeneous data is used to use localized large language models (LLM), and through semantic analysis, multi -header attention mechanism, main component analysis, embedded dimension reduction and incremental learning to achieve deep integration and real -time optimization of data.

Benefits of technology

Significantly improves the efficiency and accuracy of data integration, provides high-quality data input, and solves the problem of insufficient semantic understanding; reduces computational complexity and improves the real-time and accuracy of data processing; realizes the detection of complex abnormal patterns The precise detection and intelligent correction enhance the stability and credibility of the data; it meets the real-time and adaptive capability requirements of the factory's dynamic energy dispatch.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119357880A_ABST
    Figure CN119357880A_ABST
Patent Text Reader

Abstract

The invention discloses a multi-source heterogeneous data fusion and processing method based on a localized LLM model, and relates to the technical field of factory energy management.The method comprises the steps that multi-source heterogeneous data is collected from a factory energy management system, and the collected original data is preprocessed and standardized; performing feature selection, feature extraction and feature combination on the processed data; carrying out embedding dimensionality reduction by adopting principal component analysis and a localized LLM model; performing intelligent semantic analysis and fusion on the dimension reduction feature data by utilizing a localized LLM model, performing weighted fusion on embedded vectors by adopting a multi-head attention mechanism, and extracting semantic association among the data; and performing intelligent anomaly detection on the fused high-quality data by using localized LLM model embedding analysis and cosine similarity calculation. According to the method, the processing efficiency and quality of the multi-source heterogeneous data are comprehensively improved, high-quality data support is provided for comprehensive energy management of factories, and efficient and intelligent energy scheduling and management optimization are achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of factory energy management, and in particular to a multi-source heterogeneous data fusion and processing method based on a localized LLM model. Background Art

[0002] In the comprehensive energy management of factories, current energy management technologies are mainly used for the coordinated operation of photovoltaic power generation, grid power supply and energy storage equipment, and efficient energy scheduling is achieved through data collection, processing and optimization. The existing technologies generally adopt the following methods: Rule-based algorithm: This method uses fixed rules and simple logic to process and integrate multi-source data. For example, a simple weighted combination of photovoltaic power generation and energy storage charging and discharging data is used to generate energy scheduling solutions.

[0003] Traditional machine learning models: Basic models such as linear regression and decision trees are used to predict load demand or optimize energy storage charging and discharging strategies.

[0004] These methods have high data requirements and are difficult to process complex multi-source heterogeneous data. Although the above methods have achieved the basic functions of energy management to a certain extent, they still have the following shortcomings when facing the intelligent processing and analysis of multi-source heterogeneous data: Insufficient semantic understanding capabilities: Existing technologies are mostly based on rule-based algorithms or simple machine learning models, which make it difficult to mine potential associations between data at the semantic level. For example, it is impossible to deeply analyze the complex relationship between photovoltaic power generation, energy storage response and production plan data.

[0005] Low data processing efficiency: Traditional methods have limited processing capabilities for high-dimensional data. Redundant features and data noise seriously affect model performance, resulting in low data utilization and decision-making efficiency.

[0006] Lack of intelligent anomaly detection: Rule-based anomaly detection methods are difficult to adapt to complex anomaly patterns, false detections and missed detections occur frequently, and data reliability is difficult to guarantee.

[0007] Insufficient real-time and dynamic adaptability: The existing system responds slowly in a dynamic environment and lacks the ability to adapt to real-time data changes, which affects the timeliness of scheduling optimization.

[0008] To solve the above problems, the present invention combines the semantic understanding ability of the localized large language model, applies it to the field of factory energy management, and proposes a multi-source heterogeneous data fusion and processing method based on the localized LLM model to improve the intelligent level of data processing. Summary of the invention

[0009] The purpose of the present invention is to propose a multi-source heterogeneous data fusion and processing method based on a localized LLM model, which realizes the intelligent fusion of multi-source data through semantic analysis and multi-head attention mechanism based on the localized LLM model, can deeply mine the implicit associations between data, significantly improve the efficiency and accuracy of data integration, provide high-quality data input for subsequent optimization, and solve the problem of insufficient semantic understanding ability in the background technology; By embedding the principal component analysis and localized LLM model into the dimension reduction, the redundant features are greatly reduced while retaining the main information, the computational complexity is reduced, and the problem of low data processing efficiency in the background technology is solved; The present invention utilizes localized LLM model embedding analysis combined with cosine similarity calculation to achieve accurate detection and intelligent correction of complex abnormal patterns, solving the problem of lack of intelligent abnormality detection in the background technology. The present invention utilizes localized deployment and incremental learning mechanisms. The present invention can quickly adapt to environmental changes, dynamically adjust data processing and optimization strategies, meet the dynamic energy scheduling needs of the factory, and solve the problems of insufficient real-time and dynamic adaptability.

[0010] The technical solution adopted by the present invention is as follows: The present invention is a multi-source heterogeneous data fusion and processing method based on a localized LLM model, comprising the following steps: Collect multi-source heterogeneous data from the factory energy management system as raw data, and transmit data through standardized communication protocols and unified data transmission interfaces; The collected raw data are preprocessed and standardized. Specifically, the interquartile range method is used to detect and eliminate outliers in multi-source heterogeneous data, and missing values ​​are filled based on the KNN algorithm before normalization. Perform feature selection, feature extraction and feature combination on the normalized data to obtain feature data, extract features highly relevant to energy scheduling based on correlation analysis, and remove redundant information; The principal component analysis and localized LLM model embedding dimensionality reduction are used to reduce the dimensionality of high-dimensional feature data to obtain reduced-dimensional feature data, which is used to optimize computing efficiency and improve data analysis performance; The localized LLM model is used to perform intelligent semantic analysis and fusion on the reduced-dimensional feature data. That is, the reduced-dimensional feature data is input into the localized LLM model to generate an embedding vector, and a multi-head attention mechanism is used to perform weighted fusion on the embedding vector to extract the semantic association between the data and obtain the fused high-quality data. The localized LLM model embedding analysis and cosine similarity calculation are used to perform intelligent anomaly detection on the fused high-quality data. The low-similarity data detected by anomaly is adjusted through intelligent correction strategies. The output reliable data provides decision support for optimizing factory energy scheduling.

[0011] Furthermore, the multi-source heterogeneous data collected from the factory energy management system are specifically: photovoltaic operation data, energy storage battery status data, electricity market price data, production plan data, load data, main network operation information and distribution network operation information and exchange power plan collected from photovoltaic power generation systems, energy storage equipment, power grid power supply systems and factory production management systems. The multi-source heterogeneous data are collected and transmitted in real time using standardized communication protocols.

[0012] Furthermore, the collected multi-source heterogeneous data are preprocessed and standardized, specifically: The interquartile range method is used to detect and remove outliers from multi-source heterogeneous data. First, the interquartile range is calculated: , Among them, Q1 represents the first quartile, which is the value at the 25% position after the data is sorted; Q3 represents the third quartile, which is the value at the 75% position after the data is sorted; IQR is the interquartile range, which represents the gap between Q1 and Q3 and reflects the central tendency of the data; Determine the bounds for outliers: Nether: , Upper bound: , Data points that are smaller than the lower bound or larger than the upper bound are considered outliers and are removed; The missing value is filled based on the KNN algorithm. The formula is as follows: ; in, is the missing value after filling, is the number of nearest neighbors selected, It is The value of the nearest neighbor; For a missing value, by finding its The missing value is filled by calculating the average value of the nearest neighbor values, and the information of similar samples in the data set is used to estimate the missing value, thereby reducing the impact of missing data on the analysis results. The Min-Max normalization method is used to scale the different data feature values ​​to the range of [0,1]: ; in, is a characteristic value of the original data, is the minimum value of the feature, is the maximum value of the feature, is the normalized eigenvalue. The formula scales the data to the range [0,1] so that the data value is between the minimum and maximum values.

[0013] Furthermore, the above-mentioned normalized data is subjected to feature selection, feature extraction and feature combination, and the specific steps are as follows: Feature selection: Based on correlation analysis, for all features in the data, the following formula is used to calculate the correlation between each feature and the energy scheduling target variable. The Pearson correlation coefficient is as follows: ; Correlation Coefficient is the Pearson correlation coefficient, which is used to measure the linear relationship between two continuous variables. The value ranges from -1 to 1. The closer the value is to 1 or -1, the stronger the linear relationship between the variables; the closer the value is to 0, the weaker the linear relationship between the variables. and represents the values ​​in the sample data, , is the mean of the sample data, is the sample size; Select the target variables related to factory energy scheduling Highly relevant key features , that is, the feature with the largest absolute value of the correlation coefficient; Feature extraction: Use Fourier transform to extract frequency domain features of data , the formula is as follows: ; in, is the frequency domain signal, that is, the result of Fourier transform, is the time domain signal, is the angular frequency , Through Fourier transform, from the time domain signal Convert to frequency domain signal , thereby determining the key frequency components and generating frequency domain features ; Feature combination: generating interactive feature data , improve data expression ability: , in, Interaction feature data, The key features for selection are is the frequency domain feature.

[0014] Furthermore, the principal component analysis and localized LLM model embedding dimensionality reduction are used, specifically: Principal component analysis: In numerical data, principal component analysis is used to project the data into a low-dimensional space and retain the main information: ; in, is the numerical data after dimensionality reduction, is the principal component of the feature matrix, is the characteristic data; Embedding dimensionality reduction based on localized LLM model: Generate low-dimensional embedding representation for unstructured data through localized LLM model: ; in, For unstructured data with reduced dimensionality, is the characteristic data; Dimensionality reduction effect evaluation: Evaluate the dimensionality reduction effect based on variance explanation rate or information entropy to ensure that information loss is minimized.

[0015] Furthermore, the localized LLM model is used to perform intelligent semantic analysis and fusion on the reduced dimension feature data. First, the reduced dimension feature data is input into the localized LLM model to generate an embedding vector. The formula is as follows: ; in, is the embedding vector, It is the feature data for dimension reduction, including unstructured data and numerical data; The multi-head attention mechanism is used to perform weighted fusion on the embedded vectors to extract the semantic association between the data. The formula is as follows: ; in, are query matrix, key matrix and value matrix respectively, is the key vector dimension, is the transpose of the key matrix, represents the weighted fusion result of the output, Indicates generating an attention distribution matrix, indicating the criticality of each key; In the multi-head attention mechanism, multiple independent attention heads are calculated in parallel, and the formula is: , Each attention head is calculated as: , in, , , is the projection matrix of each attention head, used to transform the original Projected into different low-dimensional subspaces, through Weighted fusion of attention mechanism, output of a single attention head, output of multiple attention heads Will be spliced ​​together, and the spliced ​​result is transformed through a linear weight matrix Projecting back to the original dimension, is the linear transformation weight matrix of the multi-head attention output, Indicates parallel computation of multiple attention heads, represents the concatenation of multiple attention heads, For the An attention head.

[0016] Furthermore, intelligent semantic analysis and fusion are performed on the multi-source heterogeneous data after dimensionality reduction. The fused high-quality data is divided into real-time data, historical data and predicted data according to time characteristics and usage characteristics. Real-time data is used for timely scheduling decisions, historical data is used for trend analysis, and predicted data is used for pre-planning. The specific formula is as follows: , in, is the reference value of the current time, , is the time threshold used to determine whether a data point belongs to the real-time, historical, or forecast category, and Categorg is the category.

[0017] Furthermore, the localized LLM model embedding analysis and cosine similarity calculation are used to perform intelligent anomaly detection on the fused high-quality data. The specific formula is as follows: ; in, and They are vectors and vector No. elements, is the vector dimension, CosineSimilarity is the cosine similarity, and the value of cosine similarity is between [-1,1]. The closer the value is to 1, the more similar the two vectors are, and the closer the value is to -1, the less similar the two vectors are. When the value is 0, it means that the two vectors are orthogonal and completely unrelated. The low-similarity data of anomaly detection is adjusted through intelligent correction strategies to ensure the integrity and reliability of the data.

[0018] Furthermore, the localized LLM model is to deploy the LLM model on a local server or edge computing device, and fine-tune the LLM model based on the factory energy management system. The localized LLM model supports incremental learning and real-time model updates: ; in, is the learning rate, is the loss function, For new input data, represents the current model parameters, represents the updated model parameters, Loss Function About Model Parameters The gradient of It is the newly input data, and the update is triggered when the input data volume reaches the threshold.

[0019] The present invention provides high-quality data support for factory energy management through multi-source heterogeneous data, preprocessing, feature extraction, data dimension reduction, intelligent fusion and anomaly detection, and realizes efficient and intelligent energy scheduling and management optimization.

[0020] In summary, due to the adoption of the above technical solution, the beneficial effects of the present invention are: 1. The present invention is a multi-source heterogeneous data fusion and processing method based on the localized LLM model. Through semantic analysis and multi-head attention mechanism based on the localized LLM model, the intelligent fusion of multi-source heterogeneous data is realized, which can deeply mine the implicit correlation between data, significantly improve the efficiency and accuracy of data integration, and provide high-quality data input for subsequent optimization.

[0021] 2. The present invention is a multi-source heterogeneous data fusion and processing method based on the localized LLM model. Through IQR detection, KNN algorithm missing value filling and normalization processing, the collected raw data is cleaned and standardized to solve the problems of outliers, missing values ​​and inconsistency in the data. After preprocessing, the data quality is improved and the format is consistent, providing reliable basic data for subsequent feature extraction and intelligent fusion, avoiding low-quality data from affecting the overall performance of the system.

[0022] 3. The present invention is a multi-source heterogeneous data fusion and processing method based on a localized LLM model. By embedding dimensionality reduction technology with principal component analysis and a localized LLM model, the present invention significantly reduces redundant features while retaining the main information, thereby reducing computational complexity, and improving the real-time performance of data processing and the prediction accuracy of subsequent models.

[0023] 4. The present invention is a multi-source heterogeneous data fusion and processing method based on the localized LLM model. It utilizes the localized LLM model embedding analysis combined with cosine similarity calculation to achieve accurate detection and intelligent correction of complex abnormal patterns, enhance the stability and credibility of the data, and ensure the accuracy of subsequent scheduling results.

[0024] 5. The present invention is a multi-source heterogeneous data fusion and processing method based on the localized LLM model. Through localized deployment and incremental learning mechanism, the present invention can quickly adapt to environmental changes, dynamically adjust data processing and optimization strategies, meet the dynamic energy scheduling needs of the factory, and achieve comprehensive improvement in real-time and adaptive capabilities. 6. The present invention is a multi-source heterogeneous data fusion and processing method based on the localized LLM model. Through the full-process intelligent data processing method, the present invention greatly reduces the need for manual intervention and improves the automation and intelligence level of energy scheduling and management. At the same time, intelligent decision-making based on high-quality data can effectively optimize the coordinated operation of photovoltaic energy storage and power grid, and reduce the overall energy cost of the factory.

[0025] 7. The present invention is a multi-source heterogeneous data fusion and processing method based on a localized LLM model. The present invention provides efficient and reliable technical support for comprehensive energy management of factories by comprehensively improving the efficiency, quality and intelligence level of data processing. Its beneficial effects are not only reflected in scheduling optimization and cost control, but also significantly improve the real-time and intelligence of the system, providing an innovative solution for comprehensive energy management of factories. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments. It should be understood that the following drawings only illustrate certain embodiments of the present invention and should not be regarded as limiting the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative work, among which: Figure 1 is a general method flow chart of embodiment 1 of the present invention; Figure 2 This is a multi-source heterogeneous data collection flow chart of the present invention; Figure 3 It is a data preprocessing flow chart of the present invention; Figure 4 It is a flow chart of data feature processing and dimensionality reduction of the present invention; Figure 5 It is a flow chart of intelligent data fusion based on localized LLM model of the present invention; Figure 6 The data classification and application flow chart of the present invention; Figure 7 The data anomaly detection and correction flow chart of the present invention; Figure 8 It is a schematic diagram of the localized deployment and real-time update mechanism of the present invention; Fig. 9 This is a relationship diagram between the production plan and energy demand of the present invention. DETAILED DESCRIPTION

[0027] In order to make the purpose, technical scheme and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention, that is, the embodiments described are only part of the embodiments of the present invention, rather than all of the embodiments. The components of the embodiments of the present invention described and shown in the drawings herein can be arranged and designed in various different configurations.

[0028] It should be noted that the terms "comprises", "includes" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, product or equipment that includes a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, product or equipment.

[0029] The LLM model, or Large Language Model, is a type of natural language processing model based on deep learning. It usually has billions to trillions of parameters and can handle complex language tasks. The following are the key points about LLM: Large-scale parameters: LLM models are usually composed of a large number of neural network parameters. For example, the number of parameters of models such as GPT-4 and PaLM has reached hundreds of billions. This large-scale parameter enables the model to capture subtle semantics and complex relationships in language.

[0030] Training Data: The datasets used to train LLM models usually cover a wide range of domains and include books, articles, web pages, etc. This enables the model to generate language output similar to that of humans.

[0031] Infrastructure: Most LLM models use the Transformer architecture, which can efficiently process long sequence data and support self-attention mechanism to understand contextual relationships.

[0032] The present invention deploys the LLM model locally in an edge computing device or server. In the present invention, the localized LLM model must be trained before using it, and multi-source heterogeneous data historical data of the factory energy management system is collected and preprocessed. The preprocessed data is used to train the localized LLM model. When training the localized LLM model, multiple key hyperparameters are adjusted to optimize the model performance: 1. Learning rate: Initially set to a small value, such as 0.001, and dynamically adjust the strategy according to the convergence of the model during the training process. For example, when the decline of the loss function of the model is less than a certain threshold in several consecutive training cycles, the learning rate can be appropriately reduced to avoid the model oscillating near the local optimal solution; on the contrary, if the loss function decreases rapidly, the learning rate can be appropriately increased to speed up the convergence.

[0033] 2. Batch Size: Select according to hardware resources and data size. In the early stage of training, try a smaller batch size, such as 32 or 64, to ensure that the model can converge quickly and adapt to data characteristics. As training progresses, gradually increase the batch size to 128 or 256 to improve training efficiency, but be careful to avoid memory overflow or model overfitting due to too large a batch size.

[0034] 3. Number of hidden layers and neurons: Determine by comparing the performance of models with different architectures through experiments. Start with a simple architecture, such as 2-3 hidden layers with 128-512 neurons in each layer, gradually increase the number of hidden layers and neurons, and observe the accuracy of the model on the validation set, loss function value and other indicators. Finally, determine the hidden layer structure that is suitable for the data characteristics of the energy management field, such as 3 hidden layers with 256, 128 and 64 neurons respectively, to balance the model's expressiveness and computational complexity.

[0035] 4. Training cycle, Epoch: Set a relatively large upper limit, such as 1000 epochs, but use the Early Stopping method to prevent overfitting. During the training process, monitor the loss function value on the validation set. When the loss function value does not decrease for several consecutive epochs, such as 10 epochs, stop training. The model parameters at this time are the better parameters obtained through training.

[0036] Example like Figure 1 As shown, the present invention proposes a multi-source heterogeneous data fusion and processing method based on a localized LLM model. Figure 1 It demonstrates multi-source heterogeneous data collection, raw data preprocessing, feature extraction, dimensionality reduction, intelligent data fusion and analysis based on localized LLM model, data classification, and anomaly detection, and shows the data flow and interaction between each link.

[0037] The specific process of each part is as follows: S1, multi-source heterogeneous data collection This embodiment collects multi-source heterogeneous data from multiple data sources such as photovoltaic power generation equipment, energy storage devices, power grid power supply systems, factory production management systems, etc. Figure 2 As shown, including: Photovoltaic operation data, such as power generation, light intensity, and temperature, covering operation data in different seasons and weather conditions to fully reflect various working conditions of photovoltaic power generation; Energy storage device data, such as historical data on charge and discharge status, battery capacity, SOH, and performance data under different charge and discharge rates and temperature environments, are used to train the LLM model to understand the characteristics and behavior patterns of energy storage devices; Electricity market price data; Load data, such as equipment operating power and production demand; Main network operation information and distribution network operation information, such as voltage, current, and power factor; Production planning data, such as order planning and production progress; In this embodiment, the collection and transmission of multi-source heterogeneous data are completed through standard communication protocols, such as Modbus, OPC, HTTP API, etc.

[0038] The present invention integrates various heterogeneous data such as photovoltaic power generation, energy storage devices, grid power supply, production plans and load data, supports multi-scenario application expansion, and provides an integrated solution for comprehensive factory energy management.

[0039] S2, data preprocessing and standardization like Figure 3 As shown in the figure, the specific steps of multi-source heterogeneous data preprocessing are demonstrated, including outlier detection, missing value filling, and data normalization to ensure data consistency and integrity. Multi-source heterogeneous data are used as raw data, and the collected raw data are cleaned and standardized to solve the problems of outliers, missing values ​​and inconsistent formats in the raw data.

[0040] First, outlier detection: Use the interquartile range method, i.e. IQR, to detect and remove outliers: , Among them, Q1 represents the first quartile, which is the value at the 25% position after the data is sorted; Q3 represents the third quartile, which is the value at the 75% position after the data is sorted; IQR is the interquartile range, which represents the gap between Q1 and Q3 and reflects the central tendency of the data; Determine the bounds for outliers: Nether: , Upper bound: , Data points that are smaller than the lower bound or larger than the upper bound are considered outliers and are removed; Missing value filling: The KNN algorithm is used to fill missing values. The KNN algorithm is the K-Nearest Neighbors algorithm, and the formula is as follows: ; in, is the missing value after filling, is the number of nearest neighbors selected, It is The nearest neighbor values ​​for a missing value are found by The missing value is filled by finding the nearest neighbors and then calculating the average of the values ​​of these nearest neighbors. In this way, the missing value can be estimated by using the information of similar samples in the data set, thereby reducing the impact of missing data on the analysis results.

[0041] Data normalization: Use the Min-Max method to normalize the data to the range [0,1]: ; in, is a characteristic value of the original data, is the minimum value of the feature, is the maximum value of the feature, is the normalized eigenvalue. The formula scales the data to the range [0,1] so that the data value is between the minimum and maximum values.

[0042] The present invention comprehensively improves data quality through IQR outlier detection, KNN missing value filling and Min-Max normalization methods, solves anomalies and inconsistencies in multi-source data, and provides high-reliability input for subsequent processing.

[0043] S3, data feature processing and dimensionality reduction like Figure 4 As shown, feature selection, feature extraction and feature combination are performed on the normalized data to extract key features related to factory energy management, remove redundant information and reduce data dimensions. Specifically: Feature Selection: Through correlation analysis, key features that are highly relevant to factory energy scheduling are selected , For all features in the data, the following formula is used to calculate the relationship between each feature and the plant energy scheduling target variable: The Pearson correlation coefficient is as follows: ; Correlation Coefficient is the Pearson correlation coefficient, which is used to measure the linear relationship between two continuous variables. The value ranges from -1 to 1. The closer the value is to 1 or -1, the stronger the linear relationship between the variables; the closer the value is to 0, the weaker the linear relationship between the variables. and represents the values ​​in the sample data, , is the mean of the sample data, is the sample size; Select the target variables related to factory energy scheduling Highly relevant key features , that is, the feature with the largest absolute value of the correlation coefficient.

[0044] Feature extraction: Extract frequency domain features using Fourier transform , used to identify periodic patterns, the formula is as follows: ; in, is the frequency domain signal, that is, the result of Fourier transform, is the time domain signal, is the angular frequency , Through Fourier transform, from the time domain signal Convert to frequency domain signal , thereby determining the key frequency components and generating frequency domain features ; Feature combination: generating interactive feature data , improve data expression ability: , in, Interaction feature data, The key features for selection are is the frequency domain feature.

[0045] In the feature selection process, the present invention selects key features that are highly relevant to energy scheduling based on correlation analysis and removes redundant information. For example, when analyzing the relationship between production plan data and energy demand, key features such as order plan quantity and production progress are identified, and there is a close linear or nonlinear relationship between these features and energy consumption. After feature extraction, such as Fourier transform to extract frequency domain features, and finally the interactive features generated by feature combination, the correlation between features is further enhanced, so that the data can more accurately reflect the inherent laws in the factory energy management system. For example, by combining the frequency domain features of photovoltaic operation data with the charge and discharge state features of energy storage equipment, the synergistic relationship between photovoltaic power generation and energy storage systems in time and energy conversion can be better revealed.

[0046] Dimensionality reduction: In numerical data, the PCA method, that is, the principal component analysis method, is used to reduce the data dimension, retain the main information, and effectively reduce the redundant features of the data: ; in, is the numerical data after dimensionality reduction, is the principal component of the feature matrix, is the characteristic data.

[0047] Embedding dimensionality reduction based on localized LLM model: Generate low-dimensional embedding representation for unstructured data through localized LLM model: , in, Generate low-dimensional semantic embeddings for unstructured data with reduced dimensionality, is the characteristic data.

[0048] Dimensionality reduction effect evaluation: Evaluate the dimensionality reduction effect based on variance explanation rate or information entropy to ensure that information loss is minimized.

[0049] The present invention uses the PCA method to perform dimensionality reduction processing on numerical data, projects high-dimensional data into a low-dimensional space, retains the main information, and effectively reduces the redundant characteristics of the data. For example, the original description of the operating status of a photovoltaic power generation system may require multiple related variables, such as data of multiple dimensions such as power generation, temperature, and light intensity in different time periods. After dimensionality reduction using the PCA method, these information can be represented by a few principal components, which reduces the complexity of the data while retaining the most critical information in the data, such as the main correlation patterns between power generation and environmental factors. For unstructured data, a localized LLM model is used for embedding and dimensionality reduction, converting it into a low-dimensional semantic embedding representation, so that the key information of the data at the semantic level is retained, and the dimensionality reduction facilitates subsequent calculations and analysis.

[0050] Correlation analysis, Fourier transform and interactive feature generation technology are used to extract the core features related to factory energy management. At the same time, principal component analysis (PCA) and localized LLM model embedding are used to reduce dimensionality and reduce redundant features, optimize data expression, improve processing efficiency, and facilitate subsequent semantic analysis and fusion through the localized LLM model.

[0051] S4, intelligent data fusion based on localized LLM model The localized LLM model of this embodiment has been fine-tuned in the field and is suitable for the field of factory energy management. The domain-fine-tuned localized LLM model is used to perform semantic analysis and deep fusion of multi-source heterogeneous data.

[0052] Embedding generation: Input the preprocessed data into the localized LLM model to generate an embedding vector: ; in, is the embedding vector, It is the feature data for dimension reduction, including unstructured data and numerical data; Multi-head attention mechanism fusion: The multi-source data features are weighted and fused through the attention mechanism to extract the semantic associations between the data: ; in, are query matrix, key matrix and value matrix respectively, is the key vector dimension, is the transpose of the key matrix, represents the weighted fusion result of the output, Indicates generating an attention distribution matrix, indicating the criticality of each key; In the multi-head attention mechanism, multiple independent attention heads are calculated in parallel, and the formula is: , Each attention head is calculated as: , in, , , is the projection matrix of each attention head, used to transform the original Projected into different low-dimensional subspaces, through Weighted fusion of attention mechanism, output of a single attention head, output of multiple attention heads Will be spliced ​​together, and the spliced ​​result is transformed through a linear weight matrix Projecting back to the original dimension, is the linear transformation weight matrix of the multi-head attention output, Indicates parallel computation of multiple attention heads, represents the concatenation of multiple attention heads, For the An attention head.

[0053] After domain fine-tuning, the localized LLM model of the present invention has the ability to deeply understand the data in the field of factory energy management. For the reduced-dimensional feature data, it can understand the meaning of each feature in the context of factory energy management, as well as the complex semantic relationships between features. For example, for the reduced-dimensional features in photovoltaic operation data, the localized LLM model can understand the semantic meaning of the changes in power generation under different production plans and energy storage states, whether it means that the energy supply is sufficient and energy storage is required, or that the supply is insufficient and energy needs to be supplemented, etc. This semantic understanding ability is not possessed by traditional data processing methods. The method of the present invention can dig out the deep-level information hidden behind the data, providing a more valuable basis for accurate energy scheduling.

[0054] Advantages of multi-source heterogeneous data fusion: Since the data in the factory energy management system comes from multiple different sources, such as photovoltaic power generation systems, energy storage equipment, production management systems, etc., the data types are diverse and the structures are complex, including structured numerical data and unstructured data, such as text descriptions in production plans. The localized LLM model can handle this multi-source heterogeneity and unify data of different types and sources at the semantic level for fusion analysis. After feature processing and dimensionality reduction, although the data has been simplified and optimized to a certain extent, a powerful tool is still needed to integrate the semantic information between different source data and realize knowledge association across data sources. For example, the product type, production quantity and other information in the production plan are integrated with the operating status information of photovoltaic power generation and energy storage equipment at the semantic level, so as to reasonably arrange energy supply and scheduling strategies according to production tasks and improve energy utilization efficiency.

[0055] Dynamic adaptability and real-time support: In factory energy management scenarios, data real-time requirements are high, and the system operating environment is constantly changing, such as production plan adjustments, weather changes affecting photovoltaic power generation, etc. The localized LLM model supports incremental learning and real-time updates, and can adjust model parameters in a timely manner according to the newly input data to adapt to the dynamically changing environment. Real-time data after feature processing and dimensionality reduction can be quickly input into the localized LLM model for analysis and fusion. The model can quickly understand the semantics of the new data and integrate it with historical data and other real-time data sources to provide the latest and accurate information for energy scheduling decisions in a timely manner. For example, when a temporary increase in emergency orders on the production line causes a change in the production plan, the localized LLM model can immediately adjust the energy allocation strategy based on the new production plan data and the current energy supply situation, including photovoltaic power generation and energy storage status, to ensure smooth production while achieving efficient use of energy.

[0056] like Figure 5 As shown, the process of semantic embedding generation of multi-source heterogeneous data through a domain-fine-tuned localized LLM model and semantic analysis and weighted fusion using a multi-head attention mechanism is demonstrated. This embodiment uses a localized LLM model to intelligently fuse multi-source heterogeneous data, extract deep associations between data, and improve the intelligence level of data integration.

[0057] Data input: Multi-source data, such as photovoltaic operation data, energy storage equipment data, production plan data, etc., are input into the domain-fine-tuned localized LLM model through different channels.

[0058] Domain-fine-tuned localized LLM model embedding generation: The domain-fine-tuned localized LLM model performs semantic analysis on the input data and generates a semantic embedding vector that reflects the deep correlation of the data.

[0059] Multi-head attention mechanism: The embedded vector is semantically analyzed through the multi-head attention mechanism, and the weights are fused into high-dimensional feature data to further improve the intelligence of data integration.

[0060] Fusion result output: The semantic embedding vector after weighted fusion is output as "fused high-quality data" for subsequent classification and scheduling optimization.

[0061] The present invention performs semantic analysis on the reduced-dimensional feature data through a domain-fine-tuned localized LLM model, utilizes a multi-head attention mechanism to achieve deep semantic fusion of data, mines implicit associations between data, significantly improves data processing efficiency and accuracy, and enhances the intelligent level of data integration.

[0062] S5, Data Classification The fused data is classified into real-time data, historical data and predicted data according to time and purpose. Real-time data is used for timely scheduling decisions, historical data is used for trend analysis, and predicted data is used for advance planning. All of these data are used to optimize real-time energy scheduling.

[0063] , in, is the reference value of the current time, , is the time threshold used to determine whether a data point belongs to the real-time, historical, or forecast category, and Categorg is the category.

[0064] like Figure 6 As shown, the data is divided into real-time data, historical data and predicted data according to time characteristics and application requirements, as well as the role of each type of data in different application scenarios. This embodiment illustrates how classified data can provide targeted support for immediate scheduling decisions, trend analysis and advance planning. The details are as follows: Data input: The fused high-quality data is used as input into the classification module.

[0065] Data classification part: According to time characteristics, data is divided into three categories: Real-time data classification, dynamic data with instant response.

[0066] Historical data classification, data records for past time periods.

[0067] Predictive data classification, future trend data generated based on the model.

[0068] Data application part: Different categories of data play a role in different application scenarios: real-time data is used for immediate scheduling decisions, historical data is used for trend analysis and identification of long-term patterns, and predictive data is used for advance planning and optimization of future resource allocation.

[0069] Output: The three types of data jointly support energy scheduling optimization and provide a reliable decision-making basis for comprehensive energy management of factories.

[0070] S6, data anomaly detection and correction The localized LLM model embedding analysis and cosine similarity are used to detect abnormal data and make intelligent corrections. The specific formula is as follows: ; in, and They are vectors and vector No. elements, is the vector dimension, CosineSimilarity is the cosine similarity, and the value of cosine similarity is between [-1,1]. The closer the value is to 1, the more similar the two vectors are, and the closer the value is to -1, the less similar the two vectors are. When the value is 0, it means that the two vectors are orthogonal and completely unrelated. If the similarity is lower than the set threshold, it is marked as an anomaly and the corrected data is injected back into the system through an intelligent correction strategy.

[0071] like Figure 7 As shown, the process of anomaly detection based on localized LLM model embedding analysis and cosine similarity calculation is demonstrated, as well as how the abnormal data after detection is intelligently corrected and re-injected into the data stream. This embodiment improves data quality and reliability through intelligent means and reduces the impact of abnormal data on decision-making.

[0072] Data input: The fused high-quality data is used as input and enters the anomaly detection process.

[0073] Anomaly detection part: Use the localized LLM model embedding analysis to extract data features, and use cosine similarity calculation to determine the degree of match between the data and the normal pattern. If the similarity is lower than the set threshold, it is determined to be abnormal data.

[0074] Abnormal correction part: Marking abnormal data: After identifying abnormal data, it is isolated and processed by marking; Intelligent correction strategy: Use historical data, contextual semantics, etc. to generate correction values ​​and adjust abnormal data to meet expected data.

[0075] Data reflow: The corrected data is reinjected into the data stream and output together with the normal data.

[0076] Output results: Output high-reliability data to ensure data quality and consistency, and provide reliable support for subsequent decision-making.

[0077] The present invention combines localized LLM model embedding analysis and cosine similarity calculation to accurately detect abnormal data, and restores the integrity and consistency of the data through intelligent correction strategies to ensure the stability and reliability of the system.

[0078] Figure 8 Local deployment and real-time update mechanism The present invention deploys the LLM model in a local server or edge device, performs domain fine-tuning based on the plant energy management system, supports the real-time update process of the model for incremental learning, protects data privacy and supports real-time processing, while meeting the adaptation needs in a dynamic environment.

[0079] Support incremental learning: Dynamically update model parameters through incremental data: ; in, is the learning rate, is the loss function, For new input data, represents the current model parameters, represents the updated model parameters, Loss Function About Model Parameters The gradient of is the newly entered data.

[0080] Trigger condition: trigger update when the input data volume reaches a threshold.

[0081] The specific process is as follows Figure 8 As shown: Data input and localized processing: Real-time data input, such as photovoltaic power generation data and energy storage equipment status data, is directly transmitted to the local server or edge computing device. The locally deployed LLM model ensures data privacy while quickly processing input data and generating decision support outputs.

[0082] Real-time processing and output: The localized LLM model processes real-time input data and generates decision support information for immediate application by the system.

[0083] Incremental learning trigger conditions: Real-time monitoring of whether the input data meets the incremental learning trigger conditions, such as changes in data distribution and data volume exceeding the threshold. When the trigger conditions are met, the system starts collecting incremental data.

[0084] Trigger conditions, specifically: Monitor the distribution changes of input data in real time, calculate the statistical characteristics of the data, such as mean, variance, covariance, etc., and compare them with the statistical characteristics of historical data. When the change in data distribution exceeds the preset threshold, for example, the mean change exceeds 10% or the variance change exceeds 20%, it is considered that the data has changed significantly, triggering incremental learning.

[0085] Monitor the amount of input data. When the amount of new input data reaches a certain threshold, such as 1,000 new valid data, start the incremental learning process. This ensures that the model is updated when there is enough new data to avoid overfitting or instability of the model due to too little data.

[0086] Model optimization and update: The collected incremental data is used to optimize the parameters of the localized LLM model. The updated localized LLM model is adapted to the dynamic environment. The optimized localized LLM model is fed back to the local server to replace the old version of the localized LLM model.

[0087] When incremental learning is triggered, new input data is collected and merged with historical training data. During the merging process, the new data is also preprocessed, such as outlier processing, missing value filling, and normalization, to ensure data consistency.

[0088] The localized LLM model is retrained using the merged data. During the training process, the idea of ​​transfer learning is adopted to initialize the model parameters to the parameters of the previous version of the model, and then only some model parameters related to the new data are fine-tuned. Specifically, some early layers of the model, such as the parameters of the first few layers, are frozen. These layers usually learn the common features of the data, and the parameters of subsequent layers, such as those close to the output layer, are updated to adapt to the knowledge changes brought by the new data.

[0089] During fine-tuning, hyperparameters such as the learning rate are adjusted according to the characteristics of the new data. For example, if the amount of new data is small, the learning rate can be appropriately reduced to avoid over-adjustment of the model; if the data distribution changes greatly, the training cycle can be increased to ensure that the model can fully learn the new data pattern.

[0090] The performance of the model on new data is evaluated by calculating the loss function, such as the cross entropy loss function or the mean square error loss function, and back propagation is performed based on the gradient of the loss function to update the model parameters. During the update process, techniques such as gradient clipping are used to prevent gradient explosion or disappearance and ensure the stability of model training.

[0091] Update completion notification: After the update is completed, the system notifies the update completion status, and the new localized LLM model begins to receive real-time data for processing.

[0092] The present invention deploys the LLM model locally in the edge computing device or server, realizes efficient data processing and analysis, ensures data privacy and realizes real-time processing, avoids excessive reliance on cloud computing, and dynamically updates the localized LLM model parameters through the incremental learning mechanism, thereby enhancing the energy system's ability to adapt to environmental changes.

[0093] like Fig. 9 As shown in the figure, it shows how production planning data affects load demand, and the process of adjusting energy storage and scheduling strategies through load data reflects the role of production planning data in energy demand management. Fig. 9 It explains how to dynamically match production demand with energy supply. The specific process is as follows: Production plan data input: Production plan data includes order requirements, production progress, capacity planning, etc., which are used as the core basis for energy demand management; Load demand analysis: Analyze the changing trend of load demand based on production plan data and predict energy demand in different periods; Energy storage strategy adjustment: Combined with the load demand analysis results, the charging and discharging strategy of the energy storage device is dynamically adjusted to adapt to the energy demand of production; Energy dispatch strategy optimization: Based on the adjusted energy storage strategy, optimize the energy dispatch plan, such as the allocation of photovoltaic power generation and grid power supply, to achieve accurate matching of production demand and energy supply; Result output: Through dynamic matching, ensure that energy supply meets production demand while optimizing energy utilization efficiency.

[0094] Through the above implementation methods, the present invention realizes the efficient collection, deep processing and intelligent fusion of multi-source heterogeneous data, provides high-quality data support for factory energy management in which photovoltaic energy storage and power grid operate in coordination, and significantly improves the real-time and intelligence level of the system.

[0095] In the present invention, the localized LLM model plays an important role in all aspects of data processing, specifically: Data collection stage: The localized LLM model plays a role in data verification and preprocessing guidance during the data collection process. Through preliminary analysis of the collected data, the semantic understanding ability of the model is used to identify abnormal patterns in the data, such as data that does not conform to physical laws or normal operating ranges, to provide a reference for subsequent data preprocessing. For example, if the model finds that the photovoltaic power generation power suddenly increases abnormally at a certain moment, exceeding the maximum power that can be generated by the light intensity in the area, it may indicate that the data collection equipment is faulty or the data transmission is wrong, so that timely inspection and correction can be carried out.

[0096] Data preprocessing: As mentioned above, the selection and preprocessing of model training data are closely coordinated with the preprocessing steps in the actual data fusion process. The requirements and processing methods for data quality during model training provide standards and references for actual data preprocessing, ensuring that the data actually input into the model has similar distribution and quality as the training data, thus improving the accuracy and stability of the model.

[0097] Feature selection, feature extraction, and feature combination: The localized LLM model can provide guidance for feature selection by learning from historical data. For example, the model can help determine which features are most critical in energy management based on the correlation analysis results between energy scheduling and each feature, so as to give priority to retaining these features in the feature selection step. In terms of feature extraction, the model can verify the effectiveness of feature extraction methods such as Fourier transform based on its understanding of data patterns, and perform semantic interpretation on extracted frequency domain features, making them easier to combine and analyze with other features. In the feature combination stage, the model can learn the interactive relationship between different features, provide a basis for generating more meaningful interactive features, and further improve the expressiveness of the data.

[0098] Dimensionality reduction processing: For the application of principal component analysis in dimensionality reduction of numerical data, the localized LLM model can assist in evaluating the dimensionality reduction effect. Through semantic analysis of the data after dimensionality reduction, it is determined whether the main information is effectively retained and whether the features after dimensionality reduction can still accurately reflect the key features of the data. For the embedded dimensionality reduction method based on the localized LLM model, the model directly converts unstructured data into a low-dimensional semantic embedding representation, which complements other dimensionality reduction methods to jointly reduce the redundant features of the data and improve data processing efficiency. At the same time, during the dimensionality reduction process, the model can adaptively adjust the dimensionality reduction strategy according to the semantic information of the data to ensure that the useful information in the data is retained to the maximum extent while reducing the dimension, providing a high-quality data foundation for subsequent intelligent fusion and analysis.

[0099] Intelligent data fusion link: The localized LLM model is the core of intelligent data fusion. After the reduced-dimensional feature data is input into the model to generate an embedding vector, the model uses its powerful semantic understanding ability to deeply explore the implicit associations between the data. Through the weighted fusion of the embedding vectors through the multi-head attention mechanism, the model can dynamically adjust the weights according to the importance and relevance of the data to achieve accurate extraction of semantic associations between data. For example, when fusing photovoltaic power generation data, energy storage equipment data, and production plan data, the model can focus on the power generation potential of photovoltaic power generation in the corresponding period and the available power of energy storage equipment according to the task arrangement in the production plan, so as to reasonably allocate energy supply strategies and improve the intelligence level of energy scheduling.

[0100] Data classification: The localized LLM model provides semantic understanding support in data classification. Based on the model's analysis of data semantics, combined with time characteristics and usage characteristics, the fused data can be more accurately divided into real-time data, historical data, and predicted data. For example, the model can identify time stamps and task priority information in production plan data, and classify real-time energy demand data that is closely related to current production tasks as real-time data so that it can be used in scheduling decisions in a timely manner; classify energy consumption data in past production cycles as historical data for trend analysis; and classify future energy demand and supply conditions predicted by the model as predicted data to provide a basis for advance planning.

[0101] Anomaly detection and correction link: Localized LLM model embedding analysis plays a key role in anomaly detection. The model extracts the feature representation of the data through semantic understanding of the data and compares it with the features of the normal mode. The cosine similarity calculation is used to determine the degree of deviation of the data from the normal mode, so as to accurately detect abnormal data. When abnormal data is detected, the model generates an intelligent correction strategy based on its understanding of the semantics of the data context, combined with historical data and normal operating modes. For example, if it is found that the charging current of the energy storage device is abnormally high at a certain moment, the model can refer to the normal charging current range under similar historical circumstances, as well as the current status of the energy storage device, such as power, temperature, etc., to generate reasonable correction values, adjust the abnormal data to meet the expected data, ensure the integrity and reliability of the data, and provide accurate data support for subsequent decision-making.

[0102] In summary, the present invention relates to the cross-application field of new energy and artificial intelligence technology, in particular, multi-source data processing and analysis technology for comprehensive energy management of smart factories. For factory power consumption scenarios, including the coordinated operation of photovoltaic power generation, power grid power supply and energy storage systems, the present invention covers intelligent collection, feature processing, fusion analysis and preprocessing methods of multi-source heterogeneous data. By introducing a localized large language model, i.e., an LLM model, semantic analysis, deep fusion, anomaly detection and real-time update processing are performed on multi-type energy data such as photovoltaic operation data, energy storage battery status data, electricity market price data, power distribution data, production load data, production plan data, energy storage response data, main network operation information and distribution network operation information. This method effectively solves the problems of low efficiency, poor quality and insufficient semantic association in the integration of multi-source heterogeneous data in the prior art, significantly improves the efficiency and quality of data preprocessing, and provides high-quality data support for energy consumption optimization, scheduling decision-making, production plan adjustment and factory energy management. The method of the present invention can be widely applied to smart factories, industrial parks and other complex multi-source energy storage systems, and can provide innovative technical solutions for factory energy management, optimized scheduling, production stability and cost control.

[0103] The above is only a preferred embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any changes or substitutions that can be thought of by a person skilled in the art within the technical scope disclosed by the present invention without creative work should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention should be based on the protection scope defined in the claims.

Claims

1. A multi-source heterogeneous data fusion and processing method based on a localized LLM model, characterized in that: The following steps are involved: Collect multi-source heterogeneous data from the factory energy management system as raw data, and transmit data through standardized communication protocols and unified data transmission interfaces; The collected raw data are preprocessed and standardized. Specifically, the interquartile range method is used to detect and eliminate outliers in multi-source heterogeneous data, and missing values ​​are filled based on the KNN algorithm before normalization. Perform feature selection, feature extraction and feature combination on the normalized data to obtain feature data, extract features highly relevant to energy scheduling based on correlation analysis, and remove redundant information; The principal component analysis and localized LLM model embedding dimensionality reduction are used to reduce the dimensionality of high-dimensional feature data to obtain reduced-dimensional feature data, which is used to optimize computing efficiency and improve data analysis performance; The localized LLM model is used to perform intelligent semantic analysis and fusion on the reduced-dimensional feature data. That is, the reduced-dimensional feature data is input into the localized LLM model to generate an embedding vector, and a multi-head attention mechanism is used to perform weighted fusion on the embedding vector to extract the semantic association between the data and obtain the fused high-quality data. The localized LLM model embedding analysis and cosine similarity calculation are used to perform intelligent anomaly detection on the fused high-quality data. The low-similarity data detected by anomaly is adjusted through intelligent correction strategies. The output reliable data provides decision support for optimizing factory energy scheduling.

2. The multi-source heterogeneous data fusion and processing method based on the localized LLM model according to claim 1 is characterized by: The multi-source heterogeneous data collected from the factory energy management system are specifically: photovoltaic operation data, energy storage battery status data, electricity market price data, production plan data, load data, main network operation information and distribution network operation information and exchange power plan collected from photovoltaic power generation systems, energy storage equipment, power grid power supply systems and factory production management systems. The multi-source heterogeneous data are collected and transmitted in real time using standardized communication protocols.

3. The multi-source heterogeneous data fusion and processing method based on the localized LLM model according to claim 1 is characterized by: Preprocess and standardize the collected multi-source heterogeneous data. Specifically: The interquartile range method is used to detect and remove outliers from multi-source heterogeneous data. First, the interquartile range is calculated: , Among them, Q1 represents the first quartile, which is the value at the 25% position after the data is sorted; Q3 represents the third quartile, which is the value at the 75% position after the data is sorted; IQR is the interquartile range, which represents the gap between Q1 and Q3 and reflects the central tendency of the data; determine the boundaries of outliers: Nether: , Upper bound: , Data points that are smaller than the lower bound or larger than the upper bound are considered outliers and are removed; The missing value is filled based on the KNN algorithm. The formula is as follows: ; in, is the missing value after filling, is the number of nearest neighbors selected, It is The value of the nearest neighbor; For a missing value, by finding its The missing value is filled by calculating the average value of the nearest neighbor values, and the information of similar samples in the data set is used to estimate the missing value, thereby reducing the impact of missing data on the analysis results. The Min-Max normalization method is used to scale the different data feature values ​​to the range of [0,1]: ; in, is a characteristic value of the original data, is the minimum value of the feature, is the maximum value of the feature, is the normalized eigenvalue. The formula scales the data to the range [0,1] so that the data value is between the minimum and maximum values.

4. The multi-source heterogeneous data fusion and processing method based on the localized LLM model according to claim 1 is characterized in that: The specific steps of performing feature selection, feature extraction and feature combination on the normalized data are as follows: Feature selection: Based on correlation analysis, for all features in the data, the following formula is used to calculate the correlation between each feature and the target variable of the plant energy scheduling. The Pearson correlation coefficient is as follows: ; Correlation Coefficient is the Pearson correlation coefficient, which is used to measure the linear relationship between two continuous variables. The value ranges from -1 to 1. The closer the value is to 1 or -1, the stronger the linear relationship between the variables. The closer the value is to 0, the weaker the linear relationship between the variables; and represents the values ​​in the sample data, , is the mean of the sample data, is the sample size; Select the target variables related to factory energy scheduling Highly relevant key features , that is, the feature with the largest absolute value of the correlation coefficient; feature Extraction: Use Fourier transform to extract frequency domain features of data , the formula is as follows: ; in, is the frequency domain signal, that is, the result of Fourier transform, is the time domain signal, is the angular frequency , Through Fourier transform, from the time domain signal Convert to frequency domain signal , thereby determining the key frequency components and generating frequency domain features ; Feature combination: generating interactive feature data , improve data expression ability: , in, Interaction feature data, The key features for selection are It is the frequency domain feature.

5. The multi-source heterogeneous data fusion and processing method based on the localized LLM model according to claim 1 or 4 is characterized in that: The principal component analysis and localized LLM model are used to embed dimension reduction, specifically: Principal component analysis: In numerical data, principal component analysis is used to project the data into a low-dimensional space and retain the main information: ; in, is the numerical data after dimensionality reduction, is the principal component of the feature matrix, is the characteristic data; Embedding dimensionality reduction based on localized LLM model: Generate low-dimensional embedding representation for unstructured data through localized LLM model: ; in, For unstructured data with reduced dimensionality, is the characteristic data; Dimensionality reduction effect evaluation: Evaluate the dimensionality reduction effect based on variance explanation rate or information entropy to ensure that information loss is minimized.

6. The multi-source heterogeneous data fusion and processing method based on the localized LLM model according to claim 5 is characterized in that: The localized LLM model is used to perform intelligent semantic analysis and fusion on the reduced-dimensional feature data. First, the reduced-dimensional feature data is input into the localized LLM model to generate an embedding vector. The formula is as follows: ; in, is the embedding vector, It is the feature data for dimension reduction, including unstructured data and numerical data; The multi-head attention mechanism is used to perform weighted fusion on the embedded vectors to extract the semantic association between the data. The formula is as follows: ; in, are query matrix, key matrix and value matrix respectively, is the key vector dimension, is the transpose of the key matrix, represents the weighted fusion result of the output, Indicates generating an attention distribution matrix, indicating the criticality of each key; In the multi-head attention mechanism, multiple independent attention heads are calculated in parallel, and the formula is: , Each attention head is calculated as: , in, , , is the projection matrix of each attention head, used to transform the original Projected into different low-dimensional subspaces, through Weighted fusion of attention mechanism, output of a single attention head, output of multiple attention heads Will be spliced ​​together, and the spliced ​​result is transformed through a linear weight matrix Projecting back to the original dimension, is the linear transformation weight matrix of the multi-head attention output, Indicates parallel computation of multiple attention heads, represents the concatenation of multiple attention heads, For the An attention head.

7. The multi-source heterogeneous data fusion and processing method based on the localized LLM model according to claim 1 is characterized by: Intelligent semantic analysis and fusion are performed on multi-source heterogeneous data after dimensionality reduction. The fused high-quality data is divided into real-time data, historical data and predicted data according to time characteristics and usage characteristics. Real-time data is used for timely scheduling decisions, historical data is used for trend analysis, and predicted data is used for pre-planning. The specific formula is as follows: , in, is the reference value of the current time, , is the time threshold used to determine whether a data point belongs to the real-time, historical, or forecast category, and Categorg is the category.

8. The multi-source heterogeneous data fusion and processing method based on the localized LLM model according to claim 1 is characterized by: The localized LLM model embedding analysis and cosine similarity calculation perform intelligent anomaly detection on the fused high-quality data. The specific formula is as follows: ; in, and They are vectors and vector No. elements, is the vector dimension, CosineSimilarity is the cosine similarity, and the value of cosine similarity is between [-1,1]. The closer the value is to 1, the more similar the two vectors are, and the closer the value is to -1, the less similar the two vectors are. When the value is 0, it means that the two vectors are orthogonal and completely unrelated. The low-similarity data of anomaly detection is adjusted through intelligent correction strategies to ensure the integrity and reliability of the data.

9. The multi-source heterogeneous data fusion and processing method based on the localized LLM model according to claim 1 is characterized in that: The localized LLM model is to deploy the LLM model on a local server or edge computing device, and fine-tune the LLM model based on the factory energy management system. The localized LLM model supports incremental learning and real-time model updates: ; in, is the learning rate, is the loss function, For new input data, represents the current model parameters, represents the updated model parameters, Loss Function About Model Parameters The gradient of It is the newly input data, and the update is triggered when the input data volume reaches the threshold.

Citation Information

Patent Citations

  • Intelligent electric energy meter reliability evaluation method based on survival analysis

    CN116522241A

  • Tranform parallel cross fusion model-based cellular lung disease course and period detection and evaluation method and device

    CN117275681A

  • Data knowledge extraction method for large language model

    CN117743838A

  • Anomaly detection method and system for industrial control network

    CN118133204A

  • Multi-source heterogeneous data fusion method and device for flight operation control

    CN118296560A

Cited By

  • Municipal engineering surveying and mapping method and system

    CN120493667A

  • Motor manufacturing quality intelligent detection system

    CN120629932A

  • Thermal runaway prediction method and device of power battery, storage medium and electronic equipment

    CN121276357A

  • LLM central multi-agent tool arrangement and virtual-real closed-loop evolution scheduling system

    CN121704387A

  • Intelligent community power utilization security data linkage processing method

    CN121705943A