# A Knowledge-Based Service Composition Algorithm with Better QoS in Semantic Overlay

Authors: Huijun Dai; Hua Qu; Jihong Zhao
Journal: Mathematical Problems in Engineering
 (2015)

---

## Abstract

A semantic overlay network (SON) is a visual framework clustered under similar metaknowledge units such as ontologies, algorithms, and rule engines. Knowledge-based service composition (KC) has become a prominent aspect of building new and creative composed service through a combination of semantically similar information at the knowledge level. In this study, a promising approach to construct a standard knowledge model is developed to utilize the progress of KC. To evaluate and optimize the composition, we define the quantity of service (QoS) regarding user requirements in the KC instance, and a KC instance path with better QoS is found in the model using the KC algorithm. Simulation results prove that our approach has a tradeoff between efficiency and equality.


---

## Body

## 1. Introduction

Knowledge-based applications are organized according to semantic relevance and context in semantic overlay network (SON) with the purpose of retrieving the service in a large-scale intelligent information system [1]. In a SON, many groups of nodes with similar content or documents compose reusable software service into an integrated heterogeneous virtual platform for sharing information [2]. Content-addressable network (CAN) is also essentially a type of SON via content cached at nodes based on content routing for locating content [3, 4]. With the accumulation of massive amounts of service or application from many different domains (e.g., scientific research and personal and corporate communications or interactions [5]) for specific service supplying, the SON aims to thoroughly bind such individual and distributed services into workflow systems that support different kinds of knowledge sharing [6]. The approach of composition must support the evaluation of quality of service (QoS) to optimize the composition effect of reusable software. Therefore, the purpose of knowledge-based composition (KC) is not different from that of traditional service composition because the former can reuse the more units (e.g., databases, algorithms, and tools from different fields which could also be regarded as individual service [7]) in semantic level. While, knowledge-based service composition makes information sharing more dynamic, flexible, and scalable.Therefore, KC is intended to share a wider range of information or services scattered across numerous distributed nodes. There are multiple QoS attributes that users pay attention to including price, reputation, reliability, and delay [8]. Although previous studies related to better QoS have contributed significantly to service composition in semantic web, most of them are still limited to traditional semantic web service and do not extend to overlay based on knowledge. This study aims to find a novel way to compose service based on knowledge sharing with better QoS in an SON.The rest of this paper is organized as follows. The approach is formally modeled and related studies are reviewed in Section2. Section 3 presents the adopted KC model in a SON. The exhaustive algorithm process is detailed and implemented in Section 4. In Section 5, the algorithm is examined and evaluated by simulation. The conclusion is provided in Section 6.


## 2. Related Works

The massive amounts of distributed service or units such as those available from digital libraries and web-accessible text databases motivate researchers to work toward efficient service management in highly distributed environments [9]. By correlating these isolated islands of information, individuals can gain new insights, discover new relationships, and produce more knowledge [10]. A large body of work on knowledge-based service composition in SONs has been generated [6, 9, 11–13]. Certain approaches use algebra in composing ontologies that represent the terminologies from distinct, typically autonomous domains to compose knowledge [14, 15]. Usually, the links of ontology among the domains are called intersections [16].Knowledge-based service composition is different from knowledge discovery [17] or knowledge creation [18] because that the former enable users to collectively create, share, browse, and query their own individual knowledge [13, 19, 20]. Some recommendations or recommender systems compose a set of services into data processing logic which combine the service according to user preferences or its execution environment [15].Significant research has focused on optimizing the QoS of service composition [21, 22]. Existing approaches often show a tradeoff in every aspect to gain balanced performance [23, 24]. In fact, KC can be implemented and utilized in e-ScienceNet [25], e-Flow with customized services [26]. Cross-enterprise collaboration has emerged using automatic business composition in the global market [27]. In the scientific research, medical information, and collaborative manufacturing, the creative approach of the KC for a SON is also presented [28] for searching service-oriented knowledge utilities [29]. The process of KC should include information retrieval, knowledge representation, and databases, as well as exploiting pieces of knowledge from the multitude of heterogeneous sources available. In [30], the candidates with the same functionality are organized as a class and ACO4WS is used to test the feasibility and soundness of the approach.Based on the aforementioned study, such a conclusion can be reached. Firstly, SONs have received growing attention as a scalable and distributed platform for knowledge-sharing applications. Then, KC dynamically combines two or more basic services (called units) into potentially complex value-added knowledge-based workflow to fulfill the functional requirements of the user. Finally, the key to KC is to choose a scheme with better QoS under the QoS constraints.


## 3. Problem Formulation

