Case-based Reasoning of Damaged Ancient Buildings based on Ontology

. At present, China has a large number of ancient buildings, and correspondingly, it also faces many problems. Staff of different professions have inconsistent perceptions of ancient buildings, resulting in inability to interact with information. In addition, the ancient architecture case did not carry out efficient reuse of knowledge. Therefore, this article applies ontology to the field of ancient architecture, and proposes the knowledge expression of ancient architecture based on ontology. And SWRL is used to describe the ancient building rules. Secondly, through the application of case-reasoning technology, the reuse of case knowledge of ancient architecture is realized. Ontology-based case representation can provide a unified definition of ancient building knowledge for different participants and lay the foundation for information interaction. Case-based reasoning provides an implementation method for knowledge reuse of ancient building damage cases.


Introduction
The life cycle of historical building refers to the process from when the historic building enters people's protect vision until it disintegrates and dies for various reasons. During this period, the protection of historical buildings involved multiple disciplines and specialties, and activities related to historic buildings produced a large amount of heterogeneous and scattered information. Historic Building Information Model (HBIM) [1]is an extension of BIM technology in the field of historical building heritage protection. It exerts strong digital technology advantages, and many application cases benefit from it [2] [3].However, at present, HBIM technology focuses on the expression of geometric features of ancient buildings. As a result, digital models of ancient buildings produced by HBIM cannot reflect the non-geometric characteristics of ancient architectural heritage [4].
Ontology, as a specification for the conceptualization and formalization of shared knowledge [5],is suitable for multi-domain knowledge expression, tacit knowledge mining and management [6].Cacciotti [7]combined the ontology with the diagnostic information of historical buildings, and carried out semantic expressions, which provided effective technical support for diagnosing the damage of historical buildings; Acierno [8]integrates ontology into the historical building heritage protection process to support knowledge representation and management throughout the process. Davide [4] focused on the semantic expression of historical buildings, proposed the use of semantic Web technology to describe the non-geometric characteristics of historical buildings, and established a BIM semantic knowledge base. This research improves the semantic expression ability of HBIM.
However, due to the differences of architectural styles between the eastern and western, the ontology study of western historical buildings cannot solve the semantic expression of Chinese historical buildings. In China, Different from western stone buildings, most Chinese historical buildings, namely, Chinese ancient buildings use wooden structures. It is important that the design and construction of ancient buildings are carried out according to strict rules, reflecting the ancient Chinese social hierarchy.
In addition, In the current repair works of ancient buildings, professionals use their own expertise and past work experience to repair and restore various damages to ancient buildings. However, The protection engineering of ancient buildings is extremely professional. Professional knowledge and work experience can only exist in the brains of individual professionals, and cannot guide other ancient building damage cases on a large scale and efficiently. Therefore, It is important for the repair of ancient buildings that how to use the existing ancient building cases for case reasoning and case reuse.

Methed
The restoration is an important part of the life cycle of historical building, which determines whether the historical building can exist in a better state. Therefore, this article takes Chinese ancient buildings damage as the research theme, analyzes the concepts, attributes, relationships of the cases, and analyzes the rules followed in the repair of Chinese ancient buildings. The result is the establishment of the ontology of the Chinese ancient buildings damage case.Case-based reasoning (CBR) is the implementation of knowledge reuse. This article will study the reasoning of ancient buildings damage based on ontology. Based on the historical building case retrieval and case matching, it will realize the knowledge reuse of ancient buildings damage repair case.

Building Damage Ontology
The damage of ancient buildings is an objective fact, which corresponds to the object of damage. The damage object is an essential and direct manifestation of the damage phenomenon in ancient buildings. For example, cracking damage is manifested as cracks, and moth damage is manifested as holes. According to the possible consequences and severity of the damage, the ancient building damage is classified as structural damage, component damage and decorative damage.
The severity degree of damaged objects is mainly determined by their own damage feature. Damage feature are quantifiable performance characteristics of damaged objects in damaged components. For example, the damage feature of cracks case are the length, width and depth of crack.
Because the damage feature reflect the degree of damage to ancient buildings, it is an important indicator for making repair decisions. Due to the different causes of injury, each type of injury object has different characteristics. Dividing the degree of damage through different numerical intervals can define the threshold of the bulding damage characteristics. When the damage feature value meets a corresponding threshold, the feature object can be divided into a specific damage degree interval, thereby matching the corresponding maintenance method. Based on the above analysis of the damage information, this article proposes the ontology framework of damage information of Chinese ancient buildings, as shown in Figure 1. The subject of the ancient building damage case is the damaged object, and its corresponding instance is also connected to the object properties and data properties. This article uses the crack case in the middle of the Yan column as an example for poperties analysis. As can be seen from Figure 2, the core of the case is cracking damage. In the first circle, the object properties are connected to the crack, the purpose of which is to limit the definition of damage from a conceptual level. In the second circle, the properties connected to the object attributes are data restrictions on the object, that is, quantitative restrictions on the concepts involved in cracking.

Expression of Damage Rules Based on SWRL Language
According to the performance of the ancient building damage case, we set the threshold of the relevant attribute characteristic value, and then determine the degree of damage treatment, as a result, match the corresponding repair method.In this paper, by determining the damage object or subject and quantifying the parameters of the damage case, the final result is to achieve SWRL expression.
Taking the repair of cracks on the Yan column of ancient buildings as an example, it is taken from Article 6.6.1 of the <Code> [9]: the case of dry shrinkage cracks of wooden columns, if the depth does not exceed 1/3 of the diameter of the column, and if the width is not greater than 3mm, you can use putty to wipe the solid during YouShi [10] or DuanBai [10] process.Through analysis of the rules, we can obtain the regular composition of cracks and damages in the YanColumn of ancient buildings, as shown in the Table1.

