Automatic modeling method for operation mechanism of building electromechanical system under few-shot labeling scenario

HK40135924BActive Publication Date: 2026-09-18SHANGHAI CONSTRUCTION FOURTH CONSTRUCTION GROUP CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
HK42026124440
Authority / Receiving Office
HK · HK
Patent Type
Patents
Current Assignee / Owner
Filing Date
2026-06-08
Publication Date
2026-09-18
Estimated Expiration
2045-11-30

AI Technical Summary

Technical Problem

Existing digital twin modeling methods for building electromechanical systems require a large number of manually labeled samples, are highly dependent on experts, and are difficult to generate interpretable operational mechanism models under small sample conditions, resulting in high modeling costs, poor interpretability, and difficulty in adapting to actual operational deviations.

Method used

By extracting static topology data and dynamic operation data of building electromechanical systems, a topology operation data graph is constructed. The GraphSAGE algorithm is used to extract node feature vectors. Combined with few-shot learning and meta-learning models, the system automatically classifies and generates interpretable system operation rules and causal relationship networks, reducing the reliance on expert annotation.

Benefits of technology

It enables efficient and automated modeling of the operating mechanism of building electromechanical systems under small sample conditions, reduces annotation costs, and improves the interpretability and adaptability of modeling, making it suitable for intelligent operation and maintenance of new or renovated projects.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 00000000_0000_ABST
    Figure 00000000_0000_ABST
Patent Text Reader

Abstract

The application discloses a building mechanical and electrical system operation mechanism automatic modeling method for a small sample labeling scene, comprising the following steps: extracting static topology data and dynamic operation data of a building mechanical and electrical system; constructing a topology operation data graph of the building mechanical and electrical system; extracting a node topology feature vector in the topology operation graph; performing small sample labeling on an operation mode in the topology operation graph and constructing a meta-learning task through small sample learning; automatically classifying and labeling an operation mode of a brand-new building mechanical and electrical system digital twin model graph, and automatically generating an interpretable system operation rule, a mathematical expression or a causal relationship network on the building mechanical and electrical system digital twin model graph as a building mechanical and electrical system digital twin operation mechanism model. The application reduces the number of artificially labeled samples, reduces the dependence on experts and labeling costs, and realizes efficient, automatic and understandable modeling of the building mechanical and electrical system operation mechanism under the condition of a small number of labeled samples.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of building operation and maintenance, and specifically to an automatic modeling method for the operation mechanism of building electromechanical systems in small sample annotation scenarios. Background Technology

[0002] In the field of building operation and maintenance, digital twin models of building electromechanical systems (EMS) are typically used for the operation and maintenance management of these systems. Currently, there are two main technical approaches to modeling EMS digital twins: physical mechanism models and data-driven models. Physical mechanism models rely on precise equipment parameters and system architecture knowledge. However, in actual installation projects, incomplete information or operational deviations often lead to insufficient model accuracy, resulting in complex modeling and difficulty in adapting to actual operational deviations. While data-driven models can adapt to complex systems, they require a large number of manually labeled samples to identify operating conditions and equipment status. However, in new construction or renovation projects, the scarcity of expert resources and high labeling costs lead to a serious data cold start problem, making modeling difficult and highly dependent on experts. Furthermore, existing technologies lack in-depth application of the topological relationships in EMS digital twin models, making it difficult to automatically generate interpretable digital twin models with operational mechanisms from a small number of labeled samples, thus hindering the widespread application of intelligent operation and maintenance technologies. Summary of the Invention

[0003] The purpose of this invention is to provide an automatic modeling method for the operation mechanism of building electromechanical systems in scenarios with small sample annotation, so as to solve the problems of existing building electromechanical system modeling methods, such as the need for manual annotation of a large number of sample data to identify operation modes and equipment status, strong expert dependence, large sample data volume, high modeling cost, and poor interpretability.

[0004] To address the aforementioned technical problems, the present invention provides the following technical solution: an automatic modeling method for the operating mechanism of building electromechanical systems in small-sample annotation scenarios, comprising:

[0005] Step 1: Extract the static topology data and dynamic operation data of the building's electromechanical system;

[0006] Step 2: Construct the topology operation data diagram of the building's electromechanical system;

[0007] Step 3: Extract the node topology feature vectors from the topology operation data graph of the building electromechanical system;

[0008] Step 4 involves labeling the operating modes in the topology operation data diagram of the building electromechanical system with small samples and constructing a meta-learning task through small sample learning, including:

[0009] Step 4.1: Establish an operational mode labeling system for the dynamic operation data of building electromechanical systems; divide the operational modes of building electromechanical systems into several categories to form an operational mode classification system. ,in For the operating modes of categories 1 to n, the operating modes labeled with categories are used as samples;

[0010] Step 4.2: Organize the episode training structure. Train the samples using the episode training structure from few-shot learning in machine learning. During the training process, randomly sample the data each time. The operating modes for each category are selected. A set of labeled category samples is used as the support set for a certain time period, and the remaining labeled category samples are used as the query set. This constitutes a meta-learning task. The meta-learning outputs the category of the operation mode in the unlabeled time period of the query set and labels it to form a meta-learning model, enabling small sample learning to quickly adapt to the labeling of operation mode categories.

[0011] Step 5: Automatically classify the operation modes of the new building electromechanical system digital twin model diagram to construct the building electromechanical system digital twin operation mechanism model;

