BIM (Building Information Modeling) review method based on large language model
The automatic review of BIM through the large language model solves the problems of high time consumption and low accuracy caused by the existing manual BIM review, achieving efficient and accurate BIM review, reducing labor consumption and reducing costs.
Patent Information
- Application Number
- CN202411492443.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-24
- Publication Date
- 2025-01-21
AI Technical Summary
The existing BIM review mainly relies on labor, resulting in high time consumption and easy-to-be-influence of subjective factors, and the accuracy cannot be guaranteed.
A large language model is used to realize automatic review of BIM. By obtaining element information in the building information model and building a model database, combined with optical character recognition technology, it extracts keywords from CAD drawings, builds a CAD information database, and provides guidance based on the review instructions input by the user. The large language model performs each review sub-task, performs correlation matching between the model database and the CAD information database, and outputs review results.
It improves the efficiency and accuracy of BIM review, reduces the consumption of manpower, avoids the occurrence of human errors, generates review reports that are accurate and reliable, and saves a lot of labor costs.
Smart Images

Figure CN119336895A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of computer-aided management, and in particular to a BIM review method based on a large language model. Background Art
[0002] BIM (Building Information Modeling) is an important tool in the process of building design, construction and management. It can integrate building information and update and accumulate building information throughout the life cycle of the building, thereby providing data support for the decision-making of all project participants. In order to ensure the validity of building information in BIM, it needs to be reviewed before BIM is delivered. The existing BIM review is mainly carried out manually. However, manual review requires a lot of time and manpower, and the review results are easily affected by subjective factors, and the accuracy cannot be guaranteed. Summary of the invention
[0003] The purpose of the embodiment of the present invention is to provide a BIM review method based on a large language model, which can use the large language model to realize automatic review of BIM, improve review efficiency and accuracy, and reduce manpower consumption.
[0004] To achieve the above object, an embodiment of the present invention provides a BIM review method based on a large language model, comprising:
[0005] Acquire element information in a target building information model, and construct a model database according to the element information;
[0006] Extracting keywords from the target CAD drawings using optical character recognition technology and constructing a CAD information database; wherein the target CAD drawings are CAD drawings corresponding to the target building information model;
[0007] Constructing prompt words according to the review instructions input by the user, so as to guide the large language model to perform each review subtask one by one according to the prompt words;
[0008] When executing each of the review subtasks, the large language model performs association matching on the model database and the CAD information database, and outputs corresponding review results.
[0009] As an improvement of the above solution, the step of obtaining element information in the target building information model and constructing a model database according to the element information includes:
[0010] Calling the Revit document of the target building information model, and reading all the element information from the Revit document;
[0011] Convert each element information into a text string;
[0012] Each of the text strings is converted into a vector representation using an embedding model, and the model database is constructed based on the vector representation.
[0013] As an improvement of the above solution, the associative matching of the model database and the CAD information database includes:
[0014] A comparative learning model is used to perform similarity search on the model database and the CAD information database, and a matching result is output to generate the review result.
[0015] As an improvement of the above solution, the use of a contrastive learning model to perform similarity search on the model database and the CAD information database includes:
[0016] The encoder is used to convert the data in the model database and the CAD information database into vectors respectively, and similarity judgment is performed based on the cosine values between the corresponding vectors.
[0017] As an improvement to the above solution, the contrastive learning model is pre-trained using the following loss function:
[0018]
[0019] Among them, L represents the loss function; S i,j represents the cosine similarity between the i-th data and the j-th data; τ represents the temperature coefficient; N represents the total number of data; e represents a natural constant; and log represents a logarithmic function.
[0020] As an improvement to the above solution, the format of the text string is one of Markdown format, character separated value format or JSON format.
[0021] As an improvement of the above solution, the element information includes the type, name, size and position of the element, and the element is a building structure.
[0022] As an improvement of the above solution, after executing each of the review subtasks, the large language model also summarizes the review results of each of the review subtasks to generate a review report.
[0023] As an improvement of the above solution, after aggregating the review results of each review subtask and before generating the review report, the method further includes:
[0024] Evaluating the accuracy of the review results of each review subtask;
[0025] Select the review subtasks whose accuracy does not meet the preset requirements and construct new prompt words for them;
[0026] The new prompt word is used to guide the large language model to re-execute the review subtask whose accuracy does not meet the preset requirement.
[0027] As an improvement of the above scheme, before adopting the new prompt word to guide the large language model to re-execute the review subtask whose accuracy does not meet the preset requirements, it also includes rebuilding the model database and / or CAD information database.
[0028] Compared with the prior art, the BIM review method based on the large language model provided in the embodiment of the present invention obtains element information in the target building information model, and constructs a model database based on the element information; uses optical character recognition technology to extract keywords from the target CAD drawings, and constructs a CAD information database; wherein the target CAD drawings are CAD drawings corresponding to the target building information model; constructs prompt words according to the review instructions input by the user, so as to guide the large language model to perform each review subtask one by one according to the prompt words; wherein, when executing each of the review subtasks, the large language model performs correlation matching on the model database and the CAD information database, and outputs the corresponding review results. Compared with the prior art, the embodiment of the present invention uses a large language model to realize automatic review of BIM, which can improve the review efficiency and the accuracy of the review results, and reduce the consumption of manpower. BRIEF DESCRIPTION OF THE DRAWINGS
[0029] Figure 1 It is a flowchart of a BIM review method based on a large language model provided by one embodiment of the present invention. DETAILED DESCRIPTION
[0030] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0031] See also Figure 1 , is a flow chart of a BIM review method based on a large language model provided by an embodiment of the present invention, comprising steps S1 to S3:
[0032] S1, obtaining element information in a target building information model, and constructing a model database according to the element information;
[0033] S2, extracting keywords from the target CAD drawing using optical character recognition technology, and constructing a CAD information database; wherein the target CAD drawing is a CAD drawing corresponding to the target building information model;
[0034] S3, constructing prompt words according to the review instruction input by the user, so as to guide the large language model to perform each review subtask one by one according to the prompt words;
[0035] When executing each of the review subtasks, the large language model performs association matching on the model database and the CAD information database, and outputs corresponding review results.
[0036] It is worth noting that, in step S1, the target building information model can be understood as the building information model to be reviewed, that is, the BIM to be reviewed.
[0037] As an optional implementation manner, the element information includes the type, name, size and position of the element, and the element is a building structure.
[0038] It is worth noting that the element information extracted from the target building information model can be understood as the information of the building structure, wherein the building structure can be walls, doors and windows, beams and columns, etc., and the element information includes the type, name, size and position of the element.
[0039] As an optional implementation manner, the step of obtaining element information in a target building information model and constructing a model database according to the element information (S1) includes:
[0040] S11, calling the Revit document of the target building information model, and reading all the element information from the Revit document;
[0041] S12, converting each element information into a text string;
[0042] S13. Using an embedding model to convert each of the text strings into a vector representation, and constructing the model database based on the vector representation.
[0043] Furthermore, in step S11, a C language program may be written to call a Revit API (Application Programming Interface) to read a Revit document; further, a code may be written to traverse the Revit document to read all element information in the Revit document.
[0044] As an optional implementation, in step S12, the format of the text string is one of Markdown format, character separated value format or JSON (JavaScript Object Notation) format.
[0045] Furthermore, in step S13, an embedding model is used to capture semantic information of text strings, and similar text strings are generated into similar vector representations for use in building a model database.
[0046] It is understandable that the model database constructed above is constructed based on the information in the target building information model. In order to review the target building information model, it is also necessary to construct a database for the target CAD (Computer Aided Design) drawings, that is, to construct a CAD information database.
[0047] Furthermore, in step S2, optical character recognition technology (OCR) may be used to extract keywords from the target CAD drawings for use in constructing a CAD information database, wherein the keywords may include building types, building parameters, and specification requirements.
[0048] It is worth noting that, in some implementations, the CAD information database may be constructed first, and then the model database may be constructed, that is, the order of the above-mentioned step S1 and step S2 may be swapped, which is not limited here.
[0049] Furthermore, in step S3, a prompt word (Prompt) is constructed according to the review instruction input by the user, and the prompt word is input into a large language model (LLM) to help the large language model understand the current task and guide the large language model to complete the task.
[0050] It is worth noting that a major difference between the embodiment of the present invention and the prior art is that the embodiment of the present invention does not manually review the building information model, but uses the memory retrieval capability of the large language model to achieve automatic review of the building information model. In order to help the large language model understand the review task and guide it to complete the review task, it is necessary to construct prompt words for it. Furthermore, the "prompt words" of the embodiment of the present invention are intended to provide instructions for the large language model, but their form is not limited to words, but can also be sentences, which is not limited here.
[0051] For example, the user's review instruction may be "check whether all windows are set according to specifications", and the prompt word may be "please check whether all windows in the residential building BIM are set according to specifications."
[0052] In some embodiments, the large language model can also participate in the construction of the CAD information database in step S2. At this time, a prompt word can be input into the large language model: "Extract each keyword from the keyword list output by OCR. The text recognition results of OCR are surrounded by '' symbols and contain the recognized text, and the order is from left to right and from top to bottom in the original image. The specified keyword list is surrounded by 0 symbols. Please note that the OCR recognition results may have problems such as long sentences being cut off, unreasonable word segmentation, and incorrect merging of text. A comprehensive judgment based on the context semantics is required to extract accurate keywords. The JSON format is used when returning the results, including multiple key-value pairs, the key value is the specified keyword, and the value value is the extracted result. If it is believed that there is no keyword key in the OCR recognition result, the value is assigned to 'no relevant information found' and the result in JSON format is output. "
[0053] Further, in step S3, the large language model will execute each review subtask one by one according to the prompt words. It can be understood that if the review target building information model is regarded as a review task, then this review task will include multiple different subtasks, such as door and window review subtasks, wall review subtasks, and beam and column review subtasks, etc. Then, when the large language model reviews the target building information model, it will execute each review subtask one by one. After each review subtask is executed, it is necessary to check whether there are any unexecuted review subtasks. If so, execute a new review subtask, otherwise, end the review process. For example, execute the door and window review subtask first, then execute the wall review subtask, and then execute the beam and column review subtask until all review subtasks are completed. Further, in step S3, when the large language model executes each review subtask, it will associate and match the model database and the CAD information database, and output the review result of the review subtask.
[0054] As an optional implementation manner, the associating and matching the model database and the CAD information database includes:
[0055] A comparative learning model is used to perform similarity search on the model database and the CAD information database, and a matching result is output to generate the review result.
[0056] As an optional implementation manner, the using of a contrastive learning model to perform similarity search on the model database and the CAD information database includes:
[0057] The encoder is used to convert the data in the model database and the CAD information database into vectors respectively, and similarity judgment is performed based on the cosine values between the corresponding vectors.
[0058] Specifically, in step S3, when executing each review subtask, the large language model will perform a similarity search on the model database and the CAD information database, that is, it will convert the data in the two databases into vectors and perform similarity judgment based on the cosine value to achieve self-inspection of the model and the drawing.
[0059] As an optional implementation, the contrastive learning model is pre-trained using the following loss function:
[0060]
[0061] Among them, L represents the loss function; S i,j represents the cosine similarity between the i-th data and the j-th data; τ represents the temperature coefficient; N represents the total number of data; e represents a natural constant; and log represents a logarithmic function.
[0062] For example, the value of τ may be 0.05.
[0063] Furthermore, S i,j The calculation formula is as follows:
[0064]
[0065] Among them, S i,j represents the cosine similarity between the i-th data and the j-th data; h i Indicates the i-th data; h j represents the jth data; T represents the transposition operation; |||| represents the norm operation.
[0066] As an optional implementation, after executing each of the review subtasks, the large language model also summarizes the review results of each of the review subtasks to generate a review report.
[0067] It can be understood that the embodiment of the present invention can facilitate user review and analysis by aggregating the review results of each review subtask to generate a review report.
[0068] As an optional implementation manner, after aggregating the review results of each review subtask and before generating the review report, the method further includes:
[0069] Evaluating the accuracy of the review results of each review subtask;
[0070] Select the review subtasks whose accuracy does not meet the preset requirements and construct new prompt words for them;
[0071] The new prompt word is used to guide the large language model to re-execute the review subtask whose accuracy does not meet the preset requirement.
[0072] For example, the user can evaluate and verify the review results of the review subtask to confirm the accuracy and reliability of the review results. When the evaluation results show that the review results are inaccurate, the review process or review objectives can be adjusted as needed and the review task can be re-executed.
[0073] As an optional implementation, before using the new prompt word to guide the large language model to re-execute the review subtask whose accuracy does not meet the preset requirement, it also includes rebuilding the model database and / or CAD information database.
[0074] Compared with the prior art, the BIM review method based on the large language model provided in the embodiment of the present invention obtains the element information in the target building information model, and constructs a model database according to the element information; uses optical character recognition technology to extract keywords from the target CAD drawings, and constructs a CAD information database; wherein the target CAD drawings are CAD drawings corresponding to the target building information model; constructs prompt words according to the review instructions input by the user, so as to guide the large language model to perform each review subtask one by one according to the prompt words; wherein, when executing each of the review subtasks, the large language model performs correlation matching on the model database and the CAD information database, and outputs the corresponding review results. Compared with the prior art, the embodiment of the present invention uses a large language model to realize automatic review of BIM, which can improve the review efficiency and the accuracy of the review results, and reduce the consumption of manpower.
[0075] In order to have a clearer understanding of the BIM review method based on the large language model, the following takes the BIM review of a residential building as an example. It should be noted that the BIM of the residential building contains a large number of elements, such as walls, doors and windows, beams and columns, etc., which need to be comprehensively reviewed to ensure that they comply with design specifications and construction requirements.
[0076] First, the data of the target building information model, that is, the data of the residential building BIM, needs to be loaded. Specifically, the Revit document is read through the Revit API interface, and all element information in the residential building BIM is read from the Revit document, including the element type, name, size, and location, etc., and the model database is built based on the extracted element information.
[0077] Next, it is necessary to extract information from the target CAD drawing, wherein the target CAD drawing is the CAD drawing of the residential building. Specifically, optical character recognition technology is used to extract keywords from the target CAD drawing and build a CAD information database, wherein the keywords may be "doors and windows" and "specifications" and the like.
[0078] Then, prompt words are constructed according to the review instructions input by the user to help the large language model understand the review task and guide it to perform the review task. For example, the user may enter "check whether all doors and windows are set according to the specifications", then the prompt word "Please check whether all doors and windows in the residential building BIM are set according to the specifications" is constructed. Furthermore, the large language model executes each review subtask one by one, and when executing the review subtask, the large language model will associate and match the model database and the CAD information database. For example, the door and window elements in the residential building BIM are matched with the specification requirements in the target CAD drawings to evaluate whether the doors and windows in the residential building BIM meet the specification requirements, and then output the review results of each review subtask, for example, "All doors and windows in the residential building BIM meet the specification requirements." Furthermore, the large language model executes each review subtask one by one, summarizes the review results of each review subtask, and generates a review report.
[0079] Finally, after receiving the review report of the residential building BIM, the user can also evaluate and verify the review report to confirm whether the review report is accurate and reliable enough. If it is inaccurate or unreliable, the review process or review target can be adjusted as needed, and the review task can be re-executed. Alternatively, the user can also evaluate and verify the review results of each review subtask before the large language model generates the review report, and guide the large language model to re-execute the review subtask with inaccurate review results.
[0080] Compared with the prior art, the BIM review method based on the large language model provided in the embodiment of the present invention adopts the large language model to automatically complete the review work without human intervention, which can greatly improve the review efficiency; and, by utilizing the information extraction capability and association matching capability of the large language model for BIM review, it can effectively avoid the occurrence of human errors and improve the accuracy and reliability of the review results; further, the present invention can flexibly adjust the review process according to user needs, and automatically generate a review report for user convenience in review and analysis; finally, the present invention can also save a lot of manpower costs and improve work efficiency, thereby reducing the total cost of BIM review.
[0081] The above is a preferred embodiment of the present invention. It should be pointed out that a person skilled in the art can make several improvements and modifications without departing from the principle of the present invention. These improvements and modifications are also considered to be within the scope of protection of the present invention.
Claims
1. A BIM review method based on a large language model, characterized in that: include: Acquire element information in a target building information model, and construct a model database according to the element information; Extracting keywords from the target CAD drawings using optical character recognition technology and constructing a CAD information database; wherein the target CAD drawings are CAD drawings corresponding to the target building information model; Constructing prompt words according to the review instructions input by the user, so as to guide the large language model to perform each review subtask one by one according to the prompt words; When executing each of the review subtasks, the large language model performs association matching on the model database and the CAD information database, and outputs corresponding review results.
2. The BIM review method based on a large language model as claimed in claim 1, characterized in that: The step of acquiring element information in a target building information model and constructing a model database according to the element information includes: Calling the Revit document of the target building information model, and reading all the element information from the Revit document; Convert each element information into a text string; Each of the text strings is converted into a vector representation using an embedding model, and the model database is constructed based on the vector representation.
3. The BIM review method based on a large language model according to claim 1, characterized in that: The associating and matching the model database with the CAD information database includes: A comparative learning model is used to perform similarity search on the model database and the CAD information database, and a matching result is output to generate the review result.
4. The BIM review method based on a large language model as claimed in claim 3, characterized in that: The using of the contrastive learning model to perform similarity search on the model database and the CAD information database includes: The encoder is used to convert the data in the model database and the CAD information database into vectors respectively, and similarity judgment is performed based on the cosine values between the corresponding vectors.
5. The BIM review method based on a large language model as claimed in claim 3, characterized in that: The contrastive learning model is pre-trained using the following loss function: Among them, L represents the loss function; S i,j represents the cosine similarity between the i-th data and the j-th data; τ represents the temperature coefficient; N represents the total number of data; e represents a natural constant; and log represents a logarithmic function.
6. The BIM review method based on a large language model as claimed in claim 2, characterized in that: The format of the text string is one of Markdown format, character separated value format or JSON format.
7. The BIM review method based on a large language model according to claim 1, characterized in that: The element information includes the type, name, size and position of the element, and the element is a building structure.
8. The BIM review method based on a large language model according to claim 1, characterized in that: After executing each of the review subtasks, the large language model also summarizes the review results of each of the review subtasks to generate a review report.
9. The BIM review method based on a large language model as claimed in claim 8, characterized in that: After the review results of each review subtask are summarized and before the review report is generated, the method further includes: Evaluating the accuracy of the review results of each review subtask; Select the review subtasks whose accuracy does not meet the preset requirements and construct new prompt words for them; The new prompt word is used to guide the large language model to re-execute the review subtask whose accuracy does not meet the preset requirement.
10. The BIM review method based on a large language model according to claim 9, characterized in that: Before adopting the new prompt word to guide the large language model to re-execute the review subtask whose accuracy does not meet the preset requirement, it also includes rebuilding the model database and / or CAD information database.