In knowledge repository, a unit (subservice) can be expressed asK
=
I
,
O
,
Q, I is the input set, O represents the output set, and Q is the QoS. The QoS of a KC consists of the following parameters: {
Q
1
,
Q
2
,
…
,
Q
n
}.The QoS attributesQ
i are availability, cost, time overhead, and so on. The model can be classified into subservice and compositional service. The subservice is a single unit cached in SON just like the one shown in Figure 1. The model enables the incorporation of various composition approaches by starting from the input of the first unit, traversing through the chosen unit, and ending at the output of the final unit in different knowledge repositories.Figure 1
Units in SON.N different but semantically related subservice constructs a body of compositional service from M SONs, and KC involves mapping from the composite template to instantiated knowledge. The previous subservice output should be consistent with the next subservice input at the knowledge level. Each subservice in an SON has a few candidates called units, which are those that have the same or similar meaning or function. In Figure 1, points 1, 2, and 3 are candidates in SON1. The points and links between them can form an indirect graph from source to target. A weighted link between points represents the QoS of discovering or retrieving the next node. The QoS labeled in links merges the different QoS attributes of nodes using a cost function. The KC with different QoS indicates different paths in the knowledge graph. So, we can get the following.The QoS of KC indicates the overall QoS of the instantiated knowledge path, which can be calculated as follows:Q
com
=
∑
i
=
1
n
Q
i, where Q
i represents the merged QoS of nodes and links. For example, the availability and time of the overall QoS of composition can be expressed as
(1)
ln
⁡
1
A
com
=
∑
i
=
1
n
ln
⁡
1
A
node
(
i
)
+
∑
j
=
1
n
-
1
ln
⁡
1
A
link
(
j
)
,
Time
com
=
∑
i
=
1
n
RTT
i
+
∑
j
=
1
n
-
1
Delay
j
.
A
node
(
i
) refers to the availability of node i, A
link
(
j
) stands for the availability of the conjoint link j, and RTT
i and Delay
j represent the round trip time of node and links’ delay. Given the semantic similarity of the nodes, their QoS in the same SONs can be considered as equal, and the QoS of the links are not equal because of the different locations. Because the QoS of KC path can translate into the additive metrics, the best QoS of KC also indicates the smallest QoS of links in the knowledge graph.The KC progress can be formulated based on the knowledge graph model shown in Figure2 which is converted from Figure 1. In Figure 2, the QoS has been marked in links.Figure 2
Time curves with metaknowledge.


## 4. KC Approach with Better QoS

The target of KC is to find an optimal path in the graph by comparing the total QoS as the cost function. Instead of searching the entire SON, the KC algorithm involves three basic steps: probing and collecting the information; path; backwording.


### 4.1. An Instance

There is an instance to show how this approach works. In probing, matrices of different nodes in neighbor SONs are constructed filling with the QoS values of the links. Because the knowledge model graph is indirect, the constructing matrix is symmetrical.During the probing, the constructing matrixes are as in Tables1, 2, 3, and 4.Table 1
Adjacent matrix 1.
S
1
2
3
S
0
4
2
6
1
0
0
0
2
0
0
3
0Table 2
Adjacent matrix 2.
1
2
3
4
5
1
0
0
0
8
12
2
0
0
7
9
3
0
13
4
4
0
0
5
0Table 3
Adjacent matrix 3.
4
5
6
7
8
4
0
0
9
7
7
5
0
10
5
3
6
0
0
0
7
0
0
8
0Table 4
Adjacent matrix 4.
6
7
8
9
10
6
0
0
0
4
7
7
0
0
10
8
8
0
9
6
9
0
0
10
0The searching results are saved with link-table.During probing and constructing, we can find an initial path. In this example, from the node ofS, the next node of 2 should be chosen. Then from the node 2, the node of 4 should be chosen. Thus, the node sequence is S
→
2
→
4
→
7
→
10
→
T, in which the QoS of the total path is the sum of each link’s QoS indicated as C
a
l
_
s
u
m. Now, the C
a
l
_
s
u
m is “24” in this example.During the path, the minimum is found and chosen from the second matrix of Table2. The nodes with minimum link are located, then search the shortest link starting from the nodes. The searching include forward and backward until a path was been chosen.The backwording progress will traverse all the matrixes and give out different paths with better QoS in their SON. Then, there areM (the number of SON) paths with their nodes and QoS are saved and compared. The final C
a
l
_
s
u
m of smallest QoS is 19, and the node sequence is S
→
3
→
5
→
8
→
10
→
T.In this example, the KC instance is found in which the path with smaller QoS is obtained through a simple linear search algorithm. The time complexity does not depend on the number of SONs (matrixes). This approach may not find a path with best QoS because of the local optimization. But it will get a tradeoff between efficiency and equality. Although the nodes in knowledge model graph continually grow with the number of metaknowledge units, the time complexity of this approach will not soar but increase linearly.