[0012] The extracted node topology feature vectors are combined with the extracted dynamic operation data to construct a "topology-operation" joint feature vector, which is then input into the meta-learning model to automatically classify and label the operation modes of the novel building electromechanical system digital twin model under small sample conditions.

[0013] Step 6: Based on the automatic classification and labeling results in Step 5, automatically generate interpretable system operation rules, mathematical expressions, or causal relationship networks on the digital twin model diagram of the building electromechanical system as the operating mechanism model of the digital twin of the building electromechanical system.

[0014] Furthermore, the automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios provided by the present invention also includes:

[0015] Step 7, Validation and Iterative Optimization of the Meta-Learning Model: Through expert review, simulation comparison and online feedback mechanisms, continuously improve the accuracy and reliability of the meta-learning model in class identification of unlabeled operating modes, and validate and iteratively update the meta-learning model.

[0016] Furthermore, the automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios provided by the present invention includes the following steps in step 1: Extracting static topology data and dynamic operating data of the building electromechanical system.

[0017] Step 1.1: Extract the static topology data of the building electromechanical system from the digital twin model diagram of the building electromechanical system; the static topology data mainly includes the components of the building electromechanical system and the connection relationship information between the components, and also includes the component attribute information;

[0018] Step 1.2: Collect dynamic operation data of the building electromechanical system from the building automation system corresponding to the digital twin model diagram of the building electromechanical system and the sensors deployed on its corresponding nodes; wherein the dynamic operation data includes operation parameter information and operation status information; wherein the building automation system is the building electromechanical system deployed in the building;

[0019] Step 1.3: Identify and map the components of the digital twin model of the building electromechanical system with the components in the operating data of the building automation system to realize the correspondence between static topology data and dynamic operating data.

[0020] Furthermore, the automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios provided by the present invention includes the following steps in step 2: The method for constructing the topological operating data graph of the building electromechanical system includes:

[0021] Transform a heterogeneous graph based on the mapping relationship between the extracted static topology data and dynamic operational data. As a topology operation data diagram of a building's electromechanical system, the node set Represents all components, with each type of component assigned a unique type code, and an edge set. E It indicates the physical connection or control relationship between components.

[0022] Furthermore, the automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios provided by the present invention includes the following steps in step 2: processing nodes and edges.

[0023] Step 2.1, Initialize node feature vectors: for each node Constructing the initial feature vector The initial feature vector of a node includes information such as component type code, rated parameters, control mode, sensor identifier, system affiliation number, and node three-dimensional coordinates. All node feature vectors are collected into a node set.

[0024] Step 2.2, define the semantic type of the edge: define the physical connection or control relationship between components as the edge between components, and classify the edges into different types; the edge types include fluid connection edges, electrical signal edges and control command edges, assign corresponding initial weight values ​​to each type of edge, and gather all edges into an edge set.

[0025] Furthermore, the automatic modeling method for the operation mechanism of building electromechanical systems in small sample annotation scenarios provided by the present invention includes the following steps in step 3: extracting the node topological feature vectors in the topological operation data graph of the building electromechanical system by performing embedding learning on the nodes in the topological operation data graph of the building electromechanical system through the GraphSAGE algorithm in the graph neural network, aggregating neighbor information to generate low-dimensional feature vectors with context awareness, and obtaining the position, functional role and association strength of the nodes in the building electromechanical system.

[0026] Furthermore, in the automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios provided by the present invention, step 3 includes:

[0027] Step 3.1, Perform multi-level neighbor sampling and feature aggregation: Using the GraphSAGE algorithm, for each node, a fixed number of neighboring nodes are randomly sampled within its 1-hop and 2-hop neighborhoods. A mean aggregator is used to calculate the average of the neighboring features, which is then concatenated with the node's own features. This concatenation is then updated to the node using a linear transformation and a non-linear activation function for node embedding. The node embedding formula is as follows:

[0028] (1);

[0029] In equation (1), For nodes exist Layer embedding vectors, For activation function, The weight matrix is ​​a learnable matrix. For nodes In the Layer embedding vectors, For vector concatenation, It is the mean aggregation function. For nodes The set of embeddings of all neighboring nodes, Represents a node The set of neighboring nodes;

[0030] Step 3.2, Generate final node embeddings: After propagating through L layers using the GraphSAGE algorithm, the final low-dimensional feature vector of each node is obtained. ,in It is a d-dimensional real vector space, where the final low-dimensional feature vector integrates the node's position in the building electromechanical system, the functional contextual description information, and the association strength description information between nodes.

[0031] Furthermore, in the automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios provided by the present invention, step 5 includes:

[0032] Step 5.1, Construct the joint feature vector: For each node In time Observations The "topology-operation" joint feature vector is obtained by concatenating the low-dimensional feature vectors embedded in the topology operation data graph of the building electromechanical system;

[0033] Step 5.2: Based on the prototype network in few-shot learning, automatically classify and label the operation modes of the novel building electromechanical system digital twin model diagram using few-shot data: Building upon the N-way K-shot episode model in few-shot learning, typical modes of various operation modes are learned using sample data that supports centralized labeling. For the first The support set for class-based operation modes, where each sample data is a labeled pair. Encode the feature vectors of all sample data and average them to calculate the prototype vector of this type of operating mode:

[0034] (2);

[0035] In equation (2), C K For the prototype vector of the running mode category, For trainable feature encoding networks, For the first The class supports a certain number of sample data sets. Let i be the feature vector of the corresponding node i within a certain time period. The table shows the operating mode category to which the feature vector of the corresponding node i belongs;

