A knowledge graph-based shelter design case retrieval method
By constructing a knowledge graph-based modular hospital design case retrieval system and utilizing relationship and attribute similarity calculations, the system solves the problem of low retrieval efficiency in existing modular hospital design case technologies, enabling faster and more accurate similar case searches and improving design efficiency and production effectiveness.
Patent Information
- Application Number
- CN202310849912.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-07-11
- Publication Date
- 2025-12-12
- Estimated Expiration
- 2043-07-11
AI Technical Summary
In existing technologies, the process of finding historical design cases is inefficient for modular hospital designers, and they cannot ensure the optimality of similar cases found, resulting in low design efficiency.
A knowledge graph-based method is used to construct a case retrieval system for makeshift hospital design. The knowledge graph is represented in the Neo4j graph database through a top-down construction approach. Triples are used to describe historical cases of makeshift hospitals. The relationships and attribute similarities between cases are calculated. The Jaccard similarity coefficient, nearest neighbor retrieval algorithm and expert assignment method are used to assign weights and determine the optimal similar cases.
This improved the efficiency and accuracy of retrieval of modular hospital design cases, reduced manual modification time, ensured the rationality and reliability of design schemes, and enhanced design efficiency and production benefits.
Smart Images

Figure CN116861036B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application relates to a shelter design, in particular to a shelter design case retrieval method based on a knowledge graph. BACKGROUND
[0002] A shelter is a "box-shaped workroom with certain protection ability, which can be transported and can provide a suitable working environment for personnel and equipment, and is convenient for independent cabin of various modes of transport." In recent years, the application field of the shelter is more and more extensive, and the demand of customers for the shelter is more and more personalized. Correspondingly, a large number of shelter orders different from historical cases appear in enterprises. When facing such orders, the design personnel of the shelter manufacturing enterprise often searches the historical design case library for reference, finds similar cases and related design data, and modifies, supplements and reuses them to meet the personalized new order demand of customers. The design personnel of the enterprise still adopts the order batch number retrieval or product keyword search method to search for similar cases, which requires the design personnel to have higher experience. In addition, manual retrieval is not only low in efficiency, but also cannot ensure the optimality of the similar cases retrieved. The traditional design method has become a factor restricting the efficiency of the shelter design, so it is necessary to study the shelter design case retrieval technology, which will help the design personnel to find similar cases more quickly, improve the retrieval efficiency and accuracy, reduce repetitive labor and improve the design efficiency.
[0003] The knowledge graph was first proposed by Google in 2012. Its representation method is to record knowledge in the form of triples, and establish the connection between entities through this method. These connections are organized into a network, thus forming a rich knowledge system. Through the knowledge graph, we can more conveniently obtain and manage knowledge, and also understand the internal connection of knowledge through the association between different entities. The knowledge graph is suitable for various knowledge processing tasks, can be used in various fields and can support the sedimentation and integration of knowledge, helping people to more efficiently retrieve and utilize knowledge resources.
[0004] The shelter design case retrieval refers to retrieving the most similar historical design case to the target design case (new customer order) in the historical case library, quantitatively processing the similarity of the cases through a similarity measurement method, thereby sorting the top N similar historical design cases to the target design case, obtaining the optimal similar case, and helping the designer to find the most suitable design scheme faster. Common similarity measures include Euclidean distance, cosine similarity, Jaccard coefficient, etc. These indicators can measure the similarity between cases from different angles. In the construction of the shelter design case knowledge graph, nodes are used as entities and are described by numerical, numerical range and natural language attribute types; edges are used as relationships, reflecting the structural hierarchy between various node entities. When measuring the similarity between the target design case and the historical design case, the attribute similarity and the relationship similarity of the two need to be considered comprehensively, and different weights are given to obtain the overall case similarity after comprehensive weighting. SUMMARY
[0005] The purpose of the present application is to provide a knowledge graph-based shelter design case retrieval method, which can quickly and accurately retrieve the optimal similar case from the historical cases accumulated by the enterprise for many years when a new order occurs, so that the designer can modify and reuse the optimal similar case, shorten the design cycle, improve the design efficiency, reduce the design cost, and thus increase the enterprise benefit.
[0006] Technical scheme: The knowledge graph-based shelter design case retrieval method comprises the following steps:
[0007] (1) Construct a historical case knowledge graph for a shelter product;
[0008] The construction of the historical case knowledge graph for the shelter product adopts a top-down construction method, and a neo4j graph database is used to represent the knowledge graph.
[0009] The ontology of the knowledge graph is described by a triple defined by O={C, A C , R}, wherein C represents a concept, A C represents a concept attribute set, and R represents a relationship set between concepts.
[0010] The knowledge sources used to construct the historical case knowledge graph for the shelter product include historical design orders, delivered design cases, product three-dimensional models and drawings, and enterprise standard libraries.
[0011] (2) Establish a design target shelter case C T knowledge graph;
[0012] Establish a design target shelter case C TThe knowledge source adopted by the knowledge graph is demand information of the new order technical agreement.
[0013] (3) calculating C T the relationship similarity of the historical case C H ;
[0014] The Jaccard similarity coefficient is adopted to calculate the relationship similarity between the shelter target design case and the historical case.
[0015] (4) calculating C T the attribute similarity of the historical case C H ;
[0016] Based on the nearest neighbor search algorithm, the attribute similarity of different types of attributes in the shelter design case knowledge graph is calculated by adopting the corresponding attribute similarity calculation method, then the attribute similarity of different types of attributes in each node is weighted and allocated, and the overall attribute similarity of each node is calculated.
[0017] (5) calculating C T the overall case similarity of the historical case C H ;
[0018] The attribute similarity of different types of nodes is weighted and allocated by adopting the expert evaluation method, and the final overall similarity of the shelter design case is obtained by comprehensively considering the relationship similarity and the attribute similarity.
[0019] (6) repeating steps (3) to (5) until all the shelter instances in the historical case knowledge graph are subjected to similarity calculation;
[0020] (7) the similarity of all cases is sorted in descending order, and the first N cases are taken as the retrieval result.
[0021] The different types of attributes of each node in the shelter design case knowledge graph include specific numerical value type attributes, numerical range type attributes and text type attributes. The types of the nodes include a cabin assembly, a wallboard, a main frame, a door and window and others.
[0022] Advantages: compared with the prior art, the present application has the following advantages:
[0023] 1. The present application utilizes the knowledge graph to represent the knowledge of the historical design cases accumulated by enterprises, has high information processing efficiency, rich semantic relationship, supports data addition and updating in the later stage, and the like.
[0024] 2. The present application adopts a method of comprehensively considering subjective factors and objective factors, evaluates and calculates the similarity of the design cases from two aspects of relationship similarity and attribute similarity, and especially considers the influence of personal subjective factors in the attribute similarity calculation, so as to more scientifically and accurately determine the attribute similarity of the design cases.
[0025] 3. This invention utilizes similar case retrieval technology to apply existing design knowledge within the enterprise to the design of solutions for new orders. This allows for faster identification of similar cases, reducing manual modification time and ensuring the rationality and reliability of the design solutions. This is of great significance for improving the design efficiency of modular shelter products. By applying the similar case retrieval technology of this invention, enterprises can more efficiently promote the development of new products, improving production efficiency and product quality. Attached Figure Description
[0026] Figure 1 This is a flowchart of the steps of the method described in this invention;
[0027] Figure 2 This is a schematic diagram of the relationship system of the modular shelter;
[0028] Figure 3 A schematic diagram of the main structural form of a mobile shelter design case;
[0029] Figure 4 A schematic diagram of the technical route for searching similar design cases of mobile cabins;
[0030] Figure 5 Here are two examples of knowledge graph illustrations for makeshift hospital cases;
[0031] Figure 6 A schematic diagram of the knowledge graph for the design requirements of mobile cabins;
[0032] Figure 7 A schematic diagram of the node AHP hierarchical architecture model of the knowledge graph for the design of makeshift hospitals. Detailed Implementation
[0033] The technical solution of the present invention will be further described below with reference to the accompanying drawings.
[0034] like Figure 1 As shown, a knowledge graph-based method for retrieving case studies of makeshift hospital design includes the following steps:
[0035] (1) Construct a knowledge graph of historical cases for mobile cabin products;
[0036] Through the formula O={C,A C The triple defined by R describes the ontology of the knowledge graph of historical cases in makeshift hospitals, where C represents a concept, and A represents a concept. C Let R represent the set of conceptual attributes, and R represent the set of relationships between concepts. Analyze the modular hospital assembly structure tree to clarify the relationships and structural hierarchy between the modular hospital's ontological concepts, such as... Figure 2As shown, these relationships are divided into three categories: wall panels, accessories and standard parts (standard parts do not need to be considered in design case retrieval). Among them, the wall panel category mainly includes front wall, rear wall, left wall, right wall, top wall and bottom wall. Each wall panel also contains doors, windows, wall boxes and other accessories. The accessory category includes main frames, H-shaped frames, skids, etc. The design case ontology of the shelter product mainly distributes related concepts through the product structure level relationship. The shelter design case ontology structure is shown in Figure 3 .
[0037] After constructing the shelter ontology using the top-down knowledge graph construction method, the next step is to acquire design knowledge. This process aims to acquire relevant case design knowledge and fill it into the graph by comparing with the ontology. As shown in Figure 4 , the enterprise's historical design order cases, product 3D models and drawings, enterprise standard library, etc. have rich design data that can be used for reference and can be used as knowledge sources for building the shelter design case knowledge graph. Most of these knowledge is structured data and has been archived in the enterprise's PDM library, making it easy to obtain. At the same time, some of it is semi-structured data, which needs to be refined and integrated by artificial means before it can be stored in the knowledge graph.
[0038] As shown in Figure 5 , the knowledge graph is represented in the Neo4j graph database. The entity nodes of the graph, shelter 1 and shelter 2, represent the "cabin assembly" entity in the design case, and other nodes represent the entities of each wall panel and accessory in the shelter. The association relationships between these entities are represented by directed edges with arrows. Each entity node is attached with attribute information, which can help to find the optimal similar case more accurately during retrieval. Through the shelter design case knowledge graph, the enterprise's design resources can be integrated into one, making it easier for designers to find and utilize existing cases.
[0039] (2) Establish the design target shelter case C T knowledge graph
[0040] As shown in Figure 6 , based on the relationship system of the shelter ontology summarized in step (1), the new order obtained by the enterprise is used as the knowledge source to establish the design target shelter case C T knowledge graph.
[0041] (3) Calculate the relationship similarity between C T and historical cases C H .
[0042] This paper utilizes the principle of interrelationships between nodes in a knowledge graph of mobile cabin design cases to calculate the similarity of mobile cabin design cases. This method first requires establishing a knowledge graph of mobile cabin design cases, summarizing and categorizing various design elements and knowledge, and establishing relationships between them. Then, when calculating similarity, the relationship structure between nodes in the knowledge graph can be analyzed to identify mobile cabin design cases with high similarity. Since the types of relationships in the knowledge graph of mobile cabin design cases are clear and the number of case entities is limited, the similarity between two samples in the comparison set can be measured using the Jaccard similarity method. In this method, the Jaccard coefficient can be used to measure the similarity between two sets. The more repeated elements in two sets, the higher their Jaccard coefficient, and the greater the similarity. Formula (1) is the formula for calculating the similarity between the target mobile cabin case and historical cases.
[0043]
[0044] The “hull assembly” is the root node, with a depth of 0, while the depth of the next level node is 1, and so on. The weight of the node is calculated using formula (2).
[0045]
[0046] by Figure 5 For example, to calculate the similarity between shelter 1 and shelter 2, we can obtain the result from formula (2). Then, from formula (1), the similarity between the two can be obtained as sim. rel (Fangcang 1, Fangcang 2) = 0.477, and formula (3) is the specific calculation process.
[0047]
[0048] (4) Calculate C T Compared with historical case C H Attribute similarity;
[0049] Based on the nearest neighbor retrieval algorithm, calculating the attribute similarity of the makeshift hospital design cases is equivalent to calculating the attribute spatial distance between nodes. In the knowledge graph of makeshift hospital design cases, different types of attributes of each node require corresponding attribute similarity calculation methods. Assume node N... T and N H For nodes on the same path in the target case modular housing and the historical case modular housing, then N T With N H The attribute similarity is calculated using formula (4).
[0050] sim(N T NH ) = 1 - Dist(N T ,N H )(4)
[0051] where Dist(N T ,N H ) is the attribute space distance between nodes N T and N H .
[0052] (4.1) Numeric attribute
[0053] For a numeric attribute, formula (5) can be used to compute the attribute similarity between the attribute T T of C att and the attribute H H of C att under the same relationship path node.
[0054]
[0055] where T att , H att ∈ [att min , att max ], att max and att min are the value range of the numeric attribute.
[0056] (4.2) Range attribute
[0057] For a range attribute, the range of a certain attribute of a node in C T is [T att1 , T att2 ], and the range of the same attribute of a node in C H is [H att1 , H att2 ], the similarity of the range attribute between the two nodes under the same relationship path can be represented as formula (6).
[0058]
[0059] (4.3) Text attribute
[0060] In addition to the specific numerical properties and range numerical properties, some nodes in the shelter design case knowledge graph also contain natural language type text properties. These text properties are mostly customer's note requirements in the order, which is an important factor that must be considered in the design process to improve customer satisfaction. The text properties of each node in the shelter design case knowledge graph have good structure and clear expression, and the length of the text is relatively short. Therefore, for these properties, the vector space model (VSM) can be used to calculate the similarity. This model represents the text object as a high-dimensional vector and calculates the vector space distance between nodes to measure their similarity. VSM is a text similarity calculation method that vectorizes text content, is widely used, and has the advantages of fast calculation speed and intuitive understanding. The basic idea of this method is to represent the text content as a vector form, and measure the similarity between texts by calculating the distance in the vector space. The cosine similarity function is a commonly used vector space distance calculation method, and the specific formula is:
[0061]
[0062] In the formula, a i and b i refer to the elements in the n-dimensional space vector corresponding to the text T att and H att after segmentation, and k represents the weight coefficient of each element.
[0063] The present application takes into account the fact that the weight of each element in the space vector is different, and combines the characteristics of the shelter design case to assign different weight information to the text properties of each node in the knowledge graph when performing segmentation. According to the actual situation and demand characteristics, when performing segmentation on the text properties of each node, a feature word library is established and the feature word elements in the library are classified, and different weight coefficients k are assigned, as shown in Table 1.
[0064] Table 1 Feature word category and weight distribution
[0065]
[0066] When calculating the similarity of the text properties of C T and C H under the same relationship path, the similarity value of the text properties of the two is equal to the sum of the maximum value of the similarity of each text in the C T node to the corresponding text properties in the C H node divided by the maximum value of the number of text properties of the two, and the calculation formula is as follows:
[0067]
[0068] In the formula, j = 1, …, H NT N and H N C respectively T and C H The number of text attributes of nodes under the same relational path.
[0069] For example, C T The example "Right Wall Assembly" has two text attribute requirements {T att1 = "Install a set of ventilation louvers in a suitable location", T att2 =“Set up a power supply box at the bottom rear”}, calculate using formula (7) and Figure 3 C in H The similarity of each text attribute of the "Right Wall Assembly" instance is calculated as: sim(T att1 H att1 ) = 0.118, sim(T att1 H att2 ) = 0.216, sim(T) att1 H att3 ) = 0.824, take 0.824 as T att1 With C H The similarity of attributes for the "right wall assembly" is calculated similarly. att2 Its corresponding attribute similarity sim(T) att2 H att1 ) = 0.392, sim(T att2 H att2 ) = 0.118, sim(T att2 H att3 ) = 0.392, take 0.392 as T att2 With C H Attribute similarity of "right wall assembly". Max(T) N H N =3, and the text attribute similarity between the two is 0.405 according to formula (8).
[0070] When calculating the similarity of attributes of various nodes in the knowledge graph of cabin design cases, different attributes of a node have varying degrees of influence on the overall node attribute similarity. Therefore, it is necessary to assign weights to the similarities of different attributes in each node when calculating the overall node attribute similarity. Taking into account both subjective and objective factors, this paper adopts the Analytic Hierarchy Process (AHP) combined with the similarity deviation weighting method to perform combined weight allocation on the attributes of nodes in the knowledge graph of cabin design cases.
[0071] The basic principle of the AHP weighting method is to quantify the weights of multiple factors in decision-making through expert evaluation, thereby enabling decision-making on complex problems. The node-based AHP hierarchical architecture based on the knowledge graph of modular shelter design cases is as follows: Figure 7Example.
[0072] According to the experience of senior designers and experts in the enterprise Figure 7 The judgment matrix A=(a ij ) n×n is constructed according to n attributes of each node in the knowledge graph max The characteristic equation AW=λ max W is calculated, and the maximum eigenvalue λ H and the eigenvector W corresponding to W are calculated. After normalization of W, the subjective weight vector W is obtained. At the same time, the consistency ratio CR of A is tested according to formula (9). If the condition is not met, A is modified.
[0073]
[0074] The objective weight reflects the objective contribution of each attribute information of the node to the overall node attribute similarity decision result. Let N H1 ={N H2 ,N Hm ,…,N T} be a node N H in the design target shelter knowledge graph, and N T be the node set under the same relationship path in the knowledge graph. The j-th attribute similarity of N Hi and N ij is defined as s T , and the attribute similarity matrix S=(s Hi ) of N ij facing N m×n is established. According to the similarity deviation method, the objective weight vector of each attribute of the node is obtained where is calculated by formula (10).
[0075]
[0076] Considering subjective experience and attribute information of the node, W obj and W sub are combined to obtain the attribute weight distribution vector W=[w1,w2,...,w n ] T in the same relationship path node, and w i is calculated by formula (11).
[0077]
[0078] (5) Calculate the overall case similarity of C T and historical cases C H ;
[0079] After the relationship similarity and attribute similarity of each node of the shelter case based on the design case knowledge graph are calculated, the two similarities obtained by different categories of nodes need to be weighted according to the importance of the overall similarity of the shelter design case. In this paper, expert assignment method is used to weight the attribute similarity of different categories of nodes. The weight L of different types of nodes is allocated as shown in Table 2.
[0080] Table 2 Weight allocation of node type and attribute similarity
[0081]
[0082] The overall attribute similarity sim of the shelter based on the design case knowledge graph is obtained by combining the weight L of different types of nodes. att (C T ,C H ) is calculated by the formula:
[0083]
[0084] In the formula, sim(T att ,H att ) represents the attribute similarity of nodes under two same relationship paths, and D i represents the number of all non-repeated nodes with depth i in the two knowledge graphs.
[0085] For the target design case C T and the historical design case C H , sim(C T ,C H ) is used to represent the overall similarity of the two cases, and sim(C T ,C H ) ∈ (0, 1). The closer the similarity is to 1, the higher the similarity of the two cases is, and vice versa. sim(C T ,C H ) is determined by formula (13).
[0086] sim(C T ,C H ) = αsim att (C T ,C H ) + (1-α)sim rel (C T ,C H ) (13)
[0087] In the formula, sim att (C T ,C H ) represents the case attribute similarity, and sim rel (C T,C H ) represents the case relationship similarity, α represents the weight of attribute similarity, and (1-α) represents the weight of relationship similarity. Next, the calculation methods of sim att (C T ,C H ) and sim rel (C T ,C H ) are described.
[0088] After the calculation of the overall attribute similarity and relationship similarity of the shelter, α=0.8 is taken to balance the weights of the two, and the similarity of the overall design case of the shelter is calculated by formula (12).
[0089] (6) Repeat steps (3) to (5) until all shelter instances in the historical case knowledge graph are calculated for similarity;
[0090] The similarity of the design target shelter case and all historical shelter design cases is calculated in turn, so that the search results are more comprehensive and accurate, and the correctness and effectiveness of the similar case search are ensured.
[0091] (7) Sort all case similarities in descending order, and take the top N cases as the search results.
[0092] Sort all case similarities in descending order, and the top N cases with the highest similarity values are the search results, from which the enterprise designers can select the optimal similar case for reuse and modification to improve design efficiency.
Claims
1. A knowledge graph-based shelter design case retrieval method, characterized in that, Comprising the following steps: (1) Constructing a historical case knowledge graph for shelter products; (2) Establishing the design target shelter case C T Knowledge graph; (3) Calculate C T Similarity of relationship with historical case C H as shown in the following formula: The "shelter body assembly" is the root node, with a depth of Depth=0, while the depth of the next level node is Depth=1, and so on; Jaccard(·) is the Jaccard similarity coefficient; the weight ω of the node is calculated according to the following formula: (4) Calculate C T Similarity of attributes to historical cases C H includes: Based on the nearest neighbor search algorithm, the attribute similarity of the shelter design case is the attribute space distance between the nodes, assuming that the nodes N T and N H are the nodes under the same relationship path in the target design case shelter and the historical design case shelter, then the attribute similarity of N T and N H is calculated by the following formula: sim(N T ,N H ) = 1 - Dist(N T ,N H ) where Dist(N T ,N H ) is the attribute space distance between nodes N T and N H . The weight L of the different types of nodes is combined to obtain the overall attribute similarity sim of the shelter based on the design case knowledge graph att (C T ,C H ) is: where sim(T att ,H att ) represents the attribute similarity of nodes in two same relationship paths, D i represents the number of all non-repeated nodes with depth i in two knowledge graphs. (5) Calculate C T The overall case similarity with historical cases C H includes: For the target design case C T and the historical design case C H sim(C T ,C H ) is used to represent the overall similarity of both, sim(C T ,C H ) is determined by the following equation: sim(C T ,C H ) = α sim att (C T ,C H ) + (1 - α) sim rel (C T ,C H ) (13) wherein sim att (C T ,C H ) represents the case attribute similarity, sim rel (C T ,C H ) represents the case relation similarity, and a represents the weight of the attribute similarity and (1-a) represents the weight of the relation similarity. (6) Repeat steps (3) to (5) until all shelter instances in the historical case knowledge graph are calculated for similarity; (7) Sort the similarity of all cases in descending order, and take the top N cases as the search results.
2. The method according to claim 1, wherein, In step (1), the historical case knowledge graph for shelter products is constructed in a top-down manner, and the neo4j graph database is used to represent the knowledge graph.
3. The method according to claim 1, wherein, In the step (1), the ontology of the knowledge graph is described by triplets defined by O={C, A C ,R}, where C represents a concept, A C represents a set of concept attributes, and R represents a set of relationship between concepts.
4. The method according to claim 1, wherein, In step (1), the knowledge sources used to construct the historical case knowledge graph for shelter products include enterprise historical design orders, delivered design cases, product 3D models and drawings, and enterprise standard libraries.
5. The method according to claim 1, wherein, In the step (2), a design target shelter case C is established T The knowledge graph adopts the knowledge source as the demand information of the new order technical agreement.
6. The method according to claim 1, wherein, In the step (5), the C is calculated T The historical case C H The method of the overall case similarity is specifically as follows: the expert assignment method is used to perform weight distribution on the attribute similarity of nodes of different categories, and the relationship similarity and the attribute similarity are comprehensively considered to obtain the final overall similarity of the shelter design case.
7. The method according to claim 1, wherein, The attributes of each node in the knowledge graph include specific numerical attributes, numerical range attributes, and text attributes.
8. The method according to claim 6, wherein, The types of nodes include shelter body assembly, wall panel, main frame, door and window, and others.