In this article, we evaluate the efficiency and performance of two clustering algorithms: (Agglomerative Hierarchical Clustering) and . We are aware that there are various linkage options and distance measures that influence the clustering results. We assess the quality of clustering using the Davies–Bouldin and Dunn cluster validity indexes. The main contribution of this research is to verify whether the quality of clusters without outliers is higher than those with outliers in the data. To do this, we compare and analyze outlier detection algorithms depending on the applied clustering algorithm. In our research, we use and compare the (Local Outlier Factor) and (Connectivity-based Outlier Factor) algorithms for detecting outliers before and after removing , , and of outliers. Next, we analyze how the quality of clustering has improved. In the experiments, three real data sets were used with a different number of instances.
This paper presents a novel approach to optimize inference in rule-based knowledge systems by introducing a clustering mechanism for rule organization. Rules are clustered using K-Means or Agglomerative Hierarchical Clustering (AHC) algorithms, with different distance measures and clustering strategies. We propose and evaluate four inference strategies based on different group representation methods (mean or median) and rule activation strategies (activation of one or all matching rules). Experimental studies on real knowledge bases show that clustering significantly improves inference performance while maintaining a satisfied inference success rate.