[0036] For any unlabeled time period feature vector in the query set Calculate its relationship with various prototype vectors Euclidean distance It assigns the operating mode to the nearest one and outputs the classification probability of the operating mode through the softmax function, thereby completing the automatic classification and labeling of the operating modes of the digital twin model of the building electromechanical system with small sample data, and automatically constructing the operating mechanism model of the digital twin model of the building electromechanical system.

[0037] Furthermore, in the automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios provided by the present invention, step 6 includes:

[0038] Step 6.1: Perform correlation analysis on the automatic classification and labeling results of the topology operation data diagram of the building electromechanical system and its operation mode categories to determine the key variables affecting the behavior of the building electromechanical system and their action paths;

[0039] Step 6.2, Extraction and Parametric Modeling of Typical Operating Characteristic Curves: For each identified operating mode, extract the steady-state or dynamic response relationship between key variables from historical data, and construct a parametric curve model that reflects the operating characteristics of the building electromechanical system.

[0040] Step 6.3, Constructing an Explainable Operating Rule Extraction and Knowledge Base: Combining cluster analysis and threshold segmentation techniques, key variables under various operating modes are identified to determine the operating mode category, extract typical operating logic, and generate a set of structured rules expressed in IF-THEN form. The rule condition part consists of variable thresholds, trend changes, or state combinations, and the conclusion part describes the system behavior response or mode determination result. The causal relationship network, mathematical expressions, and operating rules are integrated to construct a unified operating mechanism knowledge base and map it onto the digital twin model diagram of the building electromechanical system to automatically construct the operating mechanism and form a digital twin operating mechanism model of the building electromechanical system.

[0041] Compared with the prior art, the beneficial effects of the present invention are as follows:

[0042] This invention provides an automatic modeling method for the operational mechanism of building electromechanical systems (MEMS) in scenarios with small sample annotation. The method involves: extracting static and dynamic topological data of the MEMS; constructing a topological operational data graph of the MEMS; extracting topological feature vectors from the nodes in the topological operational data graph; annotating the operational modes in the topological operational data graph with small samples and constructing a meta-learning model through small sample learning; automatically classifying unannotated operational modes using the meta-learning model; and automatically generating interpretable system operation rules, mathematical expressions, or causal relationship networks as the operational mechanism model of the digital twin of the MEMS based on the identified and annotated operational mode categories. Compared to traditional data-driven modeling methods, this method reduces the number of manually annotated samples, lowers the dependence on expert annotation, and reduces annotation costs. By constructing a meta-learning task through few-shot learning, the system automatically identifies and labels unlabeled operating modes from a small number of labeled samples. This is combined with graph neural networks to generate interpretable operating rules, numerical equations, or causal relationship networks. This enables efficient, automatic, and understandable modeling of the operating mechanisms of building electromechanical systems. It is suitable for intelligent operation and maintenance and digital twin applications in low-data environments, such as cold starts of newly deployed building electromechanical systems and renovation of old building electromechanical systems. Under the condition of scarce labeled samples, it integrates the topology of building information model with operating data to achieve automated modeling of the operating mechanisms of building electromechanical systems. Attached Figure Description

[0043] Figure 1This is a flowchart of the steps for an automatic modeling method of the operating mechanism of building electromechanical systems for small sample annotation scenarios.

[0044] Figure 2 This is a framework flowchart for an automatic modeling method of the operating mechanism of building electromechanical systems for small sample annotation scenarios. Detailed Implementation

[0045] The present invention will now be described in detail with reference to the accompanying drawings. The advantages and features of the present invention will become clearer from the following description. It should be noted that the drawings are all in a very simplified form and use non-precise proportions, and are only used to facilitate and clarify the illustration of the embodiments of the present invention.

[0046] Please refer to Figures 1 to 2 This invention provides an automatic modeling method for the operating mechanism of building electromechanical systems in scenarios with small sample annotation, including:

[0047] Step 1 involves extracting the static topology data and dynamic operational data of the building's electromechanical systems. This involves integrating the BIM model, sensor time-series data, and a small amount of manual annotation to build a foundation for multimodal data input, supporting subsequent structured modeling and semantic learning. Specifically, this includes:

[0048] Step 1.1: Extract the static topology data of the building's mechanical and electrical (MEM) system from the digital twin model diagram. This static topology data primarily includes information on the components of the MEM system, such as chillers, pumps, fans, valves, pipes, and sensors, as well as the connections between these components. It may also include component attribute information such as rated power, flow rate, control logic description, and system category. This results in static topology data with a component list and topology structure. The digital twin model diagram of the MEM system is a BIM diagram in IFC format. The topology structure here mainly refers to the connections between components and the control relationships that may exist in the BIM diagram.

[0049] Step 1.2 involves collecting dynamic operational data of the building's electromechanical system (EMS) from the building automation system corresponding to the digital twin model of the EMS and the sensors deployed at its corresponding nodes. This dynamic operational data includes operational parameters such as temperature, humidity, pressure, current, voltage, frequency, flow rate, and velocity, as well as operational status information such as equipment start / stop, alarm signals, and control modes; this dynamic operational data is also referred to as sensor time-series data. The building automation system refers to the EMS deployed within the building. The sampling granularity can range from 1 minute to 5 minutes, with a sampling period of at least one week, to accurately reflect the operational status of the EMS under different operating modes. To ensure the accuracy of the collected dynamic operational data, processes such as missing value completion, outlier removal, and time axis alignment can be performed to form a standardized dataset with a unified format.