## 4.1. An Instance

There is an instance to show how this approach works. In probing, matrices of different nodes in neighbor SONs are constructed filling with the QoS values of the links. Because the knowledge model graph is indirect, the constructing matrix is symmetrical.During the probing, the constructing matrixes are as in Tables1, 2, 3, and 4.Table 1
Adjacent matrix 1.
S
1
2
3
S
0
4
2
6
1
0
0
0
2
0
0
3
0Table 2
Adjacent matrix 2.
1
2
3
4
5
1
0
0
0
8
12
2
0
0
7
9
3
0
13
4
4
0
0
5
0Table 3
Adjacent matrix 3.
4
5
6
7
8
4
0
0
9
7
7
5
0
10
5
3
6
0
0
0
7
0
0
8
0Table 4
Adjacent matrix 4.
6
7
8
9
10
6
0
0
0
4
7
7
0
0
10
8
8
0
9
6
9
0
0
10
0The searching results are saved with link-table.During probing and constructing, we can find an initial path. In this example, from the node ofS, the next node of 2 should be chosen. Then from the node 2, the node of 4 should be chosen. Thus, the node sequence is S
→
2
→
4
→
7
→
10
→
T, in which the QoS of the total path is the sum of each link’s QoS indicated as C
a
l
_
s
u
m. Now, the C
a
l
_
s
u
m is “24” in this example.During the path, the minimum is found and chosen from the second matrix of Table2. The nodes with minimum link are located, then search the shortest link starting from the nodes. The searching include forward and backward until a path was been chosen.The backwording progress will traverse all the matrixes and give out different paths with better QoS in their SON. Then, there areM (the number of SON) paths with their nodes and QoS are saved and compared. The final C
a
l
_
s
u
m of smallest QoS is 19, and the node sequence is S
→
3
→
5
→
8
→
10
→
T.In this example, the KC instance is found in which the path with smaller QoS is obtained through a simple linear search algorithm. The time complexity does not depend on the number of SONs (matrixes). This approach may not find a path with best QoS because of the local optimization. But it will get a tradeoff between efficiency and equality. Although the nodes in knowledge model graph continually grow with the number of metaknowledge units, the time complexity of this approach will not soar but increase linearly.


## 5. Simulation and Analysis

### 5.1. Simulation Environment

To evaluate the performance of proposed KC algorithms with better QoS, we use them in the specified application. We suppose that the application has certain user requirements as input and the expected results as the output. The number of metaknowledge units spreading across different specific P2P systems is less than 20 (including source and target), and each metaknowledge has a few candidates with the same meaning, input, and output. Then, the workflow graph of this application can be formulated as shown in Figure2, where N, (
N
<
20
) groups of nodes are shown. The underlying physical topology is generated by GT-ITM using n-node transit-stub models. To simulate the performance variation in the real world and the initial availability of each node, we distribute the QoS of each link uniformly in a certain range.To verify the effectiveness of the proposed approach (KC), we compare it with two types of algorithms: one is the shortest path algorithm with optimal results and the other is the heuristic algorithm (ant colony) with local optimal results in service composition. We have attempted to provide the same conditions (e.g., interface and input data) for three kinds of algorithms.


### 5.2. Simulation Results

With regard to the optimal algorithm, Dijkstra and ant colony algorithms require more time and calculation to obtain the solution. Therefore, from the perspective of theoretical analysis, the time complexity of the DijkstraΘ
(
N
2
) and the time complexity of traditional ant colony algorithms were greater than that of our approach. These two solutions employ the global optimization approach but do not show promising running speed. The time complexity of the KC algorithm increases linearly.For the sake of a number of candidates in many SONs, which continuously increase along with the growth of the SON, by taking more storage space in computing service (numerous matrices with the QoS of links), the approach obviously has quick convergence speed. However, the KC algorithm is not optimal. In the worst case, the iterations would reachΘ
(
N
). Three simulation time curves of those algorithms which would vary with the numbers of metaknowledge units or the candidates are shown in Figures 2 and 3. The number of metaknowledge units influences our approach, whereas the number of the candidates influences the two other approaches.Figure 3
Time curves with candidates.The metric for evaluating the KC approach performance is the QoS rate. This rate is defined as(2)
QoS
rate
=
numbers
of
satisfied
instances
numbers
of
required
.For this target, our approach has a lower QoS rate just like what is shown in Figure4. This figure shows that our QoS rate is less than that of the other algorithms, particularly when a number of candidates exist. Comparing with other algorithms, our approach simplified the composition progress at the cost of QoS rate.Figure 4
QoS rate of three algorithms.We also implement another two common heuristic algorithms used in service composition for comparison. One is ACO4WS [30], which is based on a general knowledge model, and the other is mixed integer linear programming, an algorithm for semiautomatic merging and alignment ontologies. Both algorithms are applicable to a wide range of knowledge representation and ontology development systems. Three algorithms are based on a different model, but the similarity is that all of them map the function modules into node graphs, and all focus on the matrix of QoS. Three simulation time curves of those algorithms varied with the candidates, as shown in Figure 5.Figure 5
QoS rate with three local optimization methods.The experimental results indicate that the QoS rate of each algorithm decreases slightly with the increase of function modules because finding a path in a more complex graph is difficult. However, the QoS rate of KC has a higher value than that of the two other algorithms because KC uses a simple principle to measure QoS (smaller is better), which can fulfill most of the QoS attributes.