DamageBady
Timber Column DamageObject Cracking Boundary When the crack depth does not exceed 1/3 of the column diameter and the crack width ≤ 3 .

RepairMethod
Use the putty during the YouShi decoration orDuanBai According to the above rules framework of cracking repairing, SWRL language can be used to express the cracking repairing rules of ancient building columns. Anc_YanColumn

Two-stage case retrieval
The ontology-based case of ancient building damage is composed of a large number of elements such as concepts, relationships, rules. Among them, the characteristic information of the ancient building damage is expressed through properties forms, such as case hasDamageObject cracking,case hasDamageBody YanColumn.The properties of ancient building damage cases are divided into object properties and data properties, both of which restrict the objects in the case in different ways. From the perspective of case constraints, object properties and data properties express the qualitative and quantitative constraints of the case, respectively. Therefore, this article proposes a two-stage case retrieval method based on ontology. In the first stage, we use the connection between concepts in the ontology, and then use SPARQL language to express the qualitative constraints of the ontology object. Through preliminary retrieval, we identify cases that meet specific conditions. The second stage is to match the target case with a case based on quantitative constraints, and finally determine the ideal reference case.

Case retrieval based on SPARQL
At the beginning of case retrieval, we perform information analysis on the new case. The first step is to determine the case subject category and other background information, and determine the retrieval conditions based on the results. Then we use SPARQL language to write the retrieval statement and enter it into SPARQL query for retrieval.Then we can identify the cases that meet the search conditions. The number of cases may not be unique,and there may even be multiple cases. Too many retrieved cases will reduce the case matching efficiency, which is not conducive to the next stage. We can restrict the search conditions again to remove cases that are not highly relevant.

Case matching based on similarity
After the first stage of case retrieval, we screened the cases according to the object attribute constraints to obtain some eligible cases. The differences between these cases and target cases are reflected in the data properties.Therefore, we obtain the similarity between the two according to the attribute calculation method of the ancient building damage case data. The data types of the numerical attributes of ancient building damage cases mainly include numerical, Boolean, and enum,etc.
The numerical property in the case of ancient building damage is represented by the value A, and the value range of A is { , } . Then, the similarity calculation formula for the property a between the comparison case and the target case is In the case of ancient building damage, there are some properties b. Their property value type is Boolean and the result is "ture" or "false". Then, the similarity calculation formula for properties b between the comparison case and the target case is In the case of ancient building damage, some of the properties c value types are enumerated, that is, the possible values of the value are a set of sets{ 1 , 2 , … , }. We map this set into a set of arrays, and can get the corresponding Ordered array collection { 1 , 2 , … , } .For example, the damage position property of the crack damage is an enumerated value property, and the value set is {Column top, Column body, Column foot}, and we map it to an ordered array {1, 2, 3}. Therefore, the comparison formula for the similarity of attribute c between the comparison case and the target case is is the cardinal number of the ordered array [ar].
After calculating the similarity simt of each type of properties, we calculate the overall similarity of the case according to the weight value wt of each property. The overall similarity of a case is a weighted sum of the similarities of properties, and its calculation formula is ( , ) = ∑ 1≤ ≤

Application
The main building of a certain ChengHuang Temple is of WuDian [10] type , with a blue glazed tile on the roof, seven room in the horizontal direction and five room in the Vertical. The main space of the ancient building occupies three room in the Vertical direction, and the structure type is QiJiaLiuChuanFu [10]. We carried out manual surveying and mapping of this ancient building, and then took the ancient building damage of the main hall as an example, and used protégé5.0 software to establish the damaged ontology of the ancient building.
In the representation of specific cases, we divide the information according to the above-mentioned problem background, problem occurrence, method description and other aspects, and then add them to the ontology by instantiation. The final result is to realize the ontologybased case representation. As shown in Figure 3. Take the cracking of an Yan column in Chenghuang Temple as an example. First, we define the type of the case as a damage case, and classify the damage as a type of damage based on the damage to the building.In the object properties,we show that the ancient building where the case is located is Chenghuang Temple, and its building type is WuDian.
The damaged object in the case is individual of the damage in the ancient building. It is marked as DA1010102 by the coding method of the ancient building, and its corresponding repair process is marked as CA04010102. The location of the damage is on the wall space (BA8020101). The damage object in the case is the YanColumn (BA1010101).After the above actions, the damaged cases of ancient buildings are stored in the case library in the form of individual.
Assume that the target case is cracking damage to the YanColumn of the DanYanWuDian [10]. The crack length is 532mm, width 22mm, and depth 96mm. Define search conditions based on the object attributes of ancient building damage cases.The search results are shown in Figure 4. The damaged case case1 meets the requirements of the target case.By querying the damage characteristics of case1, it can be concluded that the crack length of case1 is 372mm, width is 13mm, depth is 45mm, and the damage location is at the top of the column.Assume that the weight of the four eigenvalues is 0.25, 0.25, 0.25, 0.25. Then according to the case similarity formula, the similarity between the target case and case1 is ( , ) = ∑ 1≤ ≤ = 0.735

Conclusion
This article proposes the representation of ancient building damage cases based on ontology. It can be found that the ancient building damage cases can be decomposed and logically linked through information. It is well combined with the ontology to achieve case expression. Through case-based reasoning, past engineering experience can be used efficiently, and at the same time, invisible knowledge about ancient building repairs can be discovered.However, in the reasoning of the ancient building damage cases based on ontology, the properties weight value of the ancient building is not clear, and there is no specific regulation for the properties value range in the damage cases.Therefore, the next step is to carefully divide the attributes of ancient building damage cases and reasonably determine the attribute value range.