[0050] Step 1.3: Identify and map the components of the digital twin model of the building electromechanical system with the components in the operating data of the building automation system to realize the correspondence between static topology data and dynamic operating data.

[0051] For example: collecting three types of data from building electromechanical systems:

[0052] (1) Export the BIM drawing to IFC format and extract the static topology data containing component type, connection relationship and spatial coordinates;

[0053] (2) Obtain dynamic operation data from the building automation system corresponding to the BIM diagram. Collect a total of 10 key measurement points over a period of more than 7 days, where "more than" includes the number itself.

[0054] (3) Operation and maintenance experts semantically labeled the dynamic operation data of four typical time periods into different categories of operation modes. Only one sample was labeled for each operation mode, as follows:

[0055] Sample S1 (02:00–02:30): labeled as "Energy Saving Operation Mode".

[0056] Sample S2 (08:15–08:45): labeled as “Transitional Adjustment Mode”, also known as “High Power Mode”.

[0057] Sample S3 (14:00–14:30): labeled as “steady-state high load mode”.

[0058] Sample S4 (17:30–18:00): labeled as “abnormal fluctuation pattern”.

[0059] The operating mode is also known as the working condition. Figure 2In the diagram, "Energy Saving" indicates "Energy Saving Operation Mode" corresponding to Condition 1, "High Power" indicates "Transitional Adjustment Mode" corresponding to Condition 2, "Steady State" indicates "Steady State High Load Mode" corresponding to Condition 3, and "Abnormal" indicates "Abnormal Fluctuation Mode" corresponding to Condition 4.

[0060] Step 2 involves constructing a topology operation data diagram of the building's electromechanical system. This involves analyzing the components and their connections in the BIM diagram to create a heterogeneous graph with components as nodes and physical or control paths as edges, thus representing the system's structural topology operation diagram. Physical paths are also called physical connections, and control paths are also called control relationships.

[0061] Transform a heterogeneous graph based on the mapping relationship between the extracted static topology data and dynamic operational data. As a topology operation data diagram of a building's electromechanical system, the node set Represents all components, with each type of component assigned a unique type code, and an edge set. E This represents the physical connection or control relationship between components. The steps for processing nodes and edges include:

[0062] Step 2.1: Initialize node feature vectors.

[0063] For each node Constructing the initial feature vector The initial feature vector of a node includes component type encoding. Rated parameters, control mode Sensor Identification System Attribution Number and node 3D coordinates Information such as rated parameters, including but not limited to rated power. The feature vectors of all nodes are aggregated into a node set. This information forms structured input data, which is used for training the graph neural network.

[0064] Step 2.2, define the semantic type of the edge.

[0065] The edges between components are classified as either physical connections or control relationships, and are further categorized into different types. These edge types include fluid connection edges, electrical signal edges, and control command edges. Each type of edge is assigned a corresponding initial weight value, and all edges are aggregated into an edge set for the message passing mechanism used in graph neural network training.

[0066] The processing steps from step 2.1 to step 2.2 correspond to... Figure 2 Graph neural network encoding in [the context of graph neural networks].

[0067] For example, by parsing IFC format BIM drawings, extracting 12 main components (such as cold source equipment, conveying equipment, and terminal equipment) from static topology data and dynamic operation data, identifying the connection properties of the components (such as physical connections for fluid paths and control connections for control links), and constructing a heterogeneous graph G=(V,E). For instance, there is a fluid connection between component A and component B, and a control signal link between component B and component C, forming a path structure of "A→B→C", thus realizing the construction of the topology operation data diagram of the building's electromechanical system.

[0068] Step 3: Extract the node topology feature vectors from the topology operation data graph of the building electromechanical system. That is, use the GraphSAGE algorithm to embed the topology graph to generate equipment feature vectors that integrate structural information, which serve as prior knowledge input.

[0069] The GraphSAGE algorithm in graph neural networks is used to embed nodes in the topological operation data graph of a building MEP system. Neighbor information is aggregated to generate low-dimensional feature vectors with context-aware capabilities, obtaining the node's position, functional role, and association strength within the building MEP system. In other words, the graph neural network is trained using the GraphSAGE algorithm. Specifically, this includes:

[0070] Step 3.1: Perform multi-level neighbor sampling and feature aggregation.

[0071] The GraphSAGE algorithm is used to randomly sample a fixed number of neighboring nodes within each node's 1-hop and 2-hop neighborhoods. A mean aggregator is used to calculate the average of the neighboring features, which is then concatenated with the node's own features. This concatenation is followed by a linear transformation and a non-linear activation function to update the node for embedding. The node embedding formula is as follows:

[0072] (1);

[0073] In equation (1), For nodes exist Layer embedding vectors, For activation function, The weight matrix is ​​a learnable matrix. For nodes In the Layer embedding vectors, For vector concatenation, It is the mean aggregation function. For nodes The set of embeddings of all neighboring nodes, Represents a node The set of neighboring nodes.

[0074] Step 3.2: Generate the final node embedding.

[0075] After propagating through L layers using the GraphSAGE algorithm, the final low-dimensional feature vector of each node is obtained. .in Let be a d-dimensional real vector space, where the final low-dimensional feature vector integrates the node's position in the building's electromechanical system, its functional contextual description, and the strength of the association between nodes. This final low-dimensional feature vector can serve as prior knowledge for subsequent automatic modeling of the operational mechanism. That is, the weight matrix is ​​trained using the node embedding formula to obtain the trained graph neural network.

