BIM model data query method and system, product and medium
By generating and coexisting structured search paths and generalized queries in the BIM model, the problem of data omissions caused by fuzzy queries is solved, and logical integrity and self-evolving data query accuracy are achieved.
Patent Information
- Application Number
- CN202510881828.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-27
- Publication Date
- 2025-11-11
AI Technical Summary
In existing technologies for Building Information Modeling (BIM), fuzzy natural language queries can cause large language models to choose a single path, ignoring other reasonable dimensions, resulting in inaccurate and incomplete data queries.
By using a pre-defined structured semantic dictionary, all coexisting and valid structured search paths are generated for each target component and constraint condition. Logical operators are used to combine them into comprehensive database query instructions. When a query fails, semantic priority and relaxed priority are used to perform generalized queries. User-alternative keywords are recorded for self-evolution.
It improves the accuracy and completeness of data queries, avoids data omissions caused by single semantic guesses, realizes a logically complete query process, and enhances the intelligence of the query system by self-evolving and correcting user input.
Smart Images

Figure CN120929484A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of electronic digital data processing, and in particular to a BIM model data query method, system, product, and medium. Background Technology
[0002] Currently, Building Information Modeling (BIM) technology plays a crucial role in the architecture, engineering, and construction industries. With the deepening of digital transformation in these industries, BIM models integrate massive amounts of multi-dimensional building data. Therefore, efficiently and conveniently extracting the necessary data from complex BIM models is of great significance for project management, design collaboration, and subsequent operation and maintenance.
[0003] In related technologies, upon receiving a natural language query, structural information, i.e., a data pattern, is first retrieved from the target database. Subsequently, this data pattern is combined with the user's natural language question to construct a context-rich prompt. This prompt is then input into a large language model to generate a corresponding structured query statement, which is executed to retrieve the query results from the database.
[0004] When the input natural language is ambiguous, in BIM data relationships, a vague natural language concept may correspond to multiple coexisting and valid structured search paths. However, the large language model, based on the nature of probabilistic inference, will select the most probable query path from these reasonable interpretations to generate the query statement, which may ignore query statements under other reasonable dimensions, resulting in errors or omissions in the query statement and inaccurate data retrieval. Summary of the Invention
[0005] This application provides a BIM model data query method to improve the accuracy of data querying of building BIM models.
[0006] The first aspect of this application provides a method for querying BIM model data, the method comprising: Upon receiving a natural language statement, lexical analysis is performed on the statement based on a pre-defined structured semantic dictionary to obtain one or more target components and one or more limiting conditions. Based on the predefined BIM inherent relationship types in the structured semantic dictionary, a set of corresponding candidate query paths is generated for each target component and each limiting condition. Each candidate query path in the candidate query path set is combined using logical operators to form a conditional query block. All conditional query blocks are connected using the logical operator "AND" to obtain a database query instruction. The database query instruction is executed to retrieve the target component from the BIM model database. The target components are merged and deduplicated, and each target component is labeled with a corresponding candidate query path as the result source basis. The target components are classified according to the result source basis to obtain the data query results.
[0007] In the above embodiments, based on a predefined structured semantic dictionary, a fully coexisting and valid structured search path is generated for any concept in natural language within the BIM model. These paths are then combined into a comprehensive database query command, allowing for the simultaneous retrieval of all logically plausible possibilities during the query execution phase. This mechanism avoids the drawback of large language models in related technologies, which, due to their probabilistic inference nature, tend to select the most probable single path while ignoring other reasonable interpretations when faced with fuzzy concepts. By ensuring that all potential dimensions conforming to the BIM structural logic are included in the retrieval scope, a query process that might be missed due to semantic bias is transformed into a logically complete process, avoiding data omissions caused by a single query path and improving the accuracy of data query results.
[0008] In conjunction with some embodiments of the first aspect, in some embodiments, after executing the database query instruction and retrieving the target component from the BIM model database, the method further includes: When the number of target components returned by the database query command is zero, predefined relaxation priority scores are assigned to multiple constraints based on the corresponding semantic categories in the structured semantic dictionary; the constraint with the highest relaxation priority score is used as the key constraint and removed; the query is re-executed using the remaining constraints to obtain a set of generalized result sets; attribute values of the same type as the key constraints are extracted from the generalized result sets as alternative keywords; query optimization suggestions containing alternative keywords are output while returning zero results.
[0009] In the above embodiments, when the initial query fails, the system identifies and removes the most likely erroneous or overly specific key constraints using preset semantic priorities. A generalized query is then performed based on the remaining, more reliable query conditions. This extracts correct attribute values, similar to those removed conditions and actually existing in the BIM model, as replacement keywords within a broader, validated data range. This transforms an inaccurate user input that led to query failure into an interactive suggestion containing a series of validated correct options, guiding the user to make corrections. Through context-sensitive and valid alternatives derived from real data, the system proactively helps the user construct a more accurate query, thereby improving the accuracy of data queries on building BIM models.
[0010] In conjunction with some embodiments of the first aspect, in some embodiments, after returning zero results and outputting query optimization suggestions containing alternative keywords, the method further includes: Record key limiting conditions and alternative keywords to form a query failure suggestion record; count the query failure suggestion records, and when the number of occurrences of a fixed combination of fixed key limiting conditions and fixed alternative keywords exceeds the threshold for the number of erroneous queries, mark the fixed key limiting conditions and fixed alternative keywords as potential synonym pairs; add the potential synonym pairs to the structured semantic dictionary.
[0011] In the above embodiments, by recording the alternative keywords used by users after failed queries and conducting long-term statistical analysis on these records, high-frequency erroneous input-replacement combinations are identified. These high-frequency replacement combinations are then added to the structured semantic dictionary, transforming the originally isolated, one-off, passive error correction behavior into proactive knowledge accumulation. By internalizing this synonym relationship into the knowledge base, when a non-standard term is received in the future, it can be directly corrected to a standard term during the lexical analysis stage, thereby directly executing the correct query. This achieves the self-evolution and improvement of system knowledge, enhancing the accuracy of data queries on building BIM models.
[0012] In conjunction with some embodiments of the first aspect, in some embodiments, after merging and deduplicating the query target components and labeling each query target component with a corresponding candidate query path as the basis for the result source, the method further includes: Based on a pre-defined logical rule base, when there is a semantic conflict among multiple candidate query paths corresponding to a query target component, the query target component judged to have a semantic conflict is marked as a conflicting component, and the candidate query paths that generate semantic conflicts are marked as conflicting paths. Based on pre-defined conflict arbitration rules, multiple conflicting paths are prioritized to determine the highest priority conflicting path. The connected components and associated components within a pre-defined association range of the conflicting component in the BIM model are obtained, and it is determined whether the connected components or associated components meet the highest priority conflicting path. If so, the conflicting component is classified into the query result category determined by the highest priority conflicting path; if not, the conflicting component is classified into an independent conflict category to be reviewed.
[0013] In the above embodiments, when the same component is repeatedly detected due to multiple semantically conflicting query paths, components with data contradictions are classified. When the attributes of a component are ambiguous or conflicting, the conflicting path with the highest priority is taken as a hypothesis to be verified, and the attributes of physically connected or logically related components of the conflicting component are further retrieved in the BIM model as corroborating evidence. If the corroborating evidence generally supports the hypothesis, the component is automatically classified; otherwise, it is proven that the component has data or logical inconsistencies and is classified into an independent category to be verified. By utilizing the inherent topological relationships of the BIM model to resolve semantic ambiguity at the data level, automatic classification errors caused by incomplete rules or data errors are reduced, and the accuracy of data querying of building BIM models is improved.
[0014] In conjunction with some embodiments of the first aspect, in some embodiments, after classifying the conflicting components into a separate category of conflicts to be reviewed, the method further includes: The system matches conflicting components and paths with a pre-defined conflict pattern knowledge base to identify specific error patterns. For each specific error pattern, it extracts one or more candidate correction operations from a pre-defined correction strategy library. For each candidate correction operation, it iterates through the data relationships of the BIM model to deduce the components that will be directly or indirectly affected after the corresponding operation is executed, thus obtaining the corresponding influence domain. A correction suggestion containing an operation description and influence domain is generated for each candidate correction operation. One or more correction suggestions are associated with conflicting components, and the correction suggestion information is output.
[0015] In the above embodiments, by matching the identified data conflicts with a preset conflict pattern knowledge base, errors are qualitatively diagnosed, and validated, targeted candidate correction operations are proposed from the correction strategy library. This provides users with a complete correction suggestion that includes an operation description and an impact domain. Before proposing any correction suggestion, the data relationships in the BIM model are traversed in advance to deduce all components (i.e., impact domains) that will be directly or indirectly affected after the operation is performed. This transforms a previously opaque and high-risk manual data modification process into a completely transparent and predictable decision-making process. By guiding users in model maintenance, the accuracy of data queries on the building BIM model is improved.
[0016] In conjunction with some embodiments of the first aspect, in some embodiments, before obtaining the database query instruction by querying the block with logical operators and join conditions, the method further includes: If there are path pairs corresponding to instance attribute paths and inherited attribute paths respectively in a set of candidate query paths generated under the same constraint, the system determines whether the instance attribute path covers the inherited attribute path according to the preset attribute coverage rule. The instance attribute path is the query path of the attribute of the component that is independently assigned a value. The inherited attribute path is the query path of the shared or inherited attribute obtained by the component in the system or region. The attribute coverage rule defines that the instance attribute of the component takes precedence over the inherited attribute. If so, the covered inherited attribute path is deleted from the candidate query paths.
[0017] In the above embodiments, by actively identifying and applying the core BIM data rule of prioritizing instance attributes during the preprocessing stage of query construction, when a component has both inherited values from its system or type and its own independently assigned instance values, it is determined that the instance assignment logically covers the inherited values, and the covered inheritance paths are removed from the candidate query paths. This ensures that the final generated database query instructions are logically consistent, avoids potential data conflicts introduced by data inheritance, and improves the accuracy of data querying of building BIM models.
[0018] In conjunction with some embodiments of the first aspect, in some embodiments, after classifying the target components of the query according to the result source and obtaining the data query results, the method further includes: Integrate the query target components and limiting conditions to generate a query context; upon receiving a new natural language statement, if the new natural language statement contains an incomplete query with a pronoun or an omitted subject, parse the new target components or limiting conditions from the new natural language statement; use the new target components or limiting conditions to cover the query target components or limiting conditions to correct the query context.
[0019] In the above embodiments, the ability to understand continuous dialogue is achieved by generating and dynamically maintaining a structured query context after each query. When a follow-up question containing referential or omitted elements is received, the existing context is used to parse it into the result set of the previous query. By intelligently fusing the newly parsed constraints with the historical context, a new, logically rigorous query instruction that inherits the user's complete intent is automatically constructed. This transforms a follow-up question, which is prone to errors due to ambiguity, into a filtering of the correct target range, avoiding semantic drift in the dialogue and improving the accuracy of data querying of building BIM models.
[0020] Secondly, embodiments of this application provide a BIM model data query system, which includes: one or more processors and a memory; the memory is coupled to the one or more processors, and the memory is used to store computer program code, which includes computer instructions, and the one or more processors call the computer instructions to cause the BIM model data query system to perform the method described in the first aspect and any possible implementation thereof.
[0021] Thirdly, embodiments of this application provide a computer program product containing instructions that, when the computer program product is run on a BIM model data query system, cause the BIM model data query system to execute the method described in the first aspect and any possible implementation thereof.
[0022] Fourthly, embodiments of this application provide a computer-readable storage medium including instructions that, when executed on a BIM model data query system, cause the BIM model data query system to perform the method described in the first aspect and any possible implementation thereof.
[0023] Understandably, the BIM model data query system provided in the second aspect, the computer program product provided in the third aspect, and the computer storage medium provided in the fourth aspect are all used to execute the BIM model data query method provided in the embodiments of this application. Therefore, the beneficial effects they can achieve can be referred to the beneficial effects in the corresponding methods, and will not be repeated here.
[0024] One or more technical solutions provided in the embodiments of this application have at least the following technical effects or advantages: 1. This application generates all coexisting and valid structured search paths within the BIM model for any concept in natural language based on a predefined structured semantic dictionary. These paths are then combined into a comprehensive database query command, allowing for the simultaneous retrieval of all logically plausible possibilities during the query execution phase. This mechanism avoids the drawback of large language models in related technologies, which, due to their probabilistic inference nature, tend to select the most probable single path while ignoring other reasonable interpretations when faced with fuzzy concepts. By ensuring that all potential dimensions conforming to the BIM structural logic are included in the search scope, a query process that might be missed due to semantic bias is transformed into a logically complete process, avoiding data omissions caused by a single query path and improving the accuracy of data query results.
[0025] 2. This application improves the accuracy of data retrieval from building BIM models by identifying and removing the most likely erroneous or overly specific key constraints when the initial query fails, using preset semantic priorities. Based on the remaining, more reliable query conditions, a generalized query is executed. This extracts correct attribute values, similar to the removed conditions and actually existing in the BIM model, as replacement keywords within a broader, validated data range. This transforms an inaccurate user input that led to query failure into an interactive suggestion containing a series of validated correct options, guiding the user to make corrections. Through context-sensitive, valid alternatives derived from real data, it proactively helps users construct more accurate queries, thereby improving the accuracy of data retrieval from building BIM models.
[0026] 3. This application records the alternative keywords used by users after failed queries and conducts long-term statistical analysis on these records to identify frequently occurring erroneous input-replacement combinations. These frequently occurring replacement combinations are then added to a structured semantic dictionary, transforming what was originally an isolated, one-off, passive error correction behavior into proactive knowledge accumulation. By internalizing this synonym relationship into the knowledge base, when a non-standard term is received in the future, it can be directly corrected to a standard term during the lexical analysis stage, thereby directly executing the correct query. This achieves the self-evolution and improvement of system knowledge, enhancing the accuracy of data queries for building BIM models. Attached Figure Description
[0027] Figure 1 This is a flowchart illustrating a BIM model data query method in an embodiment of this application; Figure 2 This is another flowchart illustrating the BIM model data query method in this application embodiment; Figure 3 This is a schematic diagram of an exemplary hardware structure of the BIM model data query system in this application embodiment. Detailed Implementation
[0028] The terminology used in the following embodiments of this application is for the purpose of describing particular embodiments only and is not intended to be limiting of this application. As used in the specification and appended claims of this application, the singular expressions “a,” “an,” “the,” “the,” “the,” and “this” are intended to include the plural expressions as well, unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used in this application refers to and includes any or all possible combinations of one or more of the listed items.
[0029] Hereinafter, the terms "first" and "second" are used for descriptive purposes only and should not be construed as implying or suggesting relative importance or implicitly indicating the number of indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature, and in the description of the embodiments of this application, unless otherwise stated, "multiple" means two or more.
[0030] In related technologies, a common approach to data querying using natural language is to utilize large language models to translate natural language into database query statements. This method typically involves receiving a user query, combining it with schema information from the target database to construct a context-rich hint, and then having the large language model generate a structured query instruction to obtain the result. However, in specialized fields such as Building Information Modeling (BIM), when the input natural language is ambiguous, due to the complex relationships within BIM data, a vague natural language concept (such as "fire-fighting equipment on the first floor") may correspond to multiple coexisting and valid structured search paths. However, based on its probabilistic inference nature, the large language model will select what it considers the semantically most likely query path from a massive corpus to generate the instruction, potentially ignoring other equally reasonable query dimensions within the BIM data structure. This can lead to errors or omissions in the generated query statement, ultimately resulting in inaccurate data query results.
[0031] This application proposes a BIM model data query method. Upon receiving a natural language statement, instead of performing probabilistic inference, this method, based on a pre-defined structured semantic dictionary, deterministically generates all valid structured search paths for each parsed target component and its constraints within the BIM model. Subsequently, the system combines these detailed candidate paths into a comprehensive database query command through logical operations. This ensures that all logically plausible possibilities are retrieved simultaneously in a single query. Through this "census-style" query mechanism, this application fundamentally avoids the risk of data omissions caused by relying on a single semantic guess, transforming a potentially incomplete query process into a rigorous process that ensures logical integrity, thereby significantly improving the accuracy and completeness of the data query results.
[0032] Figure 1 This is a flowchart illustrating the BIM model data query method used in the embodiments of this application, including the following steps: S101. After receiving the natural language statement, perform lexical analysis on the natural language statement based on the preset structured semantic dictionary to obtain one or more target components and one or more limiting conditions.
[0033] Specifically, natural language statements refer to unstructured query commands entered by users following everyday language habits. They are characterized by flexible expression and potential semantic ambiguity. A structured semantic dictionary is a pre-built knowledge base specific to a particular domain (in this case, BIM), systematically storing the mapping between natural language vocabulary and machine-understandable, structured semantic concepts. A target component refers to the entity category that is the primary object of search, manipulation, or analysis in the user's query intent. Limitations refer to specific attributes, states, or relationships used to filter, constrain, or describe target components, serving as the basis for the query.
[0034] Upon receiving a natural language statement, a word segmentation algorithm (such as a segmenter based on maximum matching, N-gram model, or Hidden Markov Model) is used to divide the continuous character sequence into a word sequence with basic semantic units, i.e., lexical units. For example, for the statement "find the fire pipes on the second floor", the word segmentation result is ["find", "second floor", "of", "fire pipes"].
[0035] After word segmentation, the word sequence is traversed, and each word or a series of consecutive words is used as a key to query a pre-defined structured semantic dictionary. The structured semantic dictionary is a knowledge base containing rich semantic information, and its internal data structure is typically key-value pairs. The key is a word in natural language, such as "door," "pipe," or "second floor." The value is a structured information body, containing at least the semantic role of the word and its corresponding standard paradigm. A semantic role refers to the function or category a word plays in a sentence. For example, the semantic role of "door" is a component entity, and the semantic role of "fireproof" is an attribute name. A standard paradigm refers to a unified, unambiguous standard name or identifier within a word or concept. For example, regardless of whether the user inputs "door," "door," or "a plate-like component that typically opens by rotation or translation to manage access between two independent spaces," their standard paradigm can be unified as "door."
[0036] When traversing the word sequence, once a match is successfully found in the dictionary, the word is labeled with the semantic information defined in the dictionary, and the originally undifferentiated word sequence is given a semantic role that the machine can understand.
[0037] S102. Based on the predefined BIM inherent relationship types in the structured semantic dictionary, generate a set of corresponding candidate query paths for each target component and each limiting condition.
[0038] Specifically, BIM inherent relationship types refer to standardized associations predefined in the data structure of a building information model (BIM) that describe relationships between components, between components and spaces, or between components and systems, conforming to the logic of architectural engineering. Examples include geometric inclusion relationships, system-level membership relationships, or defined type and instance relationships. A candidate query path group refers to the set of all possible data access candidate query paths generated based on the aforementioned BIM inherent relationship types, for a semantic concept parsed from natural language (such as a target component or a limiting condition).
[0039] Take a structured semantic concept (e.g., the qualifier "located on the second floor") as input and query a structured semantic dictionary. For each core entity or attribute concept in the dictionary, a set of BIM-native relationship types are predefined and associated.
[0040] When the concept of "located on the second floor" is input, all valid relation types related to the concept of location are retrieved from the dictionary, and a specific candidate query path is instantiated based on each relation type. This is a one-to-many divergent generation process, aiming to interpret the connotation of location from different dimensions. Direct geometric location path: corresponds to physical location. A path is generated based on spatial inclusion relationships, its semantics being to directly find all components whose geometric center point coordinates or bounding boxes fall within the spatial entity area of the second floor. Functional system affiliation path corresponds to functional location. The location of a component can also be defined by its associated engineering system. Based on predefined service area relationships, an indirect path is generated, its semantics being: first, all engineering systems are searched, systems whose service area attribute is marked as "second floor" are filtered out, and then all member components contained in these systems are searched.
[0041] In practical applications, suppose a BIM model contains underfloor heating pipes pre-embedded in the first-floor ceiling structure for installing underfloor heating on the second floor. Therefore, the geometric coordinates of these pipes actually belong to the first floor. However, another portion of the pipes is laid directly on the second-floor floor. Both of these pipes belong to an engineering system called the second-floor underfloor heating system. After the above process, both types of pipes can be retrieved. However, in related technologies, the pipes located on the first floor might be ignored, leading to inaccurate queries.
[0042] In the above process, the original single concept of "located on the second floor" was expanded into a group of candidate query paths that simultaneously included two different query strategies: physical location and functional location. By exhaustively enumerating all possible query dimensions that conform to BIM logic, the recall rate of the query is maximized to ensure that the user's true intent is accurately captured, rather than merely remaining at the literal understanding of geometric location.
[0043] S103. Each candidate query path in the candidate query path group is combined using logical operators to form a conditional query block.
[0044] Specifically, each independent candidate query path group is traversed, and the logical operator "OR" is applied to connect all candidate query paths within the group to obtain the conditional query block.
[0045] The theoretical basis for using the "OR" operator is that all paths within a path group are essentially multiple equivalent interpretations of the same user intent. For example, for the intent "located on the second floor," whether the component is found through geometric coordinates or through system function attribution, it should be considered to satisfy the user's query requirement. Therefore, these paths are related by "OR"—satisfying the conditions of any one of these paths is equivalent to satisfying the overall requirement of the semantic concept.
[0046] S104. Use logical operators to connect all conditional query blocks to obtain the database query instruction.
[0047] Specifically, all generated conditional query blocks are collected and concatenated using the AND operator.
[0048] The theoretical basis for choosing the "AND" operator lies in the fact that a user's natural language query is essentially a set of constraints that must be satisfied simultaneously. When a user requests "find the underfloor heating pipes on the second floor," the implicit logic is that the target object must both be "underfloor heating pipes" and "located on the second floor." These two conditions are a typical "AND" relationship; neither can be omitted. Each conditional query block represents an independent constraint, and only objects that satisfy all constraints represent the user's desired result.
[0049] Ultimately, this structured logical expression is compiled into specific instructions that conform to the query syntax of a particular database (such as SQL database, graph database, etc.), resulting in a database query instruction.
[0050] S105. Execute the database query command to retrieve the target component from the BIM model database.
[0051] Specifically, the final string instructions, defined in a database query language (such as SQL, NoSQL query syntax, or Cypher for graph databases), are sent to the BIM model database via the database connector. Upon receiving the instructions, the database's query parser performs syntax validation and breaks them down into an internally understandable operation tree.
[0052] Before execution, the database query optimizer reconstructs the original operation tree based on the database's internal statistics, index status, and other factors, generating an execution plan with the lowest execution cost (e.g., shortest time, least I / O). For example, the optimizer decides which part of the AND clause to execute first, or how to process the OR clause most efficiently to narrow down the search scope as quickly as possible.
[0053] The database execution engine performs data lookups in the physical storage layer according to the optimized execution plan. It accesses rows of tables, collections of documents, or nodes of graphs, applying every AND and OR logic block contained in the query command to filter, join, and select the data.
[0054] All data records that satisfy the complete query command logic are collected to form a result set. This result set contains information about one or more query target components and is then returned to the application that initiated the query.
[0055] S106. Merge and deduplicate the target components of the query, and mark the corresponding candidate query path for each target component as the basis for the result source.
[0056] Specifically, since a component may simultaneously satisfy multiple candidate query paths connected by "OR" (e.g., a component is physically located on the second floor, and its system also serves the second floor), under certain database execution strategies, the same component may appear multiple times in the original result set. By traversing the original result set returned by the database and utilizing the component's globally unique identifier, a set that does not allow duplicate members is constructed, thereby ensuring that each target component appears only once in the final list.
[0057] While deduplicating, the source of the results is recorded and labeled, that is, which candidate query path(s) matched each unique component. Specifically, when processing each returned component, it verifies which specific path combinations in the final query instruction the component satisfies. For example, it checks whether the component satisfies the combination of path A1 AND path B1, and whether it satisfies the combination of path A1 AND path B2. Then, all the path descriptions that enabled the successful retrieval are appended as a data tag to the component.
[0058] In some embodiments, after source labeling of the target component, a rule-based conflict detection, arbitration, and correction suggestion generation mechanism can be further introduced, which can not only discover data, but also proactively identify and assist in solving data quality problems.
[0059] First, the pre-defined logical rule base is queried, which defines the logical contradictions between different BIM inherent relationship types in a formal language. For example, a rule might be defined as: "There is a functional conflict between the system to which a component's system membership relationship points (such as a fire sprinkler system) and the space to which its geometric inclusion relationship points (such as a power supply shaft)."
[0060] Iterate through the list of source-labeled query target components generated in the previous stage. For each query target component, check the multiple candidate query paths in the source basis to see if they trigger any contradictory rules in the logical rule base. Once triggered, mark the query target component as a conflicting component and mark the candidate query paths that caused the conflict as conflicting paths.
[0061] Upon discovering a conflict, the system queries a pre-defined conflict arbitration rule library, which sets priorities for different BIM-specific relationship types. For example, a rule could be defined as: "When determining the functional affiliation of a component, system membership has higher priority than geometric inclusion," because the physical installation location of a component may sometimes deviate from its functional service area for construction convenience.
[0062] According to the rules in the conflict arbitration rule base, the highest priority conflict path is determined among multiple conflict paths. However, contextual verification is performed, focusing on the conflicting component, by searching for directly connected components (such as upstream and downstream pipes) or other components within a pre-defined association range (such as other equipment in the same room) in the BIM model, and determining whether these related components generally conform to the highest priority conflict path.
[0063] If, for example, a pipe located on the first floor is classified as part of the "second-floor heating" system, and all other pipes connected to it also belong to the "second-floor heating" system, then its functional classification is correct. In this case, the arbitration result should be adopted, and the conflicting component should be classified into the category determined by the highest priority path.
[0064] If not, it means that a reliable judgment cannot be made automatically, and the conflicting component will be classified into a separate conflict category awaiting review by a human.
[0065] For identified conflicts, the conflict pattern knowledge base is queried. This knowledge base stores a large number of BIM data error patterns (such as "system affiliation and spatial location mismatch", "component type and material conflict", etc.). The conflict path combination of the current conflicting component is matched with the conflict pattern knowledge base to identify the corresponding specific error pattern.
[0066] Extract one or more candidate correction operations from a pre-defined correction strategy library for the specific error mode. For example, for "system-location mismatch", the strategy library may provide operation A: correct the system affiliation attribute of the component and operation B: correct the spatial location attribute of the component.
[0067] For each candidate modification operation, the data relationship network of the BIM model is traversed to deduce all other components that will be directly or indirectly affected if the operation is executed. For example, modifying the system classification of a pipeline may affect the hydraulic calculation and analysis results of the entire pipeline. The set of affected components that is deduced is the influence domain of the operation.
[0068] Finally, for each candidate correction operation, a correction suggestion containing an operation description and the corresponding influence domain is generated, and the correction suggestion is associated with the conflicting component and then output.
[0069] By introducing the closed-loop process of conflict detection, arbitration, and correction suggestions, the accuracy of automated classification of data contradictions discovered during the query process is improved by utilizing context and rule knowledge base. Furthermore, the predictability of correction operations is obtained through influence domain inference. By proactively revealing and assisting in the correction of potential logical contradictions in the model, the reliability of the BIM model as a data source is improved. This means that in the future, the ambiguity and uncertainty of data queries based on this model will be reduced, thereby improving the accuracy of data queries on building BIM models.
[0070] S107. Classify the target components of the query according to the source of the results to obtain the data query results.
[0071] Specifically, the source of the result is used as a category key. All query target components that have undergone merging, deduplication, and source tagging are traversed, and the source path combinations associated with each component are examined. Components with identical source path combinations are grouped into the same logical category. The result list is then transformed into a multi-dimensional, structured analysis report.
[0072] In the above embodiments, based on a predefined structured semantic dictionary, a fully coexisting and valid structured search path is generated for any concept in natural language within the BIM model. These paths are then combined into a comprehensive database query command, allowing for the simultaneous retrieval of all logically plausible possibilities during the query execution phase. This mechanism avoids the drawback of large language models in related technologies, which, due to their probabilistic inference nature, tend to select the most probable single path while ignoring other reasonable interpretations when faced with fuzzy concepts. By ensuring that all potential dimensions conforming to the BIM structural logic are included in the retrieval scope, a query process that might be missed due to semantic bias is transformed into a logically complete process, avoiding data omissions caused by a single query path and improving the accuracy of data query results.
[0073] In some other embodiments of this application, when a user's initial query returns zero results due to the use of non-standard terminology or errors, the query may fail and be interrupted, reducing interaction efficiency. The BIM model data query method provided in this application intelligently broadens and reorganizes the query, proactively recommends effective keywords to the user, and learns from multiple failure records to automatically supplement high-frequency word pairs with synonyms, thereby enabling the query system to self-evolve.
[0074] like Figure 2 The diagram shown is another flowchart illustrating the BIM model data query method provided in this application embodiment, including the following steps: S201. After receiving the natural language statement, perform lexical analysis on the natural language statement based on the preset structured semantic dictionary to obtain one or more target components and one or more limiting conditions.
[0075] S202. Based on the predefined BIM inherent relationship types in the structured semantic dictionary, generate a set of corresponding candidate query paths for each target component and each limiting condition.
[0076] S203. Each candidate query path in the candidate query path group is combined using logical operators to form a conditional query block.
[0077] S204. Use logical operators to connect all conditional query blocks to obtain the database query instruction.
[0078] In some embodiments, when multiple query paths are generated for the same limiting conditions, attribute coverage judgment and path pruning can be performed to optimize query logic, avoid potential data conflicts, and improve the accuracy of the final query results.
[0079] When identifying path pairs pointing to the same logical attribute, path pairs include instance attribute paths, which point to attribute values directly assigned to a single component to characterize its independent, specific state, and inherited attribute paths, which point to attribute values with shared or default properties assigned by the component's upper-level structure, such as the system, region, or type. The simultaneous existence of these two types of paths means that for the same attribute of the same component, there are two potential, possibly different, value sources.
[0080] Once such path pairs are identified, a preset attribute coverage rule will be applied. This attribute coverage rule is a fundamental axiom of BIM data logic, explicitly defining that the instance attribute value of a component logically takes precedence over its inherited attribute value. Following this rule, it is determined that the instance attribute path logically covers the corresponding inherited attribute path, and a path pruning operation is then performed, that is, the covered inherited attribute path is deleted from the current candidate query path set.
[0081] By applying instance attribute priority overriding rules, query paths for inherited attributes that are logically overridden can be proactively eliminated. This avoids redundant or even contradictory judgments on the same attribute of the same component in the final query, thereby simplifying the query logic, reducing the database load, and ensuring that the final returned data follows the principle of attribute specificity in the BIM model, thus improving the accuracy of the query results.
[0082] S205. Execute the database query command to retrieve the target component from the BIM model database.
[0083] Steps S201-S205 and Figure 1 Steps S101-S105 in the illustrated embodiment are similar and can be found in the descriptions of steps S101-S105, which will not be repeated here.
[0084] S206. When the number of query target components returned by the database query command is zero, assign predefined relaxation priority scores to multiple limiting conditions according to the corresponding semantic categories in the structured semantic dictionary.
[0085] Specifically, if the number of target components returned is zero when the database query instruction is executed in the preceding step S205, it indicates that the user's original query conditions are too strict or have errors, resulting in no completely matching objects in the database.
[0086] In the structured semantic dictionary, each semantic category (such as "spatial location," "device model," "system," "material," etc.) is pre-assigned a numerical relaxation priority score. This score is based on statistical analysis of domain experts' experience and common query habits; the numerical value represents the negotiability or error-proneness of the category's condition. A higher relaxation priority score indicates that the condition is more likely to be entered incorrectly by the user or is less stringent, and therefore can be ignored when relaxing the query. For example, specific technical parameters such as device model and color may be misremembered or arbitrarily specified by the user.
[0087] Backtracking to the original list of constraints parsed in step S201, traversing each constraint, identifying the corresponding semantic category, then retrieving the predefined relaxed priority score corresponding to the category from the structured semantic dictionary, and binding this score to the constraint.
[0088] S207. Remove the constraint with the highest relaxation priority score as a critical constraint.
[0089] Specifically, the list of constraints that have been assigned relaxation priority scores is traversed to locate the constraint with the highest relaxation priority score. According to the relaxation priority score setting, the highest score represents either the lowest importance or the highest negotiability.
[0090] The constraint with the highest relaxation priority score is marked as the key constraint for this relaxation operation and removed from the current query condition set.
[0091] S208. Re-execute the query using the remaining constraints to obtain a generalized result set.
[0092] Specifically, the remaining constraints are recombined with the target component to create a new database query instruction with fewer constraints, which is then submitted to the BIM model database and executed.
[0093] Since the query conditions have been relaxed (the constraint most likely to fail has been removed), the probability of this query successfully returning non-empty results has increased, and the returned result set is a generalized result set.
[0094] S209. Extract attribute values of the same type as the key constraints from the generalized result set and use them as alternative keywords.
[0095] Specifically, the structure of the previously deleted key constraints is analyzed to identify the attribute type targeted by the key constraints. For example, if the removed condition is model = 001, then the target attribute type is locked as model.
[0096] Iterate through each component object in the generalization result set. For each component, read the actual attribute value of the target attribute (such as model). Collect all extracted attribute values into a temporary set and perform a deduplication operation on this set to ensure that each attribute value appears only once.
[0097] S210. While returning zero results, output query optimization suggestions containing alternative keywords.
[0098] Specifically, the process integrates several key information elements generated in the preceding steps. These elements include: the initial state where the original query returned zero results; the limiting conditions that were removed during the relaxation process and were judged as query failures; and the list of alternative keywords and the generalized result set extracted by analyzing the generalized result set, which can be used to correct the original query.
[0099] The system invokes a pre-defined natural language interaction template to structurally populate the aforementioned elements, generating a logically clear and naturally language-based query optimization suggestion. This suggestion not only informs the user of the query failure result but also infers the reason for the failure and provides verified and feasible alternative solutions.
[0100] S211. Record key limiting conditions and alternative keywords to form a query failure suggestion record.
[0101] Specifically, a standardized data structure for query failure suggestion records is defined, which includes: the timestamp of the event, the key constraints that caused the query failure (including attribute type and incorrect input value), and a list of alternative keywords found by the generalized query.
[0102] Based on the predefined query failure suggestion record structure, the obtained key limiting conditions and alternative keywords are filled in and written to a dedicated storage medium, such as a database log table or a structured log file.
[0103] S212. Record the failure suggestions for statistical queries. When the number of occurrences of a fixed combination of fixed key qualifiers and fixed alternative keywords exceeds the threshold for the number of erroneous queries, mark the fixed key qualifiers and fixed alternative keywords as potential synonym pairs.
[0104] Specifically, a data aggregation operation is performed on all stored query failure suggestion records, using a specific fixed combination—a triple or multi-tuple consisting of the attributes and values of the key limiting conditions and the values of alternative keywords—as the grouping basis. All records with the exact same combination are grouped together.
[0105] After grouping, frequency counting is performed for each combination to calculate the total number of times each specific error-correction pairing pattern appears in the historical records. The calculated occurrence count is compared to a pre-defined threshold for error query counts. This threshold is a control parameter that filters out noise data caused by occasional, isolated user errors. Only when the occurrence count of a fixed combination exceeds this threshold is the key qualifying condition and alternative keyword in that combination marked as a potential synonym pair.
[0106] S213. Add potential synonym pairs to the structured semantic dictionary.
[0107] Specifically, potential synonym pairs that have been statistically verified are directly written into the structured semantic dictionary. When the frequency of a synonym pair exceeds the threshold for erroneous queries, the entry for the standard term (i.e., alternative keyword) in the dictionary is located, and the non-standard term (i.e., key qualifying condition) is associated with it as a new alias or synonym.
[0108] S214. Merge and deduplicate the target components of the query, and label each target component with a corresponding candidate query path as the basis for the result source.
[0109] S215. Classify the target components according to the source of the results to obtain the data query results.
[0110] Steps S214-S215 and Figure 1 Steps S106-S107 in the illustrated embodiment are similar and can be found in the descriptions of steps S106-S107, which will not be repeated here.
[0111] In some embodiments, after presenting the data query results to the user, the query context can be constructed and dynamically modified to support continuous, multi-turn natural language queries containing pronouns or omitted components, thereby improving the fluency of human-computer interaction.
[0112] First, after a query is performed and the results are returned to the user, a query context generation operation is executed to integrate the target components of this query with the parsed constraints to form a structured data object.
[0113] Secondly, upon receiving a new natural language instruction, the session intent is determined first. The Natural Language Processing (NLP) module analyzes the linguistic features of the new statement to determine whether it is an incomplete query dependent on the preceding context. Typical features include pronouns such as "exists," "among," and "the region," or the omission of a specific query subject.
[0114] Once the new statement is confirmed to be a follow-up query, new, incremental constraints or target components are parsed from this incomplete statement. These newly parsed conditions are then used to overwrite or append to the previously stored query context. Based on this dynamically corrected and complete new context, a new query can be constructed and executed. This process improves interaction efficiency because users do not need to repeat known, unchanged background conditions.
[0115] By constructing and dynamically maintaining the query context, the inherent ambiguity of incomplete natural language statements is resolved. A follow-up question such as "What types are made of steel?" is no longer seen as a global, vague instruction, but rather interpreted as a specific request constrained by the preceding context. This also avoids introducing new human errors when users repeatedly enter complex queries to correct single conditions. By ensuring that incremental corrections by users are applied to a correct and complete background condition, the overall accuracy of consecutive queries is improved.
[0116] In the above embodiments, when faced with zero-result queries due to non-standard user input, the system intelligently removes the most likely erroneous key constraints to perform a generalized query. Within a validated and broader data range, it extracts actual attribute values as replacement keywords. Furthermore, these adopted correction suggestions are recorded and statistically analyzed. When the frequency of a certain error-correction combination exceeds a statistical threshold, it proves that a synonymous relationship exists between the two. This relationship is then solidified into the core semantic dictionary, achieving a shift from passive suggestions to active learning. In the future, when other users use the non-standard terminology again, it is directly pre-translated into standard terminology for query execution, improving the accuracy of data queries on building BIM models.
[0117] The following describes an exemplary BIM model data query system 300 provided in an embodiment of this application. Figure 3 This is an exemplary hardware structure diagram of the BIM model data query system 300 provided in this application embodiment.
[0118] In some embodiments, the BIM model data query system 300 is a computer device or includes a computer device in the BIM model data query system 300. The computer device includes a processor, memory, and a network interface connected via a system bus. The processor of the computer device provides computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores an operating system, computer programs, and a database. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The database of the computer device stores data. The network interface of the computer device is used to communicate with other external terminals or servers via a network connection. In some embodiments, the network interface can be a wired network interface; in some embodiments, the network interface can also be a wireless network interface. When the computer program is executed by the processor, it implements the methods in the embodiments of this application.
[0119] Those skilled in the art will understand that Figure 3 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0120] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit it. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.
[0121] As used in the above embodiments, depending on the context, the term "when..." can be interpreted as "if...", "after...", "in response to determining...", or "in response to detecting...". Similarly, depending on the context, the phrase "when determining..." or "if (the stated condition or event) is interpreted as "if determining...", "in response to determining...", "when (the stated condition or event) is detected", or "in response to detecting (the stated condition or event)".
[0122] In the above embodiments, implementation can be achieved entirely or partially through software, hardware, firmware, or any combination thereof. When implemented using software, it can be implemented entirely or partially in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, digital subscriber line) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that integrates one or more available media. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., solid-state drive), etc.
[0123] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. This program can be stored in a computer-readable storage medium, and when executed, it can include the processes described in the above method embodiments. The aforementioned storage medium includes various media capable of storing program code, such as ROM or random access memory (RAM), magnetic disks, or optical disks.
Claims
1. A method for querying BIM model data, characterized in that, include: Upon receiving a natural language statement, lexical analysis is performed on the natural language statement based on a preset structured semantic dictionary to obtain one or more target components and one or more limiting conditions. Based on the predefined BIM inherent relationship types in the structured semantic dictionary, a set of corresponding candidate query paths is generated for each target component and each limiting condition. Each candidate query path in the candidate query path group is combined using logical operators to form a conditional query block; Use logical operators to connect all the conditional query blocks to obtain the database query instruction; Execute the database query command to retrieve the target component from the BIM model database; The query target components are merged and deduplicated, and each query target component is labeled with the corresponding candidate query path as the basis for the result source. The query target components are classified according to the source of the results to obtain the data query results.
2. The method according to claim 1, characterized in that, After executing the database query instruction and retrieving the target component from the BIM model database, the process further includes: When the number of the target components returned by the database query instruction is zero, predefined relaxation priority scores are assigned to the multiple limiting conditions according to the corresponding semantic categories in the structured semantic dictionary. The constraint with the highest relaxation priority score is treated as a critical constraint and removed. Re-execute the query using the remaining constraints to obtain a generalized result set; Extract attribute values of the same type as the key limiting conditions from the generalization result set and use them as alternative keywords; While returning zero results, output query optimization suggestions containing the aforementioned alternative keywords.
3. The method according to claim 2, characterized in that, After returning zero results and outputting query optimization suggestions containing the alternative keywords, the method further includes: Record the key limiting conditions and the alternative keywords to form a query failure suggestion record; The query failure suggestion records are statistically analyzed. When the frequency of occurrence of a fixed combination of a fixed key limiting condition and a fixed alternative keyword exceeds the threshold for the number of erroneous queries, the fixed key limiting condition and the fixed alternative keyword are marked as potential synonym pairs. The potential synonym pairs are added to the structured semantic dictionary.
4. The method according to claim 1, characterized in that, After merging and deduplicating the query target components and labeling each query target component with the corresponding candidate query path as the result source basis, the method further includes: Based on a preset logical rule base, when there is a semantic conflict among multiple candidate query paths corresponding to the query target component, the query target component that is judged to have a semantic conflict is marked as a conflicting component, and the candidate query path that generates the semantic conflict is marked as a conflicting path; the logical rule base defines the logical contradiction relationship between different BIM inherent relationship types; Based on preset conflict arbitration rules, the multiple conflict paths are prioritized to determine the highest priority conflict path. Obtain the connected components and associated components within a preset association range of the conflicting component in the BIM model, and determine whether the connected component or the associated component conforms to the highest priority conflict path; If so, the conflicting component is classified into the query result category determined by the highest priority conflicting path; If not, the conflicting component will be categorized into a separate conflict category to be reviewed.
5. The method according to claim 4, characterized in that, After classifying the conflicting components into a separate category of conflicts to be reviewed, the method further includes: The conflicting components and conflicting paths are matched with a preset conflict pattern knowledge base to match a specific error pattern. For the specific error mode, one or more candidate correction operations are extracted from a preset correction strategy library; For each of the candidate correction operations, by traversing the data associations of the BIM model, the components that will be directly or indirectly affected after the corresponding operation is executed are deduced, and the corresponding influence domain is obtained. For each of the candidate correction operations, generate a correction suggestion that includes an operation description and the influence domain; Associate one or more of the aforementioned correction suggestions with the conflicting component, and output the correction suggestion information.
6. The method according to claim 1, characterized in that, Before obtaining the database query instruction by connecting the conditional query block with logical operators, the method further includes: When there are path pairs corresponding to instance attribute paths and inherited attribute paths respectively in a set of candidate query paths generated under the same limiting condition, it is determined whether the instance attribute path covers the inherited attribute path according to the preset attribute coverage rule; the instance attribute path is the query path of the attribute of the component that is independently assigned a value; the inherited attribute path is the query path of the shared or inherited attribute obtained by the component in the system or region; the attribute coverage rule defines that the instance attribute of the component takes precedence over the inherited attribute. If so, then delete the overridden inherited attribute path from the candidate query paths.
7. The method according to claim 1, characterized in that, After classifying the target component according to the result source and obtaining the data query results, the method further includes: Integrate the target query component and the limiting conditions to generate a query context; Upon receiving a new natural language statement, if it is determined that the new natural language statement contains an incomplete query with a pronoun or an omitted subject, a new target component or a new limiting condition is parsed from the new natural language statement. The query context is modified by overriding the query target component or the query constraint with the new target component or the new constraint.
8. A BIM model data query system, characterized in that, The BIM model data query system includes: one or more processors and a memory; the memory is coupled to the one or more processors, the memory is used to store computer program code, the computer program code includes computer instructions, and the one or more processors call the computer instructions to cause the BIM model data query system to perform the method as described in any one of claims 1-7.
9. A computer program product containing instructions, characterized in that, When the computer program product is run on the BIM model data query system, the BIM model data query system performs the method as described in any one of claims 1-7.
10. A computer-readable storage medium comprising instructions, characterized in that, When the instruction is executed on the BIM model data query system, the BIM model data query system performs the method as described in any one of claims 1-7.
Citation Information
Cited By
Method, device and equipment for intelligently controlling BIM model and storage medium
CN121300741A