## 5.1. Simulation Environment

To evaluate the performance of proposed KC algorithms with better QoS, we use them in the specified application. We suppose that the application has certain user requirements as input and the expected results as the output. The number of metaknowledge units spreading across different specific P2P systems is less than 20 (including source and target), and each metaknowledge has a few candidates with the same meaning, input, and output. Then, the workflow graph of this application can be formulated as shown in Figure2, where N, (
N
<
20
) groups of nodes are shown. The underlying physical topology is generated by GT-ITM using n-node transit-stub models. To simulate the performance variation in the real world and the initial availability of each node, we distribute the QoS of each link uniformly in a certain range.To verify the effectiveness of the proposed approach (KC), we compare it with two types of algorithms: one is the shortest path algorithm with optimal results and the other is the heuristic algorithm (ant colony) with local optimal results in service composition. We have attempted to provide the same conditions (e.g., interface and input data) for three kinds of algorithms.


## 5.2. Simulation Results

With regard to the optimal algorithm, Dijkstra and ant colony algorithms require more time and calculation to obtain the solution. Therefore, from the perspective of theoretical analysis, the time complexity of the DijkstraΘ
(
N
2
) and the time complexity of traditional ant colony algorithms were greater than that of our approach. These two solutions employ the global optimization approach but do not show promising running speed. The time complexity of the KC algorithm increases linearly.For the sake of a number of candidates in many SONs, which continuously increase along with the growth of the SON, by taking more storage space in computing service (numerous matrices with the QoS of links), the approach obviously has quick convergence speed. However, the KC algorithm is not optimal. In the worst case, the iterations would reachΘ
(
N
). Three simulation time curves of those algorithms which would vary with the numbers of metaknowledge units or the candidates are shown in Figures 2 and 3. The number of metaknowledge units influences our approach, whereas the number of the candidates influences the two other approaches.Figure 3
Time curves with candidates.The metric for evaluating the KC approach performance is the QoS rate. This rate is defined as(2)
QoS
rate
=
numbers
of
satisfied
instances
numbers
of
required
.For this target, our approach has a lower QoS rate just like what is shown in Figure4. This figure shows that our QoS rate is less than that of the other algorithms, particularly when a number of candidates exist. Comparing with other algorithms, our approach simplified the composition progress at the cost of QoS rate.Figure 4
QoS rate of three algorithms.We also implement another two common heuristic algorithms used in service composition for comparison. One is ACO4WS [30], which is based on a general knowledge model, and the other is mixed integer linear programming, an algorithm for semiautomatic merging and alignment ontologies. Both algorithms are applicable to a wide range of knowledge representation and ontology development systems. Three algorithms are based on a different model, but the similarity is that all of them map the function modules into node graphs, and all focus on the matrix of QoS. Three simulation time curves of those algorithms varied with the candidates, as shown in Figure 5.Figure 5
QoS rate with three local optimization methods.The experimental results indicate that the QoS rate of each algorithm decreases slightly with the increase of function modules because finding a path in a more complex graph is difficult. However, the QoS rate of KC has a higher value than that of the two other algorithms because KC uses a simple principle to measure QoS (smaller is better), which can fulfill most of the QoS attributes.


## 6. Conclusions

In this study, we investigated the KC algorithm in the SON based on distributed knowledge systems. Unlike various existing studies, our work converts the problem into two sections for analysis. First, the knowledge-based service composition is transformed into the instance path in the graph with a sequence work flow with interface between the previous output and successor input. Second, the KC algorithm with better QoS is transformed into the shortest path problem, which has a local optimization result related to the KC model. Regarding the performance shown in Section5, we believe that the proposed approach can open a wide range of new studies intended to improve the performance of knowledge-based information sharing or create new combined service across various disciplines (e.g., digital biomedical and aerospace material industries). We intend to study another algorithm to address such problems in the future. Such an algorithm with better QoS can be solved by adapting other optimization algorithms as part of our future work.



---

*Source: 126296-2015-03-30.xml*