[0076] For example, using the GraphSAGE algorithm, with an embedding dimension d=64 and an aggregation layer number L=2, the topology operation data graph of the building MEP system in step 2 is encoded. For instance, for component A, its one-hop neighbors components B and C are sampled, their neighbor feature mean is calculated and concatenated with its own feature, and after two layers of propagation, the topology embedding vector of component A is output. ∈ .in Let A be the topological embedding vector of component A. This represents a 64-dimensional real vector space.

[0077] Step 4: Label the operating modes in the topology operation data diagram of the building electromechanical system with small samples and construct a meta-learning task through small sample learning. That is, construct an N-way K-shot episode based on the labeled samples, and fuse sensor time series data and topology vector features to achieve rapid identification of operating modes under few sample conditions.

[0078] Step 4.1: Establish a labeling system for the dynamic operation data of building electromechanical systems.

[0079] The operating modes of building electromechanical systems are divided into several categories, forming an operating mode classification system. .in For the operating modes categorized from 1 to n, the operating modes labeled with the category are used as samples. The categories of operating modes include, but are not limited to, "cooling mode", "dehumidification mode", "nighttime energy saving mode", and "cooling unit high-pressure protection mode".

[0080] Step 4.2: Organize the episode training structure.

[0081] The training is performed using the episode training structure in few-shot learning from machine learning. During the training process, samples are randomly selected each time. The operating modes for each category are selected. A set of labeled category samples is used as the support set for a certain time period, and the remaining labeled category samples are used as the query set. This constitutes a meta-learning task. The meta-learning outputs the categories of the operating modes in the unlabeled time periods of the query set and labels them to form a meta-learning model, enabling small-sample learning to quickly adapt to the labeling of operating mode categories.

[0082] Step 5: Automatically classify the operation modes of the new digital twin model diagram of the building electromechanical system and construct the digital twin operation mechanism model of the building electromechanical system. That is, extract the response relationship of key variables under various working conditions, construct standardized operation characteristic curves and parameterized models, and characterize the dynamic behavior law of the building electromechanical system.

[0083] The extracted node topology feature vectors are combined with the extracted dynamic operation data to construct a "topology-operation" joint feature vector. This vector is then input into the meta-learning model to automatically classify and label the operation modes of novel building electromechanical system digital twin model diagrams under small sample conditions. Specifically, this includes:

[0084] Step 5.1: Construct the joint feature vector.

[0085] For each node In time Observations The "topology-operation" joint feature vector is obtained by concatenating the low-dimensional feature vectors embedded in the topology operation data graph of the building electromechanical system. .in The observation value at time t corresponds to the sensor time series data, which is simplified to time series data.

[0086] Step 5.2: Based on the prototype network in few-shot learning, the operation mode of the new digital twin model of the building electromechanical system is automatically classified and labeled with a few samples.

[0087] Building upon the construction of N-way K-shot episodes in few-shot learning, typical patterns of various operating modes are learned using sample data that supports centralized annotation. Let... For the first The support set for class-based operation modes, where each sample data is a labeled pair. Encode the feature vectors of all sample data and average them to calculate the prototype vector of this type of operating mode:

[0088] (2);

[0089] In equation (2), C K For the prototype vector of the running mode category, For trainable feature encoding networks, For the first The class supports a certain number of sample data sets. Let i be the feature vector of the corresponding node i within a certain time period. The table shows the operating mode category to which the feature vector of the corresponding node i belongs;

[0090] For any unlabeled time period feature vector in the query set Calculate its relationship with various prototype vectors Euclidean distance It assigns the operating mode to the nearest one and outputs the classification probability of the operating mode through the softmax function, thereby completing the automatic classification and labeling of the operating modes of the digital twin model of the building electromechanical system with small sample data, and realizing the automated construction of the operating mechanism model of the digital twin of the building electromechanical system.

[0091] For example, constructing a 4-way 1-shot episode: the support set contains the four labeled samples (S1-S4) mentioned above, and the query set selects the unlabeled time period from 20:00 to 20:30. For each sample, its joint feature sequence is extracted and encoded into a fixed-length vector using LSTM. Calculate the prototype vector for each class. = (), for the query sample Calculate its Euclidean distance to each prototype vector, identify the one closest to the "energy-saving operation mode", and complete the automated classification and labeling of the operation modes for unlabeled time periods in the query set.

[0092] For the "energy-saving operation mode" category, the "load rate - unit energy consumption" relationship is extracted from all time periods identified as belonging to this category. For example, in the load rate range of 20%-40%, the unit energy consumption remains at 0.8-1.0 kW / ton, forming the left branch of the U-shaped curve; when the load rate is <20%, the unit energy consumption rises sharply, identifying it as an "inefficient zone". An inflection point threshold (e.g., load rate = 20%) is extracted, and a parameterized model is constructed: when the load rate is >20%, energy efficiency is optimal.

[0093] Step 6: Based on the automatic classification and annotation results from Step 5, automatically generate interpretable system operation rules, mathematical expressions, or causal relationship networks on the digital twin model diagram of the building electromechanical system as the digital twin operation mechanism model of the building electromechanical system. This involves combining the action path and characteristic model to generate operation rules in IF-THEN form, constructing a readable, verifiable, and callable mechanism knowledge base. The operation rules, mathematical expressions, and causal relationship networks are three ways to express the operation mechanism of the building electromechanical system. This automatic construction of the digital twin operation mechanism model of the building electromechanical system corresponds to... Figure 2 The construction of the building's operational mechanism. Specifically, this includes:

[0094] Step 6.1 involves performing a correlation analysis on the automatic classification and labeling results of the building's electromechanical system topology operation data diagram and its operation mode categories to determine the key variables affecting the behavior of the building's electromechanical system and their impact paths. Specifically:

[0095] Using the component connection relationships provided by BIM drawings as analysis constraints, correlation and response relationship tests are only conducted between variables that have physical connection relationships or control links to eliminate spurious associations without connection basis.

[0096] By calculating the temporal correlation, mutual information, and dynamic time warping distance between variables, we can screen out variable pairs that have a lead-lag relationship in time.

[0097] Using sliding window regression and residual analysis, we identified input variables that have a significant impact on the output of building electromechanical systems under specific operating modes, and analyzed their response intensity and delay characteristics.

[0098] By combining the sequence of variable changes with the topological direction of the building's electromechanical system, an action network reflecting the transmission paths of energy, signals, or media is constructed to describe the functional dependencies and dominant action mechanisms of each component during operation.

[0099] Step 6.2, Extraction and Parametric Modeling of Typical Operating Characteristic Curves: For each identified operating mode, extract the steady-state or dynamic response relationship between key variables from historical data, and construct a parametric curve model that reflects the operating characteristics of the building electromechanical system.

[0100] By clustering alignment and time normalization, multiple operating trajectories under the same operating mode are aligned and averaged to generate standardized operating characteristic curves, including input-output response curves, load-energy consumption relationship curves, and transient process dynamic curves.

[0101] For each curve, perform piecewise linearization or basis function expansion to extract key characteristic parameters, such as response delay, rise time, steady-state gain, slope inflection point, and energy efficiency inflection point.

[0102] Establish a correlation model between these characteristic parameters and system boundary conditions (such as environmental parameters and setpoints) to form an adaptive operating characteristic description that can be adjusted according to changes in operating mode.

[0103] The generated characteristic curves and their parameter sets together constitute a typical behavior template of the building electromechanical system under this operating mode, which is used for subsequent energy efficiency assessment, anomaly detection and control strategy comparison.

[0104] Step 6.3: Constructing an interpretable operating rule extraction and knowledge base: Combining cluster analysis and threshold segmentation techniques, key variables under various operating modes are categorized to identify operating mode types, extract typical operating logic, and generate a structured rule set expressed in IF-THEN form. The rule condition part consists of variable thresholds, trend changes, or state combinations, while the conclusion part describes the system's behavioral response or mode determination result. Causal relationship networks, mathematical expressions, and operating rules are integrated to construct a unified operating mechanism knowledge base and map it onto the digital twin model diagram of the building electromechanical system. This automatically constructs the operating mechanism, forming a digital twin operating mechanism model of the building electromechanical system.

[0105] The operating mechanism knowledge base is stored in a readable format and supports visualization and external system calls, serving as an interpretable decision-making basis for fault diagnosis, energy efficiency assessment and operation optimization of building electromechanical systems.

[0106] For example, based on the curve in step 5 and the action path in step 6, IF-THEN rules are automatically generated.

[0107] If the system load rate is <20% and the unit energy consumption is >1.2 kW / ton, then it is judged as "inefficient operation, and it is recommended to increase the load or optimize start-stop".

[0108] If the rate of change of key parameters is <0.1% / min for 5 consecutive sampling points, then the system is considered to be in steady state and requires no adjustment. All operating rules are categorized and stored according to operating modes, along with data sources and confidence scores.

[0109] By using a digital twin operation mechanism model of a building's electromechanical system, fault analysis can be performed on the operation and maintenance of the building's electromechanical system, and corresponding maintenance strategies can be output.

[0110] Step 7: Validation and iterative optimization of the meta-learning model.

[0111] Through expert review, simulation comparison, and online feedback mechanisms, the accuracy and reliability of the meta-learning model's category identification of unlabeled operating modes are evaluated, and the meta-learning model is validated and iteratively updated. It supports manual correction and incremental learning to achieve continuous system evolution, and supports closed-loop updates and long-term operational adaptation. Specifically, it includes:

[0112] Step 7.1: Perform machine learning rationality verification.

[0113] The automatically generated operation mode category labels are compared with the operation mode categories annotated by experts to evaluate the accuracy of machine learning in judging and recognizing operation mode categories; the digital twin operation mechanism model of the building electromechanical system is cross-validated with the operation modes in historical maintenance records to ensure the effectiveness of machine learning output.

[0114] Step 7.2 supports expert feedback and model updates.

[0115] It allows operations and maintenance personnel to correct erroneous labels or rules and re-incorporate the corrected small sample data into the training set, driving machine learning fine-tuning of meta-learning tasks or retraining of graph neural networks, thereby achieving continuous evolution and adaptive enhancement of machine learning.

[0116] Comparing the generated operating rules with historical maintenance records revealed that the "inefficient operation" rule matched three real work orders, achieving an accuracy rate of 92%. Experts suggested a correction to one rule: "Inefficient alarms are only triggered when the load rate is <15%." The system added the corrected sample to the training set and fine-tuned the meta-learning model. After the update, the meta-learning model's accuracy on the test set improved to 95%, completing the closed-loop optimization.

[0117] The automatic modeling method for the operation mechanism of building electromechanical systems (EMS) provided in this invention, targeting scenarios with small sample annotations, integrates the topological information of the digital twin model of the EMS with a small amount of manually annotated category data of the operation modes. This achieves efficient, automatic, and interpretable modeling of the EMS operation mechanism on the digital twin model, significantly reducing the reliance on large-scale annotated operation mode data. It can accurately identify the operation modes of the EMS and automatically classify unannotated data with only 3-5 annotated samples per operation mode. Furthermore, it extracts components using a graph neural network based on the GraphSAGE algorithm. By combining the structural correlation features between the elements with the meta-learning framework to construct an episode training mechanism, the generalization ability and operation mode recognition accuracy of the meta-learning model in cold start scenarios are improved. Furthermore, based on the action path analysis of topological constraints and the extraction of typical operation characteristic curves, a parameterized model and readable rules reflecting the dynamic response law of the system are generated, which enhances the physical rationality and operational understandability of the modeling results. The constructed operation mechanism knowledge base can be directly used for fault diagnosis, energy efficiency assessment and control optimization. It is suitable for actual construction engineering scenarios such as the installation and commissioning of building electromechanical systems and the renovation of electromechanical systems in old buildings. It has the technical advantages of short modeling cycle, less expert participation and flexible deployment.

[0118] The automatic modeling method for the operation mechanism of building electromechanical systems in small-sample labeled scenarios provided in this invention has the following advantages:

[0119] Low data dependency: Only 3 to 5 labeled samples are needed for each type of working condition to build an effective operating mechanism model, solving the cold start problem.

[0120] Advantages of knowledge integration: It makes full use of the existing static topology data in the BIM drawings, reducing the dependence on dynamic running data.

[0121] Strong interpretability: The generated operating rules, numerical expression equations, and causal relationship networks are easy to understand and verify.

[0122] High generalization capability: knowledge can be transferred between tasks in different operating modes through a meta-learning framework.

[0123] Engineering practicality: It is particularly suitable for the initial deployment of building electromechanical systems in new buildings and the renovation of building electromechanical systems in old buildings, accelerating the implementation of intelligent operation and maintenance platforms for building electromechanical systems.

[0124] This invention is not limited to the specific embodiments described above. Obviously, the embodiments described above are only a part of the embodiments of this invention, not all of them. All other embodiments obtained by those skilled in the art based on the described embodiments of this invention are within the scope of protection of this invention. Those skilled in the art can make other modifications and variations to this invention. Therefore, if these modifications and variations of this invention fall within the scope of the claims of this invention, then this invention also intends to include these modifications and variations.

Claims

1. An automatic modeling method for the operating mechanism of building electromechanical systems in scenarios with small sample annotation, characterized in that, include: Step 1: Extract the static topology data and dynamic operation data of the building's electromechanical system; Step 2: Construct the topology operation data diagram of the building's electromechanical system; Step 3: Extract the node topology feature vectors from the topology operation data graph of the building electromechanical system; Step 4 involves labeling the operating modes in the topology operation data diagram of the building electromechanical system with small samples and constructing a meta-learning task through small sample learning, including: Step 4.1: Establish an operational mode labeling system for the dynamic operation data of building electromechanical systems; divide the operational modes of building electromechanical systems into several categories to form an operational mode classification system. ,in For the operating modes of categories 1 to n, the operating modes labeled with categories are used as samples; Step 4.2: Organize the episode training structure. Train the samples using the episode training structure from few-shot learning in machine learning. During the training process, randomly sample the data each time. The operating modes for each category are selected. A set of labeled category samples is used as the support set for a certain time period, and the remaining labeled category samples are used as the query set. This constitutes a meta-learning task. The meta-learning outputs the category of the operation mode in the unlabeled time period of the query set and labels it to form a meta-learning model, enabling small sample learning to quickly adapt to the labeling of operation mode categories. Step 5: Automatically classify and label the operating modes of the new building electromechanical system digital twin model diagram; The extracted node topology feature vectors are combined with the extracted dynamic operation data to construct a "topology-operation" joint feature vector, which is then input into the meta-learning model to automatically classify and label the operation modes of the new building electromechanical system digital twin model under small sample conditions. Step 6: Based on the automatic classification and labeling results of Step 5, automatically generate interpretable system operation rules, mathematical expressions, or causal relationship networks on the digital twin model diagram of the building electromechanical system as the operating mechanism model of the digital twin of the building electromechanical system.

2. The automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios according to claim 1, characterized in that, Also includes: Step 7, Validation and Iterative Optimization of the Meta-Learning Model: Through expert review, simulation comparison and online feedback mechanisms, evaluate the accuracy and reliability of the meta-learning model in class identification of unlabeled operating modes, and validate and iteratively update the meta-learning model.

3. The automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios according to claim 1, characterized in that, In step 1, the method for extracting static topology data and dynamic operation data of the building's electromechanical system includes: Step 1.1: Extract the static topology data of the building electromechanical system from the digital twin model diagram of the building electromechanical system; the static topology data mainly includes the components of the building electromechanical system and the connection relationship information between the components, and also includes the component attribute information; Step 1.2: Collect dynamic operation data of the building electromechanical system from the building automation system corresponding to the digital twin model diagram of the building electromechanical system and the sensors deployed on its corresponding nodes; wherein the dynamic operation data includes operation parameter information and operation status information; wherein the building automation system is the building electromechanical system deployed in the building; Step 1.3: Identify and map the components of the digital twin model of the building electromechanical system with the components in the operating data of the building automation system to realize the correspondence between static topology data and dynamic operating data.

4. The automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios according to claim 1, characterized in that, In step 2, the method for constructing the topology operation data diagram of the building's electromechanical system includes: Transform a heterogeneous graph based on the mapping relationship between the extracted static topology data and dynamic operational data. As a topology operation data diagram of a building's electromechanical system, the node set Represents all components, with each type of component assigned a unique type code, and an edge set. E It indicates the physical connection or control relationship between components.

5. The automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios according to claim 4, characterized in that, In step 2, the processing steps for nodes and edges include: Step 2.1, Initialize node feature vectors: for each node Constructing the initial feature vector The initial feature vector of a node includes component type code, rated parameters, control mode, sensor identifier, system affiliation number, and node three-dimensional coordinate information. All node feature vectors are collected into a node set. Step 2.2, define the semantic type of the edge: define the physical connection or control relationship between components as the edge between components, and classify the edges into different types; the edge types include fluid connection edges, electrical signal edges and control command edges, assign corresponding initial weight values ​​to each type of edge, and gather all edges into an edge set.

6. The automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios according to claim 1, characterized in that, In step 3, the method for extracting the node topology feature vectors in the topology operation data graph of the building electromechanical system includes: using the GraphSAGE algorithm in the graph neural network to perform embedding learning on the nodes in the topology operation data graph of the building electromechanical system, aggregating neighbor information to generate low-dimensional feature vectors with context awareness, and obtaining the position, functional role and association strength of the nodes in the building electromechanical system.

7. The automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios according to claim 6, characterized in that, Step 3 includes: Step 3.1, Perform multi-level neighbor sampling and feature aggregation: Using the GraphSAGE algorithm, for each node, a fixed number of neighboring nodes are randomly sampled within its 1-hop and 2-hop neighborhoods. A mean aggregator is used to calculate the average of the neighboring features, which is then concatenated with the node's own features. This concatenation is then updated to the node using a linear transformation and a non-linear activation function for node embedding. The node embedding formula is as follows: (1); In equation (1), For nodes exist Layer embedding vectors, For activation function, The weight matrix is ​​a learnable matrix. For nodes In the Layer embedding vectors, For vector concatenation, It is the mean aggregation function. For nodes The set of embeddings of all neighboring nodes, Represents a node The set of neighboring nodes; Step 3.2, Generate final node embeddings: After propagating through L layers using the GraphSAGE algorithm, the final low-dimensional feature vector of each node is obtained. ,in It is a d-dimensional real vector space, where the final low-dimensional feature vector integrates the node's position in the building electromechanical system, the functional contextual description information, and the association strength description information between nodes.

8. The automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios according to claim 1, characterized in that, Step 5 includes: Step 5.1, Construct the joint feature vector: For each node In time Observations The "topology-operation" joint feature vector is obtained by concatenating the low-dimensional feature vectors embedded in the topology operation data graph of the building electromechanical system; Step 5.2: Based on the prototype network in few-shot learning, automatically classify and label the operation modes of the novel building electromechanical system digital twin model diagram using few-shot data: Building upon the N-way K-shot episode model in few-shot learning, typical modes of various operation modes are learned using sample data that supports centralized labeling. For the first The support set for class-based operation modes, where each sample data is a labeled pair. Encode the feature vectors of all sample data and average them to calculate the prototype vector of this type of operating mode: (2); In equation (2), C K For the prototype vector of the running mode category, For trainable feature encoding networks, For the first The class supports a certain number of sample data sets. Let i be the feature vector of the corresponding node i within a certain time period. The table shows the operating mode category to which the feature vector of the corresponding node i belongs; For any unlabeled time period feature vector in the query set Calculate its relationship with various prototype vectors Euclidean distance It assigns the operating mode to the nearest one and outputs the classification probability of the operating mode through the softmax function, thereby completing the automatic classification and labeling of the operating modes of the digital twin model of the building electromechanical system with small sample data, and realizing the automated construction of the operating mechanism model of the digital twin of the building electromechanical system.

9. The automatic modeling method for the operating mechanism of building electromechanical systems in small-sample labeled scenarios according to claim 1, characterized in that, Step 6 includes: Step 6.1: Perform correlation analysis on the automatic classification and labeling results of the topology operation data diagram of the building electromechanical system and its operation mode categories to determine the key variables affecting the behavior of the building electromechanical system and their action paths; Step 6.2, Extraction and Parametric Modeling of Typical Operating Characteristic Curves: For each identified operating mode, extract the steady-state or dynamic response relationship between key variables from historical data, and construct a parametric curve model that reflects the operating characteristics of the building electromechanical system. Step 6.3, Constructing an Explainable Operating Rule Extraction and Knowledge Base: Combining cluster analysis and threshold segmentation techniques, key variables under various operating modes are identified to determine the operating mode category, extract typical operating logic, and generate a set of structured rules expressed in IF-THEN form. The rule condition part consists of variable thresholds, trend changes, or state combinations, and the conclusion part describes the system behavior response or mode determination result. The causal relationship network, mathematical expressions, and operating rules are integrated to construct a unified operating mechanism knowledge base and map it onto the digital twin model diagram of the building electromechanical system to automatically construct the operating mechanism and form a digital twin operating mechanism model of the building electromechanical system.